Integrating SAP Business Processes in Microsoft Teams using SAP Business Technology Platform
Enterprise business users are looking to shift from standard web-based experience to alternate channels for performing their day-to-day business operations. It is becoming quite evident to enable these users with multi-channel user experience to increase the usability and ease of performing their tasks.
SAP and Microsoft are creating innovation together by integrating Microsoft Teams across SAP solutions for seamless collaboration across business processes/workflows for internal and external stakeholders.
In this post, we will focus on SAP S/4HANA integration with Microsoft Teams by building an extension application leveraging the SAP Business Technology platform (SAP BTP), allowing users to perform Purchase Requisition approval via Microsoft Teams.
In addition, with the adoption of RISE with SAP on Azure, organizations are looking at utilizing the best of both environments and building intuitive and innovative solutions for their business users. The focus here will be on integration with SAP S/4HANA (on-premises) leveraging SAP Connectivity Services and SAP S/4HANA on Azure (RISE with SAP) leveraging SAP Private Link Service in SAP BTP.
Here is the link to the GitHub repository – Integrate SAP Business Processes in Microsoft Teams using SAP Business Technology Platform (github.com)
Let us get started!
There has been a transition from GUI to CUI (Conversational User Interface) for consumer-based applications as well as for enterprise business applications. The UX transition and transformation have helped organizations increase the usability and adoption of these different UX channels and business application usage.
Given the above context, we will show how a simple extension application developed on SAP BTP can provide SAP business users with the flexibility to perform Purchase Requisition Approval via Microsoft Teams. This application can be further enhanced for additional use cases. For example, we can create alerts/notifications for other business operations, create a collaboration platform for a team, workflow actions, and show data from multiple systems within Microsoft Teams instead of navigating to the Web or SAP GUI user interface etc.
Let us look at a simple business process flow of Purchase Requisition Approval.
The diagram below depicts the user journey of a purchasing manager to whom purchase requisition details are sent for approval/rejection. Before the approval process, if the business user wants to look at additional information, they can query and then complete the actions.
- Step 1: SAP business user creates Purchase Requisition (PR) in SAP S/4HANA.
- Step 2: PR creation event is published to SAP Event Mesh from SAP S/4HANA.
- Step 3: The extension application in SAP BTP receives the PR event leveraging webhook utility (In future, a direct integration between SAP Event Mesh and Azure Event Grid will be made available. Check out the Influence Opportunity Homepage – Customer Influence ).
- Step 4: Fetches additional details of the Purchase Requisition by querying the SAP. S/4HANA system via SAP Destination Service and Cloud Connector.
- Step 5: Notification is sent to approver.
- Step 6: Approve/reject the notification.
- Step 7: Extension App sends the Approval/Rejection status to the SAP S/4HANA system.
For this scenario, let us look at the architecture and technical services used in SAP Business Technology Platform.
The two diagrams below depict the architectures with SAP BTP, Microsoft Azure and SAP S/4HANA (on-premises & on Microsoft Azure).
The key components leveraged are SAP Event Mesh, SAP Cloud Foundry Runtime, SAP Destination Services, Cloud Connector, SAP Authorization and Trust Management Service from SAP Business Technology Platform.
We will use Azure Bot Service, Blob Storage, Enterprise App Registration, MS Graph, and Azure Active Directory from the Microsoft Azure Platform and Microsoft Teams. Regarding connectivity, we will use the SAP Connectivity Service for an on-premises use case. In the case of SAP S/4HANA on Azure (RISE with SAP), we recommend using the SAP Private Link Service (see the connectivity use case).
Let us look at the scenarios in detail.
Scenario 1: High-Level Architecture: Using SAP Connectivity Service (SAP S/4HANA on-premise)
The architecture below leverages the Cloud Connector and SAP Connectivity Service to establish secured communication between SAP BTP and SAP S/4HANA seamlessly. We will see how the communication and flow of information work.
We start with the first (1) step, wherein a business user logs into the SAP S/4HANA system to create a purchase requisition.
(2) An event is triggered from SAP S/4HANA, which is received in SAP Event Mesh using the webhook utility.
(3) Updates from SAP Event Mesh are sent to the Node.js extension application running on SAP BTP.
(4) Extension application (Node.js) sends the event to Microsoft Azure Bot Service.
(5) End-user in Microsoft Teams receives the event and approves/rejects the purchase requisition.
(6) Azure Bot Service acts as bot handler and updates are received in the SAP BTP extension application.
(7) The extension application updates the status in SAP S/4HANA via the SAP Destination service and Cloud Connector.
Note: The GitHub documentation will have the required detailed steps for configurations, setup and extension code. Link to the GitHub repository is mentioned below.
Scenario 2: High-Level Architecture: Using SAP Private Link Service (SAP S/4HANA on Azure )
The architecture below leveraging the SAP Private Link Service in SAP BTP and Azure Private Link Service for connectivity helps seamlessly establish secured communication between SAP BTP and SAP S/4HANA deployed on Microsoft Azure.
Briefly, SAP Private Link Service is available in SAP BTP with Microsoft Azure as an IaaS provider for establishing a secure connection between selected SAP BTP and Azure services, ensuring that the traffic is routed within the Azure network backbone(i.e. between SAP BTP VNet and Azure VNet).
The steps mentioned in Scenario 1 hold good except for the last step, where SAP Private Link Service is used for establishing private connection between SAP BTP and SAP S/4HANA.
Look out for the below documentation for more information on both services.
Please read this blog post, Extend your Business Processes with the new SAP Private Link service | SAP Blogs, by Harutyun Ter-Minasyan, where he talks about how to consume data from the SAP S/4HANA system securely.
Benefits of this solution
The key benefits of bringing the interoperable designs are
- Combine Microsoft Teams’ user experience with SAP BTP for SAP business processes.
- Event driven integration touch points with SAP S/4HANA with SAP Event Mesh as central eventing hub.
- Network security focused design with SAP Private Link Service specifically for RISE with SAP customers who have deployed SAP S/4HANA on Microsoft Azure.
- Single Sign-On (SSO) and Principal Propagation of users from Azure AD to SAP BTP and to SAP S/4HANA.
Scenario Setup and Deployment
To get the entire scenario working, prerequisites and initial configurations are required in SAP BTP, Microsoft Azure and SAP S/4HANA.
The GitHub repository – Integrate SAP Business Processes in Microsoft Teams using SAP Business Technology Platform (github.com) contains code samples and instructions for developing a native Microsoft Teams application and an SAP BTP extension application for extending the S/4HANA business process into the Microsoft Azure ecosystem. The GitHub repository will cover:
- Prerequisites required in Microsoft Azure, SAP BTP and SAP S/4HANA.
- Configurations in Microsoft Azure, SAP BTP and SAP S/4HANA.
- Extension Application development in Node.js. This can be enhanced to incorporate additional validations and business scenarios.
- How to set up principal propagation of users.
- How to setup and leverage SAP Private Link Service and Azure Private Link Service in case of SAP S/4HANA on Azure.
Demo showcasing business user approving Purchase Requisition via Microsoft Teams.
Approve/Reject Purchase Requisition from Microsoft Teams
During SAP Sapphire 2022 in Orlando, we had the opportunity to showcase this scenario to customers at the Microsoft booth. The ability to act on SAP business processes from Microsoft Teams via SAP BTP resonated extremely well. Microsoft Teams integration use cases with SAP SuccessFactors, SAP Sales Cloud, SAP Work Zone and others can provide customers with a quick starting point and use cases like the Purchase Requisition approval highlight how easy it is to build your own scenarios.
Showcase at SAPPHIRE 2022 – Microsoft Booth by
Holger Bruchelt, Program Manager for SAP on Azure at Microsoft
In a customer advisory board before the event, we had similar feedback: creating a more collaborative experience around SAP is currently top of mind for a lot of customers. Being able to interact with colleagues in the context of an SAP business object, but with bots can increase productivity dramatically.
- OpenSAP course on Building Applications on SAP BTP with Microsoft Services.
- Here are a few blog posts which you can refer to as well, which talks about different integration scenarios of Microsoft Teams with SAP SuccessFactors, SAP Sales Cloud and SAP Business ByDesign.
- SAP Success Factors integration with MS Teams by Martin Frick – [SAP & MS Teams] 1 – Preface and scenario introduction | SAP Blogs.
- SAP Business ByDesign Teams Integration – Single Sign-On (SSO) , Reports, Supplier with SAP Business ByDesign Teams Integration | SAP Blogs.
- Microsoft Teams Integration with SAP Sales Cloud – Microsoft Teams Integration with SAP Sales Cloud (C4C) | SAP Blogs.
I hope this has given you a brief idea of leveraging SAP BTP to create business-focused applications and extend SAP S/4HANA business workflows into the Microsoft Azure ecosystem.
You might want to look for similar scenarios and identify the benefits for your organizations from processes cycle time improvement and increased usability of business applications from Microsoft Teams as one of the user interfaces channels.
Special thanks to Praveen Kumar Padegal , Lalit Mohan Sharma and Mahesh Kumar Palavalli for building the solution, curating GitHub Repository content and for their collaboration with Microsoft for creating solutions with interoperable architecture patterns.
To learn more about SAP BTP, see the learning journey on SAP Learning called Discover SAP Business Technology Platform, a great introduction to BTP and the Intelligent Enterprise strategy to see what it’s all about for free or check out Develop Advanced Extensions with SAP Cloud SDK plus much more free learning at SAP Learning site.
What next! We will be publishing the next series to this blog post with different business scenarios and other system integrations. Try it and let us know your feedback.