Create a guardrail

Create a new guardrail for the authenticated user.

Authentication

AuthorizationBearer
API key as bearer token in Authorization header

Request

This endpoint expects an object.
namestringRequired1-200 characters
Name for the new guardrail
descriptionstring or nullOptional<=1000 characters
Description of the guardrail
limit_usddouble or nullOptional>=0
Spending limit in USD
reset_intervalenum or nullOptional

Interval at which the limit resets (daily, weekly, monthly)

Allowed values:
allowed_providerslist of strings or nullOptional
List of allowed provider IDs
allowed_modelslist of strings or nullOptional

Array of model identifiers (slug or canonical_slug accepted)

enforce_zdrboolean or nullOptional
Whether to enforce zero data retention

Response

Guardrail created successfully
dataobject
The created guardrail

Errors