{"openapi":"3.1.0","info":{"title":"External APIs","description":"A FastAPI application for handling external API integrations","version":"1.0.0"},"paths":{"/v1/auth/token":{"post":{"tags":["Auth"],"summary":"Get Auth Token","operationId":"get_auth_token_v1_auth_token_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthTokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/auth/validate-token":{"post":{"tags":["Auth"],"summary":"Validate Token","operationId":"validate_token_v1_auth_validate_token_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgData"}}}}},"security":[{"JWTBearer":[]}]}},"/v1/conversations/":{"post":{"tags":["Conversations"],"summary":"Create a new conversation","description":"Creates a new conversation for an end user","operationId":"create_conversation_v1_conversations__post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectA3CreateConversationResponse"}}}}},"security":[{"JWTBearer":[]}]}},"/v1/conversations/{conversation_id}/messages":{"post":{"tags":["Conversations"],"summary":"Create a new message in a conversation","description":"Adds a new message to an existing conversation and generates an AI response. Accepts an optional 'stream' boolean in the request body.","operationId":"create_conversation_message_v1_conversations__conversation_id__messages_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Body_create_conversation_message_v1_conversations__conversation_id__messages_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectA3GenerateCompletionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"JWTBearer":[]}]}},"/v1/actions/list":{"get":{"tags":["Actions"],"summary":"List all actions","description":"Retrieves a list of all actions for an end user","operationId":"list_actions_v1_actions_list_get","security":[{"JWTBearer":[]}],"parameters":[{"name":"execution_type","in":"query","required":false,"schema":{"$ref":"#/components/schemas/ExecutionType","description":"Type of action execution to use","default":"DEFAULT"},"description":"Type of action execution to use"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdoptCapabilityList"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/actions/sync":{"post":{"tags":["Actions"],"summary":"Sync actions with training pipeline in the cloud.","description":"Syncs all actions with the training pipeline in Adopt cloud.","operationId":"sync_actions_v1_actions_sync_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectA3ApiDriverResponse"}}}}},"security":[{"JWTBearer":[]}]}},"/v1/actions/sync-mysql":{"post":{"tags":["Actions"],"summary":"Sync MySQL tables with on-prem deployment.","description":"Syncs MySQL tables from cloud to on-prem MySQL database.","operationId":"sync_mysql_tables_v1_actions_sync_mysql_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectA3ApiDriverResponse"}}}}},"security":[{"JWTBearer":[]}]}},"/v1/actions/sync-assist":{"post":{"tags":["Actions"],"summary":"Sync assist/vectors table with on-prem deployment.","description":"Syncs the vectors (assist) table from cloud to on-prem database. This should be called after /sync to ensure projecta3_config is synced first.","operationId":"sync_assist_vectors_v1_actions_sync_assist_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectA3ApiDriverResponse"}}}}},"security":[{"JWTBearer":[]}]}},"/v1/actions/run":{"post":{"tags":["Actions"],"summary":"Run a specific action.","description":"Triggers a specific action in the training pipeline. Use include_trace=true to get detailed execution trace for debugging. Optionally specify version_number to execute a specific version, or set allow_draft=True to allow executing draft versions. Defaults to latest published version.","operationId":"run_action_v1_actions_run_post","security":[{"JWTBearer":[]}],"parameters":[{"name":"include_trace","in":"query","required":false,"schema":{"type":"boolean","description":"Include detailed execution trace in response for debugging. This will include step-by-step input/output data.","default":false,"title":"Include Trace"},"description":"Include detailed execution trace in response for debugging. This will include step-by-step input/output data."},{"name":"allow_draft","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to allow executing draft versions. If True and version_number is not specified, uses latest draft. If False (or not specified), uses latest published version. Can also be set in request body; query param takes precedence.","title":"Allow Draft"},"description":"Whether to allow executing draft versions. If True and version_number is not specified, uses latest draft. If False (or not specified), uses latest published version. Can also be set in request body; query param takes precedence."},{"name":"version_number","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Optional version number to execute. If allow_draft=True, can execute draft versions. If not specified, uses version from request body or defaults to latest. Query param takes precedence over body.","title":"Version Number"},"description":"Optional version number to execute. If allow_draft=True, can execute draft versions. If not specified, uses version from request body or defaults to latest. Query param takes precedence over body."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LangChainDriverRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LangChainDriverResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/actions/run-wdl":{"post":{"tags":["Actions"],"summary":"Execute a WDL payload directly (no platform save required).","description":"Execute a Workflow Definition Language (WDL) payload directly without first saving the action to the Adopt platform. This is intended for iterative local testing and development workflows where round-tripping through the ABCD UI would slow iteration.\n\n**Profile support** mirrors the ``/run`` endpoint:\n- Pass ``profiles_map`` as a dict keyed by api_id / application name, each entry containing ``base_url``, ``security_headers`` (and optionally ``app_base_url``).\n- Use the ``'default'`` key as a catch-all fallback profile.\n- ``mcp_profiles_map`` follows the same convention for MCP integrations.\n\n**WDL format**: pass the backend / code-only WDL steps – the same list of operation dicts that would be stored in the ``wdl`` DB column. Use ``include_trace=true`` (query param) to get step-by-step debug output.","operationId":"run_wdl_directly_v1_actions_run_wdl_post","security":[{"JWTBearer":[]}],"parameters":[{"name":"include_trace","in":"query","required":false,"schema":{"type":"boolean","description":"Include detailed step-by-step execution trace in the response for debugging. Takes precedence over the ``include_execution_trace`` field in the request body.","default":false,"title":"Include Trace"},"description":"Include detailed step-by-step execution trace in the response for debugging. Takes precedence over the ``include_execution_trace`` field in the request body."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunWdlDirectlyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LangChainDriverResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/api-discovery/upload-file":{"post":{"tags":["api-discovery"],"summary":"Upload an API file","description":"Upload a Postman collection (.json) or HAR file (.har) for API discovery","operationId":"upload_api_discovery_file_v1_api_discovery_upload_file_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_api_discovery_file_v1_api_discovery_upload_file_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FileUploadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"JWTBearer":[]}]}},"/v1/tools/apis":{"get":{"tags":["Tools"],"summary":"List documented APIs","description":"Returns a paginated list of Adopt-documented APIs","operationId":"list_documented_apis_v1_tools_apis_get","security":[{"JWTBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":10,"title":"Page Size"},"description":"Items per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Optional search query","title":"Search"},"description":"Optional search query"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tools/apis/{api_id}":{"get":{"tags":["Tools"],"summary":"Get a documented API","description":"Returns a documented API by ID","operationId":"get_documented_api_v1_tools_apis__api_id__get","security":[{"JWTBearer":[]}],"parameters":[{"name":"api_id","in":"path","required":true,"schema":{"type":"string","title":"Api Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tools/apis-detailed":{"get":{"tags":["Tools"],"summary":"List detailed ProjectA3 APIs","description":"Returns a paginated list of detailed API information from ProjectA3 API store","operationId":"list_detailed_apis_v1_tools_apis_detailed_get","security":[{"JWTBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":10,"title":"Page Size"},"description":"Items per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search in title and API endpoint","title":"Search"},"description":"Search in title and API endpoint"},{"name":"method","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"HTTP method filter","title":"Method"},"description":"HTTP method filter"},{"name":"api_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"API type filter","title":"Api Type"},"description":"API type filter"},{"name":"is_usable","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Is usable filter","title":"Is Usable"},"description":"Is usable filter"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/tools/apis-detailed/{api_id}":{"get":{"tags":["Tools"],"summary":"Get a detailed ProjectA3 API","description":"Returns detailed API information from ProjectA3 API store by ID","operationId":"get_detailed_api_v1_tools_apis_detailed__api_id__get","security":[{"JWTBearer":[]}],"parameters":[{"name":"api_id","in":"path","required":true,"schema":{"type":"string","title":"Api Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/action-logs/":{"get":{"tags":["Action Logs"],"summary":"List action logs","description":"Fetch action logs filtered to specific fields only","operationId":"list_action_logs_v1_action_logs__get","security":[{"JWTBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":10,"title":"Page Size"},"description":"Items per page"},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Start date in YYYY-MM-DD format","title":"Start Date"},"description":"Start date in YYYY-MM-DD format"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"End date in YYYY-MM-DD format","title":"End Date"},"description":"End date in YYYY-MM-DD format"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/action-logs/{action_log_id}/messages":{"get":{"tags":["Action Logs"],"summary":"Get messages for an action log","description":"Get messages for an action log by ID","operationId":"get_action_log_messages_v1_action_logs__action_log_id__messages_get","security":[{"JWTBearer":[]}],"parameters":[{"name":"action_log_id","in":"path","required":true,"schema":{"type":"string","title":"Action Log Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/http-network-logs":{"get":{"tags":["HTTP Network Logs"],"summary":"List HTTP network logs","description":"Returns a paginated list of HTTP network logs for the authenticated organization","operationId":"list_http_network_logs_v1_http_network_logs_get","security":[{"JWTBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":10,"title":"Page Size"},"description":"Items per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search in API URLs","title":"Search"},"description":"Search in API URLs"},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Start date (ISO format)","title":"Start Date"},"description":"Start date (ISO format)"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"End date (ISO format)","title":"End Date"},"description":"End date (ISO format)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/http-network-logs/{log_id}":{"get":{"tags":["HTTP Network Logs"],"summary":"Get a HTTP network log","description":"Returns a HTTP network log by ID for the authenticated organization","operationId":"get_http_network_log_v1_http_network_logs__log_id__get","security":[{"JWTBearer":[]}],"parameters":[{"name":"log_id","in":"path","required":true,"schema":{"type":"string","title":"Log Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/wdl/validate":{"post":{"tags":["WDL"],"summary":"Validate Wdl Endpoint","description":"Validate a WDL workflow using the two-layer compiler.\n\nReturns HTTP 200 for both SUCCESS and FAILURE (compilation executed\ncorrectly; check the ``status`` field for the outcome).\nHTTP 500 only on unexpected compiler crashes.","operationId":"validate_wdl_endpoint_v1_wdl_validate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WdlValidateRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WdlValidateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"JWTBearer":[]}]}}},"components":{"schemas":{"AIMessage-Input":{"properties":{"content":{"anyOf":[{"type":"string"},{"items":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"}]},"type":"array"}],"title":"Content"},"additional_kwargs":{"additionalProperties":true,"type":"object","title":"Additional Kwargs"},"response_metadata":{"additionalProperties":true,"type":"object","title":"Response Metadata"},"type":{"type":"string","const":"ai","title":"Type","default":"ai"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"tool_calls":{"items":{"$ref":"#/components/schemas/ToolCall"},"type":"array","title":"Tool Calls"},"invalid_tool_calls":{"items":{"$ref":"#/components/schemas/InvalidToolCall"},"type":"array","title":"Invalid Tool Calls"},"usage_metadata":{"anyOf":[{"$ref":"#/components/schemas/UsageMetadata"},{"type":"null"}]}},"additionalProperties":true,"type":"object","required":["content"],"title":"AIMessage","description":"Message from an AI.\n\nAn `AIMessage` is returned from a chat model as a response to a prompt.\n\nThis message represents the output of the model and consists of both\nthe raw output as returned by the model and standardized fields\n(e.g., tool calls, usage metadata) added by the LangChain framework."},"AIMessage-Output":{"properties":{"content":{"anyOf":[{"type":"string"},{"items":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"}]},"type":"array"}],"title":"Content"},"additional_kwargs":{"additionalProperties":true,"type":"object","title":"Additional Kwargs"},"response_metadata":{"additionalProperties":true,"type":"object","title":"Response Metadata"},"type":{"type":"string","const":"ai","title":"Type","default":"ai"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"tool_calls":{"items":{"$ref":"#/components/schemas/ToolCall"},"type":"array","title":"Tool Calls"},"invalid_tool_calls":{"items":{"$ref":"#/components/schemas/InvalidToolCall"},"type":"array","title":"Invalid Tool Calls"},"usage_metadata":{"anyOf":[{"$ref":"#/components/schemas/UsageMetadata"},{"type":"null"}]}},"additionalProperties":true,"type":"object","required":["content"],"title":"AIMessage","description":"Message from an AI.\n\nAn `AIMessage` is returned from a chat model as a response to a prompt.\n\nThis message represents the output of the model and consists of both\nthe raw output as returned by the model and standardized fields\n(e.g., tool calls, usage metadata) added by the LangChain framework."},"AdoptCapability":{"properties":{"title":{"type":"string","title":"Title","description":"The capability of the adopt agent, detailing what actions it can perform.","default":""},"description":{"type":"string","title":"Description","description":"A detailed description of the adopt agent's capabilities.","default":""},"id":{"type":"string","title":"Id","description":"Unique identifier for the adopt agent's capability.","default":""},"required_inputs":{"items":{"type":"string"},"type":"array","title":"Required Inputs","description":"List of required inputs for the adopt agent's capability. Each input is a string."},"apis":{"items":{"$ref":"#/components/schemas/ApiDetails"},"type":"array","title":"Apis","description":"List of API details for the adopt agent's capability."}},"type":"object","title":"AdoptCapability","description":"Prompt for the adopt capability."},"AdoptCapabilityList":{"properties":{"capabilities":{"items":{"$ref":"#/components/schemas/AdoptCapability"},"type":"array","title":"Capabilities","description":"List of adopt agent capabilities."}},"type":"object","title":"AdoptCapabilityList","description":"List of adopt capabilities."},"ApiDetails":{"properties":{"id":{"type":"string","title":"Id","description":"The unique identifier of the API","default":""},"method":{"type":"string","title":"Method","description":"The HTTP method of the API (GET, POST, PUT, DELETE, etc.).","default":""},"endpoint":{"type":"string","title":"Endpoint","description":"The canonical API endpoint of the API.","default":""}},"type":"object","title":"ApiDetails","description":"Details of the API."},"AuthRequest":{"properties":{"clientId":{"type":"string","title":"Clientid"},"secret":{"type":"string","title":"Secret"}},"type":"object","required":["clientId","secret"],"title":"AuthRequest"},"AuthTokenResponse":{"properties":{"access_token":{"type":"string","title":"Access Token"},"refresh_token":{"type":"string","title":"Refresh Token"},"expires_in":{"type":"integer","title":"Expires In"},"expires":{"type":"string","title":"Expires"}},"type":"object","required":["access_token","refresh_token","expires_in","expires"],"title":"AuthTokenResponse"},"Body_create_conversation_message_v1_conversations__conversation_id__messages_post":{"properties":{"message_request":{"$ref":"#/components/schemas/ProjectA3GenerateCompletionRequest"},"stream":{"type":"boolean","title":"Stream","description":"Whether to stream the response","default":false}},"type":"object","required":["message_request"],"title":"Body_create_conversation_message_v1_conversations__conversation_id__messages_post"},"Body_upload_api_discovery_file_v1_api_discovery_upload_file_post":{"properties":{"file":{"type":"string","format":"binary","title":"File","description":"API file to upload (.json or .har)"},"metadata":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Metadata","description":"Metadata along with file upload (BYOK Keys)"}},"type":"object","required":["file"],"title":"Body_upload_api_discovery_file_v1_api_discovery_upload_file_post"},"ExecutionType":{"type":"string","enum":["TOOL","WORKFLOW","DEFAULT","ALL"],"title":"ExecutionType"},"FileUploadResponse":{"properties":{"status":{"type":"string","title":"Status"},"message":{"type":"string","title":"Message"},"workflow_id":{"type":"string","title":"Workflow Id"},"org_id":{"type":"string","title":"Org Id"},"details":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Details"}},"type":"object","required":["status","message","workflow_id","org_id"],"title":"FileUploadResponse","description":"Response model for file upload (Postman/HAR)"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"HumanMessage":{"properties":{"content":{"anyOf":[{"type":"string"},{"items":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"}]},"type":"array"}],"title":"Content"},"additional_kwargs":{"additionalProperties":true,"type":"object","title":"Additional Kwargs"},"response_metadata":{"additionalProperties":true,"type":"object","title":"Response Metadata"},"type":{"type":"string","const":"human","title":"Type","default":"human"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"}},"additionalProperties":true,"type":"object","required":["content"],"title":"HumanMessage","description":"Message from the user.\n\nA `HumanMessage` is a message that is passed in from a user to the model.\n\nExample:\n    ```python\n    from langchain_core.messages import HumanMessage, SystemMessage\n\n    messages = [\n        SystemMessage(content=\"You are a helpful assistant! Your name is Bob.\"),\n        HumanMessage(content=\"What is your name?\"),\n    ]\n\n    # Instantiate a chat model and invoke it with the messages\n    model = ...\n    print(model.invoke(messages))\n    ```"},"InlineActionDefinition":{"properties":{"title":{"type":"string","title":"Title","description":"Tool name (used as LangChain tool name)"},"description":{"type":"string","title":"Description","description":"Tool description for the LLM","default":""},"wdl":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Wdl","description":"The full WDL for this subaction — same format as a widdle.json file. The required_inputs block (the entry without an 'id' key) is extracted automatically from this array, just like the WiddleExecutor already does."}},"type":"object","required":["title","wdl"],"title":"InlineActionDefinition","description":"Defines a subaction inline, without needing it saved on the platform.\n\nUsed by uber agents (PROMPT_AND_TOOLS_AGENT) during direct WDL execution\nto resolve action_ids from the request payload instead of the platform DB."},"InputTokenDetails":{"properties":{"audio":{"type":"integer","title":"Audio"},"cache_creation":{"type":"integer","title":"Cache Creation"},"cache_read":{"type":"integer","title":"Cache Read"}},"additionalProperties":true,"type":"object","title":"InputTokenDetails","description":"Breakdown of input token counts.\n\nDoes *not* need to sum to full input token count. Does *not* need to have all keys.\n\nExample:\n    ```python\n    {\n        \"audio\": 10,\n        \"cache_creation\": 200,\n        \"cache_read\": 100,\n    }\n    ```\n\nMay also hold extra provider-specific keys.\n\n!!! version-added \"Added in `langchain-core` 0.3.9\""},"InvalidToolCall":{"properties":{"type":{"type":"string","const":"invalid_tool_call","title":"Type"},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"args":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Args"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"index":{"anyOf":[{"type":"integer"},{"type":"string"}],"title":"Index"},"extras":{"additionalProperties":true,"type":"object","title":"Extras"}},"additionalProperties":true,"type":"object","required":["type","id","name","args","error"],"title":"InvalidToolCall","description":"Allowance for errors made by LLM.\n\nHere we add an `error` key to surface errors made during generation\n(e.g., invalid JSON arguments.)"},"LangChainDriverRequest":{"properties":{"messages":{"items":{"anyOf":[{"$ref":"#/components/schemas/SystemMessage"},{"$ref":"#/components/schemas/HumanMessage"},{"$ref":"#/components/schemas/AIMessage-Input"}]},"type":"array","title":"Messages","description":"List of messages to process in the conversation."},"trace_id":{"type":"string","title":"Trace Id","description":"Unique identifier for the conversation trace.","default":"b0409e96-f47b-4478-b497-8298780d0cf7"},"base_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Base Url","description":"Base URL for the end user's tenant.","default":""},"workflow_params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Workflow Params","description":"Workflow parameters for the conversation, if any."},"security_params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Security Params","description":"Security parameters for the conversation, if any."},"user_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Message","description":"The user's message in the conversation, if applicable.","default":""},"action_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action Id","description":"The ID of the action to be performed, if applicable.","default":""},"fetch_latest_models":{"type":"boolean","title":"Fetch Latest Models","description":"Whether to fetch the latest models from the training portal.","default":false},"application_base_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Application Base Url","description":"Base URL for the application, if different from the tenant base URL.","default":""},"execution_type":{"$ref":"#/components/schemas/ExecutionType","description":"The type of action execution to use.","default":"DEFAULT"},"include_execution_trace":{"type":"boolean","title":"Include Execution Trace","description":"Whether to include detailed execution trace in response for debugging.","default":false},"version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version Number","description":"Optional version number of the action to execute. If not specified, defaults to latest published version. If specified, can fetch draft or specific published version."},"allow_draft":{"type":"boolean","title":"Allow Draft","description":"Whether to allow executing draft versions. If version_number is specified and action is draft, this must be True. If version_number is None and allow_draft is True, will fetch latest version (published or draft).","default":false},"profiles_map":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Profiles Map","description":"Map of profiles keyed by api_id or application. Each value contains base_url, security_headers, app_base_url. Use 'default' key for fallback profile."},"mcp_profiles_map":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Mcp Profiles Map","description":"Map of MCP profiles keyed by integration_id. Each value contains tool_id, security_headers. Use 'default' key for fallback profile."}},"type":"object","title":"LangChainDriverRequest","description":"Request model for LangChainDriver."},"LangChainDriverResponse":{"properties":{"status":{"type":"boolean","title":"Status","description":"Status of the response. True if successful, False otherwise.","default":false},"message":{"type":"string","title":"Message","description":"Message providing additional information about the response.","default":""},"ai_message":{"$ref":"#/components/schemas/AIMessage-Output","description":"Data returned by the driver, if any.","default":{"content":"","additional_kwargs":{},"response_metadata":{},"type":"ai","tool_calls":[],"invalid_tool_calls":[]}},"debug_tracing":{"anyOf":[{"$ref":"#/components/schemas/WiddleExecutionTrace"},{"type":"null"}],"description":"Detailed execution trace for debugging. Only included when include_execution_trace=True."}},"type":"object","title":"LangChainDriverResponse","description":"Response model for LangChainDriver."},"OperationStatus":{"type":"string","enum":["SUCCESS","FAILURE"],"title":"OperationStatus","description":"Enum for operation status"},"OperationStatusInfo":{"properties":{"status":{"$ref":"#/components/schemas/OperationStatus","description":"Status of the operation","default":"SUCCESS"},"error_message":{"type":"string","title":"Error Message","description":"Error message if operation failed","default":""},"status_code":{"type":"string","title":"Status Code","description":"HTTP status code for the operation","default":"200"}},"type":"object","title":"OperationStatusInfo","description":"Status information for an operation"},"OrgData":{"properties":{"org_id":{"type":"string","title":"Org Id"},"user_email":{"type":"string","title":"User Email"}},"type":"object","required":["org_id","user_email"],"title":"OrgData","description":"Organization data extracted from validated token"},"OutputTokenDetails":{"properties":{"audio":{"type":"integer","title":"Audio"},"reasoning":{"type":"integer","title":"Reasoning"}},"additionalProperties":true,"type":"object","title":"OutputTokenDetails","description":"Breakdown of output token counts.\n\nDoes *not* need to sum to full output token count. Does *not* need to have all keys.\n\nExample:\n    ```python\n    {\n        \"audio\": 10,\n        \"reasoning\": 200,\n    }\n    ```\n\nMay also hold extra provider-specific keys.\n\n!!! version-added \"Added in `langchain-core` 0.3.9\""},"ProjectA3ApiDriverResponse":{"properties":{"status":{"type":"string","title":"Status","description":"Status of the API call","default":"error"},"message":{"type":"string","title":"Message","description":"Response message","default":""},"data":{"additionalProperties":true,"type":"object","title":"Data","description":"Response data"}},"type":"object","title":"ProjectA3ApiDriverResponse","description":"Base model for API driver responses."},"ProjectA3CreateConversationResponse":{"properties":{"conversation_id":{"type":"string","title":"Conversation Id","description":"The ID of the newly created conversation."}},"type":"object","required":["conversation_id"],"title":"ProjectA3CreateConversationResponse","description":"Response model for creating a new conversation."},"ProjectA3GenerateCompletionRequest":{"properties":{"conversation_id":{"type":"string","title":"Conversation Id","description":"The ID of the conversation where the message will be created."},"message":{"type":"string","title":"Message","description":"The content of the message to be created."},"base_url":{"type":"string","title":"Base Url","description":"Base URL for the end user's tenant.","default":""},"app_base_url":{"type":"string","title":"App Base Url","description":"Base URL for the application, if different from the end user's tenant.","default":""},"workflow_params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Workflow Params","description":"Optional parameters for the workflow, if applicable."},"security_params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Security Params","description":"Optional security parameters for the request, if applicable."},"additional_metadata_values":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Additional Metadata Values","description":"Additional metadata values to be included in the request, such as flags for clickable follow-ups."},"profiles_map":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Profiles Map","description":"Map of profiles keyed by api_id or application. Each value contains base_url, security_headers, app_base_url. Use 'default' key for fallback profile."},"mcp_profiles_map":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Mcp Profiles Map","description":"Map of MCP profiles keyed by integration_id. Each value contains tool_id, security_headers. Use 'default' key for fallback profile."}},"type":"object","required":["conversation_id","message"],"title":"ProjectA3GenerateCompletionRequest","description":"Request model for creating a new message."},"ProjectA3GenerateCompletionResponse":{"properties":{"message_id":{"type":"string","title":"Message Id","description":"The ID of the completion message."},"conversation_id":{"type":"string","title":"Conversation Id","description":"The ID of the conversation where the message was created."},"role":{"type":"string","title":"Role","description":"The role of the message sender (e.g., 'user', 'assistant')."},"content":{"type":"string","title":"Content","description":"The content of the message."}},"type":"object","required":["message_id","conversation_id","role","content"],"title":"ProjectA3GenerateCompletionResponse","description":"Response model for creating a new message."},"RunWdlDirectlyRequest":{"properties":{"wdl":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Wdl","description":"The WDL steps to execute directly (backend / code-only format). This is equivalent to the ``wdl`` field stored in the Adopt action DB."},"title":{"type":"string","title":"Title","description":"Human-readable label for this execution (used in traces / logs).","default":"direct_wdl_execution"},"required_inputs":{"items":{"type":"string"},"type":"array","title":"Required Inputs","description":"Required workflow input names, same semantics as ActionV2.required_inputs."},"user_message":{"type":"string","title":"User Message","description":"The user's natural-language query / trigger message.","default":""},"trace_id":{"type":"string","title":"Trace Id","description":"Unique identifier for this conversation / execution trace."},"base_url":{"type":"string","title":"Base Url","description":"Base URL for the end-user's tenant API endpoints.","default":""},"application_base_url":{"type":"string","title":"Application Base Url","description":"Base URL for the application (used for post-action redirects).","default":""},"workflow_params":{"additionalProperties":true,"type":"object","title":"Workflow Params","description":"Workflow parameters (e.g. email, user_id) passed into the WDL."},"security_params":{"additionalProperties":true,"type":"object","title":"Security Params","description":"Security / authentication parameters (headers, cookies, tokens)."},"include_execution_trace":{"type":"boolean","title":"Include Execution Trace","description":"When True, the response will include a step-by-step execution trace.","default":false},"profiles_map":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Profiles Map","description":"Map of profiles keyed by api_id or application name. Each value may contain ``base_url``, ``security_headers``, ``app_base_url``. Use the ``'default'`` key as a catch-all fallback profile. Mirrors adopt-profile.json semantics."},"mcp_profiles_map":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Mcp Profiles Map","description":"Map of MCP profiles keyed by integration_id. Each value may contain ``tool_id`` and ``security_headers``. Use the ``'default'`` key as a catch-all fallback."},"inline_actions":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/InlineActionDefinition"},"type":"object"},{"type":"null"}],"title":"Inline Actions","description":"Map of placeholder action IDs to their inline WDL definitions. When present, the executor resolves these IDs from this map instead of looking them up in the platform database. Use the 'inline::' prefix convention for placeholder IDs."}},"type":"object","required":["wdl"],"title":"RunWdlDirectlyRequest","description":"Request model for running a WDL directly without saving it to the platform.\n\nThis enables iterative WDL testing by bypassing the need to save an action to the\nAdopt platform. The WDL steps are passed directly in the request payload and executed\nimmediately using the caller's configuration (org/config).\n\nThe ``wdl`` field must be in the **backend (code-only) WDL format** – i.e. the list\nof operation step dictionaries that would normally be stored in the ``wdl`` DB column\n(no statement / metadata / required_inputs wrapper blocks).\n\nProfile resolution (``profiles_map`` / ``mcp_profiles_map``) works identically to the\nexisting ``/v1/actions/run`` endpoint so you can pass an adopt-profile.json–style map\nor a flat ``profiles_map`` dict directly."},"StepTrace":{"properties":{"operation_id":{"type":"string","title":"Operation Id","description":"ID of the operation","default":""},"operation_type":{"type":"string","title":"Operation Type","description":"Type of the operation","default":""},"operation_input":{"anyOf":[{},{"type":"null"}],"title":"Operation Input","description":"Input of the operation"},"operation_output":{"anyOf":[{},{"type":"null"}],"title":"Operation Output","description":"Output of the operation"},"resolved_operation":{"title":"Resolved Operation","description":"Resolved operation details"},"status":{"$ref":"#/components/schemas/OperationStatusInfo","description":"Status information for the operation"},"tool_calls":{"items":{"$ref":"#/components/schemas/ToolCallTrace"},"type":"array","title":"Tool Calls","description":"Tool call traces for PROMPT_AND_TOOLS_AGENT operations. Empty for other operation types."}},"type":"object","title":"StepTrace"},"SystemMessage":{"properties":{"content":{"anyOf":[{"type":"string"},{"items":{"anyOf":[{"type":"string"},{"additionalProperties":true,"type":"object"}]},"type":"array"}],"title":"Content"},"additional_kwargs":{"additionalProperties":true,"type":"object","title":"Additional Kwargs"},"response_metadata":{"additionalProperties":true,"type":"object","title":"Response Metadata"},"type":{"type":"string","const":"system","title":"Type","default":"system"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"}},"additionalProperties":true,"type":"object","required":["content"],"title":"SystemMessage","description":"Message for priming AI behavior.\n\nThe system message is usually passed in as the first of a sequence\nof input messages.\n\nExample:\n    ```python\n    from langchain_core.messages import HumanMessage, SystemMessage\n\n    messages = [\n        SystemMessage(content=\"You are a helpful assistant! Your name is Bob.\"),\n        HumanMessage(content=\"What is your name?\"),\n    ]\n\n    # Define a chat model and invoke it with the messages\n    print(model.invoke(messages))\n    ```"},"ToolCall":{"properties":{"name":{"type":"string","title":"Name"},"args":{"additionalProperties":true,"type":"object","title":"Args"},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id"},"type":{"type":"string","const":"tool_call","title":"Type"}},"additionalProperties":true,"type":"object","required":["name","args","id"],"title":"ToolCall","description":"Represents an AI's request to call a tool.\n\nExample:\n    ```python\n    {\"name\": \"foo\", \"args\": {\"a\": 1}, \"id\": \"123\"}\n    ```\n\n    This represents a request to call the tool named `'foo'` with arguments\n    `{\"a\": 1}` and an identifier of `'123'`.\n\n!!! note \"Factory function\"\n\n    `tool_call` may also be used as a factory to create a `ToolCall`. Benefits\n    include:\n\n    * Required arguments strictly validated at creation time"},"ToolCallTrace":{"properties":{"tool_name":{"type":"string","title":"Tool Name","description":"Name of the tool (sub-action) called","default":""},"action_id":{"type":"string","title":"Action Id","description":"Action ID of the sub-action","default":""},"tool_input":{"additionalProperties":true,"type":"object","title":"Tool Input","description":"Input parameters passed to the tool"},"tool_output":{"title":"Tool Output","description":"Output returned by the tool (string or dict)"},"status":{"$ref":"#/components/schemas/OperationStatusInfo","description":"Status of the tool call"},"sub_step_traces":{"items":{"$ref":"#/components/schemas/StepTrace"},"type":"array","title":"Sub Step Traces","description":"Step traces from the sub-action's WDL execution"},"execution_log":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Execution Log","description":"Execution log from the sub-action"},"duration_ms":{"type":"integer","title":"Duration Ms","description":"Duration of the tool call in milliseconds","default":0},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if tool call failed"}},"type":"object","title":"ToolCallTrace","description":"Trace for a single tool call within a PROMPT_AND_TOOLS_AGENT step.\n\nCaptures full context of a sub-action execution including:\n- What tool was called and with what input\n- The output returned by the tool\n- Full WDL step traces from the sub-action's internal execution\n- Timing and error information"},"UsageMetadata":{"properties":{"input_tokens":{"type":"integer","title":"Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"total_tokens":{"type":"integer","title":"Total Tokens"},"input_token_details":{"$ref":"#/components/schemas/InputTokenDetails"},"output_token_details":{"$ref":"#/components/schemas/OutputTokenDetails"}},"additionalProperties":true,"type":"object","required":["input_tokens","output_tokens","total_tokens"],"title":"UsageMetadata","description":"Usage metadata for a message, such as token counts.\n\nThis is a standard representation of token usage that is consistent across models.\n\nExample:\n    ```python\n    {\n        \"input_tokens\": 350,\n        \"output_tokens\": 240,\n        \"total_tokens\": 590,\n        \"input_token_details\": {\n            \"audio\": 10,\n            \"cache_creation\": 200,\n            \"cache_read\": 100,\n        },\n        \"output_token_details\": {\n            \"audio\": 10,\n            \"reasoning\": 200,\n        },\n    }\n    ```\n\n!!! warning \"Behavior changed in `langchain-core` 0.3.9\"\n\n    Added `input_token_details` and `output_token_details`.\n\n!!! note \"LangSmith SDK\"\n\n    The LangSmith SDK also has a `UsageMetadata` class. While the two share fields,\n    LangSmith's `UsageMetadata` has additional fields to capture cost information\n    used by the LangSmith platform."},"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"},"WdlValidateRequest":{"properties":{"wdl":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Wdl","description":"The WDL workflow blocks to validate"}},"type":"object","required":["wdl"],"title":"WdlValidateRequest","description":"Request body for POST /v1/wdl/validate."},"WdlValidateResponse":{"properties":{"status":{"type":"string","title":"Status","description":"SUCCESS or FAILURE"},"errors":{"items":{"$ref":"#/components/schemas/WdlValidationError"},"type":"array","title":"Errors"},"warnings":{"items":{"$ref":"#/components/schemas/WdlValidationError"},"type":"array","title":"Warnings"},"error_count":{"type":"integer","title":"Error Count","default":0},"warning_count":{"type":"integer","title":"Warning Count","default":0}},"type":"object","required":["status"],"title":"WdlValidateResponse","description":"Response body for POST /v1/wdl/validate."},"WdlValidationError":{"properties":{"error_code":{"type":"string","title":"Error Code","description":"Error code, e.g. MISSING_REQUIRED_FIELDS"},"error_msg":{"type":"string","title":"Error Msg","description":"Human-readable description"},"block_id":{"type":"string","title":"Block Id","description":"Which block caused the error","default":""},"suggestion":{"type":"string","title":"Suggestion","description":"Actionable fix for AI agent","default":""}},"type":"object","required":["error_code","error_msg"],"title":"WdlValidationError","description":"A single validation error or warning."},"WiddleExecutionTrace":{"properties":{"execution_log":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Execution Log","description":"Execution log for the Widdle","default":[]},"step_traces":{"items":{"$ref":"#/components/schemas/StepTrace"},"type":"array","title":"Step Traces","description":"List of step traces for the Widdle execution","default":[]},"exception_traceback":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Exception Traceback","description":"Exception traceback for the Widdle"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message for the Widdle"},"workflow_arguments":{"additionalProperties":true,"type":"object","title":"Workflow Arguments","description":"Workflow arguments passed to the Widdle execution"}},"type":"object","title":"WiddleExecutionTrace","description":"Widdle execution trace."}},"securitySchemes":{"JWTBearer":{"type":"http","scheme":"bearer"}}}}