API Reference / Proxy usage
Summarise requests through your proxies
Returns the figures and the chart over the same rows ListProxyRequests lists, for a window of the last 6 hours at most: requests and failures, connections opened and open now, the median and 95th percentile time, the bytes each way, the average split of the time into your side, the proxy and the site, and the requests in every bucket of the window.
/ analytics. v1. Analytics/ GetProxyRequestSummaryRequest body
application/jsonRequired
Request for the figures and the chart over the same rows ListProxyRequests lists, over a window of the last 6 hours at most.
bucketWidth?stringWidth of the chart's buckets. Unspecified picks one minute for a window of up to an hour, five minutes up to two hours, and fifteen minutes beyond.
Value in"PROXY_"PROXY_"PROXY_
filter?ProxyRequestFilterThe window and which rows to count, the same filter as the list.
Show attributes
accountName?stringSteam account name, matched exactly.
destination?stringDestination, matched exactly: a host for a request (with its port only when it is not the usual one), a host and port or an address and port for a connection.
kind?stringRequests only or connections only. Absent covers both.
Value in"PROXY_"PROXY_
poolId?stringOpaque 16-byte identifier of a pool, base64-encoded in JSON.
Format"byte" base64
providerId?stringOpaque 16-byte identifier of a provider, base64-encoded in JSON.
Format"byte" base64
result?stringSucceeded only or failed only. Absent covers both.
Value in"PROXY_"PROXY_
search?stringText the account name, the destination or the path contains, ignoring case. Absent or empty matches every row.
sessionId?stringOpaque 16-byte identifier of one proxy (the proxies service's session), base64-encoded in JSON.
Format"byte" base64
startedBefore?stringExclusive end of the window. Absent means the time of the request. A list's later pages keep the end of its first page, so they never shift. Send the same explicit window to the list and the summary to have both count the same rows.
Format"date-time"
startedFrom?stringInclusive start of the window. Absent means 6 hours before started_before. A start more than 6 hours ago is rejected with invalid_argument: older rows are kept only to rebuild the rollup.
Format"date-time"
Response body
application/json
Success
averageTimings?ProxyRequestTimingsAverage split of the window's successful timed requests into our side, the proxy and the site (only ours, proxy, site and unmeasured are set). Absent when no request in the window was timed.
Show attributes
connectionWait?stringWaiting for a connection, or for an idle one to be handed over. Our side.
download?stringDownloading the response, from its first byte to its end. The site.
firstByteWait?stringWaiting for the site's first byte. The site.
ours?stringOur side: connection_wait.
proxy?stringThe proxy: proxy_lookup, proxy_connect, proxy_sign_in and proxy_tunnel.
proxyConnect?stringConnecting to the proxy itself (its name looked up when given by name, and the TCP connect). The proxy.
proxyLookup?stringLooking up the proxy's own name, when it is given by name (a provider's gateway). Absent when the proxy is given by address. When present, proxy_connect is the TCP connect alone. The proxy.
proxySignIn?stringSigning in to a SOCKS5 proxy: the greeting and the username and password exchange. Absent for an HTTP CONNECT proxy, whose credentials travel with its connect request, and for rows recorded before 13 November 2026. When present, proxy_tunnel is the proxy reaching the site alone. The proxy.
proxyTunnel?stringThe proxy connecting to the site: the CONNECT or SOCKS5 handshake, which includes the proxy's own lookup of the site's name. The proxy.
requestWrite?stringSending the request. The site.
site?stringThe site: tls_handshake, request_write, first_byte_wait and download.
tlsHandshake?stringThe TLS handshake with the site through the proxy. The site.
unmeasured?stringThe rest of the whole duration that no phase covers (reading the response headers, scheduling). Absent when the phases cover it.
buckets?array<ProxyRequestBucket>Every bucket of the window in time order, including empty ones.
Show attributes
bytesIn?stringBytes received in the bucket, a connection's counted when reported.
Format"int64"
bytesOut?stringBytes sent in the bucket, a connection's counted when reported.
Format"int64"
connectionCount?stringConnection dials that started in the bucket, apart from request_count.
Format"int64"
failedConnectionCount?stringOf those, the ones that failed to open.
Format"int64"
failedRequestCount?stringOf those, the ones that failed.
Format"int64"
medianDuration?stringMedian whole duration of the bucket's successful requests (approximate). Absent with none.
requestCount?stringRequests that started in the bucket, not counting connection dials.
Format"int64"
startedAt?stringStart of the bucket, on a multiple of its width in UTC.
Format"date-time"
bytesIn?stringBytes received in the window.
Format"int64"
bytesOut?stringBytes sent in the window.
Format"int64"
connectionCount?stringConnection dials that started in the window.
Format"int64"
failedConnectionCount?stringOf those, the ones that failed to open.
Format"int64"
failedRequestCount?stringOf those, the ones that failed.
Format"int64"
medianDuration?stringMedian whole duration of the window's successful requests (approximate). Absent with none.
openConnectionCount?stringConnections open now under the filter's provider, pool, proxy, account, destination and search, whenever they opened: reported within the last 10 minutes and not closed.
Format"int64"
p95Duration?string95th percentile of the same (approximate). Absent with none.
requestCount?stringRequests that started in the window.
Format"int64"
windowEnd?stringExclusive end of the window read.
Format"date-time"
windowStart?stringInclusive start of the window read.
Format"date-time"
application/json
The request was malformed, such as a missing required field or an unparseable cursor.
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
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.
curl -X POST "https://api.goldmine.to/analytics.v1.Analytics/GetProxyRequestSummary" \
-H "Authorization: Bearer $CSTRADER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"filter": {
"startedFrom": "2026-11-12T18:00:00Z",
"startedBefore": "2026-11-12T18:30:00Z",
"poolId": "AZrEoUhh/X+4C3EJAhYjqg=="
},
"bucketWidth": "PROXY_REQUEST_BUCKET_WIDTH_FIFTEEN_MINUTES"
}'const res = await fetch("https://api.goldmine.to/analytics.v1.Analytics/GetProxyRequestSummary", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.CSTRADER_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"filter": {
"startedFrom": "2026-11-12T18:00:00Z",
"startedBefore": "2026-11-12T18:30:00Z",
"poolId": "AZrEoUhh/X+4C3EJAhYjqg=="
},
"bucketWidth": "PROXY_REQUEST_BUCKET_WIDTH_FIFTEEN_MINUTES"
}),
});
const data = await res.json();body := strings.NewReader(`{
"filter": {
"startedFrom": "2026-11-12T18:00:00Z",
"startedBefore": "2026-11-12T18:30:00Z",
"poolId": "AZrEoUhh/X+4C3EJAhYjqg=="
},
"bucketWidth": "PROXY_REQUEST_BUCKET_WIDTH_FIFTEEN_MINUTES"
}`)
req, err := http.NewRequestWithContext(ctx, http.MethodPost, "https://api.goldmine.to/analytics.v1.Analytics/GetProxyRequestSummary", 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/analytics.v1.Analytics/GetProxyRequestSummary",
headers={"Authorization": f"Bearer {os.environ['CSTRADER_API_KEY']}"},
json={
"filter": {
"startedFrom": "2026-11-12T18:00:00Z",
"startedBefore": "2026-11-12T18:30:00Z",
"poolId": "AZrEoUhh/X+4C3EJAhYjqg=="
},
"bucketWidth": "PROXY_REQUEST_BUCKET_WIDTH_FIFTEEN_MINUTES"
},
)
data = res.json(){
"windowStart": "2026-11-12T18:00:00Z",
"windowEnd": "2026-11-12T18:30:00Z",
"requestCount": "200",
"failedRequestCount": "5",
"connectionCount": "4",
"openConnectionCount": "4",
"medianDuration": "0.270s",
"p95Duration": "0.910s",
"bytesOut": "412000",
"bytesIn": "6200000",
"buckets": [
{
"startedAt": "2026-11-12T18:00:00Z",
"requestCount": "96",
"failedCount": "2",
"bytesOut": "200000",
"bytesIn": "3000000"
},
{
"startedAt": "2026-11-12T18:15:00Z",
"requestCount": "108",
"failedCount": "3",
"bytesOut": "212000",
"bytesIn": "3200000"
}
],
"averageTimings": {
"ours": "0.001s",
"proxy": "0.020s",
"site": "0.240s"
}
}{
"code": "invalid_argument",
"message": "The request was malformed, such as a missing required field or an unparseable cursor."
}{
"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": "internal",
"message": "An internal server error occurred."
}