Export items
Export items from an inbox or the Archive as CSV, PDF or ZIP and get a download link.
GET https://cotlet.dev/api/v1/dext/items/export
read
Exports the chosen items, or every item matching the filter. PDF holds up to 250 items; ZIP suits large batches and includes the original files. Dext can archive items after an export, depending on the Archiving settings in Business settings.
Parameters
| Name | Type | Description |
|---|---|---|
| inbox enum | enum | costs or sales. Default: costs. |
| format enum required | enum | csv, pdf or zip. |
| item_ids string[] | string[] | Items to export. Omit to use the filters below. |
| location enum | enum | inbox or archive. Default: inbox. |
| date_from date | date | Only items dated on or after this date. |
| date_to date | date | Only items dated on or before this date. |
Request
curl "https://cotlet.dev/api/v1/dext/items/export?format=csv" \
-H "Authorization: Bearer $COTLET_API_KEY" result = client.call("dext", "export_items", {"format":"csv"}) const result = await cotlet.call('dext', 'export_items', {"format":"csv"}); cotlet call dext export_items --data '{"format":"csv"}' Example response
{
"export_id": "ex_5120",
"format": "csv",
"items": 41,
"download_url": "https://files.cotlet.dev/exports/ex_5120.csv"
}