AgentGateway · Schema
LLMBackend
Configuration for an LLM provider backend in AgentGateway, defining the target model, authentication, and routing parameters.
AI GatewayAPI GatewayMCPLLMAgent-to-AgentOpen SourceCNCFObservabilitySecurity
Properties
| Name | Type | Description |
|---|---|---|
| name | string | Unique name for this LLM backend. |
| provider | string | The LLM provider for this backend. |
| model | string | The model identifier to use for requests. |
| alias | string | Optional alias exposed to clients instead of the actual model name. |
| baseUrl | string | Base URL for the LLM provider API endpoint. |
| authentication | object | Authentication configuration for this backend. |
| weight | integer | Load balancing weight for this backend (higher means more traffic). |
| priority | integer | Failover priority, lower values have higher priority. |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://raw.githubusercontent.com/api-evangelist/agentgateway/refs/heads/main/json-schema/agentgateway-llm-backend-schema.json",
"title": "LLMBackend",
"description": "Configuration for an LLM provider backend in AgentGateway, defining the target model, authentication, and routing parameters.",
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "Unique name for this LLM backend.",
"example": "openai-gpt4"
},
"provider": {
"type": "string",
"description": "The LLM provider for this backend.",
"enum": ["openai", "anthropic", "gemini", "bedrock", "azure-openai", "ollama", "vllm"],
"example": "openai"
},
"model": {
"type": "string",
"description": "The model identifier to use for requests.",
"example": "gpt-4o"
},
"alias": {
"type": "string",
"description": "Optional alias exposed to clients instead of the actual model name.",
"example": "primary-llm"
},
"baseUrl": {
"type": "string",
"format": "uri",
"description": "Base URL for the LLM provider API endpoint.",
"example": "https://api.openai.com/v1"
},
"authentication": {
"type": "object",
"description": "Authentication configuration for this backend.",
"properties": {
"type": {
"type": "string",
"enum": ["bearer", "apikey", "basic"],
"example": "bearer"
},
"secretRef": {
"type": "string",
"description": "Reference to a secret containing the API key.",
"example": "openai-api-key"
}
}
},
"weight": {
"type": "integer",
"description": "Load balancing weight for this backend (higher means more traffic).",
"example": 100
},
"priority": {
"type": "integer",
"description": "Failover priority, lower values have higher priority.",
"example": 1
}
},
"required": ["name", "provider", "model"]
}