Last changed in Agentgateway v1.6.0
APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Desired backend configuration.
A2A backend.
Hostname or IP address of the A2A backend.
Port number of the A2A backend.
LLM backend.
Groups in priority order, where each group defines a set of LLM providers. The priority determines the priority of the backend endpoints chosen. Note: provider names must be unique across all providers in all priority groups. Backend policies may target a specific provider by name using `targetRefs[].sectionName`. Example configuration with two priority groups: groups: - providers: - azureopenai: deploymentName: gpt-4o-mini apiVersion: 2024-02-15-preview endpoint: ai-gateway.openai.azure.com - providers: - azureopenai: deploymentName: gpt-4o-mini-2 apiVersion: 2024-02-15-preview endpoint: ai-gateway-2.openai.azure.com policies: auth: secretRef: name: azure-secret
LLM providers within this group. Each provider is treated equally in terms of priority, with automatic weighting based on health.
Anthropic provider settings.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
Azure provider with resource-based configuration. Supports both Azure OpenAI and Azure AI Foundry resource types.
The version of the Azure OpenAI API to use. If unset, defaults to `v1`.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
The Foundry project name, required when `resourceType` is `Foundry`. Used to construct paths: /api/projects/{projectName}/openai/v1/...
The Azure resource name used to construct the endpoint host. For OpenAI: {resourceName}.openai.azure.com For Foundry: {resourceName}.services.ai.azure.com Note: when the Azure portal "Foundry legacy" template was used, the generated resource name may end in "-resource" (e.g. "myproject-resource"); that suffix is part of the resource name as the user configured it, not part of the hostname suffix agentgateway should append.
The type of Azure endpoint. Determines the host suffix.
Azure OpenAI provider settings.
The version of the Azure OpenAI API to use. For more information, see the [Azure OpenAI API version reference](https://learn.microsoft.com/en-us/azure/foundry/openai/reference). If unset, defaults to `v1`.
The name of the Azure OpenAI model deployment to use. For 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). This is required if `apiVersion` is not `v1`. For `v1`, the model can be set in the request.
The endpoint for the Azure OpenAI API to use, such as `my-endpoint.openai.azure.com`. If the scheme is included, it is stripped.
Bedrock provider settings.
EndpointPreference selects which Bedrock API surface to prefer. Defaults to `RuntimePreferred`, preferring runtime over mantle. Decides which endpoint to pick mainly based on the catalog tags `mantle` and `runtime`.
Guardrail policy to use for the backend. See <https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html>. If not specified, the AWS Guardrail policy will not be used.
Identifier of the Guardrail policy to use for the backend.
Version of the Guardrail policy to use for the backend.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
AWS region to use for the backend. Defaults to `us-east-1` if not specified.
Custom provider configures a non-managed or self-hosted LLM provider. Use this when the provider target and API formats should be declared explicitly instead of inferred from a managed provider such as OpenAI or Anthropic.
Kubernetes backend that serves this provider. `backendRef` may target only a namespace-local Service or InferencePool. If unset, host and port must be set on the parent provider.
API group of the referenced resource. For example, `gateway.networking.k8s.io`. Defaults to the empty string, which identifies the core API group.
Kind of the referenced resource. For example, `Service`. Defaults to "Service" when not specified.
Name of the referenced resource.
Destination port number to use for this resource. Required when the referenced resource is a Kubernetes Service.
Provider-native API formats this provider supports.
Default upstream path override for this format. If unset, agentgateway uses the default path for the format.
Provider-native API format.
Model name override, such as `gpt-oss`. If unset, the model name is taken from the request.
Provider identity used for cost-catalog lookup and telemetry. Defaults to "custom" when unset.
Gemini provider settings.
Model name override, such as `gemini-2.5-pro`. If unset, the model name is taken from the request.
Hostname to send requests to. For custom providers without backendRef, host and port specify the target. For managed providers, host and port override the provider default.
Name of the provider. Policies can target this provider by name.
OpenAI provider settings.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
Inline moderation configuration to inject into OpenAI chat completions and responses requests. If unset, the OpenAI inline moderation parameter is not injected.
The moderation model to use, such as `omni-moderation-latest`. Defaults to `omni-moderation-latest` if not specified.
Policies to apply to request input and generated output.
Policy for request input moderation.
Mode controls whether moderation only returns scores or blocks flagged content.
Policy for generated output moderation.
Mode controls whether moderation only returns scores or blocks flagged content.
URL path to use for LLM provider API requests. This is useful when you need to route requests to a different API endpoint while maintaining compatibility with the original provider's API structure. If not specified, the default path for the provider is used.
Overrides the default base path prefix, such as `/v1`, for upstream requests. Path translation for cross-format requests still applies using this prefix. Only supported for OpenAI and Anthropic providers.
Policies for communicating with this backend. Policies may also be set in `AgentgatewayPolicy`, or in the top-level `AgentgatewayBackend`. Policies are merged on a field-level basis, with order: `AgentgatewayPolicy` < `AgentgatewayBackend` < `AgentgatewayBackend` LLM provider (this field).
Settings for AI workloads. This is only applicable when connecting to a `Backend` of type `ai`.
Defaults to merge with user input fields. If the field is already set, the field in the request is used.
Name of the field.
Default value for the field. This can be any JSON data type.
CEL transformations to compute and set fields in the request body. The expression result overwrites any existing value for that field. This has a higher priority than `overrides` if both are set for the same key. Those transformations are applied after the request is converted to the provider's format, so they can be used to set provider-specific fields.
CEL expression used to compute the field value.
Name of the field to set.
Maps friendly model names to actual provider model names. Example: `{"fast": "gpt-3.5-turbo", "smart": "gpt-4-turbo"}`. Note: This field is only applicable when using the agentgateway data plane.
Overrides to merge with user input fields. If the field is already set, the field is overwritten.
Name of the field.
Default value for the field. This can be any JSON data type.
Enriches requests sent to the LLM provider by appending and prepending system prompts. This can be configured only for LLM providers that use the `CHAT` or `CHAT_STREAMING` API route type.
Messages to append to the prompt sent by the client.
String content of the message.
Role of the message. The available roles depend on the backend LLM provider model, such as `SYSTEM` or `USER` in the OpenAI API.
Messages to prepend to the prompt sent by the client.
String content of the message.
Role of the message. The available roles depend on the backend LLM provider model, such as `SYSTEM` or `USER` in the OpenAI API.
Automatic prompt caching for supported providers, currently AWS Bedrock. Reduces API costs by caching static content like system prompts and tool definitions. Only applicable for Bedrock Claude 3+ and Nova models.
Shifts the message cache point further back in the conversation. 0 (default) places it at the second-to-last message. Higher values move it N additional messages towards the start, clamped to bounds.
Enables caching for conversation messages. Defaults to true. Caches all messages in the conversation for cost savings.
Enables caching for system prompts. Defaults to true. Inserts a cache point after all system messages.
Enables caching for tool definitions. Defaults to false. Inserts a cache point after all tool specifications.
Minimum estimated token count before caching is enabled. Uses rough heuristic (word count × 1.3) to estimate tokens. Defaults to 1024. Bedrock requires at least 1,024 tokens for caching to be effective.
Guardrails for LLM requests and responses.
Prompt guards to apply to requests sent by the client.
AWS Bedrock Guardrails settings for prompt guarding.
Action controls whether the guardrail's verdict is enforced or only observed. `Reject` (the default) enforces the guardrail: a blocked assessment rejects the request/response and an anonymized assessment masks the matched content. `Audit` runs the guardrail in observe mode: it is invoked and its assessment recorded (metrics + structured log), but the request/response is never blocked or masked.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Identifier of the Guardrail policy to use for the backend.
Policies for communicating with AWS Bedrock Guardrails.
Settings for authenticating to AWS Bedrock Guardrails.
AWS authentication method for Bedrock Guardrails. Use `aws: {}` for default AWS SDK credential discovery.
AWS STS AssumeRole settings to use before signing backend requests. Ambient AWS credentials are used as the source credentials for STS.
ExternalID is set when the role's trust policy requires sts:ExternalId.
AWS IAM role ARN to assume.
SessionName is a custom session name (RoleSessionName) for CloudTrail and Cost & Usage Report attribution. If unset, AWS generates a random name.
SessionNameExpression is a CEL expression evaluated against each request to produce the session name (RoleSessionName), for example `jwt.sub` or `request.headers["x-team"]`. If the expression does not produce a valid session name at request time, the request is rejected.
Session tags passed to STS AssumeRole for cost attribution in the AWS Cost & Usage Report, once activated. STS allows at most 50 per role session.
CEL expression evaluated against each request to produce the tag value, for example `jwt.sub` or `request.headers["x-app"]`. Requests with invalid tag values are rejected.
Key is the tag key.
Value is a static tag value.
AWS SigV4 signing region, for example `us-east-1`. Set this when the target AWS service is in a different region than the gateway. If unset, typed AWS backends may provide this automatically; otherwise the ambient AWS region is used.
Credential source for AWS credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `accessKey`, `secretKey`, and optional `sessionToken` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
AWS SigV4 signing service name, for example `bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS backends may provide this automatically.
Inline API key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where API keys are inserted. Defaults to the `Authorization` header with the `Bearer ` prefix. Applies to `key` and `secretRef`.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Credential source for the API key, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
AWS region where the guardrail is deployed, for example `us-west-2`).
Version of the Guardrail policy to use for the backend.
Google Model Armor settings for prompt guarding.
Action controls whether flagged content is rejected or only observed. `Reject` (the default) rejects flagged content; `Audit` records the would-be rejection without blocking.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Google Cloud location, for example `us-central1`. Defaults to `us-central1` if not specified.
Policies for communicating with Google Model Armor.
Settings for authenticating to Google Model Armor.
Google authentication method for Model Armor. Use `gcp: {}` for default Google credential discovery.
Explicit `aud` value for the ID token. Only valid with `IdToken` type. If not set, the `aud` is automatically derived from the backend hostname.
Credential source for ADC-compatible Google credential JSON, defaulting to a Kubernetes `Secret`. By default, the value is read from `credentials.json`; set `secretRef.key` to override it. When omitted, ambient credentials are used.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
The type of token to generate. To authenticate to GCP services, generally an `AccessToken` is used. To authenticate to Cloud Run, an `IdToken` is used.
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Google Cloud project ID.
Template ID for Google Model Armor.
Passes prompt data through the OpenAI Moderations endpoint. See https://developers.openai.com/api/reference/resources/moderations for more information.
Action controls whether flagged content is rejected or only observed. `Reject` (the default) rejects flagged content; `Audit` records the would-be rejection without blocking.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Moderation model to use. For example, `omni-moderation`.
Policies for communicating with OpenAI.
Settings for authenticating to OpenAI.
Inline key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where backend credentials are inserted. Defaults to the `Authorization` header with the `Bearer ` prefix. Applies to `key` and `secretRef`.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Credential source for the authorization value, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Regular expression (regex) matching for prompt guards and data masking.
The action to take if a regex pattern is matched in a request or response. The action applies to request and response matches alike. Note that `Mask` is not applied to streamed responses: matched content in a streamed response is passed through unmodified. Defaults to `Mask`.
Built-in regex patterns to match against the request or response. Matches and built-ins are additive.
Regex patterns to match against the request or response. Matches and built-ins are additive.
Custom response message to return to the client. If not specified, defaults to `The request was rejected due to inappropriate content`.
Custom response message to return to the client. If not specified, defaults to `The request was rejected due to inappropriate content`.
Status code to return to the client. Defaults to 403.
Which parts of the request this guard inspects. When unset, defaults to `SystemPrompt` and `Messages`. Tool call inputs and outputs are not inspected unless `ToolInput`/`ToolOutput` are listed explicitly. In APIs that send tool arguments as opaque JSON, such as Completions, the arguments are masked as a single string, meaning a prompt guard has the potential to rewrite the arguments into invalid JSON.
Webhook that receives requests for prompt guarding.
Action controls whether the webhook's verdict is enforced or only observed. `Reject` (the default) enforces it; `Audit` records the would-be action without blocking or masking.
Webhook server to reach. Supported types: Service and Backend.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Behavior when the webhook guardrail is unavailable or returns an error. `FailOpen` allows the request to continue. `FailClosed` (default) rejects the request.
HTTP header matches used to select the headers to forward to the webhook. Request headers are used when forwarding requests and response headers are used when forwarding responses. By default, no headers are forwarded.
Name of the HTTP header to match, case-insensitive. When names are equivalent, only the first matching entry is used
How to match against the header value: `Exact` (default) or `RegularExpression`. The regex dialect is implementation-specific
Value of the HTTP header to match
CEL-computed headers to include in webhook requests.
Prompt guards to apply to responses returned by the LLM provider.
AWS Bedrock Guardrails settings for prompt guarding.
Action controls whether the guardrail's verdict is enforced or only observed. `Reject` (the default) enforces the guardrail: a blocked assessment rejects the request/response and an anonymized assessment masks the matched content. `Audit` runs the guardrail in observe mode: it is invoked and its assessment recorded (metrics + structured log), but the request/response is never blocked or masked.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Identifier of the Guardrail policy to use for the backend.
Policies for communicating with AWS Bedrock Guardrails.
Settings for authenticating to AWS Bedrock Guardrails.
AWS authentication method for Bedrock Guardrails. Use `aws: {}` for default AWS SDK credential discovery.
AWS STS AssumeRole settings to use before signing backend requests. Ambient AWS credentials are used as the source credentials for STS.
ExternalID is set when the role's trust policy requires sts:ExternalId.
AWS IAM role ARN to assume.
SessionName is a custom session name (RoleSessionName) for CloudTrail and Cost & Usage Report attribution. If unset, AWS generates a random name.
SessionNameExpression is a CEL expression evaluated against each request to produce the session name (RoleSessionName), for example `jwt.sub` or `request.headers["x-team"]`. If the expression does not produce a valid session name at request time, the request is rejected.
Session tags passed to STS AssumeRole for cost attribution in the AWS Cost & Usage Report, once activated. STS allows at most 50 per role session.
CEL expression evaluated against each request to produce the tag value, for example `jwt.sub` or `request.headers["x-app"]`. Requests with invalid tag values are rejected.
Key is the tag key.
Value is a static tag value.
AWS SigV4 signing region, for example `us-east-1`. Set this when the target AWS service is in a different region than the gateway. If unset, typed AWS backends may provide this automatically; otherwise the ambient AWS region is used.
Credential source for AWS credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `accessKey`, `secretKey`, and optional `sessionToken` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
AWS SigV4 signing service name, for example `bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS backends may provide this automatically.
Inline API key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where API keys are inserted. Defaults to the `Authorization` header with the `Bearer ` prefix. Applies to `key` and `secretRef`.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Credential source for the API key, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
AWS region where the guardrail is deployed, for example `us-west-2`).
Version of the Guardrail policy to use for the backend.
Google Model Armor settings for prompt guarding.
Action controls whether flagged content is rejected or only observed. `Reject` (the default) rejects flagged content; `Audit` records the would-be rejection without blocking.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Google Cloud location, for example `us-central1`. Defaults to `us-central1` if not specified.
Policies for communicating with Google Model Armor.
Settings for authenticating to Google Model Armor.
Google authentication method for Model Armor. Use `gcp: {}` for default Google credential discovery.
Explicit `aud` value for the ID token. Only valid with `IdToken` type. If not set, the `aud` is automatically derived from the backend hostname.
Credential source for ADC-compatible Google credential JSON, defaulting to a Kubernetes `Secret`. By default, the value is read from `credentials.json`; set `secretRef.key` to override it. When omitted, ambient credentials are used.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
The type of token to generate. To authenticate to GCP services, generally an `AccessToken` is used. To authenticate to Cloud Run, an `IdToken` is used.
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Google Cloud project ID.
Template ID for Google Model Armor.
Regular expression (regex) matching for prompt guards and data masking.
The action to take if a regex pattern is matched in a request or response. The action applies to request and response matches alike. Note that `Mask` is not applied to streamed responses: matched content in a streamed response is passed through unmodified. Defaults to `Mask`.
Built-in regex patterns to match against the request or response. Matches and built-ins are additive.
Regex patterns to match against the request or response. Matches and built-ins are additive.
Custom response message to return to the client. If not specified, defaults to `The response was rejected due to inappropriate content`.
Custom response message to return to the client. If not specified, defaults to `The request was rejected due to inappropriate content`.
Status code to return to the client. Defaults to 403.
Webhook that receives responses for prompt guarding.
Action controls whether the webhook's verdict is enforced or only observed. `Reject` (the default) enforces it; `Audit` records the would-be action without blocking or masking.
Webhook server to reach. Supported types: Service and Backend.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Behavior when the webhook guardrail is unavailable or returns an error. `FailOpen` allows the request to continue. `FailClosed` (default) rejects the request.
HTTP header matches used to select the headers to forward to the webhook. Request headers are used when forwarding requests and response headers are used when forwarding responses. By default, no headers are forwarded.
Name of the HTTP header to match, case-insensitive. When names are equivalent, only the first matching entry is used
How to match against the header value: `Exact` (default) or `RegularExpression`. The regex dialect is implementation-specific
Value of the HTTP header to match
CEL-computed headers to include in webhook requests.
Apply prompt guards to streaming responses and realtime websocket messages. Defaults to disabled to preserve streaming throughput unless explicitly enabled.
Rules for identifying the type of traffic to handle. The keys are URL path suffixes matched using ends-with comparison, for example `"/v1/chat/completions"`. The special `*` wildcard matches any path. If not specified, all traffic defaults to `completions` type.
CEL transformations to compute and set fields in the request body. The expression result overwrites any existing value for that field. This has a higher priority than `overrides` if both are set for the same key.
CEL expression used to compute the field value.
Name of the field to set.
Settings for managing authentication to the backend
Explicit AWS authentication method for the backend. When omitted, default AWS SDK credential discovery is used.
AWS STS AssumeRole settings to use before signing backend requests. Ambient AWS credentials are used as the source credentials for STS.
ExternalID is set when the role's trust policy requires sts:ExternalId.
AWS IAM role ARN to assume.
SessionName is a custom session name (RoleSessionName) for CloudTrail and Cost & Usage Report attribution. If unset, AWS generates a random name.
SessionNameExpression is a CEL expression evaluated against each request to produce the session name (RoleSessionName), for example `jwt.sub` or `request.headers["x-team"]`. If the expression does not produce a valid session name at request time, the request is rejected.
Session tags passed to STS AssumeRole for cost attribution in the AWS Cost & Usage Report, once activated. STS allows at most 50 per role session.
CEL expression evaluated against each request to produce the tag value, for example `jwt.sub` or `request.headers["x-app"]`. Requests with invalid tag values are rejected.
Key is the tag key.
Value is a static tag value.
AWS SigV4 signing region, for example `us-east-1`. Set this when the target AWS service is in a different region than the gateway. If unset, typed AWS backends may provide this automatically; otherwise the ambient AWS region is used.
Credential source for AWS credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `accessKey`, `secretKey`, and optional `sessionToken` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
AWS SigV4 signing service name, for example `bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS backends may provide this automatically.
Azure authentication method for the backend.
Managed identity authentication settings. Leave this object empty to use the system-assigned identity. To use a user-assigned identity, set one of `clientId`, `objectId`, or `resourceId`.
Client ID of the user-assigned managed identity.
Object ID of the user-assigned managed identity.
Resource ID of the user-assigned managed identity.
Scopes requested for the Azure access token. When omitted, the scope is inferred from the backend hostname. Managed Identity supports exactly one scope.
Credential source for Azure credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `clientID`, `tenantID`, and `clientSecret` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Workload identity authentication settings. Uses the federated token and Azure env vars projected into the data plane pod. Recommended on AKS with Workload Identity enabled.
Credentials is a list of additional credentials to inject on the backend request. Each entry resolves a Secret key and writes its value to the entry's location. `credentials` is independent of the primary `key`/`secretRef`/`passthrough` mechanism and may be set on its own or alongside it.
Where the credential is inserted on the backend request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
SecretRef references a Kubernetes Secret holding the credential value, and optionally overrides the key read from it. Defaults to `Authorization`, matching the key convention used by the top-level `secretRef`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Cross App Access (Identity Assertion / ID-JAG) authentication.
Scopes requested when exchanging the ID-JAG for an access token. When omitted, defaults to Scopes. Set to an empty list to omit scope.
Identifier of the resource authorization server. The issued ID-JAG is bound to this audience.
Response cache configuration.
TTL used when the token endpoint omits expires_in. Default 300s.
Default 8192; 0 disables the cache.
User identity provider authorization server, used for the RFC 8693 ID-JAG exchange.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Client authentication for the token endpoint.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token endpoint path; defaults to "/". Must start with "/".
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Resource authorization server, used for the RFC 7523 jwt-bearer exchange.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Client authentication for the token endpoint.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token endpoint path; defaults to "/". Must start with "/".
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Resources sent to the token endpoint.
Scopes requested when obtaining the ID-JAG from the identity provider.
Subject token sent to the identity provider. Defaults to an OpenID Connect ID token read from the Authorization Bearer header.
Where to read the subject token. Defaults to the Authorization Bearer header.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth RFC 8693 subject token type. Defaults to IdToken
Google authentication method for the backend. When omitted, default Google credential discovery is used.
Explicit `aud` value for the ID token. Only valid with `IdToken` type. If not set, the `aud` is automatically derived from the backend hostname.
Credential source for ADC-compatible Google credential JSON, defaulting to a Kubernetes `Secret`. By default, the value is read from `credentials.json`; set `secretRef.key` to override it. When omitted, ambient credentials are used.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
The type of token to generate. To authenticate to GCP services, generally an `AccessToken` is used. To authenticate to Cloud Run, an `IdToken` is used.
Signs a short-lived JWT with a private key on each request and sends it to the backend, for upstreams that require per-request keypair JWTs (e.g. the Snowflake SQL API) rather than a static credential.
JWS signing algorithm. Defaults to RS256.
Static claims added to every token (e.g. iss, sub, aud). Values may be any JSON value (e.g. a string, number, bool, or array). iat, exp, and nbf are reserved for the signer and cannot be configured here; the controller rejects them at translation time.
Optional JWS key ID header.
Where the signed token is written on the backend request. Defaults to the Authorization header with a "Bearer " prefix.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Secret providing the `signingKey` key with a PEM-encoded RSA or EC private key.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token lifetime used for exp. Defaults to 300s.
Inline key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where backend credentials are inserted. If omitted, credentials are written to the `Authorization` header with the `Bearer ` prefix. This applies to `key`, `secretRef`, and `passthrough`. Entries in `credentials` carry their own location.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth 2.0 token exchange (RFC 8693) / jwt-bearer (RFC 7523) authentication.
RFC 8693 delegation actor token. TokenExchange grant only.
may_act claim validation mode. When omitted, may_act is not enforced.
Where to read the actor token. Actor tokens have no default source.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth token type. Empty defaults to AccessToken. Custom absolute URI values are supported for actor tokens.
Extra form params; values are CEL expressions over the incoming request.
Audiences sent to the token endpoint.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Response cache configuration.
TTL used when the token endpoint omits expires_in. Default 300s.
Default 8192; 0 disables the cache.
Client authentication for the token endpoint. When unset, none is sent.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
RFC followed by the request. Defaults to TokenExchange (RFC 8693).
Where the exchanged token is written to the backend request. Defaults to Authorization: Bearer.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Token endpoint path; defaults to "/". Must start with "/".
RFC 8693 requested_token_type. Unlike subject/actor token types, only the built-in values may be requested; custom URIs are not supported here.
Resources sent to the token endpoint.
Scopes sent to the token endpoint.
Subject token / assertion source and type. Defaults to Authorization Bearer, AccessToken. The token type may be a built-in value or a custom absolute URI for providers that support custom token exchange profiles.
Where to read the token. CEL `expression` variant is permitted.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth token type. Empty defaults to AccessToken. Custom absolute URI values are supported for subject tokens.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Reuses a client token already validated by another policy. Those policies may strip client credentials; passthrough adds the original token back to the backend request. Without client auth policies, this has no effect.
Credential source for the authorization value, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Authorization rules that clients must satisfy after this AI provider is selected.
The effect of this rule when it matches. If unspecified, defaults to `Allow`. `Require` rules are cumulative: all require rules must match.
The authorization rule to evaluate. * `Allow`: any matching allow rule allows the request. * `Require`: every require rule must match for the request to be allowed. * `Deny`: any matching deny rule denies the request. `Deny` is not recommended because expression failures fail to deny; prefer `Allow` or `Require`. If used, design expressions defensively against evaluation errors. If at least one `Allow` rule is configured, requests are denied unless at least one allow rule matches.
CEL expressions that must all evaluate to true for the rule to match.
Settings for passive and active health checking.
Settings for evicting unhealthy backends.
Number of consecutive unhealthy responses required before the backend is evicted. For example, a value of 5 means the backend must receive 5 unhealthy responses in a row before being evicted. When both consecutiveFailures and healthThreshold are set, the backend is evicted when either condition is met. When neither is set, a single unhealthy response can trigger eviction.
Base time a backend should be evicted after being marked unhealthy. Subsequent evictions use multiplicative backoff (duration * times_evicted). If all endpoints are evicted, the load balancer falls back to returning evicted endpoints rather than failing entirely. If unset, defaults to `3s`.
EWMA health score threshold, from 0 to 100. When set, a backend is evicted only if its computed health drops below this value after an unhealthy response (e.g. 50 evicts when EWMA health falls below 50%). Unlike consecutiveFailures, this sliding-window average lets a single success delay eviction. If both are set, either condition evicts; if neither, a single unhealthy response evicts.
Health score from 0 to 100 assigned to a backend when it returns from eviction. For gradual recovery, set below 100; for full recovery immediately, set 100. If unset, the backend resumes with the health it had when evicted.
CEL expression that determines whether a response indicates an unhealthy backend. When the expression evaluates to true, the backend is considered unhealthy and may be evicted. For example, to evict on 5xx responses: `response.code >= 500`. When unset, any 5xx response, or a connection failure, is treated as unhealthy. This default lowers the backend's health score but does not trigger eviction on its own.
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Mutates and transforms requests and responses sent to and from the backend.
Request transformation settings.
Headers to add to the request and what each value should be set to. If there is already a header with these values then append the value as an extra entry.
The name of the header to add.
CEL expression that generates the output value for the header.
HTTP body transformation.
Stores CEL-evaluated values under the `metadata` CEL variable for subsequent policy evaluations. `metadata` is evaluated before header or body transformations.
Header names to remove from the request or response.
Headers to set and the values to use.
The name of the header to add.
CEL expression that generates the output value for the header.
Response transformation settings.
Headers to add to the request and what each value should be set to. If there is already a header with these values then append the value as an extra entry.
The name of the header to add.
CEL expression that generates the output value for the header.
HTTP body transformation.
Stores CEL-evaluated values under the `metadata` CEL variable for subsequent policy evaluations. `metadata` is evaluated before header or body transformations.
Header names to remove from the request or response.
Headers to set and the values to use.
The name of the header to add.
CEL expression that generates the output value for the header.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Port to send requests to.
Vertex AI provider settings.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
The ID of the Google Cloud Project that you use for the Vertex AI.
The location of the Google Cloud Project that you use for the Vertex AI. Special values: `global` uses the global endpoint, while `us` and `eu` use restricted multi-region endpoints. Other values are treated as regional locations. Defaults to `global` if not specified.
Configuration for how to reach the configured LLM provider.
Anthropic provider settings.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
Azure provider with resource-based configuration. Supports both Azure OpenAI and Azure AI Foundry resource types.
The version of the Azure OpenAI API to use. If unset, defaults to `v1`.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
The Foundry project name, required when `resourceType` is `Foundry`. Used to construct paths: /api/projects/{projectName}/openai/v1/...
The Azure resource name used to construct the endpoint host. For OpenAI: {resourceName}.openai.azure.com For Foundry: {resourceName}.services.ai.azure.com Note: when the Azure portal "Foundry legacy" template was used, the generated resource name may end in "-resource" (e.g. "myproject-resource"); that suffix is part of the resource name as the user configured it, not part of the hostname suffix agentgateway should append.
The type of Azure endpoint. Determines the host suffix.
Azure OpenAI provider settings.
The version of the Azure OpenAI API to use. For more information, see the [Azure OpenAI API version reference](https://learn.microsoft.com/en-us/azure/foundry/openai/reference). If unset, defaults to `v1`.
The name of the Azure OpenAI model deployment to use. For 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). This is required if `apiVersion` is not `v1`. For `v1`, the model can be set in the request.
The endpoint for the Azure OpenAI API to use, such as `my-endpoint.openai.azure.com`. If the scheme is included, it is stripped.
Bedrock provider settings.
EndpointPreference selects which Bedrock API surface to prefer. Defaults to `RuntimePreferred`, preferring runtime over mantle. Decides which endpoint to pick mainly based on the catalog tags `mantle` and `runtime`.
Guardrail policy to use for the backend. See <https://docs.aws.amazon.com/bedrock/latest/userguide/guardrails.html>. If not specified, the AWS Guardrail policy will not be used.
Identifier of the Guardrail policy to use for the backend.
Version of the Guardrail policy to use for the backend.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
AWS region to use for the backend. Defaults to `us-east-1` if not specified.
Custom provider configures a non-managed or self-hosted LLM provider. Use this when the provider target and API formats should be declared explicitly instead of inferred from a managed provider such as OpenAI or Anthropic.
Kubernetes backend that serves this provider. `backendRef` may target only a namespace-local Service or InferencePool. If unset, host and port must be set on the parent provider.
API group of the referenced resource. For example, `gateway.networking.k8s.io`. Defaults to the empty string, which identifies the core API group.
Kind of the referenced resource. For example, `Service`. Defaults to "Service" when not specified.
Name of the referenced resource.
Destination port number to use for this resource. Required when the referenced resource is a Kubernetes Service.
Provider-native API formats this provider supports.
Default upstream path override for this format. If unset, agentgateway uses the default path for the format.
Provider-native API format.
Model name override, such as `gpt-oss`. If unset, the model name is taken from the request.
Provider identity used for cost-catalog lookup and telemetry. Defaults to "custom" when unset.
Gemini provider settings.
Model name override, such as `gemini-2.5-pro`. If unset, the model name is taken from the request.
Hostname to send requests to. For custom providers without backendRef, host and port specify the target. For managed providers, host and port override the provider default.
OpenAI provider settings.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
Inline moderation configuration to inject into OpenAI chat completions and responses requests. If unset, the OpenAI inline moderation parameter is not injected.
The moderation model to use, such as `omni-moderation-latest`. Defaults to `omni-moderation-latest` if not specified.
Policies to apply to request input and generated output.
Policy for request input moderation.
Mode controls whether moderation only returns scores or blocks flagged content.
Policy for generated output moderation.
Mode controls whether moderation only returns scores or blocks flagged content.
URL path to use for LLM provider API requests. This is useful when you need to route requests to a different API endpoint while maintaining compatibility with the original provider's API structure. If not specified, the default path for the provider is used.
Overrides the default base path prefix, such as `/v1`, for upstream requests. Path translation for cross-format requests still applies using this prefix. Only supported for OpenAI and Anthropic providers.
Port to send requests to.
Vertex AI provider settings.
Model name override, such as `gpt-4o-mini`. If unset, the model name is taken from the request.
The ID of the Google Cloud Project that you use for the Vertex AI.
The location of the Google Cloud Project that you use for the Vertex AI. Special values: `global` uses the global endpoint, while `us` and `eu` use restricted multi-region endpoints. Other values are treated as regional locations. Defaults to `global` if not specified.
AWS service backend, such as AgentCore.
Amazon Bedrock AgentCore backend settings.
ARN of the AgentCore runtime.
Alias or version qualifier.
Dynamically sends requests to the destination based on the incoming request HTTP host header, or TLS SNI for TLS traffic. Warning: this backend type can send requests to arbitrary destinations. Proper access controls must be put in place when using this backend type.
MCP backend.
Behavior when MCP targets fail to initialize or become unavailable at runtime. `FailOpen` skips failed targets and continues serving from healthy ones. `FailClosed` (default) fails the entire session if any target fails.
How tool and prompt names are prefixed with the target name. Resource URIs always retain target routing information when multiplexing and are unaffected. `Conditional` (default) prefixes only when there are multiple targets. `Always` prefixes even with a single target. `Never` exposes unprefixed names and routes calls by looking up which target serves the name; names must be unique across targets.
MCP session routing behavior. Defaults to `Stateful` if not set.
MCP targets to use for this backend. Policies targeting MCP targets must use `targetRefs[].sectionName` to select the target by name.
Name of the MCP target.
Label selector used to select `Service` resources. If policies are needed on a per-service basis, `AgentgatewayPolicy` can target the desired `Service`.
`namespace` is the label selector for namespaces that `Service` resources should be selected from. If unset, only the namespace of the `AgentgatewayBackend` is searched.
matchExpressions is a list of label selector requirements. The requirements are ANDed.
key is the label key that the selector applies to.
operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.
matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed.
`services` is the label selector for which `Service` resources should be selected.
matchExpressions is a list of label selector requirements. The requirements are ANDed.
key is the label key that the selector applies to.
operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.
matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed.
Static MCP destination. When connecting to in-cluster `Service` resources, it is recommended to use `selector` instead.
Namespace-local `Service` resource by name. When set, this replaces `host` only; `port`, `path`, and `protocol` remain configured on this target.
Name of the referent
Hostname or IP address of the MCP target.
URL path of the MCP target endpoint. Defaults to `"/sse"` for the `SSE` protocol or `"/mcp"` for the `StreamableHTTP` protocol if not specified.
Policies for communicating with this backend. Policies may also be set in `AgentgatewayPolicy`, or in the top-level `AgentgatewayBackend`. Policies are merged on a field-level basis, with order: `AgentgatewayPolicy` < `AgentgatewayBackend` < `AgentgatewayBackend` MCP (this field). This field may only be used with host-based static targets, not `backendRef`.
Settings for managing authentication to the backend
Explicit AWS authentication method for the backend. When omitted, default AWS SDK credential discovery is used.
AWS STS AssumeRole settings to use before signing backend requests. Ambient AWS credentials are used as the source credentials for STS.
ExternalID is set when the role's trust policy requires sts:ExternalId.
AWS IAM role ARN to assume.
SessionName is a custom session name (RoleSessionName) for CloudTrail and Cost & Usage Report attribution. If unset, AWS generates a random name.
SessionNameExpression is a CEL expression evaluated against each request to produce the session name (RoleSessionName), for example `jwt.sub` or `request.headers["x-team"]`. If the expression does not produce a valid session name at request time, the request is rejected.
Session tags passed to STS AssumeRole for cost attribution in the AWS Cost & Usage Report, once activated. STS allows at most 50 per role session.
CEL expression evaluated against each request to produce the tag value, for example `jwt.sub` or `request.headers["x-app"]`. Requests with invalid tag values are rejected.
Key is the tag key.
Value is a static tag value.
AWS SigV4 signing region, for example `us-east-1`. Set this when the target AWS service is in a different region than the gateway. If unset, typed AWS backends may provide this automatically; otherwise the ambient AWS region is used.
Credential source for AWS credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `accessKey`, `secretKey`, and optional `sessionToken` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
AWS SigV4 signing service name, for example `bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS backends may provide this automatically.
Azure authentication method for the backend.
Managed identity authentication settings. Leave this object empty to use the system-assigned identity. To use a user-assigned identity, set one of `clientId`, `objectId`, or `resourceId`.
Client ID of the user-assigned managed identity.
Object ID of the user-assigned managed identity.
Resource ID of the user-assigned managed identity.
Scopes requested for the Azure access token. When omitted, the scope is inferred from the backend hostname. Managed Identity supports exactly one scope.
Credential source for Azure credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `clientID`, `tenantID`, and `clientSecret` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Workload identity authentication settings. Uses the federated token and Azure env vars projected into the data plane pod. Recommended on AKS with Workload Identity enabled.
Credentials is a list of additional credentials to inject on the backend request. Each entry resolves a Secret key and writes its value to the entry's location. `credentials` is independent of the primary `key`/`secretRef`/`passthrough` mechanism and may be set on its own or alongside it.
Where the credential is inserted on the backend request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
SecretRef references a Kubernetes Secret holding the credential value, and optionally overrides the key read from it. Defaults to `Authorization`, matching the key convention used by the top-level `secretRef`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Cross App Access (Identity Assertion / ID-JAG) authentication.
Scopes requested when exchanging the ID-JAG for an access token. When omitted, defaults to Scopes. Set to an empty list to omit scope.
Identifier of the resource authorization server. The issued ID-JAG is bound to this audience.
Response cache configuration.
TTL used when the token endpoint omits expires_in. Default 300s.
Default 8192; 0 disables the cache.
User identity provider authorization server, used for the RFC 8693 ID-JAG exchange.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Client authentication for the token endpoint.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token endpoint path; defaults to "/". Must start with "/".
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Resource authorization server, used for the RFC 7523 jwt-bearer exchange.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Client authentication for the token endpoint.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token endpoint path; defaults to "/". Must start with "/".
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Resources sent to the token endpoint.
Scopes requested when obtaining the ID-JAG from the identity provider.
Subject token sent to the identity provider. Defaults to an OpenID Connect ID token read from the Authorization Bearer header.
Where to read the subject token. Defaults to the Authorization Bearer header.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth RFC 8693 subject token type. Defaults to IdToken
Google authentication method for the backend. When omitted, default Google credential discovery is used.
Explicit `aud` value for the ID token. Only valid with `IdToken` type. If not set, the `aud` is automatically derived from the backend hostname.
Credential source for ADC-compatible Google credential JSON, defaulting to a Kubernetes `Secret`. By default, the value is read from `credentials.json`; set `secretRef.key` to override it. When omitted, ambient credentials are used.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
The type of token to generate. To authenticate to GCP services, generally an `AccessToken` is used. To authenticate to Cloud Run, an `IdToken` is used.
Signs a short-lived JWT with a private key on each request and sends it to the backend, for upstreams that require per-request keypair JWTs (e.g. the Snowflake SQL API) rather than a static credential.
JWS signing algorithm. Defaults to RS256.
Static claims added to every token (e.g. iss, sub, aud). Values may be any JSON value (e.g. a string, number, bool, or array). iat, exp, and nbf are reserved for the signer and cannot be configured here; the controller rejects them at translation time.
Optional JWS key ID header.
Where the signed token is written on the backend request. Defaults to the Authorization header with a "Bearer " prefix.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Secret providing the `signingKey` key with a PEM-encoded RSA or EC private key.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token lifetime used for exp. Defaults to 300s.
Inline key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where backend credentials are inserted. If omitted, credentials are written to the `Authorization` header with the `Bearer ` prefix. This applies to `key`, `secretRef`, and `passthrough`. Entries in `credentials` carry their own location.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth 2.0 token exchange (RFC 8693) / jwt-bearer (RFC 7523) authentication.
RFC 8693 delegation actor token. TokenExchange grant only.
may_act claim validation mode. When omitted, may_act is not enforced.
Where to read the actor token. Actor tokens have no default source.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth token type. Empty defaults to AccessToken. Custom absolute URI values are supported for actor tokens.
Extra form params; values are CEL expressions over the incoming request.
Audiences sent to the token endpoint.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Response cache configuration.
TTL used when the token endpoint omits expires_in. Default 300s.
Default 8192; 0 disables the cache.
Client authentication for the token endpoint. When unset, none is sent.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
RFC followed by the request. Defaults to TokenExchange (RFC 8693).
Where the exchanged token is written to the backend request. Defaults to Authorization: Bearer.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Token endpoint path; defaults to "/". Must start with "/".
RFC 8693 requested_token_type. Unlike subject/actor token types, only the built-in values may be requested; custom URIs are not supported here.
Resources sent to the token endpoint.
Scopes sent to the token endpoint.
Subject token / assertion source and type. Defaults to Authorization Bearer, AccessToken. The token type may be a built-in value or a custom absolute URI for providers that support custom token exchange profiles.
Where to read the token. CEL `expression` variant is permitted.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth token type. Empty defaults to AccessToken. Custom absolute URI values are supported for subject tokens.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Reuses a client token already validated by another policy. Those policies may strip client credentials; passthrough adds the original token back to the backend request. Without client auth policies, this has no effect.
Credential source for the authorization value, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Port number of the MCP target.
Protocol to use for the connection to the MCP target.
Policies for communicating with this backend. Policies may also be set with AgentgatewayPolicy. Backend policies take precedence over policy resources when they set the same field.
Settings for AI workloads. This is only applicable when connecting to a `Backend` of type `ai`.
Defaults to merge with user input fields. If the field is already set, the field in the request is used.
Name of the field.
Default value for the field. This can be any JSON data type.
CEL transformations to compute and set fields in the request body. The expression result overwrites any existing value for that field. This has a higher priority than `overrides` if both are set for the same key. Those transformations are applied after the request is converted to the provider's format, so they can be used to set provider-specific fields.
CEL expression used to compute the field value.
Name of the field to set.
Maps friendly model names to actual provider model names. Example: `{"fast": "gpt-3.5-turbo", "smart": "gpt-4-turbo"}`. Note: This field is only applicable when using the agentgateway data plane.
Overrides to merge with user input fields. If the field is already set, the field is overwritten.
Name of the field.
Default value for the field. This can be any JSON data type.
Enriches requests sent to the LLM provider by appending and prepending system prompts. This can be configured only for LLM providers that use the `CHAT` or `CHAT_STREAMING` API route type.
Messages to append to the prompt sent by the client.
String content of the message.
Role of the message. The available roles depend on the backend LLM provider model, such as `SYSTEM` or `USER` in the OpenAI API.
Messages to prepend to the prompt sent by the client.
String content of the message.
Role of the message. The available roles depend on the backend LLM provider model, such as `SYSTEM` or `USER` in the OpenAI API.
Automatic prompt caching for supported providers, currently AWS Bedrock. Reduces API costs by caching static content like system prompts and tool definitions. Only applicable for Bedrock Claude 3+ and Nova models.
Shifts the message cache point further back in the conversation. 0 (default) places it at the second-to-last message. Higher values move it N additional messages towards the start, clamped to bounds.
Enables caching for conversation messages. Defaults to true. Caches all messages in the conversation for cost savings.
Enables caching for system prompts. Defaults to true. Inserts a cache point after all system messages.
Enables caching for tool definitions. Defaults to false. Inserts a cache point after all tool specifications.
Minimum estimated token count before caching is enabled. Uses rough heuristic (word count × 1.3) to estimate tokens. Defaults to 1024. Bedrock requires at least 1,024 tokens for caching to be effective.
Guardrails for LLM requests and responses.
Prompt guards to apply to requests sent by the client.
AWS Bedrock Guardrails settings for prompt guarding.
Action controls whether the guardrail's verdict is enforced or only observed. `Reject` (the default) enforces the guardrail: a blocked assessment rejects the request/response and an anonymized assessment masks the matched content. `Audit` runs the guardrail in observe mode: it is invoked and its assessment recorded (metrics + structured log), but the request/response is never blocked or masked.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Identifier of the Guardrail policy to use for the backend.
Policies for communicating with AWS Bedrock Guardrails.
Settings for authenticating to AWS Bedrock Guardrails.
AWS authentication method for Bedrock Guardrails. Use `aws: {}` for default AWS SDK credential discovery.
AWS STS AssumeRole settings to use before signing backend requests. Ambient AWS credentials are used as the source credentials for STS.
ExternalID is set when the role's trust policy requires sts:ExternalId.
AWS IAM role ARN to assume.
SessionName is a custom session name (RoleSessionName) for CloudTrail and Cost & Usage Report attribution. If unset, AWS generates a random name.
SessionNameExpression is a CEL expression evaluated against each request to produce the session name (RoleSessionName), for example `jwt.sub` or `request.headers["x-team"]`. If the expression does not produce a valid session name at request time, the request is rejected.
Session tags passed to STS AssumeRole for cost attribution in the AWS Cost & Usage Report, once activated. STS allows at most 50 per role session.
CEL expression evaluated against each request to produce the tag value, for example `jwt.sub` or `request.headers["x-app"]`. Requests with invalid tag values are rejected.
Key is the tag key.
Value is a static tag value.
AWS SigV4 signing region, for example `us-east-1`. Set this when the target AWS service is in a different region than the gateway. If unset, typed AWS backends may provide this automatically; otherwise the ambient AWS region is used.
Credential source for AWS credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `accessKey`, `secretKey`, and optional `sessionToken` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
AWS SigV4 signing service name, for example `bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS backends may provide this automatically.
Inline API key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where API keys are inserted. Defaults to the `Authorization` header with the `Bearer ` prefix. Applies to `key` and `secretRef`.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Credential source for the API key, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
AWS region where the guardrail is deployed, for example `us-west-2`).
Version of the Guardrail policy to use for the backend.
Google Model Armor settings for prompt guarding.
Action controls whether flagged content is rejected or only observed. `Reject` (the default) rejects flagged content; `Audit` records the would-be rejection without blocking.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Google Cloud location, for example `us-central1`. Defaults to `us-central1` if not specified.
Policies for communicating with Google Model Armor.
Settings for authenticating to Google Model Armor.
Google authentication method for Model Armor. Use `gcp: {}` for default Google credential discovery.
Explicit `aud` value for the ID token. Only valid with `IdToken` type. If not set, the `aud` is automatically derived from the backend hostname.
Credential source for ADC-compatible Google credential JSON, defaulting to a Kubernetes `Secret`. By default, the value is read from `credentials.json`; set `secretRef.key` to override it. When omitted, ambient credentials are used.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
The type of token to generate. To authenticate to GCP services, generally an `AccessToken` is used. To authenticate to Cloud Run, an `IdToken` is used.
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Google Cloud project ID.
Template ID for Google Model Armor.
Passes prompt data through the OpenAI Moderations endpoint. See https://developers.openai.com/api/reference/resources/moderations for more information.
Action controls whether flagged content is rejected or only observed. `Reject` (the default) rejects flagged content; `Audit` records the would-be rejection without blocking.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Moderation model to use. For example, `omni-moderation`.
Policies for communicating with OpenAI.
Settings for authenticating to OpenAI.
Inline key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where backend credentials are inserted. Defaults to the `Authorization` header with the `Bearer ` prefix. Applies to `key` and `secretRef`.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Credential source for the authorization value, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Regular expression (regex) matching for prompt guards and data masking.
The action to take if a regex pattern is matched in a request or response. The action applies to request and response matches alike. Note that `Mask` is not applied to streamed responses: matched content in a streamed response is passed through unmodified. Defaults to `Mask`.
Built-in regex patterns to match against the request or response. Matches and built-ins are additive.
Regex patterns to match against the request or response. Matches and built-ins are additive.
Custom response message to return to the client. If not specified, defaults to `The request was rejected due to inappropriate content`.
Custom response message to return to the client. If not specified, defaults to `The request was rejected due to inappropriate content`.
Status code to return to the client. Defaults to 403.
Which parts of the request this guard inspects. When unset, defaults to `SystemPrompt` and `Messages`. Tool call inputs and outputs are not inspected unless `ToolInput`/`ToolOutput` are listed explicitly. In APIs that send tool arguments as opaque JSON, such as Completions, the arguments are masked as a single string, meaning a prompt guard has the potential to rewrite the arguments into invalid JSON.
Webhook that receives requests for prompt guarding.
Action controls whether the webhook's verdict is enforced or only observed. `Reject` (the default) enforces it; `Audit` records the would-be action without blocking or masking.
Webhook server to reach. Supported types: Service and Backend.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Behavior when the webhook guardrail is unavailable or returns an error. `FailOpen` allows the request to continue. `FailClosed` (default) rejects the request.
HTTP header matches used to select the headers to forward to the webhook. Request headers are used when forwarding requests and response headers are used when forwarding responses. By default, no headers are forwarded.
Name of the HTTP header to match, case-insensitive. When names are equivalent, only the first matching entry is used
How to match against the header value: `Exact` (default) or `RegularExpression`. The regex dialect is implementation-specific
Value of the HTTP header to match
CEL-computed headers to include in webhook requests.
Prompt guards to apply to responses returned by the LLM provider.
AWS Bedrock Guardrails settings for prompt guarding.
Action controls whether the guardrail's verdict is enforced or only observed. `Reject` (the default) enforces the guardrail: a blocked assessment rejects the request/response and an anonymized assessment masks the matched content. `Audit` runs the guardrail in observe mode: it is invoked and its assessment recorded (metrics + structured log), but the request/response is never blocked or masked.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Identifier of the Guardrail policy to use for the backend.
Policies for communicating with AWS Bedrock Guardrails.
Settings for authenticating to AWS Bedrock Guardrails.
AWS authentication method for Bedrock Guardrails. Use `aws: {}` for default AWS SDK credential discovery.
AWS STS AssumeRole settings to use before signing backend requests. Ambient AWS credentials are used as the source credentials for STS.
ExternalID is set when the role's trust policy requires sts:ExternalId.
AWS IAM role ARN to assume.
SessionName is a custom session name (RoleSessionName) for CloudTrail and Cost & Usage Report attribution. If unset, AWS generates a random name.
SessionNameExpression is a CEL expression evaluated against each request to produce the session name (RoleSessionName), for example `jwt.sub` or `request.headers["x-team"]`. If the expression does not produce a valid session name at request time, the request is rejected.
Session tags passed to STS AssumeRole for cost attribution in the AWS Cost & Usage Report, once activated. STS allows at most 50 per role session.
CEL expression evaluated against each request to produce the tag value, for example `jwt.sub` or `request.headers["x-app"]`. Requests with invalid tag values are rejected.
Key is the tag key.
Value is a static tag value.
AWS SigV4 signing region, for example `us-east-1`. Set this when the target AWS service is in a different region than the gateway. If unset, typed AWS backends may provide this automatically; otherwise the ambient AWS region is used.
Credential source for AWS credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `accessKey`, `secretKey`, and optional `sessionToken` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
AWS SigV4 signing service name, for example `bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS backends may provide this automatically.
Inline API key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where API keys are inserted. Defaults to the `Authorization` header with the `Bearer ` prefix. Applies to `key` and `secretRef`.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Credential source for the API key, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
AWS region where the guardrail is deployed, for example `us-west-2`).
Version of the Guardrail policy to use for the backend.
Google Model Armor settings for prompt guarding.
Action controls whether flagged content is rejected or only observed. `Reject` (the default) rejects flagged content; `Audit` records the would-be rejection without blocking.
Behavior when the provider is unavailable or returns an error. `FailOpen` allows the request to continue; `FailClosed` (default) rejects it.
Google Cloud location, for example `us-central1`. Defaults to `us-central1` if not specified.
Policies for communicating with Google Model Armor.
Settings for authenticating to Google Model Armor.
Google authentication method for Model Armor. Use `gcp: {}` for default Google credential discovery.
Explicit `aud` value for the ID token. Only valid with `IdToken` type. If not set, the `aud` is automatically derived from the backend hostname.
Credential source for ADC-compatible Google credential JSON, defaulting to a Kubernetes `Secret`. By default, the value is read from `credentials.json`; set `secretRef.key` to override it. When omitted, ambient credentials are used.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
The type of token to generate. To authenticate to GCP services, generally an `AccessToken` is used. To authenticate to Cloud Run, an `IdToken` is used.
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Google Cloud project ID.
Template ID for Google Model Armor.
Regular expression (regex) matching for prompt guards and data masking.
The action to take if a regex pattern is matched in a request or response. The action applies to request and response matches alike. Note that `Mask` is not applied to streamed responses: matched content in a streamed response is passed through unmodified. Defaults to `Mask`.
Built-in regex patterns to match against the request or response. Matches and built-ins are additive.
Regex patterns to match against the request or response. Matches and built-ins are additive.
Custom response message to return to the client. If not specified, defaults to `The response was rejected due to inappropriate content`.
Custom response message to return to the client. If not specified, defaults to `The request was rejected due to inappropriate content`.
Status code to return to the client. Defaults to 403.
Webhook that receives responses for prompt guarding.
Action controls whether the webhook's verdict is enforced or only observed. `Reject` (the default) enforces it; `Audit` records the would-be action without blocking or masking.
Webhook server to reach. Supported types: Service and Backend.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Behavior when the webhook guardrail is unavailable or returns an error. `FailOpen` allows the request to continue. `FailClosed` (default) rejects the request.
HTTP header matches used to select the headers to forward to the webhook. Request headers are used when forwarding requests and response headers are used when forwarding responses. By default, no headers are forwarded.
Name of the HTTP header to match, case-insensitive. When names are equivalent, only the first matching entry is used
How to match against the header value: `Exact` (default) or `RegularExpression`. The regex dialect is implementation-specific
Value of the HTTP header to match
CEL-computed headers to include in webhook requests.
Apply prompt guards to streaming responses and realtime websocket messages. Defaults to disabled to preserve streaming throughput unless explicitly enabled.
Rules for identifying the type of traffic to handle. The keys are URL path suffixes matched using ends-with comparison, for example `"/v1/chat/completions"`. The special `*` wildcard matches any path. If not specified, all traffic defaults to `completions` type.
CEL transformations to compute and set fields in the request body. The expression result overwrites any existing value for that field. This has a higher priority than `overrides` if both are set for the same key.
CEL expression used to compute the field value.
Name of the field to set.
Settings for managing authentication to the backend
Explicit AWS authentication method for the backend. When omitted, default AWS SDK credential discovery is used.
AWS STS AssumeRole settings to use before signing backend requests. Ambient AWS credentials are used as the source credentials for STS.
ExternalID is set when the role's trust policy requires sts:ExternalId.
AWS IAM role ARN to assume.
SessionName is a custom session name (RoleSessionName) for CloudTrail and Cost & Usage Report attribution. If unset, AWS generates a random name.
SessionNameExpression is a CEL expression evaluated against each request to produce the session name (RoleSessionName), for example `jwt.sub` or `request.headers["x-team"]`. If the expression does not produce a valid session name at request time, the request is rejected.
Session tags passed to STS AssumeRole for cost attribution in the AWS Cost & Usage Report, once activated. STS allows at most 50 per role session.
CEL expression evaluated against each request to produce the tag value, for example `jwt.sub` or `request.headers["x-app"]`. Requests with invalid tag values are rejected.
Key is the tag key.
Value is a static tag value.
AWS SigV4 signing region, for example `us-east-1`. Set this when the target AWS service is in a different region than the gateway. If unset, typed AWS backends may provide this automatically; otherwise the ambient AWS region is used.
Credential source for AWS credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `accessKey`, `secretKey`, and optional `sessionToken` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
AWS SigV4 signing service name, for example `bedrock`, `bedrock-agentcore`, or `execute-api`). If unset, typed AWS backends may provide this automatically.
Azure authentication method for the backend.
Managed identity authentication settings. Leave this object empty to use the system-assigned identity. To use a user-assigned identity, set one of `clientId`, `objectId`, or `resourceId`.
Client ID of the user-assigned managed identity.
Object ID of the user-assigned managed identity.
Resource ID of the user-assigned managed identity.
Scopes requested for the Azure access token. When omitted, the scope is inferred from the backend hostname. Managed Identity supports exactly one scope.
Credential source for Azure credentials, defaulting to a Kubernetes `Secret`. The default Secret resolver expects `clientID`, `tenantID`, and `clientSecret` keys.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Workload identity authentication settings. Uses the federated token and Azure env vars projected into the data plane pod. Recommended on AKS with Workload Identity enabled.
Credentials is a list of additional credentials to inject on the backend request. Each entry resolves a Secret key and writes its value to the entry's location. `credentials` is independent of the primary `key`/`secretRef`/`passthrough` mechanism and may be set on its own or alongside it.
Where the credential is inserted on the backend request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
SecretRef references a Kubernetes Secret holding the credential value, and optionally overrides the key read from it. Defaults to `Authorization`, matching the key convention used by the top-level `secretRef`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Cross App Access (Identity Assertion / ID-JAG) authentication.
Scopes requested when exchanging the ID-JAG for an access token. When omitted, defaults to Scopes. Set to an empty list to omit scope.
Identifier of the resource authorization server. The issued ID-JAG is bound to this audience.
Response cache configuration.
TTL used when the token endpoint omits expires_in. Default 300s.
Default 8192; 0 disables the cache.
User identity provider authorization server, used for the RFC 8693 ID-JAG exchange.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Client authentication for the token endpoint.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token endpoint path; defaults to "/". Must start with "/".
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Resource authorization server, used for the RFC 7523 jwt-bearer exchange.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Client authentication for the token endpoint.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token endpoint path; defaults to "/". Must start with "/".
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Resources sent to the token endpoint.
Scopes requested when obtaining the ID-JAG from the identity provider.
Subject token sent to the identity provider. Defaults to an OpenID Connect ID token read from the Authorization Bearer header.
Where to read the subject token. Defaults to the Authorization Bearer header.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth RFC 8693 subject token type. Defaults to IdToken
Google authentication method for the backend. When omitted, default Google credential discovery is used.
Explicit `aud` value for the ID token. Only valid with `IdToken` type. If not set, the `aud` is automatically derived from the backend hostname.
Credential source for ADC-compatible Google credential JSON, defaulting to a Kubernetes `Secret`. By default, the value is read from `credentials.json`; set `secretRef.key` to override it. When omitted, ambient credentials are used.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
The type of token to generate. To authenticate to GCP services, generally an `AccessToken` is used. To authenticate to Cloud Run, an `IdToken` is used.
Signs a short-lived JWT with a private key on each request and sends it to the backend, for upstreams that require per-request keypair JWTs (e.g. the Snowflake SQL API) rather than a static credential.
JWS signing algorithm. Defaults to RS256.
Static claims added to every token (e.g. iss, sub, aud). Values may be any JSON value (e.g. a string, number, bool, or array). iat, exp, and nbf are reserved for the signer and cannot be configured here; the controller rejects them at translation time.
Optional JWS key ID header.
Where the signed token is written on the backend request. Defaults to the Authorization header with a "Bearer " prefix.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Secret providing the `signingKey` key with a PEM-encoded RSA or EC private key.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Token lifetime used for exp. Defaults to 300s.
Inline key to use as the value of the `Authorization` header. This option is the least secure; usage of a `Secret` is preferred.
Where backend credentials are inserted. If omitted, credentials are written to the `Authorization` header with the `Bearer ` prefix. This applies to `key`, `secretRef`, and `passthrough`. Entries in `credentials` carry their own location.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth 2.0 token exchange (RFC 8693) / jwt-bearer (RFC 7523) authentication.
RFC 8693 delegation actor token. TokenExchange grant only.
may_act claim validation mode. When omitted, may_act is not enforced.
Where to read the actor token. Actor tokens have no default source.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth token type. Empty defaults to AccessToken. Custom absolute URI values are supported for actor tokens.
Extra form params; values are CEL expressions over the incoming request.
Audiences sent to the token endpoint.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Response cache configuration.
TTL used when the token endpoint omits expires_in. Default 300s.
Default 8192; 0 disables the cache.
Client authentication for the token endpoint. When unset, none is sent.
Client ID sent to the token endpoint.
Client authentication method. Defaults to ClientSecretBasic.
Client assertion settings. Required when method is PrivateKeyJwt.
JWS signing algorithm. Defaults to RS256.
Audience for the client assertion, typically the token endpoint URL.
JWS certificate header. Required when certificateRef is set.
PEM-encoded X.509 certificate chain, leaf first, for certificateHeader. The leaf public key should match signingKeyRef; a mismatch only logs a warning but the token endpoint will reject the assertions. Required when certificateHeader is set. The key defaults to `certificate`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Optional JWS key ID header.
PEM-encoded RSA or EC private key; key defaults to `signingKey`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Secret providing the `clientSecret` key by default; override via `secretRef.key`. When omitted, client_id is sent without a secret, which is only valid with ClientSecretPost.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
RFC followed by the request. Defaults to TokenExchange (RFC 8693).
Where the exchanged token is written to the backend request. Defaults to Authorization: Bearer.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
Token endpoint path; defaults to "/". Must start with "/".
RFC 8693 requested_token_type. Unlike subject/actor token types, only the built-in values may be requested; custom URIs are not supported here.
Resources sent to the token endpoint.
Scopes sent to the token endpoint.
Subject token / assertion source and type. Defaults to Authorization Bearer, AccessToken. The token type may be a built-in value or a custom absolute URI for providers that support custom token exchange profiles.
Where to read the token. CEL `expression` variant is permitted.
CEL expression that extracts the credential from the request.
Name of an HTTP header. HTTP/2 pseudo-headers (names beginning with `:`) are not supported
OAuth token type. Empty defaults to AccessToken. Custom absolute URI values are supported for subject tokens.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Reuses a client token already validated by another policy. Those policies may strip client credentials; passthrough adds the original token back to the backend request. Without client auth policies, this has no effect.
Credential source for the authorization value, defaulting to a Kubernetes `Secret`. By default, the value is read from the `Authorization` key; set `secretRef.key` to override it. A `Bearer ` prefix is stripped only from the default `Authorization` key.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Authorization rules that clients must satisfy after this backend is selected. Unlike traffic authorization, this policy is evaluated against the request associated with the selected destination backend.
The effect of this rule when it matches. If unspecified, defaults to `Allow`. `Require` rules are cumulative: all require rules must match.
The authorization rule to evaluate. * `Allow`: any matching allow rule allows the request. * `Require`: every require rule must match for the request to be allowed. * `Deny`: any matching deny rule denies the request. `Deny` is not recommended because expression failures fail to deny; prefer `Allow` or `Require`. If used, design expressions defensively against evaluation errors. If at least one `Allow` rule is configured, requests are denied unless at least one allow rule matches.
CEL expressions that must all evaluate to true for the rule to match.
External authentication configuration for requests sent to this backend.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
Caches authorization results. WARNING: the safety of this feature depends on the cache key accurately capturing every request property that the authorization service uses to make a decision. For example, if the service returns different results based on both path and authorization header, both must be included in `key`; otherwise, one request may incorrectly reuse another request's authorization result. If any key expression fails to evaluate or produces an unsupported value, the request is still sent to the authorization service, but its result is not read from or written to the cache.
Ordered list of CEL expressions evaluated against the request to construct the cache key.
Maximum number of authorization results to keep in the cache. If unset, this defaults to 10000.
Duration string, such as `5m`, or a CEL expression that returns the duration that cached authorization results may be reused, or a timestamp when the cached authorization result expires. The expression is evaluated after the authorization response has been applied to the request.
Behavior when the external authorization service is unavailable or returns an error. "FailOpen" allows the request to continue. "FailClosed" (default) denies the request.
Whether to include the HTTP body in the authorization request. If enabled, the request body will be buffered.
Largest body, in bytes, that will be buffered and sent to the authorization server. If the body size is larger than `maxSize`, then the request will be rejected with a response.
Uses the gRPC External Authorization [protocol](https://www.envoyproxy.io/docs/envoy/latest/api-v3/service/auth/v3/external_auth.proto) should be used.
Additional arbitrary key-value pairs to send to the authorization server in the `context_extensions` field.
Metadata to send to the authorization server. This maps to the `metadata_context.filter_metadata` field of the request, and allows dynamic CEL expressions. If unset, by default the `envoy.filters.http.jwt_authn` key is set if the JWT policy is used as well, for compatibility.
Uses HTTP to connect to the authorization server. The authorization server must return a `200` status code, otherwise the request is considered an authorization failure.
Additional headers to add to the request to the authorization server. While `allowedRequestHeaders` just passes the original headers through, `addRequestHeaders` allows defining custom headers based on CEL expressions.
Additional headers from the client request that will be sent to the authorization server. If unset, the following headers are sent by default: `Authorization`.
Headers from the authorization response that will be copied into the request to the backend.
Body is a CEL expression that produces the HTTP authorization request body. Strings and bytes are used directly; other values are JSON-encoded.
Path to send to the authorization server. If unset, this defaults to the original request path. This is a CEL expression, which allows customizing the path based on the incoming request. For example, to add a prefix, use `"/prefix/" + request.path`.
Optional expression that determines a path to redirect to on authorization failure. This is useful to redirect to a sign-in page.
Metadata fields to construct from the authorization response. These will be included under the `extauthz` variable in future CEL expressions. Setting this is useful for things like logging usernames, without needing to include them as headers to the backend, as `allowedResponseHeaders` would.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Settings for passive and active health checking.
Settings for evicting unhealthy backends.
Number of consecutive unhealthy responses required before the backend is evicted. For example, a value of 5 means the backend must receive 5 unhealthy responses in a row before being evicted. When both consecutiveFailures and healthThreshold are set, the backend is evicted when either condition is met. When neither is set, a single unhealthy response can trigger eviction.
Base time a backend should be evicted after being marked unhealthy. Subsequent evictions use multiplicative backoff (duration * times_evicted). If all endpoints are evicted, the load balancer falls back to returning evicted endpoints rather than failing entirely. If unset, defaults to `3s`.
EWMA health score threshold, from 0 to 100. When set, a backend is evicted only if its computed health drops below this value after an unhealthy response (e.g. 50 evicts when EWMA health falls below 50%). Unlike consecutiveFailures, this sliding-window average lets a single success delay eviction. If both are set, either condition evicts; if neither, a single unhealthy response evicts.
Health score from 0 to 100 assigned to a backend when it returns from eviction. For gradual recovery, set below 100; for full recovery immediately, set 100. If unset, the backend resumes with the health it had when evicted.
CEL expression that determines whether a response indicates an unhealthy backend. When the expression evaluates to true, the backend is considered unhealthy and may be evicted. For example, to evict on 5xx responses: `response.code >= 500`. When unset, any 5xx response, or a connection failure, is treated as unhealthy. This default lowers the backend's health score but does not trigger eviction on its own.
Settings for managing HTTP requests to the backend
Deadline for receiving a response from the backend.
HTTP protocol version for backend connections. If unset, it is inferred: `Service` appProtocol, `HTTP2` for gRPC, the original protocol for plaintext HTTP, or `HTTP1` for HTTPS because clients often upgrade HTTPS to HTTP/2 even when the backend does not support it.
Settings for MCP workloads. This is only applicable when connecting to a `Backend` of type `mcp`.
MCP backend-specific authentication rules. This field is deprecated; prefer to use traffic policy `jwtAuthentication.mcp`, which ensures authentication runs before other policies such as transformation and rate limiting.
Allowed audiences that are allowed access. This corresponds to the `aud` claim ([RFC 7519 §4.1.3](https://datatracker.ietf.org/doc/html/rfc7519#section-4.1.3)). If unset, any audience is allowed.
Client ID to use for short-circuiting Dynamic Client Registration. If set, the gateway will not proxy registration requests to the IDP and instead return this client ID.
Reference to a Kubernetes Secret holding the OAuth client secret of the app registration identified by `clientId` (for example Entra ID confidential clients, which require the secret at the token endpoint). The gateway injects it into the token requests it proxies to the provider. Defaults to the `clientSecret` key; override via `clientSecretRef.key`.
API group of the referenced credential; empty selects the core API group
Key in the referenced Secret. If omitted, a location-specific default is used
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
IdP that issued the JWT. This corresponds to the `iss` claim ([RFC 7519 §4.1.1](https://tools.ietf.org/html/rfc7519#section-4.1.1)).
Remote JSON Web Key used to validate the signature of the JWT.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How long a fetched `jwks` document is used before it is re-fetched from the IdP. Defaults to `5m`.
Path to the IdP `jwks` endpoint, relative to the root, commonly `".well-known/jwks.json"`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Validation mode for JWT authentication. Defaults to `Strict`.
Identity provider to use for authentication.
Metadata to use for MCP resources.
Additional JWT claim presence requirements. Defaults to requiring `exp`. Issuer validation always requires `iss`; a non-empty audiences list also requires `aud`, regardless of these options. An empty `requiredClaims` list removes only the additional presence requirements. Expiration is still checked whenever `exp` is present.
Additional claims that must be present in the token payload. Recognized values: `exp`, `nbf`, `aud`, `sub`. Defaults to `["exp"]` when omitted. An empty list adds no requirements beyond `iss`, which is always required, and `aud`, which is required when a non-empty audiences list is configured. Expiration is still checked whenever `exp` is present.
MCP backend authorization. Unlike authorization at the HTTP level, which rejects unauthorized requests with a `403` error, this policy works at the `MCPBackend` level. List operations, such as `list_tools`, will have each item evaluated. Items that do not meet the rule will be filtered. Get or call operations, such as `call_tool`, will evaluate the specific item and reject requests that do not meet the rule.
The effect of this rule when it matches. If unspecified, defaults to `Allow`. `Require` rules are cumulative: all require rules must match.
The authorization rule to evaluate. * `Allow`: any matching allow rule allows the request. * `Require`: every require rule must match for the request to be allowed. * `Deny`: any matching deny rule denies the request. `Deny` is not recommended because expression failures fail to deny; prefer `Allow` or `Require`. If used, design expressions defensively against evaluation errors. If at least one `Allow` rule is configured, requests are denied unless at least one allow rule matches.
CEL expressions that must all evaluate to true for the rule to match.
`guardrails` routes selected JSON-RPC methods through a remote policy server.
`processors` is the ordered list of policy processors applied to matched methods. Processors run in the order listed; the first to reject a request short-circuits the chain.
`methods` is the allowlist of JSON-RPC methods (e.g. `tools/call`, `tools/list`) routed through this processor, keyed by method name with the phase it runs in. Keys may be exact, a prefix wildcard (`tools/*`), a suffix wildcard (`*/list`), or `*` for all methods; the most specific match wins. Methods matching no key, including unknown ones, bypass this processor.
`remote` configures a gRPC policy server.
`allowedRequestHeaders` lists the incoming request headers forwarded to the policy server in `McpRequest.headers`. If empty, all headers and pseudo-headers (`:authority`, `:method`, ...) are forwarded. Matching is case-insensitive.
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
`disallowedRequestHeaders` lists header names never forwarded to the policy server, even if listed in `allowedRequestHeaders`. Matching is case-insensitive.
`failureMode` controls behavior when the policy server is unreachable or returns an error. `FailOpen` allows the request; `FailClosed` (default) denies it.
`metadata` is static or CEL-evaluated context surfaced to the policy server as fields of the `metadata_context` google.protobuf.Struct, keyed by config key. Values are CEL expressions.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Configures best-effort session affinity using an existing request attribute. For AI backends, this applies across the backend's provider groups and must not be configured on an individual provider.
CEL expression evaluated against request state. It must return a string or bytes value. For example, `request.headers["x-session-id"]` or `string(source.address)`.
Settings for managing TCP connections to the backend
Deadline for establishing a connection to the destination.
Settings for enabling TCP keepalives on the connection.
Time between keepalive probes. If unset, this defaults to 180s.
Maximum number of keepalive probes to send before dropping the connection. If unset, this defaults to 9.
Time a connection needs to be idle before keepalive probes start being sent. If unset, this defaults to 180s.
Settings for managing TLS connections to the backend When set, TLS is originated to the backend using the system trusted CA certificates, and SNI is inferred from the destination.
Application-Layer Protocol Negotiation (`ALPN`) value to use in the TLS handshake. If not present, defaults to `["h2", "http/1.1"]`.
CA certificate source to use to verify the server certificate. Omitted kind and `ConfigMap` select a ConfigMap; `Secret` selects a Secret. The bundle is read from the `ca.crt` key unless `key` names a different one. If unset, the system's trusted certificates are used.
Key within the referenced source holding the PEM-encoded CA bundle. Omitted defaults to `ca.crt`.
Kind of the referenced CA certificate source. Omitted defaults to ConfigMap.
Name of the referenced CA certificate source.
Source for the gateway's client identity and trust roots (`Inline` default, or `SPIFFE`).
Originates TLS but skips verification of the backend's certificate WARNING: insecure; only use if the risks are understood Modes: * `All` disables all TLS verification * `Hostname` trusts the CA certificate but ignores hostname/SAN mismatches. Still insecure; prefer `verifySubjectAltNames` where possible.
Ordered list of key exchange groups for a TLS connection. For example: `X25519_MLKEM768,X25519`.
Enables mutual TLS to the backend using `tls.key` and `tls.crt` from the referenced credential source (defaulting to a Kubernetes `Secret`). An optional `ca.cert`, if present, verifies the server certificate, but `caCertificateRefs` takes priority. If unspecified, no client certificate is used.
API group of the referenced credential; empty selects the core API group
Kind of the referenced credential; empty defaults to `Secret`
Name of the referenced credential
Server Name Indicator (`SNI`) to use in the TLS handshake. If unset, the `SNI` is automatically set based on the destination hostname.
Subject Alternative Names (`SAN`) to verify in the server certificate. If not present, the destination hostname is automatically used.
Mutates and transforms requests and responses sent to and from the backend.
Request transformation settings.
Headers to add to the request and what each value should be set to. If there is already a header with these values then append the value as an extra entry.
The name of the header to add.
CEL expression that generates the output value for the header.
HTTP body transformation.
Stores CEL-evaluated values under the `metadata` CEL variable for subsequent policy evaluations. `metadata` is evaluated before header or body transformations.
Header names to remove from the request or response.
Headers to set and the values to use.
The name of the header to add.
CEL expression that generates the output value for the header.
Response transformation settings.
Headers to add to the request and what each value should be set to. If there is already a header with these values then append the value as an extra entry.
The name of the header to add.
CEL expression that generates the output value for the header.
HTTP body transformation.
Stores CEL-evaluated values under the `metadata` CEL variable for subsequent policy evaluations. `metadata` is evaluated before header or body transformations.
Header names to remove from the request or response.
Headers to set and the values to use.
The name of the header to add.
CEL expression that generates the output value for the header.
Settings for managing tunnel connections to the backend, like `HTTPS_PROXY`
`backendRef` selects a backend for this policy. Mutually exclusive with `url`.
Group of the referent, for example `gateway.networking.k8s.io`. Empty selects the core API group
Kubernetes resource kind of the referent, for example `Service`. Defaults to `Service`
Name is the name of the referent.
Namespace of the referent. Defaults to the local namespace. A cross-namespace reference requires a ReferenceGrant in the referent namespace
Destination port number. Required when the referent is a Kubernetes `Service`
How requests are sent through the proxy. Defaults to `Auto`.
`url` directly specifies the HTTP(S) endpoint for this policy. When the scheme is `https`, backend TLS is enabled automatically. Mutually exclusive with `backendRef`. URLs are opaque; referencing a Kubernetes service hostname like `hello.ns.svc.cluster.local` will not apply Service policies or load balancing.
Static hostname, IP address, or Unix Domain Socket backend.
Host to connect to for TCP backends.
Port to connect to for TCP backends.
Filesystem path to a Unix Domain Socket. The gateway pod must share a volume with the target (e.g., via emptyDir sidecar pattern). Mutually exclusive with host/port.
Current backend status.
Current condition state for the backend.
lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
message is a human readable message indicating details about the transition. This may be an empty string.
observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.
reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.
status of the condition, one of True, False, Unknown.
type of condition in CamelCase or in foo.example.com/CamelCase.
Source: agentgateway.dev_agentgatewaybackends.yaml
Changes to AgentgatewayBackend (agentgateway.dev/v1alpha1) in each Agentgateway version, compared to the version before it.
39 properties have been added
25 properties have changed the description
Released · View AgentgatewayBackend in v1.6.0
95 properties have been added
13 properties are now required
34 properties are no longer required
71 properties have changed the description
Released · View AgentgatewayBackend in v1.5.0
4 properties have been added
Released · View AgentgatewayBackend in v1.4.1
59 properties have been added
44 properties have been removed
390 properties have changed the description
Released · View AgentgatewayBackend in v1.4.0
2 properties have changed the description
Released · View AgentgatewayBackend in v1.3.1
168 properties have been added
65 properties are now required
13 properties are no longer required
749 properties have changed the description
Released · View AgentgatewayBackend in v1.3.0
45 properties have been added
22 properties have been removed
2 properties are no longer required
23 properties have changed the description
Released · View AgentgatewayBackend in v1.2.0
3 properties have been added
1 property has been removed
3 properties are no longer required
603 properties have changed the description
Released · View AgentgatewayBackend in v1.1.0
1 property has been added
Released · View AgentgatewayBackend in v1.0.1
AgentgatewayBackend was already present in this version of Agentgateway, the oldest one on kubespec.dev
Released · View AgentgatewayBackend in v1.0.0
No examples of AgentgatewayBackend yet. Contribute one on GitHub.