Skip to main content
GET
/
deploy
/
{deploy_id}
/
stats
Deploy Stats
curl --request GET \
  --url https://api.example.com/deploy/{deploy_id}/stats \
  --header 'Authorization: Bearer <token>'
{
  "requests": 123,
  "total_time": 123,
  "total_tokens": 123,
  "input_tokens": 123,
  "output_tokens": 123,
  "total_amount": 123,
  "avg_time": 123,
  "avg95_time": 123,
  "errors": 123
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

xi-api-key
string | null

Path Parameters

deploy_id
string
required

Query Parameters

from
string
required

start of period, unix ts or 'now-5h', supported units s(ec), m(min), h(our), d(ay), w(eek), M(onth)

to
string
default:now

end of period, unix ts or now-relative, check from, defaults to now

Response

Successful Response

requests
integer
required

number of inference requests in the provided interval

total_time
integer
required

total number of seconds spend in inference

total_tokens
integer
required

total number of tokens generated

input_tokens
integer
required

number of input tokens generated

output_tokens
integer
required

number of output tokens generated

total_amount
integer
required

total number of cents spent

avg_time
number
required

average millisecond inference time

avg95_time
number
required

95th percentile inference time (estimated)

errors
integer
required

number of errors