---
title: "Set Access Group Budget"
method: PUT
path: "/access_group/{access_group}/budget"
tags: ["model management"]
---

# Set Access Group Budget

`PUT /access_group/{access_group}/budget`

Set or replace the shared budget of an access group. Idempotent.

Every key that can reach a model in the group draws from this one budget.

Example:
```bash
curl -X PUT 'http://localhost:4000/access_group/production-models/budget' \
  -H 'Authorization: Bearer sk-1234' \
  -H 'Content-Type: application/json' \
  -d '{
    "max_budget": 100.0,
    "budget_duration": "30d"
  }'
```

Parameters:
- access_group: str - The access group name (URL path parameter)
- max_budget: Optional[float] - Requests fail once the group's shared spend exceeds this
- soft_budget: Optional[float] - Fires an alert when reached; requests still succeed
- budget_duration: Optional[str] - Frequency of resetting the group's spend (e.g. '30d')
- budget_id: Optional[str] - Link an existing budget instead of creating one

Returns:
- AccessGroupBudgetResponse with the stored budget and current spend

Raises:
- HTTPException 400: If no budget field is given, or budget_duration cannot be parsed
- HTTPException 404: If access group not found

## Path parameters

- `access_group` string, required

## Request body

- AccessGroupBudgetRequest
  - `budget_id` string, nullable
  - `max_budget` number, nullable
  - `soft_budget` number, nullable
  - `budget_duration` string, nullable

## Response `200`

Successful Response

- AccessGroupBudgetResponse
  - `access_group` string, required
  - `spend` number, required
  - `budget` AccessGroupBudget
    - `budget_id` string, required
    - `max_budget` number, nullable
    - `soft_budget` number, nullable
    - `budget_duration` string, nullable
    - `budget_reset_at` string, date-time, nullable

## Other responses

- `422` — Validation Error

## Changes

- **2026-09-18** `082b5fabd909` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/flock/apis/litellm-api/changes/access_group/:access_group/budget/put.md)

---

[API](https://skmtc.dev/flock/apis/litellm-api.md) · [All operations](https://skmtc.dev/flock/apis/litellm-api/llms.txt) · [OpenAPI document](https://skmtc.dev/flock/apis/litellm-api/revisions/731afbea6a1b?raw)
