Skip to Content
Technical Articles
Author's profile photo Gunter Albrecht

Supplier Invoice posting with SAP Process Automation

Motivation

Paper has been replaced by an increased volume of emails or electronic documents in general. If you speak with purchasing or accounts payable departments you hear that they work with a high amount of PDF invoices from countless suppliers.

Entering these supplier invoices takes tremendous effort: So why not automate it? This blog outlines the approach.

Business Process

Image%201%3A%20Procure-to-pay%20process%20in%20business%20process%20map

Image 1: Procure-to-pay process in business process map

The procure to pay process we look at is part of source to pay in the SAP S/4HANA Intelligent Enterprise framework. There are many variations possible but in principle it’s like that:

  1. Purchase requisitions bundled into purchase orders.
  2. Purchase orders are either with an account assignment e.g. to a cost center (often for indirect procurement) or to stock.
  3. Supplier confirms date and quantity (scheduling, PO confirmation)
  4. Logistics processes are involved for delivery e.g. inbound delivery or not depending on the goods procured. Goods receipt process is needed for inventory managed goods.
  5. The supplier provides and invoice which Accounts Payable or Purchasing enters into the S/4HANA system as a supplier invoice.
  6. Accounts Payable department triggers supplier payment and clears the suppliers AP account.

Our automation addresses point 5: We assume we receive PDF invoices from suppliers into our outlook mailbox.

Image%202%3A%20Outline%20of%20automation%20flow

Image 2: Outline of automation flow

This video illustrates the end-to-end process from email to created invoice in S/4HANA Cloud.

Solution Architecture

The architecture uses standard S/4HANA Cloud APIs made available by integration scenario

Scenario IDSAP_COM_0057 Scenario: Supplier Invoice Integration

You can set this scenario to “inbound communication” only as there are only calls made into S/4HANA Cloud.

Image%203%3A%20Communication%20scenario%20in%20S/4HANA%20Cloud%20for%20supplier%20invoices

Image 3: Communication scenario in S/4HANA Cloud for supplier invoices

Altogether this boils down to below solution architecture using the OData v2 APIs shown above with the technical user defined for the scenario.

Image%204%3A%20Solution%20architecture%20for%20automation%20scenario.

Image 4: Solution architecture for automation scenario.

The APIs require CSRF tokens to be called, therefore a GET precedes every POST. The business object type to be used is BUS2081.

Details explained

Finally a walk through the flow with some – hopefully – noteworthy details of how to develop this automation.

Summary

We have seen an example of how SAP Process Automation can help your hyper-automation journey. Of course the story doesn’t end here. With AI business services you can also train your own document information extraction and apply it to other business processes:

  • Delivery documents/ Goods receipt documents
  • Quality Management: Scan paper forms to automated QM result entry
  • Purchase order to sales order conversion in an O2C scenario

Do you have other scenarios in mind? If there is strong interest we can help you to firm up your use case and idea with a prototype! Feel free to contact me.

Assigned Tags

      10 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Jay Adnure
      Jay Adnure

      Very well explained thank you Gunter for simplifying the process with this blog.

      Author's profile photo Paul PINARD
      Paul PINARD

      Great blog!

      Author's profile photo Murali Shanmugham
      Murali Shanmugham

      Awesome.

      Author's profile photo Sanket Sachde
      Sanket Sachde

      Very Powerful! This opens the gates to unlimited possibilities!

      Author's profile photo Mohamed Cassim
      Mohamed Cassim

      Samuel Muturi , Malebona Mokhutsoane , Hani HAJJI , Haaroon Daya

      Please take note of the solution presented in this blog.

      Gunter Albrecht , thanks for sharing this - is this end-to-end automation available as a standard solution in the RPA store?

      Author's profile photo Gunter Albrecht
      Gunter Albrecht
      Blog Post Author

      Good day Mohamed,

      the service to translate documents into data (e.g. for invoices) is standard in iRPA and (as shown here) in SAP Process Automation. The complete flow is not (yet) available but you might just follow the blog or build on template which is close to it. If you have questions at that time, feel free to ask.

      Author's profile photo Abraham Zuloaga
      Abraham Zuloaga

      Excellent blog

      Author's profile photo Ignacio Kristof
      Ignacio Kristof

      Thank you for this fantastic demo. Is this applicable to S/4HANA On Premise as well?

      Author's profile photo Gunter Albrecht
      Gunter Albrecht
      Blog Post Author

      Good day Ignacio,

      I haven't tried it out but the creation of supplier invoices works for sure in a recent S/4HANA. The API is available since 2020FPS02. You find it here: https://api.sap.com/api/OP_API_SUPPLIERINVOICE_PROCESS_SRV/resource (header, POST)

      From what I see it's just copy & paste of what was done for S/4HANA Cloud. As for attachment upload the API was created at the same time (2020FPS02) https://api.sap.com/api/OP_API_CV_ATTACHMENT_SRV_0001/resource and it looks "same" like the one I've used for S/4HANA Cloud.

      I see no roadblock - maybe just a URL change from what I did.

      P.S.: Stay tuned for an upcoming blog of my colleague - he's showing how to run this process with SAP AppGyver and S/4HANA Cloud. 😀

      Author's profile photo Stuti Vyas
      Stuti Vyas

      Hello Gunter,

      This is really Awesome! And I am also trying to implement similar scenario but I have added action for creating supplier Invoice separately in the project. Along that I am facing some issues. So can we import this project or do you have step by step guide which I can refer to achieve this.
      Thanks in advance!