{"openapi":"3.1.0","info":{"title":"FastAPI","version":"0.1.0"},"paths":{"/healthcheck":{"get":{"summary":"Healthcheck","operationId":"healthcheck_healthcheck_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/ready":{"get":{"summary":"Ready","operationId":"ready_ready_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v2/model/chat/completion":{"post":{"summary":"Chat Completion","operationId":"chat_completion_api_v2_model_chat_completion_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v2/model/ai/completion":{"post":{"summary":"Ai Completion","description":"Run a completion with the configuration in the body, no user-created agent needed.","operationId":"ai_completion_api_v2_model_ai_completion_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v2/model/claude_code/verify":{"post":{"summary":"Verify Claude Login","description":"Check a Claude login (the token `claude setup-token` prints) before it is saved for an org.\nBody: ``{\"apikey\": \"<token>\"}``. Makes one tiny call on that login.","operationId":"verify_claude_login_api_v2_model_claude_code_verify_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v2/model/openai/responses":{"post":{"summary":"Openai Sdk Responses","operationId":"openai_sdk_responses_api_v2_model_openai_responses_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v2/model/batch/chat/completion":{"post":{"summary":"Batch Chat Completion","operationId":"batch_chat_completion_api_v2_model_batch_chat_completion_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v2/model/testcases":{"post":{"summary":"Run Testcases Route","description":"Execute testcases either from direct input or MongoDB\n\nReturns immediately and streams results to an RTLayer channel\n`{org_id}_{bridge_id}` as each testcase completes. Avoids HTTP timeouts\non long testcase runs.\n\nEvents published to the channel:\n- run_started        : { bridge_id, version_ids, total_testcases }\n- testcase_result    : { version_id, result }\n- version_completed  : { version_id, total_testcases, results }\n- run_completed      : full final payload\n- run_failed         : { error } on any unhandled execution error","operationId":"run_testcases_route_api_v2_model_testcases_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v2/model/rerun":{"post":{"summary":"Rerun Messages Route","description":"Rerun previous messages with current bridge configuration.\nEach message is pushed to the queue for async processing.\n\nOption 1 – by message IDs:\n    Body: {\"bridge_id\": \"...\", \"message_ids\": [\"msg-id-1\", ...]}\nOption 2 – by thread (reruns the last message in the thread):\n    Body: {\"bridge_id\": \"...\", \"thread_id\": \"...\", \"sub_thread_id\": \"...\"}","operationId":"rerun_messages_route_api_v2_model_rerun_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/browser/live/{token}":{"get":{"summary":"Live View","description":"Send whoever holds the link to this conversation's browser as it is right now.","operationId":"live_view_browser_live__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/browser/live-session/{token}":{"get":{"summary":"Live Session","description":"The live view URL for a signed-in viewer, as JSON, for the UI to put in its iframe.\n\nOnly the conversation's org gets it, and only the conversation's own user when the token\nnames one. The URL itself is a credential for that one browser, so it is never cached.","operationId":"live_session_browser_live_session__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/browser/providers":{"get":{"summary":"Browser Providers","description":"The browser services an agent can pick in ``gtwy_browser_settings.provider``: id, label,\nwhether it is set up on this server (only those work), and which one is the default.","operationId":"browser_providers_browser_providers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/chatbot/{botId}/sendMessage":{"post":{"summary":"Send Message","operationId":"send_message_chatbot__botId__sendMessage_post","parameters":[{"name":"botId","in":"path","required":true,"schema":{"type":"string","title":"Botid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChatbotSendMessageRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/image/processing/":{"post":{"summary":"Image","operationId":"image_image_processing__post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_image_image_processing__post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/image/processing/multi":{"post":{"summary":"Multi Image","operationId":"multi_image_image_processing_multi_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_multi_image_image_processing_multi_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/image/processing/upload":{"post":{"summary":"Upload","operationId":"upload_image_processing_upload_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/files/":{"post":{"summary":"Image","operationId":"image_files__post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_image_files__post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/files/multi":{"post":{"summary":"Multi Image","operationId":"multi_image_files_multi_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_multi_image_files_multi_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/files/upload":{"post":{"summary":"Upload","operationId":"upload_files_upload_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/rag/query":{"post":{"summary":"Get Query","operationId":"get_query_rag_query_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RAGQueryRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"Body_image_files__post":{"properties":{"image":{"type":"string","contentMediaType":"application/octet-stream","title":"Image"}},"type":"object","required":["image"],"title":"Body_image_files__post"},"Body_image_image_processing__post":{"properties":{"image":{"type":"string","contentMediaType":"application/octet-stream","title":"Image"}},"type":"object","required":["image"],"title":"Body_image_image_processing__post"},"Body_multi_image_files_multi_post":{"properties":{"image":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"Image"}},"type":"object","required":["image"],"title":"Body_multi_image_files_multi_post"},"Body_multi_image_image_processing_multi_post":{"properties":{"image":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"Image"}},"type":"object","required":["image"],"title":"Body_multi_image_image_processing_multi_post"},"ChatbotSendMessageRequest":{"properties":{"agent_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Id"},"version_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version Id"},"configuration":{"additionalProperties":true,"type":"object","title":"Configuration"},"service":{"anyOf":[{"type":"string","enum":["openai","gemini","anthropic","grok","deepseek","groq","open_router","mistral","deepgram","openai_completion","neev_cloud","moonshot","minimax","typesafe","claude_code"]},{"type":"null"}],"title":"Service"},"apikey":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apikey"},"response_type":{"anyOf":[{},{"type":"null"}],"title":"Response Type"},"template_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Template Id"},"variables":{"additionalProperties":true,"type":"object","title":"Variables"},"variables_path":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Variables Path"},"extra_tools":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Extra Tools"},"built_in_tools":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Built In Tools"},"guardrails":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Guardrails"},"web_search_filters":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Web Search Filters"},"gtwy_browser_settings":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Gtwy Browser Settings"},"mcp_auth":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"additionalProperties":{"type":"string"},"type":"object","maxProperties":1,"minProperties":1}]},"type":"object"},{"type":"null"}],"title":"Mcp Auth"},"orchestrator_flag":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Orchestrator Flag"},"environment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment"},"wrapper_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wrapper Id"},"auto_model_select":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Auto Model Select"},"cache_on":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cache On"},"user":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User"},"images":{"items":{},"type":"array","title":"Images"},"files":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Files"},"user_urls":{"anyOf":[{"items":{"$ref":"#/components/schemas/UserUrlItem"},"type":"array"},{"type":"null"}],"title":"User Urls"},"thread_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thread Id"},"sub_thread_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sub Thread Id"},"stream":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Stream"},"is_stream":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Stream"},"is_playground":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Playground"},"is_rerun":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Rerun"},"message_ids":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Message Ids"},"batch":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Batch"},"webhook":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook"},"batch_variables":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Batch Variables"},"slugName":{"type":"string","title":"Slugname"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"threadId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Threadid"},"subThreadId":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subthreadid"},"flag":{"type":"boolean","title":"Flag","default":false},"interfaceContextData":{"additionalProperties":true,"type":"object","title":"Interfacecontextdata"}},"additionalProperties":true,"type":"object","required":["slugName"],"title":"ChatbotSendMessageRequest"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"RAGQueryRequest":{"properties":{"query":{"type":"string","title":"Query"},"top_k":{"type":"integer","minimum":1.0,"title":"Top K","default":2},"score":{"type":"number","maximum":1.0,"minimum":0.1,"title":"Score","default":0.1},"collection_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Collection Id"},"owner_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Owner Id"},"doc_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Doc Id"},"resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Id"}},"additionalProperties":true,"type":"object","required":["query"],"title":"RAGQueryRequest"},"UserUrlItem":{"properties":{"type":{"anyOf":[{"type":"string","enum":["image","audio","video","file","pdf"]},{"type":"null"}],"title":"Type"},"url":{"anyOf":[{"type":"string","pattern":"^https?://(?:(?:\\d{1,3}\\.){3}\\d{1,3}|[^\\s/?#:]+)(?::\\d{1,5})?(?:[/?#][^\\s]*)?$"},{"type":"null"}],"title":"Url"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"}},"additionalProperties":false,"type":"object","title":"UserUrlItem"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}