CropPath for developers

All guides

Data export

Available

Records of lots for an authority or a buyer, and an archive of everything a company holds.

Records of lots

When an authority or a buyer asks for the records of a lot, GET /v1/lots/{lot}/records-export.csv (or .json) answers in one request: the lot's tracking events, the facts frozen at the seal, every lab result, any recall and the open holds, with the supplier on every row and the shipment on the shipping rows. Times are local (+07:00) and masses in kg.

GET /v1/records-export.csv (or .json) with start and end covers the company's lots created in that range, at most 366 days, one page at a time: the next page's cursor is next_cursor (JSON) or X-Next-Cursor (CSV). A lot whose device events were cut is flagged by the X-Records-Truncated header, a truncation_notice row in the CSV and truncated in the JSON.

Company admins and auditors may download them; an OAuth2 client needs the records_export scope, which no other scope includes. Every download is written to the activity log and never cached.

Everything the company holds

A company admin downloads the whole company as one ZIP archive of CSV and JSON files: in the console (Settings, Download all data) or over the API from a signed-in session only (API tokens and API clients are refused). Asking and downloading both need a password confirmed within the last 10 minutes.

  1. POST /v1/company/exports asks for an archive (202). One at a time (409 export_in_progress), at most 3 in any 24 hours (429 too_many_exports, with Retry-After).
  2. GET /v1/company/exports shows its status: queued, running, then ready or failed; a ready archive becomes expired 24 hours later.
  3. GET /v1/company/exports/{id}/download returns the archive for 24 hours after it is ready, then 410 export_expired. Check it against the sha256 the list shows.

The archive never holds passwords, sign-in secrets, tokens, client or webhook secrets, private keys or session data. company-export.md below lists every file and column.

In the API reference

Downloads

This portal serves these files: you do not need access to the source repository.