All tools

Finance · parse_invoice

Parse an invoice

Extract structured data from an invoice.

Price
plan AI usage
Requirements
No connector
runs on platform keys
Human approval
No
read or internal write

Input

FieldTypeDescription
invoicesarrayBatch: the FULL list of invoices to parse in one call (preferred whenever there is more than one). When provided, the top-level single fields are ignored.
rawTextstringRaw invoice text, email body, or OCR output
sourceemail | pdf | manualOrigin of the text
persistbooleanSave to the Ezyagents ledger (finance_invoices, status draft). Default: true when an invoice number and a total amount were found. Idempotent on (invoice number, counterparty).
typepayable | receivable'payable' = supplier invoice to pay (default) · 'receivable' = your own invoice to a customer
counterpartystringSupplier/customer name override when the text is ambiguous
invoiceNumberstringInvoice number override when the text is ambiguous
poNumberstringPurchase order reference if known

Call this tool

Through the HTTP API, or from the MCP server with the run meta-tool.

curl https://api.ezyagents.fr/gateway/v1/run \
  -H "Authorization: Bearer ezk_…" -H "Content-Type: application/json" \
  -d '{"tool":"parse_invoice","input":{"invoices":[],"rawText":"…","source":"email","persist":true}}'
$run({ "tool": "parse_invoice", "input": {"invoices":[],"rawText":"…","source":"email","persist":true} })