---
title: "Get Token Costs"
method: GET
path: "/api/keys/token-costs"
tags: ["api-keys"]
---

# Get Token Costs

`GET /api/keys/token-costs`

## Request

- Base URL: `https://api.halalterminal.com`
- URL: `https://api.halalterminal.com/api/keys/token-costs`
- Auth: none required

Return the full token cost table.

Lists every endpoint pattern and how many tokens each request costs.
Use this to estimate usage before making API calls. No authentication
required.

**curl example**:
```bash
curl https://api.halalterminal.com/api/keys/token-costs
```

**Python example**:
```python
import requests

resp = requests.get("https://api.halalterminal.com/api/keys/token-costs")
for cost in resp.json()["costs"]:
    print(f"{cost['pattern']} ({cost['method']}): {cost['tokens']} tokens")
```

## Response `200`

Token cost table for all endpoint categories

- TokenCostsResponse: Full token cost table.
  - `costs` TokenCostEntry[], required: Token costs per endpoint
    - `pattern` string, required: Endpoint path pattern
    - `method` string, required: HTTP method (* = all methods)
    - `tokens` integer, required: Token cost per request

---

[API](https://skmtc.dev/halalterminal/apis/halal-terminal-api.md) · [All operations](https://skmtc.dev/halalterminal/apis/halal-terminal-api/llms.txt) · [OpenAPI document](https://skmtc.dev/halalterminal/apis/halal-terminal-api/revisions/78768b250943?raw)
