Export Accounting COGS Drilldown
GET/api/reporting/accounting-cogs/drilldown/export
All underlying movements behind one COGS report row, unpaginated (capped at 5,000 rows), so every transaction for the row can be exported at once. Identify the row the same way as the paginated drilldown endpoint (dimensions[<group_by>]=<value> for each active group-by dimension) and pass the same filter[date_range_from]/filter[date_range_to] the report was generated with.
reports:readGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Unlike the paginated drilldown, this returns the full movement set as { data, total, truncated }: data is every movement (up to 5,000, same fields as the drilldown), total is the true count of movements in the row, and truncated is true when total exceeded the 5,000 cap (narrow the date range to export the remainder).
Authentication: Requires Bearer token. Scope: reports.
Each movement row includes a cross-link to the underlying business document via link_route (e.g. the sales order fulfillment, inventory adjustment, or return receipt that produced it), plus link_type_label, link_id, and link_reference. link_route is null for batch-sourced movements that don't resolve to a single document.
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.