CreateGuardrailRequest - Go SDK
CreateGuardrailRequest type definition
The Go SDK and docs are currently in beta. Report issues on GitHub.
Fields
| Field | Type | Required | Description | Example |
|---|---|---|---|---|
Name | string | ✔️ | Name for the new guardrail | My New Guardrail |
Description | optionalnullable.OptionalNullable[string] | ➖ | Description of the guardrail | A guardrail for limiting API usage |
LimitUsd | *float64 | ➖ | Spending limit in USD | 50 |
ResetInterval | optionalnullable.OptionalNullable[components.GuardrailInterval] | ➖ | Interval at which the limit resets (daily, weekly, monthly) | monthly |
AllowedProviders | optionalnullable.OptionalNullable[[]string] | ➖ | List of allowed provider IDs | [ “openai”, “anthropic”, “deepseek” ] |
IgnoredProviders | optionalnullable.OptionalNullable[[]string] | ➖ | List of provider IDs to exclude from routing | [ “azure” ] |
AllowedModels | optionalnullable.OptionalNullable[[]string] | ➖ | Array of model identifiers (slug or canonical_slug accepted) | [ “openai/gpt-5.2”, “anthropic/claude-4.5-opus-20251124”, “deepseek/deepseek-r1-0528:free” ] |
EnforceZdr | optionalnullable.OptionalNullable[bool] | ➖ | Whether to enforce zero data retention | false |