Export Bills
GET/api/bills/list/export
Export landed cost bills as XLSX or CSV. The response is a binary file download, not JSON.
purchase-orders:readGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Authentication: Requires Bearer token. Scope: purchase-orders (read/write).
Parameters
format—xlsx(default) orcsvcontent_mode—summary(one row per bill, default) orline_items(one row per bill line; bill columns repeat per line, line-item columns are appended)scope— which bills to export:all— every bill, ignoring active filtersfiltered— bills matching the currentfilter[...]/filter_groupsparams (default)current_page— only the current page (honorspage/per_page/sort)selected— only the bills inids
columns— comma-separated bill column keys to include (preserves order). Omit for all columns. Available keys:id,invoice_number,invoice_date,supplier_name,link_type,link_reference,proration_strategy,currency_code,currency_rate,line_count,subtotal,tax_total,grand_total,allocated_amount,unallocated_amount,allocation_status,cost_categories,has_accounting_transaction,source,settlement_reference_count,created_at,updated_atids— comma-separated bill IDs (required whenscope=selected)
All filter[...], filter_groups, and sort params from the List Bills endpoint also apply when scope=filtered.
In line_items mode these line columns are always appended: Line Description, Line Cost Category, Line Qty, Line Amount, Line Extended, Line Tax Rate.
Response
Binary file download:
- XLSX:
Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet - CSV:
Content-Type: text/csv - Filename:
landed-cost-bills-{timestamp}.{ext}(summary) orlanded-cost-bills-detail-{timestamp}.{ext}(line_items)
Request
Responses
- 200
- 401
- 403
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.