API Documentation
Invoices ¶
Invoices ¶
For more details on how to work with custom fields please refer to Working with custom fields guide.
The invoice object represents the main building block of the invoicing module.
You can find out more about invoicing in our Help documentation: Creating and Managing Invoices
Following diagram shows invoices in our data hierarchy:
Tax changes
On September 3, 2024, we’ve released new Tax rates system. That means that tax1_name, tax1_value, tax2_name and tax2_value attributes on Invoice object are no longer in use. You should, however, use tax_rate_id attribute on Line item objects to achieve the same goal. You can read more about this in LineItems endpoint documentation.
Related resources
Supported filter params
-
amount
-
amount_credited
-
amount_credited_with_tax
-
amount_paid
-
amount_tax
-
amount_unpaid
-
amount_with_tax
-
amount_written_off
-
company_id (array)
-
created_at
-
creator_id (array)
-
credited
-
currency
-
deal_id (array)
-
delivery_on
-
export_status (1: exported, 2: unexported)
-
full_query
-
fuzzy_dates
-
fuzzy_people
-
id
-
invoice_aging (0: other, 1: overdue < 15 days, 2: overdue 15 - 45 days, 3: overdue 45+ days, 4: not overdue)
-
invoice_state (1: draft, 2: finalized)
-
invoice_status (0: unsent, 1: paid, 2: overdue, 3: not_overdue, 4: draft)
-
invoice_type (1: invoice, 2: credit note)
-
invoiced_on
-
invoicing_method (1: actuals, 2: uninvoiced amount, 3: percentage)
-
issuer_id (array)
-
jump_query
-
last_activity_at
-
number
-
overdue_status
-
paid_on
-
parent_invoice_id (array)
-
pay_on
-
payment_status (1: paid, 2: unpaid, 3: partially paid)
-
project_id (array)
-
purchase_order_number
-
query
-
responsible_id (array)
-
sent_on
-
sent_status (1: sent, 2: unsent)
-
status (0: unsent, 1: paid, 2: overdue, 3: not_overdue, 4: draft)
-
subscriber_id (array)
-
subsidiary_id (array)
-
tags
Supported sort params
-
amount
-
amount_credited
-
amount_credited_with_tax
-
amount_paid
-
amount_tax
-
amount_with_tax
-
amount_written_off
-
company_name
-
created_at
-
credited
-
custom_fields
-
deleted_at
-
delivery_on
-
discount
-
invoiced_on
-
last_activity_at
-
number
-
pay_on
-
purchase_order_number
-
sent_on
Filter operations are supported on this endpoint.
Invoicing flow
Manual workflow
Step 1: Create Draft Invoice
-
Endpoint:
POST /api/v2/invoices -
Creates invoice in draft state with generated ID
Step 2: Add Line Items
-
Endpoint:
POST /api/v2/line_items -
Each line item is validated and created individually
Step 3: Create Invoice Attributions
-
Endpoint:
POST /api/v2/invoice_attributions -
Links invoice to specific budgets with amount allocation
-
Validates budget and invoice have same currency
-
Updates associated time entries and expenses to link them to the attribution
Workflow using line item generator
Step 1: Create Draft Invoice
- Same as manual workflow
Step 2: Preview Line Items (Optional)
-
Endpoint:
GET /api/v2/invoices/:id/preview -
Test different invoicing methods and parameters
-
Returns computed line items and invoice attributions without persisting
-
Use same parameters as generation step
Step 3: Generate Line Items and Attributions
-
Endpoint:
POST /api/v2/line_items/generate -
Creates all line items and invoice attributions in a single operation
-
Automatically handles grouping, calculations, and positioning
GET /api/v2/invoices
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonHeaders
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": [
{
"id": "25",
"type": "invoices",
"attributes": {
"number": "2016/01",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "882af3ed2bba3846992470fe396fb4da",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:51.383+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:05:51.383+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:05:51.383+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "657"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
}
],
"links": {
"first": "http://api-test.productive.io/api/v2/invoices?page%5Bnumber%5D=1&page%5Bsize%5D=30",
"last": "http://api-test.productive.io/api/v2/invoices?page%5Bnumber%5D=1&page%5Bsize%5D=30"
},
"meta": {
"current_page": 1,
"total_pages": 1,
"total_count": 1,
"page_size": 30,
"max_page_size": 200
}
}Get invoicesGET/api/v2/invoices
GET /api/v2/invoices/27
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonHeaders
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "27",
"type": "invoices",
"attributes": {
"number": "2016/01",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "593e6e9e831498bea1e483c60c987587",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:51.857+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:05:51.857+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:05:51.857+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "659"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}POST /api/v2/invoices
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"invoiced_on": "2025-10-25",
"pay_on": "2025-11-04",
"currency": "EUR",
"bank_account_id": 1,
"bank_account_details": {
"bank_name": "Test Bank",
"number": "HR123456789"
}
},
"relationships": {
"company": {
"data": {
"type": "companies",
"id": "1806"
}
},
"subsidiary": {
"data": {
"type": "subsidiaries",
"id": "775"
}
},
"document_type": {
"data": {
"type": "document_types",
"id": "697"
}
},
"issuer_id": {
"data": {
"type": "people",
"id": "2541"
}
}
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "29",
"type": "invoices",
"attributes": {
"number": null,
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": null,
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "64138e0ae20ecc06182f2e14ed5e27ed",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:52.330+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:05:52.330+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": true,
"last_activity_at": "2025-10-25T06:05:52.330+02:00",
"creation_options": null,
"payment_terms": 10,
"bank_account_details": {
"bank_name": "Test Bank",
"number": "HR123456789"
},
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "660"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}POST /api/v2/invoices
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"invoiced_on": ""
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/currency"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/invoiced_on"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/company"
}
}
]
}Create an invoicePOST/api/v2/invoices
- invoiced_on
date(required) Example: 2018-01-01invoiced on
- currency
string(required) Example: EURcurrency
- company_id
number(required) Example: 1company id
- subsidiary_id
number(optional) Example: 1subsidiary id, required if subsidiary feature enabled
- invoice_type_id
number(optional) Example: 2invoice type id, required if credit note
- document_type_id
number(required) Example: 1document type id
- issuer_id
number(optional) Example: 100ID of invoice issuer; if nothing is sent, creator will be set as issuer
PATCH /api/v2/invoices/34
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"number": "02/2017"
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "34",
"type": "invoices",
"attributes": {
"number": "02/2017",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "d226e8957398fac874dfc4e4d944d7b7",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:53.634+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:05:53.666+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": true,
"last_activity_at": "2025-10-25T06:05:53.634+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "664"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}PATCH /api/v2/invoices/36
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"invoiced_on": ""
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/invoiced_on"
}
}
]
}DELETE /api/v2/invoices/37
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonPATCH /api/v2/invoices/39/export
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonHeaders
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"errors": [
{
"status": "422",
"code": "tax_rates_not_mapped",
"title": "Invalid Attribute",
"detail": "Tax rates not mapped",
"source": {
"pointer": "data/attributes/tax_rate"
}
}
]
}PATCH /api/v2/invoices/40/export
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"id": "1",
"type": "invoices",
"attributes": {
"company_reference_id": "115"
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "40",
"type": "invoices",
"attributes": {
"number": "2016/01",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "a31a75b66568a7c96dd8db1e76a9fd94",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:55.322+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:05:55.322+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:05:55.322+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "670"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}PATCH /api/v2/invoices/41/export
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"id": "1",
"type": "invoices",
"attributes": {
"company_reference_id": null
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "41",
"type": "invoices",
"attributes": {
"number": "2016/01",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "cbf9a3d9b33ac249271388759db149c2",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:55.468+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:05:55.468+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:05:55.468+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "671"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}PATCH /api/v2/invoices/42/export
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"id": "1",
"type": "invoices"
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "42",
"type": "invoices",
"attributes": {
"number": "2016/01",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "87036b190d7da217a49a71b7500c6892",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:55.628+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:05:55.628+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:05:55.628+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "672"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}Exports an invoicePATCH/api/v2/invoices/{id}/export
- id
number(required) Example: 1invoice id
PATCH /api/v2/invoices/44/export_update
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonHeaders
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "feature unavailable",
"source": {
"pointer": "data/attributes/export_to_accounting"
}
}
]
}Updates an exported invoicePATCH/api/v2/invoices/{id}/export_update
- id
number(required) Example: 1invoice id
PATCH /api/v2/invoices/46/send
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"to": [
"test@email.com"
],
"cc": [
"test@productive.io",
"test-2@productive.io"
],
"bcc": [
"mail@something.com"
],
"subject": "Mail title",
"body": "Lorem ipsum dolor si amet",
"e_invoice_url": "https://einvoice-files-test.productive.io/test.xml"
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "46",
"type": "invoices",
"attributes": {
"number": "2016/01",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": "2025-10-25",
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "38fb095847bf828a77979762e5411cfd",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:56.475+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:05:56.549+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:05:56.475+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "676"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}PATCH /api/v2/invoices/52/send
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"to": [
"invalid mail"
]
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "invalid mail is not an email",
"source": {
"pointer": "data/attributes/to"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/subject"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/body"
}
}
]
}PATCH /api/v2/invoices/53/send
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"to": [
"random_email@mail.com"
],
"cc": [
"random_email_cc@mail.com"
],
"bcc": [
"random_email_bcc@mail.com"
],
"subject": "Test Email",
"body": "This is a test email"
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"errors": [
{
"status": "403",
"code": "restricted_email_in_trialing",
"title": "Access Denied",
"detail": "When in trial you can send emails only to yourself",
"source": {}
}
]
}PATCH /api/v2/invoices/54/send
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"to": [
"test@email.com"
],
"cc": [
"test@productive.io",
"test-2@productive.io"
],
"bcc": [
"mail@something.com"
],
"subject": "Mail title",
"body": "Lorem ipsum dolor si amet"
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "54",
"type": "invoices",
"attributes": {
"number": "2016/01",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": "2025-10-25",
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": null,
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "aeecc2e648bdbdf10e7f945df7ec2cee",
"purchase_order_number": null,
"created_at": "2025-10-25T06:05:59.988+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:06:00.065+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:05:59.988+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "684"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}Sends an invoicePATCH/api/v2/invoices/{id}/send
- id
number(required) Example: 1invoice id
PATCH /api/v2/invoices/66/finalize
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {
"number": "05/2021"
}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "66",
"type": "invoices",
"attributes": {
"number": "05/2021",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": "2025-10-25T06:06:03.285+02:00",
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "f7d67e1fc68cd731ee83f09ae0fe8c55",
"purchase_order_number": null,
"created_at": "2025-10-25T06:06:03.263+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:06:03.293+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:06:03.263+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "694"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}PATCH /api/v2/invoices/68/finalize
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonBody
{
"data": {
"type": "invoices",
"attributes": {}
}
}Headers
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"data": {
"id": "68",
"type": "invoices",
"attributes": {
"number": "0-CLIE1269-1",
"subject": null,
"invoiced_on": "2025-10-25",
"sent_on": null,
"pay_on": "2025-11-04",
"delivery_on": null,
"paid_on": null,
"finalized_on": "2025-10-25",
"finalized_at": "2025-10-25T06:06:04.401+02:00",
"discount": null,
"tax1_name": null,
"tax1_value": null,
"tax2_name": null,
"tax2_value": null,
"deleted_at": null,
"tag_list": [],
"note": null,
"footer": null,
"exported": false,
"exported_at": null,
"export_integration_type_id": null,
"export_id": null,
"export_invoice_url": null,
"company_reference_id": null,
"note_interpolated": null,
"footer_interpolated": null,
"email_key": "f771a47ce2956661ef284627fa4a8384",
"purchase_order_number": null,
"created_at": "2025-10-25T06:06:04.376+02:00",
"exchange_rate": "1.25",
"exchange_date": "2025-10-25",
"custom_fields": null,
"updated_at": "2025-10-25T06:06:04.410+02:00",
"sample_data": false,
"pay_on_relative": false,
"invoice_type_id": 1,
"credited": false,
"line_item_tax": false,
"last_activity_at": "2025-10-25T06:06:04.377+02:00",
"creation_options": {},
"payment_terms": 10,
"bank_account_details": null,
"currency": "EUR",
"currency_default": "USD",
"currency_normalized": "EUR",
"amount": 0,
"amount_default": 0,
"amount_normalized": 0,
"amount_tax": 0,
"amount_tax_default": 0,
"amount_tax_normalized": 0,
"amount_with_tax": 0,
"amount_with_tax_default": 0,
"amount_with_tax_normalized": 0,
"amount_paid": 0,
"amount_paid_default": 0,
"amount_paid_normalized": 0,
"amount_written_off": 0,
"amount_written_off_default": 0,
"amount_written_off_normalized": 0,
"amount_unpaid": 0,
"amount_unpaid_default": 0,
"amount_unpaid_normalized": 0,
"amount_credited": 0,
"amount_credited_default": 0,
"amount_credited_normalized": 0,
"amount_credited_with_tax": 0,
"amount_credited_with_tax_default": 0,
"amount_credited_with_tax_normalized": 0
},
"relationships": {
"organization": {
"data": {
"type": "organizations",
"id": "696"
}
},
"bill_to": {
"meta": {
"included": false
}
},
"bill_from": {
"meta": {
"included": false
}
},
"company": {
"meta": {
"included": false
}
},
"document_type": {
"meta": {
"included": false
}
},
"creator": {
"meta": {
"included": false
}
},
"subsidiary": {
"meta": {
"included": false
}
},
"parent_invoice": {
"meta": {
"included": false
}
},
"issuer": {
"meta": {
"included": false
}
},
"bank_account": {
"meta": {
"included": false
}
},
"invoice_attributions": {
"meta": {
"included": false
}
},
"custom_field_people": {
"meta": {
"included": false
}
},
"custom_field_attachments": {
"meta": {
"included": false
}
},
"attachment": {
"meta": {
"included": false
}
}
}
},
"meta": {}
}Finalizes an invoicePATCH/api/v2/invoices/{id}/finalize
- id
number(required) Example: 1invoice id
GET /api/v2/invoices/71/preview?budget_ids[]=684&display_format={budget}&invoicing_by=budget&invoicing_method=percentage&percentage=50
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonHeaders
Content-Type: application/json; charset=utf-8Body
{
"data": [
{
"budget_id": "684",
"service_id": null,
"service_type_id": "367",
"service_type_name": "test name",
"description": "test name",
"type": "regular",
"currency": "EUR",
"discount": null,
"amount": 50000,
"amount_rounded": 50000,
"object_type": "line_item",
"invoice_id": "71",
"unit_id": "2",
"unit_name": "Piece",
"quantity": 0.5,
"unit_price": 100000,
"position": 1
},
{
"object_type": "invoice_attribution",
"invoice_id": "71",
"budget_id": "684",
"amount": 50000,
"date_from": null,
"date_to": null
}
]
}GET /api/v2/invoices/73/preview?budget_ids[]=685&display_format={budget}&invoicing_by=budget&invoicing_method=percentage
Headers
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Content-Type: application/vnd.api+jsonHeaders
Content-Type: application/vnd.api+json; charset=utf-8Body
{
"errors": [
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "can't be blank",
"source": {
"pointer": "data/attributes/percentage"
}
},
{
"status": "422",
"code": "invalid_attribute",
"title": "Invalid Attribute",
"detail": "is not a number",
"source": {
"pointer": "data/attributes/percentage"
}
}
]
}Preview invoiceGET/api/v2/invoices/{id}/preview
The preview endpoint lets you simulate invoice line item generation without persisting any changes. It returns the exact line items and invoice attributions that would be created for a given invoice based on the selected invoicing method and options.
-
Builds line items using the same logic as the line items “generate” method
-
Returns data only, does not modify the invoice
- id
number(required) Example: 1invoice id
- budget_ids
array(required) Example: %5B1%2C+3%5Darray of budget ids
- invoicing_method
string(required) Example: percentagepossible values: uninvoiced_time_and_expenses, uninvoiced_amount, percentage
- invoicing_by
string(optional) Example: servicepossible values: service/budget; required for invoicing method uninvoiced_amount or percentage
- percentage
number(optional) Example: 50percentage of budget revenue; required for invoicing method percentage
- display_format
string(required) Example: %7Bservice%7Ddisplay format
- expense_display_format
string(optional) Example: %7Bexpense%7Ddisplay format for expenses
- locale
string(optional) Example: en_USlocale; required for invoicing method uninvoiced_time_and_expenses
- date_from
date(optional) Example: 2024-04-01date from
- date_to
date(optional) Example: 2024-05-01date to
Generated by aglio on 25 Oct 2025