API Reference / Proxy usage
Query proxy bandwidth usage
Returns the proxy bandwidth ledger over an inclusive date range, optionally narrowed by provider, pool, session, or account. Each row is a daily total of requests, errors, and bytes transferred. Results are paginated. Follow the returned cursor for subsequent pages.
/ proxies. v1. Proxies/ QueryProxyUsageRequest body
application/jsonRequired
Request for one page of daily proxy usage over a range of UTC days, optionally narrowed by provider, pool, session or account.
accountName?stringAn account name to return only its traffic. Absent includes every account.
cursor?stringOpaque cursor from a previous QueryProxyUsageResponse.next_cursor. Empty for the first page. Send the same filters with every page.
endDatestringLast UTC day of the range, inclusive, as YYYY-MM-DD. Required, and must not be before start_date.
Format"date-time"
limit?integerMaximum number of records to return, up to 1000. Zero uses the default of 200. A larger value is rejected with invalid_argument.
Format"int32"
poolId?stringOpaque 16-byte identifier of a pool, base64-encoded in JSON, to return only its traffic. Absent includes every pool.
Format"byte" base64
providerId?stringOpaque 16-byte identifier of a provider, base64-encoded in JSON, to return only its traffic. Absent includes every provider.
Format"byte" base64
sessionId?stringOpaque 16-byte identifier of a session, base64-encoded in JSON, to return only its traffic. Absent includes every session.
Format"byte" base64
startDatestringFirst UTC day of the range, inclusive, as YYYY-MM-DD. Required.
Format"date-time"
Response body
application/json
Success
nextCursor?stringCursor to pass as cursor to fetch the next page. Empty when this is the last page.
records?array<ProxyUsageRecord>The usage records on this page, ordered by day, then provider, pool, session and account.
Show attributes
accountName?stringThe account that made the requests.
bytesIn?stringBytes received through the proxy that day.
Format"int64"
bytesOut?stringBytes sent through the proxy that day.
Format"int64"
errorCount?stringNumber of that day's requests that failed. Part of request_count.
Format"int64"
poolId?stringOpaque 16-byte identifier of the session's pool, base64-encoded in JSON.
Format"byte" base64
providerId?stringOpaque 16-byte identifier of the provider the traffic went through, base64-encoded in JSON.
Format"byte" base64
requestCount?stringNumber of requests made that day.
Format"int64"
sessionId?stringOpaque 16-byte identifier of the session the traffic used, base64-encoded in JSON.
Format"byte" base64
usageDate?stringThe UTC day, as YYYY-MM-DD.
Format"date-time"
workspaceId?stringOpaque 16-byte identifier of the workspace, base64-encoded in JSON.
Format"byte" base64
application/json
The request was malformed, such as a missing required field or an unparseable cursor. The request cannot be carried out in the current system state.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The request lacks a valid API key in the Authorization header.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The API key is not allowed to perform this action on this workspace.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The request was rate limited. Slow down and retry later.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
An internal server error occurred.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
application/json
The service is temporarily unavailable. Retry with backoff.
codestringThe Connect error code, such as "not_found".
details?array<object>Optional machine-readable error details.
messagestringA human-readable description of the error.
curl -X POST "https://api.goldmine.to/proxies.v1.Proxies/QueryProxyUsage" \
-H "Authorization: Bearer $CSTRADER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"startDate": "2026-06-01",
"endDate": "2026-06-29",
"poolId": "AY+MISIifMyN3T09PT09PQ==",
"limit": 100
}'const res = await fetch("https://api.goldmine.to/proxies.v1.Proxies/QueryProxyUsage", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.CSTRADER_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"startDate": "2026-06-01",
"endDate": "2026-06-29",
"poolId": "AY+MISIifMyN3T09PT09PQ==",
"limit": 100
}),
});
const data = await res.json();body := strings.NewReader(`{
"startDate": "2026-06-01",
"endDate": "2026-06-29",
"poolId": "AY+MISIifMyN3T09PT09PQ==",
"limit": 100
}`)
req, err := http.NewRequestWithContext(ctx, http.MethodPost, "https://api.goldmine.to/proxies.v1.Proxies/QueryProxyUsage", body)
if err != nil {
return err
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("CSTRADER_API_KEY"))
req.Header.Set("Content-Type", "application/json")
res, err := http.DefaultClient.Do(req)import os, requests
res = requests.post(
"https://api.goldmine.to/proxies.v1.Proxies/QueryProxyUsage",
headers={"Authorization": f"Bearer {os.environ['CSTRADER_API_KEY']}"},
json={
"startDate": "2026-06-01",
"endDate": "2026-06-29",
"poolId": "AY+MISIifMyN3T09PT09PQ==",
"limit": 100
},
)
data = res.json(){
"records": [
{
"workspaceId": "AY+MHnorfD2eTxorPE1ebw==",
"providerId": "AY+MIBEReqqLuywsLCwsLA==",
"poolId": "AY+MISIifMyN3T09PT09PQ==",
"sessionId": "AY+MIjMzfu6P/05OTk5OTg==",
"accountName": "steam_bot_01",
"usageDate": "2026-06-15",
"requestCount": "1500",
"errorCount": "12",
"bytesOut": "5242880",
"bytesIn": "104857600"
}
],
"nextCursor": "eyJvZmZzZXQiOjUwfQ=="
}{
"code": "failed_precondition",
"message": "The request cannot be carried out in the current system state."
}{
"code": "unauthenticated",
"message": "The request lacks a valid API key in the Authorization header."
}{
"code": "permission_denied",
"message": "The API key is not allowed to perform this action on this workspace."
}{
"code": "resource_exhausted",
"message": "The request was rate limited. Slow down and retry later."
}{
"code": "internal",
"message": "An internal server error occurred."
}{
"code": "unavailable",
"message": "The service is temporarily unavailable. Retry with backoff."
}