18e2f2e178dd
Get statistics
Returns statistics for specified report types.
You need to specify the report types you want to retrieve in the report_types query parameter as a comma-separated list, e.g. report_types=sales_and_costs,profit.
Note: You cannot get statistics for a period longer than 6 months.
Example
To get statistics in the default currency of a store for sales_and_costs and profit reports for August 2022, you can use the following URL: https://api.printful.com/reports/statistics?report_types=sales_and_costs,profit&date_from=2022-08-01&date_to=2022-08-31.
Report types
Currently, the following report types are available:
| Report type | Description |
|---|---|
| sales_and_costs | Detailed information on sales and costs grouped by date. |
| sales_and_costs_summary | Short information on sales and costs grouped by date. |
| printful_costs | Amount paid to Printful for fulfillment and shipping. |
| profit | Profit in the specified period. |
| total_paid_orders | The number of paid orders in the specified period. |
| costs_by_amount | Information on costs by amount grouped by date. |
| costs_by_product | Information on costs grouped by product. |
| costs_by_variant | Information on costs grouped by variant. |
| average_fulfillment_time | Average time it took Printful to fulfill your orders. |
The response structure for the specific reports is documented in the response schema (result.store_statistics.[reportName]).
Query parameters
The beginning of the period to get the statistics from (date in Y-m-d format).
The end of the period to get the statistics from (date in Y-m-d format).
The currency (3-letter code) to return the statistics in. You can also specify display_currency as the value to get the statistics in the account's display currency. The store currency will be used by default.
A comma-separated list of report types to be retrieved.
Headers
Use this to specify which store you want to use (required only for account level token).
The store IDs can be retrieved with the Get basic information about stores endpoint.
Response
OK
Example response
{
"code": 200,
"result": {
"store_statistics": [
{
"currency": "USD"
}
]
}
}