Fixed exports script

This commit is contained in:
James Ketr 2025-09-05 13:38:48 -07:00
parent af5e45fb38
commit d6791a5233
5 changed files with 2 additions and 321 deletions

View File

@ -1249,253 +1249,6 @@
} }
} }
} }
},
"/ai-voicebot/{path}": {
"post": {
"summary": "Proxy Static",
"operationId": "proxy_static_ai_voicebot__path__post",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string",
"title": "Path"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
},
"patch": {
"summary": "Proxy Static",
"operationId": "proxy_static_ai_voicebot__path__post",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string",
"title": "Path"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
},
"delete": {
"summary": "Proxy Static",
"operationId": "proxy_static_ai_voicebot__path__post",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string",
"title": "Path"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
},
"head": {
"summary": "Proxy Static",
"operationId": "proxy_static_ai_voicebot__path__post",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string",
"title": "Path"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
},
"put": {
"summary": "Proxy Static",
"operationId": "proxy_static_ai_voicebot__path__post",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string",
"title": "Path"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
},
"options": {
"summary": "Proxy Static",
"operationId": "proxy_static_ai_voicebot__path__post",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string",
"title": "Path"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
},
"get": {
"summary": "Proxy Static",
"operationId": "proxy_static_ai_voicebot__path__post",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string",
"title": "Path"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
}
} }
}, },
"components": { "components": {

View File

@ -276,34 +276,6 @@ export class ApiClient {
async getExportMetricsPrometheus(): Promise<any> { async getExportMetricsPrometheus(): Promise<any> {
return this.request<any>(this.getApiPath(`/ai-voicebot/api/metrics/export`), { method: "GET" }); return this.request<any>(this.getApiPath(`/ai-voicebot/api/metrics/export`), { method: "GET" });
} }
async createProxyStatic(path: string): Promise<any> {
return this.request<any>(this.getApiPath(`/ai-voicebot/${path}`), { method: "POST" });
}
async updateProxyStatic(path: string): Promise<any> {
return this.request<any>(this.getApiPath(`/ai-voicebot/${path}`), { method: "PATCH" });
}
async deleteProxyStatic(path: string): Promise<any> {
return this.request<any>(this.getApiPath(`/ai-voicebot/${path}`), { method: "DELETE" });
}
async headProxyStatic(path: string): Promise<any> {
return this.request<any>(this.getApiPath(`/ai-voicebot/${path}`), { method: "HEAD" });
}
async replaceProxyStatic(path: string): Promise<any> {
return this.request<any>(this.getApiPath(`/ai-voicebot/${path}`), { method: "PUT" });
}
async optionsProxyStatic(path: string): Promise<any> {
return this.request<any>(this.getApiPath(`/ai-voicebot/${path}`), { method: "OPTIONS" });
}
async getProxyStatic(path: string): Promise<any> {
return this.request<any>(this.getApiPath(`/ai-voicebot/${path}`), { method: "GET" });
}
} }
// Default client instance // Default client instance

View File

@ -7,7 +7,6 @@ export const knownEndpoints = new Set([
`DELETE:${base}/api/bots/config/lobby/{lobby_id}`, `DELETE:${base}/api/bots/config/lobby/{lobby_id}`,
`DELETE:${base}/api/bots/config/lobby/{lobby_id}/bot/{bot_name}`, `DELETE:${base}/api/bots/config/lobby/{lobby_id}/bot/{bot_name}`,
`DELETE:${base}/api/bots/config/schema/{bot_name}/cache`, `DELETE:${base}/api/bots/config/schema/{bot_name}/cache`,
`DELETE:${base}/{path}`,
`GET:${base}/api/admin/names`, `GET:${base}/api/admin/names`,
`GET:${base}/api/admin/session_metrics`, `GET:${base}/api/admin/session_metrics`,
`GET:${base}/api/admin/validate_sessions`, `GET:${base}/api/admin/validate_sessions`,
@ -30,10 +29,6 @@ export const knownEndpoints = new Set([
`GET:${base}/api/session`, `GET:${base}/api/session`,
`GET:${base}/api/system/health`, `GET:${base}/api/system/health`,
`GET:${base}/api/system/info`, `GET:${base}/api/system/info`,
`GET:${base}/{path}`,
`HEAD:${base}/{path}`,
`OPTIONS:${base}/{path}`,
`PATCH:${base}/{path}`,
`POST:${base}/api/admin/cleanup_lobbies`, `POST:${base}/api/admin/cleanup_lobbies`,
`POST:${base}/api/admin/cleanup_sessions`, `POST:${base}/api/admin/cleanup_sessions`,
`POST:${base}/api/admin/clear_password`, `POST:${base}/api/admin/clear_password`,
@ -45,9 +40,7 @@ export const knownEndpoints = new Set([
`POST:${base}/api/bots/providers/register`, `POST:${base}/api/bots/providers/register`,
`POST:${base}/api/bots/{bot_name}/join`, `POST:${base}/api/bots/{bot_name}/join`,
`POST:${base}/api/cache/clear`, `POST:${base}/api/cache/clear`,
`POST:${base}/api/lobby/{session_id}`, `POST:${base}/api/lobby/{session_id}`
`POST:${base}/{path}`,
`PUT:${base}/{path}`
]); ]);
// Schema path for dynamic usage // Schema path for dynamic usage

View File

@ -261,22 +261,6 @@ export interface paths {
*/ */
get: operations["export_metrics_prometheus_ai_voicebot_api_metrics_export_get"]; get: operations["export_metrics_prometheus_ai_voicebot_api_metrics_export_get"];
}; };
"/ai-voicebot/{path}": {
/** Proxy Static */
get: operations["proxy_static_ai_voicebot__path__post"];
/** Proxy Static */
put: operations["proxy_static_ai_voicebot__path__post"];
/** Proxy Static */
post: operations["proxy_static_ai_voicebot__path__post"];
/** Proxy Static */
delete: operations["proxy_static_ai_voicebot__path__post"];
/** Proxy Static */
options: operations["proxy_static_ai_voicebot__path__post"];
/** Proxy Static */
head: operations["proxy_static_ai_voicebot__path__post"];
/** Proxy Static */
patch: operations["proxy_static_ai_voicebot__path__post"];
};
} }
export type webhooks = Record<string, never>; export type webhooks = Record<string, never>;
@ -1576,26 +1560,4 @@ export interface operations {
}; };
}; };
}; };
/** Proxy Static */
proxy_static_ai_voicebot__path__post: {
parameters: {
path: {
path: string;
};
};
responses: {
/** @description Successful Response */
200: {
content: {
"application/json": unknown;
};
};
/** @description Validation Error */
422: {
content: {
"application/json": components["schemas"]["HTTPValidationError"];
};
};
};
};
} }

View File

@ -239,6 +239,7 @@ async def lifespan(app: FastAPI):
@app.api_route( @app.api_route(
f"{public_url}{{path:path}}", f"{public_url}{{path:path}}",
methods=["GET", "POST", "PUT", "DELETE", "OPTIONS", "HEAD", "PATCH"], methods=["GET", "POST", "PUT", "DELETE", "OPTIONS", "HEAD", "PATCH"],
include_in_schema=False,
) )
async def proxy_static(request: Request, path: str): async def proxy_static(request: Request, path: str):
# Do not proxy API or websocket paths # Do not proxy API or websocket paths