Azure Logic Apps connected to SAP, and now what?
So we've released to public preview the SAP connector for Azure Logic Apps which lets you call or be called as RFCs, BAPIs, as well as send and receive IDOCs. But beyond the technical aspect, what does that mean in terms of business process, patterns you can enable with these? What does it really mean you can achieve?
Here's a non-holistic set of practical end-to-end scenarios we've seen enabled using the combined power of SAP and Logic Apps in Azure.
The first scenario is B2B (Business to Business) and plays to Logic Apps' core strengths. It makes an otherwise high entry price scenario available for free at the very bottom of the scale while capable to scale up in performance to very high transaction volumes, with a pay-as-you-go model. You register a SAP connector trigger your send B2B Logic App with SAP for IDOCs (say purchase order - PO), you have an XML message validation action by schema, followed by a transform XSLT map action, an exchange protocol encode action (X12 for North America businesses, EDIFACT for European business), an AS2 encode action (with optional certificate based encryption and signing), and finally a send action - typically HTTP but you have (S)FTP, SMTP available also. The opposite receive B2B Logic App will start with the reverse trigger (HTTP when a request is received, (S)FTP when a new file is created), decode the AS2 message (optionally send an MDN acknowledgement), decode the X12 or EDIFACT payload, XML message validation, transform the XML with XSLT to an IDOC XML, send with SAP connector send message the IDOC to the SAP system. To further dig into this B2B scenario, here are deep references to the components involved:
- HTTP request trigger (and response, for the synchronous MDN) https://docs.microsoft.com/en-us/azure/connectors/connectors-native-reqres
- SFTP connector https://docs.microsoft.com/en-us/azure/connectors/connectors-sftp-ssh
- SMTP connector to send e-mails https://docs.microsoft.com/en-us/azure/connectors/connectors-create-api-smtp
- B2B connectors overview with AS2, X12, EDIFACT. Talks also about the Integration Account you will use to store B2B artifacts of Partner profile, Agreements, certificates, protocol schemas https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-enterprise-integration-overview
- Do note the link to monitoring of your B2B operation through a dedicated solution extending OMS / Azure Log Analytics
- XML message validation by XSD schema, also using the Integration Account https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-enterprise-integration-xml-validation
- XML message transformation with XSLT map action, also using the Integration Account https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-enterprise-integration-transform
- If you need to create new maps and schema, get the Enterprise Integration SDK for Visual Studio at https://aka.ms/vsmapsandschemas
- Pay-as-you-go current pricing for Logic Apps at https://azure.microsoft.com/en-us/pricing/details/logic-apps/
A second scenario is the integration between SAP and other ERP systems SalesForce, Dynamics 365 (CRM), Workday (Human Resources with HCM and other scenarios with the wide SOAP API surface of Workday) through logic Apps. References for further details on the elements of this scenario:
- Salesforce connector for Logic Apps https://docs.microsoft.com/en-us/azure/connectors/connectors-create-api-salesforce
- Dynamics 365 CRM connector for Logic Apps https://docs.microsoft.com/en-us/azure/connectors/connectors-create-api-crmonline
- Workday HCM connector for Logic Apps https://docs.microsoft.com/en-us/connectors/workdayhcm/
- And also reach other Workday SOAP API by either importing WSDL for SOAP Custom Connector or using SOAP pass-through Custom Connector with transform to create the request payload https://docs.microsoft.com/en-us/connectors/custom-connectors/create-register-logic-apps-soap-connector
A third scenario is the integration between SAP and custom enterprise services based on REST, SOAP protocols using the Logic App custom connectors or File shared based integration points (typically for batch payloads), using also then the Flat File Encode and Decode built-in actions of Logic Apps. References for further details on these connection points:
- Create a Logic Apps Custom Connector from either OpenAPI definition aka swagger or Postman collection https://docs.microsoft.com/en-us/connectors/custom-connectors/create-logic-apps-connector
- (SOAP, see above reference)
- Connect to File System SMB shares from Logic Apps for either receiving or sending files https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-using-file-connector
- Encode or Decode Flat Files in Logic Apps, such as .csv files https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-enterprise-integration-flatfile
A fourth scenario is the migration of existing integration flows from BizTalk Server to a native cloud integration using Logic Apps. Notice the ease of re-using existing integration artifacts like XML-, protocol- schemas and maps, with the same SAP XML message schemas.
In all those we commonly observe the use of SQL, Azure Table connectors to fetch reference data, as well as the escape to Azure Function to augment the integration logic with custom code. References for further details on these connection / extension points:
- Connect to Azure SQL DB or to on-premises SQL Server with Logic Apps https://docs.microsoft.com/en-us/azure/connectors/connectors-create-api-sqlazure
- Connect to Azure Table with Logic Apps https://docs.microsoft.com/en-us/connectors/azuretables/
- Use Azure Functions within Logic Apps https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-azure-functions
In conclusion, let me share although the thought borrowed from my colleague Divya, that in general the integration you enable for SAP with Logic Apps fall into two categories - those based on natively XML payloads, and those where Logic Apps let you escape from XML and reach out to other format based services, such as Json-based (REST) services. One final reference on this topic to a fellow blogger:
- Converting XML to JSon with Logic Apps https://blogs.msdn.microsoft.com/mioteg/2017/07/06/converting-xml-to-json-with-azure-logic-apps/
Now it's your turn: what have you connected SAP to using Azure Logic Apps?