---
title: Guardrail object
url: https://runapi.ai/docs/api/management/guardrails/object.md
canonical: https://runapi.ai/docs/api/management/guardrails/object
locale: en
---

# Guardrail object

A reusable policy with model, provider, and spending controls.

## Object fields

Stable fields shared by the resource's reusable object.

### Guardrails

```json
{
  "allowed_models": {
    "description": "Allowed model identifiers.",
    "required": true,
    "type": "array"
  },
  "allowed_providers": {
    "description": "Allowed provider names.",
    "required": true,
    "type": "array"
  },
  "assignment_count": {
    "description": "Number of API keys or members assigned this guardrail.",
    "required": true,
    "type": "integer"
  },
  "blocked_models": {
    "description": "Blocked model identifiers.",
    "required": true,
    "type": "array"
  },
  "blocked_providers": {
    "description": "Blocked provider names.",
    "required": true,
    "type": "array"
  },
  "created_at": {
    "description": "Time the guardrail was created.",
    "required": true,
    "type": "string"
  },
  "credit_limit_cents": {
    "description": "Optional total spending cap in USD cents.",
    "required": true,
    "type": "integer | null"
  },
  "credit_limit_reset_interval": {
    "description": "Reset cadence for the total spending cap.",
    "enum": [
      "daily",
      "weekly",
      "monthly",
      null
    ],
    "required": true,
    "type": "string | null"
  },
  "description": {
    "description": "Optional guardrail description.",
    "required": true,
    "type": "string | null"
  },
  "enabled": {
    "description": "Whether the guardrail is enforced.",
    "required": true,
    "type": "boolean"
  },
  "id": {
    "description": "Guardrail prefix ID.",
    "required": true,
    "type": "string"
  },
  "model_budgets": {
    "description": "Per-model budget rules.",
    "required": true,
    "type": "array"
  },
  "name": {
    "description": "Guardrail name.",
    "required": true,
    "type": "string"
  }
}
```

## Related reference

- [Guardrails](/docs/api/management/guardrails)
- [List guardrails](/docs/api/management/guardrails/list)
- [Retrieve a guardrail](/docs/api/management/guardrails/retrieve)
- [Create a guardrail](/docs/api/management/guardrails/create)
- [Update a guardrail](/docs/api/management/guardrails/update)
- [Delete a guardrail](/docs/api/management/guardrails/delete)
