comecerodocs

Get a customer's usage this period

GET
/customers/{customer_id}/usage

Used, included and percent on each of the customer's plans billed by use. No prices. A shopper's token reads only its own customer (me works). With usage billing turned off, data is empty. Here customer_id is the Comecero customer id, not your own id. Kept for 5 minutes.

Authorization

headerAuthorizationBearer <token>

A secret, trusted or limited token. See Authentication.

Path Parameters

customer_id*string

The Comecero customer id, or me.

Response Body

Success.

application/json
  1. response
object?string

Always list.

data?array<>

One entry per active agreement: subscription_id, period_start, period_end, as_of, and metrics with metric_name, unit_label, used, included, percent. No prices.

Example Request
curl -X GET 'https://api.comecero.com/api/v1/customers/string/usage'
Example Response
{  "object": "list",  "data": [    {      "object": "customer_usage",      "subscription_id": "SB0123456789",      "period_start": "2026-11-01T00:00:00Z",      "period_end": "2026-12-01T00:00:00Z",      "as_of": "2026-11-12T10:00:00Z",      "metrics": [        {          "metric_name": "AI tokens",          "unit_label": "token",          "used": 830000,          "included": 1000000,          "percent": 83        }      ]    }  ]}