---
title: Get Spend Limit
url: https://platform.claude.com/docs/en/api/php/beta/organization/spend_limits/retrieve
---

# Get Spend Limit

`$client->beta->organization->spendLimits->retrieve(string spendLimitID): SpendLimit`

**GET** `/v1/organizations/spend_limits/{spend_limit_id}`

Retrieve a spend limit by ID.

## Parameters

- `spendLimitID: string` (path parameter)

  ID of the Spend Limit.

## Returns

- `class SpendLimit`

  - `"spend_limit" type`

    Object type. Always `spend_limit`.

  - `string id`

    Unique tagged ID of the spend limit (`spl_...`).

  - `?string amount`

    Limit amount as a non-negative integer decimal string in the minor unit of `currency` (cents for USD): "50000" is $500.00. `null` means no numeric cap is configured at this scope — see the effective report for whether a limit applies.

  - `\Datetime createdAt`

    RFC 3339 datetime at which the spend limit was created.

  - `string currency`

    ISO 4217 code of the organization's billing currency; the unit for `amount`.

  - `bool isEnabled`

    Read-only. `false` when extra usage is switched off for this organization (`organization` limit); `amount` is kept and applies again when it's switched back on. Always `true` for other limits.

  - `SpendLimitPeriod period`

    Length of the window the limit resets over. `amount` caps spend within each period.

  - `Scope scope`

    What the limit applies to. A tagged union on `type`; each variant carries the identifier for its scope.

  - `\Datetime updatedAt`

    RFC 3339 datetime at which the spend limit was last modified.

## Example

```php
<?php

require_once dirname(__DIR__) . '/vendor/autoload.php';

use Anthropic\Client;

$client = new Client(apiKey: 'my-anthropic-api-key');

$betaSpendLimit = $client->beta->organization->spendLimits->retrieve(
  'spend_limit_id'
);

var_dump($betaSpendLimit);
```

### Response (200)

```json
{
  "id": "id",
  "amount": "50000",
  "created_at": "2019-12-27T18:11:19.117Z",
  "currency": "USD",
  "is_enabled": true,
  "period": "daily",
  "scope": {
    "type": "user",
    "user_id": "user_01WCz1FkmYMm4gnmykNKUu3Q"
  },
  "type": "spend_limit",
  "updated_at": "2019-12-27T18:11:19.117Z"
}
```
