{"uid":"cap_SUjf1DfVi74ubH8yJMMDv","slug":"invoket-invoice-generator-f560c517","name":"Invoket Invoice Generator","description":"Generate a guaranteed EN 16931-conformant e-invoice: post simple business JSON (parties, lines, VAT) and get XML that has already passed the full official rule set - totals computed for you, inconsistent inputs rejected with actionable field-level errors. Default output is CII (Factur-X EN 16931 profile URN); set syntax=ubl for a UBL 2.1 invoice, and add ruleset=peppol for a guaranteed-conformant Peppol BIS Billing 3.0 document (Belgium mandate, live since 2026-04). Ready for the French 2026-2027 reform. No account, no key.","url":"https://api.invoket.com/invoice/generate","method":"POST","headers":{},"bodySchema":{"type":"object","required":["buyer","lines","seller","payment","currency","due_date","issue_date","invoice_number"],"properties":{"buyer":{"type":"object"},"lines":{"type":"array","description":"Invoice lines (BG-25), required non-empty. Line ids (BT-126) are numbered for you; each line net (BT-131) is computed as qty x unit_price with the official EN 16931 rounding. Document totals (BG-22) and the VAT breakdown (BG-23) are computed from the lines; an optional top-level `totals` object is VERIFIED against that computation and rejected with code inconsistent_totals if it diverges - never silently repaired"},"seller":{"type":"object"},"payment":{"type":"object"},"currency":{"type":"string","description":"Invoice currency (BT-5), ISO 4217, required. It must be usable for billing: XXX (no currency) and XTS (test) are a 400 implausible_currency although BR-CL accepts them - a restriction no BR rule states; metals and units of account (XAU, XAG, XPD, XPT, XDR, XUA) are accepted"},"due_date":{"type":"string"},"issue_date":{"type":"string","description":"Issue date (BT-2), required, YYYY-MM-DD AND a real calendar date - 2026-13-99 fits the pattern but is a 400 invalid_date. Optional due_date (BT-9, same check) and type_code (BT-3, default 380 commercial invoice, 381 credit note)"},"invoice_number":{"type":"string","description":"Invoice number (BT-1), required. The whole input is the simple business JSON shown here - unknown or misspelled fields are refused (400 INVALID_INVOICE_INPUT), a typo is never silently ignored. Max body 10 MB (413 beyond). Optional syntax: 'cii' (default, Factur-X CII D16B) or 'ubl' (UBL 2.1 Invoice). Optional ruleset: 'peppol' guarantees a Peppol BIS Billing 3.0 document (Belgium mandate) - it requires syntax='ubl' (else 400 ruleset_requires_ubl), a buyer_reference (BT-10), and on both seller and buyer an electronic_address {value, scheme} whose scheme is an EAS code (e.g. 0208 Belgian company number, 0009 SIRET); an unknown scheme is a 400 invalid_eas_scheme. The generated document is re-validated against the requested ruleset before being served. Under ANY ruleset, a supplied electronic_address is form-checked: a value repeating its own EAS code, or malformed for the declared scheme, is a 400 implausible_identifier"}}},"responseSchema":{"type":"object"},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.1","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.1/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.1","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.1","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_QB9AE5zBKzZKir1xqi_Jo","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.1","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Generates standards-compliant electronic invoices (Factur-X CII or UBL 2.1) with automatic EN 16931 line-total computation, VAT breakdown, and optional Peppol BIS Billing 3.0 validation","exampleAgentPrompt":"Generate a Factur-X CII invoice number INV-2025-001 dated 2025-07-15, due 2025-08-15, in EUR — seller is Acme SRL (VAT BE0123456789), buyer is Widget Corp (VAT FR12345678901) — for 10 units of 'Software License' at €120 each with 21% VAT.","exampleUseCases":[{"title":"Belgian Peppol mandate compliance","prompt":"Create a Peppol BIS Billing 3.0 UBL invoice number PEPPOL-001 issued 2025-07-01 due 2025-07-31 in EUR — seller is BrusselsSupply NV with EAS scheme 0208 and company number 0456789012, buyer is GovAgency BE with EAS scheme 0208 and number 0200001234, buyer reference BEF-2025-999 — for 5 units of 'Consulting Day' at €850 each with 21% VAT."},{"title":"French Factur-X supplier invoice","prompt":"Generate a Factur-X CII invoice INV-FR-0042 dated 2025-06-30, due 2025-07-30, in EUR — seller is Lyon Fournitures SARL (SIRET 12345678901234), buyer is Paris Retail SAS (SIRET 98765432100019) — two lines: 3 units of 'Office Chair' at €199 each at 20% VAT, and 1 unit of 'Delivery' at €25 at 20% VAT."},{"title":"Credit note in foreign currency","prompt":"Produce a UBL 2.1 credit note (type code 381) number CN-2025-007 issued 2025-07-10 in USD — seller is ExportCo Ltd, buyer is ImportCorp Inc — for a single line: -2 units of 'Returned Goods SKU-999' at $340 each with 0% VAT."}],"resultDescription":"Returns a structured electronic invoice document in the requested syntax (Factur-X CII D16B XML by default, or UBL 2.1 XML), with automatically computed EN 16931 line net amounts (quantity × unit price with official rounding), document totals, and VAT breakdown. Includes provenance metadata. If a totals object was supplied, it is verified against computed values and rejected if inconsistent rather than silently corrected.","failureModes":["400 inconsistent_totals — supplied totals object diverges from computed line totals","400 invalid_date — date string matches YYYY-MM-DD pattern but is not a real calendar date (e.g. 2026-13-99)","400 implausible_currency — currency code is XXX or XTS (no-currency/test codes)","400 ruleset_requires_ubl — peppol ruleset requested without syntax=ubl","400 invalid_eas_scheme — Peppol electronic address scheme code is not a valid EAS code","400 INVALID_INVOICE_INPUT — unknown or misspelled top-level fields in the request body","413 beyond — request body exceeds 10 MB limit","Lines array empty — lines field required to be non-empty"],"whenToPreferThis":"Choose this endpoint when you need a fully standards-compliant electronic invoice (EN 16931 / Factur-X CII or UBL 2.1) with automatic computation of line totals and VAT breakdowns, especially for European B2B billing or Peppol mandate compliance. It is stricter than generic invoice generators — it rejects inconsistent totals, invalid dates, and unknown fields rather than silently patching them, making it suitable for regulated environments where auditability and provenance matter.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T06:49:51.667Z","isFirstParty":false}