Enterprise Resource Planning Blogs by SAP
Get insights and updates about cloud ERP and RISE with SAP, SAP S/4HANA and SAP S/4HANA Cloud, and more enterprise management capabilities with SAP blog posts.
cancel
Showing results for 
Search instead for 
Did you mean: 
MartinSlavik
Associate
Associate
The purpose of this blog is to provide to you a comprehensive information about integration of SAP  Business One with Document Information Extraction service, based on the SAP Business One version 10.0 release 2105.

Document Information Extraction is an existing service (API) from SAP that automatically reads and extracts information from digital document files and scanned documents. The service is to be made available for use with SAP Business One to assist customers by removing the need to manually process documents such as invoices. The basic scenario is following

  1. SAP Business One connects to the Document Information Extraction service through Electronic Document Service and an API.

  2. Document Information Extraction service reads A/P invoices from received PDFs and JPGs before communicating the structured information, in .JSON files, to SAP Business One

  3. The response from the service, including the JSON file, is stored in system database in ECM8 table.

  4. The import process itself is maintained by the Electronic Documents Import Wizard. As a result the A/P invoice drafts are created.


 

  • The service is activated and controlled through settings in Document Settings under a new Document Information Extraction protocol.


 

  • Document Information Extraction is a cloud service that is hosted and operated through SAP Business Technology Platform. Document Information Extraction service is available for purchase separately from SAP Business One licenses.


 

Document Settings

A new tab Doc. Information Extract. is available for Document Settings (follow path Administration → System Initialization → Document Settings) with information and settings dedicated to the Document Information Extraction service:

Document Information Extraction

  • Enable Protocol

  • UAA URL

  • PDF Folder for Extraction: location on server path definition (from a Linux operating system)

  • PDF Folder for Extraction (Windows): location on server (for a Windows operating system) from where the service collects PDFs and sends them to Document Information Extraction service. Related PDFs are to be stored and saved here.

  • Client Secret: based on SAP BTP account

  • Client ID: based on SCP account

  • Service URL


Note: The Following are examples of setup for folders "PDF" that are located on SAP Business One share folder for both Linux and Windows operating systems:

 

Preparing for Document Information Extraction

  • Check that a path is set up for your attachment folder in General Settings (follow path Administration → System Initialization → General Settings → Paths).

  • Add the settings and information described above in Document Settings. In your SAP Business Technology Platform (SBTP) account, open the related Service Key and copy the relevant information to Document Settings in SAP Business One.



Note: As for HANA database there is a need to specify separately the path to the folder with documents for both Windows and Linux.

 

 

Electronic Documents Service

Document Information Extraction Service uses Electronic Documents Service to connect with SAP Business One.

 

 

Electronic Documents Import Wizard

The Electronic Document Import Wizard use in SAP Business One provides the ability to:

  • Connect imported document with base document

  • Visualize imported documents before the creation of drafts

  • Check whether imported documents are correctly recognized


 

The SAP Business One integration with Document Information Extraction service is to work through Electronic Document Import Wizard functionality in all localizations except for Brazil, Argentina, Costa Rica and Guatemala. The Electronic Document Import Wizard provides dedicated functionality for importing electronic documents to the system. For the Document Information Extraction service integration, there is the Document Information Extraction protocol under which relevant documents are imported.

The default incoming mapping determination is available now. The recommended setup includes the relevant document type A/P invoice and the identification of business partner through business partner name or Federal Tax ID as preferred options.

 

Electronic Document Import Wizard Steps

Step 1 of the Electronic Document Import Wizard gives to the user the opportunity to define the rules for the imported document. As it was mentioned earlier the document for the Document Information Extraction protocol are transferred to the system database (to ECM8 table) there is a need to define the parameters for identification of document type and Business Partner. Without these parameters there is not possible in the end of the process to create document draft.

Therefore, there is a need to provide a rule which defines how the system should identify the business partner. By default, there are defined two places – Business Partner Name and Business Partner Tax ID.

It is possible to use the system’s Electronic File Manager file or partner/user can adopt it to the required form and use it. As Data Source for the file system is using XML created out of the JSON provided from Document Information Extraction service

 

Step 2 of the Electronic Document Import Wizard provides information about the initial determination status of the available files for import. It is possible to see the status, and eventually the reason for any error, in the Message column.


In some cases, for example when there is no business partner found in the database, it is possible to correct the information in the respective data. For example, you can make a change in Business Partner Master Data and then through the option You Can Also, you can re-determine the problematic files that are available for import.

It is possible to use the selection criteria that are available in step 2 of the wizard to influence the selection of documents for processing by the wizard.

For example you can see the documents finished with error during the determination process – when system evaluates the documents stored in ECM8 table and checks whether the draft could be created. Such documents can be seen when checkbox Error is checked.

 

Step 3 of the Electronic Documents Import Wizard carries out a match of imported data from the Document Information Extraction service and previews the relevant data before document drafts are created. You can check the original document by selecting the golden arrow next to the Tax ID to compare the identified business partner, items, prices, quantity, and the identified base documents.

System tries to find the related base document. It is, at first, based on the Purchase Order value from the processed file. At second place it tries to identify the open Purchase Order relevant for the same Business Partner, which is matching items from processed document. The first successful match is proposed to the user. User can remove or replace the identified base document, by right-clicking and using the context menu.

When you choose the Operation "Generate", the system creates a document draft. When selecting "Generate", it is possible to set this operation for individual rows, not only for the whole document.

 

Step 4 of the Electronic Documents Import Wizard informs you of the status of the created drafts.

 

Completing the Documents 

The created drafts are viewed in the Document Draft Report and the Electronic Documents Monitor. From both locations, it is possible to finish the document from draft.

In the Document Draft Report, there are two new columns eDoc Protocol and Source File Path and Name to identify the protocol used for the import of a particular document as well as the file name/path of the original document.

 

Whats next?  


This is a short summary of possible functionality in SAP Business One. It should help you to understand the process of the integration  and the functionality in detail.  Then together with your customer you can elaborate on the possible approach, considering the number of the documents and possible benefits from using the integration with the SAP AI Business service.

No matter what is your industry it’s undeniable that with the help of AI, specifically the Document information Extraction,  can help you overcome various challenges. I would like to ask you to share your feedback or thoughts in a comment or ask questions in the Q&A tag area here: https://answers.sap.com/tags/01200615320800000816

 

The additional related materials can help you as well:

A video with a description of the overall process can be viewed at the following Web link.

 

Related documentation for the set-up of an account on the SAP Business Technology platform can be viewed at the following Web link.

 

Partners (excluding OEM) who have access to SAP PartnerEdge can view the following recording for more information on AI Business Services: Replay: SAP AI Business Services in SAP Business One

 

 
10 Comments