SAP Document AI
SAP's reference architecture for SAP Document AISAP Document AIExtracts header fields and line items from invoices, payment advices, purchase orders and custom document types, as structured data over a REST API — the extraction is the service's, the schema can be yours.sap official, btp, first as SAP composes the service on BTP for document extractionDocument extractionGetting structured data out of a document somebody sent you — an invoice, a purchase order, a scanned form — instead of having a person key it in. The mirror image of document output, and a different problem from reading a service: the input is a file, the shape is unknown until something reads it, and the answer arrives with a confidence rather than a guarantee.SAP only: OCR, pretrained models, customer-defined schemas and LLM calls through SAP AI CoreSAP AI CoreSAP's AI service on BTP: the runtime for AI assets, and through the Generative AI Hub inside it the access to foundation models, the orchestration service with its templating, masking, filtering and grounding modules, the Prompt Registry and Document Grounding.sap official, btp and its Prompt Registry in one pipeline, with tenant-isolated persistence in SAP HANA CloudSAP HANA CloudThe managed database under most of this: CAP's default target, the store Datasphere and Analytics Cloud sit on, and a service with plans and components.sap official, btp, PostgreSQLPostgreSQLA relational database. For CAP it is the production database when the answer is not HANA, reached through an adapter that translates CDS queries into its SQL. and an object store. Its scenario pages then lay out a solution in three layers: intake through Outlook and SharePoint inbound channels, the workspace UI, the Joule Work mobile app or the upload API; classification and extraction with a confidence score per field, automatic confirmation above a threshold and review of the rest in the workspace; and posting through outbound channels, directly to a REST API, through an SAP Integration SuiteSAP Integration SuiteSAP's integration service on BTP: Cloud Integration for orchestration, API Management in front of it, and an MCP gateway that serves a managed API to agents.sap official, btp flow, or through a CAP@sap/cdsThe CAP Node.js runtime, which compiles the CDS model, serves the services declared in it, answers generic requests before any handler runs, and loads every cds-plugin.sap official, cap service that maps the fields and calls SAP S/4HANA over OData. Enrichment beyond the service's own master data lookup is left to a CAP application or an Integration Suite flow triggered from an outbound channel, and direct API posting leaves error handling, retries and monitoring to the application.
Where it sits
Who is behind it
In the atlas: maintains 1, wrote 26author
Architecture
parts read from 5 readme files,Parts, as the source names them
- End useran actoruploads documents and reviews the ones below the confidence thresholdRA0030 0-end-to-end/readme.md in SAP/architecture-center
For manual uploads, SAP Document AI covers desktop and mobile scenarios with the Document AI workspace UI and Joule Work mobile app.
RA0030 2-enrichment/readme.md in SAP/architecture-centerLow confidence documents and documents that need additional approvals are managed within Document AI workspace. Users review the document and the extractions side by side.
- API clientan actoruploads documents through the APIRA0030 1-ingestion/readme.md in SAP/architecture-center
For document sources that are not supported out of the box, or to support complex routing and transformation scenarios, the API can be used to upload documents:
- SAP Document AIclassification, extraction and workspaceSAP BTPon Document AI posts to the target system's REST API directly, Through an Integration Suite flow, Through a CAP application on Cloud Foundry, Through SAP Build Process AutomationRA0030 0-end-to-end/readme.md in SAP/architecture-center
The architecture centers around **SAP Document AI** as the core extraction engine and user interface, with optional enrichment and integration services on **SAP BTP**:
- Cloud Identity ServicesauthenticationSAP BTPRA0030 readme.md in SAP/architecture-center
Authentication is delegated to **SAP Cloud Identity Services** (Identity Authentication, Identity Directory, Identity Provisioning) using SAML 2.0 / OIDC, with optional federation to a customer or third-party Identity Provider.
- SAP Cloud Identity Services - Identity Provisioninguser and role synchronisationSAP BTPRA0030 readme.md in SAP/architecture-center
Identity Provisioning (IPS) keeps user and role assignments in sync with the customer's identity source, so access decisions made in Document AI's Authorization Management reflect the customer's central identity governance.
- SAP Integration Suiteenrichment and posting flowSAP BTPon Through an Integration Suite flowRA0030 3-posting/readme.md in SAP/architecture-center
An integration flow (iFlow) receives the Document AI extraction payload, converts to target system protocols (IDoc, SOAP, REST), applies error handling and retry logic, and posts to cloud or on-premise target systems.
- @sap/cdsenrichment and posting serviceSAP BTPon Through a CAP application on Cloud FoundryRA0030 3-posting/readme.md in SAP/architecture-center
A CAP service receives extraction notifications from Document AI, performs field mapping and posts to SAP S/4HANA Cloud (via OData APIs), on-premise S/4HANA (via Cloud Connector and OData/RFC), Business ByDesign...
- SAP Build Process Automationposting with a conditional workflowSAP BTPon Through SAP Build Process AutomationRA0030 3-posting/readme.md in SAP/architecture-center
Build Process Automation evaluates enriched delivery note data to determine posting path.
RA0030 0-end-to-end/readme.md in SAP/architecture-center**Hybrid integration**: Support for multiple integration technologies (CAP, Integration Suite, Build Process Automation) accommodates varying complexity and governance requirements.
- SAP Connectivity serviceoutbound integrationSAP BTPRA0030 readme.md in SAP/architecture-center
Outbound integration to customer systems uses the **SAP Connectivity service** and **SAP Destination service**.
- SAP Destination serviceoutbound integrationSAP BTPRA0030 readme.md in SAP/architecture-center
Outbound integration to customer systems uses the **SAP Connectivity service** and **SAP Destination service**.
- Cloud Connectorreach into on-premise systemsRA0030 readme.md in SAP/architecture-center
**Enterprise integration**: integrates into SAP and non-SAP landscapes through the Destination service and Connectivity service, with SAP Cloud Connector providing secure reach into on-premise systems such as SAP ECC and SAP S/4HANA.
Roles the source leaves open
- Document ingestiona use case, Send a document to SAP Document AIRA0030 1-ingestion/readme.md in SAP/architecture-center
The ingestion layer serves as the entry point, responsible for document capture, optional pre-processing, and submission to the AI extraction service.
RA0030 1-ingestion/readme.md in SAP/architecture-centerFor document sources that are not supported out of the box, or to support complex routing and transformation scenarios, the API can be used to upload documents:
The source draws it as @sap/cds, SAP Integration Suite.
- Document posting and system integrationa use case, Receive SAP Document AI's extraction results in an applicationRA0030 3-posting/readme.md in SAP/architecture-center
The final stage of intelligent document processing transforms validated, enriched data into business documents in enterprise systems. Selecting the appropriate integration pattern depends on complexity requirements, governance policies, and operational constraints.
RA0030 3-posting/readme.md in SAP/architecture-center[Outbound channels](https://help.sap.com/docs/document-ai/sap-document-ai/outbound-channels?locale=en-US&version=LATEST) in SAP Document AI can notify external systems when documents are on a specific step, and can include the extraction results:
The source draws it as @sap/cds, SAP Integration Suite, SAP Build Process Automation.
Ways the source names
- Document AI posts to the target system's REST API directlyRA0030 3-posting/readme.md in SAP/architecture-center
For point-to-point scenarios with no middleware requirements, SAP Document AI can post directly to target system REST APIs.
- Through an Integration Suite flowRA0030 3-posting/readme.md in SAP/architecture-center
An integration flow (iFlow) receives the Document AI extraction payload, converts to target system protocols (IDoc, SOAP, REST), applies error handling and retry logic, and posts to cloud or on-premise target systems.
- Through a CAP application on Cloud FoundryRA0030 3-posting/readme.md in SAP/architecture-center
A CAP service receives extraction notifications from Document AI, performs field mapping and posts to SAP S/4HANA Cloud (via OData APIs), on-premise S/4HANA (via Cloud Connector and OData/RFC), Business ByDesign...
- Through SAP Build Process AutomationRA0030 3-posting/readme.md in SAP/architecture-center
Build Process Automation evaluates enriched delivery note data to determine posting path.
Properties
About this work
For document-extraction
Details
Graph
Source
History
- explains → applies_to on capability:document-extractionDoor scope derived from the artifacts this piece also explains, so a door page lists it only where it holds (docs/concepts/content-on-doors.md).
- parts, areas, edges → the customer's solution: eleven parts with two actors, one area, five edges the sub-pages stateThe main readme is how SAP composes Document AI on BTP; the sub-pages are how a customer builds a solution with it, and a reader building on the service needs the second picture with the service as one box (docs/concepts/reference-architectures.md §9.1). SAP AI Core, SAP HANA Cloud, PostgreSQL and the Cloud Foundry runtime leave the parts, and what the readme says the service itself talks to, those three among them, is on the artifact's own connections. The summary keeps SAP's composition in its first half on purpose, so three of its links name no part. On the checker's reading of the first draft: SAP BTP is a zone of SAP's cloud, since no page names a subaccount, and the notification to the CAP application is stated on the design, because the artifact's connections name entries and a customer's own application is none.
- roles → ingestion typed by the sending use case, the service fixed, posting typed by the receiving use case, each with the parts the source draws in itThe design leaves two places open, the sender and the receiver, and names its own fillers for each on its ways (docs/concepts/design-roles-and-interfaces.md, P4); typed by the use cases the atlas assessed, the record reads its candidates and their states from the graph, and the figure stays as the source draws it.
- edges[client to docai].interface → the OData V4 API, api-v2The ingestion page links the upload operation of document_information_extraction_api_v2 as the API-based integration, and the service now names that surface (docs/concepts/design-roles-and-interfaces.md §3.2, P7), so the arrow says which API it lands on and wears its protocol.
- Entered the atlasDiscovered via Added by hand.
For your agent
- Ref
content:ac-sap-document-ai- JSON
- /content/ac-sap-document-ai.json
- MCP
- Connecting an agent