Get Usage Statistics
Order API
Get Usage Statistics
Retrieve live proxy usage statistics for a datacenter order.
GET
Get Usage Statistics
Retrieve live proxy usage statistics for a datacenter order — the same data shown on the dashboard’s usage view.
Only available for datacenter orders. Residential and other product categories have no SquidAnalyzer source and return 400.
How It Works
Usage values are scraped live at request time from each child proxy server’s SquidAnalyzer report (no caching), aggregated across every server that hosts the order, and returned as a usage time series plus a list of the top requested domains. Because the data is fetched live, if a child server hosting the order is not currently producing SquidAnalyzer reports, its slice of usage is omitted (each per-server fetch has a 5s timeout and fails open). Totals therefore reflect only the servers that are reporting.Request
Headers
| Header | Value | Required |
|---|---|---|
Authorization | Bearer {your_api_key} | Yes |
Path Parameters
The order ID returned from order creation.
Query Parameters
The reporting granularity. One of
daily, weekly, monthly.daily— time series is keyed by hour ("00"–"23")weekly— time series is keyed by day of weekmonthly— time series is keyed by day of month ("01"–"31")
ISO date string selecting the reporting window (e.g.
2026-06-25). Defaults to today.Example Requests
Response
Success Response
Response Fields
Status of the request.
The order the statistics are for.
The reporting granularity that was applied (
daily, weekly, or monthly).The aggregated usage data.
Per-bucket usage. Each entry has a
date key (hour, day of week, or day of month depending on period), usage (megabytes transferred for that bucket), and requests (the request/hit count for that bucket).Aggregate totals across all reporting servers.
bytes_in and bytes_out are raw byte totals; requests is the total hit count.The most-requested domains, sorted by request count (descending), limited to the top 100.
requestPercentage is computed across the aggregated set.Error Responses
400 Bad Request - Invalid Period
400 Bad Request - Invalid Date
400 Bad Request - Not a Datacenter Order
401 Unauthorized
404 Not Found
500 Internal Server Error
Notes
- The key must have the
orderservice scope. Each call is rate-limited per key and recorded in the audit log (service: order,action: read). - Data is fetched live with no caching, so response time depends on how many servers host the order.
