API SpecificationFunctions
Get function stats
Reads traffic, errors, latency and cold starts, rolled up into the step requested. Counters are stored in five-minute buckets and kept for fourteen days.
Authorization
BearerAuth AuthorizationBearer <token>
A team API token, created by a team owner and presented as
Authorization: Bearer fnt_…. The secret is shown once at creation and
stored only as a hash.
In: header
Header Parameters
Connect-Protocol-Version*number
Define the version of the Connect protocol
Value in
1Connect-Timeout-Ms?number
Define the timeout, in ms
Request Body
application/json
functionId?string
rangeSec?integer|string
range_sec is how far back to read; 24 hours by default, 14 days at most.
Format
int64stepSec?integer|string
step_sec is the rollup width. Raised to the five-minute storage resolution when finer, and coarsened so at most 500 points are returned.
Format
int64[key: string]?never
Response Body
application/json
application/json
curl -X POST "https://functions.xeonr.io/xeonr.functions.v1.FunctionService/GetFunctionStats" \ -H "Connect-Protocol-Version: 1" \ -H "Content-Type: application/json" \ -d '{}'{
"series": [
{
"startUnix": 0,
"requests": 0,
"errors4xx": 0,
"errors5xx": 0,
"coldStarts": 0,
"p50Ms": 0,
"p95Ms": 0
}
]
}{
"code": "not_found",
"message": "string",
"details": [
{
"type": "string",
"value": "string",
"debug": {}
}
]
}