## Reference: Platform

Pricing, spec, meta

**Availability: live** on `https://api.cardog.app`.

### GET /v2/account/usage

Your credits and usage *Since 2026-11-19.*

Your own plan, credits used this cycle, what is left of the allowance, usage by day, by family and by key over the last `days` days, and the next plan up. Costs 0 credits. A signed-in session reads its own account and a personal API key reads its owner's; there is no way to read anyone else's. An organization key or a server token has no personal account (403).

**Query parameters**

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `days` | integer | no | Trailing window in UTC days (1-90, default 14) |

**Response 200** `AccountUsage`: Your plan, this cycle's credits and the window's usage

- `plan` (object)
  - `plan.id` (string): The rate-card plan id, e.g. "free", "starter"
  - `plan.name` (string)
  - `plan.monthlyPrice` (number | null): USD a month; null = sales-led
  - `plan.allowance` (integer | null): Monthly credit allowance; null = custom
  - `plan.overageBilled` (boolean): true: usage past the allowance is billed, never blocked. false: a hard stop at the allowance.
  - `plan.overagePricePerCredit` (number | null)
- `cycle` (object)
  - `cycle.start` (string): ISO 8601: the start of this billing cycle (UTC month)
  - `cycle.reset` (string): ISO 8601: when the allowance resets; the value of X-Credits-Reset
- `credits` (object)
  - `credits.spent` (integer): Credits used this cycle, from every source (allowance, packs, overage)
  - `credits.allowanceRemaining` (integer | null): The value of X-Credits-Remaining; null on a custom allowance
  - `credits.percentUsed` (integer | null): Allowance used this cycle, 0-100+; null on a custom allowance
  - `credits.packs` (integer): Prepaid pack credits left
- `window` (object)
  - `window.start` (string)
  - `window.end` (string)
  - `window.days` (integer)
- `daily` (object[]): One entry per UTC day in the window, oldest first; a day with no calls is 0
  - `daily[].date` (string): UTC day, YYYY-MM-DD
  - `daily[].credits` (integer)
  - `daily[].requests` (integer)
- `families` (object[]): Usage in the window by family, most credits first
  - `families[].family` (string): The rate-card family (GET /v2/pricing), e.g. vin, recalls, listings
  - `families[].credits` (integer)
  - `families[].requests` (integer)
- `keys` (object[]): Usage in the window by API key, most credits first
  - `keys[].id` (string | null): API key id; null for a deleted key or a session read
  - `keys[].name` (string | null)
  - `keys[].start` (string | null): The first characters of the key as issued (e.g. crdg_a1); never the key
  - `keys[].credits` (integer)
- `nextPlan` (object | null): The plan above this one on the rate card; null at the top
  - `nextPlan.id` (string)
  - `nextPlan.name` (string)
  - `nextPlan.monthlyPrice` (number | null)
  - `nextPlan.allowance` (integer | null)
- `links` (object): `self`: this operation. `pricing`: the rate card.

**Errors** (all use the ErrorEnvelope): 400, 401, 403, 429, 500, 503

**Example: cURL**

```bash
curl "https://api.cardog.app/v2/account/usage" \
  -H "x-api-key: $CARDOG_API_KEY" \
  -H "Cardog-Version: 2026-10-26"
```

**Example: TypeScript** (`npm install @cardog/api`)

```typescript
import { CardogClient } from "@cardog/api";

const client = new CardogClient({ apiKey: process.env.CARDOG_API_KEY });

const accountUsage = await client.v2.platform.usage();
console.log(accountUsage.plan);
```

**Example: Python** (`pip install cardog`)

```python
import os

from cardog import Cardog

client = Cardog(api_key=os.environ["CARDOG_API_KEY"])

account_usage = client.v2.platform.usage()
print(account_usage.plan)
```

### GET /v2/changelog

What changed on the API *Since 2026-11-19.*

The changelog at cardog.app/changelog as data, newest first: each entry's date, the dated API version it ships in, whether it broke anything and when the old shape stops, the surfaces it touched, its page and the /docs pages it links to. Costs 0 credits. Filter with `since`, `tag` or `breaking`.

**Query parameters**

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `since` | string | no | Only entries published on or after this date (YYYY-MM-DD) |
| `tag` | string | no | Only entries carrying this tag, e.g. "recalls" |
| `breaking` | boolean | no | true: only entries that broke an existing consumer |
| `limit` | integer | no | Entries to return (1-50, default 10) |

**Response 200** `Changelog`: Entries, newest first

- `data` (object[]): Newest first
  - `data[].slug` (string): Permanent, date-prefixed
  - `data[].date` (string): Publish date, YYYY-MM-DD
  - `data[].version` (string | null): The dated API version the entry ships in (Cardog-Version); null before dated versions
  - `data[].title` (string)
  - `data[].description` (string)
  - `data[].tags` (string[])
  - `data[].breaking` (boolean)
  - `data[].sunset` (string | null): When the pre-change shape stops being served; set on every breaking entry
  - `data[].surfaces` (string[])
  - `data[].url` (string): The entry on cardog.app/changelog
  - `data[].docs` (string[]): The /docs pages the entry links to, as paths
- `total` (integer): Entries matching the filters, before the limit
- `links` (object): `self`: this operation. The page itself is https://cardog.app/changelog (markdown: /changelog.md).

**Errors** (all use the ErrorEnvelope): 400, 401, 429, 500

**Example: cURL**

```bash
curl "https://api.cardog.app/v2/changelog" \
  -H "x-api-key: $CARDOG_API_KEY" \
  -H "Cardog-Version: 2026-10-26"
```

**Example: TypeScript** (`npm install @cardog/api`)

```typescript
import { CardogClient } from "@cardog/api";

const client = new CardogClient({ apiKey: process.env.CARDOG_API_KEY });

const changelog = await client.v2.platform.changelog();
console.log(changelog.data);
```

**Example: Python** (`pip install cardog`)

```python
import os

from cardog import Cardog

client = Cardog(api_key=os.environ["CARDOG_API_KEY"])

changelog = client.v2.platform.changelog()
print(changelog.data)
```

### GET /v2/pricing

The machine-readable rate card *(no auth required)* *Since 2026-07-30.*

Credit rates per family + plan allowances, as JSON. Budget mid-task with this plus the X-Credits-* headers on every metered response. Unauthenticated.

**Response 200** `Pricing`: Rates, plans, credit headers

- `version` (integer): Monotonic rate-card version. Bump it on any price change.
- `asOf` (string): When this card took effect (ISO 8601)
- `currency` (string): ISO 4217, e.g. "USD"
- `rates` (object[]): Only ENFORCED rates appear
  - `rates[].family` (string): Billing family. The route groups (vin, entities, specs, listings, instruments, quotes, tape, recalls, safety, charging, parts, chassis, fuel, locations, feedback, documents, feeds, history, carriers, agent, account, changelog) plus composite products (open set).
  - `rates[].unit` (string): What one metered unit is: "request", "vin" (batch = N units), "check", "image" (one photo), "session", "thread" or "download".
  - `rates[].credits` (number): Credits debited per unit. 0 = unmetered class read.
  - `rates[].description`? (string)
  - `rates[].operations`? (object[]): The operations this line prices. A family can carry several lines (one per unit), and the line is identified by (family, unit); each (method, operationId) appears on exactly one line, so a caller resolves the request it is about to make to one price. HEAD appears only where it is priced apart from its GET.
    - `rates[].operations[].method` ("GET" | "HEAD" | "POST")
    - `rates[].operations[].operationId` (string): An operationId from GET /v2/openapi.json
- `plans` (object[])
  - `plans[].id` (string): Stable plan id, e.g. "free", "starter", "growth", "enterprise"
  - `plans[].name` (string)
  - `plans[].monthlyPrice` (number | null): Monthly base price in `currency`; null = sales-led (contact)
  - `plans[].monthlyCredits` (integer | null): The monthly credit allowance; null = custom (sales-led)
  - `plans[].overage` (object)
    - `plans[].overage.billed` (boolean): true = past-allowance usage is billed, not blocked; false = hard stop (free tier)
    - `plans[].overage.pricePerCredit` (number | null): Overage price per credit in `currency`; null when overage is not billed
  - `plans[].rateLimits`? (object)
    - `plans[].rateLimits.perMinute` (integer | null): Token-bucket rate; null = plan-custom
  - `plans[].selfServe` (boolean): true = instant key, no sales call
  - `plans[].requiresCard`? (boolean): false on the evaluation tier
  - `plans[].description`? (string)
- `packs`? (object[]): Prepaid one-time credit top-ups, all tiers (free included). Spend order per debit: allowance → packs (FIFO by purchase) → overage; packs expire 12 months after purchase.
  - `packs[].id` (string): Stable pack id, e.g. "pack-250"
  - `packs[].credits` (integer): Credits granted by one purchase
  - `packs[].price` (number): One-time price in `currency`
  - `packs[].description`? (string)
- `customTopUp`? (object): Caller-chosen top-up amount at a flat per-credit rate (no volume bonus); mechanics identical to packs.
  - `customTopUp.ratePerCredit` (number): Flat price per credit in `currency`; no volume bonus
  - `customTopUp.minCredits` (integer): Smallest purchasable amount
  - `customTopUp.maxCredits` (integer): Largest purchasable amount
  - `customTopUp.expiryMonths` (integer): Months from purchase until unspent credits expire
- `creditHeaders`? (string[]): The response headers that carry live budget state
- `signupGrant`? (object): Present only while a signup credit grant is running: new accounts created before `endsAt` receive `credits` prepaid credits. Absent when no campaign is open.
  - `signupGrant.credits` (integer): Credits granted to a new account
  - `signupGrant.endsAt` (string): The last moment a signup qualifies (ISO 8601)
  - `signupGrant.expiryMonths` (integer): Months until unspent granted credits expire
  - `signupGrant.description` (string): Human-readable offer, e.g. plan-equivalent framing
- `links`? (object): Related resources, keyed by relation name, each a server-relative path. Example: {"recalls": "/v2/recalls/entity/model-year:toyota/rav4/2021"}
- `docs_url`? (string)

**Errors** (all use the ErrorEnvelope): 429, 500

**Example: cURL**

```bash
curl "https://api.cardog.app/v2/pricing"
```

**Example: TypeScript** (`npm install @cardog/api`)

```typescript
import { CardogClient } from "@cardog/api";

const client = new CardogClient();

const pricing = await client.v2.platform.pricing();
console.log(pricing.version);
```

**Example: Python** (`pip install cardog`)

```python
from cardog import Cardog

client = Cardog()

pricing = client.v2.platform.pricing()
print(pricing.version)
```

### GET /v2/openapi.json

This document *(no auth required)* *Since 2026-07-30.*

**Response 200**: The OpenAPI 3.0 spec for the v2 surface

**Example: cURL**

```bash
curl "https://api.cardog.app/v2/openapi.json"
```

**Example: TypeScript** (`npm install @cardog/api`)

```typescript
import { CardogClient } from "@cardog/api";

const client = new CardogClient();

const result = await client.v2.platform.openapi();
```

**Example: Python** (`pip install cardog`)

```python
from cardog import Cardog

client = Cardog()

result = client.v2.platform.openapi()
```

---

Previous: [Charging](https://cardog.app/docs/reference/charging.md) (API reference)
Next: [Agent](https://cardog.app/docs/reference/agent.md) (API reference)
