Case study · Accounts payable

Supplier invoice automation with n8n and Odoo.

Onix helped a client’s accounts payable team turn emailed supplier invoices into draft bills in Odoo. An LLM extracted the invoice lines, and n8n assigned the accounting codes before finance reviewed and posted the bill.

Before automation

Every line had to be entered and coded by hand.

The project was designed for a client’s accounts payable department, which received invoices by email and logged them in Odoo. Details of the client are available only to those who have signed an NDA.

A member of the finance team opened each PDF, manually entered the invoice details and every charge into Odoo, and selected the correct nominal code for each charge. If an invoice contained several types of charge, this had to be repeated for each line before the amounts were verified.

The workflow

From supplier email to a reviewed bill.

n8n created a draft bill in Odoo with each charge as a separate line and the relevant nominal code. Finance verified the amounts against the original invoice, checked the codes, amended them if necessary and posted the bill.

  1. 01 · Step

    Extract invoice lines

    An LLM reads the PDF and splits every charge into its own line.

  2. 02 · Step

    Code lines and create a draft

    n8n assigns a nominal code to each charge using the coding rules and creates the draft bill in Odoo.

  3. 03 · Step

    Review and post in Odoo

    Finance checks amounts and codes against the PDF, corrects what is needed and posts the bill.

Technical design

n8n workflow structure

Logical workflow stages from the technical design.

From email to Odoo draft

  1. Mail triggerReceive the supplier invoice
  2. File and stateKeep the PDF and track its source
  3. ExtractionRead invoice fields and lines
  4. ValidationCheck totals, VAT, supplier and duplicates
  5. IF / SwitchApply coding rules and flag exceptions
  6. Odoo adapterCreate the draft vendor bill

From draft to posted bill

  1. Read backRecord the bill ID and check before retrying
  2. Route and waitSend the draft to the assigned reviewer
  3. Finance reviewCheck the draft against the PDF and correct lines in Odoo
  4. PostingFinance posts the bill in Odoo
  5. Status checkConfirm the bill is posted and close the case
  6. ReconcileLink the source, bill and exception history

Worked example

A multi-line logistics invoice.

In this scenario, n8n passes an emailed PDF to an LLM, which extracts the invoice header and line items. n8n then uses the supplier and charge type to match each line to a nominal account and creates the draft bill in Odoo. If the rules do not find a single match, the line is flagged for the reviewer to code.

This example uses synthetic invoice data and sample nominal codes. The specific coding and validation rules are illustrative.

Draft bill review · demo$18.00 subtotal mismatch
Original invoice PDF
Logistics servicesSample PDF
Storage
$480.00
Fulfillment
$240.00
Returns handling
$75.00
Net subtotal
$795.00
VAT
$159.00
Gross total
$954.00
Draft bill lines in Odoo
DescriptionAI-extracted amount (USD)Proposed nominal account
Storage
Fulfillment
Returns handling
Review subtotal$777.00

Check the amounts against the PDF and the codes against your chart of accounts.

Draft in Odoo · resolve the subtotal
Interactive demo using synthetic invoice data and sample nominal codes. Edits apply to this demo only.

A validation rule checks the extracted line total against the invoice subtotal. The $18.00 discrepancy is flagged on the draft, and the reviewer checks the lines against the PDF. The reviewer finds the error in the returns handling charge and corrects it to $75.00. The totals now reconcile, the reviewer confirms the account codes and posts the bill in Odoo.

01 · Control

Flagged, not blocked

A subtotal or VAT mismatch does not stop the draft. n8n creates it anyway and flags the discrepancy on the bill, so the reviewer sees which lines to check before posting.

02 · Control

Duplicate invoice

n8n checks whether an invoice with the same supplier and invoice number has already been processed.

03 · Control

Odoo request timeout

Odoo may already have created the draft. The technical design therefore requires n8n to look up the bill before retrying and to store the Odoo ID, so it updates the existing draft instead of creating a duplicate.

What the project delivered

Finance starts with the draft ready to review.

The reviewer opens the draft bill in Odoo with its amounts and nominal codes already filled in, checks them against the PDF and corrects any discrepancies before posting. Finance no longer has to type each charge into Odoo and assign its code from scratch, and it retains control over final posting.

Project triage

Bring the messy process. We will map the path to automation.

Share the workflow, systems and data sources. We turn it into a clear next step: rescue, integration, admin panel, or a fuller automation build.

Reply within 1 business dayNDA-friendly reviewFixed scope before code

Typical first audit

free · senior-led
  • System and file-flow map with named owners
  • Automation opportunity score for each manual step
  • Delivery plan, risk list and a fixed-scope next step
Start project triage