Reports

Queue an export of the yielded sales report

Queues a CSV export of the yielded sales report to be generated asynchronously. Use this instead of the synchronous text/csv variant of /shop/reports/yielded-sales for large date ranges. Requires the reports.download permission.

get/shop/reports/yielded-sales/queue

Query parameters

site_idstring uuid required

Restrict the report to yielded sales at the given site.

date_fromstring date
Example:2026-06-01

Restrict to sales made on or after this date, in the site's local timezone.

date_tostring date
Example:2026-06-30

Restrict to sales made on or before this date, in the site's local timezone.

searchstring
Example:massage

Restrict to sales whose order reference or offering name contains the given text, case-insensitively.

offering_idsstring[]

A comma-separated list of offering IDs to filter on.

offering_typesstring[]

A comma-separated list of offering types to filter on.

yield_rule_idsstring[]

A comma-separated list of yield rule IDs to filter on. Matches the rule recorded at the time of sale, so a rule that has since been deleted still matches its historical sales.

tiersstring[]

A comma-separated list of reporting tiers to filter on.

emailboolean

If true, email the completed CSV to the authenticated user when the background job finishes. Defaults to false, in which case the queued job's output URL must be polled via the queued-jobs endpoint.

Response

The job was successfully queued

Example response

{
  "data": {
    "created_at": "2023-11-07T00:00:00+00:00",
    "updated_at": "2023-11-07T01:00:00+00:00"
  }
}

Changes

No recorded changes to this endpoint across all 1 revision of this API.