Reroute routes (#4088)

Co-authored-by: Douwe Osinga <douwe@squareup.com>
Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
Douwe Osinga
2025-08-14 14:23:02 -04:00
committed by GitHub
parent 290d29e961
commit d7e761c529
12 changed files with 466 additions and 523 deletions
+213 -1
View File
@@ -31,7 +31,7 @@
},
"responses": {
"200": {
"description": "added sub recipes to agent successfully",
"description": "Added sub recipes to agent successfully",
"content": {
"application/json": {
"schema": {
@@ -42,6 +42,84 @@
},
"401": {
"description": "Unauthorized - invalid secret key"
},
"424": {
"description": "Agent not initialized"
}
}
}
},
"/agent/prompt": {
"post": {
"tags": [
"super::routes::agent"
],
"operationId": "extend_prompt",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ExtendPromptRequest"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Extended system prompt successfully",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ExtendPromptResponse"
}
}
}
},
"401": {
"description": "Unauthorized - invalid secret key"
},
"424": {
"description": "Agent not initialized"
}
}
}
},
"/agent/session_config": {
"post": {
"tags": [
"super::routes::agent"
],
"operationId": "update_session_config",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/SessionConfigRequest"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Session config updated successfully",
"content": {
"text/plain": {
"schema": {
"type": "string"
}
}
}
},
"401": {
"description": "Unauthorized - invalid secret key"
},
"424": {
"description": "Agent not initialized"
},
"500": {
"description": "Internal server error"
}
}
}
@@ -90,6 +168,70 @@
}
}
},
"/agent/update_provider": {
"post": {
"tags": [
"super::routes::agent"
],
"operationId": "update_agent_provider",
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UpdateProviderRequest"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Provider updated successfully"
},
"400": {
"description": "Bad request - missing or invalid parameters"
},
"401": {
"description": "Unauthorized - invalid secret key"
},
"424": {
"description": "Agent not initialized"
},
"500": {
"description": "Internal server error"
}
}
}
},
"/agent/update_router_tool_selector": {
"post": {
"tags": [
"super::routes::agent"
],
"operationId": "update_router_tool_selector",
"responses": {
"200": {
"description": "Tool selection strategy updated successfully",
"content": {
"text/plain": {
"schema": {
"type": "string"
}
}
}
},
"401": {
"description": "Unauthorized - invalid secret key"
},
"424": {
"description": "Agent not initialized"
},
"500": {
"description": "Internal server error"
}
}
}
},
"/config": {
"get": {
"tags": [
@@ -1446,6 +1588,39 @@
"description": "A map of environment variables to set, e.g. API_KEY -> some_secret, HOST -> host"
}
},
"ErrorResponse": {
"type": "object",
"required": [
"error"
],
"properties": {
"error": {
"type": "string"
}
}
},
"ExtendPromptRequest": {
"type": "object",
"required": [
"extension"
],
"properties": {
"extension": {
"type": "string"
}
}
},
"ExtendPromptResponse": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean"
}
}
},
"ExtensionConfig": {
"oneOf": [
{
@@ -1799,6 +1974,15 @@
}
}
},
"GetToolsQuery": {
"type": "object",
"properties": {
"extension_name": {
"type": "string",
"nullable": true
}
}
},
"ImageContent": {
"type": "object",
"required": [
@@ -2618,6 +2802,19 @@
}
}
},
"SessionConfigRequest": {
"type": "object",
"properties": {
"response": {
"allOf": [
{
"$ref": "#/components/schemas/Response"
}
],
"nullable": true
}
}
},
"SessionDisplayInfo": {
"type": "object",
"required": [
@@ -3095,6 +3292,21 @@
}
}
},
"UpdateProviderRequest": {
"type": "object",
"required": [
"provider"
],
"properties": {
"model": {
"type": "string",
"nullable": true
},
"provider": {
"type": "string"
}
}
},
"UpdateScheduleRequest": {
"type": "object",
"required": [