Integrating SAP Cloud Platform Workflow Using SAP Business Workflow

There’s a generic standard task to integrate SAP Cloud Platform Workflow into SAP Business Workflow.

Prerequisites

You have executed the initial setup for integrating workflows of the SAP Cloud Platform Workflow service with the SAP Business Workflow as described in Configuring SAP Cloud Platform Workflow Integration.

Procedure

  1. Copy the standard task.
    1. Start transaction PFTS.
    2. Enter the standard task identifier 77408500.
    3. Choose Copy and follow the instructions.

      Make sure that you use your own object abbreviation and development package.

  2. Edit the task and add the required container element. See below Adjust the Task Container.
  3. Save the task.
  4. Integrate this task into your Business Workflow and do the mapping into this task and back to the workflow container.
  5. Activate your Business Workflow.

Results

This new task behaves like a background task, but it stays in status STARTED until a completion event is sent from SAP Cloud Platform Workflow back to the ABAP system.

Adjust the Task Container

Context

All importing parameters of the task container except for the system parameters are read and the start context of the SAP Cloud Platform Workflow is generated. This start context is rendered like this:

Once the completion callback is triggered, all exporting parameters of the task container with the exception of the system parameters are read and mapped back from the SAP Cloud Platform Workflow context to the task container.

You can use standard mapping in the workflow editor to map the parameters into the task container and back to the workflow container once the task is completed.

Procedure

Add your importing and exporting parameters into the task container and do the mapping from workflow to task and back.
The transfer to the SAP Cloud Platform Workflow and back to the ABAP system is executed automatically. Be aware, that the naming has fixed rules and names can't be changed.