GET /billing/usage
Updated Oct 1, 20261 minute read
Read usage history
AI, email and scraping usage. One USD is 1,000,000 integer microcredits. Only customer charges and neutral labels are returned. Maximum date range is 366 days. Follow every cursor for complete history.
Part of Billing.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
from | query | number | No | Inclusive Unix timestamp in milliseconds; defaults to 30 days before the end. |
to | query | number | No | Inclusive Unix timestamp in milliseconds; defaults to now. |
limit | query | integer | No | Records per page. |
cursor | query | string | No | Continuation cursor. An empty filtered page may still have a continuation. |
Responses
| Status | Description |
|---|---|
200 | Local organization records. |
401 | Invalid or missing credentials. |
403 | The authenticated role cannot read these records. |
429 | Shared organization API allowance or temporary fair-use protection reached. Retry-After states the delay. |
200 body
| Field | Type | Required | Description |
|---|---|---|---|
page | object[] | Yes | |
isDone | boolean | Yes | |
continueCursor | string | Yes |
Example request
curl https://api.median.sh/v1/billing/usage \
-H "Authorization: Bearer $BEARER_AUTH"