Skip to Content

Examples of using SAP_WAPI


Our webdynpro application has to use UWL and SAP workflow.

We can’t find more examples how to work with SAP_WAPI, and any documentation for workflow API in the net.

Actually we have to use workflow only for transfer data from one task to another. All user interface will be in webdynpro without SAPGUI.

We can’t answer to some questions because of we never used to work with sapworkflows:

- What BOR object to use for creating our type object.

- What methods, events, attributes to build?

- What is better to use for starting workflow: sap_wapi_create_event or sap_wapi_start_workflow.

- And examples how to manage sap workflow via RFC-calls

Appreciate for your help.


a member of HR project team

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Posted on Dec 03, 2007 at 01:11 PM

    Hi Sergey,

    My experience is of using Web Dynpro to work with work items from an already-started workflow, and I have used the following SAP_WAPI calls:

    SAP_WAPI_GET_HEADER - to get high level information about a work item

    SAP_WAPI_GET_WORKITEM_DETAIL - to get information about a work item

    SAP_WAPI_READ_CONTAINER - to get information from a work item's container

    SAP_WAPI_DECISION_READ - to get the available decision options for a decision-type work item

    SAP_WAPI_CREATE_EVENT - to create a work item event with attached container values

    SAP_WAPI_GET_OBJECTS - to get information about the BOR objects associated with a work item

    SAP_WAPI_WORKITEM_COMPLETE - to complete a work item and update container values at the same time

    SAP_WAPI_SUBSTITUTES_GET - get a list of the specified user's substitutes


    In general if you browse function group SWRC you can see all the SAP_WAPI function modules and see what they do.

    Best regards,


    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Dec 03, 2007 at 01:42 PM

    Hi Sergey,

    First of all, I don't have experience with this, but I have experience with workflow ;-).

    To start the workflow use SAP_WAPI_CREATE_EVENT, it is easier to maintain when a new workflow is created for the process.

    What BOR you need to use depends a bit on the process and data you need in the workflow. If you need to create something new you could also use a class. Jocelyn Dart wrote some excellent blogs about this.

    Depending on the process maybe it is an option to use a guided procedure in stead of a workflow. It mostly depends on the fact if you need data from the back-end I think.



    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 04, 2007 at 06:34 AM

    Hi Sergey

    Binding from workflow to task and back should enable you to transfer data from one step to another of a single workflow, sub-workflows, etc. You don't need the SAP_WAPIs for this...

    Good Luck


    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.