A valid request URL is required to generate request examples{
"balances": [
{
"feature_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"feature_key": "<string>",
"feature_name": "<string>",
"unit_name": "<string>",
"balance": 123
}
],
"entries": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"feature_key": "<string>",
"kind": "grant",
"amount": 123,
"source": "<string>",
"expires_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"actor_user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
]
}{
"error": {
"code": "forbidden",
"message": "your role does not allow this action"
}
}{
"error": {
"code": "forbidden",
"message": "your role does not allow this action"
}
}{
"error": {
"code": "forbidden",
"message": "your role does not allow this action"
}
}{
"error": {
"code": "forbidden",
"message": "your role does not allow this action"
}
}Read one customer's credit statement
Requires billing:read. The support view of one customer’s credit balances and the ledger behind them — the same fold POST /v1/usage spends against and GET /v1/customers/{id}/credits answers your backend with.
This view alone carries actor_user_id on each line: “who moved this balance” is the support question the screen exists for, and it is staff material — the machine and contact reads leave it out.
A valid request URL is required to generate request examples{
"balances": [
{
"feature_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"feature_key": "<string>",
"feature_name": "<string>",
"unit_name": "<string>",
"balance": 123
}
],
"entries": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"feature_key": "<string>",
"kind": "grant",
"amount": 123,
"source": "<string>",
"expires_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"actor_user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
]
}{
"error": {
"code": "forbidden",
"message": "your role does not allow this action"
}
}{
"error": {
"code": "forbidden",
"message": "your role does not allow this action"
}
}{
"error": {
"code": "forbidden",
"message": "your role does not allow this action"
}
}{
"error": {
"code": "forbidden",
"message": "your role does not allow this action"
}
}Authorizations
A staff session token, uk_st_…. Minted by sign-up, sign-in or the two-factor exchange. Only a 401 means it is spent; not_a_member (403) is about the organization named in X-Organization-Id and leaves the token good for the others.
Headers
The organization the caller is acting on — the org_… code that appears in the panel URL. It identifies; the membership JOIN is what authorizes, so a forged code reads nothing: the answer is not_a_member (403), which does not mean the session is over. Absent, the session's default organization answers, or — if that membership was revoked while the session was open — any other one the caller still holds.
Path Parameters
The customer, resolved inside the environment above. An id from the other environment answers 404.
Query Parameters
Which environment to act in. A view parameter, valid only on the staff surface — a machine credential never chooses its environment, it is resolved from the key.
live, test Statement lines per page.
x <= 200Statement lines to skip.