Endpoints: 28,729MCP servers: 18,414Payout addresses: 2,071Paid calls: 1,562Letters: 14Defects: 1,336counted just now
teppi

Server definition

Hash
sha256:0482db0bd4139333def9ff9643d0487d1e098b132f2f4a84024eb54cb5aa14b9
What it is
What a remote MCP server returned when asked what it offers: 10 tools

The blob, as servednamed by its sha256

{ "instructions": "Stateless EN 16931 invoice preparation and inspection for France and the EU.\nDocuments and evidence are returned to the caller for storage and delivery in their own system.\nCorrect an input and regenerate to revise a document; use draft_credit_note for a full or selected-line credit.\nThere are no stored invoice records to list, update or delete. Factur-X is one supported output.\n\nAsk for a Factur-X PDF/A-3 (a visual invoice with CII XML inside), CII XML alone, or UBL 2.1 XML. Profiles: en16931 (default), extended, extended-ctc-fr (French B2B mandate), basicwl.\n\ngenerate_invoice does not emit a file when EU Verify says the seller or buyer is not invoice-ready. The error names the field to fix. A ready file comes back with a dated evidence id. A register outage does not block the file. This server does not send the invoice and is not a Peppol access point.\n\n- generate_invoice: invoice data in, a compliant document out. Totals and VAT are computed.\n- embed_xml: your own PDF plus CII XML becomes a Factur-X PDF/A-3.\n- validate_invoice: XSD plus the EN 16931 schematron, and the French fr-ctc rules when asked. Findings carry rule ids and a json_pointer when the field can be named, so you can patch and retry.\n- extract_invoice: parties, totals, VAT and lines as JSON.\n- get_invoice_example: a complete invoice body to copy. Replace the sample parties before generate_invoice. No key, and it does not count as a document.\n- draft_credit_note: the credit-note body for an invoice you already have. Amounts stay positive. No key, and it does not count as a document. Call generate_invoice to emit the file.\n- check_party: ask EU Verify if one seller or buyer is invoice-ready before you generate. Does not count as a document.\n- check_invoice_parties: check both seller and buyer together before generating; preserves each result and evidence.\n- explain_finding: turn a rule id into the field to fix and an example. No key required, and it does not count as a document.\n\nStart with view_invoice_demo(sample=\"valid\" or \"invalid\") to validate a fixed synthetic CII invoice with the current engine (versioned cache, no signup or card). Call with {} to validate the passing sample; choose sample=\"downloads\" for PDF/CII/UBL files and a published report. Then get_invoice_example shows the input format. For your own documents, choose the EUR 3 evaluation pack (25 operations, 30 days, no subscription) or a monthly plan at /docs/pricing/ and send Authorization: Bearer <key>. Existing trial keys remain valid until their original expiry; new trial keys are no longer issued.\n\nAmounts are decimal strings (e.g. \"1200.00\"), dates are ISO 8601 (YYYY-MM-DD). French sellers should provide siren, vat_id and a full address. Call validate_invoice on anything you did not generate here.", "tools": [ { "description": "Check a supplied seller AND buyer together, returning combined readiness and separate evidence.\n\n Use before generate_invoice; use check_party for one party and validate_invoice for document rules.\n Each party needs siren, siret or vat; siret wins over siren. French identifiers or country_code=FR\n require SIREN/SIRET; a French lookup can derive omitted vat. Address fields activate address checks.\n requester_vat applies to both lookups but cannot replace either party's vat. Roles follow seller/buyer\n argument names; no invoice lines or full invoice body is needed.\n\n Makes at most two EU Verify requests with the caller's plan key; Pro/Scale enable register access.\n Returns status and parties.seller/buyer, each with status, reasons and available evidence. Only two\n positive results yield invoice_ready; any not_ready yields not_ready, otherwise inconclusive.\n Inspect both results: denied plans, invalid input, quotas and outages never establish readiness.\n No document quota is consumed; upstream limits still apply per lookup. Results may change on retry.\n No invoice is generated, stored or sent.\n ", "inputSchema": { "$defs": { "PartyCheckInput": { "additionalProperties": false, "properties": { "address": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "Street address to verify.", "title": "Address" }, "city": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "City for address verification.", "title": "City" }, "country_code": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "ISO 3166-1 alpha-2 country code, e.g. FR or DE.", "title": "Country Code" }, "eori": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional EORI to verify.", "title": "Eori" }, "iban": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional party IBAN to verify.", "title": "Iban" }, "postal_code": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "Postal code for address verification.", "title": "Postal Code" }, "siren": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "9-digit French SIREN, including leading zeros.", "title": "Siren" }, "siret": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "14-digit French SIRET, including leading zeros.", "title": "Siret" }, "vat": { "anyOf": [ { "maxLength": 256, "minLength": 1, "type": "string" }, { "type": "null" } ], "default": null, "description": "Party's EU VAT number, including country prefix.", "title": "Vat" } }, "title": "PartyCheckInput", "type": "object" } }, "properties": { "buyer": { "$ref": "#/$defs/PartyCheckInput", "description": "Buyer's registry identifiers and optional checks.", "type": "object" }, "requester_vat": { "anyOf": [ { "maxLength": 256, "type": "string" }, { "type": "null" } ], "default": null, "description": "Your VAT number for VIES request evidence.", "title": "Requester Vat" }, "seller": { "$ref": "#/$defs/PartyCheckInput", "description": "Seller's registry identifiers and optional checks.", "type": "object" } }, "required": [ "seller", "buyer" ], "title": "check_invoice_partiesArguments", "type": "object" }, "name": "check_invoice_parties", "outputSchema": { "additionalProperties": true, "title": "check_invoice_partiesDictOutput", "type": "object" } }, { "description": "Check exactly one seller or buyer's registry identifiers and readiness through EU Verify.\n\n Use to correct one party's identifiers; use check_invoice_parties to check seller and buyer together,\n or validate_invoice for document rules.\n Supply siren, siret or vat; siret wins over siren. A SIREN/SIRET, country_code=FR or FR VAT triggers\n French checks requiring a SIREN/SIRET. Omitted vat can be derived from a successful French lookup;\n foreign parties normally need explicit VAT. Send address fields with a coherent country_code;\n requester_vat cannot substitute for the checked party's vat.\n\n Sends supplied fields to EU Verify and applicable registers. A Pro/Scale key enables checks;\n other plans return plan_excluded. No Factur-X document quota is consumed.\n Returns status, reasons with field pointers and available evidence: invoice_ready is positive,\n not_ready needs correction, upstream_unavailable is inconclusive and retryable, invalid_input\n indicates rejected input. Register results and evidence ids may change between calls.\n No invoice is created or stored.\n ", "inputSchema": { "properties": { "address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Street line; any address, postal_code or city activates address checking.", "title": "Address" }, "city": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "City, checked with the address.", "title": "City" }, "country_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "ISO 3166-1 alpha-2 country code, for example FR or DE.", "title": "Country Code" }, "eori": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "EORI. Checked only when you send it.", "title": "Eori" }, "iban": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Party IBAN. Checked only when you send it.", "title": "Iban" }, "postal_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Postal code, checked with the address.", "title": "Postal Code" }, "requester_vat": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Your VAT number, so the evidence pack can include a VIES request identifier.", "title": "Requester Vat" }, "role": { "default": "buyer", "description": "Party role recorded in the evidence; defaults to buyer.", "enum": [ "seller", "buyer" ], "title": "Role", "type": "string" }, "siren": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "9-digit French SIREN, including leading zeros.", "title": "Siren" }, "siret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "14-digit French SIRET, including leading zeros.", "title": "Siret" }, "vat": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Party's EU VAT number, for example FR40732829320.", "title": "Vat" } }, "title": "check_partyArguments", "type": "object" }, "name": "check_party", "outputSchema": { "additionalProperties": true, "title": "check_partyDictOutput", "type": "object" } }, { "description": "Draft a type-381 credit note from an existing invoice, for all lines or selected quantities.\n\n Use to reverse an existing invoice's charges; use get_invoice_example for a synthetic credit-note example.\n invoice must be the original generate_invoice input object, not extract_invoice output.\n number and issue_date belong to the new credit note; the original number/date are copied into\n preceding_invoices. Give number a distinct value and use YYYY-MM-DD dates. due_date replaces the\n original deadline; omitting it removes that deadline rather than inheriting it.\n\n Omit credit_lines to retain all original lines and amounts. Otherwise select distinct 1-based array\n positions, not line ids: [{\"line_index\":1,\"quantity\":\"2\"}] credits two units of the first line.\n Omitted lines are excluded; quantities cannot exceed the original. Prices and VAT rates are retained.\n Selected-line mode clears original totals, prepayments, rounding and paid status for recalculation.\n Document allowances/charges, or reduced quantities on adjusted lines or overridden net amounts,\n need explicit allocation: these cases return an error; prepare a credit body for generate_invoice.\n No prior-credit history is stored: the caller must prevent cumulative credits beyond the original.\n Keep amounts positive: type 381 expresses the credit. Existing credit notes, a reused invoice number\n or negative line amounts produce a tool error. Default payment remittance references follow the\n new number; a custom reference is preserved. Returns invoice, type_code, preceding_invoice and next.\n Pass the returned invoice to generate_invoice with the original profile to create the document.\n No key or document quota is needed for drafting; nothing is stored, sent or refunded.\n ", "inputSchema": { "$defs": { "AdditionalDocument": { "additionalProperties": false, "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-123", "title": "Description" }, "id": { "description": "BT-122", "title": "Id", "type": "string" }, "url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-124", "title": "Url" } }, "required": [ "id" ], "title": "AdditionalDocument", "type": "object" }, "Address": { "additionalProperties": false, "properties": { "city": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-37 / BT-52", "title": "City" }, "country": { "description": "ISO 3166-1 alpha-2, BT-40 / BT-55", "maxLength": 2, "minLength": 2, "title": "Country", "type": "string" }, "country_subdivision": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-39 / BT-54", "title": "Country Subdivision" }, "line1": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-35 / BT-50", "title": "Line1" }, "line2": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-36 / BT-51", "title": "Line2" }, "line3": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-162 / BT-163", "title": "Line3" }, "postal_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-38 / BT-53", "title": "Postal Code" } }, "required": [ "country" ], "title": "Address", "type": "object" }, "AllowanceCharge": { "additionalProperties": false, "description": "Document-level allowance (BG-20) or charge (BG-21).", "properties": { "amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-92 / BT-99, tax excluded", "title": "Amount" }, "base_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-93 / BT-100", "title": "Base Amount" }, "percentage": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-94 / BT-101", "title": "Percentage" }, "reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-97 / BT-104", "title": "Reason" }, "reason_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UNTDID 5189 / 7161, BT-98 / BT-105", "title": "Reason Code" }, "vat_category": { "$ref": "#/$defs/VatCategory", "default": "S", "description": "BT-95 / BT-102" }, "vat_rate": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-96 / BT-103", "title": "Vat Rate" } }, "required": [ "amount" ], "title": "AllowanceCharge", "type": "object" }, "Contact": { "additionalProperties": false, "properties": { "department": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-41-0 / BT-56-0 (used when name is empty)", "title": "Department" }, "email": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-43 / BT-58", "title": "Email" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-41 / BT-56", "title": "Name" }, "phone": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-42 / BT-57", "title": "Phone" } }, "title": "Contact", "type": "object" }, "CreditLine": { "additionalProperties": false, "properties": { "line_index": { "description": "1-based position in the original invoice.lines array, not its id.", "minimum": 1, "title": "Line Index", "type": "integer" }, "quantity": { "anyOf": [ { "exclusiveMinimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,13}|(?=[\\d.]{1,20}0*$)\\d{0,13}\\.\\d{0,6}0*$)", "type": "string" } ], "description": "Positive quantity to credit, at most the original line quantity; decimal string.", "title": "Quantity" } }, "required": [ "line_index", "quantity" ], "title": "CreditLine", "type": "object" }, "Delivery": { "additionalProperties": false, "properties": { "actual_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-72", "title": "Actual Date" }, "address": { "anyOf": [ { "$ref": "#/$defs/Address" }, { "type": "null" } ], "default": null }, "location_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-71", "title": "Location Id" }, "location_id_scheme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-71-1", "title": "Location Id Scheme" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Deliver-to party name, BT-70", "title": "Name" }, "period_end": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-74", "title": "Period End" }, "period_start": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-73", "title": "Period Start" } }, "title": "Delivery", "type": "object" }, "FrenchMentions": { "additionalProperties": false, "description": "Legal mentions required on French B2B invoices (BR-FR-05). Added as BG-1 notes with codes PMD, PMT, AAB.", "properties": { "early_payment_discount": { "default": "Pas d'escompte pour paiement anticipé.", "description": "Note code AAB", "title": "Early Payment Discount", "type": "string" }, "enabled": { "default": true, "description": "Add the three mandatory French mentions when missing", "title": "Enabled", "type": "boolean" }, "late_payment_penalties": { "default": "Tout retard de paiement entraîne une pénalité exigible à compter de la date d'échéance, calculée sur la base de trois fois le taux d'intérêt légal.", "description": "Note code PMD", "title": "Late Payment Penalties", "type": "string" }, "recovery_fee": { "default": "Indemnité forfaitaire pour frais de recouvrement en cas de retard de paiement : 40 €.", "description": "Note code PMT", "title": "Recovery Fee", "type": "string" } }, "title": "FrenchMentions", "type": "object" }, "Invoice": { "additionalProperties": false, "properties": { "additional_documents": { "description": "BG-24", "items": { "$ref": "#/$defs/AdditionalDocument" }, "title": "Additional Documents", "type": "array" }, "allowances": { "description": "BG-20", "items": { "$ref": "#/$defs/AllowanceCharge" }, "title": "Allowances", "type": "array" }, "already_paid": { "default": false, "description": "Invoice already paid at issuance (French BT-23 variants B2/S2/M2)", "title": "Already Paid", "type": "boolean" }, "business_process": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Explicit BT-23 business process code (e.g. S1). Overrides operation_type/already_paid.", "title": "Business Process" }, "buyer": { "$ref": "#/$defs/Party", "description": "BG-7" }, "buyer_accounting_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-19", "title": "Buyer Accounting Reference" }, "buyer_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-10", "title": "Buyer Reference" }, "charges": { "description": "BG-21", "items": { "$ref": "#/$defs/AllowanceCharge" }, "title": "Charges", "type": "array" }, "contract_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-12", "title": "Contract Reference" }, "currency": { "default": "EUR", "description": "BT-5", "maxLength": 3, "minLength": 3, "title": "Currency", "type": "string" }, "delivery": { "anyOf": [ { "$ref": "#/$defs/Delivery" }, { "type": "null" } ], "default": null, "description": "BG-13" }, "despatch_advice_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-16", "title": "Despatch Advice Reference" }, "due_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-9", "title": "Due Date" }, "french_mentions": { "$ref": "#/$defs/FrenchMentions", "description": "Mandatory French legal mentions (BR-FR-05)" }, "issue_date": { "description": "BT-2", "format": "date", "title": "Issue Date", "type": "string" }, "lines": { "description": "BG-25", "items": { "$ref": "#/$defs/Line" }, "minItems": 1, "title": "Lines", "type": "array" }, "notes": { "description": "BG-1", "items": { "$ref": "#/$defs/Note" }, "title": "Notes", "type": "array" }, "number": { "description": "BT-1 (BR-FR-01/02: max 35 chars, letters, digits, . _ / -)", "maxLength": 35, "pattern": "^[A-Za-z0-9._/\\-]+$", "title": "Number", "type": "string" }, "operation_type": { "default": "services", "description": "Nature of the operation, used to derive the French business process code BT-23 (B1/S1/M1)", "enum": [ "goods", "services", "mixed" ], "title": "Operation Type", "type": "string" }, "payment": { "anyOf": [ { "$ref": "#/$defs/Payment" }, { "type": "null" } ], "default": null, "description": "BG-16" }, "payment_terms": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-20", "title": "Payment Terms" }, "preceding_invoices": { "description": "BG-3", "items": { "$ref": "#/$defs/PrecedingInvoice" }, "title": "Preceding Invoices", "type": "array" }, "prepaid_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-113 shortcut when totals are computed", "title": "Prepaid Amount" }, "project_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-11", "title": "Project Reference" }, "purchase_order_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-13", "title": "Purchase Order Reference" }, "receiving_advice_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-15", "title": "Receiving Advice Reference" }, "rounding_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-114 shortcut when totals are computed", "title": "Rounding Amount" }, "sales_order_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-14", "title": "Sales Order Reference" }, "seller": { "$ref": "#/$defs/Party", "description": "BG-4" }, "tax_exemption_reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Default BT-120 text for E/AE/K/G/O categories, e.g. 'TVA non applicable, art. 293 B du CGI'", "title": "Tax Exemption Reason" }, "tax_exemption_reason_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Default BT-121 VATEX code", "title": "Tax Exemption Reason Code" }, "tax_point_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-7", "title": "Tax Point Date" }, "tender_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-17", "title": "Tender Reference" }, "totals": { "anyOf": [ { "$ref": "#/$defs/Totals" }, { "type": "null" } ], "default": null, "description": "BG-22, computed when omitted" }, "type_code": { "default": "380", "description": "UNTDID 1001, BT-3: 380 invoice, 381 credit note, 384 corrected, 386 prepayment, 389 self-billed", "enum": [ "380", "381", "384", "386", "389", "261", "751" ], "title": "Type Code", "type": "string" }, "vat_accounting_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-6", "title": "Vat Accounting Currency" } }, "required": [ "number", "issue_date", "seller", "buyer", "lines" ], "title": "Invoice", "type": "object" }, "Line": { "additionalProperties": false, "properties": { "allowances": { "description": "BG-27", "items": { "$ref": "#/$defs/LineAllowanceCharge" }, "title": "Allowances", "type": "array" }, "attributes": { "additionalProperties": { "type": "string" }, "description": "BG-32 item attributes", "title": "Attributes", "type": "object" }, "buyer_accounting_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-133", "title": "Buyer Accounting Reference" }, "buyer_item_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-156", "title": "Buyer Item Id" }, "charges": { "description": "BG-28", "items": { "$ref": "#/$defs/LineAllowanceCharge" }, "title": "Charges", "type": "array" }, "gross_unit_price": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-148", "title": "Gross Unit Price" }, "id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-126, auto-numbered when omitted", "title": "Id" }, "item_description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-154", "title": "Item Description" }, "item_name": { "description": "BT-153", "title": "Item Name", "type": "string" }, "net_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-131. Computed as quantity x unit_price / base_qty - allowances + charges when omitted", "title": "Net Amount" }, "note": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-127", "title": "Note" }, "order_line_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-132", "title": "Order Line Reference" }, "origin_country": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-159", "title": "Origin Country" }, "period_end": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-135", "title": "Period End" }, "period_start": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-134", "title": "Period Start" }, "price_base_quantity": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,13}|(?=[\\d.]{1,20}0*$)\\d{0,13}\\.\\d{0,6}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-149", "title": "Price Base Quantity" }, "price_base_unit_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-150", "title": "Price Base Unit Code" }, "price_discount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-147", "title": "Price Discount" }, "quantity": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,13}|(?=[\\d.]{1,20}0*$)\\d{0,13}\\.\\d{0,6}0*$)", "type": "string" } ], "description": "BT-129", "title": "Quantity" }, "seller_item_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-155", "title": "Seller Item Id" }, "standard_item_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-157, e.g. EAN/GTIN", "title": "Standard Item Id" }, "standard_item_id_scheme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-157-1, e.g. 0160 = GTIN", "title": "Standard Item Id Scheme" }, "unit_code": { "default": "C62", "description": "UN/ECE Rec 20, BT-130 (C62 unit, HUR hour, DAY, KGM, MTR, LTR...)", "title": "Unit Code", "type": "string" }, "unit_price": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "Net unit price, BT-146", "title": "Unit Price" }, "vat_category": { "$ref": "#/$defs/VatCategory", "default": "S", "description": "BT-151" }, "vat_rate": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-152, required for category S", "title": "Vat Rate" } }, "required": [ "item_name", "quantity", "unit_price" ], "title": "Line", "type": "object" }, "LineAllowanceCharge": { "additionalProperties": false, "properties": { "amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-136 / BT-141", "title": "Amount" }, "base_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-137 / BT-142", "title": "Base Amount" }, "percentage": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-138 / BT-143", "title": "Percentage" }, "reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-139 / BT-144", "title": "Reason" }, "reason_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-140 / BT-145", "title": "Reason Code" } }, "required": [ "amount" ], "title": "LineAllowanceCharge", "type": "object" }, "Note": { "additionalProperties": false, "properties": { "subject_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UNTDID 4451 code, BT-21 (e.g. AAI general, PMT payment, PMD penalties)", "title": "Subject Code" }, "text": { "description": "BT-22", "title": "Text", "type": "string" } }, "required": [ "text" ], "title": "Note", "type": "object" }, "Party": { "additionalProperties": false, "properties": { "address": { "$ref": "#/$defs/Address" }, "contact": { "anyOf": [ { "$ref": "#/$defs/Contact" }, { "type": "null" } ], "default": null }, "electronic_address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-34 / BT-49", "title": "Electronic Address" }, "electronic_address_scheme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "EAS code for electronic_address (BT-34-1 / BT-49-1), e.g. 0225 = SIRET (FR)", "title": "Electronic Address Scheme" }, "global_ids": { "additionalProperties": { "type": "string" }, "description": "BT-29 / BT-46: {schemeID: identifier}, e.g. {'0009': SIRET}", "title": "Global Ids", "type": "object" }, "legal_info": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Seller only, BT-33: legal form, share capital, RCS city...", "title": "Legal Info" }, "legal_registration_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-30 / BT-47 when not a SIREN. Ignored if siren is set.", "title": "Legal Registration Id" }, "legal_registration_scheme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "ISO 6523 ICD for legal_registration_id (BT-30-1 / BT-47-1), e.g. 0002 = SIREN", "title": "Legal Registration Scheme" }, "name": { "description": "Legal name, BT-27 / BT-44", "title": "Name", "type": "string" }, "siren": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "French SIREN (9 digits). Written as legal registration id BT-30 / BT-47 with scheme 0002.", "title": "Siren" }, "siret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "French SIRET (14 digits). Shortcut for electronic_address with scheme 0225.", "title": "Siret" }, "tax_registration_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Seller only, BT-32", "title": "Tax Registration Id" }, "trading_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-28 / BT-45", "title": "Trading Name" }, "vat_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-31 / BT-48, e.g. FR12345678901", "title": "Vat Id" } }, "required": [ "name", "address" ], "title": "Party", "type": "object" }, "Payment": { "additionalProperties": false, "properties": { "account_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-85", "title": "Account Name" }, "bic": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-86", "title": "Bic" }, "creditor_reference_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Direct debit, BT-90", "title": "Creditor Reference Id" }, "debited_iban": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Direct debit, BT-91", "title": "Debited Iban" }, "iban": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Payee account, BT-84", "title": "Iban" }, "mandate_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Direct debit, BT-89", "title": "Mandate Reference" }, "means_code": { "default": "30", "description": "UNTDID 4461, BT-81. 30 credit transfer, 58 SEPA transfer, 59 SEPA direct debit, 48 card", "title": "Means Code", "type": "string" }, "means_text": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-82", "title": "Means Text" }, "remittance_information": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-83", "title": "Remittance Information" }, "terms": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-20", "title": "Terms" } }, "title": "Payment", "type": "object" }, "PrecedingInvoice": { "additionalProperties": false, "properties": { "issue_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-26", "title": "Issue Date" }, "number": { "description": "BT-25", "title": "Number", "type": "string" } }, "required": [ "number" ], "title": "PrecedingInvoice", "type": "object" }, "Totals": { "additionalProperties": false, "description": "Document totals (BG-22). All computed by the engine when omitted.", "properties": { "allowance_total": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-107", "title": "Allowance Total" }, "amount_due": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-115", "title": "Amount Due" }, "charge_total": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-108", "title": "Charge Total" }, "line_total": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-106", "title": "Line Total" }, "prepaid": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-113", "title": "Prepaid" }, "rounding": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-114", "title": "Rounding" }, "tax_exclusive": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-109", "title": "Tax Exclusive" }, "tax_inclusive": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-112", "title": "Tax Inclusive" }, "tax_total": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-110", "title": "Tax Total" }, "vat_breakdown": { "description": "BG-23", "items": { "$ref": "#/$defs/VatBreakdown" }, "title": "Vat Breakdown", "type": "array" } }, "required": [ "line_total", "tax_exclusive", "tax_total", "tax_inclusive", "amount_due" ], "title": "Totals", "type": "object" }, "VatBreakdown": { "additionalProperties": false, "properties": { "category": { "$ref": "#/$defs/VatCategory", "description": "BT-118" }, "exemption_reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-120", "title": "Exemption Reason" }, "exemption_reason_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "VATEX code, BT-121", "title": "Exemption Reason Code" }, "rate": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-119", "title": "Rate" }, "tax_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-117", "title": "Tax Amount" }, "taxable_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-116", "title": "Taxable Amount" } }, "required": [ "category", "taxable_amount", "tax_amount" ], "title": "VatBreakdown", "type": "object" }, "VatCategory": { "description": "UNTDID 5305 subset used by EN 16931 (BT-151 / BT-118).", "enum": [ "S", "Z", "E", "AE", "K", "G", "O", "L", "M" ], "title": "VatCategory", "type": "string" } }, "properties": { "credit_lines": { "anyOf": [ { "items": { "$ref": "#/$defs/CreditLine" }, "minItems": 1, "type": "array" }, { "type": "null" } ], "default": null, "description": "Selected original line positions and quantities. Omit for a full credit; an empty list is invalid.", "title": "Credit Lines" }, "due_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional due date. Omit it to drop the original invoice due date.", "title": "Due Date" }, "invoice": { "$ref": "#/$defs/Invoice", "description": "The original invoice object you passed to generate_invoice. Not an extract_invoice result.", "type": "object" }, "issue_date": { "description": "Credit note issue date, ISO 8601 (YYYY-MM-DD).", "format": "date", "title": "Issue Date", "type": "string" }, "number": { "description": "Credit note number, different from the invoice number. Max 35 characters: letters, digits, and . _ / -.", "title": "Number", "type": "string" } }, "required": [ "invoice", "number", "issue_date" ], "title": "draft_credit_noteArguments", "type": "object" }, "name": "draft_credit_note", "outputSchema": { "additionalProperties": true, "title": "draft_credit_noteDictOutput", "type": "object" } }, { "description": "Combine a visual PDF you already have with CII XML into one Factur-X PDF/A-3.\n\n Use for an existing visual invoice; use generate_invoice to render invoice data or produce UBL.\n Match the PDF's parties, lines and totals to xml yourself: check examines only XML and cannot detect\n disagreement with the visible PDF. The embedded profile comes from xml; neither check nor language\n changes it. language does not translate the PDF.\n\n Invalid input or failed rules return a tool error with no file; rule errors include ids. For a\n findings report use validate_invoice. Success returns a JSON summary (profile, size_bytes, warning\n count) and a base64 PDF/A-3 resource. Requires a plan key; success consumes one document, errors\n consume none. Nothing is stored or sent.\n ", "inputSchema": { "$defs": { "Language": { "enum": [ "fr", "en" ], "title": "Language", "type": "string" } }, "properties": { "check": { "default": "fr-ctc", "description": "XML validation rules: fr-ctc adds French BR-FR-* to EN 16931; base uses EN 16931 only.", "enum": [ "base", "fr-ctc" ], "title": "Check", "type": "string" }, "language": { "$ref": "#/$defs/Language", "default": "fr", "description": "Language written in the PDF metadata: fr (default) or en.", "type": "string" }, "pdf_base64": { "description": "Standard base64 of PDF bytes starting with %PDF-. Not a URL or data-URI.", "title": "Pdf Base64", "type": "string" }, "xml": { "description": "Unencoded CII XML text (Factur-X / EN 16931); UBL is not supported.", "title": "Xml", "type": "string" } }, "required": [ "pdf_base64", "xml" ], "title": "embed_xmlArguments", "type": "object" }, "name": "embed_xml", "outputSchema": null }, { "description": "Turn a validation rule id into the invoice field to change and an example value.\n\n Use after validate_invoice or a generate_invoice rule error, not to validate an invoice itself.\n rule is trimmed and uppercased to select a guide entry. message/json_pointer must come from that\n same finding: nonempty values override its generic context, but never change the selected fix or\n example. Omit them to use guide defaults for known rules.\n\n Returns rule, known, message, json_pointer, fix and example; known rules also include problem.\n Selected BR-FR rules and BR-CO-17/BR-CO-26 have guidance.\n Unknown ids return known=false and example=null with the supplied context, not an error; consult\n the original finding. No key or document quota is needed; nothing is stored.\n ", "inputSchema": { "properties": { "json_pointer": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Original finding's json_pointer field path.", "title": "Json Pointer" }, "message": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Original finding's message text.", "title": "Message" }, "rule": { "description": "Validation rule identifier, for example BR-FR-01 or BR-CO-26.", "title": "Rule", "type": "string" } }, "required": [ "rule" ], "title": "explain_findingArguments", "type": "object" }, "name": "explain_finding", "outputSchema": { "additionalProperties": true, "title": "explain_findingDictOutput", "type": "object" } }, { "description": "Extract invoice parties, dates, lines, totals and VAT as JSON for bookkeeping or matching.\n\n Use validate_invoice for compliance; this performs no OCR or recalculation. Supply one source:\n nonblank xml overrides document_base64 without inspecting it, so omit xml to extract a PDF's\n attachment. include_xml returns that selected source for archiving or validation, not XML\n reconstructed from fields. Extracted fields need mapping before use as generate_invoice input.\n\n Returns fields and format/profile metadata, plus PDF metadata for PDF input. Missing business values\n remain null; numeric values are strings. Missing input, invalid base64, malformed/unrecognized XML\n or a PDF without embedded XML returns a tool error, not an empty extraction.\n Requires a plan key; success consumes one document, errors consume none. Nothing is stored or sent.\n ", "inputSchema": { "properties": { "document_base64": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Standard base64 of a Factur-X PDF, CII XML or UBL XML file; no data-URI prefix.", "title": "Document Base64" }, "include_xml": { "default": false, "description": "Include source XML text in the result; this can substantially increase response size.", "title": "Include Xml", "type": "boolean" }, "xml": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "CII or UBL XML as unencoded text.", "title": "Xml" } }, "title": "extract_invoiceArguments", "type": "object" }, "name": "extract_invoice", "outputSchema": { "additionalProperties": true, "title": "extract_invoiceDictOutput", "type": "object" } }, { "description": "Create an EN 16931 e-invoice from structured data: Factur-X PDF/A-3, CII XML, or UBL 2.1 XML.\n\n Use when you have the parties, lines and dates and need the document. To revise one, correct the input\n and regenerate; save and deliver the returned file through your own system. Do not use when you already have a\n visual PDF and CII XML: call embed_xml. To check a document you did not create here, call validate_invoice;\n to read one, call extract_invoice.\n\n Start invoice from get_invoice_example, replacing sample parties and dates. Leave totals and line\n net_amount omitted to compute them from quantities, prices, allowances and charges. For ubl-xml,\n profile must be en16931 or extended-ctc-fr; extended and basicwl are CII/PDF-only. profile selects\n the XML model while check selects validation rules: use check=base for non-French invoices;\n changing check does not disable party_check. language and footer_text affect only the visual PDF.\n\n Omitted party_check enables registry checks only for extended-ctc-fr; true/false explicitly\n overrides that default. Enabled checks send party identifiers/address and seller IBAN to EU Verify.\n A not_ready verdict blocks output with field pointers. Successful checks add evidence ids;\n registry outages do not block generation and are reported as warnings, not proof of readiness.\n XSD/business-rule failures return a tool error with rule ids; fix the input and retry.\n\n Requires a plan key; each successful result uses one document, including repeated calls.\n Returns a JSON text summary (totals, warnings, evidence) and an embedded resource: base64 PDF\n or XML text. No invoice is stored or sent to a recipient.\n ", "inputSchema": { "$defs": { "AdditionalDocument": { "additionalProperties": false, "properties": { "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-123", "title": "Description" }, "id": { "description": "BT-122", "title": "Id", "type": "string" }, "url": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-124", "title": "Url" } }, "required": [ "id" ], "title": "AdditionalDocument", "type": "object" }, "Address": { "additionalProperties": false, "properties": { "city": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-37 / BT-52", "title": "City" }, "country": { "description": "ISO 3166-1 alpha-2, BT-40 / BT-55", "maxLength": 2, "minLength": 2, "title": "Country", "type": "string" }, "country_subdivision": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-39 / BT-54", "title": "Country Subdivision" }, "line1": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-35 / BT-50", "title": "Line1" }, "line2": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-36 / BT-51", "title": "Line2" }, "line3": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-162 / BT-163", "title": "Line3" }, "postal_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-38 / BT-53", "title": "Postal Code" } }, "required": [ "country" ], "title": "Address", "type": "object" }, "AllowanceCharge": { "additionalProperties": false, "description": "Document-level allowance (BG-20) or charge (BG-21).", "properties": { "amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-92 / BT-99, tax excluded", "title": "Amount" }, "base_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-93 / BT-100", "title": "Base Amount" }, "percentage": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-94 / BT-101", "title": "Percentage" }, "reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-97 / BT-104", "title": "Reason" }, "reason_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UNTDID 5189 / 7161, BT-98 / BT-105", "title": "Reason Code" }, "vat_category": { "$ref": "#/$defs/VatCategory", "default": "S", "description": "BT-95 / BT-102" }, "vat_rate": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-96 / BT-103", "title": "Vat Rate" } }, "required": [ "amount" ], "title": "AllowanceCharge", "type": "object" }, "Contact": { "additionalProperties": false, "properties": { "department": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-41-0 / BT-56-0 (used when name is empty)", "title": "Department" }, "email": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-43 / BT-58", "title": "Email" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-41 / BT-56", "title": "Name" }, "phone": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-42 / BT-57", "title": "Phone" } }, "title": "Contact", "type": "object" }, "Delivery": { "additionalProperties": false, "properties": { "actual_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-72", "title": "Actual Date" }, "address": { "anyOf": [ { "$ref": "#/$defs/Address" }, { "type": "null" } ], "default": null }, "location_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-71", "title": "Location Id" }, "location_id_scheme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-71-1", "title": "Location Id Scheme" }, "name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Deliver-to party name, BT-70", "title": "Name" }, "period_end": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-74", "title": "Period End" }, "period_start": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-73", "title": "Period Start" } }, "title": "Delivery", "type": "object" }, "FrenchMentions": { "additionalProperties": false, "description": "Legal mentions required on French B2B invoices (BR-FR-05). Added as BG-1 notes with codes PMD, PMT, AAB.", "properties": { "early_payment_discount": { "default": "Pas d'escompte pour paiement anticipé.", "description": "Note code AAB", "title": "Early Payment Discount", "type": "string" }, "enabled": { "default": true, "description": "Add the three mandatory French mentions when missing", "title": "Enabled", "type": "boolean" }, "late_payment_penalties": { "default": "Tout retard de paiement entraîne une pénalité exigible à compter de la date d'échéance, calculée sur la base de trois fois le taux d'intérêt légal.", "description": "Note code PMD", "title": "Late Payment Penalties", "type": "string" }, "recovery_fee": { "default": "Indemnité forfaitaire pour frais de recouvrement en cas de retard de paiement : 40 €.", "description": "Note code PMT", "title": "Recovery Fee", "type": "string" } }, "title": "FrenchMentions", "type": "object" }, "Invoice": { "additionalProperties": false, "properties": { "additional_documents": { "description": "BG-24", "items": { "$ref": "#/$defs/AdditionalDocument" }, "title": "Additional Documents", "type": "array" }, "allowances": { "description": "BG-20", "items": { "$ref": "#/$defs/AllowanceCharge" }, "title": "Allowances", "type": "array" }, "already_paid": { "default": false, "description": "Invoice already paid at issuance (French BT-23 variants B2/S2/M2)", "title": "Already Paid", "type": "boolean" }, "business_process": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Explicit BT-23 business process code (e.g. S1). Overrides operation_type/already_paid.", "title": "Business Process" }, "buyer": { "$ref": "#/$defs/Party", "description": "BG-7" }, "buyer_accounting_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-19", "title": "Buyer Accounting Reference" }, "buyer_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-10", "title": "Buyer Reference" }, "charges": { "description": "BG-21", "items": { "$ref": "#/$defs/AllowanceCharge" }, "title": "Charges", "type": "array" }, "contract_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-12", "title": "Contract Reference" }, "currency": { "default": "EUR", "description": "BT-5", "maxLength": 3, "minLength": 3, "title": "Currency", "type": "string" }, "delivery": { "anyOf": [ { "$ref": "#/$defs/Delivery" }, { "type": "null" } ], "default": null, "description": "BG-13" }, "despatch_advice_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-16", "title": "Despatch Advice Reference" }, "due_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-9", "title": "Due Date" }, "french_mentions": { "$ref": "#/$defs/FrenchMentions", "description": "Mandatory French legal mentions (BR-FR-05)" }, "issue_date": { "description": "BT-2", "format": "date", "title": "Issue Date", "type": "string" }, "lines": { "description": "BG-25", "items": { "$ref": "#/$defs/Line" }, "minItems": 1, "title": "Lines", "type": "array" }, "notes": { "description": "BG-1", "items": { "$ref": "#/$defs/Note" }, "title": "Notes", "type": "array" }, "number": { "description": "BT-1 (BR-FR-01/02: max 35 chars, letters, digits, . _ / -)", "maxLength": 35, "pattern": "^[A-Za-z0-9._/\\-]+$", "title": "Number", "type": "string" }, "operation_type": { "default": "services", "description": "Nature of the operation, used to derive the French business process code BT-23 (B1/S1/M1)", "enum": [ "goods", "services", "mixed" ], "title": "Operation Type", "type": "string" }, "payment": { "anyOf": [ { "$ref": "#/$defs/Payment" }, { "type": "null" } ], "default": null, "description": "BG-16" }, "payment_terms": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-20", "title": "Payment Terms" }, "preceding_invoices": { "description": "BG-3", "items": { "$ref": "#/$defs/PrecedingInvoice" }, "title": "Preceding Invoices", "type": "array" }, "prepaid_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-113 shortcut when totals are computed", "title": "Prepaid Amount" }, "project_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-11", "title": "Project Reference" }, "purchase_order_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-13", "title": "Purchase Order Reference" }, "receiving_advice_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-15", "title": "Receiving Advice Reference" }, "rounding_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-114 shortcut when totals are computed", "title": "Rounding Amount" }, "sales_order_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-14", "title": "Sales Order Reference" }, "seller": { "$ref": "#/$defs/Party", "description": "BG-4" }, "tax_exemption_reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Default BT-120 text for E/AE/K/G/O categories, e.g. 'TVA non applicable, art. 293 B du CGI'", "title": "Tax Exemption Reason" }, "tax_exemption_reason_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Default BT-121 VATEX code", "title": "Tax Exemption Reason Code" }, "tax_point_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-7", "title": "Tax Point Date" }, "tender_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-17", "title": "Tender Reference" }, "totals": { "anyOf": [ { "$ref": "#/$defs/Totals" }, { "type": "null" } ], "default": null, "description": "BG-22, computed when omitted" }, "type_code": { "default": "380", "description": "UNTDID 1001, BT-3: 380 invoice, 381 credit note, 384 corrected, 386 prepayment, 389 self-billed", "enum": [ "380", "381", "384", "386", "389", "261", "751" ], "title": "Type Code", "type": "string" }, "vat_accounting_currency": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-6", "title": "Vat Accounting Currency" } }, "required": [ "number", "issue_date", "seller", "buyer", "lines" ], "title": "Invoice", "type": "object" }, "Language": { "enum": [ "fr", "en" ], "title": "Language", "type": "string" }, "Line": { "additionalProperties": false, "properties": { "allowances": { "description": "BG-27", "items": { "$ref": "#/$defs/LineAllowanceCharge" }, "title": "Allowances", "type": "array" }, "attributes": { "additionalProperties": { "type": "string" }, "description": "BG-32 item attributes", "title": "Attributes", "type": "object" }, "buyer_accounting_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-133", "title": "Buyer Accounting Reference" }, "buyer_item_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-156", "title": "Buyer Item Id" }, "charges": { "description": "BG-28", "items": { "$ref": "#/$defs/LineAllowanceCharge" }, "title": "Charges", "type": "array" }, "gross_unit_price": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-148", "title": "Gross Unit Price" }, "id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-126, auto-numbered when omitted", "title": "Id" }, "item_description": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-154", "title": "Item Description" }, "item_name": { "description": "BT-153", "title": "Item Name", "type": "string" }, "net_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-131. Computed as quantity x unit_price / base_qty - allowances + charges when omitted", "title": "Net Amount" }, "note": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-127", "title": "Note" }, "order_line_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-132", "title": "Order Line Reference" }, "origin_country": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-159", "title": "Origin Country" }, "period_end": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-135", "title": "Period End" }, "period_start": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-134", "title": "Period Start" }, "price_base_quantity": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,13}|(?=[\\d.]{1,20}0*$)\\d{0,13}\\.\\d{0,6}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-149", "title": "Price Base Quantity" }, "price_base_unit_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-150", "title": "Price Base Unit Code" }, "price_discount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-147", "title": "Price Discount" }, "quantity": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,13}|(?=[\\d.]{1,20}0*$)\\d{0,13}\\.\\d{0,6}0*$)", "type": "string" } ], "description": "BT-129", "title": "Quantity" }, "seller_item_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-155", "title": "Seller Item Id" }, "standard_item_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-157, e.g. EAN/GTIN", "title": "Standard Item Id" }, "standard_item_id_scheme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-157-1, e.g. 0160 = GTIN", "title": "Standard Item Id Scheme" }, "unit_code": { "default": "C62", "description": "UN/ECE Rec 20, BT-130 (C62 unit, HUR hour, DAY, KGM, MTR, LTR...)", "title": "Unit Code", "type": "string" }, "unit_price": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "Net unit price, BT-146", "title": "Unit Price" }, "vat_category": { "$ref": "#/$defs/VatCategory", "default": "S", "description": "BT-151" }, "vat_rate": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-152, required for category S", "title": "Vat Rate" } }, "required": [ "item_name", "quantity", "unit_price" ], "title": "Line", "type": "object" }, "LineAllowanceCharge": { "additionalProperties": false, "properties": { "amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-136 / BT-141", "title": "Amount" }, "base_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-137 / BT-142", "title": "Base Amount" }, "percentage": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-138 / BT-143", "title": "Percentage" }, "reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-139 / BT-144", "title": "Reason" }, "reason_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-140 / BT-145", "title": "Reason Code" } }, "required": [ "amount" ], "title": "LineAllowanceCharge", "type": "object" }, "Note": { "additionalProperties": false, "properties": { "subject_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "UNTDID 4451 code, BT-21 (e.g. AAI general, PMT payment, PMD penalties)", "title": "Subject Code" }, "text": { "description": "BT-22", "title": "Text", "type": "string" } }, "required": [ "text" ], "title": "Note", "type": "object" }, "OutputFormat": { "enum": [ "facturx-pdf", "cii-xml", "ubl-xml" ], "title": "OutputFormat", "type": "string" }, "Party": { "additionalProperties": false, "properties": { "address": { "$ref": "#/$defs/Address" }, "contact": { "anyOf": [ { "$ref": "#/$defs/Contact" }, { "type": "null" } ], "default": null }, "electronic_address": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-34 / BT-49", "title": "Electronic Address" }, "electronic_address_scheme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "EAS code for electronic_address (BT-34-1 / BT-49-1), e.g. 0225 = SIRET (FR)", "title": "Electronic Address Scheme" }, "global_ids": { "additionalProperties": { "type": "string" }, "description": "BT-29 / BT-46: {schemeID: identifier}, e.g. {'0009': SIRET}", "title": "Global Ids", "type": "object" }, "legal_info": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Seller only, BT-33: legal form, share capital, RCS city...", "title": "Legal Info" }, "legal_registration_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-30 / BT-47 when not a SIREN. Ignored if siren is set.", "title": "Legal Registration Id" }, "legal_registration_scheme": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "ISO 6523 ICD for legal_registration_id (BT-30-1 / BT-47-1), e.g. 0002 = SIREN", "title": "Legal Registration Scheme" }, "name": { "description": "Legal name, BT-27 / BT-44", "title": "Name", "type": "string" }, "siren": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "French SIREN (9 digits). Written as legal registration id BT-30 / BT-47 with scheme 0002.", "title": "Siren" }, "siret": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "French SIRET (14 digits). Shortcut for electronic_address with scheme 0225.", "title": "Siret" }, "tax_registration_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Seller only, BT-32", "title": "Tax Registration Id" }, "trading_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-28 / BT-45", "title": "Trading Name" }, "vat_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-31 / BT-48, e.g. FR12345678901", "title": "Vat Id" } }, "required": [ "name", "address" ], "title": "Party", "type": "object" }, "Payment": { "additionalProperties": false, "properties": { "account_name": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-85", "title": "Account Name" }, "bic": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-86", "title": "Bic" }, "creditor_reference_id": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Direct debit, BT-90", "title": "Creditor Reference Id" }, "debited_iban": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Direct debit, BT-91", "title": "Debited Iban" }, "iban": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Payee account, BT-84", "title": "Iban" }, "mandate_reference": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Direct debit, BT-89", "title": "Mandate Reference" }, "means_code": { "default": "30", "description": "UNTDID 4461, BT-81. 30 credit transfer, 58 SEPA transfer, 59 SEPA direct debit, 48 card", "title": "Means Code", "type": "string" }, "means_text": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-82", "title": "Means Text" }, "remittance_information": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-83", "title": "Remittance Information" }, "terms": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-20", "title": "Terms" } }, "title": "Payment", "type": "object" }, "PrecedingInvoice": { "additionalProperties": false, "properties": { "issue_date": { "anyOf": [ { "format": "date", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-26", "title": "Issue Date" }, "number": { "description": "BT-25", "title": "Number", "type": "string" } }, "required": [ "number" ], "title": "PrecedingInvoice", "type": "object" }, "Profile": { "description": "Factur-X / CII profile for generation.", "enum": [ "basicwl", "en16931", "extended", "extended-ctc-fr" ], "title": "Profile", "type": "string" }, "Totals": { "additionalProperties": false, "description": "Document totals (BG-22). All computed by the engine when omitted.", "properties": { "allowance_total": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-107", "title": "Allowance Total" }, "amount_due": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-115", "title": "Amount Due" }, "charge_total": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-108", "title": "Charge Total" }, "line_total": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-106", "title": "Line Total" }, "prepaid": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-113", "title": "Prepaid" }, "rounding": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-114", "title": "Rounding" }, "tax_exclusive": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-109", "title": "Tax Exclusive" }, "tax_inclusive": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-112", "title": "Tax Inclusive" }, "tax_total": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-110", "title": "Tax Total" }, "vat_breakdown": { "description": "BG-23", "items": { "$ref": "#/$defs/VatBreakdown" }, "title": "Vat Breakdown", "type": "array" } }, "required": [ "line_total", "tax_exclusive", "tax_total", "tax_inclusive", "amount_due" ], "title": "Totals", "type": "object" }, "VatBreakdown": { "additionalProperties": false, "properties": { "category": { "$ref": "#/$defs/VatCategory", "description": "BT-118" }, "exemption_reason": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-120", "title": "Exemption Reason" }, "exemption_reason_code": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "VATEX code, BT-121", "title": "Exemption Reason Code" }, "rate": { "anyOf": [ { "maximum": 100, "minimum": 0, "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,3}|(?=[\\d.]{1,8}0*$)\\d{0,3}\\.\\d{0,4}0*$)", "type": "string" }, { "type": "null" } ], "default": null, "description": "BT-119", "title": "Rate" }, "tax_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-117", "title": "Tax Amount" }, "taxable_amount": { "anyOf": [ { "type": "number" }, { "pattern": "^(?!^[-+.]*$)[+-]?0*(?:\\d{0,15}|(?=[\\d.]{1,20}0*$)\\d{0,15}\\.\\d{0,4}0*$)", "type": "string" } ], "description": "BT-116", "title": "Taxable Amount" } }, "required": [ "category", "taxable_amount", "tax_amount" ], "title": "VatBreakdown", "type": "object" }, "VatCategory": { "description": "UNTDID 5305 subset used by EN 16931 (BT-151 / BT-118).", "enum": [ "S", "Z", "E", "AE", "K", "G", "O", "L", "M" ], "title": "VatCategory", "type": "string" } }, "properties": { "check": { "default": "fr-ctc", "description": "Rule set the output must pass before it is returned: fr-ctc (default) = EN 16931 + French CTC rules (BR-FR-*), base = EN 16931 only (non-French sellers).", "enum": [ "base", "fr-ctc" ], "title": "Check", "type": "string" }, "footer_text": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Optional text printed in the PDF footer. Omit it for no footer. Ignored for XML-only output.", "title": "Footer Text" }, "invoice": { "$ref": "#/$defs/Invoice", "description": "Invoice data: seller, buyer, lines, dates, payment terms. Amounts are decimal strings (\"1200.00\"), dates ISO 8601. Totals and the VAT breakdown are computed. Full JSON Schema in the resource facturx://schema/invoice.", "type": "object" }, "language": { "$ref": "#/$defs/Language", "default": "fr", "description": "Language of the visual PDF: fr (default) or en. Ignored when output is cii-xml or ubl-xml.", "type": "string" }, "output": { "$ref": "#/$defs/OutputFormat", "default": "facturx-pdf", "description": "facturx-pdf (default): PDF/A-3 with the visual invoice and CII XML inside, the hybrid file French platforms accept. cii-xml: UN/CEFACT CII XML alone. ubl-xml: UBL 2.1 XML alone.", "type": "string" }, "party_check": { "anyOf": [ { "type": "boolean" }, { "type": "null" } ], "default": null, "description": "Ask EU Verify whether the seller and buyer are invoice-ready before emitting. true checks. false skips. Omit it and extended-ctc-fr checks, other profiles do not. not_ready is a tool error and no file is returned.", "title": "Party Check" }, "profile": { "$ref": "#/$defs/Profile", "default": "en16931", "description": "EN 16931 conformance level written in the XML: en16931 (default, full semantic model), extended (optional business terms), extended-ctc-fr (French B2B mandate; parties are checked before the file is emitted), basicwl (no lines)", "type": "string" } }, "required": [ "invoice" ], "title": "generate_invoiceArguments", "type": "object" }, "name": "generate_invoice", "outputSchema": null }, { "description": "Return a complete invoice or credit-note example to edit and pass to generate_invoice.\n\n Use this first, instead of inventing fields. No API key is required, and the call does not count\n as a document. The seller and buyer are sample data: replace them, the number, the dates and the\n lines before you generate. For credit_note, also replace preceding_invoices with the original invoice reference.\n To credit a real invoice already in hand, use draft_credit_note instead of this synthetic example.\n Amounts are positive decimal strings. Nothing is stored, and no file\n is created. Returns the invoice plus the profile and check to pass to generate_invoice.\n ", "inputSchema": { "properties": { "document_type": { "default": "invoice", "description": "invoice (default): type 380; credit_note: type 381 with a sample original-invoice reference.", "enum": [ "invoice", "credit_note" ], "title": "Document Type", "type": "string" }, "profile": { "default": "en16931", "description": "en16931 (default) or extended-ctc-fr. The body is the same. extended-ctc-fr sets party_check so generate_invoice asks EU Verify before emitting a file.", "enum": [ "en16931", "extended-ctc-fr" ], "title": "Profile", "type": "string" } }, "title": "get_invoice_exampleArguments", "type": "object" }, "name": "get_invoice_example", "outputSchema": { "additionalProperties": true, "title": "get_invoice_exampleDictOutput", "type": "object" } }, { "description": "Check a Factur-X PDF, CII XML or UBL XML against EN 16931, and report the fields to fix.\n\n Use when the caller supplies a document, including after corrections; use extract_invoice for business data.\n With no document and only a request to try the product, choose view_invoice_demo instead.\n Supply one source: nonblank xml overrides document_base64 without inspecting it. To check a PDF's\n attachment, omit xml. check adds rules to the detected profile; it cannot change that profile.\n Use base for non-French invoices to avoid French-field findings.\n\n Returns validity and findings with rule ids and field pointers for explain_finding. XSD failures\n skip schematron; inspect checks_skipped before treating validation as complete. Warnings alone do\n not invalidate an invoice. Rule failures or a PDF without XML return valid=false; missing input,\n invalid base64, malformed or unrecognized XML return a tool error.\n Requires a plan key: completed reports consume one document even when invalid; tool errors do not.\n No invoice is changed, stored or sent.\n ", "inputSchema": { "properties": { "check": { "default": "fr-ctc", "description": "fr-ctc: EN 16931 plus French CTC rules (BR-FR-*). base: EN 16931 only.", "enum": [ "base", "fr-ctc" ], "title": "Check", "type": "string" }, "document_base64": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "Standard base64 of a Factur-X PDF, CII XML or UBL XML file; no data-URI prefix.", "title": "Document Base64" }, "xml": { "anyOf": [ { "type": "string" }, { "type": "null" } ], "default": null, "description": "CII or UBL XML as unencoded text.", "title": "Xml" } }, "title": "validate_invoiceArguments", "type": "object" }, "name": "validate_invoice", "outputSchema": { "additionalProperties": true, "title": "validate_invoiceDictOutput", "type": "object" } }, { "description": "Demonstrate the engine on bundled synthetic samples only; never checks a user's invoice.\n\n Use for product evaluation without a key. To check a supplied document, choose validate_invoice.\n Choose sample=valid to inspect a passing CII invoice or sample=invalid to see the missing-buyer-name\n finding. Both use the production XSD and EN 16931 engine; results may be cached for 24 hours for\n the same engine version and input. Inspect validated_at and cached; a cache hit is not a fresh run.\n Call with {} to validate the passing sample, or sample=downloads for PDF/CII/UBL files and the published report.\n Accepts no document data, URLs or extra arguments. No PDF or business-register checks in live mode.\n Shared rate limits return a retryable tool error; unavailable checks never become a passing result.\n Use explain_finding for a returned rule id. Your own invoices require validate_invoice with\n an evaluation or monthly-plan key. Nothing is stored except reports for these public fixtures.\n ", "inputSchema": { "properties": { "sample": { "default": "valid", "description": "valid (default): passing CII invoice; invalid: missing buyer name; downloads: published files.", "enum": [ "valid", "invalid", "downloads" ], "title": "Sample", "type": "string" } }, "title": "view_invoice_demoArguments", "type": "object" }, "name": "view_invoice_demo", "outputSchema": { "additionalProperties": true, "title": "view_invoice_demoDictOutput", "type": "object" } } ] }
Verify it yourselfcurl -s https://api.teppi.xyz/v1/evidence/sha256:0482db0bd4139333def9ff9643d0487d1e098b132f2f4a84024eb54cb5aa14b9 | sha256sum