Proxy Analytics
On this page, we'll explore the endpoints that provide detailed proxy-level analytics for your custom domains. These endpoints offer insights into the technical performance and operational aspects of your domain infrastructure, helping you monitor and optimize your service delivery.
The proxy analytics API provides comprehensive data about your domains' infrastructure performance, including request volumes, data transfer statistics, response times, and server behavior. Track metrics such as request counts, bandwidth usage, response time distributions, datacenter and bot traffic patterns, and HTTP response codes. These insights help you understand your domains' technical performance, identify potential issues, and ensure optimal service delivery to your users.
Common Parameters
Analytics endpoints support the following common parameters:
- Name
from- Type
- string
- Description
Start date for the analytics period in ISO 8601 format YYYY-MM-DD, e.g., "2024-01-01". If not provided, defaults to 30 days ago. Timezone is UTC.
- Name
to- Type
- string
- Description
End date for the analytics period in ISO 8601 format YYYY-MM-DD, e.g., "2024-01-31". If not provided, defaults to current date. Timezone is UTC.
- Name
frequency- Type
- string
- Description
(For time-series endpoints only) Time grouping frequency. Available values:
day,week,month. Default:day. Ranges longer than 31 days return weekly data when you ask forday, and ranges longer than 181 days always return monthly data.
Time-series endpoints return one entry for every day, week or month in the range, including periods without traffic (value 0). Each key is the first day of its period: the date itself for day, the Monday for week, and the 1st for month.
Analytics data is available from July 1, 2025, and earlier dates return zeros. Responses are cached for up to 5 minutes.
Analytics must be enabled for the account that owns the domain, otherwise these endpoints return 403 Forbidden. A domain that doesn't belong to one of your accounts returns 404 Not Found.
How proxy analytics are counted
Proxy analytics count every request to your domain, including bots and datacenter traffic. List endpoints return up to 200 entries sorted by count. percentage is each entry's share of the returned entries' total.
Request count
This endpoint returns the total number of HTTP requests processed for your custom domain.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format).
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format).
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/request_count \
-H "Authorization: Bearer {token}" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"count": 123456
}
Request counts by date
This endpoint returns the number of HTTP requests broken down by date.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format). Defaults to 30 days ago.
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format). Defaults to current date.
- Name
frequency- Type
- string
- Description
Time grouping frequency (
day,week,month). Default:day.
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/request_counts_by_date \
-H "Authorization: Bearer {token}" \
-d frequency="day" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"data": {
"2024-01-01": 45678,
"2024-01-02": 52341,
"2024-01-03": 48765,
"2024-01-04": 51234
}
}
Total data transfer
This endpoint returns the total amount of data transferred for your custom domain. This includes both incoming and outgoing traffic. The value is in bytes.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format). Defaults to 30 days ago.
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format). Defaults to current date.
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/total_data_transfer \
-H "Authorization: Bearer {token}" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"bytes": 1234567890
}
Data transfer by date
This endpoint returns the amount of data transferred in bytes broken down by date. This includes both incoming and outgoing traffic.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format). Defaults to 30 days ago.
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format). Defaults to current date.
- Name
frequency- Type
- string
- Description
Time grouping frequency (
day,week,month). Default:day.
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/data_transfer_by_date \
-H "Authorization: Bearer {token}" \
-d frequency="day" \
-d from="2024-09-01" \
-d to="2024-09-29"
Response
{
"data": {
"2024-01-01": 653420657,
"2024-01-02": 1318207597,
"2024-01-03": 710554739,
"2024-01-04": 0
}
}
Average response time
This endpoint returns how long your upstream took to respond, averaged over the requests that were forwarded to it. The duration is in seconds.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format). Defaults to 30 days ago.
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format). Defaults to current date.
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/average_response_time \
-H "Authorization: Bearer {token}" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"duration": 0.245
}
Average response time by date
This endpoint returns how long your upstream took to respond, averaged over the requests that were forwarded to it, broken down by date. The duration is in seconds.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format). Defaults to 30 days ago.
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format). Defaults to current date.
- Name
frequency- Type
- string
- Description
Time grouping frequency (
day,week,month). Default:day.
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/average_response_time_by_date \
-H "Authorization: Bearer {token}" \
-d frequency="day" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"data": {
"2024-01-01": 0.234,
"2024-01-02": 0.255,
"2024-01-03": 0.223,
"2024-01-04": 0.215
}
}
Response time distribution
This endpoint returns the number of requests in each upstream response time bucket. Only requests that were forwarded to your upstream are counted, and buckets without requests are left out.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format).
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format).
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/response_time_distribution \
-H "Authorization: Bearer {token}" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"data": {
"0-100ms": 10676,
"100-200ms": 5673,
"200-300ms": 515,
"300-400ms": 4272,
"400-500ms": 9762,
"500-600ms": 11376,
"600-700ms": 7644,
"700-800ms": 4976,
"800-900ms": 4579,
"900ms-1s": 2465,
"1-1.5s": 3271,
"1.5-2s": 1368,
"2-3s": 514,
"3-5s": 512,
"5-10s": 217,
"10s+": 140
}
}
Response codes
This endpoint returns a breakdown of HTTP response codes returned by your custom domain, including counts and percentages for each status code.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format). Defaults to 30 days ago.
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format). Defaults to current date.
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/response_codes \
-H "Authorization: Bearer {token}" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"data": [
{
"name": "200 (OK)",
"http_code": 200,
"count": 235621,
"percentage": 51.69
},
{
"name": "301 (Moved Permanently)",
"http_code": 301,
"count": 143997,
"percentage": 31.59
},
{
"name": "302 (Found)",
"http_code": 302,
"count": 32012,
"percentage": 7.02
}
]
}
Bot requests
This endpoint returns analytics about requests from known bots and crawlers, including search engines, monitoring services, and other automated agents.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format). Defaults to 30 days ago.
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format). Defaults to current date.
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/bot_requests \
-H "Authorization: Bearer {token}" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"data": [
{
"name": "CloudFlare-AlwaysOnline",
"count": 221892,
"percentage": 55.43
},
{
"name": "Google Bot",
"count": 43506,
"percentage": 10.87
},
{
"name": "Empty User-Agent",
"count": 42540,
"percentage": 10.63
}
]
}
Datacenter requests
This endpoint returns analytics about requests originating from different datacenters.
Optional attributes
- Name
from- Type
- string
- Description
Start date for the analytics period (ISO 8601 format).
- Name
to- Type
- string
- Description
End date for the analytics period (ISO 8601 format).
Request
curl -G https://app.saascustomdomains.com/api/v1/analytics/custom_domains/:uuid/datacenter_requests \
-H "Authorization: Bearer {token}" \
-d from="2024-01-01" \
-d to="2024-01-31"
Response
{
"data": [
{
"name": "Cloudflare",
"datacenter_id": "cloudflare",
"count": 222999,
"percentage": 70.94
},
{
"name": "GitHub",
"datacenter_id": "github",
"count": 57785,
"percentage": 18.38
}
]
}