SAP Build Process Automation combines capabilities from SAP Workflow Management and SAP Intelligent RPA with a powerful, yet intuitive no-code development experience. SAP Build Process Automation enables business users and technologists to become citizen developers. With powerful yet intuitive low-code and no-code capabilities, the solution supports you in driving automation by tapping into the expertise of citizen developers. Check here for What’s New and Learn more from the roadmap.
In my Blog post Business Event Triggers in SAP Build Process Automation for SAP S/4HANA Cloud : The Customer Return (BKP) Use Case I have covered the concepts of business events and how to configure business events for the use case for Customer Return for SAP S/4HANA Cloud. There is also blog post for the use case Manage Credit Block on Sales Orders . In continuation to the same, in this blog post we will learn how to create an event-trigger for “Manage Billing Block on Sales Order”.
Billing block is applied in Sales Order by internal sales representatives to prevent invoice being created in case of sales returns. These billing blocks need to be updated or deleted in random or on-demand fashion and is time critical activity in Order-to-Cash process. In many organizations this process is still manual where internal sales representatives get billing block change requests in form of Excel or Email attachment. Sales representatives download these attachments and then sales orders are manually updated in the S/4HANA system based on data in the excel files or attachments.
In this blog, we will create a process to manage billing blocks created for an existing Sales Order. Of course, the process can also be modified slightly to handle new Sales Orders created with billing block.
Event Driven Architecture for Sales Order Packages
Pre-requisites: Event Mesh configuration is done as per the pre-requisites mentioned in blog.
For detailed step by step guide on how to add event triggers to a process, follow Create Event Triggers documentation.
For the “Manage Billing Block on Sales Order” use case, the event required is Billing block status changed (ce/sap/s4/beh/salesorder/v1/SalesOrder/OvrlBlgBlkStsChgd/v1) . Details of the event is available on Business Accelerator Hub.
Sales Order Billing Block Status Changed Event
Note: Once the event is added as trigger, the payload defined in the event is available as Process Inputs and can be used later in the process for actions, decisions, mail notifications, etc.
Sales Order Billing Block Status Changed Event Trigger Outputs / Process Inputs.
This is very helpful as most of the times in SAP S/4HANA , the events contain minimum information of the business object due to security reasons. For practical implementations of business processes, further API calls via Actions are necessary which need the business object ID and other parameters coming from the event payload.
For example, to get the item level details of a Sales Order, there is a need to make further API call which takes the Sales Order from the event trigger as an input.
Please refer to Business Accelerator Hub for details on the APIs for Sales Order.
There could be many variations for the Sales Order process for billing block removal.
A sample process could be like the following:
Sample Billing Block Removal Process
Create Sales Order
Update Sales Order and Add Billing Block
Sample Approval Form
4. Approve the form and check for email notification.
5. To confirm, optionally you can check that the billing block is removed for the sales order in SAP S/4HANA.
Billing Block is Removed
Note:
Now the business events configured via Event Mesh can be monitored via Monitoring – Event Acquisition – Business Events.
The business events for last 7 days are available along with the payload information for debugging purposes. This information can also be downloaded for reference.
Event Monitoring
Other Use Cases for event triggers:
Do let me know in case of queries or feedback.