Our internal accounts payable team was the first to run Invoicing APA in production — here’s what it took to let an AI agent post invoices in a Sarbanes-Oxley environment
BY HADAS LEVI, SENIOR PRODUCT MANAGER, C3 AI
Accounts payable looks like an ideal candidate for automation: high volume, repetitive, rule-bound. It is also one of the riskiest places to put an AI agent. Every invoice we post has to be traceable and defensible years later in front of an auditor, and a model that reads the same invoice twice and reasons its way to two different answers — with no record of why — is exactly what that audit will not forgive.
So we built C3 AI Agentic Process Automation (APA) and put it to work on our own books first: our internal finance team, our real invoices, our own SOX controls. Running it on ourselves is how we find the failure modes before a customer does. Here’s what we learned.
Why Invoice Triage Fights Automation
Every month, thousands of supplier invoices arrive in a shared inbox as PDFs, scans, and multi-attachment threads. Each one has to be identified, matched to a purchase order, checked for duplicates, and posted to Coupa, our system of record, with a complete audit trail. Sarbanes-Oxley is why the process is so exacting. The law, passed in 2002 after the Enron and WorldCom collapses, requires public companies to prove that every invoice and approval is traceable and repeatable: an auditor can pull any transaction and confirm it was handled the same way as every other. Posting invoices is the deterministic heart of that regime, which is what makes a probabilistic model risky in the first place.
For years, our AP analysts did this by hand. A single invoice can mean opening a PDF, finding the matching purchase order, confirming the line items and amounts, checking that it hasn’t already been paid, and keying it in with the right coding, then doing it again, hundreds of times a week. It is exacting work, and it kept experienced people on data entry instead of the judgment calls that need them. We wanted that time back, but only if the audit team would sign off on how we got it. [AUTHOR NOTE: A value-delivered number lands hard here — e.g., analyst-hours per week on triage, or invoices per analyst. Frame as capacity gained.]
Why We Ruled Out RPA and a Bare LLM
Three obvious options were on the table before we built on APA. None of them hold up in a SOX environment, and the reasons are worth being specific about.
- Robotic process automation (RPA) would break on format variation. Every supplier formats invoices differently, and a script handles one pattern at a time. With a supplier base that changes constantly, keeping the scripts in sync would cost more than the automation ever saved.
- An LLM on its own could read an invoice but could not be trusted to post one. With no deterministic guardrails — duplicate checks, audit logging, approval thresholds — it would never clear our audit team. Strong judgment, no accountability.
- A fully custom build would have worked technically, but it would have meant standing up an engineering team inside finance to maintain it. We wanted a product we could run, without operating the infrastructure behind it.
How Invoicing APA Handles One Invoice
Invoicing APA runs on the C3 Agentic AI Platform. The design rule is simple: put an AI agent everywhere the work needs judgment, and a deterministic tool everywhere it doesn’t. An invoice moves through six phases, and the agent reasons only where reasoning is actually required.

Figure 1: The six-phase Invoicing APA pipeline. The agent reasons where judgment matters (matching and generation); deterministic tools handle the rest. Every step is logged.
Matching is the hard part, and it is where the design earns its keep. Two agents handle it, not one. A PO Matching Agent ties each line item on the invoice to the right purchase order. A separate Invoice Matching Agent compares the invoice against the supplier’s history to catch duplicates and near-duplicates: the same bill submitted twice, or a lightly edited resubmission. We split the two deliberately, because they reason over different context, open purchase orders versus prior invoices, and asking a single agent to hold both jobs made it worse at each. Everywhere judgment isn’t involved, pulling records, formatting the submission, attaching the PDF, archiving the email, a deterministic tool does the work, so there is nothing for the model to improvise.
In practice, it runs like this. An analyst forwards an invoice from a repeat supplier to the agent’s inbox with a line of context. The agent recognizes the vendor from cached state, pulls the matching purchase order and the supplier’s recent invoices, confirms the line items, and checks that the bill isn’t a duplicate. It generates the structured invoice, posts the draft through the API, attaches the source PDF, and replies, usually within a few minutes, with the vendor, the invoice number, the new invoice ID, and a link to the posted record. When something is ambiguous, it stops and routes the invoice to a person rather than guessing.

Figure 2: The agent’s reply to the analyst — vendor, invoice number, Invoice ID, a direct link to the record, and a status.
The Audit Trail Was the Point
When our internal audit team first reviewed the agent, their question was practical: could they defend its work to an external auditor, on every transaction, down to the last? The answer is the audit trail. For each invoice, the agent logs what it considered, what it ruled in, what it ruled out, and why, from how it identified the vendor to why it set a payment term to Net 30.
Because that record is complete, the audit team can review the agent’s full reasoning on every transaction instead of sampling a subset, the way they would with manual work. That is a higher standard of evidence than the process it replaced, and it is the reason sign-off was possible at all. For a function that has to defend itself under audit, the trail is what turned an interesting demo into something we could run for real.
Figure 3: The audit trail behind a single invoice. Every layer is recorded as the agent works, reviewable in full and traceable to the source PDF.
How We’re Rolling It Out
We didn’t switch everything over at once. The agent started on a narrow band of invoices with heavy human review, and it takes on more only as its track record on real transactions supports each step. Most invoices still pass a human today. The controls and the agent’s track record set how fast that scope widens.
Three Things We’d Tell the Next Team
A few lessons have held up across the rollout.
- Keep a human in the loop, permanently. Even as the agent takes on more, an analyst still owns edge cases, exceptions, and anything the controls flag. We designed for that from day one rather than bolting it on later.
- Prefer a miss to a bad post. An invoice the agent skips can be handled by hand; an invoice it posts in error is audit exposure. We tuned every threshold to prefer a miss over a bad post, and that one choice shaped the whole design, from the confidence bar for auto-posting to when a second approval kicks in.
- Trust is earned on real transactions. Our audit team signed off only after the agent had processed real invoices correctly, with the trail to prove each one. A slide deck was never going to be enough. [AUTHOR NOTE: Strongest spot for a number — how many invoices cleared correctly before sign-off, and the accuracy or exception rate.]
Where This Goes Next
Invoice triage was the first workflow, and it won’t be the last. The same shape shows up across regulated finance — journal entry review, account reconciliation, expense triage — anywhere the real test is whether the work holds up under audit. We’re finding the rough edges on our own books first, and we’re already scoping the next one.
If your finance team is sitting on the same kind of work, the same approach is available to you.
Schedule a demo
See how C3 AI Agentic Process Automation runs audit-bound finance workflows on the C3 Agentic AI Platform, with a traceable record behind every decision.
Authors
Hadas Levi is a Senior Product Manager at C3 AI focused on agentic process automation for finance and operations. [AUTHOR NOTE: Optional — expand to 2 to 3 sentences (prior experience, credentials) to match C3 AI author-bio style.]


