---
title: "Get Billing State"
method: GET
path: "/api/billing/state"
tags: ["billing"]
---

# Get Billing State

`GET /api/billing/state`

Snapshot of plan + current-period usage for the dashboard.

## Response `200`

Successful Response

- BillingStateResponse
  - `plan_tier` string, required
  - `subscription_status` string, required
  - `pro_enabled` boolean, required
  - `can_manage_billing` boolean, required
  - `monthly_price_cents` integer, required
  - `monthly_mb_included` integer, required
  - `overage_per_gb_cents` integer, required
  - `used_bytes` integer, required
  - `period_start` string, date-time, nullable, required
  - `period_end` string, date-time, nullable, required
  - `trial_ends_at` string, date-time, nullable, required
  - `cancel_at_period_end` boolean, required
  - `has_subscription` boolean
  - `has_customer` boolean
  - `refund_window_ends_at` string, date-time, nullable
  - `refund_eligible` boolean
  - `is_payg` boolean
  - `credit_balance_bytes` integer
  - `credit_balance_credits` number
  - `free_grant_credits` integer
  - `credit_price_cents` integer
  - `bytes_per_credit` integer
  - `payg_out_of_credits_mode` string
  - `credit_pack_presets` integer[]

## Changes

- **2026-08-20** `a4b69f6d2450` — 8 info
  - added the optional property `bytes_per_credit` to the response with the `200` status
  - added the optional property `credit_balance_bytes` to the response with the `200` status
  - added the optional property `credit_balance_credits` to the response with the `200` status
  - added the optional property `credit_pack_presets` to the response with the `200` status
  - …4 more
- **2026-08-18** `64da737bcc9e` — 4 info
  - added the optional property `has_customer` to the response with the `200` status
  - added the optional property `has_subscription` to the response with the `200` status
  - added the optional property `refund_eligible` to the response with the `200` status
  - added the optional property `refund_window_ends_at` to the response with the `200` status
- **2026-08-16** `44d8ea826f48` — 2 warning
  - removed the optional property `has_customer` from the response with the `200` status
  - removed the optional property `has_subscription` from the response with the `200` status
- **2026-08-13** `d80008a9efc6` — 2 info
  - added the optional property `has_customer` to the response with the `200` status
  - added the optional property `has_subscription` to the response with the `200` status
- **2026-08-12** `8540ec6c1778` — 2 warning
  - removed the optional property `has_customer` from the response with the `200` status
  - removed the optional property `has_subscription` from the response with the `200` status

[Change history](https://skmtc.dev/codag/apis/infra-logs-templater/changes/api/billing/state/get.md)

---

[API](https://skmtc.dev/codag/apis/infra-logs-templater.md) · [All operations](https://skmtc.dev/codag/apis/infra-logs-templater/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/codag/infra-logs-templater/revisions/a4b69f6d2450/schema)
