{
  "properties": {
    "apiVersion": {
      "description": "APIVersion defines the versioned schema of this representation of an object.\nServers should convert recognized schemas to the latest internal value, and\nmay reject unrecognized values.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
      "type": "string"
    },
    "kind": {
      "description": "Kind is a string value representing the REST resource this object represents.\nServers may infer this from the endpoint the client submits requests to.\nCannot be updated.\nIn CamelCase.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
      "type": "string"
    },
    "metadata": {
      "type": "object"
    },
    "spec": {
      "description": "Desired backend configuration.",
      "properties": {
        "a2a": {
          "description": "A2A backend.",
          "properties": {
            "host": {
              "description": "Hostname or IP address of the A2A backend.",
              "maxLength": 256,
              "minLength": 1,
              "type": "string"
            },
            "port": {
              "description": "Port number of the A2A backend.",
              "format": "int32",
              "maximum": 65535,
              "minimum": 1,
              "type": "integer"
            }
          },
          "required": [
            "host",
            "port"
          ],
          "type": "object",
          "additionalProperties": false
        },
        "ai": {
          "description": "LLM backend.",
          "properties": {
            "groups": {
              "description": "Groups in priority order, where each group\ndefines a set of LLM providers. The priority determines the priority of\nthe backend endpoints chosen.\nNote: provider names must be unique across all providers in all priority\ngroups. Backend policies may target a specific provider by name using\n`targetRefs[].sectionName`.\n\nExample configuration with two priority groups:\n\n\tgroups:\n\t- providers:\n\t  - azureopenai:\n\t      deploymentName: gpt-4o-mini\n\t      apiVersion: 2024-02-15-preview\n\t      endpoint: ai-gateway.openai.azure.com\n\t- providers:\n\t  - azureopenai:\n\t      deploymentName: gpt-4o-mini-2\n\t      apiVersion: 2024-02-15-preview\n\t      endpoint: ai-gateway-2.openai.azure.com\n\t     policies:\n\t       auth:\n\t         secretRef:\n\t           name: azure-secret",
              "items": {
                "properties": {
                  "providers": {
                    "description": "LLM providers within this group. Each provider is treated equally in terms of priority,\nwith automatic weighting based on health.",
                    "items": {
                      "properties": {
                        "anthropic": {
                          "description": "Anthropic provider settings.",
                          "properties": {
                            "model": {
                              "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "type": "object",
                          "additionalProperties": false
                        },
                        "azure": {
                          "description": "Azure provider with resource-based configuration.\nSupports both Azure OpenAI and Azure AI Foundry resource types.",
                          "properties": {
                            "apiVersion": {
                              "description": "The version of the Azure OpenAI API to use.\nIf unset, defaults to `v1`.",
                              "maxLength": 64,
                              "minLength": 1,
                              "type": "string"
                            },
                            "model": {
                              "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            },
                            "projectName": {
                              "description": "The Foundry project name, required when `resourceType` is `Foundry`.\nUsed to construct paths: /api/projects/{projectName}/openai/v1/...",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            },
                            "resourceName": {
                              "description": "The Azure resource name used to construct the endpoint host.\nFor OpenAI: {resourceName}.openai.azure.com\nFor Foundry: {resourceName}.services.ai.azure.com\nNote: when the Azure portal \"Foundry legacy\" template was used, the\ngenerated resource name may end in \"-resource\" (e.g. \"myproject-resource\");\nthat suffix is part of the resource name as the user configured it, not\npart of the hostname suffix agentgateway should append.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            },
                            "resourceType": {
                              "description": "The type of Azure endpoint. Determines the host suffix.",
                              "enum": [
                                "Foundry",
                                "OpenAI"
                              ],
                              "type": "string"
                            }
                          },
                          "required": [
                            "resourceName",
                            "resourceType"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "projectName is required when resourceType is Foundry",
                              "rule": "self.resourceType != 'Foundry' || has(self.projectName)"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "azureopenai": {
                          "description": "Azure OpenAI provider settings.",
                          "properties": {
                            "apiVersion": {
                              "description": "The version of the Azure OpenAI API to use.\nFor more information, see the [Azure OpenAI API version reference](https://learn.microsoft.com/en-us/azure/foundry/openai/reference).\nIf unset, defaults to `v1`.",
                              "maxLength": 64,
                              "minLength": 1,
                              "type": "string"
                            },
                            "deploymentName": {
                              "description": "The name of the Azure OpenAI model deployment to use.\nFor more information, see the [Azure OpenAI model docs](https://learn.microsoft.com/en-us/azure/foundry/foundry-models/concepts/models-sold-directly-by-azure?view=foundry-classic).\nThis is required if `apiVersion` is not `v1`. For `v1`, the model can be\nset in the request.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            },
                            "endpoint": {
                              "description": "The endpoint for the Azure OpenAI API to use, such as `my-endpoint.openai.azure.com`.\nIf the scheme is included, it is stripped.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "endpoint"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "deploymentName is required for this apiVersion",
                              "rule": "!has(self.apiVersion) || self.apiVersion == 'v1' ? true : has(self.deploymentName)"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "bedrock": {
                          "description": "Bedrock provider settings.",
                          "properties": {
                            "endpointPreference": {
                              "description": "EndpointPreference selects which Bedrock API surface to prefer.\nDefaults to `RuntimePreferred`, preferring runtime over mantle.\nDecides which endpoint to pick mainly based on the catalog tags\n`mantle` and `runtime`.",
                              "enum": [
                                "MantleOnly",
                                "MantlePreferred",
                                "RuntimeOnly",
                                "RuntimePreferred"
                              ],
                              "type": "string"
                            },
                            "guardrail": {
                              "description": "Guardrail policy to use for the backend. See\n<https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html>.\nIf not specified, the AWS Guardrail policy will not be used.",
                              "properties": {
                                "identifier": {
                                  "description": "Identifier of the Guardrail policy to use for the backend.",
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "version": {
                                  "description": "Version of the Guardrail policy to use for the backend.",
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "identifier",
                                "version"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "model": {
                              "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            },
                            "region": {
                              "description": "AWS region to use for the backend.\nDefaults to `us-east-1` if not specified.",
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-z0-9-]+$",
                              "type": "string"
                            }
                          },
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "Bedrock guardrails cannot be used with MantlePreferred or MantleOnly",
                              "rule": "!has(self.guardrail) || !has(self.endpointPreference) || !(self.endpointPreference in ['MantlePreferred', 'MantleOnly'])"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "custom": {
                          "description": "Custom provider configures a non-managed or self-hosted LLM provider.\nUse this when the provider target and API formats should be declared\nexplicitly instead of inferred from a managed provider such as OpenAI or\nAnthropic.",
                          "properties": {
                            "backendRef": {
                              "description": "Kubernetes backend that serves this provider.\n`backendRef` may target only a namespace-local Service or InferencePool.\nIf unset, host and port must be set on the parent provider.",
                              "properties": {
                                "group": {
                                  "description": "API group of the referenced resource. For example, `gateway.networking.k8s.io`.\nDefaults to the empty string, which identifies the core API group.",
                                  "maxLength": 253,
                                  "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                  "type": "string"
                                },
                                "kind": {
                                  "description": "Kind of the referenced resource. For example, `Service`.\nDefaults to \"Service\" when not specified.",
                                  "maxLength": 63,
                                  "minLength": 1,
                                  "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                  "type": "string"
                                },
                                "name": {
                                  "description": "Name of the referenced resource.",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "port": {
                                  "description": "Destination port number to use for this resource.\nRequired when the referenced resource is a Kubernetes Service.",
                                  "format": "int32",
                                  "maximum": 65535,
                                  "minimum": 1,
                                  "type": "integer"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "x-kubernetes-validations": [
                                {
                                  "message": "Must have port for Service reference",
                                  "rule": "((!has(self.group) || size(self.group) == 0) && (!has(self.kind) || self.kind == 'Service')) ? has(self.port) : true"
                                }
                              ],
                              "additionalProperties": false
                            },
                            "formats": {
                              "description": "Provider-native API formats this provider supports.",
                              "items": {
                                "description": "Provider-native LLM API format settings.",
                                "properties": {
                                  "path": {
                                    "description": "Default upstream path override for this format.\nIf unset, agentgateway uses the default path for the format.",
                                    "maxLength": 1024,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "type": {
                                    "description": "Provider-native API format.",
                                    "enum": [
                                      "AnthropicTokenCount",
                                      "Completions",
                                      "Embeddings",
                                      "Messages",
                                      "Realtime",
                                      "Rerank",
                                      "Responses"
                                    ],
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "type"
                                ],
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "path must start with /",
                                    "rule": "!has(self.path) || self.path.startsWith('/')"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "maxItems": 6,
                              "minItems": 1,
                              "type": "array",
                              "x-kubernetes-list-map-keys": [
                                "type"
                              ],
                              "x-kubernetes-list-type": "map"
                            },
                            "model": {
                              "description": "Model name override, such as `gpt-oss`.\nIf unset, the model name is taken from the request.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            },
                            "providerOverride": {
                              "description": "Provider identity used for cost-catalog lookup and telemetry.\nDefaults to \"custom\" when unset.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "formats"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "custom provider backendRef may target only Service or InferencePool",
                              "rule": "!has(self.backendRef) || (((!has(self.backendRef.group) || self.backendRef.group == \"\") && (!has(self.backendRef.kind) || self.backendRef.kind == 'Service')) || (has(self.backendRef.group) && self.backendRef.group == 'inference.networking.k8s.io' && has(self.backendRef.kind) && self.backendRef.kind == 'InferencePool'))"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "gemini": {
                          "description": "Gemini provider settings.",
                          "properties": {
                            "model": {
                              "description": "Model name override, such as `gemini-2.5-pro`.\nIf unset, the model name is taken from the request.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "type": "object",
                          "additionalProperties": false
                        },
                        "host": {
                          "description": "Hostname to send requests to.\nFor custom providers without backendRef, host and port specify the target.\nFor managed providers, host and port override the provider default.",
                          "maxLength": 256,
                          "minLength": 1,
                          "type": "string"
                        },
                        "name": {
                          "description": "Name of the provider. Policies can target this provider by name.",
                          "maxLength": 253,
                          "minLength": 1,
                          "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                          "type": "string"
                        },
                        "openai": {
                          "description": "OpenAI provider settings.",
                          "properties": {
                            "model": {
                              "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            },
                            "moderation": {
                              "description": "Inline moderation configuration to inject into OpenAI chat completions\nand responses requests.\nIf unset, the OpenAI inline moderation parameter is not injected.",
                              "properties": {
                                "model": {
                                  "description": "The moderation model to use, such as `omni-moderation-latest`.\nDefaults to `omni-moderation-latest` if not specified.",
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "policy": {
                                  "description": "Policies to apply to request input and generated output.",
                                  "properties": {
                                    "input": {
                                      "description": "Policy for request input moderation.",
                                      "properties": {
                                        "mode": {
                                          "description": "Mode controls whether moderation only returns scores or blocks flagged content.",
                                          "enum": [
                                            "Block",
                                            "Score"
                                          ],
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "mode"
                                      ],
                                      "type": "object",
                                      "additionalProperties": false
                                    },
                                    "output": {
                                      "description": "Policy for generated output moderation.",
                                      "properties": {
                                        "mode": {
                                          "description": "Mode controls whether moderation only returns scores or blocks flagged content.",
                                          "enum": [
                                            "Block",
                                            "Score"
                                          ],
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "mode"
                                      ],
                                      "type": "object",
                                      "additionalProperties": false
                                    }
                                  },
                                  "type": "object",
                                  "additionalProperties": false
                                }
                              },
                              "type": "object",
                              "additionalProperties": false
                            }
                          },
                          "type": "object",
                          "additionalProperties": false
                        },
                        "path": {
                          "description": "URL path to use for LLM provider API requests.\nThis is useful when you need to route requests to a different API endpoint while maintaining\ncompatibility with the original provider's API structure.\nIf not specified, the default path for the provider is used.",
                          "maxLength": 1024,
                          "minLength": 1,
                          "type": "string"
                        },
                        "pathPrefix": {
                          "description": "Overrides the default base path prefix, such as `/v1`, for upstream requests.\nPath translation for cross-format requests still applies using this prefix.\nOnly supported for OpenAI and Anthropic providers.",
                          "maxLength": 1024,
                          "minLength": 1,
                          "type": "string"
                        },
                        "policies": {
                          "description": "Policies for communicating with this backend.\nPolicies may also be set in `AgentgatewayPolicy`, or in the top-level\n`AgentgatewayBackend`. Policies are merged on a field-level basis, with\norder: `AgentgatewayPolicy` < `AgentgatewayBackend` < `AgentgatewayBackend`\nLLM provider (this field).",
                          "properties": {
                            "ai": {
                              "description": "Settings for AI workloads. This is only applicable when\nconnecting to a `Backend` of type `ai`.",
                              "properties": {
                                "defaults": {
                                  "description": "Defaults to merge with user input fields. If the field is already set, the field in the request is used.",
                                  "items": {
                                    "description": "Default value for a field in the JSON request body sent to the LLM provider.\nThese defaults are merged with the user-provided request to ensure missing fields are populated.\n\nUser input fields here refer to the fields in the JSON request body that a client sends when making a request to the LLM provider.\nDefaults set here do _not_ override those user-provided values unless you explicitly set `override` to `true`.\n\nExample: Setting a default system field for Anthropic, which does not support system role messages:\n\n\tdefaults:\n\t  - field: \"system\"\n\t    value: \"answer all questions in French\"\n\nExample: Setting a default temperature and overriding `max_tokens`:\n\n\tdefaults:\n\t  - field: \"temperature\"\n\t    value: \"0.5\"\n\t  - field: \"max_tokens\"\n\t    value: \"100\"\n\t    override: true\n\nExample: Setting custom lists fields:\n\n\tdefaults:\n\t  - field: \"custom_integer_list\"\n\t    value: [1,2,3]\n\n\toverrides:\n\t  - field: \"custom_string_list\"\n\t    value: [\"one\",\"two\",\"three\"]\n\nNote: The `field` values correspond to keys in the JSON request body, not fields in this CRD.",
                                    "properties": {
                                      "field": {
                                        "description": "Name of the field.",
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "value": {
                                        "description": "Default value for the field. This can be any JSON data type.",
                                        "x-kubernetes-preserve-unknown-fields": true
                                      }
                                    },
                                    "required": [
                                      "field",
                                      "value"
                                    ],
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "maxItems": 64,
                                  "minItems": 1,
                                  "type": "array"
                                },
                                "finalTransformations": {
                                  "description": "CEL transformations to compute and set fields in the request body.\nThe expression result overwrites any existing value for that field.\nThis has a higher priority than `overrides` if both are set for the same\nkey.\nThose transformations are applied after the request is converted to the provider's format, so they can be used to set provider-specific fields.",
                                  "items": {
                                    "description": "Maps a request JSON field to a CEL expression.\nThe expression is evaluated against the current request body and its result\nis assigned to the configured field.",
                                    "properties": {
                                      "expression": {
                                        "description": "CEL expression used to compute the field value.",
                                        "maxLength": 16384,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "field": {
                                        "description": "Name of the field to set.",
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "expression",
                                      "field"
                                    ],
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "maxItems": 64,
                                  "minItems": 1,
                                  "type": "array",
                                  "x-kubernetes-list-map-keys": [
                                    "field"
                                  ],
                                  "x-kubernetes-list-type": "map"
                                },
                                "modelAliases": {
                                  "additionalProperties": {
                                    "type": "string"
                                  },
                                  "description": "Maps friendly model names to actual provider model names.\nExample: `{\"fast\": \"gpt-3.5-turbo\", \"smart\": \"gpt-4-turbo\"}`.\nNote: This field is only applicable when using the agentgateway data plane.",
                                  "maxProperties": 64,
                                  "type": "object"
                                },
                                "overrides": {
                                  "description": "Overrides to merge with user input fields. If the field is already set, the field is overwritten.",
                                  "items": {
                                    "description": "Default value for a field in the JSON request body sent to the LLM provider.\nThese defaults are merged with the user-provided request to ensure missing fields are populated.\n\nUser input fields here refer to the fields in the JSON request body that a client sends when making a request to the LLM provider.\nDefaults set here do _not_ override those user-provided values unless you explicitly set `override` to `true`.\n\nExample: Setting a default system field for Anthropic, which does not support system role messages:\n\n\tdefaults:\n\t  - field: \"system\"\n\t    value: \"answer all questions in French\"\n\nExample: Setting a default temperature and overriding `max_tokens`:\n\n\tdefaults:\n\t  - field: \"temperature\"\n\t    value: \"0.5\"\n\t  - field: \"max_tokens\"\n\t    value: \"100\"\n\t    override: true\n\nExample: Setting custom lists fields:\n\n\tdefaults:\n\t  - field: \"custom_integer_list\"\n\t    value: [1,2,3]\n\n\toverrides:\n\t  - field: \"custom_string_list\"\n\t    value: [\"one\",\"two\",\"three\"]\n\nNote: The `field` values correspond to keys in the JSON request body, not fields in this CRD.",
                                    "properties": {
                                      "field": {
                                        "description": "Name of the field.",
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "value": {
                                        "description": "Default value for the field. This can be any JSON data type.",
                                        "x-kubernetes-preserve-unknown-fields": true
                                      }
                                    },
                                    "required": [
                                      "field",
                                      "value"
                                    ],
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "maxItems": 64,
                                  "minItems": 1,
                                  "type": "array"
                                },
                                "prompt": {
                                  "description": "Enriches requests sent to the LLM provider by appending and prepending system prompts. This can be configured only for\nLLM providers that use the `CHAT` or `CHAT_STREAMING` API route type.",
                                  "properties": {
                                    "append": {
                                      "description": "Messages to append to the prompt sent by the client.",
                                      "items": {
                                        "description": "An entry for a message to prepend or append to each prompt.",
                                        "properties": {
                                          "content": {
                                            "description": "String content of the message.",
                                            "type": "string"
                                          },
                                          "role": {
                                            "description": "Role of the message. The available roles depend on the backend\nLLM provider model, such as `SYSTEM` or `USER` in the OpenAI API.",
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "content",
                                          "role"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "type": "array"
                                    },
                                    "prepend": {
                                      "description": "Messages to prepend to the prompt sent by the client.",
                                      "items": {
                                        "description": "An entry for a message to prepend or append to each prompt.",
                                        "properties": {
                                          "content": {
                                            "description": "String content of the message.",
                                            "type": "string"
                                          },
                                          "role": {
                                            "description": "Role of the message. The available roles depend on the backend\nLLM provider model, such as `SYSTEM` or `USER` in the OpenAI API.",
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "content",
                                          "role"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "type": "array"
                                    }
                                  },
                                  "type": "object",
                                  "additionalProperties": false
                                },
                                "promptCaching": {
                                  "description": "Automatic prompt caching for supported\nproviders, currently AWS Bedrock.\nReduces API costs by caching static content like system prompts and tool definitions.\nOnly applicable for Bedrock Claude 3+ and Nova models.",
                                  "properties": {
                                    "cacheMessageOffset": {
                                      "description": "Shifts the message cache point further back in the\nconversation. 0 (default) places it at the second-to-last message.\nHigher values move it N additional messages towards the start, clamped\nto bounds.",
                                      "minimum": 0,
                                      "type": "integer"
                                    },
                                    "cacheMessages": {
                                      "description": "Enables caching for conversation messages. Defaults to true.\nCaches all messages in the conversation for cost savings.",
                                      "type": "boolean"
                                    },
                                    "cacheSystem": {
                                      "description": "Enables caching for system prompts. Defaults to true.\nInserts a cache point after all system messages.",
                                      "type": "boolean"
                                    },
                                    "cacheTools": {
                                      "description": "Enables caching for tool definitions. Defaults to false.\nInserts a cache point after all tool specifications.",
                                      "type": "boolean"
                                    },
                                    "minTokens": {
                                      "description": "Minimum estimated token count\nbefore caching is enabled. Uses rough heuristic (word count \u00d7 1.3) to estimate tokens.\nDefaults to 1024. Bedrock requires at least 1,024 tokens for caching to be effective.",
                                      "minimum": 0,
                                      "type": "integer"
                                    }
                                  },
                                  "type": "object",
                                  "additionalProperties": false
                                },
                                "promptGuard": {
                                  "description": "Guardrails for LLM requests and responses.",
                                  "properties": {
                                    "request": {
                                      "description": "Prompt guards to apply to requests sent by the client.",
                                      "items": {
                                        "description": "Prompt guards to apply to requests sent by the client.",
                                        "properties": {
                                          "bedrockGuardrails": {
                                            "description": "AWS Bedrock Guardrails settings for prompt\nguarding.",
                                            "properties": {
                                              "action": {
                                                "description": "Action controls whether the guardrail's verdict is enforced or only\nobserved. `Reject` (the default) enforces the guardrail: a blocked\nassessment rejects the request/response and an anonymized assessment masks\nthe matched content. `Audit` runs the guardrail in observe mode: it is\ninvoked and its assessment recorded (metrics + structured log), but the\nrequest/response is never blocked or masked.",
                                                "enum": [
                                                  "Audit",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "failureMode": {
                                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                                "enum": [
                                                  "FailClosed",
                                                  "FailOpen"
                                                ],
                                                "type": "string"
                                              },
                                              "identifier": {
                                                "description": "Identifier of the Guardrail policy to use for the backend.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "policies": {
                                                "description": "Policies for communicating with AWS Bedrock Guardrails.",
                                                "properties": {
                                                  "auth": {
                                                    "description": "Settings for authenticating to AWS Bedrock Guardrails.",
                                                    "properties": {
                                                      "aws": {
                                                        "description": "AWS authentication method for Bedrock Guardrails. Use `aws: {}` for\ndefault AWS SDK credential discovery.",
                                                        "properties": {
                                                          "assumeRole": {
                                                            "description": "AWS STS AssumeRole settings to use before signing backend requests.\nAmbient AWS credentials are used as the source credentials for STS.",
                                                            "properties": {
                                                              "externalId": {
                                                                "description": "ExternalID is set when the role's trust policy requires sts:ExternalId.",
                                                                "maxLength": 1224,
                                                                "minLength": 2,
                                                                "pattern": "^[\\w+=,.@:/-]+$",
                                                                "type": "string"
                                                              },
                                                              "roleArn": {
                                                                "description": "AWS IAM role ARN to assume.",
                                                                "minLength": 1,
                                                                "pattern": "^arn:aws[a-z-]*:iam::[0-9]{12}:role/.+$",
                                                                "type": "string"
                                                              },
                                                              "sessionName": {
                                                                "description": "SessionName is a custom session name (RoleSessionName) for CloudTrail and\nCost & Usage Report attribution. If unset, AWS generates a random name.",
                                                                "pattern": "^[\\w+=,.@-]{2,64}$",
                                                                "type": "string"
                                                              },
                                                              "sessionNameExpression": {
                                                                "description": "SessionNameExpression is a CEL expression evaluated against each request\nto produce the session name (RoleSessionName), for example `jwt.sub` or\n`request.headers[\"x-team\"]`. If the expression does not produce a valid\nsession name at request time, the request is rejected.",
                                                                "maxLength": 16384,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              },
                                                              "tags": {
                                                                "description": "Session tags passed to STS AssumeRole for cost attribution in the AWS Cost\n& Usage Report, once activated. STS allows at most 50 per role session.",
                                                                "items": {
                                                                  "description": "AwsSessionTag is an AWS STS session tag passed to AssumeRole for cost\nattribution. Exactly one of value and expression must be set.",
                                                                  "properties": {
                                                                    "expression": {
                                                                      "description": "CEL expression evaluated against each request to produce the tag value,\nfor example `jwt.sub` or `request.headers[\"x-app\"]`. Requests with invalid\ntag values are rejected.",
                                                                      "maxLength": 16384,
                                                                      "minLength": 1,
                                                                      "type": "string"
                                                                    },
                                                                    "key": {
                                                                      "description": "Key is the tag key.",
                                                                      "maxLength": 128,
                                                                      "minLength": 1,
                                                                      "type": "string"
                                                                    },
                                                                    "value": {
                                                                      "description": "Value is a static tag value.",
                                                                      "maxLength": 256,
                                                                      "type": "string"
                                                                    }
                                                                  },
                                                                  "required": [
                                                                    "key"
                                                                  ],
                                                                  "type": "object",
                                                                  "x-kubernetes-validations": [
                                                                    {
                                                                      "message": "exactly one of value or expression must be set",
                                                                      "rule": "has(self.value) != has(self.expression)"
                                                                    }
                                                                  ],
                                                                  "additionalProperties": false
                                                                },
                                                                "maxItems": 50,
                                                                "type": "array",
                                                                "x-kubernetes-list-map-keys": [
                                                                  "key"
                                                                ],
                                                                "x-kubernetes-list-type": "map"
                                                              }
                                                            },
                                                            "required": [
                                                              "roleArn"
                                                            ],
                                                            "type": "object",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "at most one of the fields in [sessionName sessionNameExpression] may be set",
                                                                "rule": "(has(self.sessionName)?1:0)+(has(self.sessionNameExpression)?1:0) <= 1"
                                                              }
                                                            ],
                                                            "additionalProperties": false
                                                          },
                                                          "region": {
                                                            "description": "AWS SigV4 signing region, for example `us-east-1`. Set this when the\ntarget AWS service is in a different region than the gateway. If unset,\ntyped AWS backends may provide this automatically; otherwise the ambient\nAWS region is used.",
                                                            "maxLength": 256,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "secretRef": {
                                                            "description": "Credential source for AWS credentials, defaulting to a Kubernetes `Secret`.\nThe default Secret resolver expects `accessKey`, `secretKey`, and optional\n`sessionToken` keys.",
                                                            "properties": {
                                                              "group": {
                                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                                "type": "string"
                                                              },
                                                              "kind": {
                                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                                "type": "string"
                                                              },
                                                              "name": {
                                                                "description": "Name of the referenced credential",
                                                                "maxLength": 253,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "x-kubernetes-map-type": "atomic",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "custom credential refs must set both group and kind",
                                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                              }
                                                            ],
                                                            "additionalProperties": false
                                                          },
                                                          "serviceName": {
                                                            "description": "AWS SigV4 signing service name, for example\n`bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS\nbackends may provide this automatically.",
                                                            "maxLength": 256,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          }
                                                        },
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "secretRef and assumeRole are mutually exclusive",
                                                            "rule": "!(has(self.secretRef) && has(self.assumeRole))"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "key": {
                                                        "description": "Inline API key to use as the value of the `Authorization` header.\nThis option is the least secure; usage of a `Secret` is preferred.",
                                                        "maxLength": 2048,
                                                        "type": "string"
                                                      },
                                                      "location": {
                                                        "description": "Where API keys are inserted. Defaults to the `Authorization` header with\nthe `Bearer ` prefix. Applies to `key` and `secretRef`.",
                                                        "properties": {
                                                          "cookie": {
                                                            "properties": {
                                                              "name": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          },
                                                          "header": {
                                                            "properties": {
                                                              "name": {
                                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                                "type": "string"
                                                              },
                                                              "prefix": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          },
                                                          "queryParameter": {
                                                            "properties": {
                                                              "name": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          }
                                                        },
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "secretRef": {
                                                        "description": "Credential source for the API key, defaulting to a Kubernetes `Secret`.\nBy default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                                                        "properties": {
                                                          "group": {
                                                            "description": "API group of the referenced credential; empty selects the core API group",
                                                            "type": "string"
                                                          },
                                                          "key": {
                                                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "kind": {
                                                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                            "type": "string"
                                                          },
                                                          "name": {
                                                            "description": "Name of the referenced credential",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          }
                                                        },
                                                        "required": [
                                                          "name"
                                                        ],
                                                        "type": "object",
                                                        "x-kubernetes-map-type": "atomic",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "custom credential refs must set both group and kind",
                                                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "location may only be set for key or secretRef auth",
                                                        "rule": "has(self.location) ? has(self.key) || has(self.secretRef) : true"
                                                      },
                                                      {
                                                        "message": "exactly one of the fields in [key secretRef aws] must be set",
                                                        "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0)+(has(self.aws)?1:0) == 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "http": {
                                                    "description": "Settings for managing HTTP requests to the backend",
                                                    "properties": {
                                                      "requestTimeout": {
                                                        "description": "Deadline for receiving a response from the backend.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "requestTimeout must be at least 1ms",
                                                            "rule": "duration(self) >= duration('1ms')"
                                                          }
                                                        ]
                                                      },
                                                      "version": {
                                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                                        "enum": [
                                                          "HTTP1",
                                                          "HTTP2"
                                                        ],
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tcp": {
                                                    "description": "Settings for managing TCP connections to the backend",
                                                    "properties": {
                                                      "connectTimeout": {
                                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "connectTimeout must be at least 100ms",
                                                            "rule": "duration(self) >= duration('100ms')"
                                                          }
                                                        ]
                                                      },
                                                      "keepalive": {
                                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                                        "properties": {
                                                          "interval": {
                                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "interval must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          },
                                                          "retries": {
                                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                                            "format": "int32",
                                                            "maximum": 64,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          },
                                                          "time": {
                                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "time must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          }
                                                        },
                                                        "type": "object",
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tls": {
                                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                                    "properties": {
                                                      "alpnProtocols": {
                                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                                        "items": {
                                                          "maxLength": 64,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      },
                                                      "caCertificateRefs": {
                                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                                        "items": {
                                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                                          "properties": {
                                                            "key": {
                                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                                              "enum": [
                                                                "ConfigMap",
                                                                "Secret"
                                                              ],
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced CA certificate source.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "certificateSource": {
                                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                                        "enum": [
                                                          "Inline",
                                                          "SPIFFE"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "insecureSkipVerify": {
                                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                                        "enum": [
                                                          "All",
                                                          "Hostname"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "keyExchangeGroups": {
                                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                                        "items": {
                                                          "enum": [
                                                            "P-256",
                                                            "P-384",
                                                            "X25519",
                                                            "X25519_MLKEM768"
                                                          ],
                                                          "type": "string"
                                                        },
                                                        "type": "array"
                                                      },
                                                      "mtlsCertificateRef": {
                                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                                        "items": {
                                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                                          "properties": {
                                                            "group": {
                                                              "description": "API group of the referenced credential; empty selects the core API group",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced credential",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "x-kubernetes-validations": [
                                                            {
                                                              "message": "custom credential refs must set both group and kind",
                                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                            }
                                                          ],
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "sni": {
                                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                                        "maxLength": 253,
                                                        "minLength": 1,
                                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                        "type": "string"
                                                      },
                                                      "verifySubjectAltNames": {
                                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                                        "items": {
                                                          "maxLength": 256,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                                      },
                                                      {
                                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                                      },
                                                      {
                                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                                      },
                                                      {
                                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "tunnel": {
                                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                                    "properties": {
                                                      "backendRef": {
                                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                                        "properties": {
                                                          "group": {
                                                            "default": "",
                                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                                            "maxLength": 253,
                                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                            "type": "string"
                                                          },
                                                          "kind": {
                                                            "default": "Service",
                                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "name": {
                                                            "description": "Name is the name of the referent.",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "namespace": {
                                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "port": {
                                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                                            "format": "int32",
                                                            "maximum": 65535,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          }
                                                        },
                                                        "required": [
                                                          "name"
                                                        ],
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "Must have port for Service reference",
                                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "mode": {
                                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                                        "enum": [
                                                          "Auto",
                                                          "Connect"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "url": {
                                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                                        "maxLength": 1024,
                                                        "minLength": 1,
                                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                                      },
                                                      {
                                                        "message": "url must not include a path for backend tunnel",
                                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  }
                                                },
                                                "type": "object",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              },
                                              "region": {
                                                "description": "AWS region where the guardrail is deployed, for example\n`us-west-2`).",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "version": {
                                                "description": "Version of the Guardrail policy to use for the backend.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "identifier",
                                              "region",
                                              "version"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "googleModelArmor": {
                                            "description": "Google Model Armor settings for prompt guarding.",
                                            "properties": {
                                              "action": {
                                                "description": "Action controls whether flagged content is rejected or only observed.\n`Reject` (the default) rejects flagged content; `Audit` records the\nwould-be rejection without blocking.",
                                                "enum": [
                                                  "Audit",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "failureMode": {
                                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                                "enum": [
                                                  "FailClosed",
                                                  "FailOpen"
                                                ],
                                                "type": "string"
                                              },
                                              "location": {
                                                "description": "Google Cloud location, for example `us-central1`.\nDefaults to `us-central1` if not specified.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "policies": {
                                                "description": "Policies for communicating with Google Model Armor.",
                                                "properties": {
                                                  "auth": {
                                                    "description": "Settings for authenticating to Google Model Armor.",
                                                    "properties": {
                                                      "gcp": {
                                                        "description": "Google authentication method for Model Armor. Use `gcp: {}` for default\nGoogle credential discovery.",
                                                        "properties": {
                                                          "audience": {
                                                            "description": "Explicit `aud` value for the ID token. Only\nvalid with `IdToken` type. If not set, the `aud` is automatically\nderived from the backend hostname.",
                                                            "maxLength": 256,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "secretRef": {
                                                            "description": "Credential source for ADC-compatible Google credential JSON, defaulting to\na Kubernetes `Secret`. By default, the value is read from\n`credentials.json`; set `secretRef.key` to override it. When omitted,\nambient credentials are used.",
                                                            "properties": {
                                                              "group": {
                                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                                "type": "string"
                                                              },
                                                              "key": {
                                                                "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                                "maxLength": 253,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              },
                                                              "kind": {
                                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                                "type": "string"
                                                              },
                                                              "name": {
                                                                "description": "Name of the referenced credential",
                                                                "maxLength": 253,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "x-kubernetes-map-type": "atomic",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "custom credential refs must set both group and kind",
                                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                              }
                                                            ],
                                                            "additionalProperties": false
                                                          },
                                                          "type": {
                                                            "description": "The type of token to generate. To authenticate to GCP services,\ngenerally an `AccessToken` is used. To authenticate to Cloud Run, an\n`IdToken` is used.",
                                                            "enum": [
                                                              "AccessToken",
                                                              "IdToken"
                                                            ],
                                                            "type": "string"
                                                          }
                                                        },
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "audience is only valid with IdToken",
                                                            "rule": "has(self.audience) ? self.type == 'IdToken' : true"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "exactly one of the fields in [gcp] must be set",
                                                        "rule": "(has(self.gcp)?1:0) == 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "http": {
                                                    "description": "Settings for managing HTTP requests to the backend",
                                                    "properties": {
                                                      "requestTimeout": {
                                                        "description": "Deadline for receiving a response from the backend.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "requestTimeout must be at least 1ms",
                                                            "rule": "duration(self) >= duration('1ms')"
                                                          }
                                                        ]
                                                      },
                                                      "version": {
                                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                                        "enum": [
                                                          "HTTP1",
                                                          "HTTP2"
                                                        ],
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tcp": {
                                                    "description": "Settings for managing TCP connections to the backend",
                                                    "properties": {
                                                      "connectTimeout": {
                                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "connectTimeout must be at least 100ms",
                                                            "rule": "duration(self) >= duration('100ms')"
                                                          }
                                                        ]
                                                      },
                                                      "keepalive": {
                                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                                        "properties": {
                                                          "interval": {
                                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "interval must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          },
                                                          "retries": {
                                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                                            "format": "int32",
                                                            "maximum": 64,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          },
                                                          "time": {
                                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "time must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          }
                                                        },
                                                        "type": "object",
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tls": {
                                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                                    "properties": {
                                                      "alpnProtocols": {
                                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                                        "items": {
                                                          "maxLength": 64,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      },
                                                      "caCertificateRefs": {
                                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                                        "items": {
                                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                                          "properties": {
                                                            "key": {
                                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                                              "enum": [
                                                                "ConfigMap",
                                                                "Secret"
                                                              ],
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced CA certificate source.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "certificateSource": {
                                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                                        "enum": [
                                                          "Inline",
                                                          "SPIFFE"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "insecureSkipVerify": {
                                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                                        "enum": [
                                                          "All",
                                                          "Hostname"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "keyExchangeGroups": {
                                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                                        "items": {
                                                          "enum": [
                                                            "P-256",
                                                            "P-384",
                                                            "X25519",
                                                            "X25519_MLKEM768"
                                                          ],
                                                          "type": "string"
                                                        },
                                                        "type": "array"
                                                      },
                                                      "mtlsCertificateRef": {
                                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                                        "items": {
                                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                                          "properties": {
                                                            "group": {
                                                              "description": "API group of the referenced credential; empty selects the core API group",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced credential",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "x-kubernetes-validations": [
                                                            {
                                                              "message": "custom credential refs must set both group and kind",
                                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                            }
                                                          ],
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "sni": {
                                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                                        "maxLength": 253,
                                                        "minLength": 1,
                                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                        "type": "string"
                                                      },
                                                      "verifySubjectAltNames": {
                                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                                        "items": {
                                                          "maxLength": 256,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                                      },
                                                      {
                                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                                      },
                                                      {
                                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                                      },
                                                      {
                                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "tunnel": {
                                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                                    "properties": {
                                                      "backendRef": {
                                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                                        "properties": {
                                                          "group": {
                                                            "default": "",
                                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                                            "maxLength": 253,
                                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                            "type": "string"
                                                          },
                                                          "kind": {
                                                            "default": "Service",
                                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "name": {
                                                            "description": "Name is the name of the referent.",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "namespace": {
                                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "port": {
                                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                                            "format": "int32",
                                                            "maximum": 65535,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          }
                                                        },
                                                        "required": [
                                                          "name"
                                                        ],
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "Must have port for Service reference",
                                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "mode": {
                                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                                        "enum": [
                                                          "Auto",
                                                          "Connect"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "url": {
                                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                                        "maxLength": 1024,
                                                        "minLength": 1,
                                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                                      },
                                                      {
                                                        "message": "url must not include a path for backend tunnel",
                                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  }
                                                },
                                                "type": "object",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              },
                                              "projectId": {
                                                "description": "Google Cloud project ID.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "templateId": {
                                                "description": "Template ID for Google Model Armor.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "projectId",
                                              "templateId"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "openAIModeration": {
                                            "description": "Passes prompt data through the OpenAI Moderations\nendpoint.\nSee https://developers.openai.com/api/reference/resources/moderations for more information.",
                                            "properties": {
                                              "action": {
                                                "description": "Action controls whether flagged content is rejected or only observed.\n`Reject` (the default) rejects flagged content; `Audit` records the\nwould-be rejection without blocking.",
                                                "enum": [
                                                  "Audit",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "failureMode": {
                                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                                "enum": [
                                                  "FailClosed",
                                                  "FailOpen"
                                                ],
                                                "type": "string"
                                              },
                                              "model": {
                                                "description": "Moderation model to use. For example,\n`omni-moderation`.",
                                                "type": "string"
                                              },
                                              "policies": {
                                                "description": "Policies for communicating with OpenAI.",
                                                "properties": {
                                                  "auth": {
                                                    "description": "Settings for authenticating to OpenAI.",
                                                    "properties": {
                                                      "key": {
                                                        "description": "Inline key to use as the value of the\n`Authorization` header. This option is the least secure; usage of a\n`Secret` is preferred.",
                                                        "maxLength": 2048,
                                                        "type": "string"
                                                      },
                                                      "location": {
                                                        "description": "Where backend credentials are inserted. Defaults to the `Authorization`\nheader with the `Bearer ` prefix. Applies to `key` and `secretRef`.",
                                                        "properties": {
                                                          "cookie": {
                                                            "properties": {
                                                              "name": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          },
                                                          "header": {
                                                            "properties": {
                                                              "name": {
                                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                                "type": "string"
                                                              },
                                                              "prefix": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          },
                                                          "queryParameter": {
                                                            "properties": {
                                                              "name": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          }
                                                        },
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "secretRef": {
                                                        "description": "Credential source for the authorization value, defaulting to a Kubernetes\n`Secret`. By default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                                                        "properties": {
                                                          "group": {
                                                            "description": "API group of the referenced credential; empty selects the core API group",
                                                            "type": "string"
                                                          },
                                                          "key": {
                                                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "kind": {
                                                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                            "type": "string"
                                                          },
                                                          "name": {
                                                            "description": "Name of the referenced credential",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          }
                                                        },
                                                        "required": [
                                                          "name"
                                                        ],
                                                        "type": "object",
                                                        "x-kubernetes-map-type": "atomic",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "custom credential refs must set both group and kind",
                                                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "exactly one of the fields in [key secretRef] must be set",
                                                        "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0) == 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "http": {
                                                    "description": "Settings for managing HTTP requests to the backend",
                                                    "properties": {
                                                      "requestTimeout": {
                                                        "description": "Deadline for receiving a response from the backend.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "requestTimeout must be at least 1ms",
                                                            "rule": "duration(self) >= duration('1ms')"
                                                          }
                                                        ]
                                                      },
                                                      "version": {
                                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                                        "enum": [
                                                          "HTTP1",
                                                          "HTTP2"
                                                        ],
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tcp": {
                                                    "description": "Settings for managing TCP connections to the backend",
                                                    "properties": {
                                                      "connectTimeout": {
                                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "connectTimeout must be at least 100ms",
                                                            "rule": "duration(self) >= duration('100ms')"
                                                          }
                                                        ]
                                                      },
                                                      "keepalive": {
                                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                                        "properties": {
                                                          "interval": {
                                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "interval must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          },
                                                          "retries": {
                                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                                            "format": "int32",
                                                            "maximum": 64,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          },
                                                          "time": {
                                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "time must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          }
                                                        },
                                                        "type": "object",
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tls": {
                                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                                    "properties": {
                                                      "alpnProtocols": {
                                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                                        "items": {
                                                          "maxLength": 64,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      },
                                                      "caCertificateRefs": {
                                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                                        "items": {
                                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                                          "properties": {
                                                            "key": {
                                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                                              "enum": [
                                                                "ConfigMap",
                                                                "Secret"
                                                              ],
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced CA certificate source.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "certificateSource": {
                                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                                        "enum": [
                                                          "Inline",
                                                          "SPIFFE"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "insecureSkipVerify": {
                                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                                        "enum": [
                                                          "All",
                                                          "Hostname"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "keyExchangeGroups": {
                                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                                        "items": {
                                                          "enum": [
                                                            "P-256",
                                                            "P-384",
                                                            "X25519",
                                                            "X25519_MLKEM768"
                                                          ],
                                                          "type": "string"
                                                        },
                                                        "type": "array"
                                                      },
                                                      "mtlsCertificateRef": {
                                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                                        "items": {
                                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                                          "properties": {
                                                            "group": {
                                                              "description": "API group of the referenced credential; empty selects the core API group",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced credential",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "x-kubernetes-validations": [
                                                            {
                                                              "message": "custom credential refs must set both group and kind",
                                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                            }
                                                          ],
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "sni": {
                                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                                        "maxLength": 253,
                                                        "minLength": 1,
                                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                        "type": "string"
                                                      },
                                                      "verifySubjectAltNames": {
                                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                                        "items": {
                                                          "maxLength": 256,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                                      },
                                                      {
                                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                                      },
                                                      {
                                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                                      },
                                                      {
                                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "tunnel": {
                                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                                    "properties": {
                                                      "backendRef": {
                                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                                        "properties": {
                                                          "group": {
                                                            "default": "",
                                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                                            "maxLength": 253,
                                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                            "type": "string"
                                                          },
                                                          "kind": {
                                                            "default": "Service",
                                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "name": {
                                                            "description": "Name is the name of the referent.",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "namespace": {
                                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "port": {
                                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                                            "format": "int32",
                                                            "maximum": 65535,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          }
                                                        },
                                                        "required": [
                                                          "name"
                                                        ],
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "Must have port for Service reference",
                                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "mode": {
                                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                                        "enum": [
                                                          "Auto",
                                                          "Connect"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "url": {
                                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                                        "maxLength": 1024,
                                                        "minLength": 1,
                                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                                      },
                                                      {
                                                        "message": "url must not include a path for backend tunnel",
                                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  }
                                                },
                                                "type": "object",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              }
                                            },
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "regex": {
                                            "description": "Regular expression (regex) matching for prompt guards and data masking.",
                                            "properties": {
                                              "action": {
                                                "description": "The action to take if a regex pattern is matched in a request or response.\nThe action applies to request and response matches alike. Note that\n`Mask` is not applied to streamed responses: matched content in a\nstreamed response is passed through unmodified.\nDefaults to `Mask`.",
                                                "enum": [
                                                  "Audit",
                                                  "Mask",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "builtins": {
                                                "description": "Built-in regex patterns to match against the request or response.\nMatches and built-ins are additive.",
                                                "items": {
                                                  "description": "Built-in regex patterns for specific types of strings in prompts.\nFor example, if you specify `CreditCard`, any credit card numbers\nin the request or response are matched.",
                                                  "enum": [
                                                    "CaSin",
                                                    "CreditCard",
                                                    "Email",
                                                    "PhoneNumber",
                                                    "Ssn"
                                                  ],
                                                  "type": "string"
                                                },
                                                "type": "array"
                                              },
                                              "matches": {
                                                "description": "Regex patterns to match against the request or response.\nMatches and built-ins are additive.",
                                                "items": {
                                                  "maxLength": 1024,
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "type": "array"
                                              }
                                            },
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "response": {
                                            "description": "Custom response message to return to the client. If not specified, defaults to\n`The request was rejected due to inappropriate content`.",
                                            "properties": {
                                              "message": {
                                                "description": "Custom response message to return to the client. If not specified, defaults to\n`The request was rejected due to inappropriate content`.",
                                                "type": "string"
                                              },
                                              "statusCode": {
                                                "description": "Status code to return to the client. Defaults to 403.",
                                                "format": "int32",
                                                "maximum": 599,
                                                "minimum": 200,
                                                "type": "integer"
                                              }
                                            },
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "scope": {
                                            "description": "Which parts of the request this guard inspects. When unset, defaults to\n`SystemPrompt` and `Messages`. Tool call inputs and outputs are not\ninspected unless `ToolInput`/`ToolOutput` are listed explicitly.\nIn APIs that send tool arguments as opaque JSON, such as Completions, the\narguments are masked as a single string, meaning a prompt guard has the\npotential to rewrite the arguments into invalid JSON.",
                                            "items": {
                                              "description": "Which category of request content a prompt guard inspects.",
                                              "enum": [
                                                "Messages",
                                                "SystemPrompt",
                                                "ToolInput",
                                                "ToolOutput"
                                              ],
                                              "type": "string"
                                            },
                                            "maxItems": 4,
                                            "minItems": 1,
                                            "type": "array",
                                            "x-kubernetes-list-type": "set"
                                          },
                                          "webhook": {
                                            "description": "Webhook that receives requests for prompt guarding.",
                                            "properties": {
                                              "action": {
                                                "description": "Action controls whether the webhook's verdict is enforced or only observed.\n`Reject` (the default) enforces it; `Audit` records the would-be action\nwithout blocking or masking.",
                                                "enum": [
                                                  "Audit",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "backendRef": {
                                                "description": "Webhook server to reach.\n\nSupported types: Service and Backend.",
                                                "properties": {
                                                  "group": {
                                                    "default": "",
                                                    "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                                    "maxLength": 253,
                                                    "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                    "type": "string"
                                                  },
                                                  "kind": {
                                                    "default": "Service",
                                                    "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                                    "maxLength": 63,
                                                    "minLength": 1,
                                                    "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                                    "type": "string"
                                                  },
                                                  "name": {
                                                    "description": "Name is the name of the referent.",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  },
                                                  "namespace": {
                                                    "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                                    "maxLength": 63,
                                                    "minLength": 1,
                                                    "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                                    "type": "string"
                                                  },
                                                  "port": {
                                                    "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                                    "format": "int32",
                                                    "maximum": 65535,
                                                    "minimum": 1,
                                                    "type": "integer"
                                                  }
                                                },
                                                "required": [
                                                  "name"
                                                ],
                                                "type": "object",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "Must have port for Service reference",
                                                    "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              },
                                              "failureMode": {
                                                "description": "Behavior when the webhook guardrail is unavailable\nor returns an error. `FailOpen` allows the request to continue.\n`FailClosed` (default) rejects the request.",
                                                "enum": [
                                                  "FailClosed",
                                                  "FailOpen"
                                                ],
                                                "type": "string"
                                              },
                                              "forwardHeaderMatches": {
                                                "description": "HTTP header matches used to select the headers to forward to the webhook.\nRequest headers are used when forwarding requests and response headers\nare used when forwarding responses.\nBy default, no headers are forwarded.",
                                                "items": {
                                                  "description": "HTTPHeaderMatch describes how to select a HTTP route by matching HTTP request\nheaders.",
                                                  "properties": {
                                                    "name": {
                                                      "description": "Name of the HTTP header to match, case-insensitive. When names are equivalent, only the first matching entry is used",
                                                      "maxLength": 256,
                                                      "minLength": 1,
                                                      "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                      "type": "string"
                                                    },
                                                    "type": {
                                                      "default": "Exact",
                                                      "description": "How to match against the header value: `Exact` (default) or `RegularExpression`. The regex dialect is implementation-specific",
                                                      "enum": [
                                                        "Exact",
                                                        "RegularExpression"
                                                      ],
                                                      "type": "string"
                                                    },
                                                    "value": {
                                                      "description": "Value of the HTTP header to match",
                                                      "maxLength": 4096,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    }
                                                  },
                                                  "required": [
                                                    "name",
                                                    "value"
                                                  ],
                                                  "type": "object",
                                                  "additionalProperties": false
                                                },
                                                "type": "array"
                                              },
                                              "headers": {
                                                "additionalProperties": {
                                                  "description": "A Common Expression Language (CEL) expression.",
                                                  "maxLength": 16384,
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "description": "CEL-computed headers to include in webhook requests.",
                                                "maxProperties": 64,
                                                "type": "object"
                                              }
                                            },
                                            "required": [
                                              "backendRef"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "scope: only regex and bedrockGuardrails guards support a non-default scope; other guard kinds always inspect the default (SystemPrompt + Messages)",
                                            "rule": "!has(self.scope) || has(self.regex) || has(self.bedrockGuardrails) || (self.scope.size() == 2 && 'SystemPrompt' in self.scope && 'Messages' in self.scope)"
                                          },
                                          {
                                            "message": "exactly one of the fields in [regex webhook openAIModeration bedrockGuardrails googleModelArmor] must be set",
                                            "rule": "(has(self.regex)?1:0)+(has(self.webhook)?1:0)+(has(self.openAIModeration)?1:0)+(has(self.bedrockGuardrails)?1:0)+(has(self.googleModelArmor)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "maxItems": 8,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "response": {
                                      "description": "Prompt guards to apply to responses returned by the LLM provider.",
                                      "items": {
                                        "description": "Prompt guards to apply to responses returned by the LLM provider.",
                                        "properties": {
                                          "bedrockGuardrails": {
                                            "description": "AWS Bedrock Guardrails settings for prompt\nguarding.",
                                            "properties": {
                                              "action": {
                                                "description": "Action controls whether the guardrail's verdict is enforced or only\nobserved. `Reject` (the default) enforces the guardrail: a blocked\nassessment rejects the request/response and an anonymized assessment masks\nthe matched content. `Audit` runs the guardrail in observe mode: it is\ninvoked and its assessment recorded (metrics + structured log), but the\nrequest/response is never blocked or masked.",
                                                "enum": [
                                                  "Audit",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "failureMode": {
                                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                                "enum": [
                                                  "FailClosed",
                                                  "FailOpen"
                                                ],
                                                "type": "string"
                                              },
                                              "identifier": {
                                                "description": "Identifier of the Guardrail policy to use for the backend.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "policies": {
                                                "description": "Policies for communicating with AWS Bedrock Guardrails.",
                                                "properties": {
                                                  "auth": {
                                                    "description": "Settings for authenticating to AWS Bedrock Guardrails.",
                                                    "properties": {
                                                      "aws": {
                                                        "description": "AWS authentication method for Bedrock Guardrails. Use `aws: {}` for\ndefault AWS SDK credential discovery.",
                                                        "properties": {
                                                          "assumeRole": {
                                                            "description": "AWS STS AssumeRole settings to use before signing backend requests.\nAmbient AWS credentials are used as the source credentials for STS.",
                                                            "properties": {
                                                              "externalId": {
                                                                "description": "ExternalID is set when the role's trust policy requires sts:ExternalId.",
                                                                "maxLength": 1224,
                                                                "minLength": 2,
                                                                "pattern": "^[\\w+=,.@:/-]+$",
                                                                "type": "string"
                                                              },
                                                              "roleArn": {
                                                                "description": "AWS IAM role ARN to assume.",
                                                                "minLength": 1,
                                                                "pattern": "^arn:aws[a-z-]*:iam::[0-9]{12}:role/.+$",
                                                                "type": "string"
                                                              },
                                                              "sessionName": {
                                                                "description": "SessionName is a custom session name (RoleSessionName) for CloudTrail and\nCost & Usage Report attribution. If unset, AWS generates a random name.",
                                                                "pattern": "^[\\w+=,.@-]{2,64}$",
                                                                "type": "string"
                                                              },
                                                              "sessionNameExpression": {
                                                                "description": "SessionNameExpression is a CEL expression evaluated against each request\nto produce the session name (RoleSessionName), for example `jwt.sub` or\n`request.headers[\"x-team\"]`. If the expression does not produce a valid\nsession name at request time, the request is rejected.",
                                                                "maxLength": 16384,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              },
                                                              "tags": {
                                                                "description": "Session tags passed to STS AssumeRole for cost attribution in the AWS Cost\n& Usage Report, once activated. STS allows at most 50 per role session.",
                                                                "items": {
                                                                  "description": "AwsSessionTag is an AWS STS session tag passed to AssumeRole for cost\nattribution. Exactly one of value and expression must be set.",
                                                                  "properties": {
                                                                    "expression": {
                                                                      "description": "CEL expression evaluated against each request to produce the tag value,\nfor example `jwt.sub` or `request.headers[\"x-app\"]`. Requests with invalid\ntag values are rejected.",
                                                                      "maxLength": 16384,
                                                                      "minLength": 1,
                                                                      "type": "string"
                                                                    },
                                                                    "key": {
                                                                      "description": "Key is the tag key.",
                                                                      "maxLength": 128,
                                                                      "minLength": 1,
                                                                      "type": "string"
                                                                    },
                                                                    "value": {
                                                                      "description": "Value is a static tag value.",
                                                                      "maxLength": 256,
                                                                      "type": "string"
                                                                    }
                                                                  },
                                                                  "required": [
                                                                    "key"
                                                                  ],
                                                                  "type": "object",
                                                                  "x-kubernetes-validations": [
                                                                    {
                                                                      "message": "exactly one of value or expression must be set",
                                                                      "rule": "has(self.value) != has(self.expression)"
                                                                    }
                                                                  ],
                                                                  "additionalProperties": false
                                                                },
                                                                "maxItems": 50,
                                                                "type": "array",
                                                                "x-kubernetes-list-map-keys": [
                                                                  "key"
                                                                ],
                                                                "x-kubernetes-list-type": "map"
                                                              }
                                                            },
                                                            "required": [
                                                              "roleArn"
                                                            ],
                                                            "type": "object",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "at most one of the fields in [sessionName sessionNameExpression] may be set",
                                                                "rule": "(has(self.sessionName)?1:0)+(has(self.sessionNameExpression)?1:0) <= 1"
                                                              }
                                                            ],
                                                            "additionalProperties": false
                                                          },
                                                          "region": {
                                                            "description": "AWS SigV4 signing region, for example `us-east-1`. Set this when the\ntarget AWS service is in a different region than the gateway. If unset,\ntyped AWS backends may provide this automatically; otherwise the ambient\nAWS region is used.",
                                                            "maxLength": 256,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "secretRef": {
                                                            "description": "Credential source for AWS credentials, defaulting to a Kubernetes `Secret`.\nThe default Secret resolver expects `accessKey`, `secretKey`, and optional\n`sessionToken` keys.",
                                                            "properties": {
                                                              "group": {
                                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                                "type": "string"
                                                              },
                                                              "kind": {
                                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                                "type": "string"
                                                              },
                                                              "name": {
                                                                "description": "Name of the referenced credential",
                                                                "maxLength": 253,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "x-kubernetes-map-type": "atomic",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "custom credential refs must set both group and kind",
                                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                              }
                                                            ],
                                                            "additionalProperties": false
                                                          },
                                                          "serviceName": {
                                                            "description": "AWS SigV4 signing service name, for example\n`bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS\nbackends may provide this automatically.",
                                                            "maxLength": 256,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          }
                                                        },
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "secretRef and assumeRole are mutually exclusive",
                                                            "rule": "!(has(self.secretRef) && has(self.assumeRole))"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "key": {
                                                        "description": "Inline API key to use as the value of the `Authorization` header.\nThis option is the least secure; usage of a `Secret` is preferred.",
                                                        "maxLength": 2048,
                                                        "type": "string"
                                                      },
                                                      "location": {
                                                        "description": "Where API keys are inserted. Defaults to the `Authorization` header with\nthe `Bearer ` prefix. Applies to `key` and `secretRef`.",
                                                        "properties": {
                                                          "cookie": {
                                                            "properties": {
                                                              "name": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          },
                                                          "header": {
                                                            "properties": {
                                                              "name": {
                                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                                "type": "string"
                                                              },
                                                              "prefix": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          },
                                                          "queryParameter": {
                                                            "properties": {
                                                              "name": {
                                                                "maxLength": 256,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "additionalProperties": false
                                                          }
                                                        },
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "secretRef": {
                                                        "description": "Credential source for the API key, defaulting to a Kubernetes `Secret`.\nBy default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                                                        "properties": {
                                                          "group": {
                                                            "description": "API group of the referenced credential; empty selects the core API group",
                                                            "type": "string"
                                                          },
                                                          "key": {
                                                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "kind": {
                                                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                            "type": "string"
                                                          },
                                                          "name": {
                                                            "description": "Name of the referenced credential",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          }
                                                        },
                                                        "required": [
                                                          "name"
                                                        ],
                                                        "type": "object",
                                                        "x-kubernetes-map-type": "atomic",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "custom credential refs must set both group and kind",
                                                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "location may only be set for key or secretRef auth",
                                                        "rule": "has(self.location) ? has(self.key) || has(self.secretRef) : true"
                                                      },
                                                      {
                                                        "message": "exactly one of the fields in [key secretRef aws] must be set",
                                                        "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0)+(has(self.aws)?1:0) == 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "http": {
                                                    "description": "Settings for managing HTTP requests to the backend",
                                                    "properties": {
                                                      "requestTimeout": {
                                                        "description": "Deadline for receiving a response from the backend.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "requestTimeout must be at least 1ms",
                                                            "rule": "duration(self) >= duration('1ms')"
                                                          }
                                                        ]
                                                      },
                                                      "version": {
                                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                                        "enum": [
                                                          "HTTP1",
                                                          "HTTP2"
                                                        ],
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tcp": {
                                                    "description": "Settings for managing TCP connections to the backend",
                                                    "properties": {
                                                      "connectTimeout": {
                                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "connectTimeout must be at least 100ms",
                                                            "rule": "duration(self) >= duration('100ms')"
                                                          }
                                                        ]
                                                      },
                                                      "keepalive": {
                                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                                        "properties": {
                                                          "interval": {
                                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "interval must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          },
                                                          "retries": {
                                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                                            "format": "int32",
                                                            "maximum": 64,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          },
                                                          "time": {
                                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "time must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          }
                                                        },
                                                        "type": "object",
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tls": {
                                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                                    "properties": {
                                                      "alpnProtocols": {
                                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                                        "items": {
                                                          "maxLength": 64,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      },
                                                      "caCertificateRefs": {
                                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                                        "items": {
                                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                                          "properties": {
                                                            "key": {
                                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                                              "enum": [
                                                                "ConfigMap",
                                                                "Secret"
                                                              ],
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced CA certificate source.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "certificateSource": {
                                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                                        "enum": [
                                                          "Inline",
                                                          "SPIFFE"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "insecureSkipVerify": {
                                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                                        "enum": [
                                                          "All",
                                                          "Hostname"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "keyExchangeGroups": {
                                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                                        "items": {
                                                          "enum": [
                                                            "P-256",
                                                            "P-384",
                                                            "X25519",
                                                            "X25519_MLKEM768"
                                                          ],
                                                          "type": "string"
                                                        },
                                                        "type": "array"
                                                      },
                                                      "mtlsCertificateRef": {
                                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                                        "items": {
                                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                                          "properties": {
                                                            "group": {
                                                              "description": "API group of the referenced credential; empty selects the core API group",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced credential",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "x-kubernetes-validations": [
                                                            {
                                                              "message": "custom credential refs must set both group and kind",
                                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                            }
                                                          ],
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "sni": {
                                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                                        "maxLength": 253,
                                                        "minLength": 1,
                                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                        "type": "string"
                                                      },
                                                      "verifySubjectAltNames": {
                                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                                        "items": {
                                                          "maxLength": 256,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                                      },
                                                      {
                                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                                      },
                                                      {
                                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                                      },
                                                      {
                                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "tunnel": {
                                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                                    "properties": {
                                                      "backendRef": {
                                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                                        "properties": {
                                                          "group": {
                                                            "default": "",
                                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                                            "maxLength": 253,
                                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                            "type": "string"
                                                          },
                                                          "kind": {
                                                            "default": "Service",
                                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "name": {
                                                            "description": "Name is the name of the referent.",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "namespace": {
                                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "port": {
                                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                                            "format": "int32",
                                                            "maximum": 65535,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          }
                                                        },
                                                        "required": [
                                                          "name"
                                                        ],
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "Must have port for Service reference",
                                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "mode": {
                                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                                        "enum": [
                                                          "Auto",
                                                          "Connect"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "url": {
                                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                                        "maxLength": 1024,
                                                        "minLength": 1,
                                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                                      },
                                                      {
                                                        "message": "url must not include a path for backend tunnel",
                                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  }
                                                },
                                                "type": "object",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              },
                                              "region": {
                                                "description": "AWS region where the guardrail is deployed, for example\n`us-west-2`).",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "version": {
                                                "description": "Version of the Guardrail policy to use for the backend.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "identifier",
                                              "region",
                                              "version"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "googleModelArmor": {
                                            "description": "Google Model Armor settings for prompt guarding.",
                                            "properties": {
                                              "action": {
                                                "description": "Action controls whether flagged content is rejected or only observed.\n`Reject` (the default) rejects flagged content; `Audit` records the\nwould-be rejection without blocking.",
                                                "enum": [
                                                  "Audit",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "failureMode": {
                                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                                "enum": [
                                                  "FailClosed",
                                                  "FailOpen"
                                                ],
                                                "type": "string"
                                              },
                                              "location": {
                                                "description": "Google Cloud location, for example `us-central1`.\nDefaults to `us-central1` if not specified.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "policies": {
                                                "description": "Policies for communicating with Google Model Armor.",
                                                "properties": {
                                                  "auth": {
                                                    "description": "Settings for authenticating to Google Model Armor.",
                                                    "properties": {
                                                      "gcp": {
                                                        "description": "Google authentication method for Model Armor. Use `gcp: {}` for default\nGoogle credential discovery.",
                                                        "properties": {
                                                          "audience": {
                                                            "description": "Explicit `aud` value for the ID token. Only\nvalid with `IdToken` type. If not set, the `aud` is automatically\nderived from the backend hostname.",
                                                            "maxLength": 256,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "secretRef": {
                                                            "description": "Credential source for ADC-compatible Google credential JSON, defaulting to\na Kubernetes `Secret`. By default, the value is read from\n`credentials.json`; set `secretRef.key` to override it. When omitted,\nambient credentials are used.",
                                                            "properties": {
                                                              "group": {
                                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                                "type": "string"
                                                              },
                                                              "key": {
                                                                "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                                "maxLength": 253,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              },
                                                              "kind": {
                                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                                "type": "string"
                                                              },
                                                              "name": {
                                                                "description": "Name of the referenced credential",
                                                                "maxLength": 253,
                                                                "minLength": 1,
                                                                "type": "string"
                                                              }
                                                            },
                                                            "required": [
                                                              "name"
                                                            ],
                                                            "type": "object",
                                                            "x-kubernetes-map-type": "atomic",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "custom credential refs must set both group and kind",
                                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                              }
                                                            ],
                                                            "additionalProperties": false
                                                          },
                                                          "type": {
                                                            "description": "The type of token to generate. To authenticate to GCP services,\ngenerally an `AccessToken` is used. To authenticate to Cloud Run, an\n`IdToken` is used.",
                                                            "enum": [
                                                              "AccessToken",
                                                              "IdToken"
                                                            ],
                                                            "type": "string"
                                                          }
                                                        },
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "audience is only valid with IdToken",
                                                            "rule": "has(self.audience) ? self.type == 'IdToken' : true"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "exactly one of the fields in [gcp] must be set",
                                                        "rule": "(has(self.gcp)?1:0) == 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "http": {
                                                    "description": "Settings for managing HTTP requests to the backend",
                                                    "properties": {
                                                      "requestTimeout": {
                                                        "description": "Deadline for receiving a response from the backend.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "requestTimeout must be at least 1ms",
                                                            "rule": "duration(self) >= duration('1ms')"
                                                          }
                                                        ]
                                                      },
                                                      "version": {
                                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                                        "enum": [
                                                          "HTTP1",
                                                          "HTTP2"
                                                        ],
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tcp": {
                                                    "description": "Settings for managing TCP connections to the backend",
                                                    "properties": {
                                                      "connectTimeout": {
                                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                                        "maxLength": 32,
                                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                        "type": "string",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "connectTimeout must be at least 100ms",
                                                            "rule": "duration(self) >= duration('100ms')"
                                                          }
                                                        ]
                                                      },
                                                      "keepalive": {
                                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                                        "properties": {
                                                          "interval": {
                                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "interval must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          },
                                                          "retries": {
                                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                                            "format": "int32",
                                                            "maximum": 64,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          },
                                                          "time": {
                                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                                            "maxLength": 32,
                                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                                            "type": "string",
                                                            "x-kubernetes-validations": [
                                                              {
                                                                "message": "time must be at least 1 second",
                                                                "rule": "duration(self) >= duration('1s')"
                                                              }
                                                            ]
                                                          }
                                                        },
                                                        "type": "object",
                                                        "additionalProperties": false
                                                      }
                                                    },
                                                    "type": "object",
                                                    "additionalProperties": false
                                                  },
                                                  "tls": {
                                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                                    "properties": {
                                                      "alpnProtocols": {
                                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                                        "items": {
                                                          "maxLength": 64,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      },
                                                      "caCertificateRefs": {
                                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                                        "items": {
                                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                                          "properties": {
                                                            "key": {
                                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                                              "enum": [
                                                                "ConfigMap",
                                                                "Secret"
                                                              ],
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced CA certificate source.",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "certificateSource": {
                                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                                        "enum": [
                                                          "Inline",
                                                          "SPIFFE"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "insecureSkipVerify": {
                                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                                        "enum": [
                                                          "All",
                                                          "Hostname"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "keyExchangeGroups": {
                                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                                        "items": {
                                                          "enum": [
                                                            "P-256",
                                                            "P-384",
                                                            "X25519",
                                                            "X25519_MLKEM768"
                                                          ],
                                                          "type": "string"
                                                        },
                                                        "type": "array"
                                                      },
                                                      "mtlsCertificateRef": {
                                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                                        "items": {
                                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                                          "properties": {
                                                            "group": {
                                                              "description": "API group of the referenced credential; empty selects the core API group",
                                                              "type": "string"
                                                            },
                                                            "kind": {
                                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                              "type": "string"
                                                            },
                                                            "name": {
                                                              "description": "Name of the referenced credential",
                                                              "maxLength": 253,
                                                              "minLength": 1,
                                                              "type": "string"
                                                            }
                                                          },
                                                          "required": [
                                                            "name"
                                                          ],
                                                          "type": "object",
                                                          "x-kubernetes-map-type": "atomic",
                                                          "x-kubernetes-validations": [
                                                            {
                                                              "message": "custom credential refs must set both group and kind",
                                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                            }
                                                          ],
                                                          "additionalProperties": false
                                                        },
                                                        "maxItems": 1,
                                                        "type": "array",
                                                        "x-kubernetes-list-type": "atomic"
                                                      },
                                                      "sni": {
                                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                                        "maxLength": 253,
                                                        "minLength": 1,
                                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                        "type": "string"
                                                      },
                                                      "verifySubjectAltNames": {
                                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                                        "items": {
                                                          "maxLength": 256,
                                                          "minLength": 1,
                                                          "type": "string"
                                                        },
                                                        "maxItems": 16,
                                                        "minItems": 1,
                                                        "type": "array"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                                      },
                                                      {
                                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                                      },
                                                      {
                                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                                      },
                                                      {
                                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  },
                                                  "tunnel": {
                                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                                    "properties": {
                                                      "backendRef": {
                                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                                        "properties": {
                                                          "group": {
                                                            "default": "",
                                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                                            "maxLength": 253,
                                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                            "type": "string"
                                                          },
                                                          "kind": {
                                                            "default": "Service",
                                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "name": {
                                                            "description": "Name is the name of the referent.",
                                                            "maxLength": 253,
                                                            "minLength": 1,
                                                            "type": "string"
                                                          },
                                                          "namespace": {
                                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                                            "maxLength": 63,
                                                            "minLength": 1,
                                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                                            "type": "string"
                                                          },
                                                          "port": {
                                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                                            "format": "int32",
                                                            "maximum": 65535,
                                                            "minimum": 1,
                                                            "type": "integer"
                                                          }
                                                        },
                                                        "required": [
                                                          "name"
                                                        ],
                                                        "type": "object",
                                                        "x-kubernetes-validations": [
                                                          {
                                                            "message": "Must have port for Service reference",
                                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                                          }
                                                        ],
                                                        "additionalProperties": false
                                                      },
                                                      "mode": {
                                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                                        "enum": [
                                                          "Auto",
                                                          "Connect"
                                                        ],
                                                        "type": "string"
                                                      },
                                                      "url": {
                                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                                        "maxLength": 1024,
                                                        "minLength": 1,
                                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                                        "type": "string"
                                                      }
                                                    },
                                                    "type": "object",
                                                    "x-kubernetes-validations": [
                                                      {
                                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                                      },
                                                      {
                                                        "message": "url must not include a path for backend tunnel",
                                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                                      }
                                                    ],
                                                    "additionalProperties": false
                                                  }
                                                },
                                                "type": "object",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              },
                                              "projectId": {
                                                "description": "Google Cloud project ID.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "templateId": {
                                                "description": "Template ID for Google Model Armor.",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "projectId",
                                              "templateId"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "regex": {
                                            "description": "Regular expression (regex) matching for prompt guards and data masking.",
                                            "properties": {
                                              "action": {
                                                "description": "The action to take if a regex pattern is matched in a request or response.\nThe action applies to request and response matches alike. Note that\n`Mask` is not applied to streamed responses: matched content in a\nstreamed response is passed through unmodified.\nDefaults to `Mask`.",
                                                "enum": [
                                                  "Audit",
                                                  "Mask",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "builtins": {
                                                "description": "Built-in regex patterns to match against the request or response.\nMatches and built-ins are additive.",
                                                "items": {
                                                  "description": "Built-in regex patterns for specific types of strings in prompts.\nFor example, if you specify `CreditCard`, any credit card numbers\nin the request or response are matched.",
                                                  "enum": [
                                                    "CaSin",
                                                    "CreditCard",
                                                    "Email",
                                                    "PhoneNumber",
                                                    "Ssn"
                                                  ],
                                                  "type": "string"
                                                },
                                                "type": "array"
                                              },
                                              "matches": {
                                                "description": "Regex patterns to match against the request or response.\nMatches and built-ins are additive.",
                                                "items": {
                                                  "maxLength": 1024,
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "type": "array"
                                              }
                                            },
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "response": {
                                            "description": "Custom response message to return to the client. If not specified, defaults to\n`The response was rejected due to inappropriate content`.",
                                            "properties": {
                                              "message": {
                                                "description": "Custom response message to return to the client. If not specified, defaults to\n`The request was rejected due to inappropriate content`.",
                                                "type": "string"
                                              },
                                              "statusCode": {
                                                "description": "Status code to return to the client. Defaults to 403.",
                                                "format": "int32",
                                                "maximum": 599,
                                                "minimum": 200,
                                                "type": "integer"
                                              }
                                            },
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "webhook": {
                                            "description": "Webhook that receives responses for prompt guarding.",
                                            "properties": {
                                              "action": {
                                                "description": "Action controls whether the webhook's verdict is enforced or only observed.\n`Reject` (the default) enforces it; `Audit` records the would-be action\nwithout blocking or masking.",
                                                "enum": [
                                                  "Audit",
                                                  "Reject"
                                                ],
                                                "type": "string"
                                              },
                                              "backendRef": {
                                                "description": "Webhook server to reach.\n\nSupported types: Service and Backend.",
                                                "properties": {
                                                  "group": {
                                                    "default": "",
                                                    "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                                    "maxLength": 253,
                                                    "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                                    "type": "string"
                                                  },
                                                  "kind": {
                                                    "default": "Service",
                                                    "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                                    "maxLength": 63,
                                                    "minLength": 1,
                                                    "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                                    "type": "string"
                                                  },
                                                  "name": {
                                                    "description": "Name is the name of the referent.",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  },
                                                  "namespace": {
                                                    "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                                    "maxLength": 63,
                                                    "minLength": 1,
                                                    "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                                    "type": "string"
                                                  },
                                                  "port": {
                                                    "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                                    "format": "int32",
                                                    "maximum": 65535,
                                                    "minimum": 1,
                                                    "type": "integer"
                                                  }
                                                },
                                                "required": [
                                                  "name"
                                                ],
                                                "type": "object",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "Must have port for Service reference",
                                                    "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              },
                                              "failureMode": {
                                                "description": "Behavior when the webhook guardrail is unavailable\nor returns an error. `FailOpen` allows the request to continue.\n`FailClosed` (default) rejects the request.",
                                                "enum": [
                                                  "FailClosed",
                                                  "FailOpen"
                                                ],
                                                "type": "string"
                                              },
                                              "forwardHeaderMatches": {
                                                "description": "HTTP header matches used to select the headers to forward to the webhook.\nRequest headers are used when forwarding requests and response headers\nare used when forwarding responses.\nBy default, no headers are forwarded.",
                                                "items": {
                                                  "description": "HTTPHeaderMatch describes how to select a HTTP route by matching HTTP request\nheaders.",
                                                  "properties": {
                                                    "name": {
                                                      "description": "Name of the HTTP header to match, case-insensitive. When names are equivalent, only the first matching entry is used",
                                                      "maxLength": 256,
                                                      "minLength": 1,
                                                      "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                      "type": "string"
                                                    },
                                                    "type": {
                                                      "default": "Exact",
                                                      "description": "How to match against the header value: `Exact` (default) or `RegularExpression`. The regex dialect is implementation-specific",
                                                      "enum": [
                                                        "Exact",
                                                        "RegularExpression"
                                                      ],
                                                      "type": "string"
                                                    },
                                                    "value": {
                                                      "description": "Value of the HTTP header to match",
                                                      "maxLength": 4096,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    }
                                                  },
                                                  "required": [
                                                    "name",
                                                    "value"
                                                  ],
                                                  "type": "object",
                                                  "additionalProperties": false
                                                },
                                                "type": "array"
                                              },
                                              "headers": {
                                                "additionalProperties": {
                                                  "description": "A Common Expression Language (CEL) expression.",
                                                  "maxLength": 16384,
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "description": "CEL-computed headers to include in webhook requests.",
                                                "maxProperties": 64,
                                                "type": "object"
                                              }
                                            },
                                            "required": [
                                              "backendRef"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "exactly one of the fields in [regex webhook bedrockGuardrails googleModelArmor] must be set",
                                            "rule": "(has(self.regex)?1:0)+(has(self.webhook)?1:0)+(has(self.bedrockGuardrails)?1:0)+(has(self.googleModelArmor)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "maxItems": 8,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "streaming": {
                                      "description": "Apply prompt guards to streaming responses and realtime websocket messages.\nDefaults to disabled to preserve streaming throughput unless explicitly enabled.",
                                      "enum": [
                                        "Enabled"
                                      ],
                                      "type": "string"
                                    }
                                  },
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "at least one of the fields in [request response] must be set",
                                      "rule": "[has(self.request),has(self.response)].filter(x,x==true).size() >= 1"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "routes": {
                                  "additionalProperties": {
                                    "description": "How the AI gateway should process incoming requests\nbased on the URL path and the API format expected.",
                                    "enum": [
                                      "AnthropicTokenCount",
                                      "Completions",
                                      "Detect",
                                      "Embeddings",
                                      "GeminiCountTokens",
                                      "GenerateContent",
                                      "Messages",
                                      "Models",
                                      "Passthrough",
                                      "Realtime",
                                      "Rerank",
                                      "Responses"
                                    ],
                                    "type": "string"
                                  },
                                  "description": "Rules for identifying the type of traffic to handle.\nThe keys are URL path suffixes matched using ends-with comparison, for\nexample `\"/v1/chat/completions\"`.\nThe special `*` wildcard matches any path.\nIf not specified, all traffic defaults to `completions` type.",
                                  "type": "object"
                                },
                                "transformations": {
                                  "description": "CEL transformations to compute and set fields in the request body.\nThe expression result overwrites any existing value for that field.\nThis has a higher priority than `overrides` if both are set for the same\nkey.",
                                  "items": {
                                    "description": "Maps a request JSON field to a CEL expression.\nThe expression is evaluated against the current request body and its result\nis assigned to the configured field.",
                                    "properties": {
                                      "expression": {
                                        "description": "CEL expression used to compute the field value.",
                                        "maxLength": 16384,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "field": {
                                        "description": "Name of the field to set.",
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "expression",
                                      "field"
                                    ],
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "maxItems": 64,
                                  "minItems": 1,
                                  "type": "array",
                                  "x-kubernetes-list-map-keys": [
                                    "field"
                                  ],
                                  "x-kubernetes-list-type": "map"
                                }
                              },
                              "type": "object",
                              "x-kubernetes-validations": [
                                {
                                  "message": "at least one of the fields in [defaults finalTransformations modelAliases overrides prompt promptCaching promptGuard routes transformations] must be set",
                                  "rule": "[has(self.defaults),has(self.finalTransformations),has(self.modelAliases),has(self.overrides),has(self.prompt),has(self.promptCaching),has(self.promptGuard),has(self.routes),has(self.transformations)].filter(x,x==true).size() >= 1"
                                }
                              ],
                              "additionalProperties": false
                            },
                            "auth": {
                              "description": "Settings for managing authentication to the backend",
                              "properties": {
                                "aws": {
                                  "description": "Explicit AWS authentication method for the backend.\nWhen omitted, default AWS SDK credential discovery is used.",
                                  "properties": {
                                    "assumeRole": {
                                      "description": "AWS STS AssumeRole settings to use before signing backend requests.\nAmbient AWS credentials are used as the source credentials for STS.",
                                      "properties": {
                                        "externalId": {
                                          "description": "ExternalID is set when the role's trust policy requires sts:ExternalId.",
                                          "maxLength": 1224,
                                          "minLength": 2,
                                          "pattern": "^[\\w+=,.@:/-]+$",
                                          "type": "string"
                                        },
                                        "roleArn": {
                                          "description": "AWS IAM role ARN to assume.",
                                          "minLength": 1,
                                          "pattern": "^arn:aws[a-z-]*:iam::[0-9]{12}:role/.+$",
                                          "type": "string"
                                        },
                                        "sessionName": {
                                          "description": "SessionName is a custom session name (RoleSessionName) for CloudTrail and\nCost & Usage Report attribution. If unset, AWS generates a random name.",
                                          "pattern": "^[\\w+=,.@-]{2,64}$",
                                          "type": "string"
                                        },
                                        "sessionNameExpression": {
                                          "description": "SessionNameExpression is a CEL expression evaluated against each request\nto produce the session name (RoleSessionName), for example `jwt.sub` or\n`request.headers[\"x-team\"]`. If the expression does not produce a valid\nsession name at request time, the request is rejected.",
                                          "maxLength": 16384,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "tags": {
                                          "description": "Session tags passed to STS AssumeRole for cost attribution in the AWS Cost\n& Usage Report, once activated. STS allows at most 50 per role session.",
                                          "items": {
                                            "description": "AwsSessionTag is an AWS STS session tag passed to AssumeRole for cost\nattribution. Exactly one of value and expression must be set.",
                                            "properties": {
                                              "expression": {
                                                "description": "CEL expression evaluated against each request to produce the tag value,\nfor example `jwt.sub` or `request.headers[\"x-app\"]`. Requests with invalid\ntag values are rejected.",
                                                "maxLength": 16384,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "key": {
                                                "description": "Key is the tag key.",
                                                "maxLength": 128,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "value": {
                                                "description": "Value is a static tag value.",
                                                "maxLength": 256,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "key"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "exactly one of value or expression must be set",
                                                "rule": "has(self.value) != has(self.expression)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "maxItems": 50,
                                          "type": "array",
                                          "x-kubernetes-list-map-keys": [
                                            "key"
                                          ],
                                          "x-kubernetes-list-type": "map"
                                        }
                                      },
                                      "required": [
                                        "roleArn"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "at most one of the fields in [sessionName sessionNameExpression] may be set",
                                          "rule": "(has(self.sessionName)?1:0)+(has(self.sessionNameExpression)?1:0) <= 1"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "region": {
                                      "description": "AWS SigV4 signing region, for example `us-east-1`. Set this when the\ntarget AWS service is in a different region than the gateway. If unset,\ntyped AWS backends may provide this automatically; otherwise the ambient\nAWS region is used.",
                                      "maxLength": 256,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "secretRef": {
                                      "description": "Credential source for AWS credentials, defaulting to a Kubernetes `Secret`.\nThe default Secret resolver expects `accessKey`, `secretKey`, and optional\n`sessionToken` keys.",
                                      "properties": {
                                        "group": {
                                          "description": "API group of the referenced credential; empty selects the core API group",
                                          "type": "string"
                                        },
                                        "kind": {
                                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                          "type": "string"
                                        },
                                        "name": {
                                          "description": "Name of the referenced credential",
                                          "maxLength": 253,
                                          "minLength": 1,
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-map-type": "atomic",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "custom credential refs must set both group and kind",
                                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "serviceName": {
                                      "description": "AWS SigV4 signing service name, for example\n`bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS\nbackends may provide this automatically.",
                                      "maxLength": 256,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "secretRef and assumeRole are mutually exclusive",
                                      "rule": "!(has(self.secretRef) && has(self.assumeRole))"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "azure": {
                                  "description": "Azure authentication method for the backend.",
                                  "properties": {
                                    "managedIdentity": {
                                      "description": "Managed identity authentication settings. Leave this object empty to use\nthe system-assigned identity. To use a user-assigned identity, set one of\n`clientId`, `objectId`, or `resourceId`.",
                                      "properties": {
                                        "clientId": {
                                          "description": "Client ID of the user-assigned managed identity.",
                                          "type": "string"
                                        },
                                        "objectId": {
                                          "description": "Object ID of the user-assigned managed identity.",
                                          "type": "string"
                                        },
                                        "resourceId": {
                                          "description": "Resource ID of the user-assigned managed identity.",
                                          "type": "string"
                                        }
                                      },
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "at most one of the fields in [clientId objectId resourceId] may be set",
                                          "rule": "(has(self.clientId)?1:0)+(has(self.objectId)?1:0)+(has(self.resourceId)?1:0) <= 1"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "scopes": {
                                      "description": "Scopes requested for the Azure access token. When omitted, the scope is\ninferred from the backend hostname. Managed Identity supports exactly one\nscope.",
                                      "items": {
                                        "type": "string"
                                      },
                                      "maxItems": 64,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "secretRef": {
                                      "description": "Credential source for Azure credentials, defaulting to a Kubernetes\n`Secret`. The default Secret resolver expects `clientID`, `tenantID`, and\n`clientSecret` keys.",
                                      "properties": {
                                        "group": {
                                          "description": "API group of the referenced credential; empty selects the core API group",
                                          "type": "string"
                                        },
                                        "kind": {
                                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                          "type": "string"
                                        },
                                        "name": {
                                          "description": "Name of the referenced credential",
                                          "maxLength": 253,
                                          "minLength": 1,
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-map-type": "atomic",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "custom credential refs must set both group and kind",
                                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "workloadIdentity": {
                                      "description": "Workload identity authentication settings. Uses the federated token and\nAzure env vars projected into the data plane pod. Recommended on AKS with\nWorkload Identity enabled.",
                                      "type": "object"
                                    }
                                  },
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "managedIdentity supports exactly one scope",
                                      "rule": "!has(self.managedIdentity) || !has(self.scopes) || self.scopes.size() == 1"
                                    },
                                    {
                                      "message": "at most one of the fields in [secretRef managedIdentity workloadIdentity] may be set",
                                      "rule": "(has(self.secretRef)?1:0)+(has(self.managedIdentity)?1:0)+(has(self.workloadIdentity)?1:0) <= 1"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "credentials": {
                                  "description": "Credentials is a list of additional credentials to inject on the\nbackend request. Each entry resolves a Secret key and writes its value\nto the entry's location. `credentials` is independent of the primary\n`key`/`secretRef`/`passthrough` mechanism and may be set on its own or\nalongside it.",
                                  "items": {
                                    "description": "BackendAuthCredential specifies one additional credential to inject on the\nbackend request.",
                                    "properties": {
                                      "location": {
                                        "description": "Where the credential is inserted on the backend request.",
                                        "properties": {
                                          "cookie": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "header": {
                                            "properties": {
                                              "name": {
                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                "type": "string"
                                              },
                                              "prefix": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "queryParameter": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "secretRef": {
                                        "description": "SecretRef references a Kubernetes Secret holding the credential value, and\noptionally overrides the key read from it. Defaults to `Authorization`,\nmatching the key convention used by the top-level `secretRef`.",
                                        "properties": {
                                          "group": {
                                            "description": "API group of the referenced credential; empty selects the core API group",
                                            "type": "string"
                                          },
                                          "key": {
                                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "kind": {
                                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name of the referenced credential",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-map-type": "atomic",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "custom credential refs must set both group and kind",
                                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                          }
                                        ],
                                        "additionalProperties": false
                                      }
                                    },
                                    "required": [
                                      "location",
                                      "secretRef"
                                    ],
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "maxItems": 8,
                                  "minItems": 1,
                                  "type": "array",
                                  "x-kubernetes-list-type": "atomic"
                                },
                                "crossAppAccess": {
                                  "description": "Cross App Access (Identity Assertion / ID-JAG) authentication.",
                                  "properties": {
                                    "accessTokenScopes": {
                                      "description": "Scopes requested when exchanging the ID-JAG for an access token.\nWhen omitted, defaults to Scopes. Set to an empty list to omit scope.",
                                      "items": {
                                        "type": "string"
                                      },
                                      "maxItems": 64,
                                      "type": "array"
                                    },
                                    "audience": {
                                      "description": "Identifier of the resource authorization server. The issued ID-JAG is bound to this audience.",
                                      "maxLength": 256,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "cache": {
                                      "description": "Response cache configuration.",
                                      "properties": {
                                        "inMemory": {
                                          "properties": {
                                            "defaultTtl": {
                                              "description": "TTL used when the token endpoint omits expires_in. Default 300s.",
                                              "maxLength": 32,
                                              "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                              "type": "string",
                                              "x-kubernetes-validations": [
                                                {
                                                  "message": "defaultTtl must be at least 1 second",
                                                  "rule": "duration(self) >= duration('1s')"
                                                }
                                              ]
                                            },
                                            "maxEntries": {
                                              "description": "Default 8192; 0 disables the cache.",
                                              "format": "int32",
                                              "type": "integer"
                                            }
                                          },
                                          "type": "object",
                                          "additionalProperties": false
                                        }
                                      },
                                      "type": "object",
                                      "additionalProperties": false
                                    },
                                    "identityProvider": {
                                      "description": "User identity provider authorization server, used for the RFC 8693 ID-JAG exchange.",
                                      "properties": {
                                        "backendRef": {
                                          "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                          "properties": {
                                            "group": {
                                              "default": "",
                                              "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                              "maxLength": 253,
                                              "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "default": "Service",
                                              "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                              "maxLength": 63,
                                              "minLength": 1,
                                              "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name is the name of the referent.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "namespace": {
                                              "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                              "maxLength": 63,
                                              "minLength": 1,
                                              "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                              "type": "string"
                                            },
                                            "port": {
                                              "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                              "format": "int32",
                                              "maximum": 65535,
                                              "minimum": 1,
                                              "type": "integer"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "Must have port for Service reference",
                                              "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "clientAuth": {
                                          "description": "Client authentication for the token endpoint.",
                                          "properties": {
                                            "clientId": {
                                              "description": "Client ID sent to the token endpoint.",
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "method": {
                                              "description": "Client authentication method. Defaults to ClientSecretBasic.",
                                              "enum": [
                                                "ClientSecretBasic",
                                                "ClientSecretPost",
                                                "PrivateKeyJwt"
                                              ],
                                              "type": "string"
                                            },
                                            "privateKeyJwt": {
                                              "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                                              "properties": {
                                                "alg": {
                                                  "description": "JWS signing algorithm. Defaults to RS256.",
                                                  "enum": [
                                                    "ES256",
                                                    "ES384",
                                                    "PS256",
                                                    "RS256",
                                                    "RS384",
                                                    "RS512"
                                                  ],
                                                  "type": "string"
                                                },
                                                "assertionAudience": {
                                                  "description": "Audience for the client assertion, typically the token endpoint URL.",
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "certificateHeader": {
                                                  "description": "JWS certificate header. Required when certificateRef is set.",
                                                  "enum": [
                                                    "x5c",
                                                    "x5t#S256"
                                                  ],
                                                  "type": "string"
                                                },
                                                "certificateRef": {
                                                  "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                                                  "properties": {
                                                    "group": {
                                                      "description": "API group of the referenced credential; empty selects the core API group",
                                                      "type": "string"
                                                    },
                                                    "key": {
                                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                      "maxLength": 253,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    },
                                                    "kind": {
                                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                      "type": "string"
                                                    },
                                                    "name": {
                                                      "description": "Name of the referenced credential",
                                                      "maxLength": 253,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    }
                                                  },
                                                  "required": [
                                                    "name"
                                                  ],
                                                  "type": "object",
                                                  "x-kubernetes-map-type": "atomic",
                                                  "x-kubernetes-validations": [
                                                    {
                                                      "message": "custom credential refs must set both group and kind",
                                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                    }
                                                  ],
                                                  "additionalProperties": false
                                                },
                                                "kid": {
                                                  "description": "Optional JWS key ID header.",
                                                  "type": "string"
                                                },
                                                "signingKeyRef": {
                                                  "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                                                  "properties": {
                                                    "group": {
                                                      "description": "API group of the referenced credential; empty selects the core API group",
                                                      "type": "string"
                                                    },
                                                    "key": {
                                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                      "maxLength": 253,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    },
                                                    "kind": {
                                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                      "type": "string"
                                                    },
                                                    "name": {
                                                      "description": "Name of the referenced credential",
                                                      "maxLength": 253,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    }
                                                  },
                                                  "required": [
                                                    "name"
                                                  ],
                                                  "type": "object",
                                                  "x-kubernetes-map-type": "atomic",
                                                  "x-kubernetes-validations": [
                                                    {
                                                      "message": "custom credential refs must set both group and kind",
                                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                    }
                                                  ],
                                                  "additionalProperties": false
                                                }
                                              },
                                              "required": [
                                                "assertionAudience",
                                                "signingKeyRef"
                                              ],
                                              "type": "object",
                                              "x-kubernetes-validations": [
                                                {
                                                  "message": "certificateRef and certificateHeader must be set together",
                                                  "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                                                }
                                              ],
                                              "additionalProperties": false
                                            },
                                            "secretRef": {
                                              "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                                              "properties": {
                                                "group": {
                                                  "description": "API group of the referenced credential; empty selects the core API group",
                                                  "type": "string"
                                                },
                                                "key": {
                                                  "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                  "maxLength": 253,
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "kind": {
                                                  "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                  "type": "string"
                                                },
                                                "name": {
                                                  "description": "Name of the referenced credential",
                                                  "maxLength": 253,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "x-kubernetes-map-type": "atomic",
                                              "x-kubernetes-validations": [
                                                {
                                                  "message": "custom credential refs must set both group and kind",
                                                  "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                }
                                              ],
                                              "additionalProperties": false
                                            }
                                          },
                                          "required": [
                                            "clientId"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "privateKeyJwt settings require method PrivateKeyJwt",
                                              "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                                            },
                                            {
                                              "message": "secretRef is not valid with method PrivateKeyJwt",
                                              "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                                            },
                                            {
                                              "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                                              "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "path": {
                                          "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                                          "pattern": "^/",
                                          "type": "string"
                                        },
                                        "url": {
                                          "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                          "maxLength": 1024,
                                          "minLength": 1,
                                          "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "clientAuth"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "path may not be set when url is set",
                                          "rule": "has(self.url) ? !has(self.path) : true"
                                        },
                                        {
                                          "message": "exactly one of the fields in [backendRef url] must be set",
                                          "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "resourceAuthorizationServer": {
                                      "description": "Resource authorization server, used for the RFC 7523 jwt-bearer exchange.",
                                      "properties": {
                                        "backendRef": {
                                          "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                          "properties": {
                                            "group": {
                                              "default": "",
                                              "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                              "maxLength": 253,
                                              "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "default": "Service",
                                              "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                              "maxLength": 63,
                                              "minLength": 1,
                                              "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name is the name of the referent.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "namespace": {
                                              "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                              "maxLength": 63,
                                              "minLength": 1,
                                              "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                              "type": "string"
                                            },
                                            "port": {
                                              "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                              "format": "int32",
                                              "maximum": 65535,
                                              "minimum": 1,
                                              "type": "integer"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "Must have port for Service reference",
                                              "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "clientAuth": {
                                          "description": "Client authentication for the token endpoint.",
                                          "properties": {
                                            "clientId": {
                                              "description": "Client ID sent to the token endpoint.",
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "method": {
                                              "description": "Client authentication method. Defaults to ClientSecretBasic.",
                                              "enum": [
                                                "ClientSecretBasic",
                                                "ClientSecretPost",
                                                "PrivateKeyJwt"
                                              ],
                                              "type": "string"
                                            },
                                            "privateKeyJwt": {
                                              "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                                              "properties": {
                                                "alg": {
                                                  "description": "JWS signing algorithm. Defaults to RS256.",
                                                  "enum": [
                                                    "ES256",
                                                    "ES384",
                                                    "PS256",
                                                    "RS256",
                                                    "RS384",
                                                    "RS512"
                                                  ],
                                                  "type": "string"
                                                },
                                                "assertionAudience": {
                                                  "description": "Audience for the client assertion, typically the token endpoint URL.",
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "certificateHeader": {
                                                  "description": "JWS certificate header. Required when certificateRef is set.",
                                                  "enum": [
                                                    "x5c",
                                                    "x5t#S256"
                                                  ],
                                                  "type": "string"
                                                },
                                                "certificateRef": {
                                                  "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                                                  "properties": {
                                                    "group": {
                                                      "description": "API group of the referenced credential; empty selects the core API group",
                                                      "type": "string"
                                                    },
                                                    "key": {
                                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                      "maxLength": 253,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    },
                                                    "kind": {
                                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                      "type": "string"
                                                    },
                                                    "name": {
                                                      "description": "Name of the referenced credential",
                                                      "maxLength": 253,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    }
                                                  },
                                                  "required": [
                                                    "name"
                                                  ],
                                                  "type": "object",
                                                  "x-kubernetes-map-type": "atomic",
                                                  "x-kubernetes-validations": [
                                                    {
                                                      "message": "custom credential refs must set both group and kind",
                                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                    }
                                                  ],
                                                  "additionalProperties": false
                                                },
                                                "kid": {
                                                  "description": "Optional JWS key ID header.",
                                                  "type": "string"
                                                },
                                                "signingKeyRef": {
                                                  "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                                                  "properties": {
                                                    "group": {
                                                      "description": "API group of the referenced credential; empty selects the core API group",
                                                      "type": "string"
                                                    },
                                                    "key": {
                                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                      "maxLength": 253,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    },
                                                    "kind": {
                                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                      "type": "string"
                                                    },
                                                    "name": {
                                                      "description": "Name of the referenced credential",
                                                      "maxLength": 253,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    }
                                                  },
                                                  "required": [
                                                    "name"
                                                  ],
                                                  "type": "object",
                                                  "x-kubernetes-map-type": "atomic",
                                                  "x-kubernetes-validations": [
                                                    {
                                                      "message": "custom credential refs must set both group and kind",
                                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                    }
                                                  ],
                                                  "additionalProperties": false
                                                }
                                              },
                                              "required": [
                                                "assertionAudience",
                                                "signingKeyRef"
                                              ],
                                              "type": "object",
                                              "x-kubernetes-validations": [
                                                {
                                                  "message": "certificateRef and certificateHeader must be set together",
                                                  "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                                                }
                                              ],
                                              "additionalProperties": false
                                            },
                                            "secretRef": {
                                              "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                                              "properties": {
                                                "group": {
                                                  "description": "API group of the referenced credential; empty selects the core API group",
                                                  "type": "string"
                                                },
                                                "key": {
                                                  "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                  "maxLength": 253,
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "kind": {
                                                  "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                  "type": "string"
                                                },
                                                "name": {
                                                  "description": "Name of the referenced credential",
                                                  "maxLength": 253,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "x-kubernetes-map-type": "atomic",
                                              "x-kubernetes-validations": [
                                                {
                                                  "message": "custom credential refs must set both group and kind",
                                                  "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                }
                                              ],
                                              "additionalProperties": false
                                            }
                                          },
                                          "required": [
                                            "clientId"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "privateKeyJwt settings require method PrivateKeyJwt",
                                              "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                                            },
                                            {
                                              "message": "secretRef is not valid with method PrivateKeyJwt",
                                              "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                                            },
                                            {
                                              "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                                              "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "path": {
                                          "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                                          "pattern": "^/",
                                          "type": "string"
                                        },
                                        "url": {
                                          "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                          "maxLength": 1024,
                                          "minLength": 1,
                                          "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "clientAuth"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "path may not be set when url is set",
                                          "rule": "has(self.url) ? !has(self.path) : true"
                                        },
                                        {
                                          "message": "exactly one of the fields in [backendRef url] must be set",
                                          "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "resources": {
                                      "description": "Resources sent to the token endpoint.",
                                      "items": {
                                        "type": "string"
                                      },
                                      "maxItems": 64,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "scopes": {
                                      "description": "Scopes requested when obtaining the ID-JAG from the identity provider.",
                                      "items": {
                                        "type": "string"
                                      },
                                      "maxItems": 64,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "subjectToken": {
                                      "description": "Subject token sent to the identity provider. Defaults to an OpenID Connect\nID token read from the Authorization Bearer header.",
                                      "properties": {
                                        "source": {
                                          "description": "Where to read the subject token. Defaults to the Authorization Bearer header.",
                                          "properties": {
                                            "cookie": {
                                              "properties": {
                                                "name": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            },
                                            "expression": {
                                              "description": "CEL expression that extracts the credential from the request.",
                                              "maxLength": 16384,
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "header": {
                                              "properties": {
                                                "name": {
                                                  "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                  "type": "string"
                                                },
                                                "prefix": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            },
                                            "queryParameter": {
                                              "properties": {
                                                "name": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            }
                                          },
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                                              "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "tokenType": {
                                          "description": "OAuth RFC 8693 subject token type. Defaults to IdToken",
                                          "type": "string"
                                        }
                                      },
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "tokenType IdJag is not supported by crossAppAccess",
                                          "rule": "!has(self.tokenType) || (self.tokenType != 'IdJag' && self.tokenType != 'urn:ietf:params:oauth:token-type:id-jag')"
                                        }
                                      ],
                                      "additionalProperties": false
                                    }
                                  },
                                  "required": [
                                    "audience",
                                    "identityProvider",
                                    "resourceAuthorizationServer"
                                  ],
                                  "type": "object",
                                  "additionalProperties": false
                                },
                                "gcp": {
                                  "description": "Google authentication method for the backend.\nWhen omitted, default Google credential discovery is used.",
                                  "properties": {
                                    "audience": {
                                      "description": "Explicit `aud` value for the ID token. Only\nvalid with `IdToken` type. If not set, the `aud` is automatically\nderived from the backend hostname.",
                                      "maxLength": 256,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "secretRef": {
                                      "description": "Credential source for ADC-compatible Google credential JSON, defaulting to\na Kubernetes `Secret`. By default, the value is read from\n`credentials.json`; set `secretRef.key` to override it. When omitted,\nambient credentials are used.",
                                      "properties": {
                                        "group": {
                                          "description": "API group of the referenced credential; empty selects the core API group",
                                          "type": "string"
                                        },
                                        "key": {
                                          "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                          "maxLength": 253,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "kind": {
                                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                          "type": "string"
                                        },
                                        "name": {
                                          "description": "Name of the referenced credential",
                                          "maxLength": 253,
                                          "minLength": 1,
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-map-type": "atomic",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "custom credential refs must set both group and kind",
                                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "type": {
                                      "description": "The type of token to generate. To authenticate to GCP services,\ngenerally an `AccessToken` is used. To authenticate to Cloud Run, an\n`IdToken` is used.",
                                      "enum": [
                                        "AccessToken",
                                        "IdToken"
                                      ],
                                      "type": "string"
                                    }
                                  },
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "audience is only valid with IdToken",
                                      "rule": "has(self.audience) ? self.type == 'IdToken' : true"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "jwtSign": {
                                  "description": "Signs a short-lived JWT with a private key on each request and sends it\nto the backend, for upstreams that require per-request keypair JWTs\n(e.g. the Snowflake SQL API) rather than a static credential.",
                                  "properties": {
                                    "alg": {
                                      "description": "JWS signing algorithm. Defaults to RS256.",
                                      "enum": [
                                        "ES256",
                                        "ES384",
                                        "PS256",
                                        "RS256",
                                        "RS384",
                                        "RS512"
                                      ],
                                      "type": "string"
                                    },
                                    "claims": {
                                      "additionalProperties": {
                                        "x-kubernetes-preserve-unknown-fields": true
                                      },
                                      "description": "Static claims added to every token (e.g. iss, sub, aud). Values may be\nany JSON value (e.g. a string, number, bool, or array). iat, exp, and\nnbf are reserved for the signer and cannot be configured here; the\ncontroller rejects them at translation time.",
                                      "type": "object"
                                    },
                                    "kid": {
                                      "description": "Optional JWS key ID header.",
                                      "type": "string"
                                    },
                                    "location": {
                                      "description": "Where the signed token is written on the backend request.\nDefaults to the Authorization header with a \"Bearer \" prefix.",
                                      "properties": {
                                        "cookie": {
                                          "properties": {
                                            "name": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        },
                                        "header": {
                                          "properties": {
                                            "name": {
                                              "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                              "type": "string"
                                            },
                                            "prefix": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        },
                                        "queryParameter": {
                                          "properties": {
                                            "name": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        }
                                      },
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                          "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "signingKeyRef": {
                                      "description": "Secret providing the `signingKey` key with a PEM-encoded RSA or EC private key.",
                                      "properties": {
                                        "group": {
                                          "description": "API group of the referenced credential; empty selects the core API group",
                                          "type": "string"
                                        },
                                        "kind": {
                                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                          "type": "string"
                                        },
                                        "name": {
                                          "description": "Name of the referenced credential",
                                          "maxLength": 253,
                                          "minLength": 1,
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-map-type": "atomic",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "custom credential refs must set both group and kind",
                                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "ttl": {
                                      "description": "Token lifetime used for exp. Defaults to 300s.",
                                      "maxLength": 32,
                                      "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                      "type": "string",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "ttl must be at least 1 second",
                                          "rule": "duration(self) >= duration('1s')"
                                        }
                                      ]
                                    }
                                  },
                                  "required": [
                                    "signingKeyRef"
                                  ],
                                  "type": "object",
                                  "additionalProperties": false
                                },
                                "key": {
                                  "description": "Inline key to use as the value of the\n`Authorization` header. This option is the least secure; usage of a\n`Secret` is preferred.",
                                  "maxLength": 2048,
                                  "type": "string"
                                },
                                "location": {
                                  "description": "Where backend credentials are inserted.\nIf omitted, credentials are written to the `Authorization` header with the `Bearer ` prefix.\nThis applies to `key`, `secretRef`, and `passthrough`. Entries in `credentials` carry their own location.",
                                  "properties": {
                                    "cookie": {
                                      "properties": {
                                        "name": {
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "additionalProperties": false
                                    },
                                    "header": {
                                      "properties": {
                                        "name": {
                                          "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                          "type": "string"
                                        },
                                        "prefix": {
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "additionalProperties": false
                                    },
                                    "queryParameter": {
                                      "properties": {
                                        "name": {
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "additionalProperties": false
                                    }
                                  },
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                      "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "oauthTokenExchange": {
                                  "description": "OAuth 2.0 token exchange (RFC 8693) / jwt-bearer (RFC 7523) authentication.",
                                  "properties": {
                                    "actorToken": {
                                      "description": "RFC 8693 delegation actor token. TokenExchange grant only.",
                                      "properties": {
                                        "mayAct": {
                                          "description": "may_act claim validation mode. When omitted, may_act is not enforced.",
                                          "enum": [
                                            "Required"
                                          ],
                                          "type": "string"
                                        },
                                        "source": {
                                          "description": "Where to read the actor token. Actor tokens have no default source.",
                                          "properties": {
                                            "cookie": {
                                              "properties": {
                                                "name": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            },
                                            "expression": {
                                              "description": "CEL expression that extracts the credential from the request.",
                                              "maxLength": 16384,
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "header": {
                                              "properties": {
                                                "name": {
                                                  "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                  "type": "string"
                                                },
                                                "prefix": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            },
                                            "queryParameter": {
                                              "properties": {
                                                "name": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            }
                                          },
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                                              "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "tokenType": {
                                          "description": "OAuth token type. Empty defaults to AccessToken. Custom absolute URI values\nare supported for actor tokens.",
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "source"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "mayAct Required requires tokenType Jwt",
                                          "rule": "!has(self.mayAct) || self.mayAct != 'Required' || (has(self.tokenType) && self.tokenType == 'Jwt')"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "additionalParams": {
                                      "additionalProperties": {
                                        "description": "A Common Expression Language (CEL) expression.",
                                        "maxLength": 16384,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "description": "Extra form params; values are CEL expressions over the incoming request.",
                                      "maxProperties": 64,
                                      "type": "object"
                                    },
                                    "audiences": {
                                      "description": "Audiences sent to the token endpoint.",
                                      "items": {
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "maxItems": 64,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "backendRef": {
                                      "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                      "properties": {
                                        "group": {
                                          "default": "",
                                          "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                          "maxLength": 253,
                                          "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                          "type": "string"
                                        },
                                        "kind": {
                                          "default": "Service",
                                          "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                          "maxLength": 63,
                                          "minLength": 1,
                                          "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                          "type": "string"
                                        },
                                        "name": {
                                          "description": "Name is the name of the referent.",
                                          "maxLength": 253,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "namespace": {
                                          "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                          "maxLength": 63,
                                          "minLength": 1,
                                          "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                          "type": "string"
                                        },
                                        "port": {
                                          "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                          "format": "int32",
                                          "maximum": 65535,
                                          "minimum": 1,
                                          "type": "integer"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "Must have port for Service reference",
                                          "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "cache": {
                                      "description": "Response cache configuration.",
                                      "properties": {
                                        "inMemory": {
                                          "properties": {
                                            "defaultTtl": {
                                              "description": "TTL used when the token endpoint omits expires_in. Default 300s.",
                                              "maxLength": 32,
                                              "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                              "type": "string",
                                              "x-kubernetes-validations": [
                                                {
                                                  "message": "defaultTtl must be at least 1 second",
                                                  "rule": "duration(self) >= duration('1s')"
                                                }
                                              ]
                                            },
                                            "maxEntries": {
                                              "description": "Default 8192; 0 disables the cache.",
                                              "format": "int32",
                                              "type": "integer"
                                            }
                                          },
                                          "type": "object",
                                          "additionalProperties": false
                                        }
                                      },
                                      "type": "object",
                                      "additionalProperties": false
                                    },
                                    "clientAuth": {
                                      "description": "Client authentication for the token endpoint. When unset, none is sent.",
                                      "properties": {
                                        "clientId": {
                                          "description": "Client ID sent to the token endpoint.",
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "method": {
                                          "description": "Client authentication method. Defaults to ClientSecretBasic.",
                                          "enum": [
                                            "ClientSecretBasic",
                                            "ClientSecretPost",
                                            "PrivateKeyJwt"
                                          ],
                                          "type": "string"
                                        },
                                        "privateKeyJwt": {
                                          "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                                          "properties": {
                                            "alg": {
                                              "description": "JWS signing algorithm. Defaults to RS256.",
                                              "enum": [
                                                "ES256",
                                                "ES384",
                                                "PS256",
                                                "RS256",
                                                "RS384",
                                                "RS512"
                                              ],
                                              "type": "string"
                                            },
                                            "assertionAudience": {
                                              "description": "Audience for the client assertion, typically the token endpoint URL.",
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "certificateHeader": {
                                              "description": "JWS certificate header. Required when certificateRef is set.",
                                              "enum": [
                                                "x5c",
                                                "x5t#S256"
                                              ],
                                              "type": "string"
                                            },
                                            "certificateRef": {
                                              "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                                              "properties": {
                                                "group": {
                                                  "description": "API group of the referenced credential; empty selects the core API group",
                                                  "type": "string"
                                                },
                                                "key": {
                                                  "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                  "maxLength": 253,
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "kind": {
                                                  "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                  "type": "string"
                                                },
                                                "name": {
                                                  "description": "Name of the referenced credential",
                                                  "maxLength": 253,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "x-kubernetes-map-type": "atomic",
                                              "x-kubernetes-validations": [
                                                {
                                                  "message": "custom credential refs must set both group and kind",
                                                  "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                }
                                              ],
                                              "additionalProperties": false
                                            },
                                            "kid": {
                                              "description": "Optional JWS key ID header.",
                                              "type": "string"
                                            },
                                            "signingKeyRef": {
                                              "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                                              "properties": {
                                                "group": {
                                                  "description": "API group of the referenced credential; empty selects the core API group",
                                                  "type": "string"
                                                },
                                                "key": {
                                                  "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                  "maxLength": 253,
                                                  "minLength": 1,
                                                  "type": "string"
                                                },
                                                "kind": {
                                                  "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                  "type": "string"
                                                },
                                                "name": {
                                                  "description": "Name of the referenced credential",
                                                  "maxLength": 253,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "x-kubernetes-map-type": "atomic",
                                              "x-kubernetes-validations": [
                                                {
                                                  "message": "custom credential refs must set both group and kind",
                                                  "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                }
                                              ],
                                              "additionalProperties": false
                                            }
                                          },
                                          "required": [
                                            "assertionAudience",
                                            "signingKeyRef"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "certificateRef and certificateHeader must be set together",
                                              "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "secretRef": {
                                          "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                                          "properties": {
                                            "group": {
                                              "description": "API group of the referenced credential; empty selects the core API group",
                                              "type": "string"
                                            },
                                            "key": {
                                              "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced credential",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "custom credential refs must set both group and kind",
                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                            }
                                          ],
                                          "additionalProperties": false
                                        }
                                      },
                                      "required": [
                                        "clientId"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "privateKeyJwt settings require method PrivateKeyJwt",
                                          "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                                        },
                                        {
                                          "message": "secretRef is not valid with method PrivateKeyJwt",
                                          "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                                        },
                                        {
                                          "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                                          "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "grantType": {
                                      "description": "RFC followed by the request. Defaults to TokenExchange (RFC 8693).",
                                      "enum": [
                                        "JwtBearer",
                                        "TokenExchange"
                                      ],
                                      "type": "string"
                                    },
                                    "location": {
                                      "description": "Where the exchanged token is written to the backend request.\nDefaults to Authorization: Bearer.",
                                      "properties": {
                                        "cookie": {
                                          "properties": {
                                            "name": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        },
                                        "header": {
                                          "properties": {
                                            "name": {
                                              "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                              "type": "string"
                                            },
                                            "prefix": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        },
                                        "queryParameter": {
                                          "properties": {
                                            "name": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        }
                                      },
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                          "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "path": {
                                      "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                                      "pattern": "^/",
                                      "type": "string"
                                    },
                                    "requestedTokenType": {
                                      "description": "RFC 8693 requested_token_type. Unlike subject/actor token types, only the\nbuilt-in values may be requested; custom URIs are not supported here.",
                                      "enum": [
                                        "AccessToken",
                                        "Jwt",
                                        "IdToken",
                                        "IdJag"
                                      ],
                                      "type": "string"
                                    },
                                    "resources": {
                                      "description": "Resources sent to the token endpoint.",
                                      "items": {
                                        "type": "string"
                                      },
                                      "maxItems": 64,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "scopes": {
                                      "description": "Scopes sent to the token endpoint.",
                                      "items": {
                                        "type": "string"
                                      },
                                      "maxItems": 64,
                                      "minItems": 1,
                                      "type": "array"
                                    },
                                    "subjectToken": {
                                      "description": "Subject token / assertion source and type. Defaults to Authorization Bearer, AccessToken.\nThe token type may be a built-in value or a custom absolute URI for providers\nthat support custom token exchange profiles.",
                                      "properties": {
                                        "source": {
                                          "description": "Where to read the token. CEL `expression` variant is permitted.",
                                          "properties": {
                                            "cookie": {
                                              "properties": {
                                                "name": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            },
                                            "expression": {
                                              "description": "CEL expression that extracts the credential from the request.",
                                              "maxLength": 16384,
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "header": {
                                              "properties": {
                                                "name": {
                                                  "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                  "type": "string"
                                                },
                                                "prefix": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            },
                                            "queryParameter": {
                                              "properties": {
                                                "name": {
                                                  "maxLength": 256,
                                                  "minLength": 1,
                                                  "type": "string"
                                                }
                                              },
                                              "required": [
                                                "name"
                                              ],
                                              "type": "object",
                                              "additionalProperties": false
                                            }
                                          },
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                                              "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "tokenType": {
                                          "description": "OAuth token type. Empty defaults to AccessToken. Custom absolute URI values\nare supported for subject tokens.",
                                          "type": "string"
                                        }
                                      },
                                      "type": "object",
                                      "additionalProperties": false
                                    },
                                    "url": {
                                      "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                      "maxLength": 1024,
                                      "minLength": 1,
                                      "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                      "type": "string"
                                    }
                                  },
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "actorToken is only valid with TokenExchange grantType",
                                      "rule": "!(has(self.actorToken) && has(self.grantType) && self.grantType == 'JwtBearer')"
                                    },
                                    {
                                      "message": "requestedTokenType is only valid with TokenExchange grantType",
                                      "rule": "!(has(self.requestedTokenType) && has(self.grantType) && self.grantType == 'JwtBearer')"
                                    },
                                    {
                                      "message": "requestedTokenType IdJag is only supported by crossAppAccess",
                                      "rule": "!has(self.requestedTokenType) || self.requestedTokenType != 'IdJag'"
                                    },
                                    {
                                      "message": "path may not be set when url is set",
                                      "rule": "has(self.url) ? !has(self.path) : true"
                                    },
                                    {
                                      "message": "exactly one of the fields in [backendRef url] must be set",
                                      "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "passthrough": {
                                  "description": "Reuses a client token already validated by another policy. Those policies\nmay strip client credentials; passthrough adds the original token back to\nthe backend request. Without client auth policies, this has no effect.",
                                  "type": "object"
                                },
                                "secretRef": {
                                  "description": "Credential source for the authorization value, defaulting to a Kubernetes\n`Secret`. By default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                                  "properties": {
                                    "group": {
                                      "description": "API group of the referenced credential; empty selects the core API group",
                                      "type": "string"
                                    },
                                    "key": {
                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "kind": {
                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                      "type": "string"
                                    },
                                    "name": {
                                      "description": "Name of the referenced credential",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name"
                                  ],
                                  "type": "object",
                                  "x-kubernetes-map-type": "atomic",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "custom credential refs must set both group and kind",
                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                    }
                                  ],
                                  "additionalProperties": false
                                }
                              },
                              "type": "object",
                              "x-kubernetes-validations": [
                                {
                                  "message": "must specify credentials, or at most one of key/secretRef/passthrough/aws/azure/gcp/oauthTokenExchange/crossAppAccess/jwtSign (credentials may be combined with a primary auth kind)",
                                  "rule": "has(self.credentials) || has(self.key) || has(self.secretRef) || has(self.passthrough) || has(self.aws) || has(self.azure) || has(self.gcp) || has(self.oauthTokenExchange) || has(self.crossAppAccess) || has(self.jwtSign)"
                                },
                                {
                                  "message": "location may only be set for key, secretRef, or passthrough auth",
                                  "rule": "has(self.location) ? has(self.key) || has(self.secretRef) || has(self.passthrough) : true"
                                },
                                {
                                  "message": "at most one of the fields in [key secretRef passthrough aws azure gcp oauthTokenExchange crossAppAccess jwtSign] may be set",
                                  "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0)+(has(self.passthrough)?1:0)+(has(self.aws)?1:0)+(has(self.azure)?1:0)+(has(self.gcp)?1:0)+(has(self.oauthTokenExchange)?1:0)+(has(self.crossAppAccess)?1:0)+(has(self.jwtSign)?1:0) <= 1"
                                }
                              ],
                              "additionalProperties": false
                            },
                            "authorization": {
                              "description": "Authorization rules that clients must satisfy after this AI provider is selected.",
                              "properties": {
                                "action": {
                                  "description": "The effect of this rule when it matches.\nIf unspecified, defaults to `Allow`.\n`Require` rules are cumulative: all require rules must match.",
                                  "enum": [
                                    "Allow",
                                    "Deny",
                                    "Require"
                                  ],
                                  "type": "string"
                                },
                                "policy": {
                                  "description": "The authorization rule to evaluate.\n\n* `Allow`: any matching allow rule allows the request.\n* `Require`: every require rule must match for the request to be allowed.\n* `Deny`: any matching deny rule denies the request.\n\n`Deny` is not recommended because expression failures fail to deny; prefer\n`Allow` or `Require`. If used, design expressions defensively against evaluation errors.\n\nIf at least one `Allow` rule is configured, requests are denied unless at\nleast one allow rule matches.",
                                  "properties": {
                                    "matchExpressions": {
                                      "description": "CEL expressions that must all evaluate to true for the rule to match.",
                                      "items": {
                                        "description": "A Common Expression Language (CEL) expression.",
                                        "maxLength": 16384,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "maxItems": 256,
                                      "minItems": 1,
                                      "type": "array"
                                    }
                                  },
                                  "required": [
                                    "matchExpressions"
                                  ],
                                  "type": "object",
                                  "additionalProperties": false
                                }
                              },
                              "required": [
                                "policy"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "health": {
                              "description": "Settings for passive and active health checking.",
                              "properties": {
                                "eviction": {
                                  "description": "Settings for evicting unhealthy backends.",
                                  "properties": {
                                    "consecutiveFailures": {
                                      "description": "Number of consecutive unhealthy responses required before the backend is evicted.\nFor example, a value of 5 means the backend must receive 5 unhealthy responses in a row before being evicted.\nWhen both consecutiveFailures and healthThreshold are set, the backend is evicted when either condition is met.\nWhen neither is set, a single unhealthy response can trigger eviction.",
                                      "format": "int32",
                                      "minimum": 0,
                                      "type": "integer"
                                    },
                                    "duration": {
                                      "description": "Base time a backend should be evicted after being marked unhealthy.\nSubsequent evictions use multiplicative backoff (duration * times_evicted).\nIf all endpoints are evicted, the load balancer falls back to returning evicted endpoints\nrather than failing entirely.\nIf unset, defaults to `3s`.",
                                      "maxLength": 32,
                                      "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                      "type": "string",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "duration must be at least 1 second",
                                          "rule": "duration(self) >= duration('1s')"
                                        }
                                      ]
                                    },
                                    "healthThreshold": {
                                      "description": "EWMA health score threshold, from 0 to 100. When set, a backend is evicted\nonly if its computed health drops below this value after an unhealthy\nresponse (e.g. 50 evicts when EWMA health falls below 50%). Unlike\nconsecutiveFailures, this sliding-window average lets a single success delay\neviction. If both are set, either condition evicts; if neither, a single\nunhealthy response evicts.",
                                      "format": "int32",
                                      "maximum": 100,
                                      "minimum": 0,
                                      "type": "integer"
                                    },
                                    "restoreHealth": {
                                      "description": "Health score from 0 to 100 assigned to a backend when it returns from eviction.\nFor gradual recovery, set below 100; for full recovery immediately, set 100.\nIf unset, the backend resumes with the health it had when evicted.",
                                      "format": "int32",
                                      "maximum": 100,
                                      "minimum": 0,
                                      "type": "integer"
                                    }
                                  },
                                  "type": "object",
                                  "additionalProperties": false
                                },
                                "unhealthyCondition": {
                                  "description": "CEL expression that determines whether a response indicates an unhealthy backend.\nWhen the expression evaluates to true, the backend is considered unhealthy and may be evicted.\n\nFor example, to evict on 5xx responses: `response.code >= 500`.\n\nWhen unset, any 5xx response, or a connection failure, is treated as unhealthy.\nThis default lowers the backend's health score but does not trigger eviction on its own.",
                                  "maxLength": 16384,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "type": "object",
                              "additionalProperties": false
                            },
                            "http": {
                              "description": "Settings for managing HTTP requests to the backend",
                              "properties": {
                                "requestTimeout": {
                                  "description": "Deadline for receiving a response from the backend.",
                                  "maxLength": 32,
                                  "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                  "type": "string",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "requestTimeout must be at least 1ms",
                                      "rule": "duration(self) >= duration('1ms')"
                                    }
                                  ]
                                },
                                "version": {
                                  "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                  "enum": [
                                    "HTTP1",
                                    "HTTP2"
                                  ],
                                  "type": "string"
                                }
                              },
                              "type": "object",
                              "additionalProperties": false
                            },
                            "tcp": {
                              "description": "Settings for managing TCP connections to the backend",
                              "properties": {
                                "connectTimeout": {
                                  "description": "Deadline for establishing a connection to\nthe destination.",
                                  "maxLength": 32,
                                  "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                  "type": "string",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "connectTimeout must be at least 100ms",
                                      "rule": "duration(self) >= duration('100ms')"
                                    }
                                  ]
                                },
                                "keepalive": {
                                  "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                  "properties": {
                                    "interval": {
                                      "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                      "maxLength": 32,
                                      "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                      "type": "string",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "interval must be at least 1 second",
                                          "rule": "duration(self) >= duration('1s')"
                                        }
                                      ]
                                    },
                                    "retries": {
                                      "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                      "format": "int32",
                                      "maximum": 64,
                                      "minimum": 1,
                                      "type": "integer"
                                    },
                                    "time": {
                                      "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                      "maxLength": 32,
                                      "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                      "type": "string",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "time must be at least 1 second",
                                          "rule": "duration(self) >= duration('1s')"
                                        }
                                      ]
                                    }
                                  },
                                  "type": "object",
                                  "additionalProperties": false
                                }
                              },
                              "type": "object",
                              "additionalProperties": false
                            },
                            "tls": {
                              "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                              "properties": {
                                "alpnProtocols": {
                                  "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                  "items": {
                                    "maxLength": 64,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "maxItems": 16,
                                  "minItems": 1,
                                  "type": "array"
                                },
                                "caCertificateRefs": {
                                  "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                  "items": {
                                    "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                    "properties": {
                                      "key": {
                                        "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                        "type": "string"
                                      },
                                      "kind": {
                                        "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                        "enum": [
                                          "ConfigMap",
                                          "Secret"
                                        ],
                                        "type": "string"
                                      },
                                      "name": {
                                        "description": "Name of the referenced CA certificate source.",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-map-type": "atomic",
                                    "additionalProperties": false
                                  },
                                  "maxItems": 1,
                                  "type": "array",
                                  "x-kubernetes-list-type": "atomic"
                                },
                                "certificateSource": {
                                  "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                  "enum": [
                                    "Inline",
                                    "SPIFFE"
                                  ],
                                  "type": "string"
                                },
                                "insecureSkipVerify": {
                                  "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                  "enum": [
                                    "All",
                                    "Hostname"
                                  ],
                                  "type": "string"
                                },
                                "keyExchangeGroups": {
                                  "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                  "items": {
                                    "enum": [
                                      "P-256",
                                      "P-384",
                                      "X25519",
                                      "X25519_MLKEM768"
                                    ],
                                    "type": "string"
                                  },
                                  "type": "array"
                                },
                                "mtlsCertificateRef": {
                                  "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                  "items": {
                                    "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                    "properties": {
                                      "group": {
                                        "description": "API group of the referenced credential; empty selects the core API group",
                                        "type": "string"
                                      },
                                      "kind": {
                                        "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                        "type": "string"
                                      },
                                      "name": {
                                        "description": "Name of the referenced credential",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-map-type": "atomic",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "custom credential refs must set both group and kind",
                                        "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "maxItems": 1,
                                  "type": "array",
                                  "x-kubernetes-list-type": "atomic"
                                },
                                "sni": {
                                  "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                  "type": "string"
                                },
                                "verifySubjectAltNames": {
                                  "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                  "items": {
                                    "maxLength": 256,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "maxItems": 16,
                                  "minItems": 1,
                                  "type": "array"
                                }
                              },
                              "type": "object",
                              "x-kubernetes-validations": [
                                {
                                  "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                  "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                },
                                {
                                  "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                  "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                },
                                {
                                  "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                  "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                },
                                {
                                  "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                  "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                }
                              ],
                              "additionalProperties": false
                            },
                            "transformation": {
                              "description": "Mutates and transforms requests and responses sent to and from the backend.",
                              "properties": {
                                "request": {
                                  "description": "Request transformation settings.",
                                  "properties": {
                                    "add": {
                                      "description": "Headers to add to the request and what each value\nshould be set to. If there is already a header with these values then\nappend the value as an extra entry.",
                                      "items": {
                                        "properties": {
                                          "name": {
                                            "description": "The name of the header to add.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                                "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                                              }
                                            ]
                                          },
                                          "value": {
                                            "description": "CEL expression that generates the output value for\nthe header.",
                                            "maxLength": 16384,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name",
                                          "value"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "maxItems": 16,
                                      "minItems": 1,
                                      "type": "array",
                                      "x-kubernetes-list-map-keys": [
                                        "name"
                                      ],
                                      "x-kubernetes-list-type": "map"
                                    },
                                    "body": {
                                      "description": "HTTP body transformation.",
                                      "maxLength": 16384,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "metadata": {
                                      "additionalProperties": {
                                        "description": "A Common Expression Language (CEL) expression.",
                                        "maxLength": 16384,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "description": "Stores CEL-evaluated values under the `metadata` CEL variable\nfor subsequent policy evaluations. `metadata` is evaluated before header\nor body transformations.",
                                      "maxProperties": 16,
                                      "minProperties": 1,
                                      "type": "object"
                                    },
                                    "remove": {
                                      "description": "Header names to remove from the request or\nresponse.",
                                      "items": {
                                        "description": "HTTP header name.",
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                            "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                                          }
                                        ]
                                      },
                                      "maxItems": 16,
                                      "minItems": 1,
                                      "type": "array",
                                      "x-kubernetes-list-type": "set"
                                    },
                                    "set": {
                                      "description": "Headers to set and the values to use.",
                                      "items": {
                                        "properties": {
                                          "name": {
                                            "description": "The name of the header to add.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                                "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                                              }
                                            ]
                                          },
                                          "value": {
                                            "description": "CEL expression that generates the output value for\nthe header.",
                                            "maxLength": 16384,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name",
                                          "value"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "maxItems": 16,
                                      "minItems": 1,
                                      "type": "array",
                                      "x-kubernetes-list-map-keys": [
                                        "name"
                                      ],
                                      "x-kubernetes-list-type": "map"
                                    }
                                  },
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "at least one of the fields in [add body metadata remove set] must be set",
                                      "rule": "[has(self.add),has(self.body),has(self.metadata),has(self.remove),has(self.set)].filter(x,x==true).size() >= 1"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "response": {
                                  "description": "Response transformation settings.",
                                  "properties": {
                                    "add": {
                                      "description": "Headers to add to the request and what each value\nshould be set to. If there is already a header with these values then\nappend the value as an extra entry.",
                                      "items": {
                                        "properties": {
                                          "name": {
                                            "description": "The name of the header to add.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                                "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                                              }
                                            ]
                                          },
                                          "value": {
                                            "description": "CEL expression that generates the output value for\nthe header.",
                                            "maxLength": 16384,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name",
                                          "value"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "maxItems": 16,
                                      "minItems": 1,
                                      "type": "array",
                                      "x-kubernetes-list-map-keys": [
                                        "name"
                                      ],
                                      "x-kubernetes-list-type": "map"
                                    },
                                    "body": {
                                      "description": "HTTP body transformation.",
                                      "maxLength": 16384,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "metadata": {
                                      "additionalProperties": {
                                        "description": "A Common Expression Language (CEL) expression.",
                                        "maxLength": 16384,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "description": "Stores CEL-evaluated values under the `metadata` CEL variable\nfor subsequent policy evaluations. `metadata` is evaluated before header\nor body transformations.",
                                      "maxProperties": 16,
                                      "minProperties": 1,
                                      "type": "object"
                                    },
                                    "remove": {
                                      "description": "Header names to remove from the request or\nresponse.",
                                      "items": {
                                        "description": "HTTP header name.",
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                            "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                                          }
                                        ]
                                      },
                                      "maxItems": 16,
                                      "minItems": 1,
                                      "type": "array",
                                      "x-kubernetes-list-type": "set"
                                    },
                                    "set": {
                                      "description": "Headers to set and the values to use.",
                                      "items": {
                                        "properties": {
                                          "name": {
                                            "description": "The name of the header to add.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                                "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                                              }
                                            ]
                                          },
                                          "value": {
                                            "description": "CEL expression that generates the output value for\nthe header.",
                                            "maxLength": 16384,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name",
                                          "value"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "maxItems": 16,
                                      "minItems": 1,
                                      "type": "array",
                                      "x-kubernetes-list-map-keys": [
                                        "name"
                                      ],
                                      "x-kubernetes-list-type": "map"
                                    }
                                  },
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "at least one of the fields in [add body metadata remove set] must be set",
                                      "rule": "[has(self.add),has(self.body),has(self.metadata),has(self.remove),has(self.set)].filter(x,x==true).size() >= 1"
                                    }
                                  ],
                                  "additionalProperties": false
                                }
                              },
                              "type": "object",
                              "x-kubernetes-validations": [
                                {
                                  "message": "at least one of the fields in [request response] must be set",
                                  "rule": "[has(self.request),has(self.response)].filter(x,x==true).size() >= 1"
                                }
                              ],
                              "additionalProperties": false
                            },
                            "tunnel": {
                              "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                              "properties": {
                                "backendRef": {
                                  "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                  "properties": {
                                    "group": {
                                      "default": "",
                                      "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                      "maxLength": 253,
                                      "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                      "type": "string"
                                    },
                                    "kind": {
                                      "default": "Service",
                                      "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                      "maxLength": 63,
                                      "minLength": 1,
                                      "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                      "type": "string"
                                    },
                                    "name": {
                                      "description": "Name is the name of the referent.",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "namespace": {
                                      "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                      "maxLength": 63,
                                      "minLength": 1,
                                      "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                      "type": "string"
                                    },
                                    "port": {
                                      "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                      "format": "int32",
                                      "maximum": 65535,
                                      "minimum": 1,
                                      "type": "integer"
                                    }
                                  },
                                  "required": [
                                    "name"
                                  ],
                                  "type": "object",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "Must have port for Service reference",
                                      "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "mode": {
                                  "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                  "enum": [
                                    "Auto",
                                    "Connect"
                                  ],
                                  "type": "string"
                                },
                                "url": {
                                  "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                  "maxLength": 1024,
                                  "minLength": 1,
                                  "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                  "type": "string"
                                }
                              },
                              "type": "object",
                              "x-kubernetes-validations": [
                                {
                                  "message": "exactly one of the fields in [backendRef url] must be set",
                                  "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                },
                                {
                                  "message": "url must not include a path for backend tunnel",
                                  "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                }
                              ],
                              "additionalProperties": false
                            }
                          },
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "at least one of the fields in [ai auth authorization health http tcp tls transformation tunnel] must be set",
                              "rule": "[has(self.ai),has(self.auth),has(self.authorization),has(self.health),has(self.http),has(self.tcp),has(self.tls),has(self.transformation),has(self.tunnel)].filter(x,x==true).size() >= 1"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "port": {
                          "description": "Port to send requests to.",
                          "format": "int32",
                          "maximum": 65535,
                          "minimum": 1,
                          "type": "integer"
                        },
                        "vertexai": {
                          "description": "Vertex AI provider settings.",
                          "properties": {
                            "model": {
                              "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            },
                            "projectId": {
                              "description": "The ID of the Google Cloud Project that you use for the Vertex AI.",
                              "maxLength": 64,
                              "minLength": 1,
                              "type": "string"
                            },
                            "region": {
                              "description": "The location of the Google Cloud Project that you use for the Vertex AI.\nSpecial values: `global` uses the global endpoint, while `us` and `eu` use restricted\nmulti-region endpoints. Other values are treated as regional locations.\nDefaults to `global` if not specified.",
                              "maxLength": 64,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "projectId"
                          ],
                          "type": "object",
                          "additionalProperties": false
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "both host and port must be set together",
                          "rule": "has(self.host) || has(self.port) ? has(self.host) && has(self.port) : true"
                        },
                        {
                          "message": "custom providers must specify exactly one of backendRef or host and port",
                          "rule": "has(self.custom) ? has(self.custom.backendRef) != has(self.host) : true"
                        },
                        {
                          "message": "path and pathPrefix are mutually exclusive",
                          "rule": "!(has(self.path) && has(self.pathPrefix))"
                        },
                        {
                          "message": "path, pathPrefix, and custom format paths are mutually exclusive",
                          "rule": "!(has(self.custom) && self.custom.formats.exists(f, has(f.path)) && (has(self.path) || has(self.pathPrefix)))"
                        },
                        {
                          "message": "pathPrefix requires host to be set",
                          "rule": "has(self.pathPrefix) ? has(self.host) : true"
                        },
                        {
                          "message": "exactly one of the fields in [openai azureopenai azure anthropic gemini vertexai bedrock custom] must be set",
                          "rule": "(has(self.openai)?1:0)+(has(self.azureopenai)?1:0)+(has(self.azure)?1:0)+(has(self.anthropic)?1:0)+(has(self.gemini)?1:0)+(has(self.vertexai)?1:0)+(has(self.bedrock)?1:0)+(has(self.custom)?1:0) == 1"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "maxItems": 16,
                    "minItems": 1,
                    "type": "array",
                    "x-kubernetes-validations": [
                      {
                        "message": "provider names must be unique within a group",
                        "rule": "self.all(p1, self.exists_one(p2, p1.name == p2.name))"
                      }
                    ]
                  }
                },
                "required": [
                  "providers"
                ],
                "type": "object",
                "additionalProperties": false
              },
              "maxItems": 8,
              "minItems": 1,
              "type": "array"
            },
            "provider": {
              "description": "Configuration for how to reach the configured LLM\nprovider.",
              "properties": {
                "anthropic": {
                  "description": "Anthropic provider settings.",
                  "properties": {
                    "model": {
                      "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "azure": {
                  "description": "Azure provider with resource-based configuration.\nSupports both Azure OpenAI and Azure AI Foundry resource types.",
                  "properties": {
                    "apiVersion": {
                      "description": "The version of the Azure OpenAI API to use.\nIf unset, defaults to `v1`.",
                      "maxLength": 64,
                      "minLength": 1,
                      "type": "string"
                    },
                    "model": {
                      "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "projectName": {
                      "description": "The Foundry project name, required when `resourceType` is `Foundry`.\nUsed to construct paths: /api/projects/{projectName}/openai/v1/...",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "resourceName": {
                      "description": "The Azure resource name used to construct the endpoint host.\nFor OpenAI: {resourceName}.openai.azure.com\nFor Foundry: {resourceName}.services.ai.azure.com\nNote: when the Azure portal \"Foundry legacy\" template was used, the\ngenerated resource name may end in \"-resource\" (e.g. \"myproject-resource\");\nthat suffix is part of the resource name as the user configured it, not\npart of the hostname suffix agentgateway should append.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "resourceType": {
                      "description": "The type of Azure endpoint. Determines the host suffix.",
                      "enum": [
                        "Foundry",
                        "OpenAI"
                      ],
                      "type": "string"
                    }
                  },
                  "required": [
                    "resourceName",
                    "resourceType"
                  ],
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "projectName is required when resourceType is Foundry",
                      "rule": "self.resourceType != 'Foundry' || has(self.projectName)"
                    }
                  ],
                  "additionalProperties": false
                },
                "azureopenai": {
                  "description": "Azure OpenAI provider settings.",
                  "properties": {
                    "apiVersion": {
                      "description": "The version of the Azure OpenAI API to use.\nFor more information, see the [Azure OpenAI API version reference](https://learn.microsoft.com/en-us/azure/foundry/openai/reference).\nIf unset, defaults to `v1`.",
                      "maxLength": 64,
                      "minLength": 1,
                      "type": "string"
                    },
                    "deploymentName": {
                      "description": "The name of the Azure OpenAI model deployment to use.\nFor more information, see the [Azure OpenAI model docs](https://learn.microsoft.com/en-us/azure/foundry/foundry-models/concepts/models-sold-directly-by-azure?view=foundry-classic).\nThis is required if `apiVersion` is not `v1`. For `v1`, the model can be\nset in the request.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "endpoint": {
                      "description": "The endpoint for the Azure OpenAI API to use, such as `my-endpoint.openai.azure.com`.\nIf the scheme is included, it is stripped.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    }
                  },
                  "required": [
                    "endpoint"
                  ],
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "deploymentName is required for this apiVersion",
                      "rule": "!has(self.apiVersion) || self.apiVersion == 'v1' ? true : has(self.deploymentName)"
                    }
                  ],
                  "additionalProperties": false
                },
                "bedrock": {
                  "description": "Bedrock provider settings.",
                  "properties": {
                    "endpointPreference": {
                      "description": "EndpointPreference selects which Bedrock API surface to prefer.\nDefaults to `RuntimePreferred`, preferring runtime over mantle.\nDecides which endpoint to pick mainly based on the catalog tags\n`mantle` and `runtime`.",
                      "enum": [
                        "MantleOnly",
                        "MantlePreferred",
                        "RuntimeOnly",
                        "RuntimePreferred"
                      ],
                      "type": "string"
                    },
                    "guardrail": {
                      "description": "Guardrail policy to use for the backend. See\n<https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html>.\nIf not specified, the AWS Guardrail policy will not be used.",
                      "properties": {
                        "identifier": {
                          "description": "Identifier of the Guardrail policy to use for the backend.",
                          "maxLength": 256,
                          "minLength": 1,
                          "type": "string"
                        },
                        "version": {
                          "description": "Version of the Guardrail policy to use for the backend.",
                          "maxLength": 256,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "identifier",
                        "version"
                      ],
                      "type": "object",
                      "additionalProperties": false
                    },
                    "model": {
                      "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "region": {
                      "description": "AWS region to use for the backend.\nDefaults to `us-east-1` if not specified.",
                      "maxLength": 63,
                      "minLength": 1,
                      "pattern": "^[a-z0-9-]+$",
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "Bedrock guardrails cannot be used with MantlePreferred or MantleOnly",
                      "rule": "!has(self.guardrail) || !has(self.endpointPreference) || !(self.endpointPreference in ['MantlePreferred', 'MantleOnly'])"
                    }
                  ],
                  "additionalProperties": false
                },
                "custom": {
                  "description": "Custom provider configures a non-managed or self-hosted LLM provider.\nUse this when the provider target and API formats should be declared\nexplicitly instead of inferred from a managed provider such as OpenAI or\nAnthropic.",
                  "properties": {
                    "backendRef": {
                      "description": "Kubernetes backend that serves this provider.\n`backendRef` may target only a namespace-local Service or InferencePool.\nIf unset, host and port must be set on the parent provider.",
                      "properties": {
                        "group": {
                          "description": "API group of the referenced resource. For example, `gateway.networking.k8s.io`.\nDefaults to the empty string, which identifies the core API group.",
                          "maxLength": 253,
                          "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                          "type": "string"
                        },
                        "kind": {
                          "description": "Kind of the referenced resource. For example, `Service`.\nDefaults to \"Service\" when not specified.",
                          "maxLength": 63,
                          "minLength": 1,
                          "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                          "type": "string"
                        },
                        "name": {
                          "description": "Name of the referenced resource.",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        },
                        "port": {
                          "description": "Destination port number to use for this resource.\nRequired when the referenced resource is a Kubernetes Service.",
                          "format": "int32",
                          "maximum": 65535,
                          "minimum": 1,
                          "type": "integer"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "Must have port for Service reference",
                          "rule": "((!has(self.group) || size(self.group) == 0) && (!has(self.kind) || self.kind == 'Service')) ? has(self.port) : true"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "formats": {
                      "description": "Provider-native API formats this provider supports.",
                      "items": {
                        "description": "Provider-native LLM API format settings.",
                        "properties": {
                          "path": {
                            "description": "Default upstream path override for this format.\nIf unset, agentgateway uses the default path for the format.",
                            "maxLength": 1024,
                            "minLength": 1,
                            "type": "string"
                          },
                          "type": {
                            "description": "Provider-native API format.",
                            "enum": [
                              "AnthropicTokenCount",
                              "Completions",
                              "Embeddings",
                              "Messages",
                              "Realtime",
                              "Rerank",
                              "Responses"
                            ],
                            "type": "string"
                          }
                        },
                        "required": [
                          "type"
                        ],
                        "type": "object",
                        "x-kubernetes-validations": [
                          {
                            "message": "path must start with /",
                            "rule": "!has(self.path) || self.path.startsWith('/')"
                          }
                        ],
                        "additionalProperties": false
                      },
                      "maxItems": 6,
                      "minItems": 1,
                      "type": "array",
                      "x-kubernetes-list-map-keys": [
                        "type"
                      ],
                      "x-kubernetes-list-type": "map"
                    },
                    "model": {
                      "description": "Model name override, such as `gpt-oss`.\nIf unset, the model name is taken from the request.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "providerOverride": {
                      "description": "Provider identity used for cost-catalog lookup and telemetry.\nDefaults to \"custom\" when unset.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    }
                  },
                  "required": [
                    "formats"
                  ],
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "custom provider backendRef may target only Service or InferencePool",
                      "rule": "!has(self.backendRef) || (((!has(self.backendRef.group) || self.backendRef.group == \"\") && (!has(self.backendRef.kind) || self.backendRef.kind == 'Service')) || (has(self.backendRef.group) && self.backendRef.group == 'inference.networking.k8s.io' && has(self.backendRef.kind) && self.backendRef.kind == 'InferencePool'))"
                    }
                  ],
                  "additionalProperties": false
                },
                "gemini": {
                  "description": "Gemini provider settings.",
                  "properties": {
                    "model": {
                      "description": "Model name override, such as `gemini-2.5-pro`.\nIf unset, the model name is taken from the request.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "host": {
                  "description": "Hostname to send requests to.\nFor custom providers without backendRef, host and port specify the target.\nFor managed providers, host and port override the provider default.",
                  "maxLength": 256,
                  "minLength": 1,
                  "type": "string"
                },
                "openai": {
                  "description": "OpenAI provider settings.",
                  "properties": {
                    "model": {
                      "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "moderation": {
                      "description": "Inline moderation configuration to inject into OpenAI chat completions\nand responses requests.\nIf unset, the OpenAI inline moderation parameter is not injected.",
                      "properties": {
                        "model": {
                          "description": "The moderation model to use, such as `omni-moderation-latest`.\nDefaults to `omni-moderation-latest` if not specified.",
                          "maxLength": 256,
                          "minLength": 1,
                          "type": "string"
                        },
                        "policy": {
                          "description": "Policies to apply to request input and generated output.",
                          "properties": {
                            "input": {
                              "description": "Policy for request input moderation.",
                              "properties": {
                                "mode": {
                                  "description": "Mode controls whether moderation only returns scores or blocks flagged content.",
                                  "enum": [
                                    "Block",
                                    "Score"
                                  ],
                                  "type": "string"
                                }
                              },
                              "required": [
                                "mode"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "output": {
                              "description": "Policy for generated output moderation.",
                              "properties": {
                                "mode": {
                                  "description": "Mode controls whether moderation only returns scores or blocks flagged content.",
                                  "enum": [
                                    "Block",
                                    "Score"
                                  ],
                                  "type": "string"
                                }
                              },
                              "required": [
                                "mode"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            }
                          },
                          "type": "object",
                          "additionalProperties": false
                        }
                      },
                      "type": "object",
                      "additionalProperties": false
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "path": {
                  "description": "URL path to use for LLM provider API requests.\nThis is useful when you need to route requests to a different API endpoint while maintaining\ncompatibility with the original provider's API structure.\nIf not specified, the default path for the provider is used.",
                  "maxLength": 1024,
                  "minLength": 1,
                  "type": "string"
                },
                "pathPrefix": {
                  "description": "Overrides the default base path prefix, such as `/v1`, for upstream requests.\nPath translation for cross-format requests still applies using this prefix.\nOnly supported for OpenAI and Anthropic providers.",
                  "maxLength": 1024,
                  "minLength": 1,
                  "type": "string"
                },
                "port": {
                  "description": "Port to send requests to.",
                  "format": "int32",
                  "maximum": 65535,
                  "minimum": 1,
                  "type": "integer"
                },
                "vertexai": {
                  "description": "Vertex AI provider settings.",
                  "properties": {
                    "model": {
                      "description": "Model name override, such as `gpt-4o-mini`.\nIf unset, the model name is taken from the request.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "projectId": {
                      "description": "The ID of the Google Cloud Project that you use for the Vertex AI.",
                      "maxLength": 64,
                      "minLength": 1,
                      "type": "string"
                    },
                    "region": {
                      "description": "The location of the Google Cloud Project that you use for the Vertex AI.\nSpecial values: `global` uses the global endpoint, while `us` and `eu` use restricted\nmulti-region endpoints. Other values are treated as regional locations.\nDefaults to `global` if not specified.",
                      "maxLength": 64,
                      "minLength": 1,
                      "type": "string"
                    }
                  },
                  "required": [
                    "projectId"
                  ],
                  "type": "object",
                  "additionalProperties": false
                }
              },
              "type": "object",
              "x-kubernetes-validations": [
                {
                  "message": "both host and port must be set together",
                  "rule": "has(self.host) || has(self.port) ? has(self.host) && has(self.port) : true"
                },
                {
                  "message": "custom providers must specify exactly one of backendRef or host and port",
                  "rule": "has(self.custom) ? has(self.custom.backendRef) != has(self.host) : true"
                },
                {
                  "message": "path and pathPrefix are mutually exclusive",
                  "rule": "!(has(self.path) && has(self.pathPrefix))"
                },
                {
                  "message": "path, pathPrefix, and custom format paths are mutually exclusive",
                  "rule": "!(has(self.custom) && self.custom.formats.exists(f, has(f.path)) && (has(self.path) || has(self.pathPrefix)))"
                },
                {
                  "message": "pathPrefix requires host to be set",
                  "rule": "has(self.pathPrefix) ? has(self.host) : true"
                },
                {
                  "message": "exactly one of the fields in [openai azureopenai azure anthropic gemini vertexai bedrock custom] must be set",
                  "rule": "(has(self.openai)?1:0)+(has(self.azureopenai)?1:0)+(has(self.azure)?1:0)+(has(self.anthropic)?1:0)+(has(self.gemini)?1:0)+(has(self.vertexai)?1:0)+(has(self.bedrock)?1:0)+(has(self.custom)?1:0) == 1"
                }
              ],
              "additionalProperties": false
            }
          },
          "type": "object",
          "x-kubernetes-validations": [
            {
              "message": "exactly one of the fields in [provider groups] must be set",
              "rule": "(has(self.provider)?1:0)+(has(self.groups)?1:0) == 1"
            }
          ],
          "additionalProperties": false
        },
        "aws": {
          "description": "AWS service backend, such as AgentCore.",
          "properties": {
            "agentCore": {
              "description": "Amazon Bedrock AgentCore backend settings.",
              "properties": {
                "agentRuntimeArn": {
                  "description": "ARN of the AgentCore runtime.",
                  "type": "string"
                },
                "qualifier": {
                  "description": "Alias or version qualifier.",
                  "type": "string"
                }
              },
              "required": [
                "agentRuntimeArn"
              ],
              "type": "object",
              "additionalProperties": false
            }
          },
          "type": "object",
          "x-kubernetes-validations": [
            {
              "message": "exactly one of the fields in [agentCore] must be set",
              "rule": "(has(self.agentCore)?1:0) == 1"
            }
          ],
          "additionalProperties": false
        },
        "dynamicForwardProxy": {
          "description": "Dynamically sends requests to the destination based on the incoming\nrequest HTTP host header, or TLS SNI for TLS traffic.\n\nWarning: this backend type can send requests to arbitrary destinations. Proper\naccess controls must be put in place when using this backend type.",
          "type": "object"
        },
        "mcp": {
          "description": "MCP backend.",
          "properties": {
            "failureMode": {
              "description": "Behavior when MCP targets fail to initialize or\nbecome unavailable at runtime. `FailOpen` skips failed targets and\ncontinues serving from healthy ones. `FailClosed` (default) fails the\nentire session if any target fails.",
              "enum": [
                "FailClosed",
                "FailOpen"
              ],
              "type": "string"
            },
            "prefixMode": {
              "description": "How tool and prompt names are prefixed with the target name. Resource URIs\nalways retain target routing information when multiplexing and are unaffected.\n`Conditional` (default) prefixes only when there are multiple targets.\n`Always` prefixes even with a single target. `Never` exposes unprefixed\nnames and routes calls by looking up which target serves the name;\nnames must be unique across targets.",
              "enum": [
                "Always",
                "Conditional",
                "Never"
              ],
              "type": "string"
            },
            "sessionRouting": {
              "description": "MCP session routing behavior.\nDefaults to `Stateful` if not set.",
              "enum": [
                "Stateful",
                "Stateless"
              ],
              "type": "string"
            },
            "targets": {
              "description": "MCP targets to use for this backend. Policies\ntargeting MCP targets must use `targetRefs[].sectionName` to select\nthe target by name.",
              "items": {
                "description": "MCP target selection for this backend.",
                "properties": {
                  "name": {
                    "description": "Name of the MCP target.",
                    "maxLength": 253,
                    "minLength": 1,
                    "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                    "type": "string"
                  },
                  "selector": {
                    "description": "Label selector used to select `Service` resources.\nIf policies are needed on a per-service basis, `AgentgatewayPolicy` can\ntarget the desired `Service`.",
                    "properties": {
                      "namespaces": {
                        "description": "`namespace` is the label selector for namespaces that `Service`\nresources should be selected from. If unset, only the namespace of the\n`AgentgatewayBackend` is searched.",
                        "properties": {
                          "matchExpressions": {
                            "description": "matchExpressions is a list of label selector requirements. The requirements are ANDed.",
                            "items": {
                              "description": "A label selector requirement is a selector that contains values, a key, and an operator that\nrelates the key and values.",
                              "properties": {
                                "key": {
                                  "description": "key is the label key that the selector applies to.",
                                  "type": "string"
                                },
                                "operator": {
                                  "description": "operator represents a key's relationship to a set of values.\nValid operators are In, NotIn, Exists and DoesNotExist.",
                                  "type": "string"
                                },
                                "values": {
                                  "description": "values is an array of string values. If the operator is In or NotIn,\nthe values array must be non-empty. If the operator is Exists or DoesNotExist,\nthe values array must be empty. This array is replaced during a strategic\nmerge patch.",
                                  "items": {
                                    "type": "string"
                                  },
                                  "type": "array",
                                  "x-kubernetes-list-type": "atomic"
                                }
                              },
                              "required": [
                                "key",
                                "operator"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "type": "array",
                            "x-kubernetes-list-type": "atomic"
                          },
                          "matchLabels": {
                            "additionalProperties": {
                              "type": "string"
                            },
                            "description": "matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels\nmap is equivalent to an element of matchExpressions, whose key field is \"key\", the\noperator is \"In\", and the values array contains only \"value\". The requirements are ANDed.",
                            "type": "object"
                          }
                        },
                        "type": "object",
                        "x-kubernetes-map-type": "atomic",
                        "additionalProperties": false
                      },
                      "services": {
                        "description": "`services` is the label selector for which `Service` resources should be\nselected.",
                        "properties": {
                          "matchExpressions": {
                            "description": "matchExpressions is a list of label selector requirements. The requirements are ANDed.",
                            "items": {
                              "description": "A label selector requirement is a selector that contains values, a key, and an operator that\nrelates the key and values.",
                              "properties": {
                                "key": {
                                  "description": "key is the label key that the selector applies to.",
                                  "type": "string"
                                },
                                "operator": {
                                  "description": "operator represents a key's relationship to a set of values.\nValid operators are In, NotIn, Exists and DoesNotExist.",
                                  "type": "string"
                                },
                                "values": {
                                  "description": "values is an array of string values. If the operator is In or NotIn,\nthe values array must be non-empty. If the operator is Exists or DoesNotExist,\nthe values array must be empty. This array is replaced during a strategic\nmerge patch.",
                                  "items": {
                                    "type": "string"
                                  },
                                  "type": "array",
                                  "x-kubernetes-list-type": "atomic"
                                }
                              },
                              "required": [
                                "key",
                                "operator"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "type": "array",
                            "x-kubernetes-list-type": "atomic"
                          },
                          "matchLabels": {
                            "additionalProperties": {
                              "type": "string"
                            },
                            "description": "matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels\nmap is equivalent to an element of matchExpressions, whose key field is \"key\", the\noperator is \"In\", and the values array contains only \"value\". The requirements are ANDed.",
                            "type": "object"
                          }
                        },
                        "type": "object",
                        "x-kubernetes-map-type": "atomic",
                        "additionalProperties": false
                      }
                    },
                    "type": "object",
                    "x-kubernetes-validations": [
                      {
                        "message": "at least one of the fields in [namespaces services] must be set",
                        "rule": "[has(self.namespaces),has(self.services)].filter(x,x==true).size() >= 1"
                      }
                    ],
                    "additionalProperties": false
                  },
                  "static": {
                    "description": "Static MCP destination. When connecting to\nin-cluster `Service` resources, it is recommended to use `selector`\ninstead.",
                    "properties": {
                      "backendRef": {
                        "description": "Namespace-local `Service` resource by name.\nWhen set, this replaces `host` only; `port`, `path`, and `protocol`\nremain configured on this target.",
                        "properties": {
                          "name": {
                            "default": "",
                            "description": "Name of the referent",
                            "type": "string"
                          }
                        },
                        "type": "object",
                        "x-kubernetes-map-type": "atomic",
                        "additionalProperties": false
                      },
                      "host": {
                        "description": "Hostname or IP address of the MCP target.",
                        "maxLength": 256,
                        "minLength": 1,
                        "type": "string"
                      },
                      "path": {
                        "description": "URL path of the MCP target endpoint.\nDefaults to `\"/sse\"` for the `SSE` protocol or `\"/mcp\"` for the\n`StreamableHTTP` protocol if not specified.",
                        "maxLength": 1024,
                        "minLength": 1,
                        "type": "string"
                      },
                      "policies": {
                        "description": "Policies for communicating with this backend.\nPolicies may also be set in `AgentgatewayPolicy`, or in the top-level\n`AgentgatewayBackend`. Policies are merged on a field-level basis, with\norder: `AgentgatewayPolicy` < `AgentgatewayBackend` < `AgentgatewayBackend` MCP (this field).\nThis field may only be used with host-based static targets, not\n`backendRef`.",
                        "properties": {
                          "auth": {
                            "description": "Settings for managing authentication to the backend",
                            "properties": {
                              "aws": {
                                "description": "Explicit AWS authentication method for the backend.\nWhen omitted, default AWS SDK credential discovery is used.",
                                "properties": {
                                  "assumeRole": {
                                    "description": "AWS STS AssumeRole settings to use before signing backend requests.\nAmbient AWS credentials are used as the source credentials for STS.",
                                    "properties": {
                                      "externalId": {
                                        "description": "ExternalID is set when the role's trust policy requires sts:ExternalId.",
                                        "maxLength": 1224,
                                        "minLength": 2,
                                        "pattern": "^[\\w+=,.@:/-]+$",
                                        "type": "string"
                                      },
                                      "roleArn": {
                                        "description": "AWS IAM role ARN to assume.",
                                        "minLength": 1,
                                        "pattern": "^arn:aws[a-z-]*:iam::[0-9]{12}:role/.+$",
                                        "type": "string"
                                      },
                                      "sessionName": {
                                        "description": "SessionName is a custom session name (RoleSessionName) for CloudTrail and\nCost & Usage Report attribution. If unset, AWS generates a random name.",
                                        "pattern": "^[\\w+=,.@-]{2,64}$",
                                        "type": "string"
                                      },
                                      "sessionNameExpression": {
                                        "description": "SessionNameExpression is a CEL expression evaluated against each request\nto produce the session name (RoleSessionName), for example `jwt.sub` or\n`request.headers[\"x-team\"]`. If the expression does not produce a valid\nsession name at request time, the request is rejected.",
                                        "maxLength": 16384,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "tags": {
                                        "description": "Session tags passed to STS AssumeRole for cost attribution in the AWS Cost\n& Usage Report, once activated. STS allows at most 50 per role session.",
                                        "items": {
                                          "description": "AwsSessionTag is an AWS STS session tag passed to AssumeRole for cost\nattribution. Exactly one of value and expression must be set.",
                                          "properties": {
                                            "expression": {
                                              "description": "CEL expression evaluated against each request to produce the tag value,\nfor example `jwt.sub` or `request.headers[\"x-app\"]`. Requests with invalid\ntag values are rejected.",
                                              "maxLength": 16384,
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "key": {
                                              "description": "Key is the tag key.",
                                              "maxLength": 128,
                                              "minLength": 1,
                                              "type": "string"
                                            },
                                            "value": {
                                              "description": "Value is a static tag value.",
                                              "maxLength": 256,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "key"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "exactly one of value or expression must be set",
                                              "rule": "has(self.value) != has(self.expression)"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "maxItems": 50,
                                        "type": "array",
                                        "x-kubernetes-list-map-keys": [
                                          "key"
                                        ],
                                        "x-kubernetes-list-type": "map"
                                      }
                                    },
                                    "required": [
                                      "roleArn"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "at most one of the fields in [sessionName sessionNameExpression] may be set",
                                        "rule": "(has(self.sessionName)?1:0)+(has(self.sessionNameExpression)?1:0) <= 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "region": {
                                    "description": "AWS SigV4 signing region, for example `us-east-1`. Set this when the\ntarget AWS service is in a different region than the gateway. If unset,\ntyped AWS backends may provide this automatically; otherwise the ambient\nAWS region is used.",
                                    "maxLength": 256,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "secretRef": {
                                    "description": "Credential source for AWS credentials, defaulting to a Kubernetes `Secret`.\nThe default Secret resolver expects `accessKey`, `secretKey`, and optional\n`sessionToken` keys.",
                                    "properties": {
                                      "group": {
                                        "description": "API group of the referenced credential; empty selects the core API group",
                                        "type": "string"
                                      },
                                      "kind": {
                                        "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                        "type": "string"
                                      },
                                      "name": {
                                        "description": "Name of the referenced credential",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-map-type": "atomic",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "custom credential refs must set both group and kind",
                                        "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "serviceName": {
                                    "description": "AWS SigV4 signing service name, for example\n`bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS\nbackends may provide this automatically.",
                                    "maxLength": 256,
                                    "minLength": 1,
                                    "type": "string"
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "secretRef and assumeRole are mutually exclusive",
                                    "rule": "!(has(self.secretRef) && has(self.assumeRole))"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "azure": {
                                "description": "Azure authentication method for the backend.",
                                "properties": {
                                  "managedIdentity": {
                                    "description": "Managed identity authentication settings. Leave this object empty to use\nthe system-assigned identity. To use a user-assigned identity, set one of\n`clientId`, `objectId`, or `resourceId`.",
                                    "properties": {
                                      "clientId": {
                                        "description": "Client ID of the user-assigned managed identity.",
                                        "type": "string"
                                      },
                                      "objectId": {
                                        "description": "Object ID of the user-assigned managed identity.",
                                        "type": "string"
                                      },
                                      "resourceId": {
                                        "description": "Resource ID of the user-assigned managed identity.",
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "at most one of the fields in [clientId objectId resourceId] may be set",
                                        "rule": "(has(self.clientId)?1:0)+(has(self.objectId)?1:0)+(has(self.resourceId)?1:0) <= 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "scopes": {
                                    "description": "Scopes requested for the Azure access token. When omitted, the scope is\ninferred from the backend hostname. Managed Identity supports exactly one\nscope.",
                                    "items": {
                                      "type": "string"
                                    },
                                    "maxItems": 64,
                                    "minItems": 1,
                                    "type": "array"
                                  },
                                  "secretRef": {
                                    "description": "Credential source for Azure credentials, defaulting to a Kubernetes\n`Secret`. The default Secret resolver expects `clientID`, `tenantID`, and\n`clientSecret` keys.",
                                    "properties": {
                                      "group": {
                                        "description": "API group of the referenced credential; empty selects the core API group",
                                        "type": "string"
                                      },
                                      "kind": {
                                        "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                        "type": "string"
                                      },
                                      "name": {
                                        "description": "Name of the referenced credential",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-map-type": "atomic",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "custom credential refs must set both group and kind",
                                        "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "workloadIdentity": {
                                    "description": "Workload identity authentication settings. Uses the federated token and\nAzure env vars projected into the data plane pod. Recommended on AKS with\nWorkload Identity enabled.",
                                    "type": "object"
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "managedIdentity supports exactly one scope",
                                    "rule": "!has(self.managedIdentity) || !has(self.scopes) || self.scopes.size() == 1"
                                  },
                                  {
                                    "message": "at most one of the fields in [secretRef managedIdentity workloadIdentity] may be set",
                                    "rule": "(has(self.secretRef)?1:0)+(has(self.managedIdentity)?1:0)+(has(self.workloadIdentity)?1:0) <= 1"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "credentials": {
                                "description": "Credentials is a list of additional credentials to inject on the\nbackend request. Each entry resolves a Secret key and writes its value\nto the entry's location. `credentials` is independent of the primary\n`key`/`secretRef`/`passthrough` mechanism and may be set on its own or\nalongside it.",
                                "items": {
                                  "description": "BackendAuthCredential specifies one additional credential to inject on the\nbackend request.",
                                  "properties": {
                                    "location": {
                                      "description": "Where the credential is inserted on the backend request.",
                                      "properties": {
                                        "cookie": {
                                          "properties": {
                                            "name": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        },
                                        "header": {
                                          "properties": {
                                            "name": {
                                              "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                              "type": "string"
                                            },
                                            "prefix": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        },
                                        "queryParameter": {
                                          "properties": {
                                            "name": {
                                              "maxLength": 256,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "additionalProperties": false
                                        }
                                      },
                                      "type": "object",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                          "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                        }
                                      ],
                                      "additionalProperties": false
                                    },
                                    "secretRef": {
                                      "description": "SecretRef references a Kubernetes Secret holding the credential value, and\noptionally overrides the key read from it. Defaults to `Authorization`,\nmatching the key convention used by the top-level `secretRef`.",
                                      "properties": {
                                        "group": {
                                          "description": "API group of the referenced credential; empty selects the core API group",
                                          "type": "string"
                                        },
                                        "key": {
                                          "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                          "maxLength": 253,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "kind": {
                                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                          "type": "string"
                                        },
                                        "name": {
                                          "description": "Name of the referenced credential",
                                          "maxLength": 253,
                                          "minLength": 1,
                                          "type": "string"
                                        }
                                      },
                                      "required": [
                                        "name"
                                      ],
                                      "type": "object",
                                      "x-kubernetes-map-type": "atomic",
                                      "x-kubernetes-validations": [
                                        {
                                          "message": "custom credential refs must set both group and kind",
                                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                        }
                                      ],
                                      "additionalProperties": false
                                    }
                                  },
                                  "required": [
                                    "location",
                                    "secretRef"
                                  ],
                                  "type": "object",
                                  "additionalProperties": false
                                },
                                "maxItems": 8,
                                "minItems": 1,
                                "type": "array",
                                "x-kubernetes-list-type": "atomic"
                              },
                              "crossAppAccess": {
                                "description": "Cross App Access (Identity Assertion / ID-JAG) authentication.",
                                "properties": {
                                  "accessTokenScopes": {
                                    "description": "Scopes requested when exchanging the ID-JAG for an access token.\nWhen omitted, defaults to Scopes. Set to an empty list to omit scope.",
                                    "items": {
                                      "type": "string"
                                    },
                                    "maxItems": 64,
                                    "type": "array"
                                  },
                                  "audience": {
                                    "description": "Identifier of the resource authorization server. The issued ID-JAG is bound to this audience.",
                                    "maxLength": 256,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "cache": {
                                    "description": "Response cache configuration.",
                                    "properties": {
                                      "inMemory": {
                                        "properties": {
                                          "defaultTtl": {
                                            "description": "TTL used when the token endpoint omits expires_in. Default 300s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "defaultTtl must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          },
                                          "maxEntries": {
                                            "description": "Default 8192; 0 disables the cache.",
                                            "format": "int32",
                                            "type": "integer"
                                          }
                                        },
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "identityProvider": {
                                    "description": "User identity provider authorization server, used for the RFC 8693 ID-JAG exchange.",
                                    "properties": {
                                      "backendRef": {
                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                        "properties": {
                                          "group": {
                                            "default": "",
                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                            "maxLength": 253,
                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                            "type": "string"
                                          },
                                          "kind": {
                                            "default": "Service",
                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name is the name of the referent.",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "namespace": {
                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "port": {
                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                            "format": "int32",
                                            "maximum": 65535,
                                            "minimum": 1,
                                            "type": "integer"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "Must have port for Service reference",
                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "clientAuth": {
                                        "description": "Client authentication for the token endpoint.",
                                        "properties": {
                                          "clientId": {
                                            "description": "Client ID sent to the token endpoint.",
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "method": {
                                            "description": "Client authentication method. Defaults to ClientSecretBasic.",
                                            "enum": [
                                              "ClientSecretBasic",
                                              "ClientSecretPost",
                                              "PrivateKeyJwt"
                                            ],
                                            "type": "string"
                                          },
                                          "privateKeyJwt": {
                                            "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                                            "properties": {
                                              "alg": {
                                                "description": "JWS signing algorithm. Defaults to RS256.",
                                                "enum": [
                                                  "ES256",
                                                  "ES384",
                                                  "PS256",
                                                  "RS256",
                                                  "RS384",
                                                  "RS512"
                                                ],
                                                "type": "string"
                                              },
                                              "assertionAudience": {
                                                "description": "Audience for the client assertion, typically the token endpoint URL.",
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "certificateHeader": {
                                                "description": "JWS certificate header. Required when certificateRef is set.",
                                                "enum": [
                                                  "x5c",
                                                  "x5t#S256"
                                                ],
                                                "type": "string"
                                              },
                                              "certificateRef": {
                                                "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                                                "properties": {
                                                  "group": {
                                                    "description": "API group of the referenced credential; empty selects the core API group",
                                                    "type": "string"
                                                  },
                                                  "key": {
                                                    "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  },
                                                  "kind": {
                                                    "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                    "type": "string"
                                                  },
                                                  "name": {
                                                    "description": "Name of the referenced credential",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  }
                                                },
                                                "required": [
                                                  "name"
                                                ],
                                                "type": "object",
                                                "x-kubernetes-map-type": "atomic",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "custom credential refs must set both group and kind",
                                                    "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              },
                                              "kid": {
                                                "description": "Optional JWS key ID header.",
                                                "type": "string"
                                              },
                                              "signingKeyRef": {
                                                "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                                                "properties": {
                                                  "group": {
                                                    "description": "API group of the referenced credential; empty selects the core API group",
                                                    "type": "string"
                                                  },
                                                  "key": {
                                                    "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  },
                                                  "kind": {
                                                    "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                    "type": "string"
                                                  },
                                                  "name": {
                                                    "description": "Name of the referenced credential",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  }
                                                },
                                                "required": [
                                                  "name"
                                                ],
                                                "type": "object",
                                                "x-kubernetes-map-type": "atomic",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "custom credential refs must set both group and kind",
                                                    "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              }
                                            },
                                            "required": [
                                              "assertionAudience",
                                              "signingKeyRef"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "certificateRef and certificateHeader must be set together",
                                                "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "secretRef": {
                                            "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                                            "properties": {
                                              "group": {
                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                "type": "string"
                                              },
                                              "key": {
                                                "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "kind": {
                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                "type": "string"
                                              },
                                              "name": {
                                                "description": "Name of the referenced credential",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-map-type": "atomic",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "custom credential refs must set both group and kind",
                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          }
                                        },
                                        "required": [
                                          "clientId"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "privateKeyJwt settings require method PrivateKeyJwt",
                                            "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                                          },
                                          {
                                            "message": "secretRef is not valid with method PrivateKeyJwt",
                                            "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                                          },
                                          {
                                            "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                                            "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "path": {
                                        "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                                        "pattern": "^/",
                                        "type": "string"
                                      },
                                      "url": {
                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                        "maxLength": 1024,
                                        "minLength": 1,
                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "clientAuth"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "path may not be set when url is set",
                                        "rule": "has(self.url) ? !has(self.path) : true"
                                      },
                                      {
                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "resourceAuthorizationServer": {
                                    "description": "Resource authorization server, used for the RFC 7523 jwt-bearer exchange.",
                                    "properties": {
                                      "backendRef": {
                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                        "properties": {
                                          "group": {
                                            "default": "",
                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                            "maxLength": 253,
                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                            "type": "string"
                                          },
                                          "kind": {
                                            "default": "Service",
                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name is the name of the referent.",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "namespace": {
                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "port": {
                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                            "format": "int32",
                                            "maximum": 65535,
                                            "minimum": 1,
                                            "type": "integer"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "Must have port for Service reference",
                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "clientAuth": {
                                        "description": "Client authentication for the token endpoint.",
                                        "properties": {
                                          "clientId": {
                                            "description": "Client ID sent to the token endpoint.",
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "method": {
                                            "description": "Client authentication method. Defaults to ClientSecretBasic.",
                                            "enum": [
                                              "ClientSecretBasic",
                                              "ClientSecretPost",
                                              "PrivateKeyJwt"
                                            ],
                                            "type": "string"
                                          },
                                          "privateKeyJwt": {
                                            "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                                            "properties": {
                                              "alg": {
                                                "description": "JWS signing algorithm. Defaults to RS256.",
                                                "enum": [
                                                  "ES256",
                                                  "ES384",
                                                  "PS256",
                                                  "RS256",
                                                  "RS384",
                                                  "RS512"
                                                ],
                                                "type": "string"
                                              },
                                              "assertionAudience": {
                                                "description": "Audience for the client assertion, typically the token endpoint URL.",
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "certificateHeader": {
                                                "description": "JWS certificate header. Required when certificateRef is set.",
                                                "enum": [
                                                  "x5c",
                                                  "x5t#S256"
                                                ],
                                                "type": "string"
                                              },
                                              "certificateRef": {
                                                "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                                                "properties": {
                                                  "group": {
                                                    "description": "API group of the referenced credential; empty selects the core API group",
                                                    "type": "string"
                                                  },
                                                  "key": {
                                                    "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  },
                                                  "kind": {
                                                    "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                    "type": "string"
                                                  },
                                                  "name": {
                                                    "description": "Name of the referenced credential",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  }
                                                },
                                                "required": [
                                                  "name"
                                                ],
                                                "type": "object",
                                                "x-kubernetes-map-type": "atomic",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "custom credential refs must set both group and kind",
                                                    "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              },
                                              "kid": {
                                                "description": "Optional JWS key ID header.",
                                                "type": "string"
                                              },
                                              "signingKeyRef": {
                                                "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                                                "properties": {
                                                  "group": {
                                                    "description": "API group of the referenced credential; empty selects the core API group",
                                                    "type": "string"
                                                  },
                                                  "key": {
                                                    "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  },
                                                  "kind": {
                                                    "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                    "type": "string"
                                                  },
                                                  "name": {
                                                    "description": "Name of the referenced credential",
                                                    "maxLength": 253,
                                                    "minLength": 1,
                                                    "type": "string"
                                                  }
                                                },
                                                "required": [
                                                  "name"
                                                ],
                                                "type": "object",
                                                "x-kubernetes-map-type": "atomic",
                                                "x-kubernetes-validations": [
                                                  {
                                                    "message": "custom credential refs must set both group and kind",
                                                    "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                                  }
                                                ],
                                                "additionalProperties": false
                                              }
                                            },
                                            "required": [
                                              "assertionAudience",
                                              "signingKeyRef"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "certificateRef and certificateHeader must be set together",
                                                "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "secretRef": {
                                            "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                                            "properties": {
                                              "group": {
                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                "type": "string"
                                              },
                                              "key": {
                                                "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "kind": {
                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                "type": "string"
                                              },
                                              "name": {
                                                "description": "Name of the referenced credential",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-map-type": "atomic",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "custom credential refs must set both group and kind",
                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          }
                                        },
                                        "required": [
                                          "clientId"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "privateKeyJwt settings require method PrivateKeyJwt",
                                            "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                                          },
                                          {
                                            "message": "secretRef is not valid with method PrivateKeyJwt",
                                            "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                                          },
                                          {
                                            "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                                            "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "path": {
                                        "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                                        "pattern": "^/",
                                        "type": "string"
                                      },
                                      "url": {
                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                        "maxLength": 1024,
                                        "minLength": 1,
                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "clientAuth"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "path may not be set when url is set",
                                        "rule": "has(self.url) ? !has(self.path) : true"
                                      },
                                      {
                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "resources": {
                                    "description": "Resources sent to the token endpoint.",
                                    "items": {
                                      "type": "string"
                                    },
                                    "maxItems": 64,
                                    "minItems": 1,
                                    "type": "array"
                                  },
                                  "scopes": {
                                    "description": "Scopes requested when obtaining the ID-JAG from the identity provider.",
                                    "items": {
                                      "type": "string"
                                    },
                                    "maxItems": 64,
                                    "minItems": 1,
                                    "type": "array"
                                  },
                                  "subjectToken": {
                                    "description": "Subject token sent to the identity provider. Defaults to an OpenID Connect\nID token read from the Authorization Bearer header.",
                                    "properties": {
                                      "source": {
                                        "description": "Where to read the subject token. Defaults to the Authorization Bearer header.",
                                        "properties": {
                                          "cookie": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "expression": {
                                            "description": "CEL expression that extracts the credential from the request.",
                                            "maxLength": 16384,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "header": {
                                            "properties": {
                                              "name": {
                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                "type": "string"
                                              },
                                              "prefix": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "queryParameter": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "tokenType": {
                                        "description": "OAuth RFC 8693 subject token type. Defaults to IdToken",
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "tokenType IdJag is not supported by crossAppAccess",
                                        "rule": "!has(self.tokenType) || (self.tokenType != 'IdJag' && self.tokenType != 'urn:ietf:params:oauth:token-type:id-jag')"
                                      }
                                    ],
                                    "additionalProperties": false
                                  }
                                },
                                "required": [
                                  "audience",
                                  "identityProvider",
                                  "resourceAuthorizationServer"
                                ],
                                "type": "object",
                                "additionalProperties": false
                              },
                              "gcp": {
                                "description": "Google authentication method for the backend.\nWhen omitted, default Google credential discovery is used.",
                                "properties": {
                                  "audience": {
                                    "description": "Explicit `aud` value for the ID token. Only\nvalid with `IdToken` type. If not set, the `aud` is automatically\nderived from the backend hostname.",
                                    "maxLength": 256,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "secretRef": {
                                    "description": "Credential source for ADC-compatible Google credential JSON, defaulting to\na Kubernetes `Secret`. By default, the value is read from\n`credentials.json`; set `secretRef.key` to override it. When omitted,\nambient credentials are used.",
                                    "properties": {
                                      "group": {
                                        "description": "API group of the referenced credential; empty selects the core API group",
                                        "type": "string"
                                      },
                                      "key": {
                                        "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "kind": {
                                        "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                        "type": "string"
                                      },
                                      "name": {
                                        "description": "Name of the referenced credential",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-map-type": "atomic",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "custom credential refs must set both group and kind",
                                        "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "type": {
                                    "description": "The type of token to generate. To authenticate to GCP services,\ngenerally an `AccessToken` is used. To authenticate to Cloud Run, an\n`IdToken` is used.",
                                    "enum": [
                                      "AccessToken",
                                      "IdToken"
                                    ],
                                    "type": "string"
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "audience is only valid with IdToken",
                                    "rule": "has(self.audience) ? self.type == 'IdToken' : true"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "jwtSign": {
                                "description": "Signs a short-lived JWT with a private key on each request and sends it\nto the backend, for upstreams that require per-request keypair JWTs\n(e.g. the Snowflake SQL API) rather than a static credential.",
                                "properties": {
                                  "alg": {
                                    "description": "JWS signing algorithm. Defaults to RS256.",
                                    "enum": [
                                      "ES256",
                                      "ES384",
                                      "PS256",
                                      "RS256",
                                      "RS384",
                                      "RS512"
                                    ],
                                    "type": "string"
                                  },
                                  "claims": {
                                    "additionalProperties": {
                                      "x-kubernetes-preserve-unknown-fields": true
                                    },
                                    "description": "Static claims added to every token (e.g. iss, sub, aud). Values may be\nany JSON value (e.g. a string, number, bool, or array). iat, exp, and\nnbf are reserved for the signer and cannot be configured here; the\ncontroller rejects them at translation time.",
                                    "type": "object"
                                  },
                                  "kid": {
                                    "description": "Optional JWS key ID header.",
                                    "type": "string"
                                  },
                                  "location": {
                                    "description": "Where the signed token is written on the backend request.\nDefaults to the Authorization header with a \"Bearer \" prefix.",
                                    "properties": {
                                      "cookie": {
                                        "properties": {
                                          "name": {
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "header": {
                                        "properties": {
                                          "name": {
                                            "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                            "type": "string"
                                          },
                                          "prefix": {
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "queryParameter": {
                                        "properties": {
                                          "name": {
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                        "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "signingKeyRef": {
                                    "description": "Secret providing the `signingKey` key with a PEM-encoded RSA or EC private key.",
                                    "properties": {
                                      "group": {
                                        "description": "API group of the referenced credential; empty selects the core API group",
                                        "type": "string"
                                      },
                                      "kind": {
                                        "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                        "type": "string"
                                      },
                                      "name": {
                                        "description": "Name of the referenced credential",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-map-type": "atomic",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "custom credential refs must set both group and kind",
                                        "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "ttl": {
                                    "description": "Token lifetime used for exp. Defaults to 300s.",
                                    "maxLength": 32,
                                    "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                    "type": "string",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "ttl must be at least 1 second",
                                        "rule": "duration(self) >= duration('1s')"
                                      }
                                    ]
                                  }
                                },
                                "required": [
                                  "signingKeyRef"
                                ],
                                "type": "object",
                                "additionalProperties": false
                              },
                              "key": {
                                "description": "Inline key to use as the value of the\n`Authorization` header. This option is the least secure; usage of a\n`Secret` is preferred.",
                                "maxLength": 2048,
                                "type": "string"
                              },
                              "location": {
                                "description": "Where backend credentials are inserted.\nIf omitted, credentials are written to the `Authorization` header with the `Bearer ` prefix.\nThis applies to `key`, `secretRef`, and `passthrough`. Entries in `credentials` carry their own location.",
                                "properties": {
                                  "cookie": {
                                    "properties": {
                                      "name": {
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "header": {
                                    "properties": {
                                      "name": {
                                        "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                        "type": "string"
                                      },
                                      "prefix": {
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "queryParameter": {
                                    "properties": {
                                      "name": {
                                        "maxLength": 256,
                                        "minLength": 1,
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "additionalProperties": false
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                    "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "oauthTokenExchange": {
                                "description": "OAuth 2.0 token exchange (RFC 8693) / jwt-bearer (RFC 7523) authentication.",
                                "properties": {
                                  "actorToken": {
                                    "description": "RFC 8693 delegation actor token. TokenExchange grant only.",
                                    "properties": {
                                      "mayAct": {
                                        "description": "may_act claim validation mode. When omitted, may_act is not enforced.",
                                        "enum": [
                                          "Required"
                                        ],
                                        "type": "string"
                                      },
                                      "source": {
                                        "description": "Where to read the actor token. Actor tokens have no default source.",
                                        "properties": {
                                          "cookie": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "expression": {
                                            "description": "CEL expression that extracts the credential from the request.",
                                            "maxLength": 16384,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "header": {
                                            "properties": {
                                              "name": {
                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                "type": "string"
                                              },
                                              "prefix": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "queryParameter": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "tokenType": {
                                        "description": "OAuth token type. Empty defaults to AccessToken. Custom absolute URI values\nare supported for actor tokens.",
                                        "type": "string"
                                      }
                                    },
                                    "required": [
                                      "source"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "mayAct Required requires tokenType Jwt",
                                        "rule": "!has(self.mayAct) || self.mayAct != 'Required' || (has(self.tokenType) && self.tokenType == 'Jwt')"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "additionalParams": {
                                    "additionalProperties": {
                                      "description": "A Common Expression Language (CEL) expression.",
                                      "maxLength": 16384,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "description": "Extra form params; values are CEL expressions over the incoming request.",
                                    "maxProperties": 64,
                                    "type": "object"
                                  },
                                  "audiences": {
                                    "description": "Audiences sent to the token endpoint.",
                                    "items": {
                                      "maxLength": 256,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "maxItems": 64,
                                    "minItems": 1,
                                    "type": "array"
                                  },
                                  "backendRef": {
                                    "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                    "properties": {
                                      "group": {
                                        "default": "",
                                        "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                        "maxLength": 253,
                                        "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                        "type": "string"
                                      },
                                      "kind": {
                                        "default": "Service",
                                        "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                        "maxLength": 63,
                                        "minLength": 1,
                                        "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                        "type": "string"
                                      },
                                      "name": {
                                        "description": "Name is the name of the referent.",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "namespace": {
                                        "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                        "maxLength": 63,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                        "type": "string"
                                      },
                                      "port": {
                                        "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                        "format": "int32",
                                        "maximum": 65535,
                                        "minimum": 1,
                                        "type": "integer"
                                      }
                                    },
                                    "required": [
                                      "name"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "Must have port for Service reference",
                                        "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "cache": {
                                    "description": "Response cache configuration.",
                                    "properties": {
                                      "inMemory": {
                                        "properties": {
                                          "defaultTtl": {
                                            "description": "TTL used when the token endpoint omits expires_in. Default 300s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "defaultTtl must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          },
                                          "maxEntries": {
                                            "description": "Default 8192; 0 disables the cache.",
                                            "format": "int32",
                                            "type": "integer"
                                          }
                                        },
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "clientAuth": {
                                    "description": "Client authentication for the token endpoint. When unset, none is sent.",
                                    "properties": {
                                      "clientId": {
                                        "description": "Client ID sent to the token endpoint.",
                                        "minLength": 1,
                                        "type": "string"
                                      },
                                      "method": {
                                        "description": "Client authentication method. Defaults to ClientSecretBasic.",
                                        "enum": [
                                          "ClientSecretBasic",
                                          "ClientSecretPost",
                                          "PrivateKeyJwt"
                                        ],
                                        "type": "string"
                                      },
                                      "privateKeyJwt": {
                                        "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                                        "properties": {
                                          "alg": {
                                            "description": "JWS signing algorithm. Defaults to RS256.",
                                            "enum": [
                                              "ES256",
                                              "ES384",
                                              "PS256",
                                              "RS256",
                                              "RS384",
                                              "RS512"
                                            ],
                                            "type": "string"
                                          },
                                          "assertionAudience": {
                                            "description": "Audience for the client assertion, typically the token endpoint URL.",
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "certificateHeader": {
                                            "description": "JWS certificate header. Required when certificateRef is set.",
                                            "enum": [
                                              "x5c",
                                              "x5t#S256"
                                            ],
                                            "type": "string"
                                          },
                                          "certificateRef": {
                                            "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                                            "properties": {
                                              "group": {
                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                "type": "string"
                                              },
                                              "key": {
                                                "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "kind": {
                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                "type": "string"
                                              },
                                              "name": {
                                                "description": "Name of the referenced credential",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-map-type": "atomic",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "custom credential refs must set both group and kind",
                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "kid": {
                                            "description": "Optional JWS key ID header.",
                                            "type": "string"
                                          },
                                          "signingKeyRef": {
                                            "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                                            "properties": {
                                              "group": {
                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                "type": "string"
                                              },
                                              "key": {
                                                "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "kind": {
                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                "type": "string"
                                              },
                                              "name": {
                                                "description": "Name of the referenced credential",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-map-type": "atomic",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "custom credential refs must set both group and kind",
                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          }
                                        },
                                        "required": [
                                          "assertionAudience",
                                          "signingKeyRef"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "certificateRef and certificateHeader must be set together",
                                            "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "secretRef": {
                                        "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                                        "properties": {
                                          "group": {
                                            "description": "API group of the referenced credential; empty selects the core API group",
                                            "type": "string"
                                          },
                                          "key": {
                                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "kind": {
                                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name of the referenced credential",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-map-type": "atomic",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "custom credential refs must set both group and kind",
                                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                          }
                                        ],
                                        "additionalProperties": false
                                      }
                                    },
                                    "required": [
                                      "clientId"
                                    ],
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "privateKeyJwt settings require method PrivateKeyJwt",
                                        "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                                      },
                                      {
                                        "message": "secretRef is not valid with method PrivateKeyJwt",
                                        "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                                      },
                                      {
                                        "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                                        "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "grantType": {
                                    "description": "RFC followed by the request. Defaults to TokenExchange (RFC 8693).",
                                    "enum": [
                                      "JwtBearer",
                                      "TokenExchange"
                                    ],
                                    "type": "string"
                                  },
                                  "location": {
                                    "description": "Where the exchanged token is written to the backend request.\nDefaults to Authorization: Bearer.",
                                    "properties": {
                                      "cookie": {
                                        "properties": {
                                          "name": {
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "header": {
                                        "properties": {
                                          "name": {
                                            "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                            "type": "string"
                                          },
                                          "prefix": {
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      },
                                      "queryParameter": {
                                        "properties": {
                                          "name": {
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                        "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "path": {
                                    "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                                    "pattern": "^/",
                                    "type": "string"
                                  },
                                  "requestedTokenType": {
                                    "description": "RFC 8693 requested_token_type. Unlike subject/actor token types, only the\nbuilt-in values may be requested; custom URIs are not supported here.",
                                    "enum": [
                                      "AccessToken",
                                      "Jwt",
                                      "IdToken",
                                      "IdJag"
                                    ],
                                    "type": "string"
                                  },
                                  "resources": {
                                    "description": "Resources sent to the token endpoint.",
                                    "items": {
                                      "type": "string"
                                    },
                                    "maxItems": 64,
                                    "minItems": 1,
                                    "type": "array"
                                  },
                                  "scopes": {
                                    "description": "Scopes sent to the token endpoint.",
                                    "items": {
                                      "type": "string"
                                    },
                                    "maxItems": 64,
                                    "minItems": 1,
                                    "type": "array"
                                  },
                                  "subjectToken": {
                                    "description": "Subject token / assertion source and type. Defaults to Authorization Bearer, AccessToken.\nThe token type may be a built-in value or a custom absolute URI for providers\nthat support custom token exchange profiles.",
                                    "properties": {
                                      "source": {
                                        "description": "Where to read the token. CEL `expression` variant is permitted.",
                                        "properties": {
                                          "cookie": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "expression": {
                                            "description": "CEL expression that extracts the credential from the request.",
                                            "maxLength": 16384,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "header": {
                                            "properties": {
                                              "name": {
                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                "type": "string"
                                              },
                                              "prefix": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "queryParameter": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "tokenType": {
                                        "description": "OAuth token type. Empty defaults to AccessToken. Custom absolute URI values\nare supported for subject tokens.",
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "url": {
                                    "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                    "maxLength": 1024,
                                    "minLength": 1,
                                    "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                    "type": "string"
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "actorToken is only valid with TokenExchange grantType",
                                    "rule": "!(has(self.actorToken) && has(self.grantType) && self.grantType == 'JwtBearer')"
                                  },
                                  {
                                    "message": "requestedTokenType is only valid with TokenExchange grantType",
                                    "rule": "!(has(self.requestedTokenType) && has(self.grantType) && self.grantType == 'JwtBearer')"
                                  },
                                  {
                                    "message": "requestedTokenType IdJag is only supported by crossAppAccess",
                                    "rule": "!has(self.requestedTokenType) || self.requestedTokenType != 'IdJag'"
                                  },
                                  {
                                    "message": "path may not be set when url is set",
                                    "rule": "has(self.url) ? !has(self.path) : true"
                                  },
                                  {
                                    "message": "exactly one of the fields in [backendRef url] must be set",
                                    "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "passthrough": {
                                "description": "Reuses a client token already validated by another policy. Those policies\nmay strip client credentials; passthrough adds the original token back to\nthe backend request. Without client auth policies, this has no effect.",
                                "type": "object"
                              },
                              "secretRef": {
                                "description": "Credential source for the authorization value, defaulting to a Kubernetes\n`Secret`. By default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                                "properties": {
                                  "group": {
                                    "description": "API group of the referenced credential; empty selects the core API group",
                                    "type": "string"
                                  },
                                  "key": {
                                    "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                    "maxLength": 253,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "kind": {
                                    "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                    "type": "string"
                                  },
                                  "name": {
                                    "description": "Name of the referenced credential",
                                    "maxLength": 253,
                                    "minLength": 1,
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "name"
                                ],
                                "type": "object",
                                "x-kubernetes-map-type": "atomic",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "custom credential refs must set both group and kind",
                                    "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                  }
                                ],
                                "additionalProperties": false
                              }
                            },
                            "type": "object",
                            "x-kubernetes-validations": [
                              {
                                "message": "must specify credentials, or at most one of key/secretRef/passthrough/aws/azure/gcp/oauthTokenExchange/crossAppAccess/jwtSign (credentials may be combined with a primary auth kind)",
                                "rule": "has(self.credentials) || has(self.key) || has(self.secretRef) || has(self.passthrough) || has(self.aws) || has(self.azure) || has(self.gcp) || has(self.oauthTokenExchange) || has(self.crossAppAccess) || has(self.jwtSign)"
                              },
                              {
                                "message": "location may only be set for key, secretRef, or passthrough auth",
                                "rule": "has(self.location) ? has(self.key) || has(self.secretRef) || has(self.passthrough) : true"
                              },
                              {
                                "message": "at most one of the fields in [key secretRef passthrough aws azure gcp oauthTokenExchange crossAppAccess jwtSign] may be set",
                                "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0)+(has(self.passthrough)?1:0)+(has(self.aws)?1:0)+(has(self.azure)?1:0)+(has(self.gcp)?1:0)+(has(self.oauthTokenExchange)?1:0)+(has(self.crossAppAccess)?1:0)+(has(self.jwtSign)?1:0) <= 1"
                              }
                            ],
                            "additionalProperties": false
                          },
                          "http": {
                            "description": "Settings for managing HTTP requests to the backend",
                            "properties": {
                              "requestTimeout": {
                                "description": "Deadline for receiving a response from the backend.",
                                "maxLength": 32,
                                "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                "type": "string",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "requestTimeout must be at least 1ms",
                                    "rule": "duration(self) >= duration('1ms')"
                                  }
                                ]
                              },
                              "version": {
                                "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                "enum": [
                                  "HTTP1",
                                  "HTTP2"
                                ],
                                "type": "string"
                              }
                            },
                            "type": "object",
                            "additionalProperties": false
                          },
                          "tcp": {
                            "description": "Settings for managing TCP connections to the backend",
                            "properties": {
                              "connectTimeout": {
                                "description": "Deadline for establishing a connection to\nthe destination.",
                                "maxLength": 32,
                                "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                "type": "string",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "connectTimeout must be at least 100ms",
                                    "rule": "duration(self) >= duration('100ms')"
                                  }
                                ]
                              },
                              "keepalive": {
                                "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                "properties": {
                                  "interval": {
                                    "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                    "maxLength": 32,
                                    "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                    "type": "string",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "interval must be at least 1 second",
                                        "rule": "duration(self) >= duration('1s')"
                                      }
                                    ]
                                  },
                                  "retries": {
                                    "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                    "format": "int32",
                                    "maximum": 64,
                                    "minimum": 1,
                                    "type": "integer"
                                  },
                                  "time": {
                                    "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                    "maxLength": 32,
                                    "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                    "type": "string",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "time must be at least 1 second",
                                        "rule": "duration(self) >= duration('1s')"
                                      }
                                    ]
                                  }
                                },
                                "type": "object",
                                "additionalProperties": false
                              }
                            },
                            "type": "object",
                            "additionalProperties": false
                          },
                          "tls": {
                            "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                            "properties": {
                              "alpnProtocols": {
                                "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                "items": {
                                  "maxLength": 64,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "maxItems": 16,
                                "minItems": 1,
                                "type": "array"
                              },
                              "caCertificateRefs": {
                                "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                "items": {
                                  "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                  "properties": {
                                    "key": {
                                      "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                      "type": "string"
                                    },
                                    "kind": {
                                      "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                      "enum": [
                                        "ConfigMap",
                                        "Secret"
                                      ],
                                      "type": "string"
                                    },
                                    "name": {
                                      "description": "Name of the referenced CA certificate source.",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name"
                                  ],
                                  "type": "object",
                                  "x-kubernetes-map-type": "atomic",
                                  "additionalProperties": false
                                },
                                "maxItems": 1,
                                "type": "array",
                                "x-kubernetes-list-type": "atomic"
                              },
                              "certificateSource": {
                                "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                "enum": [
                                  "Inline",
                                  "SPIFFE"
                                ],
                                "type": "string"
                              },
                              "insecureSkipVerify": {
                                "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                "enum": [
                                  "All",
                                  "Hostname"
                                ],
                                "type": "string"
                              },
                              "keyExchangeGroups": {
                                "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                "items": {
                                  "enum": [
                                    "P-256",
                                    "P-384",
                                    "X25519",
                                    "X25519_MLKEM768"
                                  ],
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              "mtlsCertificateRef": {
                                "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                "items": {
                                  "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                  "properties": {
                                    "group": {
                                      "description": "API group of the referenced credential; empty selects the core API group",
                                      "type": "string"
                                    },
                                    "kind": {
                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                      "type": "string"
                                    },
                                    "name": {
                                      "description": "Name of the referenced credential",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name"
                                  ],
                                  "type": "object",
                                  "x-kubernetes-map-type": "atomic",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "custom credential refs must set both group and kind",
                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "maxItems": 1,
                                "type": "array",
                                "x-kubernetes-list-type": "atomic"
                              },
                              "sni": {
                                "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                "maxLength": 253,
                                "minLength": 1,
                                "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                "type": "string"
                              },
                              "verifySubjectAltNames": {
                                "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                "items": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "maxItems": 16,
                                "minItems": 1,
                                "type": "array"
                              }
                            },
                            "type": "object",
                            "x-kubernetes-validations": [
                              {
                                "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                              },
                              {
                                "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                              },
                              {
                                "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                              },
                              {
                                "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                              }
                            ],
                            "additionalProperties": false
                          },
                          "tunnel": {
                            "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                            "properties": {
                              "backendRef": {
                                "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                "properties": {
                                  "group": {
                                    "default": "",
                                    "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                    "maxLength": 253,
                                    "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                    "type": "string"
                                  },
                                  "kind": {
                                    "default": "Service",
                                    "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                    "type": "string"
                                  },
                                  "name": {
                                    "description": "Name is the name of the referent.",
                                    "maxLength": 253,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "namespace": {
                                    "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                    "type": "string"
                                  },
                                  "port": {
                                    "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                    "format": "int32",
                                    "maximum": 65535,
                                    "minimum": 1,
                                    "type": "integer"
                                  }
                                },
                                "required": [
                                  "name"
                                ],
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "Must have port for Service reference",
                                    "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "mode": {
                                "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                "enum": [
                                  "Auto",
                                  "Connect"
                                ],
                                "type": "string"
                              },
                              "url": {
                                "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                "maxLength": 1024,
                                "minLength": 1,
                                "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                "type": "string"
                              }
                            },
                            "type": "object",
                            "x-kubernetes-validations": [
                              {
                                "message": "exactly one of the fields in [backendRef url] must be set",
                                "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                              },
                              {
                                "message": "url must not include a path for backend tunnel",
                                "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                              }
                            ],
                            "additionalProperties": false
                          }
                        },
                        "type": "object",
                        "additionalProperties": false
                      },
                      "port": {
                        "description": "Port number of the MCP target.",
                        "format": "int32",
                        "maximum": 65535,
                        "minimum": 1,
                        "type": "integer"
                      },
                      "protocol": {
                        "description": "Protocol to use for the connection to the MCP\ntarget.",
                        "enum": [
                          "SSE",
                          "StreamableHTTP"
                        ],
                        "type": "string"
                      }
                    },
                    "required": [
                      "port"
                    ],
                    "type": "object",
                    "x-kubernetes-validations": [
                      {
                        "message": "mcp target policies may not be used with backendRef",
                        "rule": "!has(self.backendRef) || !has(self.policies)"
                      },
                      {
                        "message": "exactly one of the fields in [host backendRef] must be set",
                        "rule": "(has(self.host)?1:0)+(has(self.backendRef)?1:0) == 1"
                      }
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "name"
                ],
                "type": "object",
                "x-kubernetes-validations": [
                  {
                    "message": "exactly one of the fields in [selector static] must be set",
                    "rule": "(has(self.selector)?1:0)+(has(self.static)?1:0) == 1"
                  }
                ],
                "additionalProperties": false
              },
              "maxItems": 128,
              "minItems": 1,
              "type": "array",
              "x-kubernetes-list-map-keys": [
                "name"
              ],
              "x-kubernetes-list-type": "map"
            }
          },
          "required": [
            "targets"
          ],
          "type": "object",
          "additionalProperties": false
        },
        "policies": {
          "description": "Policies for communicating with this backend. Policies may also be set\nwith AgentgatewayPolicy. Backend policies take precedence over policy\nresources when they set the same field.",
          "properties": {
            "ai": {
              "description": "Settings for AI workloads. This is only applicable when\nconnecting to a `Backend` of type `ai`.",
              "properties": {
                "defaults": {
                  "description": "Defaults to merge with user input fields. If the field is already set, the field in the request is used.",
                  "items": {
                    "description": "Default value for a field in the JSON request body sent to the LLM provider.\nThese defaults are merged with the user-provided request to ensure missing fields are populated.\n\nUser input fields here refer to the fields in the JSON request body that a client sends when making a request to the LLM provider.\nDefaults set here do _not_ override those user-provided values unless you explicitly set `override` to `true`.\n\nExample: Setting a default system field for Anthropic, which does not support system role messages:\n\n\tdefaults:\n\t  - field: \"system\"\n\t    value: \"answer all questions in French\"\n\nExample: Setting a default temperature and overriding `max_tokens`:\n\n\tdefaults:\n\t  - field: \"temperature\"\n\t    value: \"0.5\"\n\t  - field: \"max_tokens\"\n\t    value: \"100\"\n\t    override: true\n\nExample: Setting custom lists fields:\n\n\tdefaults:\n\t  - field: \"custom_integer_list\"\n\t    value: [1,2,3]\n\n\toverrides:\n\t  - field: \"custom_string_list\"\n\t    value: [\"one\",\"two\",\"three\"]\n\nNote: The `field` values correspond to keys in the JSON request body, not fields in this CRD.",
                    "properties": {
                      "field": {
                        "description": "Name of the field.",
                        "maxLength": 256,
                        "minLength": 1,
                        "type": "string"
                      },
                      "value": {
                        "description": "Default value for the field. This can be any JSON data type.",
                        "x-kubernetes-preserve-unknown-fields": true
                      }
                    },
                    "required": [
                      "field",
                      "value"
                    ],
                    "type": "object",
                    "additionalProperties": false
                  },
                  "maxItems": 64,
                  "minItems": 1,
                  "type": "array"
                },
                "finalTransformations": {
                  "description": "CEL transformations to compute and set fields in the request body.\nThe expression result overwrites any existing value for that field.\nThis has a higher priority than `overrides` if both are set for the same\nkey.\nThose transformations are applied after the request is converted to the provider's format, so they can be used to set provider-specific fields.",
                  "items": {
                    "description": "Maps a request JSON field to a CEL expression.\nThe expression is evaluated against the current request body and its result\nis assigned to the configured field.",
                    "properties": {
                      "expression": {
                        "description": "CEL expression used to compute the field value.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "field": {
                        "description": "Name of the field to set.",
                        "maxLength": 256,
                        "minLength": 1,
                        "type": "string"
                      }
                    },
                    "required": [
                      "expression",
                      "field"
                    ],
                    "type": "object",
                    "additionalProperties": false
                  },
                  "maxItems": 64,
                  "minItems": 1,
                  "type": "array",
                  "x-kubernetes-list-map-keys": [
                    "field"
                  ],
                  "x-kubernetes-list-type": "map"
                },
                "modelAliases": {
                  "additionalProperties": {
                    "type": "string"
                  },
                  "description": "Maps friendly model names to actual provider model names.\nExample: `{\"fast\": \"gpt-3.5-turbo\", \"smart\": \"gpt-4-turbo\"}`.\nNote: This field is only applicable when using the agentgateway data plane.",
                  "maxProperties": 64,
                  "type": "object"
                },
                "overrides": {
                  "description": "Overrides to merge with user input fields. If the field is already set, the field is overwritten.",
                  "items": {
                    "description": "Default value for a field in the JSON request body sent to the LLM provider.\nThese defaults are merged with the user-provided request to ensure missing fields are populated.\n\nUser input fields here refer to the fields in the JSON request body that a client sends when making a request to the LLM provider.\nDefaults set here do _not_ override those user-provided values unless you explicitly set `override` to `true`.\n\nExample: Setting a default system field for Anthropic, which does not support system role messages:\n\n\tdefaults:\n\t  - field: \"system\"\n\t    value: \"answer all questions in French\"\n\nExample: Setting a default temperature and overriding `max_tokens`:\n\n\tdefaults:\n\t  - field: \"temperature\"\n\t    value: \"0.5\"\n\t  - field: \"max_tokens\"\n\t    value: \"100\"\n\t    override: true\n\nExample: Setting custom lists fields:\n\n\tdefaults:\n\t  - field: \"custom_integer_list\"\n\t    value: [1,2,3]\n\n\toverrides:\n\t  - field: \"custom_string_list\"\n\t    value: [\"one\",\"two\",\"three\"]\n\nNote: The `field` values correspond to keys in the JSON request body, not fields in this CRD.",
                    "properties": {
                      "field": {
                        "description": "Name of the field.",
                        "maxLength": 256,
                        "minLength": 1,
                        "type": "string"
                      },
                      "value": {
                        "description": "Default value for the field. This can be any JSON data type.",
                        "x-kubernetes-preserve-unknown-fields": true
                      }
                    },
                    "required": [
                      "field",
                      "value"
                    ],
                    "type": "object",
                    "additionalProperties": false
                  },
                  "maxItems": 64,
                  "minItems": 1,
                  "type": "array"
                },
                "prompt": {
                  "description": "Enriches requests sent to the LLM provider by appending and prepending system prompts. This can be configured only for\nLLM providers that use the `CHAT` or `CHAT_STREAMING` API route type.",
                  "properties": {
                    "append": {
                      "description": "Messages to append to the prompt sent by the client.",
                      "items": {
                        "description": "An entry for a message to prepend or append to each prompt.",
                        "properties": {
                          "content": {
                            "description": "String content of the message.",
                            "type": "string"
                          },
                          "role": {
                            "description": "Role of the message. The available roles depend on the backend\nLLM provider model, such as `SYSTEM` or `USER` in the OpenAI API.",
                            "type": "string"
                          }
                        },
                        "required": [
                          "content",
                          "role"
                        ],
                        "type": "object",
                        "additionalProperties": false
                      },
                      "type": "array"
                    },
                    "prepend": {
                      "description": "Messages to prepend to the prompt sent by the client.",
                      "items": {
                        "description": "An entry for a message to prepend or append to each prompt.",
                        "properties": {
                          "content": {
                            "description": "String content of the message.",
                            "type": "string"
                          },
                          "role": {
                            "description": "Role of the message. The available roles depend on the backend\nLLM provider model, such as `SYSTEM` or `USER` in the OpenAI API.",
                            "type": "string"
                          }
                        },
                        "required": [
                          "content",
                          "role"
                        ],
                        "type": "object",
                        "additionalProperties": false
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "promptCaching": {
                  "description": "Automatic prompt caching for supported\nproviders, currently AWS Bedrock.\nReduces API costs by caching static content like system prompts and tool definitions.\nOnly applicable for Bedrock Claude 3+ and Nova models.",
                  "properties": {
                    "cacheMessageOffset": {
                      "description": "Shifts the message cache point further back in the\nconversation. 0 (default) places it at the second-to-last message.\nHigher values move it N additional messages towards the start, clamped\nto bounds.",
                      "minimum": 0,
                      "type": "integer"
                    },
                    "cacheMessages": {
                      "description": "Enables caching for conversation messages. Defaults to true.\nCaches all messages in the conversation for cost savings.",
                      "type": "boolean"
                    },
                    "cacheSystem": {
                      "description": "Enables caching for system prompts. Defaults to true.\nInserts a cache point after all system messages.",
                      "type": "boolean"
                    },
                    "cacheTools": {
                      "description": "Enables caching for tool definitions. Defaults to false.\nInserts a cache point after all tool specifications.",
                      "type": "boolean"
                    },
                    "minTokens": {
                      "description": "Minimum estimated token count\nbefore caching is enabled. Uses rough heuristic (word count \u00d7 1.3) to estimate tokens.\nDefaults to 1024. Bedrock requires at least 1,024 tokens for caching to be effective.",
                      "minimum": 0,
                      "type": "integer"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "promptGuard": {
                  "description": "Guardrails for LLM requests and responses.",
                  "properties": {
                    "request": {
                      "description": "Prompt guards to apply to requests sent by the client.",
                      "items": {
                        "description": "Prompt guards to apply to requests sent by the client.",
                        "properties": {
                          "bedrockGuardrails": {
                            "description": "AWS Bedrock Guardrails settings for prompt\nguarding.",
                            "properties": {
                              "action": {
                                "description": "Action controls whether the guardrail's verdict is enforced or only\nobserved. `Reject` (the default) enforces the guardrail: a blocked\nassessment rejects the request/response and an anonymized assessment masks\nthe matched content. `Audit` runs the guardrail in observe mode: it is\ninvoked and its assessment recorded (metrics + structured log), but the\nrequest/response is never blocked or masked.",
                                "enum": [
                                  "Audit",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "failureMode": {
                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                "enum": [
                                  "FailClosed",
                                  "FailOpen"
                                ],
                                "type": "string"
                              },
                              "identifier": {
                                "description": "Identifier of the Guardrail policy to use for the backend.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              },
                              "policies": {
                                "description": "Policies for communicating with AWS Bedrock Guardrails.",
                                "properties": {
                                  "auth": {
                                    "description": "Settings for authenticating to AWS Bedrock Guardrails.",
                                    "properties": {
                                      "aws": {
                                        "description": "AWS authentication method for Bedrock Guardrails. Use `aws: {}` for\ndefault AWS SDK credential discovery.",
                                        "properties": {
                                          "assumeRole": {
                                            "description": "AWS STS AssumeRole settings to use before signing backend requests.\nAmbient AWS credentials are used as the source credentials for STS.",
                                            "properties": {
                                              "externalId": {
                                                "description": "ExternalID is set when the role's trust policy requires sts:ExternalId.",
                                                "maxLength": 1224,
                                                "minLength": 2,
                                                "pattern": "^[\\w+=,.@:/-]+$",
                                                "type": "string"
                                              },
                                              "roleArn": {
                                                "description": "AWS IAM role ARN to assume.",
                                                "minLength": 1,
                                                "pattern": "^arn:aws[a-z-]*:iam::[0-9]{12}:role/.+$",
                                                "type": "string"
                                              },
                                              "sessionName": {
                                                "description": "SessionName is a custom session name (RoleSessionName) for CloudTrail and\nCost & Usage Report attribution. If unset, AWS generates a random name.",
                                                "pattern": "^[\\w+=,.@-]{2,64}$",
                                                "type": "string"
                                              },
                                              "sessionNameExpression": {
                                                "description": "SessionNameExpression is a CEL expression evaluated against each request\nto produce the session name (RoleSessionName), for example `jwt.sub` or\n`request.headers[\"x-team\"]`. If the expression does not produce a valid\nsession name at request time, the request is rejected.",
                                                "maxLength": 16384,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "tags": {
                                                "description": "Session tags passed to STS AssumeRole for cost attribution in the AWS Cost\n& Usage Report, once activated. STS allows at most 50 per role session.",
                                                "items": {
                                                  "description": "AwsSessionTag is an AWS STS session tag passed to AssumeRole for cost\nattribution. Exactly one of value and expression must be set.",
                                                  "properties": {
                                                    "expression": {
                                                      "description": "CEL expression evaluated against each request to produce the tag value,\nfor example `jwt.sub` or `request.headers[\"x-app\"]`. Requests with invalid\ntag values are rejected.",
                                                      "maxLength": 16384,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    },
                                                    "key": {
                                                      "description": "Key is the tag key.",
                                                      "maxLength": 128,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    },
                                                    "value": {
                                                      "description": "Value is a static tag value.",
                                                      "maxLength": 256,
                                                      "type": "string"
                                                    }
                                                  },
                                                  "required": [
                                                    "key"
                                                  ],
                                                  "type": "object",
                                                  "x-kubernetes-validations": [
                                                    {
                                                      "message": "exactly one of value or expression must be set",
                                                      "rule": "has(self.value) != has(self.expression)"
                                                    }
                                                  ],
                                                  "additionalProperties": false
                                                },
                                                "maxItems": 50,
                                                "type": "array",
                                                "x-kubernetes-list-map-keys": [
                                                  "key"
                                                ],
                                                "x-kubernetes-list-type": "map"
                                              }
                                            },
                                            "required": [
                                              "roleArn"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "at most one of the fields in [sessionName sessionNameExpression] may be set",
                                                "rule": "(has(self.sessionName)?1:0)+(has(self.sessionNameExpression)?1:0) <= 1"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "region": {
                                            "description": "AWS SigV4 signing region, for example `us-east-1`. Set this when the\ntarget AWS service is in a different region than the gateway. If unset,\ntyped AWS backends may provide this automatically; otherwise the ambient\nAWS region is used.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "secretRef": {
                                            "description": "Credential source for AWS credentials, defaulting to a Kubernetes `Secret`.\nThe default Secret resolver expects `accessKey`, `secretKey`, and optional\n`sessionToken` keys.",
                                            "properties": {
                                              "group": {
                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                "type": "string"
                                              },
                                              "kind": {
                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                "type": "string"
                                              },
                                              "name": {
                                                "description": "Name of the referenced credential",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-map-type": "atomic",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "custom credential refs must set both group and kind",
                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "serviceName": {
                                            "description": "AWS SigV4 signing service name, for example\n`bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS\nbackends may provide this automatically.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "secretRef and assumeRole are mutually exclusive",
                                            "rule": "!(has(self.secretRef) && has(self.assumeRole))"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "key": {
                                        "description": "Inline API key to use as the value of the `Authorization` header.\nThis option is the least secure; usage of a `Secret` is preferred.",
                                        "maxLength": 2048,
                                        "type": "string"
                                      },
                                      "location": {
                                        "description": "Where API keys are inserted. Defaults to the `Authorization` header with\nthe `Bearer ` prefix. Applies to `key` and `secretRef`.",
                                        "properties": {
                                          "cookie": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "header": {
                                            "properties": {
                                              "name": {
                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                "type": "string"
                                              },
                                              "prefix": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "queryParameter": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "secretRef": {
                                        "description": "Credential source for the API key, defaulting to a Kubernetes `Secret`.\nBy default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                                        "properties": {
                                          "group": {
                                            "description": "API group of the referenced credential; empty selects the core API group",
                                            "type": "string"
                                          },
                                          "key": {
                                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "kind": {
                                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name of the referenced credential",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-map-type": "atomic",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "custom credential refs must set both group and kind",
                                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                          }
                                        ],
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "location may only be set for key or secretRef auth",
                                        "rule": "has(self.location) ? has(self.key) || has(self.secretRef) : true"
                                      },
                                      {
                                        "message": "exactly one of the fields in [key secretRef aws] must be set",
                                        "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0)+(has(self.aws)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "http": {
                                    "description": "Settings for managing HTTP requests to the backend",
                                    "properties": {
                                      "requestTimeout": {
                                        "description": "Deadline for receiving a response from the backend.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "requestTimeout must be at least 1ms",
                                            "rule": "duration(self) >= duration('1ms')"
                                          }
                                        ]
                                      },
                                      "version": {
                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                        "enum": [
                                          "HTTP1",
                                          "HTTP2"
                                        ],
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tcp": {
                                    "description": "Settings for managing TCP connections to the backend",
                                    "properties": {
                                      "connectTimeout": {
                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "connectTimeout must be at least 100ms",
                                            "rule": "duration(self) >= duration('100ms')"
                                          }
                                        ]
                                      },
                                      "keepalive": {
                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                        "properties": {
                                          "interval": {
                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "interval must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          },
                                          "retries": {
                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                            "format": "int32",
                                            "maximum": 64,
                                            "minimum": 1,
                                            "type": "integer"
                                          },
                                          "time": {
                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "time must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tls": {
                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                    "properties": {
                                      "alpnProtocols": {
                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                        "items": {
                                          "maxLength": 64,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      },
                                      "caCertificateRefs": {
                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                        "items": {
                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                          "properties": {
                                            "key": {
                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                              "enum": [
                                                "ConfigMap",
                                                "Secret"
                                              ],
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced CA certificate source.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "certificateSource": {
                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                        "enum": [
                                          "Inline",
                                          "SPIFFE"
                                        ],
                                        "type": "string"
                                      },
                                      "insecureSkipVerify": {
                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                        "enum": [
                                          "All",
                                          "Hostname"
                                        ],
                                        "type": "string"
                                      },
                                      "keyExchangeGroups": {
                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                        "items": {
                                          "enum": [
                                            "P-256",
                                            "P-384",
                                            "X25519",
                                            "X25519_MLKEM768"
                                          ],
                                          "type": "string"
                                        },
                                        "type": "array"
                                      },
                                      "mtlsCertificateRef": {
                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                        "items": {
                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                          "properties": {
                                            "group": {
                                              "description": "API group of the referenced credential; empty selects the core API group",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced credential",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "custom credential refs must set both group and kind",
                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "sni": {
                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                        "type": "string"
                                      },
                                      "verifySubjectAltNames": {
                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                        "items": {
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                      },
                                      {
                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                      },
                                      {
                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                      },
                                      {
                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "tunnel": {
                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                    "properties": {
                                      "backendRef": {
                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                        "properties": {
                                          "group": {
                                            "default": "",
                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                            "maxLength": 253,
                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                            "type": "string"
                                          },
                                          "kind": {
                                            "default": "Service",
                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name is the name of the referent.",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "namespace": {
                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "port": {
                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                            "format": "int32",
                                            "maximum": 65535,
                                            "minimum": 1,
                                            "type": "integer"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "Must have port for Service reference",
                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "mode": {
                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                        "enum": [
                                          "Auto",
                                          "Connect"
                                        ],
                                        "type": "string"
                                      },
                                      "url": {
                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                        "maxLength": 1024,
                                        "minLength": 1,
                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                      },
                                      {
                                        "message": "url must not include a path for backend tunnel",
                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                      }
                                    ],
                                    "additionalProperties": false
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "region": {
                                "description": "AWS region where the guardrail is deployed, for example\n`us-west-2`).",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              },
                              "version": {
                                "description": "Version of the Guardrail policy to use for the backend.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              }
                            },
                            "required": [
                              "identifier",
                              "region",
                              "version"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          },
                          "googleModelArmor": {
                            "description": "Google Model Armor settings for prompt guarding.",
                            "properties": {
                              "action": {
                                "description": "Action controls whether flagged content is rejected or only observed.\n`Reject` (the default) rejects flagged content; `Audit` records the\nwould-be rejection without blocking.",
                                "enum": [
                                  "Audit",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "failureMode": {
                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                "enum": [
                                  "FailClosed",
                                  "FailOpen"
                                ],
                                "type": "string"
                              },
                              "location": {
                                "description": "Google Cloud location, for example `us-central1`.\nDefaults to `us-central1` if not specified.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              },
                              "policies": {
                                "description": "Policies for communicating with Google Model Armor.",
                                "properties": {
                                  "auth": {
                                    "description": "Settings for authenticating to Google Model Armor.",
                                    "properties": {
                                      "gcp": {
                                        "description": "Google authentication method for Model Armor. Use `gcp: {}` for default\nGoogle credential discovery.",
                                        "properties": {
                                          "audience": {
                                            "description": "Explicit `aud` value for the ID token. Only\nvalid with `IdToken` type. If not set, the `aud` is automatically\nderived from the backend hostname.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "secretRef": {
                                            "description": "Credential source for ADC-compatible Google credential JSON, defaulting to\na Kubernetes `Secret`. By default, the value is read from\n`credentials.json`; set `secretRef.key` to override it. When omitted,\nambient credentials are used.",
                                            "properties": {
                                              "group": {
                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                "type": "string"
                                              },
                                              "key": {
                                                "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "kind": {
                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                "type": "string"
                                              },
                                              "name": {
                                                "description": "Name of the referenced credential",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-map-type": "atomic",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "custom credential refs must set both group and kind",
                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "type": {
                                            "description": "The type of token to generate. To authenticate to GCP services,\ngenerally an `AccessToken` is used. To authenticate to Cloud Run, an\n`IdToken` is used.",
                                            "enum": [
                                              "AccessToken",
                                              "IdToken"
                                            ],
                                            "type": "string"
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "audience is only valid with IdToken",
                                            "rule": "has(self.audience) ? self.type == 'IdToken' : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [gcp] must be set",
                                        "rule": "(has(self.gcp)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "http": {
                                    "description": "Settings for managing HTTP requests to the backend",
                                    "properties": {
                                      "requestTimeout": {
                                        "description": "Deadline for receiving a response from the backend.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "requestTimeout must be at least 1ms",
                                            "rule": "duration(self) >= duration('1ms')"
                                          }
                                        ]
                                      },
                                      "version": {
                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                        "enum": [
                                          "HTTP1",
                                          "HTTP2"
                                        ],
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tcp": {
                                    "description": "Settings for managing TCP connections to the backend",
                                    "properties": {
                                      "connectTimeout": {
                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "connectTimeout must be at least 100ms",
                                            "rule": "duration(self) >= duration('100ms')"
                                          }
                                        ]
                                      },
                                      "keepalive": {
                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                        "properties": {
                                          "interval": {
                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "interval must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          },
                                          "retries": {
                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                            "format": "int32",
                                            "maximum": 64,
                                            "minimum": 1,
                                            "type": "integer"
                                          },
                                          "time": {
                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "time must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tls": {
                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                    "properties": {
                                      "alpnProtocols": {
                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                        "items": {
                                          "maxLength": 64,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      },
                                      "caCertificateRefs": {
                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                        "items": {
                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                          "properties": {
                                            "key": {
                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                              "enum": [
                                                "ConfigMap",
                                                "Secret"
                                              ],
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced CA certificate source.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "certificateSource": {
                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                        "enum": [
                                          "Inline",
                                          "SPIFFE"
                                        ],
                                        "type": "string"
                                      },
                                      "insecureSkipVerify": {
                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                        "enum": [
                                          "All",
                                          "Hostname"
                                        ],
                                        "type": "string"
                                      },
                                      "keyExchangeGroups": {
                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                        "items": {
                                          "enum": [
                                            "P-256",
                                            "P-384",
                                            "X25519",
                                            "X25519_MLKEM768"
                                          ],
                                          "type": "string"
                                        },
                                        "type": "array"
                                      },
                                      "mtlsCertificateRef": {
                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                        "items": {
                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                          "properties": {
                                            "group": {
                                              "description": "API group of the referenced credential; empty selects the core API group",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced credential",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "custom credential refs must set both group and kind",
                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "sni": {
                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                        "type": "string"
                                      },
                                      "verifySubjectAltNames": {
                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                        "items": {
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                      },
                                      {
                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                      },
                                      {
                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                      },
                                      {
                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "tunnel": {
                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                    "properties": {
                                      "backendRef": {
                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                        "properties": {
                                          "group": {
                                            "default": "",
                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                            "maxLength": 253,
                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                            "type": "string"
                                          },
                                          "kind": {
                                            "default": "Service",
                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name is the name of the referent.",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "namespace": {
                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "port": {
                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                            "format": "int32",
                                            "maximum": 65535,
                                            "minimum": 1,
                                            "type": "integer"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "Must have port for Service reference",
                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "mode": {
                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                        "enum": [
                                          "Auto",
                                          "Connect"
                                        ],
                                        "type": "string"
                                      },
                                      "url": {
                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                        "maxLength": 1024,
                                        "minLength": 1,
                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                      },
                                      {
                                        "message": "url must not include a path for backend tunnel",
                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                      }
                                    ],
                                    "additionalProperties": false
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "projectId": {
                                "description": "Google Cloud project ID.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              },
                              "templateId": {
                                "description": "Template ID for Google Model Armor.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              }
                            },
                            "required": [
                              "projectId",
                              "templateId"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          },
                          "openAIModeration": {
                            "description": "Passes prompt data through the OpenAI Moderations\nendpoint.\nSee https://developers.openai.com/api/reference/resources/moderations for more information.",
                            "properties": {
                              "action": {
                                "description": "Action controls whether flagged content is rejected or only observed.\n`Reject` (the default) rejects flagged content; `Audit` records the\nwould-be rejection without blocking.",
                                "enum": [
                                  "Audit",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "failureMode": {
                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                "enum": [
                                  "FailClosed",
                                  "FailOpen"
                                ],
                                "type": "string"
                              },
                              "model": {
                                "description": "Moderation model to use. For example,\n`omni-moderation`.",
                                "type": "string"
                              },
                              "policies": {
                                "description": "Policies for communicating with OpenAI.",
                                "properties": {
                                  "auth": {
                                    "description": "Settings for authenticating to OpenAI.",
                                    "properties": {
                                      "key": {
                                        "description": "Inline key to use as the value of the\n`Authorization` header. This option is the least secure; usage of a\n`Secret` is preferred.",
                                        "maxLength": 2048,
                                        "type": "string"
                                      },
                                      "location": {
                                        "description": "Where backend credentials are inserted. Defaults to the `Authorization`\nheader with the `Bearer ` prefix. Applies to `key` and `secretRef`.",
                                        "properties": {
                                          "cookie": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "header": {
                                            "properties": {
                                              "name": {
                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                "type": "string"
                                              },
                                              "prefix": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "queryParameter": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "secretRef": {
                                        "description": "Credential source for the authorization value, defaulting to a Kubernetes\n`Secret`. By default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                                        "properties": {
                                          "group": {
                                            "description": "API group of the referenced credential; empty selects the core API group",
                                            "type": "string"
                                          },
                                          "key": {
                                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "kind": {
                                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name of the referenced credential",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-map-type": "atomic",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "custom credential refs must set both group and kind",
                                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                          }
                                        ],
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [key secretRef] must be set",
                                        "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "http": {
                                    "description": "Settings for managing HTTP requests to the backend",
                                    "properties": {
                                      "requestTimeout": {
                                        "description": "Deadline for receiving a response from the backend.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "requestTimeout must be at least 1ms",
                                            "rule": "duration(self) >= duration('1ms')"
                                          }
                                        ]
                                      },
                                      "version": {
                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                        "enum": [
                                          "HTTP1",
                                          "HTTP2"
                                        ],
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tcp": {
                                    "description": "Settings for managing TCP connections to the backend",
                                    "properties": {
                                      "connectTimeout": {
                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "connectTimeout must be at least 100ms",
                                            "rule": "duration(self) >= duration('100ms')"
                                          }
                                        ]
                                      },
                                      "keepalive": {
                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                        "properties": {
                                          "interval": {
                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "interval must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          },
                                          "retries": {
                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                            "format": "int32",
                                            "maximum": 64,
                                            "minimum": 1,
                                            "type": "integer"
                                          },
                                          "time": {
                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "time must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tls": {
                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                    "properties": {
                                      "alpnProtocols": {
                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                        "items": {
                                          "maxLength": 64,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      },
                                      "caCertificateRefs": {
                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                        "items": {
                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                          "properties": {
                                            "key": {
                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                              "enum": [
                                                "ConfigMap",
                                                "Secret"
                                              ],
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced CA certificate source.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "certificateSource": {
                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                        "enum": [
                                          "Inline",
                                          "SPIFFE"
                                        ],
                                        "type": "string"
                                      },
                                      "insecureSkipVerify": {
                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                        "enum": [
                                          "All",
                                          "Hostname"
                                        ],
                                        "type": "string"
                                      },
                                      "keyExchangeGroups": {
                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                        "items": {
                                          "enum": [
                                            "P-256",
                                            "P-384",
                                            "X25519",
                                            "X25519_MLKEM768"
                                          ],
                                          "type": "string"
                                        },
                                        "type": "array"
                                      },
                                      "mtlsCertificateRef": {
                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                        "items": {
                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                          "properties": {
                                            "group": {
                                              "description": "API group of the referenced credential; empty selects the core API group",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced credential",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "custom credential refs must set both group and kind",
                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "sni": {
                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                        "type": "string"
                                      },
                                      "verifySubjectAltNames": {
                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                        "items": {
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                      },
                                      {
                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                      },
                                      {
                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                      },
                                      {
                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "tunnel": {
                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                    "properties": {
                                      "backendRef": {
                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                        "properties": {
                                          "group": {
                                            "default": "",
                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                            "maxLength": 253,
                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                            "type": "string"
                                          },
                                          "kind": {
                                            "default": "Service",
                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name is the name of the referent.",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "namespace": {
                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "port": {
                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                            "format": "int32",
                                            "maximum": 65535,
                                            "minimum": 1,
                                            "type": "integer"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "Must have port for Service reference",
                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "mode": {
                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                        "enum": [
                                          "Auto",
                                          "Connect"
                                        ],
                                        "type": "string"
                                      },
                                      "url": {
                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                        "maxLength": 1024,
                                        "minLength": 1,
                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                      },
                                      {
                                        "message": "url must not include a path for backend tunnel",
                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                      }
                                    ],
                                    "additionalProperties": false
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                  }
                                ],
                                "additionalProperties": false
                              }
                            },
                            "type": "object",
                            "additionalProperties": false
                          },
                          "regex": {
                            "description": "Regular expression (regex) matching for prompt guards and data masking.",
                            "properties": {
                              "action": {
                                "description": "The action to take if a regex pattern is matched in a request or response.\nThe action applies to request and response matches alike. Note that\n`Mask` is not applied to streamed responses: matched content in a\nstreamed response is passed through unmodified.\nDefaults to `Mask`.",
                                "enum": [
                                  "Audit",
                                  "Mask",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "builtins": {
                                "description": "Built-in regex patterns to match against the request or response.\nMatches and built-ins are additive.",
                                "items": {
                                  "description": "Built-in regex patterns for specific types of strings in prompts.\nFor example, if you specify `CreditCard`, any credit card numbers\nin the request or response are matched.",
                                  "enum": [
                                    "CaSin",
                                    "CreditCard",
                                    "Email",
                                    "PhoneNumber",
                                    "Ssn"
                                  ],
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              "matches": {
                                "description": "Regex patterns to match against the request or response.\nMatches and built-ins are additive.",
                                "items": {
                                  "maxLength": 1024,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "type": "array"
                              }
                            },
                            "type": "object",
                            "additionalProperties": false
                          },
                          "response": {
                            "description": "Custom response message to return to the client. If not specified, defaults to\n`The request was rejected due to inappropriate content`.",
                            "properties": {
                              "message": {
                                "description": "Custom response message to return to the client. If not specified, defaults to\n`The request was rejected due to inappropriate content`.",
                                "type": "string"
                              },
                              "statusCode": {
                                "description": "Status code to return to the client. Defaults to 403.",
                                "format": "int32",
                                "maximum": 599,
                                "minimum": 200,
                                "type": "integer"
                              }
                            },
                            "type": "object",
                            "additionalProperties": false
                          },
                          "scope": {
                            "description": "Which parts of the request this guard inspects. When unset, defaults to\n`SystemPrompt` and `Messages`. Tool call inputs and outputs are not\ninspected unless `ToolInput`/`ToolOutput` are listed explicitly.\nIn APIs that send tool arguments as opaque JSON, such as Completions, the\narguments are masked as a single string, meaning a prompt guard has the\npotential to rewrite the arguments into invalid JSON.",
                            "items": {
                              "description": "Which category of request content a prompt guard inspects.",
                              "enum": [
                                "Messages",
                                "SystemPrompt",
                                "ToolInput",
                                "ToolOutput"
                              ],
                              "type": "string"
                            },
                            "maxItems": 4,
                            "minItems": 1,
                            "type": "array",
                            "x-kubernetes-list-type": "set"
                          },
                          "webhook": {
                            "description": "Webhook that receives requests for prompt guarding.",
                            "properties": {
                              "action": {
                                "description": "Action controls whether the webhook's verdict is enforced or only observed.\n`Reject` (the default) enforces it; `Audit` records the would-be action\nwithout blocking or masking.",
                                "enum": [
                                  "Audit",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "backendRef": {
                                "description": "Webhook server to reach.\n\nSupported types: Service and Backend.",
                                "properties": {
                                  "group": {
                                    "default": "",
                                    "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                    "maxLength": 253,
                                    "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                    "type": "string"
                                  },
                                  "kind": {
                                    "default": "Service",
                                    "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                    "type": "string"
                                  },
                                  "name": {
                                    "description": "Name is the name of the referent.",
                                    "maxLength": 253,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "namespace": {
                                    "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                    "type": "string"
                                  },
                                  "port": {
                                    "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                    "format": "int32",
                                    "maximum": 65535,
                                    "minimum": 1,
                                    "type": "integer"
                                  }
                                },
                                "required": [
                                  "name"
                                ],
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "Must have port for Service reference",
                                    "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "failureMode": {
                                "description": "Behavior when the webhook guardrail is unavailable\nor returns an error. `FailOpen` allows the request to continue.\n`FailClosed` (default) rejects the request.",
                                "enum": [
                                  "FailClosed",
                                  "FailOpen"
                                ],
                                "type": "string"
                              },
                              "forwardHeaderMatches": {
                                "description": "HTTP header matches used to select the headers to forward to the webhook.\nRequest headers are used when forwarding requests and response headers\nare used when forwarding responses.\nBy default, no headers are forwarded.",
                                "items": {
                                  "description": "HTTPHeaderMatch describes how to select a HTTP route by matching HTTP request\nheaders.",
                                  "properties": {
                                    "name": {
                                      "description": "Name of the HTTP header to match, case-insensitive. When names are equivalent, only the first matching entry is used",
                                      "maxLength": 256,
                                      "minLength": 1,
                                      "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                      "type": "string"
                                    },
                                    "type": {
                                      "default": "Exact",
                                      "description": "How to match against the header value: `Exact` (default) or `RegularExpression`. The regex dialect is implementation-specific",
                                      "enum": [
                                        "Exact",
                                        "RegularExpression"
                                      ],
                                      "type": "string"
                                    },
                                    "value": {
                                      "description": "Value of the HTTP header to match",
                                      "maxLength": 4096,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name",
                                    "value"
                                  ],
                                  "type": "object",
                                  "additionalProperties": false
                                },
                                "type": "array"
                              },
                              "headers": {
                                "additionalProperties": {
                                  "description": "A Common Expression Language (CEL) expression.",
                                  "maxLength": 16384,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "description": "CEL-computed headers to include in webhook requests.",
                                "maxProperties": 64,
                                "type": "object"
                              }
                            },
                            "required": [
                              "backendRef"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          }
                        },
                        "type": "object",
                        "x-kubernetes-validations": [
                          {
                            "message": "scope: only regex and bedrockGuardrails guards support a non-default scope; other guard kinds always inspect the default (SystemPrompt + Messages)",
                            "rule": "!has(self.scope) || has(self.regex) || has(self.bedrockGuardrails) || (self.scope.size() == 2 && 'SystemPrompt' in self.scope && 'Messages' in self.scope)"
                          },
                          {
                            "message": "exactly one of the fields in [regex webhook openAIModeration bedrockGuardrails googleModelArmor] must be set",
                            "rule": "(has(self.regex)?1:0)+(has(self.webhook)?1:0)+(has(self.openAIModeration)?1:0)+(has(self.bedrockGuardrails)?1:0)+(has(self.googleModelArmor)?1:0) == 1"
                          }
                        ],
                        "additionalProperties": false
                      },
                      "maxItems": 8,
                      "minItems": 1,
                      "type": "array"
                    },
                    "response": {
                      "description": "Prompt guards to apply to responses returned by the LLM provider.",
                      "items": {
                        "description": "Prompt guards to apply to responses returned by the LLM provider.",
                        "properties": {
                          "bedrockGuardrails": {
                            "description": "AWS Bedrock Guardrails settings for prompt\nguarding.",
                            "properties": {
                              "action": {
                                "description": "Action controls whether the guardrail's verdict is enforced or only\nobserved. `Reject` (the default) enforces the guardrail: a blocked\nassessment rejects the request/response and an anonymized assessment masks\nthe matched content. `Audit` runs the guardrail in observe mode: it is\ninvoked and its assessment recorded (metrics + structured log), but the\nrequest/response is never blocked or masked.",
                                "enum": [
                                  "Audit",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "failureMode": {
                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                "enum": [
                                  "FailClosed",
                                  "FailOpen"
                                ],
                                "type": "string"
                              },
                              "identifier": {
                                "description": "Identifier of the Guardrail policy to use for the backend.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              },
                              "policies": {
                                "description": "Policies for communicating with AWS Bedrock Guardrails.",
                                "properties": {
                                  "auth": {
                                    "description": "Settings for authenticating to AWS Bedrock Guardrails.",
                                    "properties": {
                                      "aws": {
                                        "description": "AWS authentication method for Bedrock Guardrails. Use `aws: {}` for\ndefault AWS SDK credential discovery.",
                                        "properties": {
                                          "assumeRole": {
                                            "description": "AWS STS AssumeRole settings to use before signing backend requests.\nAmbient AWS credentials are used as the source credentials for STS.",
                                            "properties": {
                                              "externalId": {
                                                "description": "ExternalID is set when the role's trust policy requires sts:ExternalId.",
                                                "maxLength": 1224,
                                                "minLength": 2,
                                                "pattern": "^[\\w+=,.@:/-]+$",
                                                "type": "string"
                                              },
                                              "roleArn": {
                                                "description": "AWS IAM role ARN to assume.",
                                                "minLength": 1,
                                                "pattern": "^arn:aws[a-z-]*:iam::[0-9]{12}:role/.+$",
                                                "type": "string"
                                              },
                                              "sessionName": {
                                                "description": "SessionName is a custom session name (RoleSessionName) for CloudTrail and\nCost & Usage Report attribution. If unset, AWS generates a random name.",
                                                "pattern": "^[\\w+=,.@-]{2,64}$",
                                                "type": "string"
                                              },
                                              "sessionNameExpression": {
                                                "description": "SessionNameExpression is a CEL expression evaluated against each request\nto produce the session name (RoleSessionName), for example `jwt.sub` or\n`request.headers[\"x-team\"]`. If the expression does not produce a valid\nsession name at request time, the request is rejected.",
                                                "maxLength": 16384,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "tags": {
                                                "description": "Session tags passed to STS AssumeRole for cost attribution in the AWS Cost\n& Usage Report, once activated. STS allows at most 50 per role session.",
                                                "items": {
                                                  "description": "AwsSessionTag is an AWS STS session tag passed to AssumeRole for cost\nattribution. Exactly one of value and expression must be set.",
                                                  "properties": {
                                                    "expression": {
                                                      "description": "CEL expression evaluated against each request to produce the tag value,\nfor example `jwt.sub` or `request.headers[\"x-app\"]`. Requests with invalid\ntag values are rejected.",
                                                      "maxLength": 16384,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    },
                                                    "key": {
                                                      "description": "Key is the tag key.",
                                                      "maxLength": 128,
                                                      "minLength": 1,
                                                      "type": "string"
                                                    },
                                                    "value": {
                                                      "description": "Value is a static tag value.",
                                                      "maxLength": 256,
                                                      "type": "string"
                                                    }
                                                  },
                                                  "required": [
                                                    "key"
                                                  ],
                                                  "type": "object",
                                                  "x-kubernetes-validations": [
                                                    {
                                                      "message": "exactly one of value or expression must be set",
                                                      "rule": "has(self.value) != has(self.expression)"
                                                    }
                                                  ],
                                                  "additionalProperties": false
                                                },
                                                "maxItems": 50,
                                                "type": "array",
                                                "x-kubernetes-list-map-keys": [
                                                  "key"
                                                ],
                                                "x-kubernetes-list-type": "map"
                                              }
                                            },
                                            "required": [
                                              "roleArn"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "at most one of the fields in [sessionName sessionNameExpression] may be set",
                                                "rule": "(has(self.sessionName)?1:0)+(has(self.sessionNameExpression)?1:0) <= 1"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "region": {
                                            "description": "AWS SigV4 signing region, for example `us-east-1`. Set this when the\ntarget AWS service is in a different region than the gateway. If unset,\ntyped AWS backends may provide this automatically; otherwise the ambient\nAWS region is used.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "secretRef": {
                                            "description": "Credential source for AWS credentials, defaulting to a Kubernetes `Secret`.\nThe default Secret resolver expects `accessKey`, `secretKey`, and optional\n`sessionToken` keys.",
                                            "properties": {
                                              "group": {
                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                "type": "string"
                                              },
                                              "kind": {
                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                "type": "string"
                                              },
                                              "name": {
                                                "description": "Name of the referenced credential",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-map-type": "atomic",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "custom credential refs must set both group and kind",
                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "serviceName": {
                                            "description": "AWS SigV4 signing service name, for example\n`bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS\nbackends may provide this automatically.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "secretRef and assumeRole are mutually exclusive",
                                            "rule": "!(has(self.secretRef) && has(self.assumeRole))"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "key": {
                                        "description": "Inline API key to use as the value of the `Authorization` header.\nThis option is the least secure; usage of a `Secret` is preferred.",
                                        "maxLength": 2048,
                                        "type": "string"
                                      },
                                      "location": {
                                        "description": "Where API keys are inserted. Defaults to the `Authorization` header with\nthe `Bearer ` prefix. Applies to `key` and `secretRef`.",
                                        "properties": {
                                          "cookie": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "header": {
                                            "properties": {
                                              "name": {
                                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                                "type": "string"
                                              },
                                              "prefix": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          },
                                          "queryParameter": {
                                            "properties": {
                                              "name": {
                                                "maxLength": 256,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "additionalProperties": false
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "secretRef": {
                                        "description": "Credential source for the API key, defaulting to a Kubernetes `Secret`.\nBy default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                                        "properties": {
                                          "group": {
                                            "description": "API group of the referenced credential; empty selects the core API group",
                                            "type": "string"
                                          },
                                          "key": {
                                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "kind": {
                                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name of the referenced credential",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-map-type": "atomic",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "custom credential refs must set both group and kind",
                                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                          }
                                        ],
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "location may only be set for key or secretRef auth",
                                        "rule": "has(self.location) ? has(self.key) || has(self.secretRef) : true"
                                      },
                                      {
                                        "message": "exactly one of the fields in [key secretRef aws] must be set",
                                        "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0)+(has(self.aws)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "http": {
                                    "description": "Settings for managing HTTP requests to the backend",
                                    "properties": {
                                      "requestTimeout": {
                                        "description": "Deadline for receiving a response from the backend.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "requestTimeout must be at least 1ms",
                                            "rule": "duration(self) >= duration('1ms')"
                                          }
                                        ]
                                      },
                                      "version": {
                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                        "enum": [
                                          "HTTP1",
                                          "HTTP2"
                                        ],
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tcp": {
                                    "description": "Settings for managing TCP connections to the backend",
                                    "properties": {
                                      "connectTimeout": {
                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "connectTimeout must be at least 100ms",
                                            "rule": "duration(self) >= duration('100ms')"
                                          }
                                        ]
                                      },
                                      "keepalive": {
                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                        "properties": {
                                          "interval": {
                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "interval must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          },
                                          "retries": {
                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                            "format": "int32",
                                            "maximum": 64,
                                            "minimum": 1,
                                            "type": "integer"
                                          },
                                          "time": {
                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "time must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tls": {
                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                    "properties": {
                                      "alpnProtocols": {
                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                        "items": {
                                          "maxLength": 64,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      },
                                      "caCertificateRefs": {
                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                        "items": {
                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                          "properties": {
                                            "key": {
                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                              "enum": [
                                                "ConfigMap",
                                                "Secret"
                                              ],
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced CA certificate source.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "certificateSource": {
                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                        "enum": [
                                          "Inline",
                                          "SPIFFE"
                                        ],
                                        "type": "string"
                                      },
                                      "insecureSkipVerify": {
                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                        "enum": [
                                          "All",
                                          "Hostname"
                                        ],
                                        "type": "string"
                                      },
                                      "keyExchangeGroups": {
                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                        "items": {
                                          "enum": [
                                            "P-256",
                                            "P-384",
                                            "X25519",
                                            "X25519_MLKEM768"
                                          ],
                                          "type": "string"
                                        },
                                        "type": "array"
                                      },
                                      "mtlsCertificateRef": {
                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                        "items": {
                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                          "properties": {
                                            "group": {
                                              "description": "API group of the referenced credential; empty selects the core API group",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced credential",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "custom credential refs must set both group and kind",
                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "sni": {
                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                        "type": "string"
                                      },
                                      "verifySubjectAltNames": {
                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                        "items": {
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                      },
                                      {
                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                      },
                                      {
                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                      },
                                      {
                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "tunnel": {
                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                    "properties": {
                                      "backendRef": {
                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                        "properties": {
                                          "group": {
                                            "default": "",
                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                            "maxLength": 253,
                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                            "type": "string"
                                          },
                                          "kind": {
                                            "default": "Service",
                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name is the name of the referent.",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "namespace": {
                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "port": {
                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                            "format": "int32",
                                            "maximum": 65535,
                                            "minimum": 1,
                                            "type": "integer"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "Must have port for Service reference",
                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "mode": {
                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                        "enum": [
                                          "Auto",
                                          "Connect"
                                        ],
                                        "type": "string"
                                      },
                                      "url": {
                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                        "maxLength": 1024,
                                        "minLength": 1,
                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                      },
                                      {
                                        "message": "url must not include a path for backend tunnel",
                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                      }
                                    ],
                                    "additionalProperties": false
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "region": {
                                "description": "AWS region where the guardrail is deployed, for example\n`us-west-2`).",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              },
                              "version": {
                                "description": "Version of the Guardrail policy to use for the backend.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              }
                            },
                            "required": [
                              "identifier",
                              "region",
                              "version"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          },
                          "googleModelArmor": {
                            "description": "Google Model Armor settings for prompt guarding.",
                            "properties": {
                              "action": {
                                "description": "Action controls whether flagged content is rejected or only observed.\n`Reject` (the default) rejects flagged content; `Audit` records the\nwould-be rejection without blocking.",
                                "enum": [
                                  "Audit",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "failureMode": {
                                "description": "Behavior when the provider is unavailable or returns an error.\n`FailOpen` allows the request to continue; `FailClosed` (default) rejects it.",
                                "enum": [
                                  "FailClosed",
                                  "FailOpen"
                                ],
                                "type": "string"
                              },
                              "location": {
                                "description": "Google Cloud location, for example `us-central1`.\nDefaults to `us-central1` if not specified.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              },
                              "policies": {
                                "description": "Policies for communicating with Google Model Armor.",
                                "properties": {
                                  "auth": {
                                    "description": "Settings for authenticating to Google Model Armor.",
                                    "properties": {
                                      "gcp": {
                                        "description": "Google authentication method for Model Armor. Use `gcp: {}` for default\nGoogle credential discovery.",
                                        "properties": {
                                          "audience": {
                                            "description": "Explicit `aud` value for the ID token. Only\nvalid with `IdToken` type. If not set, the `aud` is automatically\nderived from the backend hostname.",
                                            "maxLength": 256,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "secretRef": {
                                            "description": "Credential source for ADC-compatible Google credential JSON, defaulting to\na Kubernetes `Secret`. By default, the value is read from\n`credentials.json`; set `secretRef.key` to override it. When omitted,\nambient credentials are used.",
                                            "properties": {
                                              "group": {
                                                "description": "API group of the referenced credential; empty selects the core API group",
                                                "type": "string"
                                              },
                                              "key": {
                                                "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              },
                                              "kind": {
                                                "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                                "type": "string"
                                              },
                                              "name": {
                                                "description": "Name of the referenced credential",
                                                "maxLength": 253,
                                                "minLength": 1,
                                                "type": "string"
                                              }
                                            },
                                            "required": [
                                              "name"
                                            ],
                                            "type": "object",
                                            "x-kubernetes-map-type": "atomic",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "custom credential refs must set both group and kind",
                                                "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                              }
                                            ],
                                            "additionalProperties": false
                                          },
                                          "type": {
                                            "description": "The type of token to generate. To authenticate to GCP services,\ngenerally an `AccessToken` is used. To authenticate to Cloud Run, an\n`IdToken` is used.",
                                            "enum": [
                                              "AccessToken",
                                              "IdToken"
                                            ],
                                            "type": "string"
                                          }
                                        },
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "audience is only valid with IdToken",
                                            "rule": "has(self.audience) ? self.type == 'IdToken' : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [gcp] must be set",
                                        "rule": "(has(self.gcp)?1:0) == 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "http": {
                                    "description": "Settings for managing HTTP requests to the backend",
                                    "properties": {
                                      "requestTimeout": {
                                        "description": "Deadline for receiving a response from the backend.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "requestTimeout must be at least 1ms",
                                            "rule": "duration(self) >= duration('1ms')"
                                          }
                                        ]
                                      },
                                      "version": {
                                        "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                                        "enum": [
                                          "HTTP1",
                                          "HTTP2"
                                        ],
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tcp": {
                                    "description": "Settings for managing TCP connections to the backend",
                                    "properties": {
                                      "connectTimeout": {
                                        "description": "Deadline for establishing a connection to\nthe destination.",
                                        "maxLength": 32,
                                        "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                        "type": "string",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "connectTimeout must be at least 100ms",
                                            "rule": "duration(self) >= duration('100ms')"
                                          }
                                        ]
                                      },
                                      "keepalive": {
                                        "description": "Settings for enabling TCP keepalives on the\nconnection.",
                                        "properties": {
                                          "interval": {
                                            "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "interval must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          },
                                          "retries": {
                                            "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                                            "format": "int32",
                                            "maximum": 64,
                                            "minimum": 1,
                                            "type": "integer"
                                          },
                                          "time": {
                                            "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                                            "maxLength": 32,
                                            "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                                            "type": "string",
                                            "x-kubernetes-validations": [
                                              {
                                                "message": "time must be at least 1 second",
                                                "rule": "duration(self) >= duration('1s')"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object",
                                        "additionalProperties": false
                                      }
                                    },
                                    "type": "object",
                                    "additionalProperties": false
                                  },
                                  "tls": {
                                    "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
                                    "properties": {
                                      "alpnProtocols": {
                                        "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                                        "items": {
                                          "maxLength": 64,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      },
                                      "caCertificateRefs": {
                                        "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                                        "items": {
                                          "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                                          "properties": {
                                            "key": {
                                              "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                                              "enum": [
                                                "ConfigMap",
                                                "Secret"
                                              ],
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced CA certificate source.",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "certificateSource": {
                                        "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                                        "enum": [
                                          "Inline",
                                          "SPIFFE"
                                        ],
                                        "type": "string"
                                      },
                                      "insecureSkipVerify": {
                                        "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                                        "enum": [
                                          "All",
                                          "Hostname"
                                        ],
                                        "type": "string"
                                      },
                                      "keyExchangeGroups": {
                                        "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                                        "items": {
                                          "enum": [
                                            "P-256",
                                            "P-384",
                                            "X25519",
                                            "X25519_MLKEM768"
                                          ],
                                          "type": "string"
                                        },
                                        "type": "array"
                                      },
                                      "mtlsCertificateRef": {
                                        "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                                        "items": {
                                          "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                                          "properties": {
                                            "group": {
                                              "description": "API group of the referenced credential; empty selects the core API group",
                                              "type": "string"
                                            },
                                            "kind": {
                                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                              "type": "string"
                                            },
                                            "name": {
                                              "description": "Name of the referenced credential",
                                              "maxLength": 253,
                                              "minLength": 1,
                                              "type": "string"
                                            }
                                          },
                                          "required": [
                                            "name"
                                          ],
                                          "type": "object",
                                          "x-kubernetes-map-type": "atomic",
                                          "x-kubernetes-validations": [
                                            {
                                              "message": "custom credential refs must set both group and kind",
                                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                            }
                                          ],
                                          "additionalProperties": false
                                        },
                                        "maxItems": 1,
                                        "type": "array",
                                        "x-kubernetes-list-type": "atomic"
                                      },
                                      "sni": {
                                        "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                                        "maxLength": 253,
                                        "minLength": 1,
                                        "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                        "type": "string"
                                      },
                                      "verifySubjectAltNames": {
                                        "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                                        "items": {
                                          "maxLength": 256,
                                          "minLength": 1,
                                          "type": "string"
                                        },
                                        "maxItems": 16,
                                        "minItems": 1,
                                        "type": "array"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                                        "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                                      },
                                      {
                                        "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                                        "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                                      },
                                      {
                                        "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                                        "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                                      },
                                      {
                                        "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                                        "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                                      }
                                    ],
                                    "additionalProperties": false
                                  },
                                  "tunnel": {
                                    "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
                                    "properties": {
                                      "backendRef": {
                                        "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                        "properties": {
                                          "group": {
                                            "default": "",
                                            "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                            "maxLength": 253,
                                            "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                            "type": "string"
                                          },
                                          "kind": {
                                            "default": "Service",
                                            "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                            "type": "string"
                                          },
                                          "name": {
                                            "description": "Name is the name of the referent.",
                                            "maxLength": 253,
                                            "minLength": 1,
                                            "type": "string"
                                          },
                                          "namespace": {
                                            "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                            "maxLength": 63,
                                            "minLength": 1,
                                            "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                            "type": "string"
                                          },
                                          "port": {
                                            "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                            "format": "int32",
                                            "maximum": 65535,
                                            "minimum": 1,
                                            "type": "integer"
                                          }
                                        },
                                        "required": [
                                          "name"
                                        ],
                                        "type": "object",
                                        "x-kubernetes-validations": [
                                          {
                                            "message": "Must have port for Service reference",
                                            "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                          }
                                        ],
                                        "additionalProperties": false
                                      },
                                      "mode": {
                                        "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                                        "enum": [
                                          "Auto",
                                          "Connect"
                                        ],
                                        "type": "string"
                                      },
                                      "url": {
                                        "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                        "maxLength": 1024,
                                        "minLength": 1,
                                        "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                        "type": "string"
                                      }
                                    },
                                    "type": "object",
                                    "x-kubernetes-validations": [
                                      {
                                        "message": "exactly one of the fields in [backendRef url] must be set",
                                        "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                                      },
                                      {
                                        "message": "url must not include a path for backend tunnel",
                                        "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                                      }
                                    ],
                                    "additionalProperties": false
                                  }
                                },
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "at least one of the fields in [auth http tcp tls tunnel] must be set",
                                    "rule": "[has(self.auth),has(self.http),has(self.tcp),has(self.tls),has(self.tunnel)].filter(x,x==true).size() >= 1"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "projectId": {
                                "description": "Google Cloud project ID.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              },
                              "templateId": {
                                "description": "Template ID for Google Model Armor.",
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              }
                            },
                            "required": [
                              "projectId",
                              "templateId"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          },
                          "regex": {
                            "description": "Regular expression (regex) matching for prompt guards and data masking.",
                            "properties": {
                              "action": {
                                "description": "The action to take if a regex pattern is matched in a request or response.\nThe action applies to request and response matches alike. Note that\n`Mask` is not applied to streamed responses: matched content in a\nstreamed response is passed through unmodified.\nDefaults to `Mask`.",
                                "enum": [
                                  "Audit",
                                  "Mask",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "builtins": {
                                "description": "Built-in regex patterns to match against the request or response.\nMatches and built-ins are additive.",
                                "items": {
                                  "description": "Built-in regex patterns for specific types of strings in prompts.\nFor example, if you specify `CreditCard`, any credit card numbers\nin the request or response are matched.",
                                  "enum": [
                                    "CaSin",
                                    "CreditCard",
                                    "Email",
                                    "PhoneNumber",
                                    "Ssn"
                                  ],
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              "matches": {
                                "description": "Regex patterns to match against the request or response.\nMatches and built-ins are additive.",
                                "items": {
                                  "maxLength": 1024,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "type": "array"
                              }
                            },
                            "type": "object",
                            "additionalProperties": false
                          },
                          "response": {
                            "description": "Custom response message to return to the client. If not specified, defaults to\n`The response was rejected due to inappropriate content`.",
                            "properties": {
                              "message": {
                                "description": "Custom response message to return to the client. If not specified, defaults to\n`The request was rejected due to inappropriate content`.",
                                "type": "string"
                              },
                              "statusCode": {
                                "description": "Status code to return to the client. Defaults to 403.",
                                "format": "int32",
                                "maximum": 599,
                                "minimum": 200,
                                "type": "integer"
                              }
                            },
                            "type": "object",
                            "additionalProperties": false
                          },
                          "webhook": {
                            "description": "Webhook that receives responses for prompt guarding.",
                            "properties": {
                              "action": {
                                "description": "Action controls whether the webhook's verdict is enforced or only observed.\n`Reject` (the default) enforces it; `Audit` records the would-be action\nwithout blocking or masking.",
                                "enum": [
                                  "Audit",
                                  "Reject"
                                ],
                                "type": "string"
                              },
                              "backendRef": {
                                "description": "Webhook server to reach.\n\nSupported types: Service and Backend.",
                                "properties": {
                                  "group": {
                                    "default": "",
                                    "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                    "maxLength": 253,
                                    "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                    "type": "string"
                                  },
                                  "kind": {
                                    "default": "Service",
                                    "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                    "type": "string"
                                  },
                                  "name": {
                                    "description": "Name is the name of the referent.",
                                    "maxLength": 253,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "namespace": {
                                    "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                    "type": "string"
                                  },
                                  "port": {
                                    "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                    "format": "int32",
                                    "maximum": 65535,
                                    "minimum": 1,
                                    "type": "integer"
                                  }
                                },
                                "required": [
                                  "name"
                                ],
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "Must have port for Service reference",
                                    "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "failureMode": {
                                "description": "Behavior when the webhook guardrail is unavailable\nor returns an error. `FailOpen` allows the request to continue.\n`FailClosed` (default) rejects the request.",
                                "enum": [
                                  "FailClosed",
                                  "FailOpen"
                                ],
                                "type": "string"
                              },
                              "forwardHeaderMatches": {
                                "description": "HTTP header matches used to select the headers to forward to the webhook.\nRequest headers are used when forwarding requests and response headers\nare used when forwarding responses.\nBy default, no headers are forwarded.",
                                "items": {
                                  "description": "HTTPHeaderMatch describes how to select a HTTP route by matching HTTP request\nheaders.",
                                  "properties": {
                                    "name": {
                                      "description": "Name of the HTTP header to match, case-insensitive. When names are equivalent, only the first matching entry is used",
                                      "maxLength": 256,
                                      "minLength": 1,
                                      "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                      "type": "string"
                                    },
                                    "type": {
                                      "default": "Exact",
                                      "description": "How to match against the header value: `Exact` (default) or `RegularExpression`. The regex dialect is implementation-specific",
                                      "enum": [
                                        "Exact",
                                        "RegularExpression"
                                      ],
                                      "type": "string"
                                    },
                                    "value": {
                                      "description": "Value of the HTTP header to match",
                                      "maxLength": 4096,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name",
                                    "value"
                                  ],
                                  "type": "object",
                                  "additionalProperties": false
                                },
                                "type": "array"
                              },
                              "headers": {
                                "additionalProperties": {
                                  "description": "A Common Expression Language (CEL) expression.",
                                  "maxLength": 16384,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "description": "CEL-computed headers to include in webhook requests.",
                                "maxProperties": 64,
                                "type": "object"
                              }
                            },
                            "required": [
                              "backendRef"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          }
                        },
                        "type": "object",
                        "x-kubernetes-validations": [
                          {
                            "message": "exactly one of the fields in [regex webhook bedrockGuardrails googleModelArmor] must be set",
                            "rule": "(has(self.regex)?1:0)+(has(self.webhook)?1:0)+(has(self.bedrockGuardrails)?1:0)+(has(self.googleModelArmor)?1:0) == 1"
                          }
                        ],
                        "additionalProperties": false
                      },
                      "maxItems": 8,
                      "minItems": 1,
                      "type": "array"
                    },
                    "streaming": {
                      "description": "Apply prompt guards to streaming responses and realtime websocket messages.\nDefaults to disabled to preserve streaming throughput unless explicitly enabled.",
                      "enum": [
                        "Enabled"
                      ],
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "at least one of the fields in [request response] must be set",
                      "rule": "[has(self.request),has(self.response)].filter(x,x==true).size() >= 1"
                    }
                  ],
                  "additionalProperties": false
                },
                "routes": {
                  "additionalProperties": {
                    "description": "How the AI gateway should process incoming requests\nbased on the URL path and the API format expected.",
                    "enum": [
                      "AnthropicTokenCount",
                      "Completions",
                      "Detect",
                      "Embeddings",
                      "GeminiCountTokens",
                      "GenerateContent",
                      "Messages",
                      "Models",
                      "Passthrough",
                      "Realtime",
                      "Rerank",
                      "Responses"
                    ],
                    "type": "string"
                  },
                  "description": "Rules for identifying the type of traffic to handle.\nThe keys are URL path suffixes matched using ends-with comparison, for\nexample `\"/v1/chat/completions\"`.\nThe special `*` wildcard matches any path.\nIf not specified, all traffic defaults to `completions` type.",
                  "type": "object"
                },
                "transformations": {
                  "description": "CEL transformations to compute and set fields in the request body.\nThe expression result overwrites any existing value for that field.\nThis has a higher priority than `overrides` if both are set for the same\nkey.",
                  "items": {
                    "description": "Maps a request JSON field to a CEL expression.\nThe expression is evaluated against the current request body and its result\nis assigned to the configured field.",
                    "properties": {
                      "expression": {
                        "description": "CEL expression used to compute the field value.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "field": {
                        "description": "Name of the field to set.",
                        "maxLength": 256,
                        "minLength": 1,
                        "type": "string"
                      }
                    },
                    "required": [
                      "expression",
                      "field"
                    ],
                    "type": "object",
                    "additionalProperties": false
                  },
                  "maxItems": 64,
                  "minItems": 1,
                  "type": "array",
                  "x-kubernetes-list-map-keys": [
                    "field"
                  ],
                  "x-kubernetes-list-type": "map"
                }
              },
              "type": "object",
              "x-kubernetes-validations": [
                {
                  "message": "at least one of the fields in [defaults finalTransformations modelAliases overrides prompt promptCaching promptGuard routes transformations] must be set",
                  "rule": "[has(self.defaults),has(self.finalTransformations),has(self.modelAliases),has(self.overrides),has(self.prompt),has(self.promptCaching),has(self.promptGuard),has(self.routes),has(self.transformations)].filter(x,x==true).size() >= 1"
                }
              ],
              "additionalProperties": false
            },
            "auth": {
              "description": "Settings for managing authentication to the backend",
              "properties": {
                "aws": {
                  "description": "Explicit AWS authentication method for the backend.\nWhen omitted, default AWS SDK credential discovery is used.",
                  "properties": {
                    "assumeRole": {
                      "description": "AWS STS AssumeRole settings to use before signing backend requests.\nAmbient AWS credentials are used as the source credentials for STS.",
                      "properties": {
                        "externalId": {
                          "description": "ExternalID is set when the role's trust policy requires sts:ExternalId.",
                          "maxLength": 1224,
                          "minLength": 2,
                          "pattern": "^[\\w+=,.@:/-]+$",
                          "type": "string"
                        },
                        "roleArn": {
                          "description": "AWS IAM role ARN to assume.",
                          "minLength": 1,
                          "pattern": "^arn:aws[a-z-]*:iam::[0-9]{12}:role/.+$",
                          "type": "string"
                        },
                        "sessionName": {
                          "description": "SessionName is a custom session name (RoleSessionName) for CloudTrail and\nCost & Usage Report attribution. If unset, AWS generates a random name.",
                          "pattern": "^[\\w+=,.@-]{2,64}$",
                          "type": "string"
                        },
                        "sessionNameExpression": {
                          "description": "SessionNameExpression is a CEL expression evaluated against each request\nto produce the session name (RoleSessionName), for example `jwt.sub` or\n`request.headers[\"x-team\"]`. If the expression does not produce a valid\nsession name at request time, the request is rejected.",
                          "maxLength": 16384,
                          "minLength": 1,
                          "type": "string"
                        },
                        "tags": {
                          "description": "Session tags passed to STS AssumeRole for cost attribution in the AWS Cost\n& Usage Report, once activated. STS allows at most 50 per role session.",
                          "items": {
                            "description": "AwsSessionTag is an AWS STS session tag passed to AssumeRole for cost\nattribution. Exactly one of value and expression must be set.",
                            "properties": {
                              "expression": {
                                "description": "CEL expression evaluated against each request to produce the tag value,\nfor example `jwt.sub` or `request.headers[\"x-app\"]`. Requests with invalid\ntag values are rejected.",
                                "maxLength": 16384,
                                "minLength": 1,
                                "type": "string"
                              },
                              "key": {
                                "description": "Key is the tag key.",
                                "maxLength": 128,
                                "minLength": 1,
                                "type": "string"
                              },
                              "value": {
                                "description": "Value is a static tag value.",
                                "maxLength": 256,
                                "type": "string"
                              }
                            },
                            "required": [
                              "key"
                            ],
                            "type": "object",
                            "x-kubernetes-validations": [
                              {
                                "message": "exactly one of value or expression must be set",
                                "rule": "has(self.value) != has(self.expression)"
                              }
                            ],
                            "additionalProperties": false
                          },
                          "maxItems": 50,
                          "type": "array",
                          "x-kubernetes-list-map-keys": [
                            "key"
                          ],
                          "x-kubernetes-list-type": "map"
                        }
                      },
                      "required": [
                        "roleArn"
                      ],
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "at most one of the fields in [sessionName sessionNameExpression] may be set",
                          "rule": "(has(self.sessionName)?1:0)+(has(self.sessionNameExpression)?1:0) <= 1"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "region": {
                      "description": "AWS SigV4 signing region, for example `us-east-1`. Set this when the\ntarget AWS service is in a different region than the gateway. If unset,\ntyped AWS backends may provide this automatically; otherwise the ambient\nAWS region is used.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "secretRef": {
                      "description": "Credential source for AWS credentials, defaulting to a Kubernetes `Secret`.\nThe default Secret resolver expects `accessKey`, `secretKey`, and optional\n`sessionToken` keys.",
                      "properties": {
                        "group": {
                          "description": "API group of the referenced credential; empty selects the core API group",
                          "type": "string"
                        },
                        "kind": {
                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                          "type": "string"
                        },
                        "name": {
                          "description": "Name of the referenced credential",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "x-kubernetes-map-type": "atomic",
                      "x-kubernetes-validations": [
                        {
                          "message": "custom credential refs must set both group and kind",
                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "serviceName": {
                      "description": "AWS SigV4 signing service name, for example\n`bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS\nbackends may provide this automatically.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "secretRef and assumeRole are mutually exclusive",
                      "rule": "!(has(self.secretRef) && has(self.assumeRole))"
                    }
                  ],
                  "additionalProperties": false
                },
                "azure": {
                  "description": "Azure authentication method for the backend.",
                  "properties": {
                    "managedIdentity": {
                      "description": "Managed identity authentication settings. Leave this object empty to use\nthe system-assigned identity. To use a user-assigned identity, set one of\n`clientId`, `objectId`, or `resourceId`.",
                      "properties": {
                        "clientId": {
                          "description": "Client ID of the user-assigned managed identity.",
                          "type": "string"
                        },
                        "objectId": {
                          "description": "Object ID of the user-assigned managed identity.",
                          "type": "string"
                        },
                        "resourceId": {
                          "description": "Resource ID of the user-assigned managed identity.",
                          "type": "string"
                        }
                      },
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "at most one of the fields in [clientId objectId resourceId] may be set",
                          "rule": "(has(self.clientId)?1:0)+(has(self.objectId)?1:0)+(has(self.resourceId)?1:0) <= 1"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "scopes": {
                      "description": "Scopes requested for the Azure access token. When omitted, the scope is\ninferred from the backend hostname. Managed Identity supports exactly one\nscope.",
                      "items": {
                        "type": "string"
                      },
                      "maxItems": 64,
                      "minItems": 1,
                      "type": "array"
                    },
                    "secretRef": {
                      "description": "Credential source for Azure credentials, defaulting to a Kubernetes\n`Secret`. The default Secret resolver expects `clientID`, `tenantID`, and\n`clientSecret` keys.",
                      "properties": {
                        "group": {
                          "description": "API group of the referenced credential; empty selects the core API group",
                          "type": "string"
                        },
                        "kind": {
                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                          "type": "string"
                        },
                        "name": {
                          "description": "Name of the referenced credential",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "x-kubernetes-map-type": "atomic",
                      "x-kubernetes-validations": [
                        {
                          "message": "custom credential refs must set both group and kind",
                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "workloadIdentity": {
                      "description": "Workload identity authentication settings. Uses the federated token and\nAzure env vars projected into the data plane pod. Recommended on AKS with\nWorkload Identity enabled.",
                      "type": "object"
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "managedIdentity supports exactly one scope",
                      "rule": "!has(self.managedIdentity) || !has(self.scopes) || self.scopes.size() == 1"
                    },
                    {
                      "message": "at most one of the fields in [secretRef managedIdentity workloadIdentity] may be set",
                      "rule": "(has(self.secretRef)?1:0)+(has(self.managedIdentity)?1:0)+(has(self.workloadIdentity)?1:0) <= 1"
                    }
                  ],
                  "additionalProperties": false
                },
                "credentials": {
                  "description": "Credentials is a list of additional credentials to inject on the\nbackend request. Each entry resolves a Secret key and writes its value\nto the entry's location. `credentials` is independent of the primary\n`key`/`secretRef`/`passthrough` mechanism and may be set on its own or\nalongside it.",
                  "items": {
                    "description": "BackendAuthCredential specifies one additional credential to inject on the\nbackend request.",
                    "properties": {
                      "location": {
                        "description": "Where the credential is inserted on the backend request.",
                        "properties": {
                          "cookie": {
                            "properties": {
                              "name": {
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              }
                            },
                            "required": [
                              "name"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          },
                          "header": {
                            "properties": {
                              "name": {
                                "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                "maxLength": 256,
                                "minLength": 1,
                                "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                "type": "string"
                              },
                              "prefix": {
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              }
                            },
                            "required": [
                              "name"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          },
                          "queryParameter": {
                            "properties": {
                              "name": {
                                "maxLength": 256,
                                "minLength": 1,
                                "type": "string"
                              }
                            },
                            "required": [
                              "name"
                            ],
                            "type": "object",
                            "additionalProperties": false
                          }
                        },
                        "type": "object",
                        "x-kubernetes-validations": [
                          {
                            "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                            "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                          }
                        ],
                        "additionalProperties": false
                      },
                      "secretRef": {
                        "description": "SecretRef references a Kubernetes Secret holding the credential value, and\noptionally overrides the key read from it. Defaults to `Authorization`,\nmatching the key convention used by the top-level `secretRef`.",
                        "properties": {
                          "group": {
                            "description": "API group of the referenced credential; empty selects the core API group",
                            "type": "string"
                          },
                          "key": {
                            "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                            "maxLength": 253,
                            "minLength": 1,
                            "type": "string"
                          },
                          "kind": {
                            "description": "Kind of the referenced credential; empty defaults to `Secret`",
                            "type": "string"
                          },
                          "name": {
                            "description": "Name of the referenced credential",
                            "maxLength": 253,
                            "minLength": 1,
                            "type": "string"
                          }
                        },
                        "required": [
                          "name"
                        ],
                        "type": "object",
                        "x-kubernetes-map-type": "atomic",
                        "x-kubernetes-validations": [
                          {
                            "message": "custom credential refs must set both group and kind",
                            "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                          }
                        ],
                        "additionalProperties": false
                      }
                    },
                    "required": [
                      "location",
                      "secretRef"
                    ],
                    "type": "object",
                    "additionalProperties": false
                  },
                  "maxItems": 8,
                  "minItems": 1,
                  "type": "array",
                  "x-kubernetes-list-type": "atomic"
                },
                "crossAppAccess": {
                  "description": "Cross App Access (Identity Assertion / ID-JAG) authentication.",
                  "properties": {
                    "accessTokenScopes": {
                      "description": "Scopes requested when exchanging the ID-JAG for an access token.\nWhen omitted, defaults to Scopes. Set to an empty list to omit scope.",
                      "items": {
                        "type": "string"
                      },
                      "maxItems": 64,
                      "type": "array"
                    },
                    "audience": {
                      "description": "Identifier of the resource authorization server. The issued ID-JAG is bound to this audience.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "cache": {
                      "description": "Response cache configuration.",
                      "properties": {
                        "inMemory": {
                          "properties": {
                            "defaultTtl": {
                              "description": "TTL used when the token endpoint omits expires_in. Default 300s.",
                              "maxLength": 32,
                              "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                              "type": "string",
                              "x-kubernetes-validations": [
                                {
                                  "message": "defaultTtl must be at least 1 second",
                                  "rule": "duration(self) >= duration('1s')"
                                }
                              ]
                            },
                            "maxEntries": {
                              "description": "Default 8192; 0 disables the cache.",
                              "format": "int32",
                              "type": "integer"
                            }
                          },
                          "type": "object",
                          "additionalProperties": false
                        }
                      },
                      "type": "object",
                      "additionalProperties": false
                    },
                    "identityProvider": {
                      "description": "User identity provider authorization server, used for the RFC 8693 ID-JAG exchange.",
                      "properties": {
                        "backendRef": {
                          "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                          "properties": {
                            "group": {
                              "default": "",
                              "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                              "maxLength": 253,
                              "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                              "type": "string"
                            },
                            "kind": {
                              "default": "Service",
                              "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                              "type": "string"
                            },
                            "name": {
                              "description": "Name is the name of the referent.",
                              "maxLength": 253,
                              "minLength": 1,
                              "type": "string"
                            },
                            "namespace": {
                              "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                              "type": "string"
                            },
                            "port": {
                              "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                              "format": "int32",
                              "maximum": 65535,
                              "minimum": 1,
                              "type": "integer"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "Must have port for Service reference",
                              "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "clientAuth": {
                          "description": "Client authentication for the token endpoint.",
                          "properties": {
                            "clientId": {
                              "description": "Client ID sent to the token endpoint.",
                              "minLength": 1,
                              "type": "string"
                            },
                            "method": {
                              "description": "Client authentication method. Defaults to ClientSecretBasic.",
                              "enum": [
                                "ClientSecretBasic",
                                "ClientSecretPost",
                                "PrivateKeyJwt"
                              ],
                              "type": "string"
                            },
                            "privateKeyJwt": {
                              "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                              "properties": {
                                "alg": {
                                  "description": "JWS signing algorithm. Defaults to RS256.",
                                  "enum": [
                                    "ES256",
                                    "ES384",
                                    "PS256",
                                    "RS256",
                                    "RS384",
                                    "RS512"
                                  ],
                                  "type": "string"
                                },
                                "assertionAudience": {
                                  "description": "Audience for the client assertion, typically the token endpoint URL.",
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "certificateHeader": {
                                  "description": "JWS certificate header. Required when certificateRef is set.",
                                  "enum": [
                                    "x5c",
                                    "x5t#S256"
                                  ],
                                  "type": "string"
                                },
                                "certificateRef": {
                                  "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                                  "properties": {
                                    "group": {
                                      "description": "API group of the referenced credential; empty selects the core API group",
                                      "type": "string"
                                    },
                                    "key": {
                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "kind": {
                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                      "type": "string"
                                    },
                                    "name": {
                                      "description": "Name of the referenced credential",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name"
                                  ],
                                  "type": "object",
                                  "x-kubernetes-map-type": "atomic",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "custom credential refs must set both group and kind",
                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "kid": {
                                  "description": "Optional JWS key ID header.",
                                  "type": "string"
                                },
                                "signingKeyRef": {
                                  "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                                  "properties": {
                                    "group": {
                                      "description": "API group of the referenced credential; empty selects the core API group",
                                      "type": "string"
                                    },
                                    "key": {
                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "kind": {
                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                      "type": "string"
                                    },
                                    "name": {
                                      "description": "Name of the referenced credential",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name"
                                  ],
                                  "type": "object",
                                  "x-kubernetes-map-type": "atomic",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "custom credential refs must set both group and kind",
                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                    }
                                  ],
                                  "additionalProperties": false
                                }
                              },
                              "required": [
                                "assertionAudience",
                                "signingKeyRef"
                              ],
                              "type": "object",
                              "x-kubernetes-validations": [
                                {
                                  "message": "certificateRef and certificateHeader must be set together",
                                  "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                                }
                              ],
                              "additionalProperties": false
                            },
                            "secretRef": {
                              "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                              "properties": {
                                "group": {
                                  "description": "API group of the referenced credential; empty selects the core API group",
                                  "type": "string"
                                },
                                "key": {
                                  "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "kind": {
                                  "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                  "type": "string"
                                },
                                "name": {
                                  "description": "Name of the referenced credential",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "x-kubernetes-map-type": "atomic",
                              "x-kubernetes-validations": [
                                {
                                  "message": "custom credential refs must set both group and kind",
                                  "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                }
                              ],
                              "additionalProperties": false
                            }
                          },
                          "required": [
                            "clientId"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "privateKeyJwt settings require method PrivateKeyJwt",
                              "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                            },
                            {
                              "message": "secretRef is not valid with method PrivateKeyJwt",
                              "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                            },
                            {
                              "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                              "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "path": {
                          "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                          "pattern": "^/",
                          "type": "string"
                        },
                        "url": {
                          "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                          "maxLength": 1024,
                          "minLength": 1,
                          "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                          "type": "string"
                        }
                      },
                      "required": [
                        "clientAuth"
                      ],
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "path may not be set when url is set",
                          "rule": "has(self.url) ? !has(self.path) : true"
                        },
                        {
                          "message": "exactly one of the fields in [backendRef url] must be set",
                          "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "resourceAuthorizationServer": {
                      "description": "Resource authorization server, used for the RFC 7523 jwt-bearer exchange.",
                      "properties": {
                        "backendRef": {
                          "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                          "properties": {
                            "group": {
                              "default": "",
                              "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                              "maxLength": 253,
                              "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                              "type": "string"
                            },
                            "kind": {
                              "default": "Service",
                              "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                              "type": "string"
                            },
                            "name": {
                              "description": "Name is the name of the referent.",
                              "maxLength": 253,
                              "minLength": 1,
                              "type": "string"
                            },
                            "namespace": {
                              "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                              "type": "string"
                            },
                            "port": {
                              "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                              "format": "int32",
                              "maximum": 65535,
                              "minimum": 1,
                              "type": "integer"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "Must have port for Service reference",
                              "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "clientAuth": {
                          "description": "Client authentication for the token endpoint.",
                          "properties": {
                            "clientId": {
                              "description": "Client ID sent to the token endpoint.",
                              "minLength": 1,
                              "type": "string"
                            },
                            "method": {
                              "description": "Client authentication method. Defaults to ClientSecretBasic.",
                              "enum": [
                                "ClientSecretBasic",
                                "ClientSecretPost",
                                "PrivateKeyJwt"
                              ],
                              "type": "string"
                            },
                            "privateKeyJwt": {
                              "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                              "properties": {
                                "alg": {
                                  "description": "JWS signing algorithm. Defaults to RS256.",
                                  "enum": [
                                    "ES256",
                                    "ES384",
                                    "PS256",
                                    "RS256",
                                    "RS384",
                                    "RS512"
                                  ],
                                  "type": "string"
                                },
                                "assertionAudience": {
                                  "description": "Audience for the client assertion, typically the token endpoint URL.",
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "certificateHeader": {
                                  "description": "JWS certificate header. Required when certificateRef is set.",
                                  "enum": [
                                    "x5c",
                                    "x5t#S256"
                                  ],
                                  "type": "string"
                                },
                                "certificateRef": {
                                  "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                                  "properties": {
                                    "group": {
                                      "description": "API group of the referenced credential; empty selects the core API group",
                                      "type": "string"
                                    },
                                    "key": {
                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "kind": {
                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                      "type": "string"
                                    },
                                    "name": {
                                      "description": "Name of the referenced credential",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name"
                                  ],
                                  "type": "object",
                                  "x-kubernetes-map-type": "atomic",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "custom credential refs must set both group and kind",
                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                    }
                                  ],
                                  "additionalProperties": false
                                },
                                "kid": {
                                  "description": "Optional JWS key ID header.",
                                  "type": "string"
                                },
                                "signingKeyRef": {
                                  "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                                  "properties": {
                                    "group": {
                                      "description": "API group of the referenced credential; empty selects the core API group",
                                      "type": "string"
                                    },
                                    "key": {
                                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    },
                                    "kind": {
                                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                      "type": "string"
                                    },
                                    "name": {
                                      "description": "Name of the referenced credential",
                                      "maxLength": 253,
                                      "minLength": 1,
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "name"
                                  ],
                                  "type": "object",
                                  "x-kubernetes-map-type": "atomic",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "custom credential refs must set both group and kind",
                                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                    }
                                  ],
                                  "additionalProperties": false
                                }
                              },
                              "required": [
                                "assertionAudience",
                                "signingKeyRef"
                              ],
                              "type": "object",
                              "x-kubernetes-validations": [
                                {
                                  "message": "certificateRef and certificateHeader must be set together",
                                  "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                                }
                              ],
                              "additionalProperties": false
                            },
                            "secretRef": {
                              "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                              "properties": {
                                "group": {
                                  "description": "API group of the referenced credential; empty selects the core API group",
                                  "type": "string"
                                },
                                "key": {
                                  "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "kind": {
                                  "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                  "type": "string"
                                },
                                "name": {
                                  "description": "Name of the referenced credential",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "x-kubernetes-map-type": "atomic",
                              "x-kubernetes-validations": [
                                {
                                  "message": "custom credential refs must set both group and kind",
                                  "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                }
                              ],
                              "additionalProperties": false
                            }
                          },
                          "required": [
                            "clientId"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "privateKeyJwt settings require method PrivateKeyJwt",
                              "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                            },
                            {
                              "message": "secretRef is not valid with method PrivateKeyJwt",
                              "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                            },
                            {
                              "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                              "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "path": {
                          "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                          "pattern": "^/",
                          "type": "string"
                        },
                        "url": {
                          "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                          "maxLength": 1024,
                          "minLength": 1,
                          "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                          "type": "string"
                        }
                      },
                      "required": [
                        "clientAuth"
                      ],
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "path may not be set when url is set",
                          "rule": "has(self.url) ? !has(self.path) : true"
                        },
                        {
                          "message": "exactly one of the fields in [backendRef url] must be set",
                          "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "resources": {
                      "description": "Resources sent to the token endpoint.",
                      "items": {
                        "type": "string"
                      },
                      "maxItems": 64,
                      "minItems": 1,
                      "type": "array"
                    },
                    "scopes": {
                      "description": "Scopes requested when obtaining the ID-JAG from the identity provider.",
                      "items": {
                        "type": "string"
                      },
                      "maxItems": 64,
                      "minItems": 1,
                      "type": "array"
                    },
                    "subjectToken": {
                      "description": "Subject token sent to the identity provider. Defaults to an OpenID Connect\nID token read from the Authorization Bearer header.",
                      "properties": {
                        "source": {
                          "description": "Where to read the subject token. Defaults to the Authorization Bearer header.",
                          "properties": {
                            "cookie": {
                              "properties": {
                                "name": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "expression": {
                              "description": "CEL expression that extracts the credential from the request.",
                              "maxLength": 16384,
                              "minLength": 1,
                              "type": "string"
                            },
                            "header": {
                              "properties": {
                                "name": {
                                  "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                  "type": "string"
                                },
                                "prefix": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "queryParameter": {
                              "properties": {
                                "name": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            }
                          },
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                              "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "tokenType": {
                          "description": "OAuth RFC 8693 subject token type. Defaults to IdToken",
                          "type": "string"
                        }
                      },
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "tokenType IdJag is not supported by crossAppAccess",
                          "rule": "!has(self.tokenType) || (self.tokenType != 'IdJag' && self.tokenType != 'urn:ietf:params:oauth:token-type:id-jag')"
                        }
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "audience",
                    "identityProvider",
                    "resourceAuthorizationServer"
                  ],
                  "type": "object",
                  "additionalProperties": false
                },
                "gcp": {
                  "description": "Google authentication method for the backend.\nWhen omitted, default Google credential discovery is used.",
                  "properties": {
                    "audience": {
                      "description": "Explicit `aud` value for the ID token. Only\nvalid with `IdToken` type. If not set, the `aud` is automatically\nderived from the backend hostname.",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "secretRef": {
                      "description": "Credential source for ADC-compatible Google credential JSON, defaulting to\na Kubernetes `Secret`. By default, the value is read from\n`credentials.json`; set `secretRef.key` to override it. When omitted,\nambient credentials are used.",
                      "properties": {
                        "group": {
                          "description": "API group of the referenced credential; empty selects the core API group",
                          "type": "string"
                        },
                        "key": {
                          "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        },
                        "kind": {
                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                          "type": "string"
                        },
                        "name": {
                          "description": "Name of the referenced credential",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "x-kubernetes-map-type": "atomic",
                      "x-kubernetes-validations": [
                        {
                          "message": "custom credential refs must set both group and kind",
                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "type": {
                      "description": "The type of token to generate. To authenticate to GCP services,\ngenerally an `AccessToken` is used. To authenticate to Cloud Run, an\n`IdToken` is used.",
                      "enum": [
                        "AccessToken",
                        "IdToken"
                      ],
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "audience is only valid with IdToken",
                      "rule": "has(self.audience) ? self.type == 'IdToken' : true"
                    }
                  ],
                  "additionalProperties": false
                },
                "jwtSign": {
                  "description": "Signs a short-lived JWT with a private key on each request and sends it\nto the backend, for upstreams that require per-request keypair JWTs\n(e.g. the Snowflake SQL API) rather than a static credential.",
                  "properties": {
                    "alg": {
                      "description": "JWS signing algorithm. Defaults to RS256.",
                      "enum": [
                        "ES256",
                        "ES384",
                        "PS256",
                        "RS256",
                        "RS384",
                        "RS512"
                      ],
                      "type": "string"
                    },
                    "claims": {
                      "additionalProperties": {
                        "x-kubernetes-preserve-unknown-fields": true
                      },
                      "description": "Static claims added to every token (e.g. iss, sub, aud). Values may be\nany JSON value (e.g. a string, number, bool, or array). iat, exp, and\nnbf are reserved for the signer and cannot be configured here; the\ncontroller rejects them at translation time.",
                      "type": "object"
                    },
                    "kid": {
                      "description": "Optional JWS key ID header.",
                      "type": "string"
                    },
                    "location": {
                      "description": "Where the signed token is written on the backend request.\nDefaults to the Authorization header with a \"Bearer \" prefix.",
                      "properties": {
                        "cookie": {
                          "properties": {
                            "name": {
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "additionalProperties": false
                        },
                        "header": {
                          "properties": {
                            "name": {
                              "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                              "maxLength": 256,
                              "minLength": 1,
                              "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                              "type": "string"
                            },
                            "prefix": {
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "additionalProperties": false
                        },
                        "queryParameter": {
                          "properties": {
                            "name": {
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "additionalProperties": false
                        }
                      },
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                          "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "signingKeyRef": {
                      "description": "Secret providing the `signingKey` key with a PEM-encoded RSA or EC private key.",
                      "properties": {
                        "group": {
                          "description": "API group of the referenced credential; empty selects the core API group",
                          "type": "string"
                        },
                        "kind": {
                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                          "type": "string"
                        },
                        "name": {
                          "description": "Name of the referenced credential",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "x-kubernetes-map-type": "atomic",
                      "x-kubernetes-validations": [
                        {
                          "message": "custom credential refs must set both group and kind",
                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "ttl": {
                      "description": "Token lifetime used for exp. Defaults to 300s.",
                      "maxLength": 32,
                      "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                      "type": "string",
                      "x-kubernetes-validations": [
                        {
                          "message": "ttl must be at least 1 second",
                          "rule": "duration(self) >= duration('1s')"
                        }
                      ]
                    }
                  },
                  "required": [
                    "signingKeyRef"
                  ],
                  "type": "object",
                  "additionalProperties": false
                },
                "key": {
                  "description": "Inline key to use as the value of the\n`Authorization` header. This option is the least secure; usage of a\n`Secret` is preferred.",
                  "maxLength": 2048,
                  "type": "string"
                },
                "location": {
                  "description": "Where backend credentials are inserted.\nIf omitted, credentials are written to the `Authorization` header with the `Bearer ` prefix.\nThis applies to `key`, `secretRef`, and `passthrough`. Entries in `credentials` carry their own location.",
                  "properties": {
                    "cookie": {
                      "properties": {
                        "name": {
                          "maxLength": 256,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "additionalProperties": false
                    },
                    "header": {
                      "properties": {
                        "name": {
                          "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                          "maxLength": 256,
                          "minLength": 1,
                          "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                          "type": "string"
                        },
                        "prefix": {
                          "maxLength": 256,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "additionalProperties": false
                    },
                    "queryParameter": {
                      "properties": {
                        "name": {
                          "maxLength": 256,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "additionalProperties": false
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                      "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                    }
                  ],
                  "additionalProperties": false
                },
                "oauthTokenExchange": {
                  "description": "OAuth 2.0 token exchange (RFC 8693) / jwt-bearer (RFC 7523) authentication.",
                  "properties": {
                    "actorToken": {
                      "description": "RFC 8693 delegation actor token. TokenExchange grant only.",
                      "properties": {
                        "mayAct": {
                          "description": "may_act claim validation mode. When omitted, may_act is not enforced.",
                          "enum": [
                            "Required"
                          ],
                          "type": "string"
                        },
                        "source": {
                          "description": "Where to read the actor token. Actor tokens have no default source.",
                          "properties": {
                            "cookie": {
                              "properties": {
                                "name": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "expression": {
                              "description": "CEL expression that extracts the credential from the request.",
                              "maxLength": 16384,
                              "minLength": 1,
                              "type": "string"
                            },
                            "header": {
                              "properties": {
                                "name": {
                                  "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                  "type": "string"
                                },
                                "prefix": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "queryParameter": {
                              "properties": {
                                "name": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            }
                          },
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                              "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "tokenType": {
                          "description": "OAuth token type. Empty defaults to AccessToken. Custom absolute URI values\nare supported for actor tokens.",
                          "type": "string"
                        }
                      },
                      "required": [
                        "source"
                      ],
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "mayAct Required requires tokenType Jwt",
                          "rule": "!has(self.mayAct) || self.mayAct != 'Required' || (has(self.tokenType) && self.tokenType == 'Jwt')"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "additionalParams": {
                      "additionalProperties": {
                        "description": "A Common Expression Language (CEL) expression.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "description": "Extra form params; values are CEL expressions over the incoming request.",
                      "maxProperties": 64,
                      "type": "object"
                    },
                    "audiences": {
                      "description": "Audiences sent to the token endpoint.",
                      "items": {
                        "maxLength": 256,
                        "minLength": 1,
                        "type": "string"
                      },
                      "maxItems": 64,
                      "minItems": 1,
                      "type": "array"
                    },
                    "backendRef": {
                      "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                      "properties": {
                        "group": {
                          "default": "",
                          "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                          "maxLength": 253,
                          "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                          "type": "string"
                        },
                        "kind": {
                          "default": "Service",
                          "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                          "maxLength": 63,
                          "minLength": 1,
                          "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                          "type": "string"
                        },
                        "name": {
                          "description": "Name is the name of the referent.",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        },
                        "namespace": {
                          "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                          "maxLength": 63,
                          "minLength": 1,
                          "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                          "type": "string"
                        },
                        "port": {
                          "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                          "format": "int32",
                          "maximum": 65535,
                          "minimum": 1,
                          "type": "integer"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "Must have port for Service reference",
                          "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "cache": {
                      "description": "Response cache configuration.",
                      "properties": {
                        "inMemory": {
                          "properties": {
                            "defaultTtl": {
                              "description": "TTL used when the token endpoint omits expires_in. Default 300s.",
                              "maxLength": 32,
                              "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                              "type": "string",
                              "x-kubernetes-validations": [
                                {
                                  "message": "defaultTtl must be at least 1 second",
                                  "rule": "duration(self) >= duration('1s')"
                                }
                              ]
                            },
                            "maxEntries": {
                              "description": "Default 8192; 0 disables the cache.",
                              "format": "int32",
                              "type": "integer"
                            }
                          },
                          "type": "object",
                          "additionalProperties": false
                        }
                      },
                      "type": "object",
                      "additionalProperties": false
                    },
                    "clientAuth": {
                      "description": "Client authentication for the token endpoint. When unset, none is sent.",
                      "properties": {
                        "clientId": {
                          "description": "Client ID sent to the token endpoint.",
                          "minLength": 1,
                          "type": "string"
                        },
                        "method": {
                          "description": "Client authentication method. Defaults to ClientSecretBasic.",
                          "enum": [
                            "ClientSecretBasic",
                            "ClientSecretPost",
                            "PrivateKeyJwt"
                          ],
                          "type": "string"
                        },
                        "privateKeyJwt": {
                          "description": "Client assertion settings. Required when method is PrivateKeyJwt.",
                          "properties": {
                            "alg": {
                              "description": "JWS signing algorithm. Defaults to RS256.",
                              "enum": [
                                "ES256",
                                "ES384",
                                "PS256",
                                "RS256",
                                "RS384",
                                "RS512"
                              ],
                              "type": "string"
                            },
                            "assertionAudience": {
                              "description": "Audience for the client assertion, typically the token endpoint URL.",
                              "minLength": 1,
                              "type": "string"
                            },
                            "certificateHeader": {
                              "description": "JWS certificate header. Required when certificateRef is set.",
                              "enum": [
                                "x5c",
                                "x5t#S256"
                              ],
                              "type": "string"
                            },
                            "certificateRef": {
                              "description": "PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The\nleaf public key should match signingKeyRef; a mismatch only logs a warning\nbut the token endpoint will reject the assertions. Required when\ncertificateHeader is set. The key defaults to `certificate`.",
                              "properties": {
                                "group": {
                                  "description": "API group of the referenced credential; empty selects the core API group",
                                  "type": "string"
                                },
                                "key": {
                                  "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "kind": {
                                  "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                  "type": "string"
                                },
                                "name": {
                                  "description": "Name of the referenced credential",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "x-kubernetes-map-type": "atomic",
                              "x-kubernetes-validations": [
                                {
                                  "message": "custom credential refs must set both group and kind",
                                  "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                }
                              ],
                              "additionalProperties": false
                            },
                            "kid": {
                              "description": "Optional JWS key ID header.",
                              "type": "string"
                            },
                            "signingKeyRef": {
                              "description": "PEM-encoded RSA or EC private key; key defaults to `signingKey`.",
                              "properties": {
                                "group": {
                                  "description": "API group of the referenced credential; empty selects the core API group",
                                  "type": "string"
                                },
                                "key": {
                                  "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "kind": {
                                  "description": "Kind of the referenced credential; empty defaults to `Secret`",
                                  "type": "string"
                                },
                                "name": {
                                  "description": "Name of the referenced credential",
                                  "maxLength": 253,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "x-kubernetes-map-type": "atomic",
                              "x-kubernetes-validations": [
                                {
                                  "message": "custom credential refs must set both group and kind",
                                  "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                                }
                              ],
                              "additionalProperties": false
                            }
                          },
                          "required": [
                            "assertionAudience",
                            "signingKeyRef"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "certificateRef and certificateHeader must be set together",
                              "rule": "has(self.certificateRef) == has(self.certificateHeader)"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "secretRef": {
                          "description": "Secret providing the `clientSecret` key by default; override via\n`secretRef.key`. When omitted, client_id is sent without a secret, which\nis only valid with ClientSecretPost.",
                          "properties": {
                            "group": {
                              "description": "API group of the referenced credential; empty selects the core API group",
                              "type": "string"
                            },
                            "key": {
                              "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                              "maxLength": 253,
                              "minLength": 1,
                              "type": "string"
                            },
                            "kind": {
                              "description": "Kind of the referenced credential; empty defaults to `Secret`",
                              "type": "string"
                            },
                            "name": {
                              "description": "Name of the referenced credential",
                              "maxLength": 253,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "x-kubernetes-map-type": "atomic",
                          "x-kubernetes-validations": [
                            {
                              "message": "custom credential refs must set both group and kind",
                              "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                            }
                          ],
                          "additionalProperties": false
                        }
                      },
                      "required": [
                        "clientId"
                      ],
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "privateKeyJwt settings require method PrivateKeyJwt",
                          "rule": "has(self.privateKeyJwt) == (has(self.method) && self.method == 'PrivateKeyJwt')"
                        },
                        {
                          "message": "secretRef is not valid with method PrivateKeyJwt",
                          "rule": "!has(self.secretRef) || !has(self.method) || self.method != 'PrivateKeyJwt'"
                        },
                        {
                          "message": "clientAuth without secretRef requires method ClientSecretPost or PrivateKeyJwt",
                          "rule": "has(self.secretRef) || has(self.privateKeyJwt) || (has(self.method) && self.method == 'ClientSecretPost')"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "grantType": {
                      "description": "RFC followed by the request. Defaults to TokenExchange (RFC 8693).",
                      "enum": [
                        "JwtBearer",
                        "TokenExchange"
                      ],
                      "type": "string"
                    },
                    "location": {
                      "description": "Where the exchanged token is written to the backend request.\nDefaults to Authorization: Bearer.",
                      "properties": {
                        "cookie": {
                          "properties": {
                            "name": {
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "additionalProperties": false
                        },
                        "header": {
                          "properties": {
                            "name": {
                              "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                              "maxLength": 256,
                              "minLength": 1,
                              "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                              "type": "string"
                            },
                            "prefix": {
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "additionalProperties": false
                        },
                        "queryParameter": {
                          "properties": {
                            "name": {
                              "maxLength": 256,
                              "minLength": 1,
                              "type": "string"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "additionalProperties": false
                        }
                      },
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "exactly one of the fields in [header queryParameter cookie] must be set",
                          "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0) == 1"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "path": {
                      "description": "Token endpoint path; defaults to \"/\". Must start with \"/\".",
                      "pattern": "^/",
                      "type": "string"
                    },
                    "requestedTokenType": {
                      "description": "RFC 8693 requested_token_type. Unlike subject/actor token types, only the\nbuilt-in values may be requested; custom URIs are not supported here.",
                      "enum": [
                        "AccessToken",
                        "Jwt",
                        "IdToken",
                        "IdJag"
                      ],
                      "type": "string"
                    },
                    "resources": {
                      "description": "Resources sent to the token endpoint.",
                      "items": {
                        "type": "string"
                      },
                      "maxItems": 64,
                      "minItems": 1,
                      "type": "array"
                    },
                    "scopes": {
                      "description": "Scopes sent to the token endpoint.",
                      "items": {
                        "type": "string"
                      },
                      "maxItems": 64,
                      "minItems": 1,
                      "type": "array"
                    },
                    "subjectToken": {
                      "description": "Subject token / assertion source and type. Defaults to Authorization Bearer, AccessToken.\nThe token type may be a built-in value or a custom absolute URI for providers\nthat support custom token exchange profiles.",
                      "properties": {
                        "source": {
                          "description": "Where to read the token. CEL `expression` variant is permitted.",
                          "properties": {
                            "cookie": {
                              "properties": {
                                "name": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "expression": {
                              "description": "CEL expression that extracts the credential from the request.",
                              "maxLength": 16384,
                              "minLength": 1,
                              "type": "string"
                            },
                            "header": {
                              "properties": {
                                "name": {
                                  "description": "Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported",
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "pattern": "^[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                  "type": "string"
                                },
                                "prefix": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            },
                            "queryParameter": {
                              "properties": {
                                "name": {
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "type": "string"
                                }
                              },
                              "required": [
                                "name"
                              ],
                              "type": "object",
                              "additionalProperties": false
                            }
                          },
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "exactly one of the fields in [header queryParameter cookie expression] must be set",
                              "rule": "(has(self.header)?1:0)+(has(self.queryParameter)?1:0)+(has(self.cookie)?1:0)+(has(self.expression)?1:0) == 1"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "tokenType": {
                          "description": "OAuth token type. Empty defaults to AccessToken. Custom absolute URI values\nare supported for subject tokens.",
                          "type": "string"
                        }
                      },
                      "type": "object",
                      "additionalProperties": false
                    },
                    "url": {
                      "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                      "maxLength": 1024,
                      "minLength": 1,
                      "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                      "type": "string"
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "actorToken is only valid with TokenExchange grantType",
                      "rule": "!(has(self.actorToken) && has(self.grantType) && self.grantType == 'JwtBearer')"
                    },
                    {
                      "message": "requestedTokenType is only valid with TokenExchange grantType",
                      "rule": "!(has(self.requestedTokenType) && has(self.grantType) && self.grantType == 'JwtBearer')"
                    },
                    {
                      "message": "requestedTokenType IdJag is only supported by crossAppAccess",
                      "rule": "!has(self.requestedTokenType) || self.requestedTokenType != 'IdJag'"
                    },
                    {
                      "message": "path may not be set when url is set",
                      "rule": "has(self.url) ? !has(self.path) : true"
                    },
                    {
                      "message": "exactly one of the fields in [backendRef url] must be set",
                      "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                    }
                  ],
                  "additionalProperties": false
                },
                "passthrough": {
                  "description": "Reuses a client token already validated by another policy. Those policies\nmay strip client credentials; passthrough adds the original token back to\nthe backend request. Without client auth policies, this has no effect.",
                  "type": "object"
                },
                "secretRef": {
                  "description": "Credential source for the authorization value, defaulting to a Kubernetes\n`Secret`. By default, the value is read from the `Authorization` key; set\n`secretRef.key` to override it. A `Bearer ` prefix is stripped only from\nthe default `Authorization` key.",
                  "properties": {
                    "group": {
                      "description": "API group of the referenced credential; empty selects the core API group",
                      "type": "string"
                    },
                    "key": {
                      "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                      "maxLength": 253,
                      "minLength": 1,
                      "type": "string"
                    },
                    "kind": {
                      "description": "Kind of the referenced credential; empty defaults to `Secret`",
                      "type": "string"
                    },
                    "name": {
                      "description": "Name of the referenced credential",
                      "maxLength": 253,
                      "minLength": 1,
                      "type": "string"
                    }
                  },
                  "required": [
                    "name"
                  ],
                  "type": "object",
                  "x-kubernetes-map-type": "atomic",
                  "x-kubernetes-validations": [
                    {
                      "message": "custom credential refs must set both group and kind",
                      "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                    }
                  ],
                  "additionalProperties": false
                }
              },
              "type": "object",
              "x-kubernetes-validations": [
                {
                  "message": "must specify credentials, or at most one of key/secretRef/passthrough/aws/azure/gcp/oauthTokenExchange/crossAppAccess/jwtSign (credentials may be combined with a primary auth kind)",
                  "rule": "has(self.credentials) || has(self.key) || has(self.secretRef) || has(self.passthrough) || has(self.aws) || has(self.azure) || has(self.gcp) || has(self.oauthTokenExchange) || has(self.crossAppAccess) || has(self.jwtSign)"
                },
                {
                  "message": "location may only be set for key, secretRef, or passthrough auth",
                  "rule": "has(self.location) ? has(self.key) || has(self.secretRef) || has(self.passthrough) : true"
                },
                {
                  "message": "at most one of the fields in [key secretRef passthrough aws azure gcp oauthTokenExchange crossAppAccess jwtSign] may be set",
                  "rule": "(has(self.key)?1:0)+(has(self.secretRef)?1:0)+(has(self.passthrough)?1:0)+(has(self.aws)?1:0)+(has(self.azure)?1:0)+(has(self.gcp)?1:0)+(has(self.oauthTokenExchange)?1:0)+(has(self.crossAppAccess)?1:0)+(has(self.jwtSign)?1:0) <= 1"
                }
              ],
              "additionalProperties": false
            },
            "authorization": {
              "description": "Authorization rules that clients must satisfy after this backend is selected.\nUnlike traffic authorization, this policy is evaluated against the request\nassociated with the selected destination backend.",
              "properties": {
                "action": {
                  "description": "The effect of this rule when it matches.\nIf unspecified, defaults to `Allow`.\n`Require` rules are cumulative: all require rules must match.",
                  "enum": [
                    "Allow",
                    "Deny",
                    "Require"
                  ],
                  "type": "string"
                },
                "policy": {
                  "description": "The authorization rule to evaluate.\n\n* `Allow`: any matching allow rule allows the request.\n* `Require`: every require rule must match for the request to be allowed.\n* `Deny`: any matching deny rule denies the request.\n\n`Deny` is not recommended because expression failures fail to deny; prefer\n`Allow` or `Require`. If used, design expressions defensively against evaluation errors.\n\nIf at least one `Allow` rule is configured, requests are denied unless at\nleast one allow rule matches.",
                  "properties": {
                    "matchExpressions": {
                      "description": "CEL expressions that must all evaluate to true for the rule to match.",
                      "items": {
                        "description": "A Common Expression Language (CEL) expression.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "maxItems": 256,
                      "minItems": 1,
                      "type": "array"
                    }
                  },
                  "required": [
                    "matchExpressions"
                  ],
                  "type": "object",
                  "additionalProperties": false
                }
              },
              "required": [
                "policy"
              ],
              "type": "object",
              "additionalProperties": false
            },
            "extAuth": {
              "description": "External authentication configuration for requests\nsent to this backend.",
              "properties": {
                "backendRef": {
                  "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                  "properties": {
                    "group": {
                      "default": "",
                      "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                      "maxLength": 253,
                      "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                      "type": "string"
                    },
                    "kind": {
                      "default": "Service",
                      "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                      "maxLength": 63,
                      "minLength": 1,
                      "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                      "type": "string"
                    },
                    "name": {
                      "description": "Name is the name of the referent.",
                      "maxLength": 253,
                      "minLength": 1,
                      "type": "string"
                    },
                    "namespace": {
                      "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                      "maxLength": 63,
                      "minLength": 1,
                      "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                      "type": "string"
                    },
                    "port": {
                      "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                      "format": "int32",
                      "maximum": 65535,
                      "minimum": 1,
                      "type": "integer"
                    }
                  },
                  "required": [
                    "name"
                  ],
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "Must have port for Service reference",
                      "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                    }
                  ],
                  "additionalProperties": false
                },
                "cache": {
                  "description": "Caches authorization results.\n\nWARNING: the safety of this feature depends on the cache key accurately\ncapturing every request property that the authorization service uses to\nmake a decision. For example, if the service returns different results\nbased on both path and authorization header, both must be included in\n`key`; otherwise, one request may incorrectly reuse another request's\nauthorization result.\n\nIf any key expression fails to evaluate or produces an unsupported value,\nthe request is still sent to the authorization service, but its result is\nnot read from or written to the cache.",
                  "properties": {
                    "key": {
                      "description": "Ordered list of CEL expressions evaluated against the request\nto construct the cache key.",
                      "items": {
                        "description": "A Common Expression Language (CEL) expression.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "maxItems": 16,
                      "minItems": 1,
                      "type": "array"
                    },
                    "maxEntries": {
                      "description": "Maximum number of authorization results to keep in\nthe cache. If unset, this defaults to 10000.",
                      "format": "int32",
                      "minimum": 1,
                      "type": "integer"
                    },
                    "ttl": {
                      "description": "Duration string, such as `5m`, or a CEL expression that\nreturns the duration that cached authorization results may be reused, or a\ntimestamp when the cached authorization result expires. The expression is\nevaluated after the authorization response has been applied to the request.",
                      "maxLength": 16384,
                      "minLength": 1,
                      "type": "string"
                    }
                  },
                  "required": [
                    "key",
                    "ttl"
                  ],
                  "type": "object",
                  "additionalProperties": false
                },
                "failureMode": {
                  "description": "Behavior when the external authorization service is\nunavailable or returns an error. \"FailOpen\" allows the request to continue.\n\"FailClosed\" (default) denies the request.",
                  "enum": [
                    "FailClosed",
                    "FailOpen"
                  ],
                  "type": "string"
                },
                "forwardBody": {
                  "description": "Whether to include the HTTP body in the authorization request.\nIf enabled, the request body will be buffered.",
                  "properties": {
                    "maxSize": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "string"
                        }
                      ],
                      "description": "Largest body, in bytes, that will be buffered\nand sent to the authorization server. If the body size is larger than\n`maxSize`, then the request will be rejected with a response.",
                      "maxLength": 32,
                      "minLength": 1,
                      "pattern": "^[+-]?([0-9]+(\\.[0-9]*)?|\\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\\+?0*([0-9]|1[0-8])|-0*[0-9]))?$",
                      "x-kubernetes-int-or-string": true,
                      "x-kubernetes-validations": [
                        {
                          "message": "value must be at least 1 byte and fit within uint32",
                          "rule": "(self >= 1 && self <= 4294967295) || self.size() > 0"
                        }
                      ]
                    }
                  },
                  "required": [
                    "maxSize"
                  ],
                  "type": "object",
                  "additionalProperties": false
                },
                "grpc": {
                  "description": "Uses the gRPC External Authorization\n[protocol](https://www.envoyproxy.io/docs/envoy/latest/api-v3/service/auth/v3/external_auth.proto) should be used.",
                  "properties": {
                    "contextExtensions": {
                      "additionalProperties": {
                        "type": "string"
                      },
                      "description": "Additional arbitrary key-value pairs to\nsend to the authorization server in the `context_extensions` field.",
                      "maxProperties": 64,
                      "type": "object"
                    },
                    "requestMetadata": {
                      "additionalProperties": {
                        "description": "A Common Expression Language (CEL) expression.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "description": "Metadata to send to the authorization\nserver. This maps to the `metadata_context.filter_metadata` field of the\nrequest, and allows dynamic CEL expressions. If unset, by default the\n`envoy.filters.http.jwt_authn` key is set if the JWT policy is used as\nwell, for compatibility.",
                      "maxProperties": 64,
                      "type": "object"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "http": {
                  "description": "Uses HTTP to connect to\nthe authorization server. The authorization server must return a `200`\nstatus code, otherwise the request is considered an authorization\nfailure.",
                  "properties": {
                    "addRequestHeaders": {
                      "additionalProperties": {
                        "description": "A Common Expression Language (CEL) expression.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "description": "Additional headers to add to the\nrequest to the authorization server. While `allowedRequestHeaders` just\npasses the original headers through, `addRequestHeaders` allows defining\ncustom headers based on CEL expressions.",
                      "maxProperties": 64,
                      "type": "object"
                    },
                    "allowedRequestHeaders": {
                      "description": "Additional headers from the client request that\nwill be sent to the authorization server.\n\nIf unset, the following headers are sent by default: `Authorization`.",
                      "items": {
                        "maxLength": 256,
                        "minLength": 1,
                        "type": "string"
                      },
                      "maxItems": 64,
                      "type": "array"
                    },
                    "allowedResponseHeaders": {
                      "description": "Headers from the authorization response that\nwill be copied into the request to the backend.",
                      "items": {
                        "maxLength": 256,
                        "minLength": 1,
                        "type": "string"
                      },
                      "maxItems": 64,
                      "type": "array"
                    },
                    "body": {
                      "description": "Body is a CEL expression that produces the HTTP authorization request body.\nStrings and bytes are used directly; other values are JSON-encoded.",
                      "maxLength": 16384,
                      "minLength": 1,
                      "type": "string"
                    },
                    "path": {
                      "description": "Path to send to the authorization server. If\nunset, this defaults to the original request path.\nThis is a CEL expression, which allows customizing the path based on the\nincoming request. For example, to add a prefix, use\n`\"/prefix/\" + request.path`.",
                      "maxLength": 16384,
                      "minLength": 1,
                      "type": "string"
                    },
                    "redirect": {
                      "description": "Optional expression that determines a path to\nredirect to on authorization failure. This is useful to redirect to a\nsign-in page.",
                      "maxLength": 16384,
                      "minLength": 1,
                      "type": "string"
                    },
                    "responseMetadata": {
                      "additionalProperties": {
                        "description": "A Common Expression Language (CEL) expression.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "description": "Metadata fields to construct\nfrom the authorization response. These will be included under the\n`extauthz` variable in future CEL expressions. Setting this is useful\nfor things like logging usernames, without needing to include them as\nheaders to the backend, as `allowedResponseHeaders` would.",
                      "maxProperties": 64,
                      "type": "object"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "url": {
                  "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                  "maxLength": 1024,
                  "minLength": 1,
                  "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                  "type": "string"
                }
              },
              "type": "object",
              "x-kubernetes-validations": [
                {
                  "message": "exactly one of backendRef or url must be set",
                  "rule": "[has(self.backendRef),has(self.url)].filter(x,x==true).size() == 1"
                },
                {
                  "message": "forwardBody cannot be used with http.body",
                  "rule": "!(has(self.forwardBody) && has(self.http) && has(self.http.body))"
                },
                {
                  "message": "url path is only valid with http",
                  "rule": "!has(self.url) || !self.url.matches('^https?://[^/?#]+/') || has(self.http)"
                },
                {
                  "message": "http.path may not be set when url includes a path",
                  "rule": "!has(self.url) || !self.url.matches('^https?://[^/?#]+/') || !has(self.http) || !has(self.http.path)"
                }
              ],
              "additionalProperties": false
            },
            "health": {
              "description": "Settings for passive and active health checking.",
              "properties": {
                "eviction": {
                  "description": "Settings for evicting unhealthy backends.",
                  "properties": {
                    "consecutiveFailures": {
                      "description": "Number of consecutive unhealthy responses required before the backend is evicted.\nFor example, a value of 5 means the backend must receive 5 unhealthy responses in a row before being evicted.\nWhen both consecutiveFailures and healthThreshold are set, the backend is evicted when either condition is met.\nWhen neither is set, a single unhealthy response can trigger eviction.",
                      "format": "int32",
                      "minimum": 0,
                      "type": "integer"
                    },
                    "duration": {
                      "description": "Base time a backend should be evicted after being marked unhealthy.\nSubsequent evictions use multiplicative backoff (duration * times_evicted).\nIf all endpoints are evicted, the load balancer falls back to returning evicted endpoints\nrather than failing entirely.\nIf unset, defaults to `3s`.",
                      "maxLength": 32,
                      "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                      "type": "string",
                      "x-kubernetes-validations": [
                        {
                          "message": "duration must be at least 1 second",
                          "rule": "duration(self) >= duration('1s')"
                        }
                      ]
                    },
                    "healthThreshold": {
                      "description": "EWMA health score threshold, from 0 to 100. When set, a backend is evicted\nonly if its computed health drops below this value after an unhealthy\nresponse (e.g. 50 evicts when EWMA health falls below 50%). Unlike\nconsecutiveFailures, this sliding-window average lets a single success delay\neviction. If both are set, either condition evicts; if neither, a single\nunhealthy response evicts.",
                      "format": "int32",
                      "maximum": 100,
                      "minimum": 0,
                      "type": "integer"
                    },
                    "restoreHealth": {
                      "description": "Health score from 0 to 100 assigned to a backend when it returns from eviction.\nFor gradual recovery, set below 100; for full recovery immediately, set 100.\nIf unset, the backend resumes with the health it had when evicted.",
                      "format": "int32",
                      "maximum": 100,
                      "minimum": 0,
                      "type": "integer"
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                },
                "unhealthyCondition": {
                  "description": "CEL expression that determines whether a response indicates an unhealthy backend.\nWhen the expression evaluates to true, the backend is considered unhealthy and may be evicted.\n\nFor example, to evict on 5xx responses: `response.code >= 500`.\n\nWhen unset, any 5xx response, or a connection failure, is treated as unhealthy.\nThis default lowers the backend's health score but does not trigger eviction on its own.",
                  "maxLength": 16384,
                  "minLength": 1,
                  "type": "string"
                }
              },
              "type": "object",
              "additionalProperties": false
            },
            "http": {
              "description": "Settings for managing HTTP requests to the backend",
              "properties": {
                "requestTimeout": {
                  "description": "Deadline for receiving a response from the backend.",
                  "maxLength": 32,
                  "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                  "type": "string",
                  "x-kubernetes-validations": [
                    {
                      "message": "requestTimeout must be at least 1ms",
                      "rule": "duration(self) >= duration('1ms')"
                    }
                  ]
                },
                "version": {
                  "description": "HTTP protocol version for backend connections. If unset, it is inferred:\n`Service` appProtocol, `HTTP2` for gRPC, the original protocol for\nplaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS\nto HTTP/2 even when the backend does not support it.",
                  "enum": [
                    "HTTP1",
                    "HTTP2"
                  ],
                  "type": "string"
                }
              },
              "type": "object",
              "additionalProperties": false
            },
            "mcp": {
              "description": "Settings for MCP workloads. This is only applicable when\nconnecting to a `Backend` of type `mcp`.",
              "properties": {
                "authentication": {
                  "description": "MCP backend-specific authentication rules.\n\nThis field is deprecated; prefer to use traffic policy `jwtAuthentication.mcp`, which ensures authentication runs before\nother policies such as transformation and rate limiting.",
                  "properties": {
                    "audiences": {
                      "description": "Allowed audiences that are allowed\naccess. This corresponds to the `aud` claim\n([RFC 7519 \u00a74.1.3](https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.3)).\nIf unset, any audience is allowed.",
                      "items": {
                        "type": "string"
                      },
                      "maxItems": 64,
                      "minItems": 1,
                      "type": "array"
                    },
                    "clientId": {
                      "description": "Client ID to use for short-circuiting Dynamic Client Registration.\nIf set, the gateway will not proxy registration requests to the IDP and instead return this client ID.",
                      "type": "string"
                    },
                    "clientSecretRef": {
                      "description": "Reference to a Kubernetes Secret holding the OAuth client secret of the app\nregistration identified by `clientId` (for example Entra ID confidential clients,\nwhich require the secret at the token endpoint). The gateway injects it into the\ntoken requests it proxies to the provider. Defaults to the `clientSecret` key;\noverride via `clientSecretRef.key`.",
                      "properties": {
                        "group": {
                          "description": "API group of the referenced credential; empty selects the core API group",
                          "type": "string"
                        },
                        "key": {
                          "description": "Key in the referenced Secret. If omitted, a location-specific default is used",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        },
                        "kind": {
                          "description": "Kind of the referenced credential; empty defaults to `Secret`",
                          "type": "string"
                        },
                        "name": {
                          "description": "Name of the referenced credential",
                          "maxLength": 253,
                          "minLength": 1,
                          "type": "string"
                        }
                      },
                      "required": [
                        "name"
                      ],
                      "type": "object",
                      "x-kubernetes-map-type": "atomic",
                      "x-kubernetes-validations": [
                        {
                          "message": "custom credential refs must set both group and kind",
                          "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "issuer": {
                      "description": "IdP that issued the JWT. This corresponds to the\n`iss` claim ([RFC 7519 \u00a74.1.1](https://tools.ietf.org/html/rfc7519#section-4.1.1)).",
                      "maxLength": 256,
                      "minLength": 1,
                      "type": "string"
                    },
                    "jwks": {
                      "description": "Remote JSON Web Key used to validate the signature of\nthe JWT.",
                      "properties": {
                        "backendRef": {
                          "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                          "properties": {
                            "group": {
                              "default": "",
                              "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                              "maxLength": 253,
                              "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                              "type": "string"
                            },
                            "kind": {
                              "default": "Service",
                              "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                              "type": "string"
                            },
                            "name": {
                              "description": "Name is the name of the referent.",
                              "maxLength": 253,
                              "minLength": 1,
                              "type": "string"
                            },
                            "namespace": {
                              "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                              "maxLength": 63,
                              "minLength": 1,
                              "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                              "type": "string"
                            },
                            "port": {
                              "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                              "format": "int32",
                              "maximum": 65535,
                              "minimum": 1,
                              "type": "integer"
                            }
                          },
                          "required": [
                            "name"
                          ],
                          "type": "object",
                          "x-kubernetes-validations": [
                            {
                              "message": "Must have port for Service reference",
                              "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                            }
                          ],
                          "additionalProperties": false
                        },
                        "cacheDuration": {
                          "description": "How long a fetched `jwks` document is used before it is re-fetched from the IdP.\nDefaults to `5m`.",
                          "maxLength": 32,
                          "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                          "type": "string",
                          "x-kubernetes-validations": [
                            {
                              "message": "cacheDuration must be at least 5m.",
                              "rule": "duration(self) >= duration('5m')"
                            }
                          ]
                        },
                        "jwksPath": {
                          "description": "Path to the IdP `jwks` endpoint, relative to the root, commonly\n`\".well-known/jwks.json\"`.",
                          "maxLength": 1024,
                          "minLength": 1,
                          "type": "string"
                        },
                        "url": {
                          "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                          "maxLength": 1024,
                          "minLength": 1,
                          "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                          "type": "string"
                        }
                      },
                      "type": "object",
                      "x-kubernetes-validations": [
                        {
                          "message": "jwksPath is required when backendRef is set",
                          "rule": "has(self.backendRef) ? has(self.jwksPath) : true"
                        },
                        {
                          "message": "jwksPath may not be set when url is set",
                          "rule": "has(self.url) ? !has(self.jwksPath) : true"
                        },
                        {
                          "message": "exactly one of the fields in [backendRef url] must be set",
                          "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                        }
                      ],
                      "additionalProperties": false
                    },
                    "mode": {
                      "description": "Validation mode for JWT authentication. Defaults to `Strict`.",
                      "enum": [
                        "Optional",
                        "Permissive",
                        "Strict"
                      ],
                      "type": "string"
                    },
                    "provider": {
                      "description": "Identity provider to use for authentication.",
                      "enum": [
                        "Auth0",
                        "Authentik",
                        "Descope",
                        "Entra",
                        "Keycloak",
                        "Okta"
                      ],
                      "type": "string"
                    },
                    "resourceMetadata": {
                      "additionalProperties": {
                        "x-kubernetes-preserve-unknown-fields": true
                      },
                      "description": "Metadata to use for MCP resources.",
                      "type": "object"
                    },
                    "validation": {
                      "description": "Additional JWT claim presence requirements. Defaults to requiring `exp`.\nIssuer validation always requires `iss`; a non-empty audiences list also\nrequires `aud`, regardless of these options. An empty `requiredClaims`\nlist removes only the additional presence requirements. Expiration is\nstill checked whenever `exp` is present.",
                      "properties": {
                        "requiredClaims": {
                          "description": "Additional claims that must be present in the token payload.\nRecognized values: `exp`, `nbf`, `aud`, `sub`.\nDefaults to `[\"exp\"]` when omitted. An empty list adds no requirements\nbeyond `iss`, which is always required, and `aud`, which is required\nwhen a non-empty audiences list is configured. Expiration is still\nchecked whenever `exp` is present.",
                          "items": {
                            "description": "JWTClaim is a JWT claim whose presence can be required during validation.",
                            "enum": [
                              "aud",
                              "exp",
                              "nbf",
                              "sub"
                            ],
                            "type": "string"
                          },
                          "maxItems": 4,
                          "type": "array",
                          "x-kubernetes-list-type": "atomic"
                        }
                      },
                      "type": "object",
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "jwks"
                  ],
                  "type": "object",
                  "additionalProperties": false
                },
                "authorization": {
                  "description": "MCP backend authorization. Unlike authorization at the HTTP level, which rejects\nunauthorized requests with a `403` error, this policy works at the\n`MCPBackend` level.\n\nList operations, such as `list_tools`, will have each item evaluated.\nItems that do not meet the rule will be filtered.\n\nGet or call operations, such as `call_tool`, will evaluate the specific\nitem and reject requests that do not meet the rule.",
                  "properties": {
                    "action": {
                      "description": "The effect of this rule when it matches.\nIf unspecified, defaults to `Allow`.\n`Require` rules are cumulative: all require rules must match.",
                      "enum": [
                        "Allow",
                        "Deny",
                        "Require"
                      ],
                      "type": "string"
                    },
                    "policy": {
                      "description": "The authorization rule to evaluate.\n\n* `Allow`: any matching allow rule allows the request.\n* `Require`: every require rule must match for the request to be allowed.\n* `Deny`: any matching deny rule denies the request.\n\n`Deny` is not recommended because expression failures fail to deny; prefer\n`Allow` or `Require`. If used, design expressions defensively against evaluation errors.\n\nIf at least one `Allow` rule is configured, requests are denied unless at\nleast one allow rule matches.",
                      "properties": {
                        "matchExpressions": {
                          "description": "CEL expressions that must all evaluate to true for the rule to match.",
                          "items": {
                            "description": "A Common Expression Language (CEL) expression.",
                            "maxLength": 16384,
                            "minLength": 1,
                            "type": "string"
                          },
                          "maxItems": 256,
                          "minItems": 1,
                          "type": "array"
                        }
                      },
                      "required": [
                        "matchExpressions"
                      ],
                      "type": "object",
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "policy"
                  ],
                  "type": "object",
                  "additionalProperties": false
                },
                "guardrails": {
                  "description": "`guardrails` routes selected JSON-RPC methods through a remote policy server.",
                  "properties": {
                    "processors": {
                      "description": "`processors` is the ordered list of policy processors applied to matched\nmethods. Processors run in the order listed; the first to reject a request\nshort-circuits the chain.",
                      "items": {
                        "description": "MCPGuardrailsProcessor selects a single policy processor. Exactly one variant must be set.",
                        "properties": {
                          "methods": {
                            "additionalProperties": {
                              "description": "MCPMethodPhase controls when an MCP method is run through the guardrails pipeline.",
                              "enum": [
                                "Full",
                                "Off",
                                "Request",
                                "Response"
                              ],
                              "type": "string"
                            },
                            "description": "`methods` is the allowlist of JSON-RPC methods (e.g. `tools/call`,\n`tools/list`) routed through this processor, keyed by method name with the\nphase it runs in. Keys may be exact, a prefix wildcard (`tools/*`), a suffix\nwildcard (`*/list`), or `*` for all methods; the most specific match wins.\nMethods matching no key, including unknown ones, bypass this processor.",
                            "maxProperties": 64,
                            "minProperties": 1,
                            "type": "object",
                            "x-kubernetes-validations": [
                              {
                                "message": "method wildcards must be '*', a prefix like 'tools/*', or a suffix like '*/list'",
                                "rule": "self.all(k, !k.contains('*') || (k.indexOf('*') == k.lastIndexOf('*') && (k.indexOf('*') == 0 || k.indexOf('*') == size(k) - 1)))"
                              }
                            ]
                          },
                          "remote": {
                            "description": "`remote` configures a gRPC policy server.",
                            "properties": {
                              "allowedRequestHeaders": {
                                "description": "`allowedRequestHeaders` lists the incoming request headers forwarded to\nthe policy server in `McpRequest.headers`. If empty, all headers and\npseudo-headers (`:authority`, `:method`, ...) are forwarded. Matching is\ncase-insensitive.",
                                "items": {
                                  "description": "HTTP header name.",
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                  "type": "string",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                      "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                                    }
                                  ]
                                },
                                "maxItems": 64,
                                "type": "array",
                                "x-kubernetes-list-type": "set"
                              },
                              "backendRef": {
                                "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                                "properties": {
                                  "group": {
                                    "default": "",
                                    "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                                    "maxLength": 253,
                                    "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                                    "type": "string"
                                  },
                                  "kind": {
                                    "default": "Service",
                                    "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                                    "type": "string"
                                  },
                                  "name": {
                                    "description": "Name is the name of the referent.",
                                    "maxLength": 253,
                                    "minLength": 1,
                                    "type": "string"
                                  },
                                  "namespace": {
                                    "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                                    "maxLength": 63,
                                    "minLength": 1,
                                    "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                                    "type": "string"
                                  },
                                  "port": {
                                    "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                                    "format": "int32",
                                    "maximum": 65535,
                                    "minimum": 1,
                                    "type": "integer"
                                  }
                                },
                                "required": [
                                  "name"
                                ],
                                "type": "object",
                                "x-kubernetes-validations": [
                                  {
                                    "message": "Must have port for Service reference",
                                    "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                                  }
                                ],
                                "additionalProperties": false
                              },
                              "disallowedRequestHeaders": {
                                "description": "`disallowedRequestHeaders` lists header names never forwarded to the\npolicy server, even if listed in `allowedRequestHeaders`. Matching is\ncase-insensitive.",
                                "items": {
                                  "description": "HTTP header name.",
                                  "maxLength": 256,
                                  "minLength": 1,
                                  "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                                  "type": "string",
                                  "x-kubernetes-validations": [
                                    {
                                      "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                      "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                                    }
                                  ]
                                },
                                "maxItems": 64,
                                "type": "array",
                                "x-kubernetes-list-type": "set"
                              },
                              "failureMode": {
                                "description": "`failureMode` controls behavior when the policy server is unreachable\nor returns an error. `FailOpen` allows the request; `FailClosed`\n(default) denies it.",
                                "enum": [
                                  "FailClosed",
                                  "FailOpen"
                                ],
                                "type": "string"
                              },
                              "metadata": {
                                "additionalProperties": {
                                  "description": "A Common Expression Language (CEL) expression.",
                                  "maxLength": 16384,
                                  "minLength": 1,
                                  "type": "string"
                                },
                                "description": "`metadata` is static or CEL-evaluated context surfaced to the policy\nserver as fields of the `metadata_context` google.protobuf.Struct,\nkeyed by config key. Values are CEL expressions.",
                                "maxProperties": 64,
                                "type": "object"
                              },
                              "url": {
                                "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                                "maxLength": 1024,
                                "minLength": 1,
                                "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                                "type": "string"
                              }
                            },
                            "type": "object",
                            "x-kubernetes-validations": [
                              {
                                "message": "url must not include a path",
                                "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                              },
                              {
                                "message": "exactly one of the fields in [backendRef url] must be set",
                                "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                              }
                            ],
                            "additionalProperties": false
                          }
                        },
                        "required": [
                          "methods"
                        ],
                        "type": "object",
                        "x-kubernetes-validations": [
                          {
                            "message": "exactly one of the fields in [remote] must be set",
                            "rule": "(has(self.remote)?1:0) == 1"
                          }
                        ],
                        "additionalProperties": false
                      },
                      "maxItems": 16,
                      "minItems": 1,
                      "type": "array"
                    }
                  },
                  "required": [
                    "processors"
                  ],
                  "type": "object",
                  "additionalProperties": false
                }
              },
              "type": "object",
              "x-kubernetes-validations": [
                {
                  "message": "at least one of the fields in [authentication authorization guardrails] must be set",
                  "rule": "[has(self.authentication),has(self.authorization),has(self.guardrails)].filter(x,x==true).size() >= 1"
                }
              ],
              "additionalProperties": false
            },
            "sessionAffinity": {
              "description": "Configures best-effort session affinity using an existing request attribute.\nFor AI backends, this applies across the backend's provider groups and must not\nbe configured on an individual provider.",
              "properties": {
                "source": {
                  "description": "CEL expression evaluated against request state. It must return a string or bytes value.\nFor example, `request.headers[\"x-session-id\"]` or `string(source.address)`.",
                  "maxLength": 16384,
                  "minLength": 1,
                  "type": "string"
                }
              },
              "required": [
                "source"
              ],
              "type": "object",
              "additionalProperties": false
            },
            "tcp": {
              "description": "Settings for managing TCP connections to the backend",
              "properties": {
                "connectTimeout": {
                  "description": "Deadline for establishing a connection to\nthe destination.",
                  "maxLength": 32,
                  "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                  "type": "string",
                  "x-kubernetes-validations": [
                    {
                      "message": "connectTimeout must be at least 100ms",
                      "rule": "duration(self) >= duration('100ms')"
                    }
                  ]
                },
                "keepalive": {
                  "description": "Settings for enabling TCP keepalives on the\nconnection.",
                  "properties": {
                    "interval": {
                      "description": "Time between keepalive probes.\nIf unset, this defaults to 180s.",
                      "maxLength": 32,
                      "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                      "type": "string",
                      "x-kubernetes-validations": [
                        {
                          "message": "interval must be at least 1 second",
                          "rule": "duration(self) >= duration('1s')"
                        }
                      ]
                    },
                    "retries": {
                      "description": "Maximum number of keepalive probes to send before dropping the connection.\nIf unset, this defaults to 9.",
                      "format": "int32",
                      "maximum": 64,
                      "minimum": 1,
                      "type": "integer"
                    },
                    "time": {
                      "description": "Time a connection needs to be idle before keepalive probes start being sent.\nIf unset, this defaults to 180s.",
                      "maxLength": 32,
                      "pattern": "^([0-9]{1,5}(h|m|s|ms)){1,4}$",
                      "type": "string",
                      "x-kubernetes-validations": [
                        {
                          "message": "time must be at least 1 second",
                          "rule": "duration(self) >= duration('1s')"
                        }
                      ]
                    }
                  },
                  "type": "object",
                  "additionalProperties": false
                }
              },
              "type": "object",
              "additionalProperties": false
            },
            "tls": {
              "description": "Settings for managing TLS connections to the backend\n\nWhen set, TLS is originated to the backend using the system trusted CA\ncertificates, and SNI is inferred from the destination.",
              "properties": {
                "alpnProtocols": {
                  "description": "Application-Layer Protocol Negotiation (`ALPN`)\nvalue to use in the TLS handshake.\n\nIf not present, defaults to `[\"h2\", \"http/1.1\"]`.",
                  "items": {
                    "maxLength": 64,
                    "minLength": 1,
                    "type": "string"
                  },
                  "maxItems": 16,
                  "minItems": 1,
                  "type": "array"
                },
                "caCertificateRefs": {
                  "description": "CA certificate source to use to verify the server certificate. Omitted kind\nand `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is\nread from the `ca.crt` key unless `key` names a different one. If unset, the\nsystem's trusted certificates are used.",
                  "items": {
                    "description": "LocalCACertificateRef references a same-namespace CA certificate source.\nAn omitted kind defaults to ConfigMap, and an omitted key to `ca.crt`.",
                    "properties": {
                      "key": {
                        "description": "Key within the referenced source holding the PEM-encoded CA bundle.\nOmitted defaults to `ca.crt`.",
                        "maxLength": 253,
                        "minLength": 1,
                        "pattern": "^[A-Za-z0-9]([A-Za-z0-9._-]*[A-Za-z0-9])?$",
                        "type": "string"
                      },
                      "kind": {
                        "description": "Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.",
                        "enum": [
                          "ConfigMap",
                          "Secret"
                        ],
                        "type": "string"
                      },
                      "name": {
                        "description": "Name of the referenced CA certificate source.",
                        "maxLength": 253,
                        "minLength": 1,
                        "type": "string"
                      }
                    },
                    "required": [
                      "name"
                    ],
                    "type": "object",
                    "x-kubernetes-map-type": "atomic",
                    "additionalProperties": false
                  },
                  "maxItems": 1,
                  "type": "array",
                  "x-kubernetes-list-type": "atomic"
                },
                "certificateSource": {
                  "description": "Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).",
                  "enum": [
                    "Inline",
                    "SPIFFE"
                  ],
                  "type": "string"
                },
                "insecureSkipVerify": {
                  "description": "Originates TLS but skips verification of the backend's certificate\nWARNING: insecure; only use if the risks are understood\n\nModes:\n* `All` disables all TLS verification\n* `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches.\n  Still insecure; prefer `verifySubjectAltNames` where possible.",
                  "enum": [
                    "All",
                    "Hostname"
                  ],
                  "type": "string"
                },
                "keyExchangeGroups": {
                  "description": "Ordered list of key exchange groups for a TLS connection.\nFor example: `X25519_MLKEM768,X25519`.",
                  "items": {
                    "enum": [
                      "P-256",
                      "P-384",
                      "X25519",
                      "X25519_MLKEM768"
                    ],
                    "type": "string"
                  },
                  "type": "array"
                },
                "mtlsCertificateRef": {
                  "description": "Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the\nreferenced credential source (defaulting to a Kubernetes `Secret`). An\noptional `ca.cert`, if present, verifies the server certificate, but\n`caCertificateRefs` takes priority. If unspecified, no client certificate\nis used.",
                  "items": {
                    "description": "References a same-namespace credential\nSet only `name` for a Kubernetes Secret",
                    "properties": {
                      "group": {
                        "description": "API group of the referenced credential; empty selects the core API group",
                        "type": "string"
                      },
                      "kind": {
                        "description": "Kind of the referenced credential; empty defaults to `Secret`",
                        "type": "string"
                      },
                      "name": {
                        "description": "Name of the referenced credential",
                        "maxLength": 253,
                        "minLength": 1,
                        "type": "string"
                      }
                    },
                    "required": [
                      "name"
                    ],
                    "type": "object",
                    "x-kubernetes-map-type": "atomic",
                    "x-kubernetes-validations": [
                      {
                        "message": "custom credential refs must set both group and kind",
                        "rule": "(!has(self.group) || size(self.group) == 0) ? (!has(self.kind) || size(self.kind) == 0 || self.kind == 'Secret') : (has(self.kind) && size(self.kind) > 0)"
                      }
                    ],
                    "additionalProperties": false
                  },
                  "maxItems": 1,
                  "type": "array",
                  "x-kubernetes-list-type": "atomic"
                },
                "sni": {
                  "description": "Server Name Indicator (`SNI`) to use in the TLS\nhandshake. If unset, the `SNI` is automatically set based on the\ndestination hostname.",
                  "maxLength": 253,
                  "minLength": 1,
                  "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                  "type": "string"
                },
                "verifySubjectAltNames": {
                  "description": "Subject Alternative Names (`SAN`)\nto verify in the server certificate.\nIf not present, the destination hostname is automatically used.",
                  "items": {
                    "maxLength": 256,
                    "minLength": 1,
                    "type": "string"
                  },
                  "maxItems": 16,
                  "minItems": 1,
                  "type": "array"
                }
              },
              "type": "object",
              "x-kubernetes-validations": [
                {
                  "message": "insecureSkipVerify All and caCertificateRefs may not be set together",
                  "rule": "has(self.insecureSkipVerify) && self.insecureSkipVerify == 'All' ? !has(self.caCertificateRefs) : true"
                },
                {
                  "message": "insecureSkipVerify and verifySubjectAltNames may not be set together",
                  "rule": "has(self.insecureSkipVerify) ? !has(self.verifySubjectAltNames) : true"
                },
                {
                  "message": "certificateSource SPIFFE may not be combined with mtlsCertificateRef, caCertificateRefs, or insecureSkipVerify",
                  "rule": "!has(self.certificateSource) || self.certificateSource != 'SPIFFE' || (!has(self.mtlsCertificateRef) && !has(self.caCertificateRefs) && !has(self.insecureSkipVerify))"
                },
                {
                  "message": "at most one of the fields in [verifySubjectAltNames insecureSkipVerify] may be set",
                  "rule": "(has(self.verifySubjectAltNames)?1:0)+(has(self.insecureSkipVerify)?1:0) <= 1"
                }
              ],
              "additionalProperties": false
            },
            "transformation": {
              "description": "Mutates and transforms requests and responses sent to and from the backend.",
              "properties": {
                "request": {
                  "description": "Request transformation settings.",
                  "properties": {
                    "add": {
                      "description": "Headers to add to the request and what each value\nshould be set to. If there is already a header with these values then\nappend the value as an extra entry.",
                      "items": {
                        "properties": {
                          "name": {
                            "description": "The name of the header to add.",
                            "maxLength": 256,
                            "minLength": 1,
                            "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                            "type": "string",
                            "x-kubernetes-validations": [
                              {
                                "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                              }
                            ]
                          },
                          "value": {
                            "description": "CEL expression that generates the output value for\nthe header.",
                            "maxLength": 16384,
                            "minLength": 1,
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "value"
                        ],
                        "type": "object",
                        "additionalProperties": false
                      },
                      "maxItems": 16,
                      "minItems": 1,
                      "type": "array",
                      "x-kubernetes-list-map-keys": [
                        "name"
                      ],
                      "x-kubernetes-list-type": "map"
                    },
                    "body": {
                      "description": "HTTP body transformation.",
                      "maxLength": 16384,
                      "minLength": 1,
                      "type": "string"
                    },
                    "metadata": {
                      "additionalProperties": {
                        "description": "A Common Expression Language (CEL) expression.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "description": "Stores CEL-evaluated values under the `metadata` CEL variable\nfor subsequent policy evaluations. `metadata` is evaluated before header\nor body transformations.",
                      "maxProperties": 16,
                      "minProperties": 1,
                      "type": "object"
                    },
                    "remove": {
                      "description": "Header names to remove from the request or\nresponse.",
                      "items": {
                        "description": "HTTP header name.",
                        "maxLength": 256,
                        "minLength": 1,
                        "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                        "type": "string",
                        "x-kubernetes-validations": [
                          {
                            "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                            "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                          }
                        ]
                      },
                      "maxItems": 16,
                      "minItems": 1,
                      "type": "array",
                      "x-kubernetes-list-type": "set"
                    },
                    "set": {
                      "description": "Headers to set and the values to use.",
                      "items": {
                        "properties": {
                          "name": {
                            "description": "The name of the header to add.",
                            "maxLength": 256,
                            "minLength": 1,
                            "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                            "type": "string",
                            "x-kubernetes-validations": [
                              {
                                "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                              }
                            ]
                          },
                          "value": {
                            "description": "CEL expression that generates the output value for\nthe header.",
                            "maxLength": 16384,
                            "minLength": 1,
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "value"
                        ],
                        "type": "object",
                        "additionalProperties": false
                      },
                      "maxItems": 16,
                      "minItems": 1,
                      "type": "array",
                      "x-kubernetes-list-map-keys": [
                        "name"
                      ],
                      "x-kubernetes-list-type": "map"
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "at least one of the fields in [add body metadata remove set] must be set",
                      "rule": "[has(self.add),has(self.body),has(self.metadata),has(self.remove),has(self.set)].filter(x,x==true).size() >= 1"
                    }
                  ],
                  "additionalProperties": false
                },
                "response": {
                  "description": "Response transformation settings.",
                  "properties": {
                    "add": {
                      "description": "Headers to add to the request and what each value\nshould be set to. If there is already a header with these values then\nappend the value as an extra entry.",
                      "items": {
                        "properties": {
                          "name": {
                            "description": "The name of the header to add.",
                            "maxLength": 256,
                            "minLength": 1,
                            "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                            "type": "string",
                            "x-kubernetes-validations": [
                              {
                                "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                              }
                            ]
                          },
                          "value": {
                            "description": "CEL expression that generates the output value for\nthe header.",
                            "maxLength": 16384,
                            "minLength": 1,
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "value"
                        ],
                        "type": "object",
                        "additionalProperties": false
                      },
                      "maxItems": 16,
                      "minItems": 1,
                      "type": "array",
                      "x-kubernetes-list-map-keys": [
                        "name"
                      ],
                      "x-kubernetes-list-type": "map"
                    },
                    "body": {
                      "description": "HTTP body transformation.",
                      "maxLength": 16384,
                      "minLength": 1,
                      "type": "string"
                    },
                    "metadata": {
                      "additionalProperties": {
                        "description": "A Common Expression Language (CEL) expression.",
                        "maxLength": 16384,
                        "minLength": 1,
                        "type": "string"
                      },
                      "description": "Stores CEL-evaluated values under the `metadata` CEL variable\nfor subsequent policy evaluations. `metadata` is evaluated before header\nor body transformations.",
                      "maxProperties": 16,
                      "minProperties": 1,
                      "type": "object"
                    },
                    "remove": {
                      "description": "Header names to remove from the request or\nresponse.",
                      "items": {
                        "description": "HTTP header name.",
                        "maxLength": 256,
                        "minLength": 1,
                        "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                        "type": "string",
                        "x-kubernetes-validations": [
                          {
                            "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                            "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                          }
                        ]
                      },
                      "maxItems": 16,
                      "minItems": 1,
                      "type": "array",
                      "x-kubernetes-list-type": "set"
                    },
                    "set": {
                      "description": "Headers to set and the values to use.",
                      "items": {
                        "properties": {
                          "name": {
                            "description": "The name of the header to add.",
                            "maxLength": 256,
                            "minLength": 1,
                            "pattern": "^:?[A-Za-z0-9!#$%&'*+\\-.^_\\x60|~]+$",
                            "type": "string",
                            "x-kubernetes-validations": [
                              {
                                "message": "pseudo-headers must be one of :authority, :method, :path, :scheme, or :status",
                                "rule": "!self.startsWith(':') || self in [':authority', ':method', ':path', ':scheme', ':status']"
                              }
                            ]
                          },
                          "value": {
                            "description": "CEL expression that generates the output value for\nthe header.",
                            "maxLength": 16384,
                            "minLength": 1,
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "value"
                        ],
                        "type": "object",
                        "additionalProperties": false
                      },
                      "maxItems": 16,
                      "minItems": 1,
                      "type": "array",
                      "x-kubernetes-list-map-keys": [
                        "name"
                      ],
                      "x-kubernetes-list-type": "map"
                    }
                  },
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "at least one of the fields in [add body metadata remove set] must be set",
                      "rule": "[has(self.add),has(self.body),has(self.metadata),has(self.remove),has(self.set)].filter(x,x==true).size() >= 1"
                    }
                  ],
                  "additionalProperties": false
                }
              },
              "type": "object",
              "x-kubernetes-validations": [
                {
                  "message": "at least one of the fields in [request response] must be set",
                  "rule": "[has(self.request),has(self.response)].filter(x,x==true).size() >= 1"
                }
              ],
              "additionalProperties": false
            },
            "tunnel": {
              "description": "Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`",
              "properties": {
                "backendRef": {
                  "description": "`backendRef` selects a backend for this policy.\nMutually exclusive with `url`.",
                  "properties": {
                    "group": {
                      "default": "",
                      "description": "Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group",
                      "maxLength": 253,
                      "pattern": "^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$",
                      "type": "string"
                    },
                    "kind": {
                      "default": "Service",
                      "description": "Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`",
                      "maxLength": 63,
                      "minLength": 1,
                      "pattern": "^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$",
                      "type": "string"
                    },
                    "name": {
                      "description": "Name is the name of the referent.",
                      "maxLength": 253,
                      "minLength": 1,
                      "type": "string"
                    },
                    "namespace": {
                      "description": "Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace",
                      "maxLength": 63,
                      "minLength": 1,
                      "pattern": "^[a-z0-9]([-a-z0-9]*[a-z0-9])?$",
                      "type": "string"
                    },
                    "port": {
                      "description": "Destination port number. Required when the referent is a Kubernetes `Service`",
                      "format": "int32",
                      "maximum": 65535,
                      "minimum": 1,
                      "type": "integer"
                    }
                  },
                  "required": [
                    "name"
                  ],
                  "type": "object",
                  "x-kubernetes-validations": [
                    {
                      "message": "Must have port for Service reference",
                      "rule": "(size(self.group) == 0 && self.kind == 'Service') ? has(self.port) : true"
                    }
                  ],
                  "additionalProperties": false
                },
                "mode": {
                  "description": "How requests are sent through the proxy.\nDefaults to `Auto`.",
                  "enum": [
                    "Auto",
                    "Connect"
                  ],
                  "type": "string"
                },
                "url": {
                  "description": "`url` directly specifies the HTTP(S) endpoint for this policy.\nWhen the scheme is `https`, backend TLS is enabled automatically.\nMutually exclusive with `backendRef`.\nURLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local`\nwill not apply Service policies or load balancing.",
                  "maxLength": 1024,
                  "minLength": 1,
                  "pattern": "^https?://[^/?#@]+(/[^?#]*)?$",
                  "type": "string"
                }
              },
              "type": "object",
              "x-kubernetes-validations": [
                {
                  "message": "exactly one of the fields in [backendRef url] must be set",
                  "rule": "(has(self.backendRef)?1:0)+(has(self.url)?1:0) == 1"
                },
                {
                  "message": "url must not include a path for backend tunnel",
                  "rule": "!has(self.url) || self.url.matches('^https?://[^/?#]+$')"
                }
              ],
              "additionalProperties": false
            }
          },
          "type": "object",
          "x-kubernetes-validations": [
            {
              "message": "at least one of the fields in [ai auth authorization extAuth health http mcp sessionAffinity tcp tls transformation tunnel] must be set",
              "rule": "[has(self.ai),has(self.auth),has(self.authorization),has(self.extAuth),has(self.health),has(self.http),has(self.mcp),has(self.sessionAffinity),has(self.tcp),has(self.tls),has(self.transformation),has(self.tunnel)].filter(x,x==true).size() >= 1"
            }
          ],
          "additionalProperties": false
        },
        "static": {
          "description": "Static hostname, IP address, or Unix Domain Socket backend.",
          "properties": {
            "host": {
              "description": "Host to connect to for TCP backends.",
              "maxLength": 256,
              "minLength": 1,
              "type": "string"
            },
            "port": {
              "description": "Port to connect to for TCP backends.",
              "format": "int32",
              "maximum": 65535,
              "minimum": 1,
              "type": "integer"
            },
            "unixPath": {
              "description": "Filesystem path to a Unix Domain Socket. The gateway pod\nmust share a volume with the target (e.g., via emptyDir sidecar pattern).\nMutually exclusive with host/port.",
              "minLength": 1,
              "type": "string"
            }
          },
          "type": "object",
          "x-kubernetes-validations": [
            {
              "message": "must specify either unixPath or both host and port",
              "rule": "has(self.unixPath) || (has(self.host) && has(self.port))"
            },
            {
              "message": "unixPath and host/port are mutually exclusive",
              "rule": "!has(self.unixPath) || (!has(self.host) && !has(self.port))"
            }
          ],
          "additionalProperties": false
        }
      },
      "type": "object",
      "x-kubernetes-validations": [
        {
          "message": "AI policies require AI backend",
          "rule": "has(self.policies) && has(self.policies.ai) ? has(self.ai) : true"
        },
        {
          "message": "MCP policies require MCP backend",
          "rule": "has(self.policies) && has(self.policies.mcp) ? has(self.mcp) : true"
        },
        {
          "message": "exactly one of the fields in [ai static dynamicForwardProxy mcp aws a2a] must be set",
          "rule": "(has(self.ai)?1:0)+(has(self.static)?1:0)+(has(self.dynamicForwardProxy)?1:0)+(has(self.mcp)?1:0)+(has(self.aws)?1:0)+(has(self.a2a)?1:0) == 1"
        }
      ],
      "additionalProperties": false
    },
    "status": {
      "description": "Current backend status.",
      "properties": {
        "conditions": {
          "description": "Current condition state for the backend.",
          "items": {
            "description": "Condition contains details for one aspect of the current state of this API Resource.",
            "properties": {
              "lastTransitionTime": {
                "description": "lastTransitionTime is the last time the condition transitioned from one status to another.\nThis should be when the underlying condition changed.  If that is not known, then using the time when the API field changed is acceptable.",
                "format": "date-time",
                "type": "string"
              },
              "message": {
                "description": "message is a human readable message indicating details about the transition.\nThis may be an empty string.",
                "maxLength": 32768,
                "type": "string"
              },
              "observedGeneration": {
                "description": "observedGeneration represents the .metadata.generation that the condition was set based upon.\nFor instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date\nwith respect to the current state of the instance.",
                "format": "int64",
                "minimum": 0,
                "type": "integer"
              },
              "reason": {
                "description": "reason contains a programmatic identifier indicating the reason for the condition's last transition.\nProducers of specific condition types may define expected values and meanings for this field,\nand whether the values are considered a guaranteed API.\nThe value should be a CamelCase string.\nThis field may not be empty.",
                "maxLength": 1024,
                "minLength": 1,
                "pattern": "^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$",
                "type": "string"
              },
              "status": {
                "description": "status of the condition, one of True, False, Unknown.",
                "enum": [
                  "True",
                  "False",
                  "Unknown"
                ],
                "type": "string"
              },
              "type": {
                "description": "type of condition in CamelCase or in foo.example.com/CamelCase.",
                "maxLength": 316,
                "pattern": "^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$",
                "type": "string"
              }
            },
            "required": [
              "lastTransitionTime",
              "message",
              "reason",
              "status",
              "type"
            ],
            "type": "object",
            "additionalProperties": false
          },
          "maxItems": 8,
          "type": "array",
          "x-kubernetes-list-map-keys": [
            "type"
          ],
          "x-kubernetes-list-type": "map"
        }
      },
      "type": "object",
      "additionalProperties": false
    }
  },
  "required": [
    "spec"
  ],
  "type": "object"
}
