Create and analyze a canonical invoice
const url = 'https://api.invogi.com/v1/invoices';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"supplier":{"name":"example","tax_id":"example","bank_account":{"iban":"example","sort_code":"60-16-13","account_number":"31926819"}},"invoice_number":"example","issue_date":"2026-04-15","due_date":"2026-04-15","currency":"GBP","net_amount":"example","tax_amount":"example","gross_amount":"example","purchase_order_ref":"example","buyer":{"name":"example","tax_id":"example"},"company_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.invogi.com/v1/invoices \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "supplier": { "name": "example", "tax_id": "example", "bank_account": { "iban": "example", "sort_code": "60-16-13", "account_number": "31926819" } }, "invoice_number": "example", "issue_date": "2026-04-15", "due_date": "2026-04-15", "currency": "GBP", "net_amount": "example", "tax_amount": "example", "gross_amount": "example", "purchase_order_ref": "example", "buyer": { "name": "example", "tax_id": "example" }, "company_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0" }'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Header Parameters
Section titled “Header Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”object
object
IBAN, or a UK domestic account as sort_code plus account_number (both required together). A GB IBAN and its sort code + account number are treated as the same account.
object
Six-digit UK sort code; “-” and spaces are ignored
Example
60-16-13Six- to eight-digit UK account number
Example
31926819ISO 4217 alphabetic currency code, case-insensitive and stored upper-case. A code that is not a currency suppliers invoice in (including XXX, funds and precious-metal codes) is rejected with INVALID_REQUEST. Invoices whose currency cannot be read from an uploaded document are stored with the ISO placeholder XXX and raise a CURRENCY_UNKNOWN finding.
Example
GBPInvoice recipient (EN 16931 BG-7). tax_id routes the invoice to the company with that VAT ID when company_id is omitted.
object
One of the organization’s companies (GET /companies); defaults to the default company
Responses
Section titled “Responses”Accepted
object
object
object
object
Example
{ "status": "ANALYZING", "decision": "PASS", "findings": [ { "severity": "INFO" } ]}Invalid request
object
object
Example
{ "error": { "code": "NOT_FOUND" }}Missing or invalid API key
object
object
Example
{ "error": { "code": "NOT_FOUND" }}Conflicting idempotency key or resource processing state
object
object
Example
{ "error": { "code": "NOT_FOUND" }}