AI agents that work with SAP

SAP runs finance, procurement and supply chain for many large and mid-sized companies, and much of the work around it is still manual: chasing invoice mismatches, answering vendor queries and pulling data for reports. Gepton builds custom AI agents that work with SAP S/4HANA and ECC through published APIs and the integration paths SAP endorses, such as SAP Integration Suite. They read documents and records, prepare the next step, and leave postings and approvals to your team.

What we build in SAP

Agents designed around how your team already works in SAP, built and tested in a sandbox first.

  • Invoice exception handling

    Reviews invoices blocked for price or quantity differences, compares them with the purchase order and goods receipt, and drafts a resolution for the AP clerk.

  • Vendor query answers

    Answers supplier questions about payment status, open invoices and remittance by email or portal, using read-only access to the relevant SAP data.

  • Purchase requisition support

    Helps employees raise requisitions in plain language, checks material and cost center details, and prepares the request for approval in SAP.

  • Sales order and delivery status

    Answers customer service questions about order, delivery and billing status from SAP, so agents do not have to navigate several transactions.

  • Period-end checks

    Runs a checklist of reconciliations and open items before close and prepares a summary of exceptions for the finance team.

  • Document intake to SAP

    Extracts fields from supplier invoices, delivery notes and orders in PDF or email and prepares them for posting or review in SAP.

How it connects. Official APIs, the narrowest access.

Agents use a technical user with SAP roles limited to the transactions and data a task needs, through communication arrangements you control. We design so that agents use published APIs or services in your own namespace, route agentic access through SAP-endorsed paths, stay read-only or draft-only by default, and log every call. Financial postings and master data changes stay with authorized users. Only the fields a task needs are sent to a model. This page describes independent integration work and does not imply a partnership with or endorsement by SAP.

Systems the agent uses (example)
4 systems
  • SAPInvoice exception handling
  • GST portal exportsUsed by the GST purchase and ITC reconciliation agent
  • TallyPrimeUsed by the accounts payable invoice agent
  • Zoho BooksUsed by the month-end close assistant

From sandbox to your live SAP

A fixed-scope plan first, then weekly releases you can test.

  1. 1

    Map processes to published APIs

    We identify the SAP Business Accelerator Hub APIs, OData services or customer-namespace services each task needs and confirm they fit SAP's API policy.

  2. 2

    Connect through SAP's integration layer

    We set up communication arrangements with OAuth 2.0 or certificates, and route agent access through SAP Integration Suite or BTP where agentic access is involved.

  3. 3

    Test in a non-production system

    We build against a development or quality system with realistic data, run evaluation cases, and check load and authorization behavior.

  4. 4

    Roll out with approvals

    Agents start read-only or draft-only for one process and one team. Postings stay with users, with logs and an owner for each agent.

How agents connect to SAP

SAP S/4HANA exposes OData, SOAP and REST APIs documented on the SAP Business Accelerator Hub. In S/4HANA Cloud, access is configured through communication arrangements, with OAuth 2.0 or X.509 certificates. On-premise S/4HANA and ECC systems also offer OData services and customer-built services in your own namespace. SAP Business Technology Platform (BTP) and SAP Integration Suite sit in between for routing, security and monitoring.

SAP's API policy and AI agents

SAP's API policy, updated in 2026, says customers and partners should use published APIs and restricts using SAP APIs for AI systems that plan and execute sequences of calls on their own, except through SAP-endorsed architectures. SAP names the MCP gateway in SAP Integration Suite, SAP-provided MCP servers through Joule Studio, and the Agent2Agent protocol as those paths. Custom OData services and CDS views in the customer namespace remain permitted within limits. SAP has also restricted third-party use of the ODP RFC interface for data extraction. We design every SAP agent to follow this policy and confirm the approach with your SAP team and licensing contact before building.

Load and limits

SAP systems do not publish a single request quota like SaaS CRMs do, but agent traffic still adds load and may be throttled at the gateway or Integration Suite. We design agents to call only what a task needs, use change events where available, and schedule heavy reads outside peak hours.

What stays read-only

By default agents read documents, master data and status, and prepare drafts, such as a parked invoice or a requisition for approval. Postings, payment runs, master data changes and approvals remain with authorized users in SAP.

How this fits with Joule

SAP's own AI assistant, Joule, now includes Joule Agents and Joule Studio for building agents on SAP data, along with SAP Business Data Cloud. For processes that sit entirely inside SAP, Joule is often the most direct option. A custom agent complements it when a process spans SAP and non-SAP systems, such as email, a supplier portal or a helpdesk, or needs document handling and rules specific to your business. Where it fits, a custom agent can connect with Joule through the Agent2Agent protocol rather than around it. Document intake is covered in NLP and document AI.

AI agents and SAP in depth

Where the agent sits in an SAP landscape

An SAP agent does not connect straight to the ERP from a model. In the designs we build, the agent service sits outside SAP and reaches it through a governed layer: SAP Integration Suite or BTP for cloud and agentic access, SAP Cloud Connector when BTP needs to reach an on-premise system, and SAP Gateway exposing OData services on S/4HANA or ECC. The agent calls a small set of tools, each mapped to one published API or approved service, such as "read purchase order with items" or "create parked supplier invoice".

This keeps SAP's own controls in charge. Authorization objects, communication arrangements and gateway monitoring still apply, and the agent's tool list becomes a document your SAP team can review line by line. It also keeps the design inside SAP's API policy described on this page, because each tool maps to an endorsed path rather than open-ended calls.

Interfaces and when each fits

InterfaceTypical use by an agentNotes
OData V2 and V4 servicesReading and creating business documentsMain route on S/4HANA; published APIs listed on the Business Accelerator Hub
BAPIs and RFCOlder processes on ECCUsually wrapped in a service in your namespace or middleware, not called directly by the agent
IDocsDocument exchange with partnersBetter handled by integration middleware than by an agent
Business eventsReacting to changes, such as an invoice being blockedDelivered through SAP's event services where available

For writes, OData services use ETags, so the agent sends the version it read and SAP rejects the change if someone else edited the document in between. That small detail prevents an agent from overwriting a clerk's work.

Technical users and SAP authorizations

Each agent gets its own technical or communication user with roles built for its task in PFCG, or communication scenarios in S/4HANA Cloud. An agent that answers vendor payment questions needs display access to vendor line items for specific company codes, not posting rights. One that prepares invoices may park documents but not post them. Certificates or OAuth 2.0 client credentials are used for authentication, with secrets held in BTP's credential store or your secrets manager. Segregation of duties rules apply to technical users as they do to people, and we check new roles against your existing SoD rule set with your SAP security team.

A worked example: blocked invoice resolution

Example: a supplier invoice is blocked for a price difference.

  1. The agent receives the blocked invoice through an event or a scheduled query on blocked documents.
  2. It reads the invoice, the purchase order and the goods receipt through published APIs, and compares price, quantity and terms line by line.
  3. It checks email from the supplier for a price revision and, if found, links it as evidence.
  4. It drafts a resolution note for the AP clerk: likely cause, evidence and suggested action, such as requesting a credit note or asking the buyer to amend the purchase order.
  5. The clerk decides and acts in SAP. The agent records the outcome so similar cases are handled consistently.

The agent never releases the block or changes the purchase order. Those remain user actions under your finance controls.

The same pattern works on ECC, with one difference. Older systems often lack the published APIs S/4HANA offers, so we expose the BAPIs a process needs through services in your namespace or your existing middleware, and the agent calls those services rather than RFC directly. If an S/4HANA move is planned, we design the tool layer so that only the mapping behind each tool changes after migration, not the agent itself.

Audit logging and evidence

SAP's Security Audit Log can record logons and function calls by the agent's technical user, and change documents record changes to business objects. Integration Suite keeps message processing logs for each call that passes through it. The agent's own log adds the reasoning trail: what it read, what it compared, what it proposed and who accepted. For finance processes, this trail helps internal and statutory auditors see that a person approved every posting the agent prepared.

Testing and rollout

We build against a development system and evaluate in a quality system with data that reflects production, including your company codes, tax codes and document types, with personal data masked. Test cases cover common exceptions and difficult ones: partial deliveries, currency differences, invoices with GST mismatches, duplicate supplier invoices. Load tests confirm the agent's traffic does not affect users during peak periods such as month-end.

Useful measures for a pilot come from SAP and the agent's log together: how long blocked invoices stay blocked, how often the clerk accepts the agent's suggested resolution, how many vendor queries are answered without someone opening SAP, and how often the agent says it is unsure. We baseline these before the agent starts.

Rollout covers one process and one company code first, in read-only or draft mode. Have ready: an SAP Basis and security contact, a functional owner for the process, access to Integration Suite or BTP, and your licensing contact's view on the approach. Related pages: procurement agents, finance and accounts agents and the Agent2Agent protocol.

Questions about AI agents and SAP

Something else? Send us your question and an engineer replies with next steps.

Does SAP allow third-party AI agents to use its APIs?

SAP's 2026 API policy restricts autonomous AI use of SAP APIs except through SAP-endorsed paths such as the MCP gateway in SAP Integration Suite, SAP MCP servers through Joule Studio, and Agent2Agent. We design within those paths and review the approach with your SAP team and licensing contact.

Do you work with ECC as well as S/4HANA?

Yes. ECC systems usually rely on OData services, BAPIs exposed through services in your namespace, or middleware. We assess what is available and supported in your landscape during discovery.

Will the agent post documents in SAP?

Not by default. It prepares drafts, such as parked invoices or requisitions, for users to review and post. Automated posting is only considered for narrow cases after a pilot and with your finance controls.

Do we need SAP BTP?

For agentic access, SAP's endorsed paths run through BTP services such as Integration Suite. Many SAP customers already have BTP. If not, we discuss options with you and your SAP account team.

How does this relate to Joule?

Joule is SAP's own assistant and agent platform. A custom agent handles work that crosses SAP and other systems, and can connect with Joule agents where that is the cleaner design.

How does an agent reach an on-premise SAP system securely?

Usually through SAP BTP with the SAP Cloud Connector installed in your network. The Cloud Connector makes an outbound connection to BTP, so no inbound firewall ports need to open, and your Basis team decides exactly which backend systems and services are exposed. The agent then calls those services through Integration Suite, where traffic is logged and can be throttled.

Will the agent's technical user break our segregation of duties rules?

It should not, and we check. Each agent's roles are designed for one task, such as display access for vendor queries or parking rights for invoice preparation, without posting or approval rights. Your SAP security team reviews the roles against your SoD rule set before they go live, just as they would for a new employee.

Can we reuse our existing OData services and CDS views?

Often, yes. Custom OData services and CDS views in your own namespace are permitted under SAP's API policy within its limits, and many companies already have useful ones. We review what exists, check that each service is suitable for agent use, and add only what is missing. Reusing tested services shortens the build and keeps your SAP team in control.

How do you test without affecting month-end close?

All building and evaluation happens in development and quality systems, never in production. Before go-live, we load-test the agent's calls in quality, and in production we schedule heavy reads outside close periods and peak hours. During close, the agent can be switched to read-only or paused entirely by your team, and that switch is part of the runbook.

Jump to

↑↓ to move↵ to open