Skip to content
✨ agentgateway has joined the Agentic AI Foundation (AAIF) — Learn more

For the complete documentation index, see llms.txt. Markdown versions of all docs pages are available by appending .md to any docs URL.

Page as Markdown

API reference (single page)

Review the API reference for agentgateway custom resources.

Review the API reference documentation for agentgateway on Kubernetes.

Looking for the standalone mode of agentgateway? Check out the Configuration reference.

Packages

agentgateway.dev/v1alpha1

Resource Types

A2ABackend

A2A backend endpoint.

Appears in:

FieldDescriptionDefaultValidation
host ShortStringHostname or IP address of the A2A backend.MaxLength: 256
MinLength: 1
Required: {}
port integerPort number of the A2A backend.Maximum: 65535
Minimum: 1
Required: {}

AIBackend

AI backend configuration.

Validation:

  • ExactlyOneOf: [provider groups]

Appears in:

FieldDescriptionDefaultValidation
provider LLMProviderConfiguration for how to reach the configured LLM
provider.
ExactlyOneOf: [openai azureopenai azure anthropic gemini vertexai bedrock custom]
Optional: {}
groups PriorityGroup arrayGroups 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
MaxItems: 8
MinItems: 1
Optional: {}

AIPromptEnrichment

Enriches requests sent to the LLM provider by appending and prepending system prompts.

Prompt enrichment allows you to add additional context to the prompt before sending it to the model. Unlike RAG or other dynamic context methods, prompt enrichment is static and is applied to every request.

Note: Some providers, including Anthropic, do not support SYSTEM role messages, and instead have a dedicated system field in the input JSON. In this case, use the defaults setting to set the system field.

The following example prepends a system prompt of Answer all questions in French. and appends Describe the painting as if you were a famous art critic from the 17th century. to each request that is sent to the openai HTTPRoute.

name: openai-opt
namespace: agentgateway-system

spec:

targetRefs:
- group: gateway.networking.k8s.io
  kind: HTTPRoute
  name: openai
ai:
    promptEnrichment:
      prepend:
      - role: SYSTEM
        content: "Answer all questions in French."
      append:
      - role: USER
        content: "Describe the painting as if you were a famous art critic from the 17th century."

Appears in:

FieldDescriptionDefaultValidation
prepend Message arrayMessages to prepend to the prompt sent by the client.Optional: {}
append Message arrayMessages to append to the prompt sent by the client.Optional: {}

AIPromptGuard

Prompt guards that block unwanted requests to the LLM provider and mask sensitive data. Prompt guards can be used to reject requests based on the content of the prompt, as well as mask responses based on the content of the response.

This example rejects any request prompts that contain the string “credit card”, and masks any credit card numbers in the response.

promptGuard:
	request:
	- response:
	    message: "Rejected due to inappropriate content"
	  regex:
	    action: REJECT
	    matches:
	    - pattern: "credit card"
	      name: "CC"
	response:
	- regex:
	    builtins:
	    - CREDIT_CARD
	    action: MASK

Appears in:

FieldDescriptionDefaultValidation
request PromptguardRequest arrayPrompt guards to apply to requests sent by the client.ExactlyOneOf: [regex webhook openAIModeration bedrockGuardrails googleModelArmor]
MaxItems: 8
MinItems: 1
Optional: {}
response PromptguardResponse arrayPrompt guards to apply to responses returned by the LLM provider.ExactlyOneOf: [regex webhook bedrockGuardrails googleModelArmor]
MaxItems: 8
MinItems: 1
Optional: {}

APIKeyAuthentication

Validation:

  • ExactlyOneOf: [secretRef secretSelector]

Appears in:

FieldDescriptionDefaultValidation
mode APIKeyAuthenticationModeValidation mode for API key authentication.StrictOptional: {}
secretRef LocalSecretObjectRefCredential source, defaulting to a Kubernetes
Secret, storing a set of API keys. If there are many Secret-backed
keys, secretSelector can be used instead.
Each entry in the credential data represents one API key. The key is an
arbitrary identifier. The value can either be:
* A string representing the API key.
* A JSON object with two fields, key and metadata. key contains
the API key. metadata contains arbitrary JSON metadata associated
with the key, which may be used by other policies. For example, you
may write an authorization policy allowing apiKey.group == 'sales'.
Example:
apiVersion: v1
kind: Secret
metadata:
name: api-key
stringData:
client1: |
{
“key”: “k-123”,
“metadata”: {
“group”: “sales”,
“created_at”: “2024-10-01T12:00:00Z”
}
}
client2: “k-456”
Optional: {}
secretSelector SecretSelectorSelects multiple Kubernetes Secret resources
containing API keys. It is Secret-only; use secretRef for other
credential kinds. If the same key is defined in multiple secrets, the
behavior is undefined.
Each entry in the Secret data represents one API key. The key is an
arbitrary identifier. The value can either be:
* A string representing the API key.
* A JSON object with two fields, key and metadata. key contains
the API key. metadata contains arbitrary JSON metadata associated
with the key, which may be used by other policies. For example, you
may write an authorization policy allowing apiKey.group == 'sales'.
Example:
apiVersion: v1
kind: Secret
metadata:
name: api-key
stringData:
client1: |
{
“key”: “k-123”,
“metadata”: {
“group”: “sales”,
“created_at”: “2024-10-01T12:00:00Z”
}
}
client2: “k-456”
Optional: {}
location AuthorizationExtractionLocationWhere API keys are read from.
If omitted, credentials are read from the Authorization header with the Bearer prefix.
ExactlyOneOf: [header queryParameter cookie expression]
Optional: {}

APIKeyAuthenticationMode

Underlying type: string

Appears in:

FieldDescription
StrictA valid API Key must be present.
This is the default option.
OptionalIf an API Key exists, validate it.
Warning: this allows requests without an API Key!
PermissiveRequests are never rejected for missing or invalid API keys.
Warning: this allows requests without a valid API key!

AWSGuardrailConfig

Appears in:

FieldDescriptionDefaultValidation
identifier ShortStringIdentifier of the Guardrail policy to use for the backend.MaxLength: 256
MinLength: 1
Required: {}
version ShortStringVersion of the Guardrail policy to use for the backend.MaxLength: 256
MinLength: 1
Required: {}

AccessLog

Per-request access log settings.

Appears in:

FieldDescriptionDefaultValidation
filter CELExpressionCEL expression used to filter logs. A log
will only be emitted if the expression evaluates to true.
MaxLength: 16384
MinLength: 1
Optional: {}
attributes LogTracingAttributesCustomizations to the key-value pairs that are
logged.
Optional: {}
otlp OtlpAccessLogOTLP access log export to an
OpenTelemetry-compatible backend.
Optional: {}

Action

Underlying type: string

Action to take if a regex pattern is matched in a request or response. This setting applies only to request matches. PromptguardResponse matches are always masked by default.

Appears in:

FieldDescription
MaskMask the matched data in the request.
RejectReject the request if the regex matches content in the request.

AgentExtAuthGRPC

Appears in:

FieldDescriptionDefaultValidation
contextExtensions object (keys:string, values:string)Additional arbitrary key-value pairs to
send to the authorization server in the context_extensions field.
MaxProperties: 64
Optional: {}
requestMetadata object (keys:string, values:CELExpression)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.
MaxProperties: 64
Optional: {}

AgentExtAuthHTTP

Appears in:

FieldDescriptionDefaultValidation
path CELExpressionPath 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.
MaxLength: 16384
MinLength: 1
Optional: {}
redirect CELExpressionOptional expression that determines a path to
redirect to on authorization failure. This is useful to redirect to a
sign-in page.
MaxLength: 16384
MinLength: 1
Optional: {}
allowedRequestHeaders ShortString arrayAdditional headers from the client request that
will be sent to the authorization server.
If unset, the following headers are sent by default: Authorization.
MaxItems: 64
MaxLength: 256
MinLength: 1
Optional: {}
addRequestHeaders object (keys:string, values:CELExpression)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.
MaxProperties: 64
Optional: {}
allowedResponseHeaders ShortString arrayHeaders from the authorization response that
will be copied into the request to the backend.
MaxItems: 64
MaxLength: 256
MinLength: 1
Optional: {}
responseMetadata object (keys:string, values:CELExpression)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.
MaxProperties: 64
Optional: {}

AgentgatewayBackend

FieldDescriptionDefaultValidation
apiVersion stringagentgateway.dev/v1alpha1
kind stringAgentgatewayBackend
kind stringKind 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
Optional: {}
apiVersion stringAPIVersion 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
Optional: {}
metadata ObjectMetaRefer to Kubernetes API documentation for fields of metadata.Optional: {}
spec AgentgatewayBackendSpecDesired backend configuration.ExactlyOneOf: [ai static dynamicForwardProxy mcp aws a2a]
Required: {}
status AgentgatewayBackendStatusCurrent backend status.Optional: {}

AgentgatewayBackendSpec

Validation:

  • ExactlyOneOf: [ai static dynamicForwardProxy mcp aws a2a]

Appears in:

FieldDescriptionDefaultValidation
static StaticBackendStatic hostname, IP address, or Unix Domain Socket backend.Optional: {}
a2a A2ABackendA2A backend.Optional: {}
ai AIBackendLLM backend.ExactlyOneOf: [provider groups]
Optional: {}
mcp MCPBackendMCP backend.Optional: {}
dynamicForwardProxy DynamicForwardProxyBackendDynamically 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.
Optional: {}
aws AwsBackendAWS service backend, such as AgentCore.ExactlyOneOf: [agentCore]
Optional: {}
policies BackendFullPolicies 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.
Optional: {}

AgentgatewayBackendStatus

Current backend status.

Appears in:

FieldDescriptionDefaultValidation
conditions Condition arrayCurrent condition state for the backend.MaxItems: 8
Optional: {}

AgentgatewayParameters

Configures dynamic provisioning for the agentgateway data plane. Labels and annotations that apply to all resources may be specified at a higher level; see https://gateway-api.sigs.k8s.io/reference/api-spec/main/spec/#gatewayinfrastructure

FieldDescriptionDefaultValidation
apiVersion stringagentgateway.dev/v1alpha1
kind stringAgentgatewayParameters
kind stringKind 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
Optional: {}
apiVersion stringAPIVersion 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
Optional: {}
metadata ObjectMetaRefer to Kubernetes API documentation for fields of metadata.Optional: {}
spec AgentgatewayParametersSpecDesired data plane provisioning settings.Required: {}
status AgentgatewayParametersStatusCurrent status for these provisioning settings.Optional: {}

AgentgatewayParametersConfigs

Appears in:

FieldDescriptionDefaultValidation
logging AgentgatewayParametersLoggingLogging configuration. By default, all logs are set to
info level.
Optional: {}
rawConfig JSONRaw agentgateway configuration to merge into the generated config file.
This is merged with
configuration derived from typed fields like logging.format, and those
typed fields will take precedence.
Example:
rawConfig:
binds:
- port: 3000
listeners:
- routes:
- policies:
cors:
allowOrigins:
- “*"
allowHeaders:
- mcp-protocol-version
- content-type
- cache-control
backends:
- mcp:
targets:
- name: everything
stdio:
cmd: npx
args: ["@modelcontextprotocol/server-everything”]
Type: object
Optional: {}
image ImageThe agentgateway container image. See
https://kubernetes.io/docs/concepts/containers/images
for details.
Default values, which may be overridden individually:
registry: cr.agentgateway.dev
repository: agentgateway
tag:
pullPolicy: <omitted, relying on Kubernetes defaults which depend on the tag>
Optional: {}
env EnvVar arrayContainer environment variables. These override any existing
values. If you want to delete an environment variable entirely, use
$patch: delete with an overlay instead. Note that
variable
expansion

does apply, but is highly discouraged – to set dependent environment
variables, you can use $(VAR_NAME), but it’s highly discouraged.
$$(VAR_NAME) avoids expansion and results in a literal
$(VAR_NAME).
If SESSION_KEY is specified, it takes precedence over the
controller-managed per-Gateway session key Secret.
Optional: {}
resources ResourceRequirementsCompute resources required by this container. See
https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
for details.
Optional: {}
shutdown ShutdownSpecShutdown delay configuration. How graceful planned or unplanned data
plane changes happen is in tension with how quickly rollouts of the data
plane complete. How long a data plane pod must wait for shutdown to be
perfectly graceful depends on how you have configured your Gateway
resources.
Optional: {}
istio IstioSpecIstio integration settings. If enabled, agentgateway can natively connect to Istio-enabled pods with mTLS.Optional: {}

AgentgatewayParametersLogging

Appears in:

FieldDescriptionDefaultValidation
level stringLogging level in standard RUST_LOG syntax, for example info (the
default), or a comma-separated per-module setting such as
rmcp=warn,hickory_server::server::server_future=off,typespec_client_core::http::policies::logging=warn.
Optional: {}
format AgentgatewayParametersLoggingFormatLogging output format.Optional: {}

AgentgatewayParametersLoggingFormat

Underlying type: string

The default logging format is text.

Appears in:

FieldDescription
json
text

AgentgatewayParametersOverlays

Appears in:

FieldDescriptionDefaultValidation
deployment KubernetesResourceOverlayOverrides for the generated
Deployment resource.
Optional: {}
service KubernetesResourceOverlayOverrides for the generated Service
resource.
Optional: {}
serviceAccount KubernetesResourceOverlayOverrides for the generated
ServiceAccount resource.
Optional: {}
podDisruptionBudget KubernetesResourceOverlayCreates a PodDisruptionBudget for the
agentgateway proxy. If absent, no PDB is created. If present, a PDB is
created with its selector automatically configured to target the
agentgateway proxy Deployment. The metadata and spec fields from
this overlay are applied to the generated PDB.
Optional: {}
horizontalPodAutoscaler KubernetesResourceOverlayCreates a HorizontalPodAutoscaler
for the agentgateway proxy. If absent, no HPA is created. If present, an
HPA is created with its scaleTargetRef automatically configured to
target the agentgateway proxy Deployment. The metadata and spec
fields from this overlay are applied to the generated HPA.
Optional: {}

AgentgatewayParametersSpec

Appears in:

FieldDescriptionDefaultValidation
logging AgentgatewayParametersLoggingLogging configuration. By default, all logs are set to
info level.
Optional: {}
rawConfig JSONRaw agentgateway configuration to merge into the generated config file.
This is merged with
configuration derived from typed fields like logging.format, and those
typed fields will take precedence.
Example:
rawConfig:
binds:
- port: 3000
listeners:
- routes:
- policies:
cors:
allowOrigins:
- “*"
allowHeaders:
- mcp-protocol-version
- content-type
- cache-control
backends:
- mcp:
targets:
- name: everything
stdio:
cmd: npx
args: ["@modelcontextprotocol/server-everything”]
Type: object
Optional: {}
image ImageThe agentgateway container image. See
https://kubernetes.io/docs/concepts/containers/images
for details.
Default values, which may be overridden individually:
registry: cr.agentgateway.dev
repository: agentgateway
tag:
pullPolicy: <omitted, relying on Kubernetes defaults which depend on the tag>
Optional: {}
env EnvVar arrayContainer environment variables. These override any existing
values. If you want to delete an environment variable entirely, use
$patch: delete with an overlay instead. Note that
variable
expansion

does apply, but is highly discouraged – to set dependent environment
variables, you can use $(VAR_NAME), but it’s highly discouraged.
$$(VAR_NAME) avoids expansion and results in a literal
$(VAR_NAME).
If SESSION_KEY is specified, it takes precedence over the
controller-managed per-Gateway session key Secret.
Optional: {}
resources ResourceRequirementsCompute resources required by this container. See
https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
for details.
Optional: {}
shutdown ShutdownSpecShutdown delay configuration. How graceful planned or unplanned data
plane changes happen is in tension with how quickly rollouts of the data
plane complete. How long a data plane pod must wait for shutdown to be
perfectly graceful depends on how you have configured your Gateway
resources.
Optional: {}
istio IstioSpecIstio integration settings. If enabled, agentgateway can natively connect to Istio-enabled pods with mTLS.Optional: {}
deployment KubernetesResourceOverlayOverrides for the generated
Deployment resource.
Optional: {}
service KubernetesResourceOverlayOverrides for the generated Service
resource.
Optional: {}
serviceAccount KubernetesResourceOverlayOverrides for the generated
ServiceAccount resource.
Optional: {}
podDisruptionBudget KubernetesResourceOverlayCreates a PodDisruptionBudget for the
agentgateway proxy. If absent, no PDB is created. If present, a PDB is
created with its selector automatically configured to target the
agentgateway proxy Deployment. The metadata and spec fields from
this overlay are applied to the generated PDB.
Optional: {}
horizontalPodAutoscaler KubernetesResourceOverlayCreates a HorizontalPodAutoscaler
for the agentgateway proxy. If absent, no HPA is created. If present, an
HPA is created with its scaleTargetRef automatically configured to
target the agentgateway proxy Deployment. The metadata and spec
fields from this overlay are applied to the generated HPA.
Optional: {}

AgentgatewayParametersStatus

Current status for these provisioning settings.

Appears in:

AgentgatewayPolicy

FieldDescriptionDefaultValidation
apiVersion stringagentgateway.dev/v1alpha1
kind stringAgentgatewayPolicy
kind stringKind 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
Optional: {}
apiVersion stringAPIVersion 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
Optional: {}
metadata ObjectMetaRefer to Kubernetes API documentation for fields of metadata.Optional: {}
spec AgentgatewayPolicySpecDesired policy configuration.ExactlyOneOf: [targetRefs targetSelectors]
Required: {}
status PolicyStatusCurrent policy status.Optional: {}

AgentgatewayPolicySpec

Validation:

  • ExactlyOneOf: [targetRefs targetSelectors]

Appears in:

FieldDescriptionDefaultValidation
targetRefs LocalPolicyTargetReferenceWithSectionName arrayTarget resources to attach the
policy to.
MaxItems: 16
MinItems: 1
Optional: {}
targetSelectors LocalPolicyTargetSelectorWithSectionName arrayTarget selectors used to select resources to attach the policy to.MaxItems: 16
MinItems: 1
Optional: {}
strategy PolicyStrategyPolicy merge and conflict resolution strategy.
Strategy settings apply to the policy object as a whole. Individual strategy fields may
only be valid for specific policy kinds; for example, inheritance is only valid when this
policy contains traffic settings.
Optional: {}
frontend FrontendSettings for how to handle incoming traffic.
A frontend policy can only target a Gateway. Listener and
ListenerSet are not valid targets.
When multiple policies are selected for a given request, they are merged on a field-level basis, but not a deep
merge. For example, policy A sets tcp and tls, and policy B sets
tls; the effective policy would be tcp from policy A, and tls from
policy B.
Optional: {}
traffic TrafficSettings for how to process traffic.
A traffic policy can target a Gateway (optionally, with a
sectionName indicating the listener), ListenerSet, or Route
(optionally, with a sectionName indicating the route rule).
When multiple policies are selected for a given request, they are merged on a field-level basis, but not a deep
merge. Precedence is given to more precise policies: Gateway «br />Listener < Route < Route Rule. For example, policy A sets
timeouts and retries, and policy B sets retries; the effective
policy would be timeouts from policy A, and retries from policy B.
Optional: {}
backend BackendFullSettings for how to connect to destination backends.
A backend policy can target a Gateway (optionally, with a
sectionName indicating the listener), ListenerSet, Route
(optionally, with a sectionName indicating the route rule), or a
Service or Backend (optionally, with a sectionName indicating the
port for Service, or sub-backend for Backend).
Note that a backend policy applies when connecting to a specific destination backend. Targeting a higher level
resource, like Gateway, is just a way to easily apply a policy to a
group of backends.
When multiple policies are selected for a given request, they are merged on a field-level basis, but not a deep
merge. Precedence is given to more precise policies: Gateway «br />Listener < Route < Route Rule < Backend or Service. For
example, if a Gateway policy sets tcp and tls, and a Backend
policy sets tls, the effective policy would be tcp from the
Gateway, and tls from the Backend.
Optional: {}

AnthropicConfig

Settings for the Anthropic LLM provider.

Appears in:

FieldDescriptionDefaultValidation
model ShortStringModel name override, such as gpt-4o-mini.
If unset, the model name is taken from the request.
MaxLength: 256
MinLength: 1
Optional: {}

AttributeAdd

Appears in:

FieldDescriptionDefaultValidation
name ShortStringMaxLength: 256
MinLength: 1
Required: {}
expression CELExpressionMaxLength: 16384
MinLength: 1
Required: {}

Authorization

Configures CEL-based authorization.

Appears in:

FieldDescriptionDefaultValidation
policy AuthorizationPolicyThe 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.
A CEL expression that fails to evaluate does not match. Prefer Require
for deny-by-default behavior.
If at least one Allow rule is configured, requests are denied unless at
least one allow rule matches.
Required: {}
action AuthorizationPolicyActionThe effect of this rule when it matches.
If unspecified, defaults to Allow.
Require rules are cumulative: all require rules must match.
AllowOptional: {}

AuthorizationCookieLocation

Appears in:

FieldDescriptionDefaultValidation
name stringMaxLength: 256
MinLength: 1
Required: {}

AuthorizationExtractionLocation

Validation:

  • ExactlyOneOf: [header queryParameter cookie expression]

Appears in:

FieldDescriptionDefaultValidation
header AuthorizationHeaderLocationOptional: {}
queryParameter AuthorizationQueryParameterLocationOptional: {}
cookie AuthorizationCookieLocationOptional: {}
expression CELExpressionCEL expression that extracts the credential from the request.MaxLength: 16384
MinLength: 1
Optional: {}

AuthorizationHeaderLocation

Appears in:

FieldDescriptionDefaultValidation
name HTTPHeaderNameMaxLength: 256
MinLength: 1
Pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
Required: {}
prefix stringMaxLength: 256
MinLength: 1
Optional: {}

AuthorizationLocation

Validation:

  • ExactlyOneOf: [header queryParameter cookie]

Appears in:

FieldDescriptionDefaultValidation
header AuthorizationHeaderLocationOptional: {}
queryParameter AuthorizationQueryParameterLocationOptional: {}
cookie AuthorizationCookieLocationOptional: {}

AuthorizationLocationFields

Appears in:

FieldDescriptionDefaultValidation
header AuthorizationHeaderLocationOptional: {}
queryParameter AuthorizationQueryParameterLocationOptional: {}
cookie AuthorizationCookieLocationOptional: {}

AuthorizationPolicy

Defines CEL expressions for a single authorization rule.

Appears in:

FieldDescriptionDefaultValidation
matchExpressions CELExpression arrayCEL expressions that must all evaluate to true for the rule to match.MaxItems: 256
MaxLength: 16384
MinItems: 1
MinLength: 1
Required: {}

AuthorizationPolicyAction

Underlying type: string

AuthorizationPolicyAction defines the action to take when the RBACPolicies matches.

Appears in:

FieldDescription
AllowAuthorizationPolicyActionAllow defines the action to take when the
RBACPolicies matches.
DenyAuthorizationPolicyActionDeny denies the action to take when the
RBACPolicies matches.
RequireAuthorizationPolicyActionRequire requires the action to take when the RBACPolicies matches.

AuthorizationQueryParameterLocation

Appears in:

FieldDescriptionDefaultValidation
name stringMaxLength: 256
MinLength: 1
Required: {}

AwsAgentCoreBackend

Configures Amazon Bedrock AgentCore.

Appears in:

FieldDescriptionDefaultValidation
agentRuntimeArn stringARN of the AgentCore runtime.Required: {}
qualifier stringAlias or version qualifier.Optional: {}

AwsAssumeRole

AWS STS AssumeRole settings for backend authentication.

Appears in:

FieldDescriptionDefaultValidation
roleArn stringAWS IAM role ARN to assume.MinLength: 1
Pattern: ^arn:aws[a-z-]*:iam::[0-9]\{12\}:role/.+$
Required: {}

AwsAuth

AWS authentication settings for the backend.

Appears in:

FieldDescriptionDefaultValidation
secretRef LocalSecretObjectRefCredential source, defaulting to a Kubernetes
Secret, containing the AWS credentials. When using the default Secret
resolver, the Secret must have keys accessKey, secretKey, and
optionally sessionToken.
Optional: {}
assumeRole AwsAssumeRoleAWS STS AssumeRole settings to use before signing backend requests.
Ambient AWS credentials are used as the source credentials for STS.
Optional: {}
serviceName ShortStringAWS SigV4 signing service name, for example
bedrock, bedrock-agentcore, or execute-api). If unset, typed AWS
backends may provide this automatically.
MaxLength: 256
MinLength: 1
Optional: {}

AwsBackend

Configures an AWS service backend.

Validation:

  • ExactlyOneOf: [agentCore]

Appears in:

FieldDescriptionDefaultValidation
agentCore AwsAgentCoreBackendAmazon Bedrock AgentCore backend settings.Optional: {}

AzureAuth

Appears in:

FieldDescriptionDefaultValidation
secretRef LocalSecretObjectRefCredential source, defaulting to a Kubernetes
Secret, containing the Azure credentials. When using the default Secret
resolver, the Secret must have keys clientID, tenantID, and
clientSecret.
Optional: {}
managedIdentity AzureManagedIdentityManaged identity authentication settings.Optional: {}

AzureConfig

Settings for Azure AI backends, supporting both Azure OpenAI and Azure AI Foundry.

Appears in:

FieldDescriptionDefaultValidation
resourceName ShortStringThe 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.
MaxLength: 256
MinLength: 1
Required: {}
resourceType AzureResourceTypeThe type of Azure endpoint. Determines the host suffix.Required: {}
model ShortStringModel name override, such as gpt-4o-mini.
If unset, the model name is taken from the request.
MaxLength: 256
MinLength: 1
Optional: {}
apiVersion TinyStringThe version of the Azure OpenAI API to use.
If unset, defaults to v1.
MaxLength: 64
MinLength: 1
Optional: {}
projectName ShortStringThe Foundry project name, required when resourceType is Foundry.
Used to construct paths: /api/projects/{projectName}/openai/v1/…
MaxLength: 256
MinLength: 1
Optional: {}

AzureManagedIdentity

Appears in:

FieldDescriptionDefaultValidation
clientId stringRequired: {}
objectId stringRequired: {}
resourceId stringRequired: {}

AzureOpenAIConfig

Settings for the Azure OpenAI LLM provider.

Appears in:

FieldDescriptionDefaultValidation
endpoint ShortStringThe endpoint for the Azure OpenAI API to use, such as my-endpoint.openai.azure.com.
If the scheme is included, it is stripped.
MaxLength: 256
MinLength: 1
Required: {}
deploymentName ShortStringThe name of the Azure OpenAI model deployment to use.
For more information, see the Azure OpenAI model docs.
This is required if apiVersion is not v1. For v1, the model can be
set in the request.
MaxLength: 256
MinLength: 1
Optional: {}
apiVersion TinyStringThe version of the Azure OpenAI API to use.
For more information, see the Azure OpenAI API version reference.
If unset, defaults to v1.
MaxLength: 64
MinLength: 1
Optional: {}

AzureResourceType

Underlying type: string

Type of Azure endpoint.

Appears in:

FieldDescription
OpenAIAzureResourceTypeOpenAI uses the Azure OpenAI endpoint: {resourceName}.openai.azure.com
FoundryAzureResourceTypeFoundry uses the Azure AI Foundry endpoint: {resourceName}.services.ai.azure.com

BackendAI

Appears in:

FieldDescriptionDefaultValidation
prompt AIPromptEnrichmentEnriches 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.
Optional: {}
promptGuard AIPromptGuardGuardrails for LLM requests and responses.Optional: {}
defaults FieldDefault arrayDefaults to merge with user input fields. If the field is already set, the field in the request is used.MaxItems: 64
MinItems: 1
Optional: {}
overrides FieldDefault arrayOverrides to merge with user input fields. If the field is already set, the field is overwritten.MaxItems: 64
MinItems: 1
Optional: {}
transformations FieldTransformation arrayCEL 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.
MaxItems: 64
MinItems: 1
Optional: {}
modelAliases object (keys:string, values:string)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.
MaxProperties: 64
Optional: {}
promptCaching PromptCachingConfigAutomatic 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.
Optional: {}
routes object (keys:string, values:RouteType)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.
Optional: {}

BackendAuth

Validation:

  • ExactlyOneOf: [key secretRef passthrough aws azure gcp]

Appears in:

FieldDescriptionDefaultValidation
key stringInline key to use as the value of the
Authorization header. This option is the least secure; usage of a
Secret is preferred.
MaxLength: 2048
Optional: {}
secretRef LocalSecretObjectRefCredential source, defaulting to a Kubernetes
Secret, storing the key to use as the authorization value. When using
the default Secret resolver, this must be stored in the Authorization
key.
Optional: {}
passthrough BackendAuthPassthroughPasses through an existing token that has been sent by the
client and validated. Other policies, like JWT and API key
authentication, will strip the original client credentials. Passthrough backend authentication
causes the original token to be added back into the request. If there are no client authentication policies on the
request, the original token would be unchanged, so this would have no effect.
Optional: {}
aws AwsAuthExplicit AWS authentication method for the backend.
When omitted, default AWS SDK credential discovery is used.
Optional: {}
azure AzureAuthAzure authentication method for the backend.Optional: {}
gcp GcpAuthGoogle authentication method for the backend.
When omitted, default Google credential discovery is used.
Optional: {}
location AuthorizationLocationWhere backend credentials are inserted.
If omitted, credentials are written to the Authorization header with the Bearer prefix.
This applies to key, secretRef, and passthrough.
ExactlyOneOf: [header queryParameter cookie]
Optional: {}

BackendAuthPassthrough

Appears in:

BackendEviction

Settings for evicting unhealthy backends.

Appears in:

FieldDescriptionDefaultValidation
duration DurationBase 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.
3sOptional: {}
restoreHealth integerHealth 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.
Maximum: 100
Minimum: 0
Optional: {}
consecutiveFailures integerNumber 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.
Minimum: 0
Optional: {}
healthThreshold integerEWMA health score threshold, expressed as 0 to 100.
When set, a backend is only evicted if its computed health drops below this value after an unhealthy response.
For example, 50 means the backend is evicted when its EWMA health falls below 50% following failures.
Unlike consecutiveFailures (which counts consecutive failures), this uses a sliding-window average
so a single success in a stream of failures can delay eviction.
When both consecutiveFailures and healthThreshold are set, the backend is evicted when either condition is met.
When neither is set, a single unhealthy response triggers eviction.
Maximum: 100
Minimum: 0
Optional: {}

BackendFull

Appears in:

FieldDescriptionDefaultValidation
tcp BackendTCPSettings for managing TCP connections to the backend.Optional: {}
tls BackendTLSSettings for managing TLS connections to the backend.
If this field is set, TLS will be initiated to the backend; the system trusted CA certificates will be used to
validate the server, and the SNI will automatically be set based on the destination.
AtMostOneOf: [verifySubjectAltNames insecureSkipVerify]
Optional: {}
http BackendHTTPSettings for managing HTTP requests to the backend.Optional: {}
tunnel BackendTunnelSettings for managing tunnel connections, with behavior like HTTPS_PROXY, to the backend.Optional: {}
auth BackendAuthSettings for managing authentication to the backend.ExactlyOneOf: [key secretRef passthrough aws azure gcp]
Optional: {}
ai BackendAISettings for AI workloads. This is only applicable when
connecting to a Backend of type ai.
Optional: {}
mcp BackendMCPSettings for MCP workloads. This is only applicable when
connecting to a Backend of type mcp.
Optional: {}
transformation TransformationMutates and transforms requests and responses sent to and from the backend.Optional: {}
health HealthSettings for passive and active health checking.Optional: {}
extAuth ExtAuthExternal authentication configuration for requests
sent to this backend.
Optional: {}

BackendHTTP

Appears in:

FieldDescriptionDefaultValidation
version HTTPVersionHTTP protocol version to use when connecting to
the backend.
If not specified, the version is automatically determined:
* Service types can specify it with appProtocol on the Service
port.
* If traffic is identified as gRPC, HTTP2 is used.
* If the incoming traffic was plaintext HTTP, the original protocol will
be used.
* If the incoming traffic was HTTPS, HTTP1 will be used. This is
because most clients will transparently upgrade HTTPS traffic to
HTTP2, even if the backend doesn’t support it.
Optional: {}
requestTimeout DurationDeadline for receiving a response from the backend.Optional: {}

BackendMCP

Appears in:

FieldDescriptionDefaultValidation
authorization AuthorizationMCP 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.
Optional: {}
authentication MCPAuthenticationMCP 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.
Optional: {}

BackendSimple

Appears in:

FieldDescriptionDefaultValidation
tcp BackendTCPSettings for managing TCP connections to the backend.Optional: {}
tls BackendTLSSettings for managing TLS connections to the backend.
If this field is set, TLS will be initiated to the backend; the system trusted CA certificates will be used to
validate the server, and the SNI will automatically be set based on the destination.
AtMostOneOf: [verifySubjectAltNames insecureSkipVerify]
Optional: {}
http BackendHTTPSettings for managing HTTP requests to the backend.Optional: {}
tunnel BackendTunnelSettings for managing tunnel connections, with behavior like HTTPS_PROXY, to the backend.Optional: {}
auth BackendAuthSettings for managing authentication to the backend.ExactlyOneOf: [key secretRef passthrough aws azure gcp]
Optional: {}

BackendTCP

Appears in:

FieldDescriptionDefaultValidation
keepalive KeepaliveSettings for enabling TCP keepalives on the
connection.
Optional: {}
connectTimeout DurationDeadline for establishing a connection to
the destination.
Optional: {}

BackendTLS

Validation:

  • AtMostOneOf: [verifySubjectAltNames insecureSkipVerify]

Appears in:

FieldDescriptionDefaultValidation
mtlsCertificateRef LocalSecretObjectRef arrayEnables mutual TLS to the backend, using the
specified key (tls.key) and cert (tls.crt) from the referenced
credential source, defaulting to a Kubernetes Secret.
An optional ca.cert field, if present, will be used to verify the
server certificate. If caCertificateRefs is also specified, the
caCertificateRefs field takes priority.
If unspecified, no client certificate will be used.
MaxItems: 1
Optional: {}
caCertificateRefs LocalObjectReference arrayCA certificate ConfigMap to use to
verify the server certificate.
If unset, the system’s trusted certificates are used.
MaxItems: 1
Optional: {}
insecureSkipVerify InsecureTLSModeOriginates TLS but skips verification of the backend’s certificate.
WARNING: This is an insecure option that should only be used if the risks are understood.
There are two modes:
* All disables all TLS verification.
* Hostname verifies the CA certificate is trusted, but ignores any
mismatch of hostname or SANs. Note that this method is still insecure;
prefer setting verifySubjectAltNames to customize the valid hostnames
if possible.
Optional: {}
sni SNIServer Name Indicator (SNI) to use in the TLS
handshake. If unset, the SNI is automatically set based on the
destination hostname.
MaxLength: 253
MinLength: 1
Pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
Optional: {}
verifySubjectAltNames ShortString arraySubject Alternative Names (SAN)
to verify in the server certificate.
If not present, the destination hostname is automatically used.
MaxItems: 16
MaxLength: 256
MinItems: 1
MinLength: 1
Optional: {}
alpnProtocols TinyStringApplication-Layer Protocol Negotiation (ALPN)
value to use in the TLS handshake.
If not present, defaults to ["h2", "http/1.1"].
MaxItems: 16
MaxLength: 64
MinItems: 1
MinLength: 1
Optional: {}
keyExchangeGroups KeyExchangeGroup arrayOrdered list of key exchange groups for a TLS connection.
For example: X25519_MLKEM768,X25519.
Optional: {}

BackendTunnel

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceProxy server to reach.
Supported types: Service and Backend.
Required: {}

BackendWithAI

Appears in:

FieldDescriptionDefaultValidation
tcp BackendTCPSettings for managing TCP connections to the backend.Optional: {}
tls BackendTLSSettings for managing TLS connections to the backend.
If this field is set, TLS will be initiated to the backend; the system trusted CA certificates will be used to
validate the server, and the SNI will automatically be set based on the destination.
AtMostOneOf: [verifySubjectAltNames insecureSkipVerify]
Optional: {}
http BackendHTTPSettings for managing HTTP requests to the backend.Optional: {}
tunnel BackendTunnelSettings for managing tunnel connections, with behavior like HTTPS_PROXY, to the backend.Optional: {}
auth BackendAuthSettings for managing authentication to the backend.ExactlyOneOf: [key secretRef passthrough aws azure gcp]
Optional: {}
ai BackendAISettings for AI workloads. This is only applicable when
connecting to a Backend of type ai.
Optional: {}
transformation TransformationMutates and transforms requests and responses sent to and from the backend.Optional: {}
health HealthSettings for passive and active health checking.Optional: {}

BasicAuthentication

Validation:

  • ExactlyOneOf: [users secretRef]

Appears in:

FieldDescriptionDefaultValidation
mode BasicAuthenticationModeValidation mode for basic authentication.StrictOptional: {}
realm stringrealm value to return in the WWW-Authenticate
header for failed authentication requests. If unset, Restricted will
be used.
Optional: {}
users string arrayInline list of username and password pairs that will
be accepted. Each entry represents one line of the htpasswd format:
https://httpd.apache.org/docs/2.4/programs/htpasswd.html.
Note: passwords should be the hash of the password, not the raw password. Use the htpasswd or similar commands
to generate a hash. MD5, bcrypt, crypt, and SHA-1 are supported.
Example:
users:
- “user1:$apr1$ivPt0D4C$DmRhnewfHRSrb3DQC.WHC."
- “user2:$2y$05$r3J4d3VepzFkedkd/q1vI.pBYIpSqjfN0qOARV3ScUHysatnS0cL2”
MaxItems: 256
MinItems: 1
Optional: {}
secretRef LocalSecretObjectRefCredential source, defaulting to a Kubernetes
Secret, storing the .htaccess file. When using the default Secret
resolver, the Secret must have a key named .htaccess, and should
contain the complete .htaccess file.
Note: passwords should be the hash of the password, not the raw password. Use the htpasswd or similar commands
to generate a hash. MD5, bcrypt, crypt, and SHA-1 are supported.
Example:
apiVersion: v1
kind: Secret
metadata:
name: basic-auth
stringData:
.htaccess: |
alice:$apr1$3zSE0Abt$IuETi4l5yO87MuOrbSE4V.
bob:$apr1$Ukb5LgRD$EPY2lIfY.A54jzLELNIId/
Optional: {}
location AuthorizationExtractionLocationWhere Basic credentials are read from.
If omitted, credentials are read from the Authorization header with the Basic prefix.
ExactlyOneOf: [header queryParameter cookie expression]
Optional: {}

BasicAuthenticationMode

Underlying type: string

Appears in:

FieldDescription
StrictA valid username and password must be present.
This is the default option.
OptionalIf a username and password exists, validate it.
Warning: this allows requests without a username!

BedrockConfig

Appears in:

FieldDescriptionDefaultValidation
region stringAWS region to use for the backend.
Defaults to us-east-1 if not specified.
us-east-1MaxLength: 63
MinLength: 1
Pattern: ^[a-z0-9-]+$
Optional: {}
model ShortStringModel name override, such as gpt-4o-mini.
If unset, the model name is taken from the request.
MaxLength: 256
MinLength: 1
Optional: {}
guardrail AWSGuardrailConfigGuardrail 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.
Optional: {}

BedrockGuardrails

Appears in:

FieldDescriptionDefaultValidation
identifier ShortStringIdentifier of the Guardrail policy to use for the backend.MaxLength: 256
MinLength: 1
Required: {}
version ShortStringVersion of the Guardrail policy to use for the backend.MaxLength: 256
MinLength: 1
Required: {}
region ShortStringAWS region where the guardrail is deployed, for example
us-west-2).
MaxLength: 256
MinLength: 1
Required: {}
policies BackendSimplePolicies for communicating with AWS Bedrock Guardrails.Optional: {}

BodySendMode

Underlying type: string

How HTTP bodies are delivered to the external processor.

Validation:

  • Enum: [None Buffered BufferedPartial FullDuplexStreamed]

Appears in:

FieldDescription
NoneBodySendModeNone does not send the body to the external processor.
BufferedBodySendModeBuffered buffers the full body before sending it to the
external processor. It returns an error if the body exceeds 8KB.
BufferedPartialBodySendModeBufferedPartial buffers up to 8KB. If the body exceeds that
limit, it sends the buffered prefix instead of returning an error.
FullDuplexStreamedBodySendModeFullDuplexStreamed streams the body to the external processor.

Buffer

Appears in:

FieldDescriptionDefaultValidation
request BufferBodyRequest body buffering settings.Optional: {}
response BufferBodyResponse body buffering settings.Optional: {}

BufferBody

Appears in:

FieldDescriptionDefaultValidation
maxBytes ByteSizeMaximum number of bytes to buffer from the request or response body.
If unset, defaults to the global proxy setting, which defaults to 2Mi.
MaxLength: 32
MinLength: 1
Pattern: ^[+-]?([0-9]+(\.[0-9]*)?|\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\+?0*([0-9]|1[0-8])|-0*[0-9]))?$
XIntOrString: {}
Optional: {}

BuiltIn

Underlying type: string

Built-in regex patterns for specific types of strings in prompts. For example, if you specify CreditCard, any credit card numbers in the request or response are matched.

Appears in:

FieldDescription
SsnDefault regex matching for Social Security numbers.
CreditCardDefault regex matching for credit card numbers.
PhoneNumberDefault regex matching for phone numbers.
EmailDefault regex matching for email addresses.
CaSinDefault regex matching for Canadian Social Insurance Numbers.

ByteSize

Byte quantity that must fit in the data plane size limit.

Validation:

  • MaxLength: 32
  • MinLength: 1
  • Pattern: ^[+-]?([0-9]+(\.[0-9]*)?|\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\+?0*([0-9]|1[0-8])|-0*[0-9]))?$
  • XIntOrString: {}

Appears in:

CELExpression

Underlying type: string

A Common Expression Language (CEL) expression.

Validation:

  • MaxLength: 16384
  • MinLength: 1

Appears in:

CORS

Appears in:

CSRF

Appears in:

FieldDescriptionDefaultValidation
additionalOrigins ShortString arrayAdditional source origins that will be
allowed in addition to the destination origin. The Origin consists of
a scheme and a host, with an optional port, and takes the form
<scheme>://<host>(:<port>).
MaxItems: 16
MaxLength: 256
MinItems: 1
MinLength: 1
Optional: {}

CipherSuite

Underlying type: string

Appears in:

FieldDescription
TLS13_AES_256_GCM_SHA384TLS 1.3 cipher suites
TLS13_AES_128_GCM_SHA256
TLS13_CHACHA20_POLY1305_SHA256
TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384TLS 1.2 cipher suites
TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256
TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256

CustomProvider

Provider with explicit API format support and an explicit target. Use this for local, self-hosted, or OpenAI-compatible providers whose supported request/response formats are not fully described by the managed provider types.

Appears in:

FieldDescriptionDefaultValidation
backendRef LocalBackendObjectReferenceKubernetes 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.
Optional: {}
model ShortStringModel name override, such as gpt-oss.
If unset, the model name is taken from the request.
MaxLength: 256
MinLength: 1
Optional: {}
formats ProviderFormatConfig arrayProvider-native API formats this provider supports.MaxItems: 6
MinItems: 1
Required: {}

CustomResponse

Response to return to the client if request content is matched against a regex pattern and the action is REJECT.

Appears in:

FieldDescriptionDefaultValidation
message stringCustom response message to return to the client. If not specified, defaults to
The request was rejected due to inappropriate content.
The request was rejected due to inappropriate contentOptional: {}
statusCode integerStatus code to return to the client. Defaults to 403.403Maximum: 599
Minimum: 200
Optional: {}

DirectResponse

Direct response policy.

Appears in:

FieldDescriptionDefaultValidation
status integerHTTP status code to return.Maximum: 599
Minimum: 200
Optional: {}
body stringContent to return in the HTTP response body.
The maximum length of the body is restricted to prevent excessively large responses.
If this field is omitted, no body is included in the response.
MaxLength: 4096
MinLength: 1
Optional: {}
bodyExpression CELExpressionCEL expression that produces the HTTP response body.
Strings and bytes are written directly; other values are serialized as JSON.
If this field is omitted, no expression body is included in the response.
MaxLength: 16384
MinLength: 1
Optional: {}
headers DirectResponseHeader arrayResponse headers to set on the direct response.MaxItems: 16
MinItems: 1
Optional: {}

DirectResponseConditional

Appears in:

FieldDescriptionDefaultValidation
condition CELExpressionCEL expression that must evaluate to true for this policy to execute.MaxLength: 16384
MinLength: 1
Optional: {}
policy DirectResponsePolicy to apply when the condition matches.Required: {}

DirectResponseHeader

Appears in:

FieldDescriptionDefaultValidation
name HTTPHeaderNameThe name of the header to set.MaxLength: 256
MinLength: 1
Pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
Required: {}
value CELExpressionCEL expression that generates the output value for
the header.
MaxLength: 16384
MinLength: 1
Required: {}

DirectResponseOrConditional

Appears in:

FieldDescriptionDefaultValidation
status integerHTTP status code to return.Maximum: 599
Minimum: 200
Optional: {}
body stringContent to return in the HTTP response body.
The maximum length of the body is restricted to prevent excessively large responses.
If this field is omitted, no body is included in the response.
MaxLength: 4096
MinLength: 1
Optional: {}
bodyExpression CELExpressionCEL expression that produces the HTTP response body.
Strings and bytes are written directly; other values are serialized as JSON.
If this field is omitted, no expression body is included in the response.
MaxLength: 16384
MinLength: 1
Optional: {}
headers DirectResponseHeader arrayResponse headers to set on the direct response.MaxItems: 16
MinItems: 1
Optional: {}
conditional DirectResponseConditional arrayConditional policy execution. Set this or the top-level directResponse fields.
The first matching policy will be executed.
A single policy may be provided without a condition set; if so, it must be the last policy and will be the fallback
in case no conditions are met.
MaxItems: 16
MinItems: 1
Optional: {}

DynamicForwardProxyBackend

Appears in:

ExtAuth

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceExternal Authorization server to reach.
Supported types: Service and Backend.
Optional: {}
failureMode FailureModeBehavior when the external authorization service is
unavailable or returns an error. “FailOpen” allows the request to continue.
“FailClosed” (default) denies the request.
Optional: {}
grpc AgentExtAuthGRPCUses the gRPC External Authorization
protocol should be used.
Optional: {}
http AgentExtAuthHTTPUses HTTP to connect to
the authorization server. The authorization server must return a 200
status code, otherwise the request is considered an authorization
failure.
Optional: {}
forwardBody ExtAuthBodyWhether to include the HTTP body in the authorization request.
If enabled, the request body will be buffered.
Optional: {}
cache ExtAuthCacheCaches gRPC 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.
Optional: {}

ExtAuthBody

Appears in:

FieldDescriptionDefaultValidation
maxSize ByteSizeLargest 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.
MaxLength: 32
MinLength: 1
Pattern: ^[+-]?([0-9]+(\.[0-9]*)?|\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\+?0*([0-9]|1[0-8])|-0*[0-9]))?$
XIntOrString: {}
Required: {}

ExtAuthCache

Appears in:

FieldDescriptionDefaultValidation
key CELExpression arrayOrdered list of CEL expressions evaluated against the request
to construct the cache key.
MaxItems: 16
MaxLength: 16384
MinItems: 1
MinLength: 1
Required: {}
ttl CELExpressionDuration 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.
MaxLength: 16384
MinLength: 1
Required: {}
maxEntries integerMaximum number of authorization results to keep in
the cache. If unset, this defaults to 10000.
Minimum: 1
Optional: {}

ExtAuthConditional

Appears in:

FieldDescriptionDefaultValidation
condition CELExpressionCEL expression that must evaluate to true for this policy to execute.MaxLength: 16384
MinLength: 1
Optional: {}
policy ExtAuthPolicy to apply when the condition matches.Required: {}

ExtAuthOrConditional

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceExternal Authorization server to reach.
Supported types: Service and Backend.
Optional: {}
failureMode FailureModeBehavior when the external authorization service is
unavailable or returns an error. “FailOpen” allows the request to continue.
“FailClosed” (default) denies the request.
Optional: {}
grpc AgentExtAuthGRPCUses the gRPC External Authorization
protocol should be used.
Optional: {}
http AgentExtAuthHTTPUses HTTP to connect to
the authorization server. The authorization server must return a 200
status code, otherwise the request is considered an authorization
failure.
Optional: {}
forwardBody ExtAuthBodyWhether to include the HTTP body in the authorization request.
If enabled, the request body will be buffered.
Optional: {}
cache ExtAuthCacheCaches gRPC 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.
Optional: {}
conditional ExtAuthConditional arrayConditional policy execution. Set this or the top-level extAuth fields.
The first matching policy will be executed.
A single policy may be provided without a condition set; if so, it must be the last policy and will be the fallback
in case no conditions are met.
MaxItems: 16
MinItems: 1
Optional: {}

ExtProc

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceExternal Processor server to reach.
Supported types: Service and Backend.
Optional: {}
processingOptions ProcessingOptionsHow request and response phases are sent to ext_proc.Optional: {}

ExtProcConditional

Appears in:

FieldDescriptionDefaultValidation
condition CELExpressionCEL expression that must evaluate to true for this policy to execute.MaxLength: 16384
MinLength: 1
Optional: {}
policy ExtProcPolicy to apply when the condition matches.Required: {}

ExtProcOrConditional

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceExternal Processor server to reach.
Supported types: Service and Backend.
Optional: {}
processingOptions ProcessingOptionsHow request and response phases are sent to ext_proc.Optional: {}
conditional ExtProcConditional arrayConditional policy execution. Set this or the top-level extProc fields.
The first matching policy will be executed.
A single policy may be provided without a condition set; if so, it must be the last policy and will be the fallback
in case no conditions are met.
MaxItems: 16
MinItems: 1
Optional: {}

FailureMode

Underlying type: string

Appears in:

FieldDescription
FailClosedFailClosed fails the entire MCP session if any target fails.
FailOpenFailOpen skips failed targets and continues serving from healthy ones.

FieldDefault

Default value for a field in the JSON request body sent to the LLM provider. These defaults are merged with the user-provided request to ensure missing fields are populated.

User input fields here refer to the fields in the JSON request body that a client sends when making a request to the LLM provider. Defaults set here do not override those user-provided values unless you explicitly set override to true.

Example: Setting a default system field for Anthropic, which does not support system role messages:

defaults:
  - field: "system"
    value: "answer all questions in French"

Example: Setting a default temperature and overriding max_tokens:

defaults:
  - field: "temperature"
    value: "0.5"
  - field: "max_tokens"
    value: "100"
    override: true

Example: Setting custom lists fields:

defaults:
  - field: "custom_integer_list"
    value: [1,2,3]

overrides:
  - field: "custom_string_list"
    value: ["one","two","three"]

Note: The field values correspond to keys in the JSON request body, not fields in this CRD.

Appears in:

FieldDescriptionDefaultValidation
field ShortStringName of the field.MaxLength: 256
MinLength: 1
Required: {}
value JSONDefault value for the field. This can be any JSON data type.Required: {}

FieldTransformation

Maps a request JSON field to a CEL expression. The expression is evaluated against the current request body and its result is assigned to the configured field.

Appears in:

FieldDescriptionDefaultValidation
field ShortStringName of the field to set.MaxLength: 256
MinLength: 1
Required: {}
expression CELExpressionCEL expression used to compute the field value.MaxLength: 16384
MinLength: 1
Required: {}

Frontend

Appears in:

FieldDescriptionDefaultValidation
tcp FrontendTCPSettings for managing incoming TCP connections.Optional: {}
networkAuthorization AuthorizationCEL authorization on downstream network connections.
This runs before protocol handling and is intended for L4 access control,
for example using source.address with cidr(...).containsIP(...).
Optional: {}
tls FrontendTLSSettings for managing incoming TLS connections.Optional: {}
http FrontendHTTPSettings for managing incoming HTTP requests.Optional: {}
proxyProtocol FrontendProxyProtocolSettings for downstream PROXY protocol handling.
If configured, incoming connections may require a PROXY header before
normal protocol handling. This can also be configured to allow both
PROXY and non-PROXY traffic on the same listener.
Optional: {}
connect FrontendConnectSettings for downstream HTTP CONNECT handling.
If unset, CONNECT requests are rejected with Method Not Allowed.
Optional: {}
accessLog AccessLogAccess logging configuration.Optional: {}
tracing TracingOpenTelemetry tracing settings.Optional: {}
metrics MetricLabelsCustom Prometheus metric label configuration.
CEL expressions are evaluated per-request and added as labels to all
Prometheus metrics exposed by agentgateway.
Optional: {}

FrontendConnect

Appears in:

FieldDescriptionDefaultValidation
mode FrontendConnectModeWhether downstream CONNECT requests are accepted.Enum: [Deny Route Tunnel]
Required: {}

FrontendConnectMode

Underlying type: string

Validation:

  • Enum: [Deny Route Tunnel]

Appears in:

FieldDescription
DenyDeny rejects downstream CONNECT requests.
RouteRoute treats CONNECT as an HTTP request and routes it through the HTTP
matching chain before establishing a raw tunnel to the selected backend.
TunnelTunnel terminates CONNECT and sends the upgraded stream through the
addressed gateway bind as a new downstream connection.

FrontendHTTP

Appears in:

FieldDescriptionDefaultValidation
maxBufferSize ByteSizeMaximum HTTP body size that will be buffered
into memory.
Bodies will only be buffered for policies which require buffering.
If unset, this defaults to 2mb.
MaxLength: 32
MinLength: 1
Pattern: ^[+-]?([0-9]+(\.[0-9]*)?|\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\+?0*([0-9]|1[0-8])|-0*[0-9]))?$
XIntOrString: {}
Optional: {}
http1MaxHeaders integerMaximum number of headers allowed
in HTTP/1.1 requests.
If unset, this defaults to 100.
Maximum: 4096
Minimum: 1
Optional: {}
http1IdleTimeout DurationTimeout before an unused connection is
closed.
If unset, this defaults to 10 minutes.
Optional: {}
http1HeaderCase HTTPHeaderCaseControls HTTP/1 request header name casing when encoding responses on the same connection.
This only applies to HTTP/1. If a request is HTTP/2 in either the incoming or outgoing request, this will be ignored.
HTTP/2 requests are always lower case.
Modifying the headers from other policies may result in the original case being lost.
Optional: {}
http2WindowSize ByteSizeInitial window size for stream-level flow
control for received data.
MaxLength: 32
MinLength: 1
Pattern: ^[+-]?([0-9]+(\.[0-9]*)?|\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\+?0*([0-9]|1[0-8])|-0*[0-9]))?$
XIntOrString: {}
Optional: {}
http2ConnectionWindowSize ByteSizeInitial window size for
connection-level flow control for received data.
MaxLength: 32
MinLength: 1
Pattern: ^[+-]?([0-9]+(\.[0-9]*)?|\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\+?0*([0-9]|1[0-8])|-0*[0-9]))?$
XIntOrString: {}
Optional: {}
http2FrameSize ByteSizeMaximum frame size to use.
If unset, this defaults to 16kb.
MaxLength: 32
MinLength: 1
Pattern: ^[+-]?([0-9]+(\.[0-9]*)?|\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\+?0*([0-9]|1[0-8])|-0*[0-9]))?$
XIntOrString: {}
Optional: {}
http2MaxHeaderSize ByteSizeMaximum aggregate size of decoded HTTP/2
request headers.
If unset, this defaults to 16Ki.
MaxLength: 32
MinLength: 1
Pattern: ^[+-]?([0-9]+(\.[0-9]*)?|\.[0-9]+)(([KMGTPE]i)|[numkMGTPE]|[eE](\+?0*([0-9]|1[0-8])|-0*[0-9]))?$
XIntOrString: {}
Optional: {}
http2KeepaliveInterval DurationOptional: {}
http2KeepaliveTimeout DurationOptional: {}
maxConnectionDuration DurationMaximum time a connection is allowed to remain open.
After this duration, the connection is gracefully closed after the current in-flight request completes.
Useful for ensuring even traffic distribution behind load balancers during scaling events.
Optional: {}

FrontendProxyProtocol

Appears in:

FieldDescriptionDefaultValidation
version ProxyProtocolVersionPROXY protocol version to accept.
If unset, this defaults to V2.
V2Optional: {}
mode ProxyProtocolModeWhether PROXY headers are required or optional.
If unset, this defaults to Strict.
StrictOptional: {}

FrontendTCP

Appears in:

FieldDescriptionDefaultValidation
keepalive KeepaliveSettings for enabling TCP keepalives on the connection.Optional: {}

FrontendTLS

Appears in:

FieldDescriptionDefaultValidation
handshakeTimeout DurationDeadline for a TLS handshake to
complete. If unset, this defaults to 15s.
Optional: {}
alpnProtocols TinyStringApplication-Layer Protocol Negotiation (ALPN)
value to use in the TLS handshake.
If not present, defaults to ["h2", "http/1.1"].
MaxItems: 16
MaxLength: 64
MinItems: 1
MinLength: 1
Optional: {}
minProtocolVersion TLSVersionMinimum TLS version to support.Optional: {}
maxProtocolVersion TLSVersionMaximum TLS version to support.Optional: {}
cipherSuites CipherSuite arrayCipher suites for a TLS listener.
The value is a comma-separated list of cipher suites, for example
TLS13_AES_256_GCM_SHA384,TLS13_AES_128_GCM_SHA256.
Use this in the TLS options field of a TLS listener.
Optional: {}
keyExchangeGroups KeyExchangeGroup arrayOrdered list of key exchange groups for a TLS listener.
For example: X25519_MLKEM768,X25519.
Optional: {}

GcpAuth

Google Cloud authentication settings.

Appears in:

FieldDescriptionDefaultValidation
type GcpAuthTypeThe type of token to generate. To authenticate to GCP services,
generally an AccessToken is used. To authenticate to Cloud Run, an
IdToken is used.
Optional: {}
secretRef LocalSecretObjectRefCredential source, defaulting to a Kubernetes
Secret, containing ADC-compatible Google credential JSON. When using
the default Secret resolver, this must be stored in the credentials.json
key. When omitted, ambient credentials are used.
Optional: {}
audience ShortStringExplicit aud value for the ID token. Only
valid with IdToken type. If not set, the aud is automatically
derived from the backend hostname.
MaxLength: 256
MinLength: 1
Optional: {}

GcpAuthType

Underlying type: string

Appears in:

FieldDescription
AccessToken
IdToken

GeminiConfig

Settings for the Gemini LLM provider.

Appears in:

FieldDescriptionDefaultValidation
model ShortStringModel name override, such as gemini-2.5-pro.
If unset, the model name is taken from the request.
MaxLength: 256
MinLength: 1
Optional: {}

GlobalRateLimit

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceRate limit server to reach.
Supported types: Service and Backend.
Required: {}
failureMode FailureModeBehavior when the remote rate limit service is
unavailable or returns an error. FailOpen allows the request to continue.
FailClosed (default) denies the request.
Optional: {}
domain ShortStringDomain under which this limit should apply.
This is an arbitrary string that enables a rate limit server to distinguish between different applications.
MaxLength: 256
MinLength: 1
Required: {}
descriptors RateLimitDescriptor arrayDimensions for rate limiting. These values are
passed to the rate limit service which applies configured limits based
on them. Each descriptor represents a single rate limit rule with one or
more entries.
MaxItems: 16
MinItems: 1
Required: {}

GoogleModelArmor

Appears in:

FieldDescriptionDefaultValidation
templateId ShortStringTemplate ID for Google Model Armor.MaxLength: 256
MinLength: 1
Required: {}
projectId ShortStringGoogle Cloud project ID.MaxLength: 256
MinLength: 1
Required: {}
location ShortStringGoogle Cloud location, for example us-central1.
Defaults to us-central1 if not specified.
us-central1MaxLength: 256
MinLength: 1
Optional: {}
policies BackendSimplePolicies for communicating with Google Model Armor.Optional: {}

HTTPHeaderCase

Underlying type: string

Appears in:

FieldDescription
Lowercase
Preserve

HTTPHeaderName

Underlying type: string

HTTP header name that does not allow pseudo-headers.

Validation:

  • MaxLength: 256
  • MinLength: 1
  • Pattern: ^[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$

Appears in:

HTTPVersion

Underlying type: string

Appears in:

FieldDescription
HTTP1
HTTP2

HeaderModifiers

Modifies request and response headers.

Appears in:

FieldDescriptionDefaultValidation
request HTTPHeaderFilterHeader changes to apply before forwarding a request.Optional: {}
response HTTPHeaderFilterHeader changes to apply before returning a response.Optional: {}

HeaderName

Underlying type: string

HTTP header name.

Validation:

  • MaxLength: 256
  • MinLength: 1
  • Pattern: ^:?[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$

Appears in:

HeaderSendMode

Underlying type: string

Whether HTTP headers are delivered to the external processor.

Validation:

  • Enum: [Send Skip]

Appears in:

FieldDescription
SendHeaderSendModeSend sends headers to the external processor.
SkipHeaderSendModeSkip does not send headers to the external processor.

HeaderTransformation

Appears in:

FieldDescriptionDefaultValidation
name HeaderNameThe name of the header to add.MaxLength: 256
MinLength: 1
Pattern: ^:?[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
Required: {}
value CELExpressionCEL expression that generates the output value for
the header.
MaxLength: 16384
MinLength: 1
Required: {}

Health

Appears in:

FieldDescriptionDefaultValidation
unhealthyCondition CELExpressionCEL 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.
MaxLength: 16384
MinLength: 1
Optional: {}
eviction BackendEvictionSettings for evicting unhealthy backends.Optional: {}

HostnameRewrite

Appears in:

FieldDescriptionDefaultValidation
mode HostnameRewriteModeHostname rewrite mode.
The following may be specified:
* Auto: automatically set the Host header based on the destination.
* None: do not rewrite the Host header. The original Host header
will be passed through.
This setting defaults to Auto when connecting to hostname-based
Backend types, and None otherwise, for Service or IP-based
backends.
Required: {}

HostnameRewriteMode

Underlying type: string

Appears in:

FieldDescription
Auto
None

Image

Container image settings. See https://kubernetes.io/docs/concepts/containers/images for details.

Appears in:

FieldDescriptionDefaultValidation
registry stringImage registry.Optional: {}
repository stringImage repository.Optional: {}
tag stringImage tag.Optional: {}
digest stringImage digest, such as sha256:12345....Optional: {}
pullPolicy PullPolicyImage pull policy for the container. See
https://kubernetes.io/docs/concepts/containers/images/#image-pull-policy
for details.
Optional: {}

InsecureTLSMode

Underlying type: string

Appears in:

FieldDescription
AllInsecureTLSModeInsecure disables all TLS verification
HostnameInsecureTLSModeHostname enables verifying the CA certificate, but disables verification of the hostname/SAN.
Note this is still, generally, very “insecure” as the name suggests.

IstioSpec

Appears in:

FieldDescriptionDefaultValidation
enabled booleanExplicitly turns Istio integration on or off for this gateway.Optional: {}
caAddress stringAddress of the Istio CA. If unset, defaults to https://istiod.istio-system.svc:15012.Optional: {}
trustDomain stringIstio trust domain. If not set, defaults to cluster.local, or the default
trust domain for the control plane’s istio revision.
Optional: {}
additionalTrustDomains string arrayAdditional SPIFFE trust domains accepted on inbound HBONE connections.
The local trust domain is always implicitly included.
Optional: {}
clusterId stringID of the cluster this gateway runs in. If unset, defaults to Kubernetes.Optional: {}
network stringIstio network this gateway runs in. If unset, defaults to the empty network.Optional: {}

JWKS

Validation:

  • ExactlyOneOf: [remote inline]

Appears in:

FieldDescriptionDefaultValidation
remote RemoteJWKSHow to reach the JSON Web Key Set from a remote
address.
Optional: {}
inline stringInline JSON Web Key Set used to validate the
signature of the JWT.
MaxLength: 65536
MinLength: 2
Optional: {}

JWTAuthentication

Appears in:

FieldDescriptionDefaultValidation
mode JWTAuthenticationModeValidation mode for JWT authentication.StrictOptional: {}
providers JWTProvider arrayMaxItems: 64
MinItems: 1
Required: {}
location AuthorizationExtractionLocationWhere JWT credentials are read from.
If omitted, credentials are read from the Authorization header with the Bearer prefix.
ExactlyOneOf: [header queryParameter cookie expression]
Optional: {}
mcp JWTMCPConfigEnables MCP OAuth metadata endpoint handling
and MCP-specific authentication behavior on top of standard JWT validation.
When set, the gateway will serve the MCP OAuth metadata discovery endpoints.
Optional: {}

JWTAuthenticationMode

Underlying type: string

Appears in:

FieldDescription
StrictA valid token, issued by a configured issuer, must be present.
This is the default option.
OptionalIf a token exists, validate it.
Warning: this allows requests without a JWT token!
PermissiveRequests are never rejected. This is useful for usage of claims in later steps (authorization, logging, etc).
Warning: this allows requests without a JWT token!

JWTMCPConfig

MCP-specific extensions for JWT authentication.

Appears in:

FieldDescriptionDefaultValidation
resourceMetadata object (keys:string, values:JSON)Metadata to use for MCP resources,
served at the MCP OAuth metadata endpoints.
Optional: {}
provider McpIDPIdentity provider to use for MCP authentication flows.Enum: [Auth0 Keycloak Okta]
Optional: {}
clientId stringClient 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.
Optional: {}

JWTProvider

Appears in:

FieldDescriptionDefaultValidation
issuer ShortStringIdP that issued the JWT. This corresponds to the
iss claim (RFC 7519 §4.1.1).
MaxLength: 256
MinLength: 1
Required: {}
audiences string arrayAllowed audiences that are allowed
access. This corresponds to the aud claim
(RFC 7519 §4.1.3).
If unset, any audience is allowed.
MaxItems: 64
MinItems: 1
Optional: {}
jwks JWKSJSON Web Key Set used to validate the signature of the
JWT.
ExactlyOneOf: [remote inline]
Required: {}

Keepalive

TCP keepalive settings.

Appears in:

FieldDescriptionDefaultValidation
retries integerMaximum number of keepalive probes to send before dropping the connection.
If unset, this defaults to 9.
Maximum: 64
Minimum: 1
Optional: {}
time DurationTime a connection needs to be idle before keepalive probes start being sent.
If unset, this defaults to 180s.
Optional: {}
interval DurationTime between keepalive probes.
If unset, this defaults to 180s.
Optional: {}

KeyExchangeGroup

Underlying type: string

Appears in:

FieldDescription
X25519
P-256
P-384
X25519_MLKEM768

KubernetesResourceOverlay

KubernetesResourceOverlay provides a mechanism to customize generated Kubernetes resources using Strategic Merge Patch semantics.

Overlay Application Order

Overlays are applied after all typed configuration fields have been processed. The full merge order is:

  1. GatewayClass typed configuration fields, for example replicas or image settings from parametersRef
  2. Gateway typed configuration fields from infrastructure.parametersRef
  3. GatewayClass overlays are applied
  4. Gateway overlays are applied

This ordering means Gateway-level configuration overrides GatewayClass-level configuration at each stage. For example, if both levels set the same label, the Gateway value wins.

Appears in:

FieldDescriptionDefaultValidation
metadata ObjectMetadataRefer to Kubernetes API documentation for fields of metadata.Optional: {}
spec JSONspec provides an opaque mechanism to configure the resource spec.
This field accepts a complete or partial Kubernetes resource spec, such
as PodSpec or ServiceSpec, and will be merged with the generated
configuration using Strategic Merge Patch semantics.
# Application Order
Overlays are applied after all typed configuration fields from both levels.
The full merge order is:
1. GatewayClass typed configuration fields
2. Gateway typed configuration fields
3. GatewayClass overlays
4. Gateway overlays (can override all previous values)
# Strategic Merge Patch & Deletion Guide
This merge strategy allows you to override individual fields, merge lists, or delete items
without needing to provide the entire resource definition.
1. Replacing Values (Scalars):
Simple fields (strings, integers, booleans) in your config will overwrite the generated defaults.
2. Merging Lists (Append/Merge):
Lists with “merge keys”, like containers which merges on name, or
tolerations which merges on key,
will append your items to the generated list, or update existing items if keys match.
3. Deleting Fields or List Items ($patch: delete):
To remove a field or list item from the generated resource, use the
$patch: delete directive. This works for both map fields and list items,
and is the recommended approach because it works with both client-side
and server-side apply.
spec:
template:
spec:
# Delete pod-level securityContext
securityContext:
$patch: delete
# Delete nodeSelector
nodeSelector:
$patch: delete
containers:
# Be sure to use the correct proxy name here or you will add a
# container instead of modifying a container.
- name: proxy-name
# Delete container-level securityContext
securityContext:
$patch: delete
4. Null Values (server-side apply only):
Setting a field to null can also remove it, but this ONLY works with
kubectl apply --server-side or equivalent. With regular client-side
kubectl apply, null values are stripped by kubectl before reaching
the API server, so the deletion won’t occur. Prefer $patch: delete
for consistent behavior across both apply modes.
spec:
template:
spec:
nodeSelector: null # Removes nodeSelector (server-side apply only!)
5. Replacing Maps Entirely ($patch: replace):
To replace an entire map with your values (instead of merging), use $patch: replace.
This removes all existing keys and replaces them with only your specified keys.
spec:
template:
spec:
nodeSelector:
$patch: replace
custom-key: custom-value
6. Replacing Lists Entirely ($patch: replace):
If you want to strictly define a list and ignore all generated defaults, use $patch: replace.
service:
spec:
ports:
- $patch: replace
- name: http
port: 80
targetPort: 8080
protocol: TCP
- name: https
port: 443
targetPort: 8443
protocol: TCP
Type: object
Optional: {}

LLMProvider

Large language model provider that the backend routes requests to.

Validation:

  • ExactlyOneOf: [openai azureopenai azure anthropic gemini vertexai bedrock custom]

Appears in:

FieldDescriptionDefaultValidation
openai OpenAIConfigOpenAI provider settings.Optional: {}
azureopenai AzureOpenAIConfigAzure OpenAI provider settings.Optional: {}
azure AzureConfigAzure provider with resource-based configuration.
Supports both Azure OpenAI and Azure AI Foundry resource types.
Optional: {}
anthropic AnthropicConfigAnthropic provider settings.Optional: {}
gemini GeminiConfigGemini provider settings.Optional: {}
vertexai VertexAIConfigVertex AI provider settings.Optional: {}
bedrock BedrockConfigBedrock provider settings.Optional: {}
custom CustomProviderCustom 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.
Optional: {}
host ShortStringHostname 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.
MaxLength: 256
MinLength: 1
Optional: {}
port integerPort to send requests to.Maximum: 65535
Minimum: 1
Optional: {}
path LongStringURL 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.
MaxLength: 1024
MinLength: 1
Optional: {}
pathPrefix LongStringOverrides 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.
MaxLength: 1024
MinLength: 1
Optional: {}

LocalBackendObjectReference

References a namespace-local backend resource.

Appears in:

FieldDescriptionDefaultValidation
group stringAPI group of the referenced resource. For example, gateway.networking.k8s.io.
When unspecified or empty string, core API group is inferred.
MaxLength: 253
Pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
Optional: {}
kind stringKind of the referenced resource. For example, Service.
Defaults to “Service” when not specified.
ServiceMaxLength: 63
MinLength: 1
Pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
Optional: {}
name stringName of the referenced resource.MaxLength: 253
MinLength: 1
Required: {}
port integerDestination port number to use for this resource.
Required when the referenced resource is a Kubernetes Service.
Maximum: 65535
Minimum: 1
Optional: {}

LocalPolicyTargetReference

Selects one same-namespace object by group, kind, and name. The object must be in the same namespace as the policy.

Appears in:

FieldDescriptionDefaultValidation
group GroupThe API group of the target resource.
For Kubernetes Gateway API resources, the group is gateway.networking.k8s.io.
MaxLength: 253
Pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
Required: {}
kind KindThe API kind of the target resource, such as Gateway or HTTPRoute.MaxLength: 63
MinLength: 1
Pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
Required: {}
name ObjectNameThe name of the target resource.Required: {}

LocalPolicyTargetReferenceWithSectionName

Selects one same-namespace object by group, kind, name, and, optionally, sectionName. The object must be in the same namespace as the policy.

Appears in:

FieldDescriptionDefaultValidation
group GroupThe API group of the target resource.
For Kubernetes Gateway API resources, the group is gateway.networking.k8s.io.
MaxLength: 253
Pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
Required: {}
kind KindThe API kind of the target resource, such as Gateway or HTTPRoute.MaxLength: 63
MinLength: 1
Pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
Required: {}
name ObjectNameThe name of the target resource.Required: {}
sectionName SectionNameThe named section of the target resource.Optional: {}

LocalPolicyTargetSelector

Selects same-namespace objects by group, kind, and matchLabels. The object must be in the same namespace as the policy and match the specified labels.

Appears in:

FieldDescriptionDefaultValidation
group GroupThe API group of the target resource.
For Kubernetes Gateway API resources, the group is gateway.networking.k8s.io.
MaxLength: 253
Pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
Required: {}
kind KindThe API kind of the target resource, such as Gateway or HTTPRoute.MaxLength: 63
MinLength: 1
Pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
Required: {}
matchLabels object (keys:string, values:string)Labels that must be present on each selected target resource.Required: {}

LocalPolicyTargetSelectorWithSectionName

Selects same-namespace objects by group, kind, matchLabels, and, optionally, sectionName. Each selected object must be in the same namespace as the policy and match the specified labels. Prefer targetRefs when reconciliation latency is important, especially when many policies target the same resource.

Appears in:

FieldDescriptionDefaultValidation
group GroupThe API group of the target resource.
For Kubernetes Gateway API resources, the group is gateway.networking.k8s.io.
MaxLength: 253
Pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
Required: {}
kind KindThe API kind of the target resource, such as Gateway or HTTPRoute.MaxLength: 63
MinLength: 1
Pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
Required: {}
matchLabels object (keys:string, values:string)Labels that must be present on each selected target resource.Required: {}
sectionName SectionNameThe named section of each selected target resource.Optional: {}

LocalRateLimit

Local rate limiting policy. Local rate limits are handled on a per-proxy basis, without coordination between instances of the proxy.

Validation:

  • ExactlyOneOf: [requests tokens]

Appears in:

FieldDescriptionDefaultValidation
requests integerNumber of HTTP requests per unit of time that
are allowed. Requests exceeding this limit will fail with a 429
error.
Minimum: 1
Optional: {}
tokens integerNumber of LLM tokens per unit of time that are
allowed. Requests exceeding this limit will fail with a 429 error.
Both input and output tokens are counted. However, token counts are not known until the request completes. As a
result, token-based rate limits will apply to future requests only.
Minimum: 1
Optional: {}
unit LocalRateLimitUnitUnit of time for the limit.Required: {}
burst integerAllowance of requests above the request-per-unit
that should be allowed within a short period of time.
Optional: {}

LocalRateLimitUnit

Underlying type: string

Appears in:

FieldDescription
Seconds
Minutes
Hours

LocalSecretObjectRef

References a same-namespace credential. Set only name to reference a Kubernetes Secret.

Appears in:

FieldDescriptionDefaultValidation
name ObjectNameThe name of the referenced credential.Required: {}
group stringThe API group of the referenced credential.
Empty selects the core API group.
Optional: {}
kind stringThe kind of the referenced credential.
Empty defaults to Secret.
Optional: {}

LogTracingAttributes

Appears in:

FieldDescriptionDefaultValidation
remove TinyString arrayDefault fields to remove. For example,
http.method.
MaxItems: 32
MaxLength: 64
MinItems: 1
MinLength: 1
Optional: {}
add AttributeAdd arrayAdditional key-value pairs to add to each entry.
The value is a CEL expression. If the CEL expression fails to evaluate,
the pair will be excluded.
MinItems: 1
Optional: {}

MCPAuthentication

Appears in:

FieldDescriptionDefaultValidation
resourceMetadata object (keys:string, values:JSON)Metadata to use for MCP resources.Optional: {}
provider McpIDPIdentity provider to use for authentication.Enum: [Auth0 Keycloak Okta]
Optional: {}
issuer ShortStringIdP that issued the JWT. This corresponds to the
iss claim (RFC 7519 §4.1.1).
MaxLength: 256
MinLength: 1
Optional: {}
audiences string arrayAllowed audiences that are allowed
access. This corresponds to the aud claim
(RFC 7519 §4.1.3).
If unset, any audience is allowed.
MaxItems: 64
MinItems: 1
Optional: {}
jwks RemoteJWKSRemote JSON Web Key used to validate the signature of
the JWT.
Required: {}
mode JWTAuthenticationModeValidation mode for JWT authentication.StrictOptional: {}
clientId stringClient 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.
Optional: {}

MCPBackend

MCP backend settings.

Appears in:

FieldDescriptionDefaultValidation
targets McpTargetSelector arrayMCP targets to use for this backend. Policies
targeting MCP targets must use targetRefs[].sectionName to select
the target by name.
ExactlyOneOf: [selector static]
MaxItems: 32
MinItems: 1
Required: {}
sessionRouting SessionRoutingMCP session routing behavior.
Defaults to Stateful if not set.
Optional: {}
failureMode FailureModeBehavior 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.
Optional: {}

MCPProtocol

Underlying type: string

Protocol to use for an MCP target.

Appears in:

FieldDescription
StreamableHTTPMCPProtocolStreamableHTTP specifies that StreamableHTTP must be used as
the protocol.
SSEMCPProtocolSSE specifies that Server-Sent Events (SSE) must be used as
the protocol.

McpIDP

Underlying type: string

Appears in:

FieldDescription
Auth0
Keycloak
Okta

McpSelector

Appears in:

FieldDescriptionDefaultValidation
namespaces LabelSelectornamespace is the label selector for namespaces that Service
resources should be selected from. If unset, only the namespace of the
AgentgatewayBackend is searched.
Optional: {}
services LabelSelectorservices is the label selector for which Service resources should be
selected.
Optional: {}

McpTarget

MCP target configuration.

Validation:

  • ExactlyOneOf: [host backendRef]

Appears in:

FieldDescriptionDefaultValidation
host ShortStringHostname or IP address of the MCP target.MaxLength: 256
MinLength: 1
Optional: {}
backendRef LocalObjectReferenceNamespace-local Service resource by name.
When set, this replaces host only; port, path, and protocol
remain configured on this target.
Optional: {}
port integerPort number of the MCP target.Maximum: 65535
Minimum: 1
Required: {}
path LongStringURL path of the MCP target endpoint.
Defaults to "/sse" for the SSE protocol or "/mcp" for the
StreamableHTTP protocol if not specified.
MaxLength: 1024
MinLength: 1
Optional: {}
protocol MCPProtocolProtocol to use for the connection to the MCP
target.
Optional: {}
policies BackendSimplePolicies 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.
Optional: {}

McpTargetSelector

MCP target selection for this backend.

Validation:

  • ExactlyOneOf: [selector static]

Appears in:

FieldDescriptionDefaultValidation
name SectionNameName of the MCP target.Required: {}
selector McpSelectorLabel selector used to select Service resources.
If policies are needed on a per-service basis, AgentgatewayPolicy can
target the desired Service.
Optional: {}
static McpTargetStatic MCP destination. When connecting to
in-cluster Service resources, it is recommended to use selector
instead.
ExactlyOneOf: [host backendRef]
Optional: {}

Message

An entry for a message to prepend or append to each prompt.

Appears in:

FieldDescriptionDefaultValidation
role stringRole of the message. The available roles depend on the backend
LLM provider model, such as SYSTEM or USER in the OpenAI API.
Required: {}
content stringString content of the message.Required: {}

MetricAttributes

Appears in:

FieldDescriptionDefaultValidation
add AttributeAdd arrayAdditional key-value pairs to add as custom labels
to all Prometheus metrics. The value is a CEL expression evaluated
per-request. If the CEL expression fails to evaluate, the label value
is set to “unknown”.
WARNING: High-cardinality labels (e.g., per-user IDs) can significantly
increase Prometheus storage and memory usage. Prefer low-cardinality
dimensions like team or environment.
MaxItems: 16
MinItems: 1
Optional: {}

MetricLabels

Custom labels to add to Prometheus metrics.

Appears in:

FieldDescriptionDefaultValidation
attributes MetricAttributesCustomizations to the labels that are
added to Prometheus metrics.
Required: {}

NamedLLMProvider

Appears in:

FieldDescriptionDefaultValidation
name SectionNameName of the provider. Policies can target this provider by name.Required: {}
policies BackendWithAIPolicies 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).
Optional: {}
openai OpenAIConfigOpenAI provider settings.Optional: {}
azureopenai AzureOpenAIConfigAzure OpenAI provider settings.Optional: {}
azure AzureConfigAzure provider with resource-based configuration.
Supports both Azure OpenAI and Azure AI Foundry resource types.
Optional: {}
anthropic AnthropicConfigAnthropic provider settings.Optional: {}
gemini GeminiConfigGemini provider settings.Optional: {}
vertexai VertexAIConfigVertex AI provider settings.Optional: {}
bedrock BedrockConfigBedrock provider settings.Optional: {}
custom CustomProviderCustom 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.
Optional: {}
host ShortStringHostname 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.
MaxLength: 256
MinLength: 1
Optional: {}
port integerPort to send requests to.Maximum: 65535
Minimum: 1
Optional: {}
path LongStringURL 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.
MaxLength: 1024
MinLength: 1
Optional: {}
pathPrefix LongStringOverrides 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.
MaxLength: 1024
MinLength: 1
Optional: {}

OTLPProtocol

Underlying type: string

Appears in:

FieldDescription
HTTP
GRPC

ObjectMetadata

ObjectMetadata contains labels and annotations for metadata overlays.

Appears in:

FieldDescriptionDefaultValidation
labels object (keys:string, values:string)Map of string keys and values that can be used to organize and categorize
(scope and select) objects. May match selectors of replication controllers
and services.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels
Optional: {}
annotations object (keys:string, values:string)Annotations is an unstructured key value map stored with a resource that may be
set by external tools to store and retrieve arbitrary metadata. They are not
queryable and should be preserved when modifying objects.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations
Optional: {}

OpenAIConfig

Settings for the OpenAI LLM provider.

Appears in:

FieldDescriptionDefaultValidation
model ShortStringModel name override, such as gpt-4o-mini.
If unset, the model name is taken from the request.
MaxLength: 256
MinLength: 1
Optional: {}

OpenAIModeration

Appears in:

FieldDescriptionDefaultValidation
model stringModeration model to use. For example,
omni-moderation.
Optional: {}
policies BackendSimplePolicies for communicating with OpenAI.Optional: {}

OtlpAccessLog

Ships access logs to an OpenTelemetry-compatible backend via OTLP.

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceOTLP server to send access logs to.
Supported types: Service and AgentgatewayBackend.
Required: {}
protocol OTLPProtocolOTLP protocol variant to use.GRPCOptional: {}
path LongStringOTLP/HTTP path to use. This is only applicable
when protocol is HTTP. If unset, this defaults to /v1/logs.
MaxLength: 1024
MinLength: 1
Optional: {}

PolicyAncestorStatus

Appears in:

FieldDescriptionDefaultValidation
ancestorRef ParentReferenceThe ancestor resource that this status entry describes.Required: {}
controllerName stringThe controller that wrote this status entry.
Example: example.net/gateway-controller.
Required: {}
conditions Condition arrayConditions for this policy’s effect on the specified ancestor.MaxItems: 8
MinItems: 1
Optional: {}

PolicyInheritance

Underlying type: string

How a traffic policy affects policy inheritance across attachment specificity levels.

Appears in:

FieldDescription
DefaultPolicyInheritanceDefault allows the normal traffic policy merge order, where more-specific
policies may override fields from less-specific policies.
OverridePolicyInheritanceOverride makes the policy authoritative for lower levels, excluding
more-specific traffic policies from the effective policy.

PolicyPhase

Underlying type: string

Appears in:

FieldDescription
PreRouting
PostRouting

PolicyStrategy

Appears in:

FieldDescriptionDefaultValidation
inheritance PolicyInheritanceControls whether less-specific traffic policies prevent more-specific traffic policies
from contributing to the effective policy.
This field is only valid on traffic policies. Frontend and backend policy merging does not use
inheritance.
When unset or set to Default, traffic policy fields are merged by specificity, with more-specific
attachment points such as routes and route rules able to override fields from less-specific
attachment points such as gateways and listeners.
In other words, this policy provides Defaults that can be overridden. For example, you may provide a Default
timeout policy for the entire Gateway that is overridden by specific routes.
When set to Override, this policy blocks traffic policies at more-specific attachment points from
being included in the effective policy. This is useful when a gateway-level policy must remain
authoritative for all routes below it.
Optional: {}

PriorityGroup

Appears in:

FieldDescriptionDefaultValidation
providers NamedLLMProvider arrayLLM providers within this group. Each provider is treated equally in terms of priority,
with automatic weighting based on health.
MaxItems: 16
MinItems: 1
Required: {}

ProcessingOptions

External processor request and response phase settings.

Appears in:

FieldDescriptionDefaultValidation
requestBodyMode BodySendModeHow request bodies are sent to the external processor.
Buffered buffers the full body and returns an error if it exceeds 8KB.
BufferedPartial buffers up to 8KB and sends the buffered prefix if the
body exceeds that limit. Defaults to FullDuplexStreamed.
FullDuplexStreamedEnum: [None Buffered BufferedPartial FullDuplexStreamed]
Optional: {}
responseBodyMode BodySendModeHow response bodies are sent to the external processor.
Buffered buffers the full body and returns an error if it exceeds 8KB.
BufferedPartial buffers up to 8KB and sends the buffered prefix if the
body exceeds that limit. Defaults to FullDuplexStreamed.
FullDuplexStreamedEnum: [None Buffered BufferedPartial FullDuplexStreamed]
Optional: {}
requestHeaderMode HeaderSendModeWhether request headers are sent to the external processor.
Defaults to Send.
SendEnum: [Send Skip]
Optional: {}
responseHeaderMode HeaderSendModeWhether response headers are sent to the external processor.
Defaults to Send.
SendEnum: [Send Skip]
Optional: {}
requestTrailerMode TrailerSendModeWhether request trailers are sent to the external processor.
Defaults to Send.
SendEnum: [Skip Send]
Optional: {}
responseTrailerMode TrailerSendModeWhether response trailers are sent to the external processor.
Defaults to Send.
SendEnum: [Skip Send]
Optional: {}
allowModeOverride booleanAllows ext_proc mode_override values from matching header responses to update
subsequent request/response processing phases for this exchange. Defaults to false.
falseOptional: {}

PromptCachingConfig

Automatic prompt caching for supported LLM providers. Currently only AWS Bedrock supports this feature (Claude 3+ and Nova models).

When enabled, the gateway automatically inserts cache points at strategic locations to reduce API costs. Bedrock charges lower rates for cached tokens (90% discount).

Example:

promptCaching:
  cacheSystem: true
  cacheMessages: true
  cacheTools: false

Cost savings example:

  • Without caching: 10,000 tokens × $3/MTok = $0.03
  • With caching (90% cached): 1,000 × $3/MTok + 9,000 × $0.30/MTok = $0.0057 (81% savings)

Appears in:

FieldDescriptionDefaultValidation
cacheSystem booleanEnables caching for system prompts.
Inserts a cache point after all system messages.
trueOptional: {}
cacheMessages booleanEnables caching for conversation messages.
Caches all messages in the conversation for cost savings.
trueOptional: {}
cacheTools booleanEnables caching for tool definitions.
Inserts a cache point after all tool specifications.
falseOptional: {}
minTokens integerMinimum estimated token count
before caching is enabled. Uses rough heuristic (word count × 1.3) to estimate tokens.
Bedrock requires at least 1,024 tokens for caching to be effective.
1024Minimum: 0
Optional: {}
cacheMessageOffset integerShifts 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.
0Minimum: 0
Optional: {}

PromptguardRequest

Prompt guards to apply to requests sent by the client.

Validation:

  • ExactlyOneOf: [regex webhook openAIModeration bedrockGuardrails googleModelArmor]

Appears in:

FieldDescriptionDefaultValidation
response CustomResponseCustom response message to return to the client. If not specified, defaults to
The request was rejected due to inappropriate content.
Optional: {}
regex RegexRegular expression (regex) matching for prompt guards and data masking.Optional: {}
webhook WebhookWebhook that receives requests for prompt guarding.Optional: {}
openAIModeration OpenAIModerationPasses prompt data through the OpenAI Moderations
endpoint.
See https://developers.openai.com/api/reference/resources/moderations for more information.
Optional: {}
bedrockGuardrails BedrockGuardrailsAWS Bedrock Guardrails settings for prompt
guarding.
Optional: {}
googleModelArmor GoogleModelArmorGoogle Model Armor settings for prompt guarding.Optional: {}

PromptguardResponse

Prompt guards to apply to responses returned by the LLM provider.

Validation:

  • ExactlyOneOf: [regex webhook bedrockGuardrails googleModelArmor]

Appears in:

FieldDescriptionDefaultValidation
response CustomResponseCustom response message to return to the client. If not specified, defaults to
The response was rejected due to inappropriate content.
Optional: {}
regex RegexRegular expression (regex) matching for prompt guards and data masking.Optional: {}
webhook WebhookWebhook that receives responses for prompt guarding.Optional: {}
bedrockGuardrails BedrockGuardrailsAWS Bedrock Guardrails settings for prompt
guarding.
Optional: {}
googleModelArmor GoogleModelArmorGoogle Model Armor settings for prompt guarding.Optional: {}

ProviderFormat

Underlying type: string

Provider-native LLM API format.

Appears in:

FieldDescription
CompletionsProviderFormatCompletions is the OpenAI-compatible chat completions API.
MessagesProviderFormatMessages is the Anthropic-compatible messages API.
ResponsesProviderFormatResponses is the OpenAI responses API.
EmbeddingsProviderFormatEmbeddings is the OpenAI-compatible embeddings API.
AnthropicTokenCountProviderFormatAnthropicTokenCount is the Anthropic token-count API.
RealtimeProviderFormatRealtime is the OpenAI-compatible realtime API.
RerankProviderFormatRerank is the Cohere-compatible rerank API.

ProviderFormatConfig

Provider-native LLM API format settings.

Appears in:

FieldDescriptionDefaultValidation
type ProviderFormatProvider-native API format.Required: {}
path LongStringDefault upstream path override for this format.
If unset, agentgateway uses the default path for the format.
MaxLength: 1024
MinLength: 1
Optional: {}

ProxyProtocolMode

Underlying type: string

Appears in:

FieldDescription
StrictA valid PROXY header must be present. This is the default option.
OptionalAccept either a PROXY header or plain downstream traffic.

ProxyProtocolVersion

Underlying type: string

Appears in:

FieldDescription
V1
V2
All

RateLimitDescriptor

Appears in:

FieldDescriptionDefaultValidation
entries RateLimitDescriptorEntry arrayIndividual components that make up this descriptor.MaxItems: 16
MinItems: 1
Required: {}
unit RateLimitUnitCost unit. If unspecified,
Requests is used.
Optional: {}
cost CELExpressionCommon Expression Language (CEL) expression that determines
the cost of the request for this descriptor. If unset, Requests costs
default to 1, and Tokens costs default to the total token count.
Tokens cost are evaluated after the request has completed. For non-streaming requests, request, llm, and
response fields are all available; for streaming requests, response is not available (however, all LLM
attributes are in llm). For Requests, cost is computed during the request phase.
See https://agentgateway.dev/docs/standalone/latest/reference/cel/ for more info.
MaxLength: 16384
MinLength: 1
Optional: {}

RateLimitDescriptorEntry

Entry in a rate limit descriptor.

Appears in:

FieldDescriptionDefaultValidation
name TinyStringName of the descriptor.MaxLength: 64
MinLength: 1
Required: {}
expression CELExpressionCommon Expression Language (CEL) expression that
defines the value for the descriptor.
For example, to rate limit based on the Client IP: source.address.
See https://agentgateway.dev/docs/standalone/latest/reference/cel/ for more info.
MaxLength: 16384
MinLength: 1
Required: {}

RateLimitUnit

Underlying type: string

Appears in:

FieldDescription
Tokens
Requests

RateLimits

Appears in:

FieldDescriptionDefaultValidation
local LocalRateLimit arrayLocal rate limiting policy.ExactlyOneOf: [requests tokens]
MaxItems: 16
MinItems: 1
Optional: {}
global GlobalRateLimitGlobal rate limiting policy using an external service.Optional: {}

RateLimitsConditional

Appears in:

FieldDescriptionDefaultValidation
condition CELExpressionCEL expression that must evaluate to true for this policy to execute.MaxLength: 16384
MinLength: 1
Optional: {}
policy RateLimitsPolicy to apply when the condition matches.Required: {}

RateLimitsOrConditional

Appears in:

FieldDescriptionDefaultValidation
local LocalRateLimit arrayLocal rate limiting policy.ExactlyOneOf: [requests tokens]
MaxItems: 16
MinItems: 1
Optional: {}
global GlobalRateLimitGlobal rate limiting policy using an external service.Optional: {}
conditional RateLimitsConditional arrayConditional policy execution. Set this or the top-level rateLimit fields.
The first matching policy will be executed.
A single policy may be provided without a condition set; if so, it must be the last policy and will be the fallback
in case no conditions are met.
MaxItems: 16
MinItems: 1
Optional: {}

Regex

Regular expression matching for prompt guards and data masking.

Appears in:

FieldDescriptionDefaultValidation
matches LongString arrayRegex patterns to match against the request or response.
Matches and built-ins are additive.
MaxLength: 1024
MinLength: 1
Optional: {}
builtins BuiltIn arrayBuilt-in regex patterns to match against the request or response.
Matches and built-ins are additive.
Optional: {}
action ActionThe action to take if a regex pattern is matched in a request or response.
This setting applies only to request matches. PromptguardResponse
matches are always masked by default.
Defaults to Mask.
MaskOptional: {}

RemoteJWKS

Appears in:

FieldDescriptionDefaultValidation
jwksPath stringPath to the IdP jwks endpoint, relative to the root, commonly
".well-known/jwks.json".
MaxLength: 2000
MinLength: 1
Required: {}
cacheDuration Duration5mOptional: {}
backendRef BackendObjectReferenceRemote JWKS server to reach.
Supported types are Service and static Backend. An
AgentgatewayPolicy containing backend TLS config can then be attached
to the Service or Backend in order to set TLS options for a
connection to the remote jwks source.
Required: {}

ResourceAdd

Appears in:

FieldDescriptionDefaultValidation
name ShortStringMaxLength: 256
MinLength: 1
Required: {}
expression CELExpressionMaxLength: 16384
MinLength: 1
Required: {}

Retry

Retry policy.

Appears in:

RouteType

Underlying type: string

How the AI gateway should process incoming requests based on the URL path and the API format expected.

Appears in:

FieldDescription
CompletionsRouteTypeCompletions processes OpenAI /v1/chat/completions format requests.
MessagesRouteTypeMessages processes Anthropic /v1/messages format requests.
ModelsRouteTypeModels handles the /v1/models endpoint.
PassthroughRouteTypePassthrough sends requests upstream as-is without LLM processing.
DetectRouteTypeDetect sends requests as-is but attempts to extract
request/response metadata for telemetry and rate limiting.
ResponsesRouteTypeResponses processes OpenAI /v1/responses format requests.
AnthropicTokenCountRouteTypeAnthropicTokenCount processes Anthropic
/v1/messages/count_tokens format requests.
EmbeddingsRouteTypeEmbeddings processes OpenAI /v1/embeddings format requests.
RealtimeRouteTypeRealtime processes OpenAI /v1/realtime requests.
RerankRouteTypeRerank processes Cohere /v2/rerank format requests.

SecretSelector

Appears in:

FieldDescriptionDefaultValidation
matchLabels object (keys:string, values:string)Labels that must be present on each selected Secret.Required: {}

SessionRouting

Underlying type: string

Appears in:

FieldDescription
StatefulStateful mode creates an MCP session (via mcp-session-id) and
internally
ensures requests for that session are routed to a consistent backend replica.
Stateless

ShutdownSpec

Appears in:

FieldDescriptionDefaultValidation
min integerMinimum time (in seconds) to wait before allowing Agentgateway to
terminate. Refer to the CONNECTION_MIN_TERMINATION_DEADLINE
environment variable for details.
Maximum: 3.1536e+07
Minimum: 0
Required: {}
max integerMaximum time (in seconds) to wait before allowing Agentgateway to
terminate. Refer to the TERMINATION_GRACE_PERIOD_SECONDS
environment variable for details.
Maximum: 3.1536e+07
Minimum: 0
Required: {}

StaticBackend

Static backend endpoint, either TCP (host and port) or Unix Domain Socket.

Appears in:

FieldDescriptionDefaultValidation
host ShortStringHost to connect to for TCP backends.MaxLength: 256
MinLength: 1
Optional: {}
port integerPort to connect to for TCP backends.Maximum: 65535
Minimum: 1
Optional: {}
unixPath stringFilesystem 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.
MinLength: 1
Optional: {}

TLSVersion

Underlying type: string

Appears in:

FieldDescription
1.2agentgateway currently only supports TLS 1.2 and TLS 1.3.
1.3

Timeouts

Appears in:

FieldDescriptionDefaultValidation
request DurationTimeout for an individual request from the gateway to a backend. This covers the time from when
the request first starts being sent from the gateway to when the full response has been received from the backend.
Optional: {}

Tracing

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceOTLP server to reach.
Supported types: Service and AgentgatewayBackend.
Required: {}
protocol OTLPProtocolOTLP protocol variant to use.GRPCOptional: {}
path LongStringOTLP path to use. This is only applicable when
protocol is HTTP. If unset, this defaults to /v1/traces.
MaxLength: 1024
MinLength: 1
Optional: {}
attributes LogTracingAttributesCustomizations to the key-value pairs that are
included in the trace.
Optional: {}
resources ResourceAdd arrayEntity producing telemetry and resources
resources to be included in the trace.
Optional: {}
randomSampling CELExpressionExpression that determines the amount of random
sampling. Random sampling will initiate a new trace span if the incoming
request does not have a trace initiated already. This should evaluate to
a float between 0.0 and 1.0, or a boolean (true or false). If
unspecified, random sampling is disabled.
MaxLength: 16384
MinLength: 1
Optional: {}
clientSampling CELExpressionExpression that determines the amount of client
sampling. Client sampling determines whether to initiate a new trace
span if the incoming request does have a trace already. This should
evaluate to a float between 0.0 and 1.0, or a boolean (true or
false). If unspecified, client sampling is 100% enabled.
MaxLength: 16384
MinLength: 1
Optional: {}

Traffic

Appears in:

FieldDescriptionDefaultValidation
phase PolicyPhaseThe phase to apply the traffic policy to. If the phase is PreRouting,
the targetRef must be a Gateway or a Listener. PreRouting is
typically used only when a policy needs to influence the routing
decision.
Even when using PostRouting mode, the policy can target the
Gateway or Listener. This is a helper for applying the policy to all
routes under that Gateway or Listener, and follows the merging logic
described above.
Note: PreRouting and PostRouting rules do not merge together. These
are independent execution phases. That is, all PreRouting rules will
merge and execute, then all PostRouting rules will merge and execute.
If unset, this defaults to PostRouting.
Optional: {}
transformation TransformationOrConditionalMutates and transforms requests and responses
before forwarding them to the destination.
Optional: {}
extProc ExtProcOrConditionalExternal processing configuration for the policy.Optional: {}
extAuth ExtAuthOrConditionalExternal authentication configuration for the policy.
This selects the external server to send requests to for authentication.
An extAuth policy can be conditionally set by nesting configuration under the conditional field.
Optional: {}
rateLimit RateLimitsOrConditionalRate limiting configuration for the policy.
This limits the rate at which requests are processed.
Optional: {}
cors CORSCORS configuration for the policy.Optional: {}
csrf CSRFCross-Site Request Forgery (CSRF) policy for this traffic policy.
The CSRF policy has the following behavior:
* Safe methods (GET, HEAD, OPTIONS) are automatically allowed.
* Requests without Sec-Fetch-Site or Origin headers are assumed to
be same-origin or non-browser requests and are allowed.
* Otherwise, the Sec-Fetch-Site header is checked, with a fallback to
comparing the Origin header to the Host header.
Optional: {}
headerModifiers HeaderModifiersRequest and response header modification policy.Optional: {}
hostRewrite HostnameRewriteHow to rewrite the Host header for requests.
If the HTTPRoute urlRewrite filter already specifies a host rewrite,
this setting is ignored.
Optional: {}
timeouts TimeoutsRequest timeouts.
It is applicable to HTTPRoute resources and ignored for other targeted
kinds.
Optional: {}
retry RetryRetry policy.Optional: {}
authorization AuthorizationAccess rules based on roles and
permissions.
If multiple authorization rules are applied across different policies, at the same or different attachment points,
all rules are merged.
Optional: {}
jwtAuthentication JWTAuthenticationAuthenticates users based on JWT tokens.Optional: {}
basicAuthentication BasicAuthenticationAuthenticates users based on the Basic
authentication scheme (RFC 7617), where a username and password are
encoded in the request.
ExactlyOneOf: [users secretRef]
Optional: {}
apiKeyAuthentication APIKeyAuthenticationAuthenticates users based on a configured API
key.
ExactlyOneOf: [secretRef secretSelector]
Optional: {}
directResponse DirectResponseOrConditionalSends a direct response to the
client.
Optional: {}
buffer BufferBuffers request and response bodies. Buffered bodies are accumulated in memory
by the proxy until completion before being forwarded. This changes the proxies default behavior, which streams bodies.
Warning: large bodies can lead to excessive memory usage in the proxy. Utilize with care, or with strict limits.
Optional: {}

TrailerSendMode

Underlying type: string

Whether HTTP trailers are delivered to the external processor.

Validation:

  • Enum: [Skip Send]

Appears in:

FieldDescription
SkipTrailerSendModeSkip does not send trailers to the external processor.
SendTrailerSendModeSend sends trailers to the external processor.

Transform

Appears in:

FieldDescriptionDefaultValidation
set HeaderTransformation arrayHeaders to set and the values to use.MaxItems: 16
MinItems: 1
Optional: {}
add HeaderTransformation arrayHeaders 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.
MaxItems: 16
MinItems: 1
Optional: {}
remove HeaderName arrayHeader names to remove from the request or
response.
MaxItems: 16
MaxLength: 256
MinItems: 1
MinLength: 1
Pattern: ^:?[A-Za-z0-9!#$%&'*+\-.^_\x60|~]+$
Optional: {}
body CELExpressionHTTP body transformation.MaxLength: 16384
MinLength: 1
Optional: {}
metadata object (keys:string, values:CELExpression)Refer to Kubernetes API documentation for fields of metadata.MaxProperties: 16
MinProperties: 1
Optional: {}

Transformation

Appears in:

FieldDescriptionDefaultValidation
request TransformRequest transformation settings.Optional: {}
response TransformResponse transformation settings.Optional: {}

TransformationConditional

Appears in:

FieldDescriptionDefaultValidation
condition CELExpressionCEL expression that must evaluate to true for this policy to execute.MaxLength: 16384
MinLength: 1
Optional: {}
policy TransformationPolicy to apply when the condition matches.Required: {}

TransformationOrConditional

Appears in:

FieldDescriptionDefaultValidation
request TransformRequest transformation settings.Optional: {}
response TransformResponse transformation settings.Optional: {}
conditional TransformationConditional arrayConditional policy execution. Set this or the top-level transformation fields.
The first matching policy will be executed.
A single policy may be provided without a condition set; if so, it must be the last policy and will be the fallback
in case no conditions are met.
MaxItems: 16
MinItems: 1
Optional: {}

VertexAIConfig

Settings for the Vertex AI LLM provider.

Appears in:

FieldDescriptionDefaultValidation
model ShortStringModel name override, such as gpt-4o-mini.
If unset, the model name is taken from the request.
MaxLength: 256
MinLength: 1
Optional: {}
projectId TinyStringThe ID of the Google Cloud Project that you use for the Vertex AI.MaxLength: 64
MinLength: 1
Required: {}
region TinyStringThe location of the Google Cloud Project that you use for the Vertex AI.
Defaults to global if not specified.
globalMaxLength: 64
MinLength: 1
Optional: {}

Webhook

Webhook for prompt guard request or response checks.

Appears in:

FieldDescriptionDefaultValidation
backendRef BackendObjectReferenceWebhook server to reach.
Supported types: Service and Backend.
Required: {}
forwardHeaderMatches HTTPHeaderMatch arrayHTTP 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.
Optional: {}
failureMode FailureModeBehavior when the webhook guardrail is unavailable
or returns an error. FailOpen allows the request to continue.
FailClosed (default) rejects the request.
Optional: {}

Shared Types

The following types are defined in the shared package and used across multiple APIs.

LongString

Underlying type: string

Validation:

  • MinLength=1
  • MaxLength=1024

PolicyAncestorStatus

FieldTypeDescription
ancestorRefgwv1.ParentReferenceThe ancestor resource that this status entry describes. Required.
controllerNamestringThe controller that wrote this status entry. Example: example.net/gateway-controller. Required.
conditions[]metav1.ConditionConditions for this policy’s effect on the specified ancestor.

PolicyStatus

FieldTypeDescription
conditions[]metav1.ConditionThe current condition state for the policy.
ancestors[]PolicyAncestorStatusStatus for each ancestor that is affected by this policy. Required.

SNI

Underlying type: string

Validation:

  • MinLength=1
  • MaxLength=253
  • Pattern=^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$

ShortString

Underlying type: string

Validation:

  • MinLength=1
  • MaxLength=256

TinyString

Underlying type: string

Validation:

  • MinLength=1
  • MaxLength=64
Was this page helpful?
Agentgateway assistant

Ask me anything about agentgateway configuration, features, or usage.

Note: AI-generated content might contain errors; please verify and test all returned information.

Tip: one topic per conversation gives the best results. Use the + button in the chat header to start a new conversation.

Switching topics? Starting a new conversation improves accuracy.
↑↓ navigate select esc dismiss

What could be improved?

Your feedback helps us improve assistant answers and identify docs gaps we should fix.

Need more help? Join us on Discord: https://discord.gg/y9efgEmppm

Want to use your own agent? Add the Solo MCP server to query our docs directly. Get started here: https://search.solo.io/.