Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
Showing results for 
Search instead for 
Did you mean: 


SAP is widely used ERP solution in the world, and it provides number of solutions for a smooth business process, I have been part of many project assignments and one concern I have faced during all my assignments is clients or user requesting CPI message processing data so that they don't have to rely on a CPI resource.


In CPI, usually business or client wants to check what message has been processed and which one failed but unfortunately CPI monitoring cannot provide them a tabular view of all the messages and their respective status.

Since we had faced this issue, we have created a simple solution to generate a excel report which contains interface name, status and failure reason.

There are other blogs available on message processing report, but they are only displaying count of success and failure message, while this blog helps you to create a report with detailed information.


This article is helpful for people who are supporting SAP CPI projects as it reduces manual monitoring effort and also creating a simple sheet that clients and businesses can also understand and hence reduces the effort.


SAP has provided APIs to fetch CPI message processing data, to generate our report we have to call multiple APIs, we need to pass value from one API response to another API call and then we will convert the data into CSV or excel format and send it out as an email attachment.

Integration Scenario Details

Receiver Adapter Configuration:

Protocol OData
Address Tenant URL/api/v1/
Authentication Basic
Protocol HTTP
Address Tenant URL/api/v1/MessageProcessingLogs('${property.GUID}')/ErrorInformation/$value
Authentication Basic
Protocol Mail
Address SMTP address
Authentication Basic/None

IFLOW Design

Steps to be performed in Main Iflow

  1. Start Timer: It can be scheduled for the time you want to generate the report.

  2. Content Modifier: to create property “to and from date “for Odata query.

  1. Request Reply: To handle response from OData call

  2. OData Adapter: To fetch CPI logs for respective tenant based on filter query

Query: $select=LogStart,LogEnd,MessageGuid,IntegrationFlowName,Status,IntegrationArtifact&$filter=LogStart ge datetime'${property.FromDate}' and LogEnd le datetime'${property.ToDate}' and Status ne 'DISCARDED'

  1. General splitter: To split Records into individual record.



  1. Router: Two paths created in router, 1 for CPI message with failed status and 2 for all the other statuses




Steps for failed route path

  • Content modifier: to add all the required field for report added as a property

  • Request Reply: To handle response from HTTP Call

  • HTTP Adapter: To fetch error detail of a failed message using Message GUID



  • Groovy Script: To create a CSV file with Iflow name, Message ID, Start time, End time, status and error details



Steps for Default Route

  • Content modifier: to add all the required field for report added as a property

  • Groovy Script: To create a CSV file with Iflow name, Message ID, Start time, End time, status

  1. Gather: To gather all records from both failed and default route to create a single CSV file

  2. Content Modifier: To add custom CSV header


  1. Send: To be use for mail adapter to send the mail.

  2. Mail Adapter: To trigger a mail to respective people with Body as an attachment.

  3. Write Variable: To create a local variable which will hold last execution date, so that when iflow runs next time it will only fetch details after last run.





Hope this blog helps you to understand the use of SAP CPI APIs and to create a proper report.
Labels in this area