create_config
Create a Portkey configuration defining request routing, caching, retry behavior, and targets.
Instructions
Create a config that defines routing, cache, retry, and targets for requests; use update_config to modify an existing one and list_config_versions for history. At least one setting is required, new configs become active immediately once referenced by a key or prompt, and the call returns the new id and version_id.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"name": "<name>"
},
"name": "create_config"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Name for the new configuration | |
| targets | No | Array of target providers with virtual keys | |
| cache_mode | No | Cache mode: 'simple' or 'semantic' | |
| auto_caching | No | Automatically add Anthropic prompt caching. Set false to disable | |
| workspace_id | No | Workspace ID to create config in | |
| cache_max_age | No | Cache max age in seconds | |
| strategy_mode | No | Routing strategy: 'loadbalance' or 'fallback' | |
| retry_attempts | No | Number of retry attempts (1-5) | |
| retry_on_status_codes | No | HTTP status codes to retry on (e.g., [429, 500, 502, 503]) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | Call succeeded | |
| data | No | Success payload | |
| error | No | Failure details |