Skip to content

Exports

Exports

Export documents (invoices, estimates, credit notes) to Excel or CSV format.
Supports date range filtering and query filters.

Start bulk PDF export

POST/documents/export/pdf

Start a background job to export documents as a ZIP archive of PDFs.
Supports date range filtering (maximum 1 year).
You will receive an email with a download link when the export is ready.

Header parameters

entity_idstringoptional

Entity ID on which the request is made. Optional - defaults to the first created entity if not provided.

Body parameters

typestringrequired

Document type to export

Possible values: "invoice", "estimate", "credit_note"

Other parameters
date_fromstringoptional
date_tostringoptional
curl -X POST "https://eu.spaceinvoices.com/documents/export/pdf" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "x-entity-id: YOUR_ENTITY_ID" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "invoice",
    "date_from": "2024-01-01",
    "date_to": "2024-12-31"
  }'
Example:

Export documents to Excel or CSV

GET/documents/export

Export filtered documents to Excel (XLSX) or CSV format.
Supports date range filtering (maximum 1 year) and the same query filters as list endpoints.
Returns a downloadable file with all base document fields including flattened customer/issuer data and tax breakdowns.

Header parameters

entity_idstringoptional

Entity ID on which the request is made. Optional - defaults to the first created entity if not provided.

Query parameters

typestringrequired

Document type to export

Possible values: "invoice", "estimate", "credit_note"

formatstringrequired

Export format

Possible values: "xlsx", "csv"

date_fromstringoptional

Start date filter (ISO 8601 date). Date range cannot exceed 1 year.

date_tostringoptional

End date filter (ISO 8601 date). Date range cannot exceed 1 year.

languagestringoptional

Language for column headers. Default: en.

Possible values: "en", "sl"

Default: "en"

querystringoptional

JSON query filter (same as list endpoints)

searchstringoptional

Full-text search

curl "https://eu.spaceinvoices.com/documents/export" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "x-entity-id: YOUR_ENTITY_ID"