Skip to Content
Author's profile photo Former Member

Developing SAP Workflow Apps for iOS – Setting the Wheels in Motion

OK, we have all enjoyed reading about how to jump start the SAP iOS development in our organization in the excellent post by Guy Soffer – Developing SAP iOS Apps – It’s Simpler Than You Think!

Now, it’s time to do some heavy lifting…

Every organization has many workflow processes, so many managers find themselves constantly being asked to approve a certain leave request here, or a purchase order for a brand new iPhone there (for testing purposes, of course 🙂 ). Some managers might even say that they have two inboxes to maintain – one for the regular emails and the other for the workflow tasks they have to process each day. 

Now, I can’t help you create a better email app for iOS, mainly because Apple did a great job on their own, but what I can do is make your life easier while creating the SAP Workflow App. A lot easier…

Here, SAP NetWeaver Gateway comes to my help. By using open protocols, it exposes the complex workflow data (as it is maintained in the standard SAP Business systems) in an easy to consume format. And the best part? When you install an SAP NetWeaver Gateway server, you get a built-in Workflow service! Even if you choose to extend it, the process below still applies.

In order to generate the Workflow app, I will use the SAP NetWeaver Gateway tool for Xcode. It will help me find the workflow service I want to work with. For information about installing and configuring the tool to work with the Gateway demo system, refer to Guy’s blog post again.

Note: The Gateway server I used in my demo is different to the one in the Gateway demo system, so the data you will get will probably be different to that shown in the screen shots below.

After you finish configuring the tool, open it, enter a name for your application in the Application Name field, and choose the “Workflow (iPhone)” application type.

Workflow Application.png

When you click Browse, the tool displays only the valid workflow services – the generic Workflow service and the services that extend it.

Selected Service.png

Once you have selected the service, press the Next button and select the location where you want to save the generated application. After that, the wizard closes and the app is displayed. Yes, it’s hard to believe, but you are done. 🙂

At this point you must be asking yourself “Done?! where did the rest of the configurations go?!”, or “How does the generated application know what data to present first without me specifying it?!” or my favorite “How do I tell the generated application that in SAPish, ‘approve’ means ‘0001’, and ‘reject’ means ‘0002’?!”

Well the answer to these questions is quite simple. Since the tool knows you are generating a Workflow App, the flow of the generated app is obvious. The first view presents the list of tasks, and from there you can drill-down to see additional data. In addition, the generated app even supports taking actions, which enables you to apply your decision from within the app!

OK enough talking, let’s see the generated application in action.

On the application’s login screen, enter the same user name and password you used earlier to connect to the Gateway server. Once logged in, you can see your Workflow inbox with all the tasks assigned to you. You can filter them by type and, of course, search the tasks.



Once you select a specific task, you can see all its details. If you choose, you may also navigate to see additional data like participants, attachments, and comments (if they exist)




And finally, when you are ready to make a decision, just click on the button, write a comment, and send.

Make Decision.pngSend Apply.png

So as you can see, by merely selecting a service and clicking a button, you have generated a full-blown iOS business application.

Moreover, if you are familiar with iOS development, you can easily customize the code of the generated app and adjust it to your needs. The generated code is well-documented and easy to understand. Refer to the tool’s documentation for more information.

And after you show this app to your manager, I’m sure you can ask him for that Leave Request. Judging by how easy it is to approve something using the generated app, I am sure you will get his ‘0001’ 🙂

Feel free to share your feedback in theComments section.

For #SAPGateway blogs and updates please follow @shirilevil Twitter account.

Assigned tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Guy Soffer
      Guy Soffer

      Great post Maxim!!

      Author's profile photo Former Member
      Former Member

      Cool, very useful!

      Author's profile photo Alexander Sperling
      Alexander Sperling

      Nice blog!

      Author's profile photo Ariel Bangiev
      Ariel Bangiev

      Wow really amazing blog !!

      Author's profile photo Uri Nizan
      Uri Nizan

      Great post, Maxim.


      Author's profile photo Former Member
      Former Member

      Great blog -Now it's even easier to consume the Gateway Workflow service 🙂

      Author's profile photo Former Member
      Former Member


      Author's profile photo Michal Keidar
      Michal Keidar

      Well done maxim, now I can too set the wheels in motion 🙂

      Author's profile photo Ofer Wolff
      Ofer Wolff

      good one 🙂

      Author's profile photo Former Member
      Former Member

      nice blog post!

      Author's profile photo Vikas Singh
      Vikas Singh

      Awesome - thanks .

      Author's profile photo Wouter Peeters
      Wouter Peeters

      Nice blog post! Could you provide extra informaiton on how the backend GW service was created? Is this entirely custom development, or did you reuse objects?


      Author's profile photo William van Strien
      William van Strien

      Nice post. I assume the full-automatic generation of the workflow-type specific taskdetails is made possible by WFService $expand=ExtensibleElements that exposes all header and workitemcontainer fields as data in the OData response; and that all the fields are default simple displayed.

      Good start, for fields that are not applicable to display (e.g. internal data); you can next modify the generated code; also you change the code to modify the format, styling and so of the displayed data fields.

      Author's profile photo Syam Babu
      Syam Babu


      Good Work

      Author's profile photo Former Member
      Former Member

      Hi Maxim.

      That looks fantastic. Would users using gateway to access this app be covered under the gateway runtime licences if they already had a sap account ?


      Author's profile photo Carlos Roggan
      Carlos Roggan

      very good blog - interesting and nice to read!

      Looking forward for the next one... 😉

      Author's profile photo Former Member
      Former Member

      Great post!!!

      Author's profile photo Martin Fischer
      Martin Fischer

      Your blog shows what a powerful tool NetWeaver Gateway is for all "non SAP" developers!

      Author's profile photo Former Member
      Former Member

      Hey, I have a query, do we have to any separate coding or config to pull attachments from SRM to Gateway? Need help in understanding how to get attachments from SRM to Mobile.

      Thanks in advance for your help.


      Author's profile photo Syam Babu
      Syam Babu

      Hi Sanddep,

      in SRM system no need to do any coding also but you should maintain the Config for Workflows in GW System to relevant SRM Tasks.