---
title: "Get AI credit usage for an organization"
method: GET
path: "/api/{org_id}/ai/usage"
tags: ["AI"]
---

# Get AI credit usage for an organization

`GET /api/{org_id}/ai/usage`

## Request

- Base URL: `https://api.openobserve.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.openobserve.ai/api/{org_id}/ai/usage`
- Auth: API key in header `Authorization`
- TypeScript: <https://skmtc.dev/openobserve/apis/openobserve-api-http/docs/api/:org_id/ai/usage/get.ts> (a function with typed inputs; its response is checked against the schema)

Returns current AI credit usage, mode, and remaining credits.

## Path parameters

- `org_id` string, required

## Response `200`

Success

- AiUsageResponse: AI usage response for the API
  - `costs` AiCreditCosts, required: Credits per AI feature: the configured cost of one operation, or the credits it used.
    - `chat` integer, required
    - `incident` integer, required
    - `incident_reanalysis` integer, required
  - `credits_limit` integer, required
  - `credits_remaining` integer, required
  - `credits_used` integer, required
  - `mode` string, required
  - `payer_org_id` string, nullable: Set for a billing-group member, whose payer org holds the subscription.
  - `requires_additional_credits` boolean, required
  - `used_by_feature` AiCreditCosts: Credits per AI feature: the configured cost of one operation, or the credits it used.
    - `chat` integer, required
    - `incident` integer, required
    - `incident_reanalysis` integer, required

---

[API](https://skmtc.dev/openobserve/apis/openobserve-api-http.md) - [All operations](https://skmtc.dev/openobserve/apis/openobserve-api-http/llms.txt) - [OpenAPI document](https://skmtc.dev/openobserve/apis/openobserve-api-http/revisions/0529b8a10252?raw)
