---
title: "Get usage summary for a billing period"
method: GET
path: "/v1/accounts/{id}/usage"
tags: ["Accounts"]
---

# Get usage summary for a billing period

`GET /v1/accounts/{id}/usage`

## Request

- Base URL: `https://api.honkio.ca`
- URL: `https://api.honkio.ca/v1/accounts/{id}/usage`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-API-Key`

Message counts, billed cost and segments for the period (defaults to the current calendar month), plus live delivery health: "delivery" { liveOutbound, delivered, failed, undelivered, pending, failureRatePct } over live outbound messages (auto-replies excluded) and "byNumber", the same figures per sending number, busiest first. A rising failureRatePct usually means wrong numbers, landlines, or a script retrying one recipient; above 10 % over your last 50 sends you are emailed and account.delivery_warning fires.

Requires `account:r`.

## Path parameters

- `id` string, required

## Query parameters

- `from` string, date
- `to` string, date

## Response `200`

Usage for the period. Field names are camelCase, unlike the rest of the API.

- object: Usage for the period. Field names are camelCase, unlike the rest of the API.
  - `totalMessages` integer, required: Every message in the period, inbound and test-mode included.
  - `testMessages` integer, required: How many of totalMessages were test-mode simulations, billed nothing.
  - `outboundMessages` integer, required
  - `inboundMessages` integer, required
  - `totalCostCents` integer, required: What LIVE messages cost, in CAD cents.
  - `segmentCount` integer, required: LIVE SMS parts billed.
  - `delivery` object, required
    - `liveOutbound` integer, required
    - `delivered` integer, required
    - `failed` integer, required
    - `undelivered` integer, required
    - `pending` integer, required: Accepted, no verdict from the carrier yet.
    - `failureRatePct` number, required: (failed + undelivered) / liveOutbound x 100, one decimal; 0 with no traffic.
  - `byNumber` object[], required: The same delivery figures per sending number, busiest first.
    - `from` string, required
    - `liveOutbound` integer, required
    - `delivered` integer, required
    - `failed` integer, required
    - `undelivered` integer, required
    - `failureRatePct` number, required
  - `period` object, required
    - `from` string, date-time, required
    - `to` string, date-time, required: Exclusive end of the period.

## Other responses

- `401`: Missing, invalid, revoked or expired API key.
- `402`: The account has no balance, or a LIVE key was used before the first top-up.
- `403`: FORBIDDEN: the id is not the calling key's account, or the key lacks the permission this operation requires.
- `422`: VALIDATION_ERROR: a malformed date, or to before from.
- `429`: Rate limit reached: 100 requests per second per account, or a route-specific limit (Retry-After set where one applies).
- `500`: Unexpected server error.

---

[API](https://skmtc.dev/honkio/apis/honkio-api.md) · [All operations](https://skmtc.dev/honkio/apis/honkio-api/llms.txt) · [OpenAPI document](https://skmtc.dev/honkio/apis/honkio-api/revisions/ce4ed3fe9691?raw)
