---
title: "getOrgUsage"
---

> Documentation Index
> Fetch the complete documentation index at: https://buildrforge.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# getOrgUsage

Path: Forge API › billing

`GET /orgs/{org_id}/usage`

Read the org's usage this month against what its plan includes: the compute runs started since the 1st, UTC, each a sandbox start for a tool call, a workflow run, a webhook's or mailbox's handler, or a custom CI check, and when the count resets. A run past the plan's runs is refused with ComputeLimitReached. Also the AI and browser use, in millionths of a US dollar: each System One answer's input tokens and each browser's running time, at twice what they cost Forge. Once it reaches what the plan includes, System One requests and new browsers are refused with AiBrowserLimitReached. And the bytes the org's repos store, their attachments and databases, as each repo last reported them a few minutes after it changed; storage never resets, and an attachment upload that would pass the plan's storage is refused with StorageLimitReached. Takes readBilling on the org.

## Path parameters

- `org_id` (`getOrgUsage.path.org_id`; string, required)
  - pattern: `^org_[0-7][0-9a-hjkmnp-tv-z]{25}$`

## Code samples

### cURL

```bash
curl --request GET \
  --url '<base-url>/orgs/<org_id>/usage'
```

### TypeScript

```typescript
const url = '<base-url>/orgs/<org_id>/usage';
const options = {method: 'GET'};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "<base-url>/orgs/<org_id>/usage"

response = requests.get(url)

print(response.text)
```

## Responses

### 200

OrgUsage

#### Example

```json
{
  "plan": "free",
  "unlimited": true,
  "resets_at": "string",
  "compute_runs": {
    "used": -9007199254740991,
    "included": -9007199254740991
  },
  "ai_browser_microdollars": {
    "used": -9007199254740991,
    "included": -9007199254740991
  },
  "storage_bytes": {
    "used": -9007199254740991,
    "included": -9007199254740991
  }
}
```

- `plan` (`getOrgUsage.response.200.plan`; string, required)
  - one of `"free"`, `"pro"`, `"team"`
- `unlimited` (`getOrgUsage.response.200.unlimited`; boolean, required)
- `resets_at` (`getOrgUsage.response.200.resets_at`; string, required)
- `compute_runs` (`getOrgUsage.response.200.compute_runs`; object, required)
  - `used` (`getOrgUsage.response.200.compute_runs.used`; integer, required)
    - maximum: `9007199254740991` · minimum: `-9007199254740991`
  - `included` (`getOrgUsage.response.200.compute_runs.included`; integer, required)
    - maximum: `9007199254740991` · minimum: `-9007199254740991`
- `ai_browser_microdollars` (`getOrgUsage.response.200.ai_browser_microdollars`; object, required)
  - `used` (`getOrgUsage.response.200.ai_browser_microdollars.used`; integer, required)
    - maximum: `9007199254740991` · minimum: `-9007199254740991`
  - `included` (`getOrgUsage.response.200.ai_browser_microdollars.included`; integer, required)
    - maximum: `9007199254740991` · minimum: `-9007199254740991`
- `storage_bytes` (`getOrgUsage.response.200.storage_bytes`; object, required)
  - `used` (`getOrgUsage.response.200.storage_bytes.used`; integer, required)
    - maximum: `9007199254740991` · minimum: `-9007199254740991`
  - `included` (`getOrgUsage.response.200.storage_bytes.included`; integer, required)
    - maximum: `9007199254740991` · minimum: `-9007199254740991`

### 400

InvalidRequest

#### Example

```json
{
  "_tag": "InvalidRequest",
  "part": "path",
  "issues": [
    {
      "path": [
        "string"
      ],
      "message": "string"
    }
  ]
}
```

- `_tag` (`getOrgUsage.response.400._tag`; string, required)
  - one of `"InvalidRequest"`
- `part` (`getOrgUsage.response.400.part`; string, required)
  - one of `"path"`, `"query"`, `"headers"`, `"body"`
- `issues` (`getOrgUsage.response.400.issues`; array of object, required)
  - `path` (`getOrgUsage.response.400.issues.path`; array\<any of\>, required)
    - any of the following: `string`, `integer`
  - `message` (`getOrgUsage.response.400.issues.message`; string, required)

### 401

InvalidCredentials

#### Example

```json
{
  "_tag": "InvalidCredentials"
}
```

- `_tag` (`getOrgUsage.response.401._tag`; string, required)
  - one of `"InvalidCredentials"`

### 403

Forbidden | ForbiddenOrigin | RequiresPersonalSession | RunBranchRequired

#### Example

```json
{
  "_tag": "Forbidden",
  "message": "string"
}
```

Any of the following:

- `ForbiddenEncoded`
  - `_tag` (`ForbiddenEncoded._tag`; string, required)
    - one of `"Forbidden"`
  - `message` (`ForbiddenEncoded.message`; string, required)
- `ForbiddenOriginEncoded`
  - `_tag` (`ForbiddenOriginEncoded._tag`; string, required)
    - one of `"ForbiddenOrigin"`
- `RequiresPersonalSessionEncoded`
  - `_tag` (`RequiresPersonalSessionEncoded._tag`; string, required)
    - one of `"RequiresPersonalSession"`
- `RunBranchRequiredEncoded`
  - `_tag` (`RunBranchRequiredEncoded._tag`; string, required)
    - one of `"RunBranchRequired"`
  - `branch` (`RunBranchRequiredEncoded.branch`; string, required)
    - minLength: `1`
  - `message` (`RunBranchRequiredEncoded.message`; string, required)

### 404

OrgNotFound

#### Example

```json
{
  "_tag": "OrgNotFound"
}
```

- `_tag` (`getOrgUsage.response.404._tag`; string, required)
  - one of `"OrgNotFound"`

### 429

RateLimited

#### Example

```json
{
  "_tag": "RateLimited"
}
```

- `_tag` (`getOrgUsage.response.429._tag`; string, required)
  - one of `"RateLimited"`

### 500

OrgFailure

#### Example

```json
{
  "_tag": "OrgFailure",
  "reason": "string"
}
```

- `_tag` (`getOrgUsage.response.500._tag`; string, required)
  - one of `"OrgFailure"`
- `reason` (`getOrgUsage.response.500.reason`; string, required)

### 503

SessionUnavailable | RateLimitUnavailable

#### Example

```json
{
  "_tag": "SessionUnavailable"
}
```

Any of the following:

- `SessionUnavailableEncoded`
  - `_tag` (`SessionUnavailableEncoded._tag`; string, required)
    - one of `"SessionUnavailable"`
- `RateLimitUnavailableEncoded`
  - `_tag` (`RateLimitUnavailableEncoded._tag`; string, required)
    - one of `"RateLimitUnavailable"`


Source: https://buildrforge.com/docs/api/get-org-usage/index.md
