Create sales invoice

Create a sales invoice with its lines for a customer. It does not send it.

POST https://cotlet.dev/api/v1/exact-online/sales-invoices

write Confirm

Creates a sales invoice and its lines in one call, because Exact needs the lines together with the header. It returns the invoice ID, number and total as Exact calculated them. It does not send the invoice; send_sales_invoice does. The endpoint exists only in some Exact packages. By default you confirm each call; you can switch that off for this tool.

Parameters

Parameters: create_sales_invoice
NameTypeDescription
division integer integer Division (company) code from list_divisions. Default: the account's current division.
customer string required string Relation name or account_id from search_relations.
invoice_date date required date Invoice date.
lines array required array Objects with description, quantity, unit_price and vat_code.
your_ref string string Your reference shown on the invoice.

Request

cURL
curl -X POST https://cotlet.dev/api/v1/exact-online/sales-invoices \
  -H "Authorization: Bearer $COTLET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"division":1234567,"customer":"Northwind Studio","invoice_date":"2026-10-14","lines":[{"description":"Consulting, October","quantity":12,"unit_price":95,"vat_code":"2"}]}'
Python
result = client.call("exact-online", "create_sales_invoice", {"division":1234567,"customer":"Northwind Studio","invoice_date":"2026-10-14","lines":[{"description":"Consulting, October","quantity":12,"unit_price":95,"vat_code":"2"}]})
Node.js
const result = await cotlet.call('exact-online', 'create_sales_invoice', {"division":1234567,"customer":"Northwind Studio","invoice_date":"2026-10-14","lines":[{"description":"Consulting, October","quantity":12,"unit_price":95,"vat_code":"2"}]});
CLI
cotlet call exact-online create_sales_invoice --data '{"division":1234567,"customer":"Northwind Studio","invoice_date":"2026-10-14","lines":[{"description":"Consulting, October","quantity":12,"unit_price":95,"vat_code":"2"}]}'

Example response

JSON

{
  "invoice_id": "b21e9d77-5a0c-4f1e-8d13-0c6a77e45002",
  "invoice_number": 20260412,
  "customer": "Northwind Studio",
  "invoice_date": "2026-10-14",
  "lines": [
    {
      "description": "Consulting, October",
      "quantity": 12,
      "unit_price": 95,
      "vat_code": "2",
      "amount": 1140
    }
  ],
  "amount_excl_vat": 1140,
  "currency": "EUR",
  "status": "created"
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.