> ## Documentation Index
> Fetch the complete documentation index at: https://openrouter-d02e98a0-mintlify-7021d5f4.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# UpdateGuardrailRequest - Python SDK

> UpdateGuardrailRequest method reference

<Warning>
  The Python SDK and docs are currently in beta.
  Report issues on [GitHub](https://github.com/OpenRouterTeam/python-sdk/issues).
</Warning>

## Fields

| Field                     | Type                                                                                                                            | Required             | Description                                                                                                                                                                                                                                                                                                                                                                             | Example                                                               |
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------- |
| `allowed_models`          | List\[*str*]                                                                                                                    | :heavy\_minus\_sign: | Array of model identifiers (slug or canonical\_slug accepted)                                                                                                                                                                                                                                                                                                                           | \[<br />"openai/gpt-5.2"<br />]                                       |
| `allowed_providers`       | List\[*str*]                                                                                                                    | :heavy\_minus\_sign: | New list of allowed provider IDs                                                                                                                                                                                                                                                                                                                                                        | \[<br />"openai",<br />"anthropic",<br />"deepseek"<br />]            |
| `content_filter_builtins` | List\[[components.ContentFilterBuiltinEntryInput](/client-sdks/python/api-reference/components/contentfilterbuiltinentryinput)] | :heavy\_minus\_sign: | Builtin content filters to apply. Set to null to remove. The "flag" action is only supported for "regex-prompt-injection"; PII slugs (email, phone, ssn, credit-card, ip-address, person-name, address) accept "block" or "redact" only.                                                                                                                                                | \[<br />`{"action": "block","slug": "regex-prompt-injection"}`<br />] |
| `content_filters`         | List\[[components.ContentFilterEntry](/client-sdks/python/api-reference/components/contentfilterentry)]                         | :heavy\_minus\_sign: | Custom regex content filters to apply. Set to null to remove.                                                                                                                                                                                                                                                                                                                           | `<nil>`                                                               |
| `description`             | *OptionalNullable\[str]*                                                                                                        | :heavy\_minus\_sign: | New description for the guardrail                                                                                                                                                                                                                                                                                                                                                       | Updated description                                                   |
| ~~`enforce_zdr`~~         | *OptionalNullable\[bool]*                                                                                                       | :heavy\_minus\_sign: | : warning: \*\* DEPRECATED \*\*: This will be removed in a future release, please migrate away from it as soon as possible.<br /><br />Deprecated. Use enforce\_zdr\_anthropic, enforce\_zdr\_openai, enforce\_zdr\_google, and enforce\_zdr\_other instead. When provided, its value is copied into any of those per-provider fields that are not explicitly specified on the request. | true                                                                  |
| `enforce_zdr_anthropic`   | *OptionalNullable\[bool]*                                                                                                       | :heavy\_minus\_sign: | Whether to enforce zero data retention for Anthropic models. Falls back to enforce\_zdr when not provided.                                                                                                                                                                                                                                                                              | true                                                                  |
| `enforce_zdr_google`      | *OptionalNullable\[bool]*                                                                                                       | :heavy\_minus\_sign: | Whether to enforce zero data retention for Google models. Falls back to enforce\_zdr when not provided.                                                                                                                                                                                                                                                                                 | true                                                                  |
| `enforce_zdr_openai`      | *OptionalNullable\[bool]*                                                                                                       | :heavy\_minus\_sign: | Whether to enforce zero data retention for OpenAI models. Falls back to enforce\_zdr when not provided.                                                                                                                                                                                                                                                                                 | true                                                                  |
| `enforce_zdr_other`       | *OptionalNullable\[bool]*                                                                                                       | :heavy\_minus\_sign: | Whether to enforce zero data retention for models that are not from Anthropic, OpenAI, or Google. Falls back to enforce\_zdr when not provided.                                                                                                                                                                                                                                         | true                                                                  |
| `ignored_models`          | List\[*str*]                                                                                                                    | :heavy\_minus\_sign: | Array of model identifiers to exclude from routing (slug or canonical\_slug accepted)                                                                                                                                                                                                                                                                                                   | \[<br />"openai/gpt-4o-mini"<br />]                                   |
| `ignored_providers`       | List\[*str*]                                                                                                                    | :heavy\_minus\_sign: | List of provider IDs to exclude from routing                                                                                                                                                                                                                                                                                                                                            | \[<br />"azure"<br />]                                                |
| `limit_usd`               | *OptionalNullable\[float]*                                                                                                      | :heavy\_minus\_sign: | New spending limit in USD                                                                                                                                                                                                                                                                                                                                                               | 75                                                                    |
| `name`                    | *Optional\[str]*                                                                                                                | :heavy\_minus\_sign: | New name for the guardrail                                                                                                                                                                                                                                                                                                                                                              | Updated Guardrail Name                                                |
| `reset_interval`          | [OptionalNullable\[components.GuardrailInterval\]](../components/guardrailinterval.md)                                          | :heavy\_minus\_sign: | Interval at which the limit resets (daily, weekly, monthly)                                                                                                                                                                                                                                                                                                                             | monthly                                                               |
