Actions7
Invoice → Create
AI-generatedSummary
Create a new invoice in InvoiceXpress.
Inputs
- date (required) — Invoice date (date‑time).
- due_date (required) — Invoice due date (date‑time).
- tax_exemption_reason — Tax exemption reason code (e.g., M00). Optional.
- observations — Free‑text observations for the invoice. Optional.
- client_id — ID of an existing client. Optional.
- client_name — Client name. Optional.
- client_email — Client email. Optional.
- client_fiscal_id — Client fiscal/VAT ID. Optional.
- client_address — Client street address. Optional.
- client_postal_code — Client postal code. Optional.
- client_country — Client country. Optional.
- client_code — Client code/reference. Optional.
- client_city — Client city. Optional.
- client_phone — Client phone number. Optional.
- itemsMode (required) — Choose how to provide invoice items: UI (form) or JSON. Options: ui, json.
- items (required) — Collection of invoice items (visible when itemsMode = ui). Each item contains: description (string), name (string), quantity (number, required, default 1), tax_id (options, optional), unit (string, optional), unit_price (number, required, default 0).
- items_json (required) — Array of item objects (visible when itemsMode = json). Each item should match InvoiceXpress format: { name, description, unit, quantity, unit_price, tax } where tax is a numeric tax ID or undefined.
Output shape
object
The created invoice object returned by the InvoiceXpress API (POST /v2/invoices).
Examples
Example 1: Create a simple invoice with one line item via UI.
Set date, due_date, itemsMode=UI, add an item with quantity 2, unit_price 10.0, tax_id M00 (no tax exemption), leave client fields blank or fill as needed.
Example 2: Create invoice via JSON items.
Set date, due_date, itemsMode=JSON, and provide items_json: [{ name: 'Consulting', description: 'Hours', unit: 'h', quantity: 5, unit_price: 20, tax: 23 }].