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.
Query parameters
Restrict the report to yielded sales at the given site.
Restrict to sales made on or after this date, in the site's local timezone.
Restrict to sales made on or before this date, in the site's local timezone.
Restrict to sales whose order reference or offering name contains the given text, case-insensitively.
A comma-separated list of offering IDs to filter on.
A comma-separated list of offering types to filter on.
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.
A comma-separated list of reporting tiers to filter on.
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"
}
}