|
10 | 10 | from typing import Any |
11 | 11 |
|
12 | 12 | REQUEST_BODY_SCHEMAS: dict[str, Any] = { |
13 | | - "CREATEAUTHPROVIDER": '{"required": ["id"], "type": "object", "properties": {"description": {"maxLength": 1000, "type": "string"}, "external_id": {"maxLength": 50, "type": "string", "description": "The unique external ID for the auth provider"}, "id": {"maxLength": 100, "type": "string"}, "oauth2": {"required": ["client_id"], "type": "object", "properties": {"authorize_request": {"required": ["endpoint"], "type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}}}, "client_id": {"maxLength": 1000, "type": "string"}, "client_secret": {"maxLength": 1000, "type": "string"}, "pkce": {"type": "object", "properties": {"code_challenge_method": {"type": "string"}, "enabled": {"type": "boolean"}}}, "refresh_request": {"required": ["endpoint"], "type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}}}, "scope_delimiter": {"type": "string", "enum": [",", " "]}, "token_introspection_request": {"required": ["endpoint", "triggers"], "type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}, "triggers": {"type": "object", "properties": {"on_token_grant": {"type": "boolean"}, "on_token_refresh": {"type": "boolean"}}}}}, "token_request": {"required": ["endpoint"], "type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}}}, "user_info_request": {"required": ["endpoint", "triggers"], "type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}, "triggers": {"type": "object", "properties": {"on_token_grant": {"type": "boolean"}, "on_token_refresh": {"type": "boolean"}}}}}}}, "provider_id": {"type": "string"}, "status": {"type": "string"}, "type": {"type": "string"}}}', # noqa: E501 |
14 | | - "UPDATEAUTHPROVIDER": '{"type": "object", "properties": {"description": {"maxLength": 1000, "type": "string"}, "id": {"maxLength": 100, "type": "string"}, "oauth2": {"type": "object", "properties": {"authorize_request": {"type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}}}, "client_id": {"maxLength": 1000, "type": "string"}, "client_secret": {"maxLength": 1000, "type": "string"}, "pkce": {"type": "object", "properties": {"code_challenge_method": {"type": "string"}, "enabled": {"type": "boolean"}}}, "refresh_request": {"type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}}}, "scope_delimiter": {"type": "string", "enum": [",", " "]}, "token_request": {"type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}}}, "user_info_request": {"type": "object", "properties": {"auth_method": {"type": "string"}, "endpoint": {"maxLength": 1000, "type": "string"}, "method": {"type": "string"}, "params": {"type": "object", "additionalProperties": {"type": "string"}}, "request_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_content_type": {"type": "string", "enum": ["application/x-www-form-urlencoded", "application/json"]}, "response_map": {"type": "object", "additionalProperties": {"type": "string"}}, "triggers": {"type": "object", "properties": {"on_token_grant": {"type": "boolean"}, "on_token_refresh": {"type": "boolean"}}}}}}}, "provider_id": {"type": "string"}, "status": {"type": "string"}, "type": {"type": "string"}}}', # noqa: E501 |
15 | | - "OPENAICHATINTERACTION": '{"type": "object", "properties": {"frequency_penalty": {"type": "number"}, "logit_bias": {"type": "object", "additionalProperties": {"type": "integer"}, "description": "LogitBias is must be a token id string (specified by their token ID in the tokenizer), not a word string.\nincorrect: `"logit_bias":{"You": 6}`, correct: `"logit_bias":{"1639": 6}`\nrefs: https://platform.openai.com/docs/api-reference/chat/create#chat/create-logit_bias"}, "logprobs": {"type": "boolean", "description": "LogProbs indicates whether to return log probabilities of the output tokens or not.\nIf true, returns the log probabilities of each output token returned in the content of message.\nThis option is currently not available on the gpt-4-vision-preview model."}, "max_tokens": {"type": "integer"}, "messages": {"type": "array", "items": {"required": ["content", "role"], "type": "object", "properties": {"content": {"type": "string", "description": "The content of the message."}, "name": {"type": "string", "description": "tool Name"}, "role": {"type": "string", "description": "The role of the author of this message. One of system, user, tool, or assistant."}, "tool_call_id": {"type": "string", "description": "tool_call_id"}, "tool_calls": {"type": "array", "description": "tool calls if any", "items": {"type": "object", "properties": {"function": {"type": "object", "properties": {"arguments": {"type": "string"}, "name": {"type": "string"}}}, "id": {"type": "string"}, "type": {"type": "string", "enum": ["function"], "x-enum-varnames": ["ToolTypeFunction"]}}}}}}}, "model": {"type": "string"}, "n": {"type": "integer"}, "parallel_tool_calls": {"type": "boolean", "description": "Disable the default behavior of parallel tool calls by setting it: false."}, "presence_penalty": {"type": "number"}, "response_format": {"type": "object", "properties": {"type": {"type": "string", "enum": ["json_object", "text"], "x-enum-varnames": ["ResponseFormatJSON", "ResponseFormatText"]}}}, "seed": {"type": "integer"}, "stop": {"type": "array", "items": {"type": "string"}}, "stream": {"type": "boolean"}, "stream_options": {"type": "object", "description": "Options for streaming response. Only set this when you set stream: true.", "allOf": [{"type": "object", "properties": {"include_usage": {"type": "boolean", "description": "If set, an additional chunk will be streamed before the data: [DONE] message.\nThe usage field on this chunk shows the token usage statistics for the entire request,\nand the choices field will always be an empty array.\nAll other chunks will also include a usage field, but with a null value."}}}]}, "temperature": {"type": "number"}, "tool_choice": {"type": "object", "description": "This can be either a string or an ToolChoice object."}, "tools": {"type": "object"}, "top_logprobs": {"type": "integer", "description": "TopLogProbs is an integer between 0 and 5 specifying the number of most likely tokens to return at each\ntoken position, each with an associated log probability.\nlogprobs must be set to true if this parameter is used."}, "top_p": {"type": "number"}, "user": {"type": "string"}}}', # noqa: E501 |
16 | 13 | "EXECUTETOOL": '{"required": ["tool_name"], "type": "object", "properties": {"include_error_stacktrace": {"type": "boolean", "description": "Whether to include the error stacktrace in the response. If not provided, the error stacktrace is not included."}, "input": {"type": "object", "description": "JSON input to the tool, if any", "allOf": [{"type": "object", "additionalProperties": true}]}, "run_at": {"type": "string", "description": "The time at which the tool should be run (optional). If not provided, the tool is run immediately. Format ISO 8601: YYYY-MM-DDTHH:MM:SS"}, "tool_name": {"type": "string"}, "tool_version": {"type": "string", "description": "The tool version to use (optional). If not provided, any version is used"}, "user_id": {"type": "string"}}}', # noqa: E501 |
17 | 14 | } |
0 commit comments