POST
/
consumers
/
{consumer_id}
/
accounting
/
invoices
/
multi-analytic-plans
curl --request POST \
  --url https://api.chift.eu/consumers/{consumer_id}/accounting/invoices/multi-analytic-plans \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "invoice_type": "customer_invoice",
  "invoice_number": "<string>",
  "currency": "<string>",
  "untaxed_amount": 123,
  "tax_amount": 123,
  "total": 123,
  "reference": "<string>",
  "payment_communication": "<string>",
  "customer_memo": "<string>",
  "invoice_date": "2023-12-25",
  "due_date": "2023-12-25",
  "partner_id": "<string>",
  "journal_id": "<string>",
  "status": "draft",
  "pdf": "<string>",
  "currency_exchange_rate": 1,
  "invoice_correction": {
    "sale_invoice_correction_tax_code": "<string>",
    "purchase_invoice_correction_tax_code": "<string>",
    "invoice_correction_credit_account_number": "<string>",
    "invoice_correction_debit_account_number": "<string>"
  },
  "nl_payment_terms_split": {
    "g_account": {
      "amount": 123,
      "iban": "<string>"
    },
    "n_account": {
      "amount": 123,
      "iban": "<string>"
    }
  },
  "shipping_country": "<string>",
  "lines": [
    {
      "line_number": 1,
      "description": "<string>",
      "unit_price": 123,
      "unit_of_measure": "<string>",
      "quantity": 123,
      "untaxed_amount": 123,
      "tax_rate": 123,
      "tax_amount": 123,
      "total": 123,
      "account_number": "<string>",
      "tax_code": "<string>",
      "analytic_distribution": []
    }
  ]
}'
{
  "invoice_type": "customer_invoice",
  "invoice_number": "<string>",
  "currency": "<string>",
  "untaxed_amount": 123,
  "tax_amount": 123,
  "total": 123,
  "reference": "<string>",
  "payment_communication": "<string>",
  "customer_memo": "<string>",
  "id": "<string>",
  "invoice_date": "2023-12-25",
  "due_date": "2023-12-25",
  "partner_id": "<string>",
  "journal_id": "<string>",
  "payments": [
    {
      "id": "<string>",
      "name": "<string>",
      "currency": "<string>",
      "amount": 123,
      "dedicated_amount": 0,
      "payment_date": "2023-12-25",
      "journal_type": "customer_invoice",
      "journal_id": "<string>",
      "journal_name": "<string>",
      "reconciled": false,
      "communication": "<string>",
      "matching_number": "<string>"
    }
  ],
  "status": "cancelled",
  "lines": [
    {
      "line_number": 1,
      "description": "<string>",
      "unit_price": 123,
      "unit_of_measure": "<string>",
      "quantity": 123,
      "untaxed_amount": 123,
      "tax_rate": 123,
      "tax_amount": 123,
      "total": 123,
      "account_number": "<string>",
      "tax_code": "<string>",
      "analytic_distribution": []
    }
  ]
}

Authorizations

Authorization
string
header
required

This access token needs to be included in each of your request to the Chift API.

Path Parameters

consumer_id
string
required

Query Parameters

folder_id
string
force_financial_period
string
regroup_lines
enum<string>
default:true

An enumeration.

Available options:
true,
false

Body

application/json
invoice_type
enum<string>
required

An enumeration.

Available options:
customer_invoice,
customer_refund,
supplier_invoice,
supplier_refund
currency
string
required

Indicates the currency of the invoice (e.g. EUR).

untaxed_amount
number
required
tax_amount
number
required
total
number
required
invoice_date
string
required
due_date
string
required
partner_id
string
required
Minimum length: 1
lines
object[]
required
invoice_number
string

Number of the invoice. If left empty, will be automatically generated by the accounting system at creation.

reference
string
payment_communication
string
customer_memo
string
journal_id
string

Indicates the journal used in for the invoice. If the journal is not given, the journal will be automatically set if only one journal exists otherwise an error will be thrown.

status
enum<string>
default:posted

An enumeration.

Available options:
draft,
posted
pdf
string

Base 64 string representing the PDF attached to the sale/purchase entry.

currency_exchange_rate
number
default:1

Indicates the exchange rate at the date of the invoice. Must be filled in when creating the invoice in another currency from the default currency of the accounting system.

invoice_correction
object

Information used to add a correction line when roundings have an impact on the total amount of the invoice.

nl_payment_terms_split
object
shipping_country
string

Response

200
application/json
Successful Response
invoice_type
enum<string>
required

An enumeration.

Available options:
customer_invoice,
customer_refund,
supplier_invoice,
supplier_refund
currency
string
required

Indicates the currency of the invoice (e.g. EUR).

untaxed_amount
number
required
tax_amount
number
required
total
number
required
invoice_date
string
required

Accounting invoice date. It is automatically set to '1970-01-01' if the value is empty in the accounting system.

due_date
string
required

Due date of the invoice. We use the value of the invoice date if the value is not available/empty in the accounting system.

partner_id
string
required
journal_id
string
required

Indicates the journal used in for the invoice. If the journal is not given, the journal will be automatically set if only one journal exists otherwise an error will be thrown.

lines
object[]
required
invoice_number
string

Number of the invoice. If left empty, will be automatically generated by the accounting system at creation.

reference
string
payment_communication
string
customer_memo
string
id
string
payments
object[]
status
enum<string>
default:posted

An enumeration.

Available options:
cancelled,
draft,
posted,
paid