From 22558e07e0fc3b3fdc78c93eab9aaae7aa1fd24f Mon Sep 17 00:00:00 2001 From: Shuchang Zheng Date: Wed, 2 Apr 2025 11:07:14 -0400 Subject: [PATCH] update auto generated code (#2068) --- fern/openapi/skyvern_openapi.json | 6494 ++++++++++++++++- pyproject.toml | 2 +- skyvern/client/__init__.py | 420 ++ skyvern/client/agent/client.py | 802 +- .../agent/types/agent_get_run_response.py | 7 + skyvern/client/browser_session/client.py | 33 +- skyvern/client/core/client_wrapper.py | 2 +- .../errors/unprocessable_entity_error.py | 4 +- skyvern/client/types/__init__.py | 452 ++ skyvern/client/types/action_block.py | 43 + .../client/types/action_block_data_schema.py | 7 + .../types/action_block_parameters_item.py | 207 + skyvern/client/types/aws_secret_parameter.py | 27 + .../bitwarden_credit_card_data_parameter.py | 31 + .../bitwarden_login_credential_parameter.py | 32 + ...twarden_sensitive_information_parameter.py | 32 + skyvern/client/types/code_block.py | 26 + .../types/code_block_parameters_item.py | 207 + skyvern/client/types/context_parameter.py | 30 + skyvern/client/types/credential_parameter.py | 27 + skyvern/client/types/download_to_s3block.py | 23 + skyvern/client/types/extraction_block.py | 43 + .../types/extraction_block_data_schema.py | 7 + .../types/extraction_block_parameters_item.py | 207 + skyvern/client/types/file_download_block.py | 43 + .../types/file_download_block_data_schema.py | 7 + .../file_download_block_parameters_item.py | 207 + skyvern/client/types/file_info.py | 36 + skyvern/client/types/file_parser_block.py | 25 + skyvern/client/types/file_storage_type.py | 5 + skyvern/client/types/file_type.py | 5 + skyvern/client/types/file_upload_block.py | 31 + skyvern/client/types/for_loop_block.py | 35 + .../types/for_loop_block_loop_blocks_item.py | 549 ++ .../client/types/for_loop_block_loop_over.py | 207 + skyvern/client/types/login_block.py | 43 + .../client/types/login_block_data_schema.py | 7 + .../types/login_block_parameters_item.py | 207 + skyvern/client/types/navigation_block.py | 43 + .../types/navigation_block_data_schema.py | 7 + .../types/navigation_block_parameters_item.py | 207 + skyvern/client/types/output_parameter.py | 26 + skyvern/client/types/pdf_parser_block.py | 24 + skyvern/client/types/send_email_block.py | 32 + skyvern/client/types/source.py | 206 + skyvern/client/types/task_block.py | 43 + .../client/types/task_block_data_schema.py | 7 + .../types/task_block_parameters_item.py | 207 + skyvern/client/types/task_run_response.py | 11 + skyvern/client/types/task_v2block.py | 28 + skyvern/client/types/text_prompt_block.py | 28 + .../text_prompt_block_parameters_item.py | 207 + skyvern/client/types/upload_to_s3block.py | 23 + skyvern/client/types/url_block.py | 43 + skyvern/client/types/url_block_data_schema.py | 7 + .../client/types/url_block_parameters_item.py | 207 + skyvern/client/types/validation_block.py | 43 + .../types/validation_block_data_schema.py | 7 + .../types/validation_block_parameters_item.py | 207 + skyvern/client/types/value.py | 7 + skyvern/client/types/wait_block.py | 26 + .../types/wait_block_parameters_item.py | 207 + skyvern/client/types/workflow.py | 41 + skyvern/client/types/workflow_definition.py | 24 + .../types/workflow_definition_blocks_item.py | 550 ++ .../workflow_definition_parameters_item.py | 207 + skyvern/client/types/workflow_parameter.py | 30 + .../types/workflow_parameter_default_value.py | 7 + .../client/types/workflow_parameter_type.py | 7 + skyvern/client/types/workflow_run_response.py | 11 + skyvern/client/types/workflow_status.py | 5 + 71 files changed, 13252 insertions(+), 55 deletions(-) create mode 100644 skyvern/client/types/action_block.py create mode 100644 skyvern/client/types/action_block_data_schema.py create mode 100644 skyvern/client/types/action_block_parameters_item.py create mode 100644 skyvern/client/types/aws_secret_parameter.py create mode 100644 skyvern/client/types/bitwarden_credit_card_data_parameter.py create mode 100644 skyvern/client/types/bitwarden_login_credential_parameter.py create mode 100644 skyvern/client/types/bitwarden_sensitive_information_parameter.py create mode 100644 skyvern/client/types/code_block.py create mode 100644 skyvern/client/types/code_block_parameters_item.py create mode 100644 skyvern/client/types/context_parameter.py create mode 100644 skyvern/client/types/credential_parameter.py create mode 100644 skyvern/client/types/download_to_s3block.py create mode 100644 skyvern/client/types/extraction_block.py create mode 100644 skyvern/client/types/extraction_block_data_schema.py create mode 100644 skyvern/client/types/extraction_block_parameters_item.py create mode 100644 skyvern/client/types/file_download_block.py create mode 100644 skyvern/client/types/file_download_block_data_schema.py create mode 100644 skyvern/client/types/file_download_block_parameters_item.py create mode 100644 skyvern/client/types/file_info.py create mode 100644 skyvern/client/types/file_parser_block.py create mode 100644 skyvern/client/types/file_storage_type.py create mode 100644 skyvern/client/types/file_type.py create mode 100644 skyvern/client/types/file_upload_block.py create mode 100644 skyvern/client/types/for_loop_block.py create mode 100644 skyvern/client/types/for_loop_block_loop_blocks_item.py create mode 100644 skyvern/client/types/for_loop_block_loop_over.py create mode 100644 skyvern/client/types/login_block.py create mode 100644 skyvern/client/types/login_block_data_schema.py create mode 100644 skyvern/client/types/login_block_parameters_item.py create mode 100644 skyvern/client/types/navigation_block.py create mode 100644 skyvern/client/types/navigation_block_data_schema.py create mode 100644 skyvern/client/types/navigation_block_parameters_item.py create mode 100644 skyvern/client/types/output_parameter.py create mode 100644 skyvern/client/types/pdf_parser_block.py create mode 100644 skyvern/client/types/send_email_block.py create mode 100644 skyvern/client/types/source.py create mode 100644 skyvern/client/types/task_block.py create mode 100644 skyvern/client/types/task_block_data_schema.py create mode 100644 skyvern/client/types/task_block_parameters_item.py create mode 100644 skyvern/client/types/task_v2block.py create mode 100644 skyvern/client/types/text_prompt_block.py create mode 100644 skyvern/client/types/text_prompt_block_parameters_item.py create mode 100644 skyvern/client/types/upload_to_s3block.py create mode 100644 skyvern/client/types/url_block.py create mode 100644 skyvern/client/types/url_block_data_schema.py create mode 100644 skyvern/client/types/url_block_parameters_item.py create mode 100644 skyvern/client/types/validation_block.py create mode 100644 skyvern/client/types/validation_block_data_schema.py create mode 100644 skyvern/client/types/validation_block_parameters_item.py create mode 100644 skyvern/client/types/value.py create mode 100644 skyvern/client/types/wait_block.py create mode 100644 skyvern/client/types/wait_block_parameters_item.py create mode 100644 skyvern/client/types/workflow.py create mode 100644 skyvern/client/types/workflow_definition.py create mode 100644 skyvern/client/types/workflow_definition_blocks_item.py create mode 100644 skyvern/client/types/workflow_definition_parameters_item.py create mode 100644 skyvern/client/types/workflow_parameter.py create mode 100644 skyvern/client/types/workflow_parameter_default_value.py create mode 100644 skyvern/client/types/workflow_parameter_type.py create mode 100644 skyvern/client/types/workflow_status.py diff --git a/fern/openapi/skyvern_openapi.json b/fern/openapi/skyvern_openapi.json index 71f71309..a9c8ea6b 100644 --- a/fern/openapi/skyvern_openapi.json +++ b/fern/openapi/skyvern_openapi.json @@ -9,9 +9,10 @@ "/v1/runs/{run_id}": { "get": { "tags": [ - "agent" + "Agent" ], - "summary": "Get Run", + "summary": "Get a task or a workflow run by id", + "description": "Get a task or a workflow run by id", "operationId": "get_run_v1_runs__run_id__get", "parameters": [ { @@ -20,7 +21,166 @@ "required": true, "schema": { "type": "string", + "description": "The id of the task run or the workflow run.", "title": "Run Id" + }, + "description": "The id of the task run or the workflow run." + }, + { + "name": "x-api-key", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "X-Api-Key" + } + }, + { + "name": "authorization", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Authorization" + } + } + ], + "responses": { + "200": { + "description": "Successfully got run", + "content": { + "application/json": { + "schema": { + "oneOf": [ + { + "$ref": "#/components/schemas/TaskRunResponse" + }, + { + "$ref": "#/components/schemas/WorkflowRunResponse" + } + ], + "discriminator": { + "propertyName": "run_type", + "mapping": { + "task_v1": "#/components/schemas/TaskRunResponse", + "task_v2": "#/components/schemas/TaskRunResponse", + "workflow_run": "#/components/schemas/WorkflowRunResponse" + } + }, + "title": "Response Get Run V1 Runs Run Id Get" + } + } + } + }, + "404": { + "description": "Run not found" + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + }, + "x-fern-sdk-group-name": "agent", + "x-fern-sdk-method-name": "get_run" + } + }, + "/v1/workflows": { + "post": { + "tags": [ + "Agent" + ], + "summary": "Create a new workflow", + "description": "Create a new workflow", + "operationId": "create_workflow_v1_workflows_post", + "parameters": [ + { + "name": "x-api-key", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "X-Api-Key" + } + }, + { + "name": "authorization", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Authorization" + } + } + ], + "responses": { + "200": { + "description": "Successfully created workflow", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Workflow" + } + } + } + }, + "422": { + "description": "Invalid workflow definition" + } + }, + "x-fern-sdk-group-name": "agent", + "x-fern-sdk-method-name": "create_workflow" + } + }, + "/v1/workflows/{workflow_id}": { + "post": { + "tags": [ + "Agent" + ], + "summary": "Update a workflow definition", + "description": "Update a workflow definition", + "operationId": "update_workflow_v1_workflows__workflow_id__post", + "parameters": [ + { + "name": "workflow_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "title": "Workflow Id" } }, { @@ -58,27 +218,2348 @@ ], "responses": { "200": { - "description": "Successful Response", + "description": "Successfully updated workflow", "content": { "application/json": { "schema": { - "oneOf": [ - { - "$ref": "#/components/schemas/TaskRunResponse" + "$ref": "#/components/schemas/Workflow" + } + } + } + }, + "422": { + "description": "Invalid workflow definition" + } + }, + "requestBody": { + "content": { + "application/x-yaml": { + "schema": { + "$defs": { + "AWSSecretParameterYAML": { + "properties": { + "parameter_type": { + "const": "aws_secret", + "default": "aws_secret", + "title": "Parameter Type", + "type": "string" + }, + "key": { + "title": "Key", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "aws_key": { + "title": "Aws Key", + "type": "string" + } }, - { - "$ref": "#/components/schemas/WorkflowRunResponse" - } - ], - "discriminator": { - "propertyName": "run_type", - "mapping": { - "task_v1": "#/components/schemas/TaskRunResponse", - "task_v2": "#/components/schemas/TaskRunResponse", - "workflow_run": "#/components/schemas/WorkflowRunResponse" - } + "required": [ + "key", + "aws_key" + ], + "title": "AWSSecretParameterYAML", + "type": "object" }, - "title": "Response Get Run V1 Runs Run Id Get" + "ActionBlockYAML": { + "properties": { + "block_type": { + "const": "action", + "default": "action", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "default": "", + "title": "Title", + "type": "string" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "default": 0, + "title": "Max Retries", + "type": "integer" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + }, + "complete_on_download": { + "default": false, + "title": "Complete On Download", + "type": "boolean" + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "default": false, + "title": "Cache Actions", + "type": "boolean" + } + }, + "required": [ + "label" + ], + "title": "ActionBlockYAML", + "type": "object" + }, + "BitwardenCreditCardDataParameterYAML": { + "properties": { + "parameter_type": { + "const": "bitwarden_credit_card_data", + "default": "bitwarden_credit_card_data", + "title": "Parameter Type", + "type": "string" + }, + "key": { + "title": "Key", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "bitwarden_client_id_aws_secret_key": { + "title": "Bitwarden Client Id Aws Secret Key", + "type": "string" + }, + "bitwarden_client_secret_aws_secret_key": { + "title": "Bitwarden Client Secret Aws Secret Key", + "type": "string" + }, + "bitwarden_master_password_aws_secret_key": { + "title": "Bitwarden Master Password Aws Secret Key", + "type": "string" + }, + "bitwarden_collection_id": { + "title": "Bitwarden Collection Id", + "type": "string" + }, + "bitwarden_item_id": { + "title": "Bitwarden Item Id", + "type": "string" + } + }, + "required": [ + "key", + "bitwarden_client_id_aws_secret_key", + "bitwarden_client_secret_aws_secret_key", + "bitwarden_master_password_aws_secret_key", + "bitwarden_collection_id", + "bitwarden_item_id" + ], + "title": "BitwardenCreditCardDataParameterYAML", + "type": "object" + }, + "BitwardenLoginCredentialParameterYAML": { + "properties": { + "parameter_type": { + "const": "bitwarden_login_credential", + "default": "bitwarden_login_credential", + "title": "Parameter Type", + "type": "string" + }, + "key": { + "title": "Key", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "bitwarden_client_id_aws_secret_key": { + "title": "Bitwarden Client Id Aws Secret Key", + "type": "string" + }, + "bitwarden_client_secret_aws_secret_key": { + "title": "Bitwarden Client Secret Aws Secret Key", + "type": "string" + }, + "bitwarden_master_password_aws_secret_key": { + "title": "Bitwarden Master Password Aws Secret Key", + "type": "string" + }, + "url_parameter_key": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url Parameter Key" + }, + "bitwarden_collection_id": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Bitwarden Collection Id" + }, + "bitwarden_item_id": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Bitwarden Item Id" + } + }, + "required": [ + "key", + "bitwarden_client_id_aws_secret_key", + "bitwarden_client_secret_aws_secret_key", + "bitwarden_master_password_aws_secret_key" + ], + "title": "BitwardenLoginCredentialParameterYAML", + "type": "object" + }, + "BitwardenSensitiveInformationParameterYAML": { + "properties": { + "parameter_type": { + "const": "bitwarden_sensitive_information", + "default": "bitwarden_sensitive_information", + "title": "Parameter Type", + "type": "string" + }, + "key": { + "title": "Key", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "bitwarden_client_id_aws_secret_key": { + "title": "Bitwarden Client Id Aws Secret Key", + "type": "string" + }, + "bitwarden_client_secret_aws_secret_key": { + "title": "Bitwarden Client Secret Aws Secret Key", + "type": "string" + }, + "bitwarden_master_password_aws_secret_key": { + "title": "Bitwarden Master Password Aws Secret Key", + "type": "string" + }, + "bitwarden_collection_id": { + "title": "Bitwarden Collection Id", + "type": "string" + }, + "bitwarden_identity_key": { + "title": "Bitwarden Identity Key", + "type": "string" + }, + "bitwarden_identity_fields": { + "items": { + "type": "string" + }, + "title": "Bitwarden Identity Fields", + "type": "array" + } + }, + "required": [ + "key", + "bitwarden_client_id_aws_secret_key", + "bitwarden_client_secret_aws_secret_key", + "bitwarden_master_password_aws_secret_key", + "bitwarden_collection_id", + "bitwarden_identity_key", + "bitwarden_identity_fields" + ], + "title": "BitwardenSensitiveInformationParameterYAML", + "type": "object" + }, + "CodeBlockYAML": { + "properties": { + "block_type": { + "const": "code", + "default": "code", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "code": { + "title": "Code", + "type": "string" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + } + }, + "required": [ + "label", + "code" + ], + "title": "CodeBlockYAML", + "type": "object" + }, + "ContextParameterYAML": { + "properties": { + "parameter_type": { + "const": "context", + "default": "context", + "title": "Parameter Type", + "type": "string" + }, + "key": { + "title": "Key", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "source_parameter_key": { + "title": "Source Parameter Key", + "type": "string" + } + }, + "required": [ + "key", + "source_parameter_key" + ], + "title": "ContextParameterYAML", + "type": "object" + }, + "CredentialParameterYAML": { + "properties": { + "parameter_type": { + "const": "credential", + "default": "credential", + "title": "Parameter Type", + "type": "string" + }, + "key": { + "title": "Key", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "credential_id": { + "title": "Credential Id", + "type": "string" + } + }, + "required": [ + "key", + "credential_id" + ], + "title": "CredentialParameterYAML", + "type": "object" + }, + "DownloadToS3BlockYAML": { + "properties": { + "block_type": { + "const": "download_to_s3", + "default": "download_to_s3", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "url": { + "title": "Url", + "type": "string" + } + }, + "required": [ + "label", + "url" + ], + "title": "DownloadToS3BlockYAML", + "type": "object" + }, + "ExtractionBlockYAML": { + "properties": { + "block_type": { + "const": "extraction", + "default": "extraction", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "data_extraction_goal": { + "title": "Data Extraction Goal", + "type": "string" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "default": "", + "title": "Title", + "type": "string" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "max_retries": { + "default": 0, + "title": "Max Retries", + "type": "integer" + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + }, + "cache_actions": { + "default": false, + "title": "Cache Actions", + "type": "boolean" + } + }, + "required": [ + "label", + "data_extraction_goal" + ], + "title": "ExtractionBlockYAML", + "type": "object" + }, + "FileDownloadBlockYAML": { + "properties": { + "block_type": { + "const": "file_download", + "default": "file_download", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "navigation_goal": { + "title": "Navigation Goal", + "type": "string" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "default": "", + "title": "Title", + "type": "string" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "default": 0, + "title": "Max Retries", + "type": "integer" + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "default": false, + "title": "Cache Actions", + "type": "boolean" + } + }, + "required": [ + "label", + "navigation_goal" + ], + "title": "FileDownloadBlockYAML", + "type": "object" + }, + "FileParserBlockYAML": { + "properties": { + "block_type": { + "const": "file_url_parser", + "default": "file_url_parser", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "file_url": { + "title": "File Url", + "type": "string" + }, + "file_type": { + "$ref": "#/$defs/FileType" + } + }, + "required": [ + "label", + "file_url", + "file_type" + ], + "title": "FileParserBlockYAML", + "type": "object" + }, + "FileStorageType": { + "enum": [ + "s3" + ], + "title": "FileStorageType", + "type": "string" + }, + "FileType": { + "enum": [ + "csv" + ], + "title": "FileType", + "type": "string" + }, + "FileUploadBlockYAML": { + "properties": { + "block_type": { + "const": "file_upload", + "default": "file_upload", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "storage_type": { + "$ref": "#/$defs/FileStorageType", + "default": "s3" + }, + "s3_bucket": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "S3 Bucket" + }, + "aws_access_key_id": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Aws Access Key Id" + }, + "aws_secret_access_key": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Aws Secret Access Key" + }, + "region_name": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Region Name" + }, + "path": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Path" + } + }, + "required": [ + "label" + ], + "title": "FileUploadBlockYAML", + "type": "object" + }, + "ForLoopBlockYAML": { + "properties": { + "block_type": { + "const": "for_loop", + "default": "for_loop", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "loop_blocks": { + "items": { + "anyOf": [ + { + "$ref": "#/$defs/TaskBlockYAML" + }, + { + "$ref": "#/$defs/ForLoopBlockYAML" + }, + { + "$ref": "#/$defs/CodeBlockYAML" + }, + { + "$ref": "#/$defs/TextPromptBlockYAML" + }, + { + "$ref": "#/$defs/DownloadToS3BlockYAML" + }, + { + "$ref": "#/$defs/UploadToS3BlockYAML" + }, + { + "$ref": "#/$defs/FileUploadBlockYAML" + }, + { + "$ref": "#/$defs/SendEmailBlockYAML" + }, + { + "$ref": "#/$defs/FileParserBlockYAML" + }, + { + "$ref": "#/$defs/ValidationBlockYAML" + }, + { + "$ref": "#/$defs/ActionBlockYAML" + }, + { + "$ref": "#/$defs/NavigationBlockYAML" + }, + { + "$ref": "#/$defs/ExtractionBlockYAML" + }, + { + "$ref": "#/$defs/LoginBlockYAML" + }, + { + "$ref": "#/$defs/WaitBlockYAML" + }, + { + "$ref": "#/$defs/FileDownloadBlockYAML" + }, + { + "$ref": "#/$defs/UrlBlockYAML" + }, + { + "$ref": "#/$defs/PDFParserBlockYAML" + }, + { + "$ref": "#/$defs/TaskV2BlockYAML" + } + ] + }, + "title": "Loop Blocks", + "type": "array" + }, + "loop_over_parameter_key": { + "default": "", + "title": "Loop Over Parameter Key", + "type": "string" + }, + "loop_variable_reference": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Loop Variable Reference" + }, + "complete_if_empty": { + "default": false, + "title": "Complete If Empty", + "type": "boolean" + } + }, + "required": [ + "label", + "loop_blocks" + ], + "title": "ForLoopBlockYAML", + "type": "object" + }, + "LoginBlockYAML": { + "properties": { + "block_type": { + "const": "login", + "default": "login", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "default": "", + "title": "Title", + "type": "string" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "default": 0, + "title": "Max Retries", + "type": "integer" + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "default": false, + "title": "Cache Actions", + "type": "boolean" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "complete_verification": { + "default": true, + "title": "Complete Verification", + "type": "boolean" + } + }, + "required": [ + "label" + ], + "title": "LoginBlockYAML", + "type": "object" + }, + "NavigationBlockYAML": { + "properties": { + "block_type": { + "const": "navigation", + "default": "navigation", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "navigation_goal": { + "title": "Navigation Goal", + "type": "string" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "default": "", + "title": "Title", + "type": "string" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "default": 0, + "title": "Max Retries", + "type": "integer" + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + }, + "complete_on_download": { + "default": false, + "title": "Complete On Download", + "type": "boolean" + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "default": false, + "title": "Cache Actions", + "type": "boolean" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "complete_verification": { + "default": true, + "title": "Complete Verification", + "type": "boolean" + } + }, + "required": [ + "label", + "navigation_goal" + ], + "title": "NavigationBlockYAML", + "type": "object" + }, + "OutputParameterYAML": { + "properties": { + "parameter_type": { + "const": "output", + "default": "output", + "title": "Parameter Type", + "type": "string" + }, + "key": { + "title": "Key", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + } + }, + "required": [ + "key" + ], + "title": "OutputParameterYAML", + "type": "object" + }, + "PDFParserBlockYAML": { + "properties": { + "block_type": { + "const": "pdf_parser", + "default": "pdf_parser", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "file_url": { + "title": "File Url", + "type": "string" + }, + "json_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Json Schema" + } + }, + "required": [ + "label", + "file_url" + ], + "title": "PDFParserBlockYAML", + "type": "object" + }, + "ProxyLocation": { + "enum": [ + "RESIDENTIAL", + "US-CA", + "US-NY", + "US-TX", + "US-FL", + "US-WA", + "RESIDENTIAL_ES", + "RESIDENTIAL_IE", + "RESIDENTIAL_GB", + "RESIDENTIAL_IN", + "RESIDENTIAL_JP", + "RESIDENTIAL_FR", + "RESIDENTIAL_DE", + "RESIDENTIAL_NZ", + "RESIDENTIAL_ZA", + "RESIDENTIAL_AR", + "RESIDENTIAL_ISP", + "NONE" + ], + "title": "ProxyLocation", + "type": "string" + }, + "SendEmailBlockYAML": { + "properties": { + "block_type": { + "const": "send_email", + "default": "send_email", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "smtp_host_secret_parameter_key": { + "title": "Smtp Host Secret Parameter Key", + "type": "string" + }, + "smtp_port_secret_parameter_key": { + "title": "Smtp Port Secret Parameter Key", + "type": "string" + }, + "smtp_username_secret_parameter_key": { + "title": "Smtp Username Secret Parameter Key", + "type": "string" + }, + "smtp_password_secret_parameter_key": { + "title": "Smtp Password Secret Parameter Key", + "type": "string" + }, + "sender": { + "title": "Sender", + "type": "string" + }, + "recipients": { + "items": { + "type": "string" + }, + "title": "Recipients", + "type": "array" + }, + "subject": { + "title": "Subject", + "type": "string" + }, + "body": { + "title": "Body", + "type": "string" + }, + "file_attachments": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "File Attachments" + } + }, + "required": [ + "label", + "smtp_host_secret_parameter_key", + "smtp_port_secret_parameter_key", + "smtp_username_secret_parameter_key", + "smtp_password_secret_parameter_key", + "sender", + "recipients", + "subject", + "body" + ], + "title": "SendEmailBlockYAML", + "type": "object" + }, + "TaskBlockYAML": { + "properties": { + "block_type": { + "const": "task", + "default": "task", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "default": "", + "title": "Title", + "type": "string" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "default": 0, + "title": "Max Retries", + "type": "integer" + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + }, + "complete_on_download": { + "default": false, + "title": "Complete On Download", + "type": "boolean" + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "default": false, + "title": "Cache Actions", + "type": "boolean" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "complete_verification": { + "default": true, + "title": "Complete Verification", + "type": "boolean" + } + }, + "required": [ + "label" + ], + "title": "TaskBlockYAML", + "type": "object" + }, + "TaskV2BlockYAML": { + "properties": { + "block_type": { + "const": "task_v2", + "default": "task_v2", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "prompt": { + "title": "Prompt", + "type": "string" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "max_iterations": { + "default": 10, + "title": "Max Iterations", + "type": "integer" + }, + "max_steps": { + "default": 25, + "title": "Max Steps", + "type": "integer" + } + }, + "required": [ + "label", + "prompt" + ], + "title": "TaskV2BlockYAML", + "type": "object" + }, + "TextPromptBlockYAML": { + "properties": { + "block_type": { + "const": "text_prompt", + "default": "text_prompt", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "llm_key": { + "default": "OPENAI_GPT4O_MINI", + "title": "Llm Key", + "type": "string" + }, + "prompt": { + "title": "Prompt", + "type": "string" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + }, + "json_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Json Schema" + } + }, + "required": [ + "label", + "prompt" + ], + "title": "TextPromptBlockYAML", + "type": "object" + }, + "UploadToS3BlockYAML": { + "properties": { + "block_type": { + "const": "upload_to_s3", + "default": "upload_to_s3", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "path": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Path" + } + }, + "required": [ + "label" + ], + "title": "UploadToS3BlockYAML", + "type": "object" + }, + "UrlBlockYAML": { + "properties": { + "block_type": { + "const": "goto_url", + "default": "goto_url", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "url": { + "title": "Url", + "type": "string" + } + }, + "required": [ + "label", + "url" + ], + "title": "UrlBlockYAML", + "type": "object" + }, + "ValidationBlockYAML": { + "properties": { + "block_type": { + "const": "validation", + "default": "validation", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "parameter_keys": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Parameter Keys" + } + }, + "required": [ + "label" + ], + "title": "ValidationBlockYAML", + "type": "object" + }, + "WaitBlockYAML": { + "properties": { + "block_type": { + "const": "wait", + "default": "wait", + "title": "Block Type", + "type": "string" + }, + "label": { + "title": "Label", + "type": "string" + }, + "continue_on_failure": { + "default": false, + "title": "Continue On Failure", + "type": "boolean" + }, + "wait_sec": { + "default": 0, + "title": "Wait Sec", + "type": "integer" + } + }, + "required": [ + "label" + ], + "title": "WaitBlockYAML", + "type": "object" + }, + "WorkflowDefinitionYAML": { + "properties": { + "parameters": { + "items": { + "discriminator": { + "mapping": { + "aws_secret": "#/$defs/AWSSecretParameterYAML", + "bitwarden_credit_card_data": "#/$defs/BitwardenCreditCardDataParameterYAML", + "bitwarden_login_credential": "#/$defs/BitwardenLoginCredentialParameterYAML", + "bitwarden_sensitive_information": "#/$defs/BitwardenSensitiveInformationParameterYAML", + "context": "#/$defs/ContextParameterYAML", + "credential": "#/$defs/CredentialParameterYAML", + "output": "#/$defs/OutputParameterYAML", + "workflow": "#/$defs/WorkflowParameterYAML" + }, + "propertyName": "parameter_type" + }, + "oneOf": [ + { + "$ref": "#/$defs/AWSSecretParameterYAML" + }, + { + "$ref": "#/$defs/BitwardenLoginCredentialParameterYAML" + }, + { + "$ref": "#/$defs/BitwardenSensitiveInformationParameterYAML" + }, + { + "$ref": "#/$defs/BitwardenCreditCardDataParameterYAML" + }, + { + "$ref": "#/$defs/WorkflowParameterYAML" + }, + { + "$ref": "#/$defs/ContextParameterYAML" + }, + { + "$ref": "#/$defs/OutputParameterYAML" + }, + { + "$ref": "#/$defs/CredentialParameterYAML" + } + ] + }, + "title": "Parameters", + "type": "array" + }, + "blocks": { + "items": { + "discriminator": { + "mapping": { + "action": "#/$defs/ActionBlockYAML", + "code": "#/$defs/CodeBlockYAML", + "download_to_s3": "#/$defs/DownloadToS3BlockYAML", + "extraction": "#/$defs/ExtractionBlockYAML", + "file_download": "#/$defs/FileDownloadBlockYAML", + "file_upload": "#/$defs/FileUploadBlockYAML", + "file_url_parser": "#/$defs/FileParserBlockYAML", + "for_loop": "#/$defs/ForLoopBlockYAML", + "goto_url": "#/$defs/UrlBlockYAML", + "login": "#/$defs/LoginBlockYAML", + "navigation": "#/$defs/NavigationBlockYAML", + "pdf_parser": "#/$defs/PDFParserBlockYAML", + "send_email": "#/$defs/SendEmailBlockYAML", + "task": "#/$defs/TaskBlockYAML", + "task_v2": "#/$defs/TaskV2BlockYAML", + "text_prompt": "#/$defs/TextPromptBlockYAML", + "upload_to_s3": "#/$defs/UploadToS3BlockYAML", + "validation": "#/$defs/ValidationBlockYAML", + "wait": "#/$defs/WaitBlockYAML" + }, + "propertyName": "block_type" + }, + "oneOf": [ + { + "$ref": "#/$defs/TaskBlockYAML" + }, + { + "$ref": "#/$defs/ForLoopBlockYAML" + }, + { + "$ref": "#/$defs/CodeBlockYAML" + }, + { + "$ref": "#/$defs/TextPromptBlockYAML" + }, + { + "$ref": "#/$defs/DownloadToS3BlockYAML" + }, + { + "$ref": "#/$defs/UploadToS3BlockYAML" + }, + { + "$ref": "#/$defs/FileUploadBlockYAML" + }, + { + "$ref": "#/$defs/SendEmailBlockYAML" + }, + { + "$ref": "#/$defs/FileParserBlockYAML" + }, + { + "$ref": "#/$defs/ValidationBlockYAML" + }, + { + "$ref": "#/$defs/ActionBlockYAML" + }, + { + "$ref": "#/$defs/NavigationBlockYAML" + }, + { + "$ref": "#/$defs/ExtractionBlockYAML" + }, + { + "$ref": "#/$defs/LoginBlockYAML" + }, + { + "$ref": "#/$defs/WaitBlockYAML" + }, + { + "$ref": "#/$defs/FileDownloadBlockYAML" + }, + { + "$ref": "#/$defs/UrlBlockYAML" + }, + { + "$ref": "#/$defs/PDFParserBlockYAML" + }, + { + "$ref": "#/$defs/TaskV2BlockYAML" + } + ] + }, + "title": "Blocks", + "type": "array" + } + }, + "required": [ + "parameters", + "blocks" + ], + "title": "WorkflowDefinitionYAML", + "type": "object" + }, + "WorkflowParameterType": { + "enum": [ + "string", + "integer", + "float", + "boolean", + "json", + "file_url", + "credential_id" + ], + "title": "WorkflowParameterType", + "type": "string" + }, + "WorkflowParameterYAML": { + "properties": { + "parameter_type": { + "const": "workflow", + "default": "workflow", + "title": "Parameter Type", + "type": "string" + }, + "key": { + "title": "Key", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "workflow_parameter_type": { + "$ref": "#/$defs/WorkflowParameterType" + }, + "default_value": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "integer" + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Default Value" + } + }, + "required": [ + "key", + "workflow_parameter_type" + ], + "title": "WorkflowParameterYAML", + "type": "object" + }, + "WorkflowStatus": { + "enum": [ + "published", + "draft", + "auto_generated" + ], + "title": "WorkflowStatus", + "type": "string" + } + }, + "properties": { + "title": { + "title": "Title", + "type": "string" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "proxy_location": { + "anyOf": [ + { + "$ref": "#/$defs/ProxyLocation" + }, + { + "type": "null" + } + ] + }, + "webhook_callback_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Webhook Callback Url" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "persist_browser_session": { + "default": false, + "title": "Persist Browser Session", + "type": "boolean" + }, + "workflow_definition": { + "$ref": "#/$defs/WorkflowDefinitionYAML" + }, + "is_saved_task": { + "default": false, + "title": "Is Saved Task", + "type": "boolean" + }, + "status": { + "$ref": "#/$defs/WorkflowStatus", + "default": "published" + } + }, + "required": [ + "title", + "workflow_definition" + ], + "title": "WorkflowCreateYAMLRequest", + "type": "object" + } + } + }, + "required": true + }, + "x-fern-sdk-group-name": "agent", + "x-fern-sdk-method-name": "update_workflow" + } + }, + "/v1/workflows/{workflow_id}/delete": { + "post": { + "tags": [ + "Agent" + ], + "summary": "Delete a workflow", + "description": "Delete a workflow", + "operationId": "delete_workflow_v1_workflows__workflow_id__delete_post", + "parameters": [ + { + "name": "workflow_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "title": "Workflow Id" + } + }, + { + "name": "x-api-key", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "X-Api-Key" + } + }, + { + "name": "authorization", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Authorization" + } + } + ], + "responses": { + "200": { + "description": "Successfully deleted workflow", + "content": { + "application/json": { + "schema": { + } } } @@ -95,17 +2576,17 @@ } }, "x-fern-sdk-group-name": "agent", - "x-fern-sdk-method-name": "get_run" + "x-fern-sdk-method-name": "delete_workflow" } }, - "/v1/tasks": { + "/v1/run/tasks": { "post": { "tags": [ "Agent" ], "summary": "Run a task", "description": "Run a task", - "operationId": "run_task_v1_tasks_post", + "operationId": "run_task_v1_run_tasks_post", "parameters": [ { "name": "x-api-key", @@ -179,6 +2660,192 @@ "x-fern-sdk-method-name": "run_task" } }, + "/v1/run/workflows": { + "post": { + "tags": [ + "Agent" + ], + "summary": "Run a workflow", + "description": "Run a workflow", + "operationId": "run_workflow_v1_run_workflows_post", + "parameters": [ + { + "name": "template", + "in": "query", + "required": false, + "schema": { + "type": "boolean", + "default": false, + "title": "Template" + } + }, + { + "name": "x-api-key", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "X-Api-Key" + } + }, + { + "name": "x-max-steps-override", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "X-Max-Steps-Override" + } + }, + { + "name": "authorization", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Authorization" + } + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/WorkflowRunRequest" + } + } + } + }, + "responses": { + "200": { + "description": "Successfully run workflow", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/WorkflowRunResponse" + } + } + } + }, + "400": { + "description": "Invalid workflow run request" + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + }, + "x-fern-sdk-group-name": "agent", + "x-fern-sdk-method-name": "run_workflow" + } + }, + "/v1/runs/{run_id}/cancel": { + "post": { + "tags": [ + "Agent" + ], + "summary": "Cancel a task or workflow run", + "description": "Cancel a task or workflow run", + "operationId": "cancel_run_v1_runs__run_id__cancel_post", + "parameters": [ + { + "name": "run_id", + "in": "path", + "required": true, + "schema": { + "type": "string", + "description": "The id of the task run or the workflow run to cancel.", + "title": "Run Id" + }, + "description": "The id of the task run or the workflow run to cancel." + }, + { + "name": "x-api-key", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "X-Api-Key" + } + }, + { + "name": "authorization", + "in": "header", + "required": false, + "schema": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Authorization" + } + } + ], + "responses": { + "200": { + "description": "Successful Response", + "content": { + "application/json": { + "schema": { + + } + } + } + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + }, + "x-fern-sdk-group-name": "agent", + "x-fern-sdk-method-name": "cancel_run" + } + }, "/v1/browser_sessions/{browser_session_id}": { "get": { "tags": [ @@ -489,6 +3156,608 @@ }, "components": { "schemas": { + "AWSSecretParameter": { + "properties": { + "parameter_type": { + "type": "string", + "const": "aws_secret", + "title": "Parameter Type", + "default": "aws_secret" + }, + "key": { + "type": "string", + "title": "Key" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "aws_secret_parameter_id": { + "type": "string", + "title": "Aws Secret Parameter Id" + }, + "workflow_id": { + "type": "string", + "title": "Workflow Id" + }, + "aws_key": { + "type": "string", + "title": "Aws Key" + }, + "created_at": { + "type": "string", + "format": "date-time", + "title": "Created At" + }, + "modified_at": { + "type": "string", + "format": "date-time", + "title": "Modified At" + }, + "deleted_at": { + "anyOf": [ + { + "type": "string", + "format": "date-time" + }, + { + "type": "null" + } + ], + "title": "Deleted At" + } + }, + "type": "object", + "required": [ + "key", + "aws_secret_parameter_id", + "workflow_id", + "aws_key", + "created_at", + "modified_at" + ], + "title": "AWSSecretParameter" + }, + "ActionBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "action", + "title": "Block Type", + "default": "action" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "task_type": { + "type": "string", + "title": "Task Type", + "default": "general" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "type": "string", + "title": "Title", + "default": "" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "type": "integer", + "title": "Max Retries", + "default": 0 + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "complete_on_download": { + "type": "boolean", + "title": "Complete On Download", + "default": false + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "type": "boolean", + "title": "Cache Actions", + "default": false + }, + "complete_verification": { + "type": "boolean", + "title": "Complete Verification", + "default": true + } + }, + "type": "object", + "required": [ + "label", + "output_parameter" + ], + "title": "ActionBlock" + }, + "BitwardenCreditCardDataParameter": { + "properties": { + "parameter_type": { + "type": "string", + "const": "bitwarden_credit_card_data", + "title": "Parameter Type", + "default": "bitwarden_credit_card_data" + }, + "key": { + "type": "string", + "title": "Key" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "bitwarden_credit_card_data_parameter_id": { + "type": "string", + "title": "Bitwarden Credit Card Data Parameter Id" + }, + "workflow_id": { + "type": "string", + "title": "Workflow Id" + }, + "bitwarden_client_id_aws_secret_key": { + "type": "string", + "title": "Bitwarden Client Id Aws Secret Key" + }, + "bitwarden_client_secret_aws_secret_key": { + "type": "string", + "title": "Bitwarden Client Secret Aws Secret Key" + }, + "bitwarden_master_password_aws_secret_key": { + "type": "string", + "title": "Bitwarden Master Password Aws Secret Key" + }, + "bitwarden_collection_id": { + "type": "string", + "title": "Bitwarden Collection Id" + }, + "bitwarden_item_id": { + "type": "string", + "title": "Bitwarden Item Id" + }, + "created_at": { + "type": "string", + "format": "date-time", + "title": "Created At" + }, + "modified_at": { + "type": "string", + "format": "date-time", + "title": "Modified At" + }, + "deleted_at": { + "anyOf": [ + { + "type": "string", + "format": "date-time" + }, + { + "type": "null" + } + ], + "title": "Deleted At" + } + }, + "type": "object", + "required": [ + "key", + "bitwarden_credit_card_data_parameter_id", + "workflow_id", + "bitwarden_client_id_aws_secret_key", + "bitwarden_client_secret_aws_secret_key", + "bitwarden_master_password_aws_secret_key", + "bitwarden_collection_id", + "bitwarden_item_id", + "created_at", + "modified_at" + ], + "title": "BitwardenCreditCardDataParameter" + }, + "BitwardenLoginCredentialParameter": { + "properties": { + "parameter_type": { + "type": "string", + "const": "bitwarden_login_credential", + "title": "Parameter Type", + "default": "bitwarden_login_credential" + }, + "key": { + "type": "string", + "title": "Key" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "bitwarden_login_credential_parameter_id": { + "type": "string", + "title": "Bitwarden Login Credential Parameter Id" + }, + "workflow_id": { + "type": "string", + "title": "Workflow Id" + }, + "bitwarden_client_id_aws_secret_key": { + "type": "string", + "title": "Bitwarden Client Id Aws Secret Key" + }, + "bitwarden_client_secret_aws_secret_key": { + "type": "string", + "title": "Bitwarden Client Secret Aws Secret Key" + }, + "bitwarden_master_password_aws_secret_key": { + "type": "string", + "title": "Bitwarden Master Password Aws Secret Key" + }, + "url_parameter_key": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url Parameter Key" + }, + "bitwarden_collection_id": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Bitwarden Collection Id" + }, + "bitwarden_item_id": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Bitwarden Item Id" + }, + "created_at": { + "type": "string", + "format": "date-time", + "title": "Created At" + }, + "modified_at": { + "type": "string", + "format": "date-time", + "title": "Modified At" + }, + "deleted_at": { + "anyOf": [ + { + "type": "string", + "format": "date-time" + }, + { + "type": "null" + } + ], + "title": "Deleted At" + } + }, + "type": "object", + "required": [ + "key", + "bitwarden_login_credential_parameter_id", + "workflow_id", + "bitwarden_client_id_aws_secret_key", + "bitwarden_client_secret_aws_secret_key", + "bitwarden_master_password_aws_secret_key", + "created_at", + "modified_at" + ], + "title": "BitwardenLoginCredentialParameter" + }, + "BitwardenSensitiveInformationParameter": { + "properties": { + "parameter_type": { + "type": "string", + "const": "bitwarden_sensitive_information", + "title": "Parameter Type", + "default": "bitwarden_sensitive_information" + }, + "key": { + "type": "string", + "title": "Key" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "bitwarden_sensitive_information_parameter_id": { + "type": "string", + "title": "Bitwarden Sensitive Information Parameter Id" + }, + "workflow_id": { + "type": "string", + "title": "Workflow Id" + }, + "bitwarden_client_id_aws_secret_key": { + "type": "string", + "title": "Bitwarden Client Id Aws Secret Key" + }, + "bitwarden_client_secret_aws_secret_key": { + "type": "string", + "title": "Bitwarden Client Secret Aws Secret Key" + }, + "bitwarden_master_password_aws_secret_key": { + "type": "string", + "title": "Bitwarden Master Password Aws Secret Key" + }, + "bitwarden_collection_id": { + "type": "string", + "title": "Bitwarden Collection Id" + }, + "bitwarden_identity_key": { + "type": "string", + "title": "Bitwarden Identity Key" + }, + "bitwarden_identity_fields": { + "items": { + "type": "string" + }, + "type": "array", + "title": "Bitwarden Identity Fields" + }, + "created_at": { + "type": "string", + "format": "date-time", + "title": "Created At" + }, + "modified_at": { + "type": "string", + "format": "date-time", + "title": "Modified At" + }, + "deleted_at": { + "anyOf": [ + { + "type": "string", + "format": "date-time" + }, + { + "type": "null" + } + ], + "title": "Deleted At" + } + }, + "type": "object", + "required": [ + "key", + "bitwarden_sensitive_information_parameter_id", + "workflow_id", + "bitwarden_client_id_aws_secret_key", + "bitwarden_client_secret_aws_secret_key", + "bitwarden_master_password_aws_secret_key", + "bitwarden_collection_id", + "bitwarden_identity_key", + "bitwarden_identity_fields", + "created_at", + "modified_at" + ], + "title": "BitwardenSensitiveInformationParameter" + }, "BrowserSessionResponse": { "properties": { "browser_session_id": { @@ -561,6 +3830,1101 @@ "title": "BrowserSessionResponse", "description": "Response model for browser session information." }, + "CodeBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "code", + "title": "Block Type", + "default": "code" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "code": { + "type": "string", + "title": "Code" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "code" + ], + "title": "CodeBlock" + }, + "ContextParameter": { + "properties": { + "parameter_type": { + "type": "string", + "const": "context", + "title": "Parameter Type", + "default": "context" + }, + "key": { + "type": "string", + "title": "Key" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "source": { + "anyOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "title": "Source" + }, + "value": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "integer" + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Value" + } + }, + "type": "object", + "required": [ + "key", + "source" + ], + "title": "ContextParameter" + }, + "CredentialParameter": { + "properties": { + "parameter_type": { + "type": "string", + "const": "credential", + "title": "Parameter Type", + "default": "credential" + }, + "key": { + "type": "string", + "title": "Key" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "credential_parameter_id": { + "type": "string", + "title": "Credential Parameter Id" + }, + "workflow_id": { + "type": "string", + "title": "Workflow Id" + }, + "credential_id": { + "type": "string", + "title": "Credential Id" + }, + "created_at": { + "type": "string", + "format": "date-time", + "title": "Created At" + }, + "modified_at": { + "type": "string", + "format": "date-time", + "title": "Modified At" + }, + "deleted_at": { + "anyOf": [ + { + "type": "string", + "format": "date-time" + }, + { + "type": "null" + } + ], + "title": "Deleted At" + } + }, + "type": "object", + "required": [ + "key", + "credential_parameter_id", + "workflow_id", + "credential_id", + "created_at", + "modified_at" + ], + "title": "CredentialParameter" + }, + "DownloadToS3Block": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "download_to_s3", + "title": "Block Type", + "default": "download_to_s3" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "url": { + "type": "string", + "title": "Url" + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "url" + ], + "title": "DownloadToS3Block" + }, + "ExtractionBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "extraction", + "title": "Block Type", + "default": "extraction" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "task_type": { + "type": "string", + "title": "Task Type", + "default": "general" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "type": "string", + "title": "Title", + "default": "" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "type": "string", + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "type": "integer", + "title": "Max Retries", + "default": 0 + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "complete_on_download": { + "type": "boolean", + "title": "Complete On Download", + "default": false + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "type": "boolean", + "title": "Cache Actions", + "default": false + }, + "complete_verification": { + "type": "boolean", + "title": "Complete Verification", + "default": true + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "data_extraction_goal" + ], + "title": "ExtractionBlock" + }, + "FileDownloadBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "file_download", + "title": "Block Type", + "default": "file_download" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "task_type": { + "type": "string", + "title": "Task Type", + "default": "general" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "type": "string", + "title": "Title", + "default": "" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "type": "integer", + "title": "Max Retries", + "default": 0 + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "complete_on_download": { + "type": "boolean", + "title": "Complete On Download", + "default": false + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "type": "boolean", + "title": "Cache Actions", + "default": false + }, + "complete_verification": { + "type": "boolean", + "title": "Complete Verification", + "default": true + } + }, + "type": "object", + "required": [ + "label", + "output_parameter" + ], + "title": "FileDownloadBlock" + }, + "FileInfo": { + "properties": { + "url": { + "type": "string", + "title": "Url", + "description": "URL to access the file" + }, + "checksum": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Checksum", + "description": "SHA-256 checksum of the file" + }, + "filename": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Filename", + "description": "Original filename" + } + }, + "type": "object", + "required": [ + "url" + ], + "title": "FileInfo", + "description": "Information about a downloaded file, including URL and checksum." + }, + "FileParserBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "file_url_parser", + "title": "Block Type", + "default": "file_url_parser" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "file_url": { + "type": "string", + "title": "File Url" + }, + "file_type": { + "$ref": "#/components/schemas/FileType" + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "file_url", + "file_type" + ], + "title": "FileParserBlock" + }, + "FileStorageType": { + "type": "string", + "enum": [ + "s3" + ], + "title": "FileStorageType" + }, + "FileType": { + "type": "string", + "enum": [ + "csv" + ], + "title": "FileType" + }, + "FileUploadBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "file_upload", + "title": "Block Type", + "default": "file_upload" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "storage_type": { + "$ref": "#/components/schemas/FileStorageType", + "default": "s3" + }, + "s3_bucket": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "S3 Bucket" + }, + "aws_access_key_id": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Aws Access Key Id" + }, + "aws_secret_access_key": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Aws Secret Access Key" + }, + "region_name": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Region Name" + }, + "path": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Path" + } + }, + "type": "object", + "required": [ + "label", + "output_parameter" + ], + "title": "FileUploadBlock" + }, + "ForLoopBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "for_loop", + "title": "Block Type", + "default": "for_loop" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "loop_blocks": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/ForLoopBlock" + }, + { + "$ref": "#/components/schemas/TaskBlock" + }, + { + "$ref": "#/components/schemas/CodeBlock" + }, + { + "$ref": "#/components/schemas/TextPromptBlock" + }, + { + "$ref": "#/components/schemas/DownloadToS3Block" + }, + { + "$ref": "#/components/schemas/UploadToS3Block" + }, + { + "$ref": "#/components/schemas/SendEmailBlock" + }, + { + "$ref": "#/components/schemas/FileParserBlock" + }, + { + "$ref": "#/components/schemas/PDFParserBlock" + }, + { + "$ref": "#/components/schemas/ValidationBlock" + }, + { + "$ref": "#/components/schemas/ActionBlock" + }, + { + "$ref": "#/components/schemas/NavigationBlock" + }, + { + "$ref": "#/components/schemas/ExtractionBlock" + }, + { + "$ref": "#/components/schemas/LoginBlock" + }, + { + "$ref": "#/components/schemas/WaitBlock" + }, + { + "$ref": "#/components/schemas/FileDownloadBlock" + }, + { + "$ref": "#/components/schemas/UrlBlock" + }, + { + "$ref": "#/components/schemas/TaskV2Block" + }, + { + "$ref": "#/components/schemas/FileUploadBlock" + } + ], + "discriminator": { + "propertyName": "block_type", + "mapping": { + "action": "#/components/schemas/ActionBlock", + "code": "#/components/schemas/CodeBlock", + "download_to_s3": "#/components/schemas/DownloadToS3Block", + "extraction": "#/components/schemas/ExtractionBlock", + "file_download": "#/components/schemas/FileDownloadBlock", + "file_upload": "#/components/schemas/FileUploadBlock", + "file_url_parser": "#/components/schemas/FileParserBlock", + "for_loop": "#/components/schemas/ForLoopBlock", + "goto_url": "#/components/schemas/UrlBlock", + "login": "#/components/schemas/LoginBlock", + "navigation": "#/components/schemas/NavigationBlock", + "pdf_parser": "#/components/schemas/PDFParserBlock", + "send_email": "#/components/schemas/SendEmailBlock", + "task": "#/components/schemas/TaskBlock", + "task_v2": "#/components/schemas/TaskV2Block", + "text_prompt": "#/components/schemas/TextPromptBlock", + "upload_to_s3": "#/components/schemas/UploadToS3Block", + "validation": "#/components/schemas/ValidationBlock", + "wait": "#/components/schemas/WaitBlock" + } + } + }, + "type": "array", + "title": "Loop Blocks" + }, + "loop_over": { + "anyOf": [ + { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + { + "type": "null" + } + ], + "title": "Loop Over" + }, + "loop_variable_reference": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Loop Variable Reference" + }, + "complete_if_empty": { + "type": "boolean", + "title": "Complete If Empty", + "default": false + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "loop_blocks" + ], + "title": "ForLoopBlock" + }, "HTTPValidationError": { "properties": { "detail": { @@ -574,6 +4938,579 @@ "type": "object", "title": "HTTPValidationError" }, + "LoginBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "login", + "title": "Block Type", + "default": "login" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "task_type": { + "type": "string", + "title": "Task Type", + "default": "general" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "type": "string", + "title": "Title", + "default": "" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "type": "integer", + "title": "Max Retries", + "default": 0 + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "complete_on_download": { + "type": "boolean", + "title": "Complete On Download", + "default": false + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "type": "boolean", + "title": "Cache Actions", + "default": false + }, + "complete_verification": { + "type": "boolean", + "title": "Complete Verification", + "default": true + } + }, + "type": "object", + "required": [ + "label", + "output_parameter" + ], + "title": "LoginBlock" + }, + "NavigationBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "navigation", + "title": "Block Type", + "default": "navigation" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "task_type": { + "type": "string", + "title": "Task Type", + "default": "general" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "type": "string", + "title": "Title", + "default": "" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "navigation_goal": { + "type": "string", + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "type": "integer", + "title": "Max Retries", + "default": 0 + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "complete_on_download": { + "type": "boolean", + "title": "Complete On Download", + "default": false + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "type": "boolean", + "title": "Cache Actions", + "default": false + }, + "complete_verification": { + "type": "boolean", + "title": "Complete Verification", + "default": true + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "navigation_goal" + ], + "title": "NavigationBlock" + }, + "OutputParameter": { + "properties": { + "parameter_type": { + "type": "string", + "const": "output", + "title": "Parameter Type", + "default": "output" + }, + "key": { + "type": "string", + "title": "Key" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "output_parameter_id": { + "type": "string", + "title": "Output Parameter Id" + }, + "workflow_id": { + "type": "string", + "title": "Workflow Id" + }, + "created_at": { + "type": "string", + "format": "date-time", + "title": "Created At" + }, + "modified_at": { + "type": "string", + "format": "date-time", + "title": "Modified At" + }, + "deleted_at": { + "anyOf": [ + { + "type": "string", + "format": "date-time" + }, + { + "type": "null" + } + ], + "title": "Deleted At" + } + }, + "type": "object", + "required": [ + "key", + "output_parameter_id", + "workflow_id", + "created_at", + "modified_at" + ], + "title": "OutputParameter" + }, + "PDFParserBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "pdf_parser", + "title": "Block Type", + "default": "pdf_parser" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "file_url": { + "type": "string", + "title": "File Url" + }, + "json_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Json Schema" + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "file_url" + ], + "title": "PDFParserBlock" + }, "ProxyLocation": { "type": "string", "enum": [ @@ -620,6 +5557,316 @@ ], "title": "RunStatus" }, + "SendEmailBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "send_email", + "title": "Block Type", + "default": "send_email" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "smtp_host": { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + "smtp_port": { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + "smtp_username": { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + "smtp_password": { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + "sender": { + "type": "string", + "title": "Sender" + }, + "recipients": { + "items": { + "type": "string" + }, + "type": "array", + "title": "Recipients" + }, + "subject": { + "type": "string", + "title": "Subject" + }, + "body": { + "type": "string", + "title": "Body" + }, + "file_attachments": { + "items": { + "type": "string" + }, + "type": "array", + "title": "File Attachments", + "default": [] + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "smtp_host", + "smtp_port", + "smtp_username", + "smtp_password", + "sender", + "recipients", + "subject", + "body" + ], + "title": "SendEmailBlock" + }, + "TaskBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "task", + "title": "Block Type", + "default": "task" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "task_type": { + "type": "string", + "title": "Task Type", + "default": "general" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "type": "string", + "title": "Title", + "default": "" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "type": "integer", + "title": "Max Retries", + "default": 0 + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "complete_on_download": { + "type": "boolean", + "title": "Complete On Download", + "default": false + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "type": "boolean", + "title": "Cache Actions", + "default": false + }, + "complete_verification": { + "type": "boolean", + "title": "Complete Verification", + "default": true + } + }, + "type": "object", + "required": [ + "label", + "output_parameter" + ], + "title": "TaskBlock" + }, "TaskRunRequest": { "properties": { "prompt": { @@ -671,6 +5918,7 @@ "data_extraction_schema": { "anyOf": [ { + "additionalProperties": true, "type": "object" }, { @@ -791,6 +6039,7 @@ "output": { "anyOf": [ { + "additionalProperties": true, "type": "object" }, { @@ -809,6 +6058,33 @@ "title": "Output", "description": "Output data from the run, if any. Format depends on the schema in the input" }, + "downloaded_files": { + "anyOf": [ + { + "items": { + "$ref": "#/components/schemas/FileInfo" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Downloaded Files", + "description": "List of files downloaded during the run" + }, + "recording_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Recording Url", + "description": "URL to the recording of the run" + }, "failure_reason": { "anyOf": [ { @@ -864,6 +6140,681 @@ ], "title": "TaskRunResponse" }, + "TaskV2Block": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "task_v2", + "title": "Block Type", + "default": "task_v2" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "prompt": { + "type": "string", + "title": "Prompt" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "max_iterations": { + "type": "integer", + "title": "Max Iterations", + "default": 10 + }, + "max_steps": { + "type": "integer", + "title": "Max Steps", + "default": 25 + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "prompt" + ], + "title": "TaskV2Block" + }, + "TextPromptBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "text_prompt", + "title": "Block Type", + "default": "text_prompt" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "llm_key": { + "type": "string", + "title": "Llm Key", + "default": "AZURE_OPENAI" + }, + "prompt": { + "type": "string", + "title": "Prompt" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "json_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Json Schema" + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "prompt" + ], + "title": "TextPromptBlock" + }, + "UploadToS3Block": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "upload_to_s3", + "title": "Block Type", + "default": "upload_to_s3" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "path": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Path" + } + }, + "type": "object", + "required": [ + "label", + "output_parameter" + ], + "title": "UploadToS3Block" + }, + "UrlBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "goto_url", + "title": "Block Type", + "default": "goto_url" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "task_type": { + "type": "string", + "title": "Task Type", + "default": "general" + }, + "url": { + "type": "string", + "title": "Url" + }, + "title": { + "type": "string", + "title": "Title", + "default": "" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "type": "integer", + "title": "Max Retries", + "default": 0 + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "complete_on_download": { + "type": "boolean", + "title": "Complete On Download", + "default": false + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "type": "boolean", + "title": "Cache Actions", + "default": false + }, + "complete_verification": { + "type": "boolean", + "title": "Complete Verification", + "default": true + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "url" + ], + "title": "UrlBlock" + }, + "ValidationBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "validation", + "title": "Block Type", + "default": "validation" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "task_type": { + "type": "string", + "title": "Task Type", + "default": "general" + }, + "url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Url" + }, + "title": { + "type": "string", + "title": "Title", + "default": "" + }, + "complete_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Complete Criterion" + }, + "terminate_criterion": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Terminate Criterion" + }, + "navigation_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Navigation Goal" + }, + "data_extraction_goal": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Data Extraction Goal" + }, + "data_schema": { + "anyOf": [ + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Data Schema" + }, + "error_code_mapping": { + "anyOf": [ + { + "additionalProperties": { + "type": "string" + }, + "type": "object" + }, + { + "type": "null" + } + ], + "title": "Error Code Mapping" + }, + "max_retries": { + "type": "integer", + "title": "Max Retries", + "default": 0 + }, + "max_steps_per_run": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "null" + } + ], + "title": "Max Steps Per Run" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + }, + "complete_on_download": { + "type": "boolean", + "title": "Complete On Download", + "default": false + }, + "download_suffix": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Download Suffix" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "cache_actions": { + "type": "boolean", + "title": "Cache Actions", + "default": false + }, + "complete_verification": { + "type": "boolean", + "title": "Complete Verification", + "default": true + } + }, + "type": "object", + "required": [ + "label", + "output_parameter" + ], + "title": "ValidationBlock" + }, "ValidationError": { "properties": { "loc": { @@ -897,6 +6848,469 @@ ], "title": "ValidationError" }, + "WaitBlock": { + "properties": { + "label": { + "type": "string", + "title": "Label" + }, + "block_type": { + "type": "string", + "const": "wait", + "title": "Block Type", + "default": "wait" + }, + "output_parameter": { + "$ref": "#/components/schemas/OutputParameter" + }, + "continue_on_failure": { + "type": "boolean", + "title": "Continue On Failure", + "default": false + }, + "wait_sec": { + "type": "integer", + "title": "Wait Sec" + }, + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters", + "default": [] + } + }, + "type": "object", + "required": [ + "label", + "output_parameter", + "wait_sec" + ], + "title": "WaitBlock" + }, + "Workflow": { + "properties": { + "workflow_id": { + "type": "string", + "title": "Workflow Id" + }, + "organization_id": { + "type": "string", + "title": "Organization Id" + }, + "title": { + "type": "string", + "title": "Title" + }, + "workflow_permanent_id": { + "type": "string", + "title": "Workflow Permanent Id" + }, + "version": { + "type": "integer", + "title": "Version" + }, + "is_saved_task": { + "type": "boolean", + "title": "Is Saved Task" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "workflow_definition": { + "$ref": "#/components/schemas/WorkflowDefinition" + }, + "proxy_location": { + "anyOf": [ + { + "$ref": "#/components/schemas/ProxyLocation" + }, + { + "type": "null" + } + ] + }, + "webhook_callback_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Webhook Callback Url" + }, + "totp_verification_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Verification Url" + }, + "totp_identifier": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Totp Identifier" + }, + "persist_browser_session": { + "type": "boolean", + "title": "Persist Browser Session", + "default": false + }, + "status": { + "$ref": "#/components/schemas/WorkflowStatus", + "default": "published" + }, + "created_at": { + "type": "string", + "format": "date-time", + "title": "Created At" + }, + "modified_at": { + "type": "string", + "format": "date-time", + "title": "Modified At" + }, + "deleted_at": { + "anyOf": [ + { + "type": "string", + "format": "date-time" + }, + { + "type": "null" + } + ], + "title": "Deleted At" + } + }, + "type": "object", + "required": [ + "workflow_id", + "organization_id", + "title", + "workflow_permanent_id", + "version", + "is_saved_task", + "workflow_definition", + "created_at", + "modified_at" + ], + "title": "Workflow" + }, + "WorkflowDefinition": { + "properties": { + "parameters": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowParameter" + }, + { + "$ref": "#/components/schemas/ContextParameter" + }, + { + "$ref": "#/components/schemas/AWSSecretParameter" + }, + { + "$ref": "#/components/schemas/BitwardenLoginCredentialParameter" + }, + { + "$ref": "#/components/schemas/BitwardenSensitiveInformationParameter" + }, + { + "$ref": "#/components/schemas/BitwardenCreditCardDataParameter" + }, + { + "$ref": "#/components/schemas/OutputParameter" + }, + { + "$ref": "#/components/schemas/CredentialParameter" + } + ], + "discriminator": { + "propertyName": "parameter_type", + "mapping": { + "aws_secret": "#/components/schemas/AWSSecretParameter", + "bitwarden_credit_card_data": "#/components/schemas/BitwardenCreditCardDataParameter", + "bitwarden_login_credential": "#/components/schemas/BitwardenLoginCredentialParameter", + "bitwarden_sensitive_information": "#/components/schemas/BitwardenSensitiveInformationParameter", + "context": "#/components/schemas/ContextParameter", + "credential": "#/components/schemas/CredentialParameter", + "output": "#/components/schemas/OutputParameter", + "workflow": "#/components/schemas/WorkflowParameter" + } + } + }, + "type": "array", + "title": "Parameters" + }, + "blocks": { + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/ForLoopBlock" + }, + { + "$ref": "#/components/schemas/TaskBlock" + }, + { + "$ref": "#/components/schemas/CodeBlock" + }, + { + "$ref": "#/components/schemas/TextPromptBlock" + }, + { + "$ref": "#/components/schemas/DownloadToS3Block" + }, + { + "$ref": "#/components/schemas/UploadToS3Block" + }, + { + "$ref": "#/components/schemas/SendEmailBlock" + }, + { + "$ref": "#/components/schemas/FileParserBlock" + }, + { + "$ref": "#/components/schemas/PDFParserBlock" + }, + { + "$ref": "#/components/schemas/ValidationBlock" + }, + { + "$ref": "#/components/schemas/ActionBlock" + }, + { + "$ref": "#/components/schemas/NavigationBlock" + }, + { + "$ref": "#/components/schemas/ExtractionBlock" + }, + { + "$ref": "#/components/schemas/LoginBlock" + }, + { + "$ref": "#/components/schemas/WaitBlock" + }, + { + "$ref": "#/components/schemas/FileDownloadBlock" + }, + { + "$ref": "#/components/schemas/UrlBlock" + }, + { + "$ref": "#/components/schemas/TaskV2Block" + }, + { + "$ref": "#/components/schemas/FileUploadBlock" + } + ], + "discriminator": { + "propertyName": "block_type", + "mapping": { + "action": "#/components/schemas/ActionBlock", + "code": "#/components/schemas/CodeBlock", + "download_to_s3": "#/components/schemas/DownloadToS3Block", + "extraction": "#/components/schemas/ExtractionBlock", + "file_download": "#/components/schemas/FileDownloadBlock", + "file_upload": "#/components/schemas/FileUploadBlock", + "file_url_parser": "#/components/schemas/FileParserBlock", + "for_loop": "#/components/schemas/ForLoopBlock", + "goto_url": "#/components/schemas/UrlBlock", + "login": "#/components/schemas/LoginBlock", + "navigation": "#/components/schemas/NavigationBlock", + "pdf_parser": "#/components/schemas/PDFParserBlock", + "send_email": "#/components/schemas/SendEmailBlock", + "task": "#/components/schemas/TaskBlock", + "task_v2": "#/components/schemas/TaskV2Block", + "text_prompt": "#/components/schemas/TextPromptBlock", + "upload_to_s3": "#/components/schemas/UploadToS3Block", + "validation": "#/components/schemas/ValidationBlock", + "wait": "#/components/schemas/WaitBlock" + } + } + }, + "type": "array", + "title": "Blocks" + } + }, + "type": "object", + "required": [ + "parameters", + "blocks" + ], + "title": "WorkflowDefinition" + }, + "WorkflowParameter": { + "properties": { + "parameter_type": { + "type": "string", + "const": "workflow", + "title": "Parameter Type", + "default": "workflow" + }, + "key": { + "type": "string", + "title": "Key" + }, + "description": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Description" + }, + "workflow_parameter_id": { + "type": "string", + "title": "Workflow Parameter Id" + }, + "workflow_parameter_type": { + "$ref": "#/components/schemas/WorkflowParameterType" + }, + "workflow_id": { + "type": "string", + "title": "Workflow Id" + }, + "default_value": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "integer" + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "additionalProperties": true, + "type": "object" + }, + { + "items": { + + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Default Value" + }, + "created_at": { + "type": "string", + "format": "date-time", + "title": "Created At" + }, + "modified_at": { + "type": "string", + "format": "date-time", + "title": "Modified At" + }, + "deleted_at": { + "anyOf": [ + { + "type": "string", + "format": "date-time" + }, + { + "type": "null" + } + ], + "title": "Deleted At" + } + }, + "type": "object", + "required": [ + "key", + "workflow_parameter_id", + "workflow_parameter_type", + "workflow_id", + "created_at", + "modified_at" + ], + "title": "WorkflowParameter" + }, + "WorkflowParameterType": { + "type": "string", + "enum": [ + "string", + "integer", + "float", + "boolean", + "json", + "file_url", + "credential_id" + ], + "title": "WorkflowParameterType" + }, "WorkflowRunRequest": { "properties": { "workflow_id": { @@ -917,6 +7331,7 @@ "description": "Optional title for this workflow run" }, "parameters": { + "additionalProperties": true, "type": "object", "title": "Parameters", "description": "Parameters to pass to the workflow", @@ -998,6 +7413,7 @@ "output": { "anyOf": [ { + "additionalProperties": true, "type": "object" }, { @@ -1016,6 +7432,33 @@ "title": "Output", "description": "Output data from the run, if any. Format depends on the schema in the input" }, + "downloaded_files": { + "anyOf": [ + { + "items": { + "$ref": "#/components/schemas/FileInfo" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Downloaded Files", + "description": "List of files downloaded during the run" + }, + "recording_url": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Recording Url", + "description": "URL to the recording of the run" + }, "failure_reason": { "anyOf": [ { @@ -1067,6 +7510,15 @@ "run_type" ], "title": "WorkflowRunResponse" + }, + "WorkflowStatus": { + "type": "string", + "enum": [ + "published", + "draft", + "auto_generated" + ], + "title": "WorkflowStatus" } } }, diff --git a/pyproject.toml b/pyproject.toml index 497dd442..7f614210 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "skyvern" -version = "0.1.68" +version = "0.1.69" description = "" authors = ["Skyvern AI "] readme = "README.md" diff --git a/skyvern/client/__init__.py b/skyvern/client/__init__.py index ee5b0a7f..ee3060d8 100644 --- a/skyvern/client/__init__.py +++ b/skyvern/client/__init__.py @@ -1,19 +1,229 @@ # This file was auto-generated by Fern from our API Definition. from .types import ( + ActionBlock, + ActionBlockDataSchema, + ActionBlockParametersItem, + ActionBlockParametersItem_AwsSecret, + ActionBlockParametersItem_BitwardenCreditCardData, + ActionBlockParametersItem_BitwardenLoginCredential, + ActionBlockParametersItem_BitwardenSensitiveInformation, + ActionBlockParametersItem_Context, + ActionBlockParametersItem_Credential, + ActionBlockParametersItem_Output, + ActionBlockParametersItem_Workflow, + AwsSecretParameter, + BitwardenCreditCardDataParameter, + BitwardenLoginCredentialParameter, + BitwardenSensitiveInformationParameter, BrowserSessionResponse, + CodeBlock, + CodeBlockParametersItem, + CodeBlockParametersItem_AwsSecret, + CodeBlockParametersItem_BitwardenCreditCardData, + CodeBlockParametersItem_BitwardenLoginCredential, + CodeBlockParametersItem_BitwardenSensitiveInformation, + CodeBlockParametersItem_Context, + CodeBlockParametersItem_Credential, + CodeBlockParametersItem_Output, + CodeBlockParametersItem_Workflow, + ContextParameter, + CredentialParameter, + DownloadToS3Block, + ExtractionBlock, + ExtractionBlockDataSchema, + ExtractionBlockParametersItem, + ExtractionBlockParametersItem_AwsSecret, + ExtractionBlockParametersItem_BitwardenCreditCardData, + ExtractionBlockParametersItem_BitwardenLoginCredential, + ExtractionBlockParametersItem_BitwardenSensitiveInformation, + ExtractionBlockParametersItem_Context, + ExtractionBlockParametersItem_Credential, + ExtractionBlockParametersItem_Output, + ExtractionBlockParametersItem_Workflow, + FileDownloadBlock, + FileDownloadBlockDataSchema, + FileDownloadBlockParametersItem, + FileDownloadBlockParametersItem_AwsSecret, + FileDownloadBlockParametersItem_BitwardenCreditCardData, + FileDownloadBlockParametersItem_BitwardenLoginCredential, + FileDownloadBlockParametersItem_BitwardenSensitiveInformation, + FileDownloadBlockParametersItem_Context, + FileDownloadBlockParametersItem_Credential, + FileDownloadBlockParametersItem_Output, + FileDownloadBlockParametersItem_Workflow, + FileInfo, + FileParserBlock, + FileStorageType, + FileType, + FileUploadBlock, + ForLoopBlock, + ForLoopBlockLoopBlocksItem, + ForLoopBlockLoopBlocksItem_Action, + ForLoopBlockLoopBlocksItem_Code, + ForLoopBlockLoopBlocksItem_DownloadToS3, + ForLoopBlockLoopBlocksItem_Extraction, + ForLoopBlockLoopBlocksItem_FileDownload, + ForLoopBlockLoopBlocksItem_FileUpload, + ForLoopBlockLoopBlocksItem_FileUrlParser, + ForLoopBlockLoopBlocksItem_ForLoop, + ForLoopBlockLoopBlocksItem_GotoUrl, + ForLoopBlockLoopBlocksItem_Login, + ForLoopBlockLoopBlocksItem_Navigation, + ForLoopBlockLoopBlocksItem_PdfParser, + ForLoopBlockLoopBlocksItem_SendEmail, + ForLoopBlockLoopBlocksItem_Task, + ForLoopBlockLoopBlocksItem_TaskV2, + ForLoopBlockLoopBlocksItem_TextPrompt, + ForLoopBlockLoopBlocksItem_UploadToS3, + ForLoopBlockLoopBlocksItem_Validation, + ForLoopBlockLoopBlocksItem_Wait, + ForLoopBlockLoopOver, + ForLoopBlockLoopOver_AwsSecret, + ForLoopBlockLoopOver_BitwardenCreditCardData, + ForLoopBlockLoopOver_BitwardenLoginCredential, + ForLoopBlockLoopOver_BitwardenSensitiveInformation, + ForLoopBlockLoopOver_Context, + ForLoopBlockLoopOver_Credential, + ForLoopBlockLoopOver_Output, + ForLoopBlockLoopOver_Workflow, HttpValidationError, + LoginBlock, + LoginBlockDataSchema, + LoginBlockParametersItem, + LoginBlockParametersItem_AwsSecret, + LoginBlockParametersItem_BitwardenCreditCardData, + LoginBlockParametersItem_BitwardenLoginCredential, + LoginBlockParametersItem_BitwardenSensitiveInformation, + LoginBlockParametersItem_Context, + LoginBlockParametersItem_Credential, + LoginBlockParametersItem_Output, + LoginBlockParametersItem_Workflow, + NavigationBlock, + NavigationBlockDataSchema, + NavigationBlockParametersItem, + NavigationBlockParametersItem_AwsSecret, + NavigationBlockParametersItem_BitwardenCreditCardData, + NavigationBlockParametersItem_BitwardenLoginCredential, + NavigationBlockParametersItem_BitwardenSensitiveInformation, + NavigationBlockParametersItem_Context, + NavigationBlockParametersItem_Credential, + NavigationBlockParametersItem_Output, + NavigationBlockParametersItem_Workflow, Output, + OutputParameter, + PdfParserBlock, ProxyLocation, RunEngine, RunStatus, + SendEmailBlock, + Source, + Source_AwsSecret, + Source_BitwardenCreditCardData, + Source_BitwardenLoginCredential, + Source_BitwardenSensitiveInformation, + Source_Context, + Source_Credential, + Source_Output, + Source_Workflow, + TaskBlock, + TaskBlockDataSchema, + TaskBlockParametersItem, + TaskBlockParametersItem_AwsSecret, + TaskBlockParametersItem_BitwardenCreditCardData, + TaskBlockParametersItem_BitwardenLoginCredential, + TaskBlockParametersItem_BitwardenSensitiveInformation, + TaskBlockParametersItem_Context, + TaskBlockParametersItem_Credential, + TaskBlockParametersItem_Output, + TaskBlockParametersItem_Workflow, TaskRunRequest, TaskRunRequestDataExtractionSchema, TaskRunResponse, + TaskV2Block, + TextPromptBlock, + TextPromptBlockParametersItem, + TextPromptBlockParametersItem_AwsSecret, + TextPromptBlockParametersItem_BitwardenCreditCardData, + TextPromptBlockParametersItem_BitwardenLoginCredential, + TextPromptBlockParametersItem_BitwardenSensitiveInformation, + TextPromptBlockParametersItem_Context, + TextPromptBlockParametersItem_Credential, + TextPromptBlockParametersItem_Output, + TextPromptBlockParametersItem_Workflow, + UploadToS3Block, + UrlBlock, + UrlBlockDataSchema, + UrlBlockParametersItem, + UrlBlockParametersItem_AwsSecret, + UrlBlockParametersItem_BitwardenCreditCardData, + UrlBlockParametersItem_BitwardenLoginCredential, + UrlBlockParametersItem_BitwardenSensitiveInformation, + UrlBlockParametersItem_Context, + UrlBlockParametersItem_Credential, + UrlBlockParametersItem_Output, + UrlBlockParametersItem_Workflow, + ValidationBlock, + ValidationBlockDataSchema, + ValidationBlockParametersItem, + ValidationBlockParametersItem_AwsSecret, + ValidationBlockParametersItem_BitwardenCreditCardData, + ValidationBlockParametersItem_BitwardenLoginCredential, + ValidationBlockParametersItem_BitwardenSensitiveInformation, + ValidationBlockParametersItem_Context, + ValidationBlockParametersItem_Credential, + ValidationBlockParametersItem_Output, + ValidationBlockParametersItem_Workflow, ValidationError, ValidationErrorLocItem, + Value, + WaitBlock, + WaitBlockParametersItem, + WaitBlockParametersItem_AwsSecret, + WaitBlockParametersItem_BitwardenCreditCardData, + WaitBlockParametersItem_BitwardenLoginCredential, + WaitBlockParametersItem_BitwardenSensitiveInformation, + WaitBlockParametersItem_Context, + WaitBlockParametersItem_Credential, + WaitBlockParametersItem_Output, + WaitBlockParametersItem_Workflow, + Workflow, + WorkflowDefinition, + WorkflowDefinitionBlocksItem, + WorkflowDefinitionBlocksItem_Action, + WorkflowDefinitionBlocksItem_Code, + WorkflowDefinitionBlocksItem_DownloadToS3, + WorkflowDefinitionBlocksItem_Extraction, + WorkflowDefinitionBlocksItem_FileDownload, + WorkflowDefinitionBlocksItem_FileUpload, + WorkflowDefinitionBlocksItem_FileUrlParser, + WorkflowDefinitionBlocksItem_ForLoop, + WorkflowDefinitionBlocksItem_GotoUrl, + WorkflowDefinitionBlocksItem_Login, + WorkflowDefinitionBlocksItem_Navigation, + WorkflowDefinitionBlocksItem_PdfParser, + WorkflowDefinitionBlocksItem_SendEmail, + WorkflowDefinitionBlocksItem_Task, + WorkflowDefinitionBlocksItem_TaskV2, + WorkflowDefinitionBlocksItem_TextPrompt, + WorkflowDefinitionBlocksItem_UploadToS3, + WorkflowDefinitionBlocksItem_Validation, + WorkflowDefinitionBlocksItem_Wait, + WorkflowDefinitionParametersItem, + WorkflowDefinitionParametersItem_AwsSecret, + WorkflowDefinitionParametersItem_BitwardenCreditCardData, + WorkflowDefinitionParametersItem_BitwardenLoginCredential, + WorkflowDefinitionParametersItem_BitwardenSensitiveInformation, + WorkflowDefinitionParametersItem_Context, + WorkflowDefinitionParametersItem_Credential, + WorkflowDefinitionParametersItem_Output, + WorkflowDefinitionParametersItem_Workflow, + WorkflowParameter, + WorkflowParameterDefaultValue, + WorkflowParameterType, WorkflowRunRequest, WorkflowRunResponse, + WorkflowStatus, ) from .errors import BadRequestError, NotFoundError, UnauthorizedError, UnprocessableEntityError from . import agent, browser_session @@ -28,30 +238,240 @@ from .environment import SkyvernEnvironment from .version import __version__ __all__ = [ + "ActionBlock", + "ActionBlockDataSchema", + "ActionBlockParametersItem", + "ActionBlockParametersItem_AwsSecret", + "ActionBlockParametersItem_BitwardenCreditCardData", + "ActionBlockParametersItem_BitwardenLoginCredential", + "ActionBlockParametersItem_BitwardenSensitiveInformation", + "ActionBlockParametersItem_Context", + "ActionBlockParametersItem_Credential", + "ActionBlockParametersItem_Output", + "ActionBlockParametersItem_Workflow", "AgentGetRunResponse", "AgentGetRunResponse_TaskV1", "AgentGetRunResponse_TaskV2", "AgentGetRunResponse_WorkflowRun", "AsyncSkyvern", + "AwsSecretParameter", "BadRequestError", + "BitwardenCreditCardDataParameter", + "BitwardenLoginCredentialParameter", + "BitwardenSensitiveInformationParameter", "BrowserSessionResponse", + "CodeBlock", + "CodeBlockParametersItem", + "CodeBlockParametersItem_AwsSecret", + "CodeBlockParametersItem_BitwardenCreditCardData", + "CodeBlockParametersItem_BitwardenLoginCredential", + "CodeBlockParametersItem_BitwardenSensitiveInformation", + "CodeBlockParametersItem_Context", + "CodeBlockParametersItem_Credential", + "CodeBlockParametersItem_Output", + "CodeBlockParametersItem_Workflow", + "ContextParameter", + "CredentialParameter", + "DownloadToS3Block", + "ExtractionBlock", + "ExtractionBlockDataSchema", + "ExtractionBlockParametersItem", + "ExtractionBlockParametersItem_AwsSecret", + "ExtractionBlockParametersItem_BitwardenCreditCardData", + "ExtractionBlockParametersItem_BitwardenLoginCredential", + "ExtractionBlockParametersItem_BitwardenSensitiveInformation", + "ExtractionBlockParametersItem_Context", + "ExtractionBlockParametersItem_Credential", + "ExtractionBlockParametersItem_Output", + "ExtractionBlockParametersItem_Workflow", + "FileDownloadBlock", + "FileDownloadBlockDataSchema", + "FileDownloadBlockParametersItem", + "FileDownloadBlockParametersItem_AwsSecret", + "FileDownloadBlockParametersItem_BitwardenCreditCardData", + "FileDownloadBlockParametersItem_BitwardenLoginCredential", + "FileDownloadBlockParametersItem_BitwardenSensitiveInformation", + "FileDownloadBlockParametersItem_Context", + "FileDownloadBlockParametersItem_Credential", + "FileDownloadBlockParametersItem_Output", + "FileDownloadBlockParametersItem_Workflow", + "FileInfo", + "FileParserBlock", + "FileStorageType", + "FileType", + "FileUploadBlock", + "ForLoopBlock", + "ForLoopBlockLoopBlocksItem", + "ForLoopBlockLoopBlocksItem_Action", + "ForLoopBlockLoopBlocksItem_Code", + "ForLoopBlockLoopBlocksItem_DownloadToS3", + "ForLoopBlockLoopBlocksItem_Extraction", + "ForLoopBlockLoopBlocksItem_FileDownload", + "ForLoopBlockLoopBlocksItem_FileUpload", + "ForLoopBlockLoopBlocksItem_FileUrlParser", + "ForLoopBlockLoopBlocksItem_ForLoop", + "ForLoopBlockLoopBlocksItem_GotoUrl", + "ForLoopBlockLoopBlocksItem_Login", + "ForLoopBlockLoopBlocksItem_Navigation", + "ForLoopBlockLoopBlocksItem_PdfParser", + "ForLoopBlockLoopBlocksItem_SendEmail", + "ForLoopBlockLoopBlocksItem_Task", + "ForLoopBlockLoopBlocksItem_TaskV2", + "ForLoopBlockLoopBlocksItem_TextPrompt", + "ForLoopBlockLoopBlocksItem_UploadToS3", + "ForLoopBlockLoopBlocksItem_Validation", + "ForLoopBlockLoopBlocksItem_Wait", + "ForLoopBlockLoopOver", + "ForLoopBlockLoopOver_AwsSecret", + "ForLoopBlockLoopOver_BitwardenCreditCardData", + "ForLoopBlockLoopOver_BitwardenLoginCredential", + "ForLoopBlockLoopOver_BitwardenSensitiveInformation", + "ForLoopBlockLoopOver_Context", + "ForLoopBlockLoopOver_Credential", + "ForLoopBlockLoopOver_Output", + "ForLoopBlockLoopOver_Workflow", "HttpValidationError", + "LoginBlock", + "LoginBlockDataSchema", + "LoginBlockParametersItem", + "LoginBlockParametersItem_AwsSecret", + "LoginBlockParametersItem_BitwardenCreditCardData", + "LoginBlockParametersItem_BitwardenLoginCredential", + "LoginBlockParametersItem_BitwardenSensitiveInformation", + "LoginBlockParametersItem_Context", + "LoginBlockParametersItem_Credential", + "LoginBlockParametersItem_Output", + "LoginBlockParametersItem_Workflow", + "NavigationBlock", + "NavigationBlockDataSchema", + "NavigationBlockParametersItem", + "NavigationBlockParametersItem_AwsSecret", + "NavigationBlockParametersItem_BitwardenCreditCardData", + "NavigationBlockParametersItem_BitwardenLoginCredential", + "NavigationBlockParametersItem_BitwardenSensitiveInformation", + "NavigationBlockParametersItem_Context", + "NavigationBlockParametersItem_Credential", + "NavigationBlockParametersItem_Output", + "NavigationBlockParametersItem_Workflow", "NotFoundError", "Output", + "OutputParameter", + "PdfParserBlock", "ProxyLocation", "RunEngine", "RunStatus", + "SendEmailBlock", "Skyvern", "SkyvernEnvironment", + "Source", + "Source_AwsSecret", + "Source_BitwardenCreditCardData", + "Source_BitwardenLoginCredential", + "Source_BitwardenSensitiveInformation", + "Source_Context", + "Source_Credential", + "Source_Output", + "Source_Workflow", + "TaskBlock", + "TaskBlockDataSchema", + "TaskBlockParametersItem", + "TaskBlockParametersItem_AwsSecret", + "TaskBlockParametersItem_BitwardenCreditCardData", + "TaskBlockParametersItem_BitwardenLoginCredential", + "TaskBlockParametersItem_BitwardenSensitiveInformation", + "TaskBlockParametersItem_Context", + "TaskBlockParametersItem_Credential", + "TaskBlockParametersItem_Output", + "TaskBlockParametersItem_Workflow", "TaskRunRequest", "TaskRunRequestDataExtractionSchema", "TaskRunResponse", + "TaskV2Block", + "TextPromptBlock", + "TextPromptBlockParametersItem", + "TextPromptBlockParametersItem_AwsSecret", + "TextPromptBlockParametersItem_BitwardenCreditCardData", + "TextPromptBlockParametersItem_BitwardenLoginCredential", + "TextPromptBlockParametersItem_BitwardenSensitiveInformation", + "TextPromptBlockParametersItem_Context", + "TextPromptBlockParametersItem_Credential", + "TextPromptBlockParametersItem_Output", + "TextPromptBlockParametersItem_Workflow", "UnauthorizedError", "UnprocessableEntityError", + "UploadToS3Block", + "UrlBlock", + "UrlBlockDataSchema", + "UrlBlockParametersItem", + "UrlBlockParametersItem_AwsSecret", + "UrlBlockParametersItem_BitwardenCreditCardData", + "UrlBlockParametersItem_BitwardenLoginCredential", + "UrlBlockParametersItem_BitwardenSensitiveInformation", + "UrlBlockParametersItem_Context", + "UrlBlockParametersItem_Credential", + "UrlBlockParametersItem_Output", + "UrlBlockParametersItem_Workflow", + "ValidationBlock", + "ValidationBlockDataSchema", + "ValidationBlockParametersItem", + "ValidationBlockParametersItem_AwsSecret", + "ValidationBlockParametersItem_BitwardenCreditCardData", + "ValidationBlockParametersItem_BitwardenLoginCredential", + "ValidationBlockParametersItem_BitwardenSensitiveInformation", + "ValidationBlockParametersItem_Context", + "ValidationBlockParametersItem_Credential", + "ValidationBlockParametersItem_Output", + "ValidationBlockParametersItem_Workflow", "ValidationError", "ValidationErrorLocItem", + "Value", + "WaitBlock", + "WaitBlockParametersItem", + "WaitBlockParametersItem_AwsSecret", + "WaitBlockParametersItem_BitwardenCreditCardData", + "WaitBlockParametersItem_BitwardenLoginCredential", + "WaitBlockParametersItem_BitwardenSensitiveInformation", + "WaitBlockParametersItem_Context", + "WaitBlockParametersItem_Credential", + "WaitBlockParametersItem_Output", + "WaitBlockParametersItem_Workflow", + "Workflow", + "WorkflowDefinition", + "WorkflowDefinitionBlocksItem", + "WorkflowDefinitionBlocksItem_Action", + "WorkflowDefinitionBlocksItem_Code", + "WorkflowDefinitionBlocksItem_DownloadToS3", + "WorkflowDefinitionBlocksItem_Extraction", + "WorkflowDefinitionBlocksItem_FileDownload", + "WorkflowDefinitionBlocksItem_FileUpload", + "WorkflowDefinitionBlocksItem_FileUrlParser", + "WorkflowDefinitionBlocksItem_ForLoop", + "WorkflowDefinitionBlocksItem_GotoUrl", + "WorkflowDefinitionBlocksItem_Login", + "WorkflowDefinitionBlocksItem_Navigation", + "WorkflowDefinitionBlocksItem_PdfParser", + "WorkflowDefinitionBlocksItem_SendEmail", + "WorkflowDefinitionBlocksItem_Task", + "WorkflowDefinitionBlocksItem_TaskV2", + "WorkflowDefinitionBlocksItem_TextPrompt", + "WorkflowDefinitionBlocksItem_UploadToS3", + "WorkflowDefinitionBlocksItem_Validation", + "WorkflowDefinitionBlocksItem_Wait", + "WorkflowDefinitionParametersItem", + "WorkflowDefinitionParametersItem_AwsSecret", + "WorkflowDefinitionParametersItem_BitwardenCreditCardData", + "WorkflowDefinitionParametersItem_BitwardenLoginCredential", + "WorkflowDefinitionParametersItem_BitwardenSensitiveInformation", + "WorkflowDefinitionParametersItem_Context", + "WorkflowDefinitionParametersItem_Credential", + "WorkflowDefinitionParametersItem_Output", + "WorkflowDefinitionParametersItem_Workflow", + "WorkflowParameter", + "WorkflowParameterDefaultValue", + "WorkflowParameterType", "WorkflowRunRequest", "WorkflowRunResponse", + "WorkflowStatus", "__version__", "agent", "browser_session", diff --git a/skyvern/client/agent/client.py b/skyvern/client/agent/client.py index 4d66965d..91bcfd27 100644 --- a/skyvern/client/agent/client.py +++ b/skyvern/client/agent/client.py @@ -6,16 +6,18 @@ from ..core.request_options import RequestOptions from .types.agent_get_run_response import AgentGetRunResponse from ..core.jsonable_encoder import jsonable_encoder from ..core.pydantic_utilities import parse_obj_as +from ..errors.not_found_error import NotFoundError from ..errors.unprocessable_entity_error import UnprocessableEntityError -from ..types.http_validation_error import HttpValidationError from json.decoder import JSONDecodeError from ..core.api_error import ApiError +from ..types.workflow import Workflow from ..types.run_engine import RunEngine from ..types.proxy_location import ProxyLocation from ..types.task_run_request_data_extraction_schema import TaskRunRequestDataExtractionSchema from ..types.task_run_response import TaskRunResponse from ..core.serialization import convert_and_respect_annotation_metadata from ..errors.bad_request_error import BadRequestError +from ..types.workflow_run_response import WorkflowRunResponse from ..core.client_wrapper import AsyncClientWrapper # this is used as the default value for optional parameters @@ -28,9 +30,12 @@ class AgentClient: def get_run(self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> AgentGetRunResponse: """ + Get a task or a workflow run by id + Parameters ---------- run_id : str + The id of the task run or the workflow run. request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -38,7 +43,7 @@ class AgentClient: Returns ------- AgentGetRunResponse - Successful Response + Successfully got run Examples -------- @@ -66,12 +71,191 @@ class AgentClient: object_=_response.json(), ), ) + if _response.status_code == 404: + raise NotFoundError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + def create_workflow(self, *, request_options: typing.Optional[RequestOptions] = None) -> Workflow: + """ + Create a new workflow + + Parameters + ---------- + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + Workflow + Successfully created workflow + + Examples + -------- + from skyvern import Skyvern + + client = Skyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + client.agent.create_workflow() + """ + _response = self._client_wrapper.httpx_client.request( + "v1/workflows", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + Workflow, + parse_obj_as( + type_=Workflow, # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + def update_workflow(self, workflow_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> Workflow: + """ + Update a workflow definition + + Parameters + ---------- + workflow_id : str + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + Workflow + Successfully updated workflow + + Examples + -------- + from skyvern import Skyvern + + client = Skyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + client.agent.update_workflow( + workflow_id="workflow_id", + ) + """ + _response = self._client_wrapper.httpx_client.request( + f"v1/workflows/{jsonable_encoder(workflow_id)}", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + Workflow, + parse_obj_as( + type_=Workflow, # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + def delete_workflow( + self, workflow_id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> typing.Optional[typing.Any]: + """ + Delete a workflow + + Parameters + ---------- + workflow_id : str + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + typing.Optional[typing.Any] + Successfully deleted workflow + + Examples + -------- + from skyvern import Skyvern + + client = Skyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + client.agent.delete_workflow( + workflow_id="workflow_id", + ) + """ + _response = self._client_wrapper.httpx_client.request( + f"v1/workflows/{jsonable_encoder(workflow_id)}/delete", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -164,7 +348,7 @@ class AgentClient: ) """ _response = self._client_wrapper.httpx_client.request( - "v1/tasks", + "v1/run/tasks", method="POST", json={ "prompt": prompt, @@ -208,9 +392,193 @@ class AgentClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + def run_workflow( + self, + *, + workflow_id: str, + template: typing.Optional[bool] = None, + max_steps_override: typing.Optional[int] = None, + title: typing.Optional[str] = OMIT, + parameters: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT, + proxy_location: typing.Optional[ProxyLocation] = OMIT, + webhook_url: typing.Optional[str] = OMIT, + totp_url: typing.Optional[str] = OMIT, + totp_identifier: typing.Optional[str] = OMIT, + browser_session_id: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> WorkflowRunResponse: + """ + Run a workflow + + Parameters + ---------- + workflow_id : str + ID of the workflow to run + + template : typing.Optional[bool] + + max_steps_override : typing.Optional[int] + + title : typing.Optional[str] + Optional title for this workflow run + + parameters : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] + Parameters to pass to the workflow + + proxy_location : typing.Optional[ProxyLocation] + Location of proxy to use for this workflow run + + webhook_url : typing.Optional[str] + URL to send workflow status updates to after a run is finished + + totp_url : typing.Optional[str] + URL for TOTP authentication setup if Skyvern should be polling endpoint for 2FA codes + + totp_identifier : typing.Optional[str] + Identifier for TOTP (Time-based One-Time Password) authentication if codes are being pushed to Skyvern + + browser_session_id : typing.Optional[str] + ID of an existing browser session to reuse, having it continue from the current screen state + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + WorkflowRunResponse + Successfully run workflow + + Examples + -------- + from skyvern import Skyvern + + client = Skyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + client.agent.run_workflow( + workflow_id="workflow_id", + ) + """ + _response = self._client_wrapper.httpx_client.request( + "v1/run/workflows", + method="POST", + params={ + "template": template, + }, + json={ + "workflow_id": workflow_id, + "title": title, + "parameters": parameters, + "proxy_location": proxy_location, + "webhook_url": webhook_url, + "totp_url": totp_url, + "totp_identifier": totp_identifier, + "browser_session_id": browser_session_id, + }, + headers={ + "x-max-steps-override": str(max_steps_override) if max_steps_override is not None else None, + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + WorkflowRunResponse, + parse_obj_as( + type_=WorkflowRunResponse, # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 400: + raise BadRequestError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + def cancel_run( + self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> typing.Optional[typing.Any]: + """ + Cancel a task or workflow run + + Parameters + ---------- + run_id : str + The id of the task run or the workflow run to cancel. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + typing.Optional[typing.Any] + Successful Response + + Examples + -------- + from skyvern import Skyvern + + client = Skyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + client.agent.cancel_run( + run_id="run_id", + ) + """ + _response = self._client_wrapper.httpx_client.request( + f"v1/runs/{jsonable_encoder(run_id)}/cancel", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -229,9 +597,12 @@ class AsyncAgentClient: self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None ) -> AgentGetRunResponse: """ + Get a task or a workflow run by id + Parameters ---------- run_id : str + The id of the task run or the workflow run. request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -239,7 +610,7 @@ class AsyncAgentClient: Returns ------- AgentGetRunResponse - Successful Response + Successfully got run Examples -------- @@ -275,12 +646,217 @@ class AsyncAgentClient: object_=_response.json(), ), ) + if _response.status_code == 404: + raise NotFoundError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + async def create_workflow(self, *, request_options: typing.Optional[RequestOptions] = None) -> Workflow: + """ + Create a new workflow + + Parameters + ---------- + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + Workflow + Successfully created workflow + + Examples + -------- + import asyncio + + from skyvern import AsyncSkyvern + + client = AsyncSkyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + + + async def main() -> None: + await client.agent.create_workflow() + + + asyncio.run(main()) + """ + _response = await self._client_wrapper.httpx_client.request( + "v1/workflows", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + Workflow, + parse_obj_as( + type_=Workflow, # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + async def update_workflow( + self, workflow_id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> Workflow: + """ + Update a workflow definition + + Parameters + ---------- + workflow_id : str + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + Workflow + Successfully updated workflow + + Examples + -------- + import asyncio + + from skyvern import AsyncSkyvern + + client = AsyncSkyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + + + async def main() -> None: + await client.agent.update_workflow( + workflow_id="workflow_id", + ) + + + asyncio.run(main()) + """ + _response = await self._client_wrapper.httpx_client.request( + f"v1/workflows/{jsonable_encoder(workflow_id)}", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + Workflow, + parse_obj_as( + type_=Workflow, # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + async def delete_workflow( + self, workflow_id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> typing.Optional[typing.Any]: + """ + Delete a workflow + + Parameters + ---------- + workflow_id : str + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + typing.Optional[typing.Any] + Successfully deleted workflow + + Examples + -------- + import asyncio + + from skyvern import AsyncSkyvern + + client = AsyncSkyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + + + async def main() -> None: + await client.agent.delete_workflow( + workflow_id="workflow_id", + ) + + + asyncio.run(main()) + """ + _response = await self._client_wrapper.httpx_client.request( + f"v1/workflows/{jsonable_encoder(workflow_id)}/delete", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -381,7 +957,7 @@ class AsyncAgentClient: asyncio.run(main()) """ _response = await self._client_wrapper.httpx_client.request( - "v1/tasks", + "v1/run/tasks", method="POST", json={ "prompt": prompt, @@ -425,9 +1001,209 @@ class AsyncAgentClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + async def run_workflow( + self, + *, + workflow_id: str, + template: typing.Optional[bool] = None, + max_steps_override: typing.Optional[int] = None, + title: typing.Optional[str] = OMIT, + parameters: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT, + proxy_location: typing.Optional[ProxyLocation] = OMIT, + webhook_url: typing.Optional[str] = OMIT, + totp_url: typing.Optional[str] = OMIT, + totp_identifier: typing.Optional[str] = OMIT, + browser_session_id: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> WorkflowRunResponse: + """ + Run a workflow + + Parameters + ---------- + workflow_id : str + ID of the workflow to run + + template : typing.Optional[bool] + + max_steps_override : typing.Optional[int] + + title : typing.Optional[str] + Optional title for this workflow run + + parameters : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] + Parameters to pass to the workflow + + proxy_location : typing.Optional[ProxyLocation] + Location of proxy to use for this workflow run + + webhook_url : typing.Optional[str] + URL to send workflow status updates to after a run is finished + + totp_url : typing.Optional[str] + URL for TOTP authentication setup if Skyvern should be polling endpoint for 2FA codes + + totp_identifier : typing.Optional[str] + Identifier for TOTP (Time-based One-Time Password) authentication if codes are being pushed to Skyvern + + browser_session_id : typing.Optional[str] + ID of an existing browser session to reuse, having it continue from the current screen state + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + WorkflowRunResponse + Successfully run workflow + + Examples + -------- + import asyncio + + from skyvern import AsyncSkyvern + + client = AsyncSkyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + + + async def main() -> None: + await client.agent.run_workflow( + workflow_id="workflow_id", + ) + + + asyncio.run(main()) + """ + _response = await self._client_wrapper.httpx_client.request( + "v1/run/workflows", + method="POST", + params={ + "template": template, + }, + json={ + "workflow_id": workflow_id, + "title": title, + "parameters": parameters, + "proxy_location": proxy_location, + "webhook_url": webhook_url, + "totp_url": totp_url, + "totp_identifier": totp_identifier, + "browser_session_id": browser_session_id, + }, + headers={ + "x-max-steps-override": str(max_steps_override) if max_steps_override is not None else None, + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + WorkflowRunResponse, + parse_obj_as( + type_=WorkflowRunResponse, # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 400: + raise BadRequestError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, body=_response.text) + raise ApiError(status_code=_response.status_code, body=_response_json) + + async def cancel_run( + self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> typing.Optional[typing.Any]: + """ + Cancel a task or workflow run + + Parameters + ---------- + run_id : str + The id of the task run or the workflow run to cancel. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + typing.Optional[typing.Any] + Successful Response + + Examples + -------- + import asyncio + + from skyvern import AsyncSkyvern + + client = AsyncSkyvern( + api_key="YOUR_API_KEY", + authorization="YOUR_AUTHORIZATION", + ) + + + async def main() -> None: + await client.agent.cancel_run( + run_id="run_id", + ) + + + asyncio.run(main()) + """ + _response = await self._client_wrapper.httpx_client.request( + f"v1/runs/{jsonable_encoder(run_id)}/cancel", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore + object_=_response.json(), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + typing.cast( + typing.Optional[typing.Any], + parse_obj_as( + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) diff --git a/skyvern/client/agent/types/agent_get_run_response.py b/skyvern/client/agent/types/agent_get_run_response.py index fb371f4e..b44635d8 100644 --- a/skyvern/client/agent/types/agent_get_run_response.py +++ b/skyvern/client/agent/types/agent_get_run_response.py @@ -5,6 +5,7 @@ from ...core.pydantic_utilities import UniversalBaseModel import typing from ...types.run_status import RunStatus from ...types.output import Output +from ...types.file_info import FileInfo import datetime as dt from ...types.task_run_request import TaskRunRequest from ...core.pydantic_utilities import IS_PYDANTIC_V2 @@ -17,6 +18,8 @@ class AgentGetRunResponse_TaskV1(UniversalBaseModel): run_id: str status: RunStatus output: typing.Optional[Output] = None + downloaded_files: typing.Optional[typing.List[FileInfo]] = None + recording_url: typing.Optional[str] = None failure_reason: typing.Optional[str] = None created_at: dt.datetime modified_at: dt.datetime @@ -37,6 +40,8 @@ class AgentGetRunResponse_TaskV2(UniversalBaseModel): run_id: str status: RunStatus output: typing.Optional[Output] = None + downloaded_files: typing.Optional[typing.List[FileInfo]] = None + recording_url: typing.Optional[str] = None failure_reason: typing.Optional[str] = None created_at: dt.datetime modified_at: dt.datetime @@ -57,6 +62,8 @@ class AgentGetRunResponse_WorkflowRun(UniversalBaseModel): run_id: str status: RunStatus output: typing.Optional[Output] = None + downloaded_files: typing.Optional[typing.List[FileInfo]] = None + recording_url: typing.Optional[str] = None failure_reason: typing.Optional[str] = None created_at: dt.datetime modified_at: dt.datetime diff --git a/skyvern/client/browser_session/client.py b/skyvern/client/browser_session/client.py index 05ae441f..b81a7b09 100644 --- a/skyvern/client/browser_session/client.py +++ b/skyvern/client/browser_session/client.py @@ -9,7 +9,6 @@ from ..core.pydantic_utilities import parse_obj_as from ..errors.unauthorized_error import UnauthorizedError from ..errors.not_found_error import NotFoundError from ..errors.unprocessable_entity_error import UnprocessableEntityError -from ..types.http_validation_error import HttpValidationError from json.decoder import JSONDecodeError from ..core.api_error import ApiError from ..core.client_wrapper import AsyncClientWrapper @@ -86,9 +85,9 @@ class BrowserSessionClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -151,9 +150,9 @@ class BrowserSessionClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -216,9 +215,9 @@ class BrowserSessionClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -285,9 +284,9 @@ class BrowserSessionClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -377,9 +376,9 @@ class AsyncBrowserSessionClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -450,9 +449,9 @@ class AsyncBrowserSessionClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -523,9 +522,9 @@ class AsyncBrowserSessionClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) @@ -600,9 +599,9 @@ class AsyncBrowserSessionClient: if _response.status_code == 422: raise UnprocessableEntityError( typing.cast( - HttpValidationError, + typing.Optional[typing.Any], parse_obj_as( - type_=HttpValidationError, # type: ignore + type_=typing.Optional[typing.Any], # type: ignore object_=_response.json(), ), ) diff --git a/skyvern/client/core/client_wrapper.py b/skyvern/client/core/client_wrapper.py index 35c53931..4ab5894b 100644 --- a/skyvern/client/core/client_wrapper.py +++ b/skyvern/client/core/client_wrapper.py @@ -24,7 +24,7 @@ class BaseClientWrapper: headers: typing.Dict[str, str] = { "X-Fern-Language": "Python", "X-Fern-SDK-Name": "skyvern", - "X-Fern-SDK-Version": "0.1.65", + "X-Fern-SDK-Version": "0.1.69", } if self._api_key is not None: headers["x-api-key"] = self._api_key diff --git a/skyvern/client/errors/unprocessable_entity_error.py b/skyvern/client/errors/unprocessable_entity_error.py index 47470a70..5666f362 100644 --- a/skyvern/client/errors/unprocessable_entity_error.py +++ b/skyvern/client/errors/unprocessable_entity_error.py @@ -1,9 +1,9 @@ # This file was auto-generated by Fern from our API Definition. from ..core.api_error import ApiError -from ..types.http_validation_error import HttpValidationError +import typing class UnprocessableEntityError(ApiError): - def __init__(self, body: HttpValidationError): + def __init__(self, body: typing.Optional[typing.Any]): super().__init__(status_code=422, body=body) diff --git a/skyvern/client/types/__init__.py b/skyvern/client/types/__init__.py index 8352d66c..5eafaeeb 100644 --- a/skyvern/client/types/__init__.py +++ b/skyvern/client/types/__init__.py @@ -1,31 +1,483 @@ # This file was auto-generated by Fern from our API Definition. +from .action_block import ActionBlock +from .action_block_data_schema import ActionBlockDataSchema +from .action_block_parameters_item import ( + ActionBlockParametersItem, + ActionBlockParametersItem_AwsSecret, + ActionBlockParametersItem_BitwardenCreditCardData, + ActionBlockParametersItem_BitwardenLoginCredential, + ActionBlockParametersItem_BitwardenSensitiveInformation, + ActionBlockParametersItem_Context, + ActionBlockParametersItem_Credential, + ActionBlockParametersItem_Output, + ActionBlockParametersItem_Workflow, +) +from .aws_secret_parameter import AwsSecretParameter +from .bitwarden_credit_card_data_parameter import BitwardenCreditCardDataParameter +from .bitwarden_login_credential_parameter import BitwardenLoginCredentialParameter +from .bitwarden_sensitive_information_parameter import BitwardenSensitiveInformationParameter from .browser_session_response import BrowserSessionResponse +from .code_block import CodeBlock +from .code_block_parameters_item import ( + CodeBlockParametersItem, + CodeBlockParametersItem_AwsSecret, + CodeBlockParametersItem_BitwardenCreditCardData, + CodeBlockParametersItem_BitwardenLoginCredential, + CodeBlockParametersItem_BitwardenSensitiveInformation, + CodeBlockParametersItem_Context, + CodeBlockParametersItem_Credential, + CodeBlockParametersItem_Output, + CodeBlockParametersItem_Workflow, +) +from .context_parameter import ContextParameter +from .credential_parameter import CredentialParameter +from .download_to_s3block import DownloadToS3Block +from .extraction_block import ExtractionBlock +from .extraction_block_data_schema import ExtractionBlockDataSchema +from .extraction_block_parameters_item import ( + ExtractionBlockParametersItem, + ExtractionBlockParametersItem_AwsSecret, + ExtractionBlockParametersItem_BitwardenCreditCardData, + ExtractionBlockParametersItem_BitwardenLoginCredential, + ExtractionBlockParametersItem_BitwardenSensitiveInformation, + ExtractionBlockParametersItem_Context, + ExtractionBlockParametersItem_Credential, + ExtractionBlockParametersItem_Output, + ExtractionBlockParametersItem_Workflow, +) +from .file_download_block import FileDownloadBlock +from .file_download_block_data_schema import FileDownloadBlockDataSchema +from .file_download_block_parameters_item import ( + FileDownloadBlockParametersItem, + FileDownloadBlockParametersItem_AwsSecret, + FileDownloadBlockParametersItem_BitwardenCreditCardData, + FileDownloadBlockParametersItem_BitwardenLoginCredential, + FileDownloadBlockParametersItem_BitwardenSensitiveInformation, + FileDownloadBlockParametersItem_Context, + FileDownloadBlockParametersItem_Credential, + FileDownloadBlockParametersItem_Output, + FileDownloadBlockParametersItem_Workflow, +) +from .file_info import FileInfo +from .file_parser_block import FileParserBlock +from .file_storage_type import FileStorageType +from .file_type import FileType +from .file_upload_block import FileUploadBlock +from .for_loop_block import ForLoopBlock +from .for_loop_block_loop_blocks_item import ( + ForLoopBlockLoopBlocksItem, + ForLoopBlockLoopBlocksItem_Action, + ForLoopBlockLoopBlocksItem_Code, + ForLoopBlockLoopBlocksItem_DownloadToS3, + ForLoopBlockLoopBlocksItem_Extraction, + ForLoopBlockLoopBlocksItem_FileDownload, + ForLoopBlockLoopBlocksItem_FileUpload, + ForLoopBlockLoopBlocksItem_FileUrlParser, + ForLoopBlockLoopBlocksItem_ForLoop, + ForLoopBlockLoopBlocksItem_GotoUrl, + ForLoopBlockLoopBlocksItem_Login, + ForLoopBlockLoopBlocksItem_Navigation, + ForLoopBlockLoopBlocksItem_PdfParser, + ForLoopBlockLoopBlocksItem_SendEmail, + ForLoopBlockLoopBlocksItem_Task, + ForLoopBlockLoopBlocksItem_TaskV2, + ForLoopBlockLoopBlocksItem_TextPrompt, + ForLoopBlockLoopBlocksItem_UploadToS3, + ForLoopBlockLoopBlocksItem_Validation, + ForLoopBlockLoopBlocksItem_Wait, +) +from .for_loop_block_loop_over import ( + ForLoopBlockLoopOver, + ForLoopBlockLoopOver_AwsSecret, + ForLoopBlockLoopOver_BitwardenCreditCardData, + ForLoopBlockLoopOver_BitwardenLoginCredential, + ForLoopBlockLoopOver_BitwardenSensitiveInformation, + ForLoopBlockLoopOver_Context, + ForLoopBlockLoopOver_Credential, + ForLoopBlockLoopOver_Output, + ForLoopBlockLoopOver_Workflow, +) from .http_validation_error import HttpValidationError +from .login_block import LoginBlock +from .login_block_data_schema import LoginBlockDataSchema +from .login_block_parameters_item import ( + LoginBlockParametersItem, + LoginBlockParametersItem_AwsSecret, + LoginBlockParametersItem_BitwardenCreditCardData, + LoginBlockParametersItem_BitwardenLoginCredential, + LoginBlockParametersItem_BitwardenSensitiveInformation, + LoginBlockParametersItem_Context, + LoginBlockParametersItem_Credential, + LoginBlockParametersItem_Output, + LoginBlockParametersItem_Workflow, +) +from .navigation_block import NavigationBlock +from .navigation_block_data_schema import NavigationBlockDataSchema +from .navigation_block_parameters_item import ( + NavigationBlockParametersItem, + NavigationBlockParametersItem_AwsSecret, + NavigationBlockParametersItem_BitwardenCreditCardData, + NavigationBlockParametersItem_BitwardenLoginCredential, + NavigationBlockParametersItem_BitwardenSensitiveInformation, + NavigationBlockParametersItem_Context, + NavigationBlockParametersItem_Credential, + NavigationBlockParametersItem_Output, + NavigationBlockParametersItem_Workflow, +) from .output import Output +from .output_parameter import OutputParameter +from .pdf_parser_block import PdfParserBlock from .proxy_location import ProxyLocation from .run_engine import RunEngine from .run_status import RunStatus +from .send_email_block import SendEmailBlock +from .source import ( + Source, + Source_AwsSecret, + Source_BitwardenCreditCardData, + Source_BitwardenLoginCredential, + Source_BitwardenSensitiveInformation, + Source_Context, + Source_Credential, + Source_Output, + Source_Workflow, +) +from .task_block import TaskBlock +from .task_block_data_schema import TaskBlockDataSchema +from .task_block_parameters_item import ( + TaskBlockParametersItem, + TaskBlockParametersItem_AwsSecret, + TaskBlockParametersItem_BitwardenCreditCardData, + TaskBlockParametersItem_BitwardenLoginCredential, + TaskBlockParametersItem_BitwardenSensitiveInformation, + TaskBlockParametersItem_Context, + TaskBlockParametersItem_Credential, + TaskBlockParametersItem_Output, + TaskBlockParametersItem_Workflow, +) from .task_run_request import TaskRunRequest from .task_run_request_data_extraction_schema import TaskRunRequestDataExtractionSchema from .task_run_response import TaskRunResponse +from .task_v2block import TaskV2Block +from .text_prompt_block import TextPromptBlock +from .text_prompt_block_parameters_item import ( + TextPromptBlockParametersItem, + TextPromptBlockParametersItem_AwsSecret, + TextPromptBlockParametersItem_BitwardenCreditCardData, + TextPromptBlockParametersItem_BitwardenLoginCredential, + TextPromptBlockParametersItem_BitwardenSensitiveInformation, + TextPromptBlockParametersItem_Context, + TextPromptBlockParametersItem_Credential, + TextPromptBlockParametersItem_Output, + TextPromptBlockParametersItem_Workflow, +) +from .upload_to_s3block import UploadToS3Block +from .url_block import UrlBlock +from .url_block_data_schema import UrlBlockDataSchema +from .url_block_parameters_item import ( + UrlBlockParametersItem, + UrlBlockParametersItem_AwsSecret, + UrlBlockParametersItem_BitwardenCreditCardData, + UrlBlockParametersItem_BitwardenLoginCredential, + UrlBlockParametersItem_BitwardenSensitiveInformation, + UrlBlockParametersItem_Context, + UrlBlockParametersItem_Credential, + UrlBlockParametersItem_Output, + UrlBlockParametersItem_Workflow, +) +from .validation_block import ValidationBlock +from .validation_block_data_schema import ValidationBlockDataSchema +from .validation_block_parameters_item import ( + ValidationBlockParametersItem, + ValidationBlockParametersItem_AwsSecret, + ValidationBlockParametersItem_BitwardenCreditCardData, + ValidationBlockParametersItem_BitwardenLoginCredential, + ValidationBlockParametersItem_BitwardenSensitiveInformation, + ValidationBlockParametersItem_Context, + ValidationBlockParametersItem_Credential, + ValidationBlockParametersItem_Output, + ValidationBlockParametersItem_Workflow, +) from .validation_error import ValidationError from .validation_error_loc_item import ValidationErrorLocItem +from .value import Value +from .wait_block import WaitBlock +from .wait_block_parameters_item import ( + WaitBlockParametersItem, + WaitBlockParametersItem_AwsSecret, + WaitBlockParametersItem_BitwardenCreditCardData, + WaitBlockParametersItem_BitwardenLoginCredential, + WaitBlockParametersItem_BitwardenSensitiveInformation, + WaitBlockParametersItem_Context, + WaitBlockParametersItem_Credential, + WaitBlockParametersItem_Output, + WaitBlockParametersItem_Workflow, +) +from .workflow import Workflow +from .workflow_definition import WorkflowDefinition +from .workflow_definition_blocks_item import ( + WorkflowDefinitionBlocksItem, + WorkflowDefinitionBlocksItem_Action, + WorkflowDefinitionBlocksItem_Code, + WorkflowDefinitionBlocksItem_DownloadToS3, + WorkflowDefinitionBlocksItem_Extraction, + WorkflowDefinitionBlocksItem_FileDownload, + WorkflowDefinitionBlocksItem_FileUpload, + WorkflowDefinitionBlocksItem_FileUrlParser, + WorkflowDefinitionBlocksItem_ForLoop, + WorkflowDefinitionBlocksItem_GotoUrl, + WorkflowDefinitionBlocksItem_Login, + WorkflowDefinitionBlocksItem_Navigation, + WorkflowDefinitionBlocksItem_PdfParser, + WorkflowDefinitionBlocksItem_SendEmail, + WorkflowDefinitionBlocksItem_Task, + WorkflowDefinitionBlocksItem_TaskV2, + WorkflowDefinitionBlocksItem_TextPrompt, + WorkflowDefinitionBlocksItem_UploadToS3, + WorkflowDefinitionBlocksItem_Validation, + WorkflowDefinitionBlocksItem_Wait, +) +from .workflow_definition_parameters_item import ( + WorkflowDefinitionParametersItem, + WorkflowDefinitionParametersItem_AwsSecret, + WorkflowDefinitionParametersItem_BitwardenCreditCardData, + WorkflowDefinitionParametersItem_BitwardenLoginCredential, + WorkflowDefinitionParametersItem_BitwardenSensitiveInformation, + WorkflowDefinitionParametersItem_Context, + WorkflowDefinitionParametersItem_Credential, + WorkflowDefinitionParametersItem_Output, + WorkflowDefinitionParametersItem_Workflow, +) +from .workflow_parameter import WorkflowParameter +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from .workflow_parameter_type import WorkflowParameterType from .workflow_run_request import WorkflowRunRequest from .workflow_run_response import WorkflowRunResponse +from .workflow_status import WorkflowStatus __all__ = [ + "ActionBlock", + "ActionBlockDataSchema", + "ActionBlockParametersItem", + "ActionBlockParametersItem_AwsSecret", + "ActionBlockParametersItem_BitwardenCreditCardData", + "ActionBlockParametersItem_BitwardenLoginCredential", + "ActionBlockParametersItem_BitwardenSensitiveInformation", + "ActionBlockParametersItem_Context", + "ActionBlockParametersItem_Credential", + "ActionBlockParametersItem_Output", + "ActionBlockParametersItem_Workflow", + "AwsSecretParameter", + "BitwardenCreditCardDataParameter", + "BitwardenLoginCredentialParameter", + "BitwardenSensitiveInformationParameter", "BrowserSessionResponse", + "CodeBlock", + "CodeBlockParametersItem", + "CodeBlockParametersItem_AwsSecret", + "CodeBlockParametersItem_BitwardenCreditCardData", + "CodeBlockParametersItem_BitwardenLoginCredential", + "CodeBlockParametersItem_BitwardenSensitiveInformation", + "CodeBlockParametersItem_Context", + "CodeBlockParametersItem_Credential", + "CodeBlockParametersItem_Output", + "CodeBlockParametersItem_Workflow", + "ContextParameter", + "CredentialParameter", + "DownloadToS3Block", + "ExtractionBlock", + "ExtractionBlockDataSchema", + "ExtractionBlockParametersItem", + "ExtractionBlockParametersItem_AwsSecret", + "ExtractionBlockParametersItem_BitwardenCreditCardData", + "ExtractionBlockParametersItem_BitwardenLoginCredential", + "ExtractionBlockParametersItem_BitwardenSensitiveInformation", + "ExtractionBlockParametersItem_Context", + "ExtractionBlockParametersItem_Credential", + "ExtractionBlockParametersItem_Output", + "ExtractionBlockParametersItem_Workflow", + "FileDownloadBlock", + "FileDownloadBlockDataSchema", + "FileDownloadBlockParametersItem", + "FileDownloadBlockParametersItem_AwsSecret", + "FileDownloadBlockParametersItem_BitwardenCreditCardData", + "FileDownloadBlockParametersItem_BitwardenLoginCredential", + "FileDownloadBlockParametersItem_BitwardenSensitiveInformation", + "FileDownloadBlockParametersItem_Context", + "FileDownloadBlockParametersItem_Credential", + "FileDownloadBlockParametersItem_Output", + "FileDownloadBlockParametersItem_Workflow", + "FileInfo", + "FileParserBlock", + "FileStorageType", + "FileType", + "FileUploadBlock", + "ForLoopBlock", + "ForLoopBlockLoopBlocksItem", + "ForLoopBlockLoopBlocksItem_Action", + "ForLoopBlockLoopBlocksItem_Code", + "ForLoopBlockLoopBlocksItem_DownloadToS3", + "ForLoopBlockLoopBlocksItem_Extraction", + "ForLoopBlockLoopBlocksItem_FileDownload", + "ForLoopBlockLoopBlocksItem_FileUpload", + "ForLoopBlockLoopBlocksItem_FileUrlParser", + "ForLoopBlockLoopBlocksItem_ForLoop", + "ForLoopBlockLoopBlocksItem_GotoUrl", + "ForLoopBlockLoopBlocksItem_Login", + "ForLoopBlockLoopBlocksItem_Navigation", + "ForLoopBlockLoopBlocksItem_PdfParser", + "ForLoopBlockLoopBlocksItem_SendEmail", + "ForLoopBlockLoopBlocksItem_Task", + "ForLoopBlockLoopBlocksItem_TaskV2", + "ForLoopBlockLoopBlocksItem_TextPrompt", + "ForLoopBlockLoopBlocksItem_UploadToS3", + "ForLoopBlockLoopBlocksItem_Validation", + "ForLoopBlockLoopBlocksItem_Wait", + "ForLoopBlockLoopOver", + "ForLoopBlockLoopOver_AwsSecret", + "ForLoopBlockLoopOver_BitwardenCreditCardData", + "ForLoopBlockLoopOver_BitwardenLoginCredential", + "ForLoopBlockLoopOver_BitwardenSensitiveInformation", + "ForLoopBlockLoopOver_Context", + "ForLoopBlockLoopOver_Credential", + "ForLoopBlockLoopOver_Output", + "ForLoopBlockLoopOver_Workflow", "HttpValidationError", + "LoginBlock", + "LoginBlockDataSchema", + "LoginBlockParametersItem", + "LoginBlockParametersItem_AwsSecret", + "LoginBlockParametersItem_BitwardenCreditCardData", + "LoginBlockParametersItem_BitwardenLoginCredential", + "LoginBlockParametersItem_BitwardenSensitiveInformation", + "LoginBlockParametersItem_Context", + "LoginBlockParametersItem_Credential", + "LoginBlockParametersItem_Output", + "LoginBlockParametersItem_Workflow", + "NavigationBlock", + "NavigationBlockDataSchema", + "NavigationBlockParametersItem", + "NavigationBlockParametersItem_AwsSecret", + "NavigationBlockParametersItem_BitwardenCreditCardData", + "NavigationBlockParametersItem_BitwardenLoginCredential", + "NavigationBlockParametersItem_BitwardenSensitiveInformation", + "NavigationBlockParametersItem_Context", + "NavigationBlockParametersItem_Credential", + "NavigationBlockParametersItem_Output", + "NavigationBlockParametersItem_Workflow", "Output", + "OutputParameter", + "PdfParserBlock", "ProxyLocation", "RunEngine", "RunStatus", + "SendEmailBlock", + "Source", + "Source_AwsSecret", + "Source_BitwardenCreditCardData", + "Source_BitwardenLoginCredential", + "Source_BitwardenSensitiveInformation", + "Source_Context", + "Source_Credential", + "Source_Output", + "Source_Workflow", + "TaskBlock", + "TaskBlockDataSchema", + "TaskBlockParametersItem", + "TaskBlockParametersItem_AwsSecret", + "TaskBlockParametersItem_BitwardenCreditCardData", + "TaskBlockParametersItem_BitwardenLoginCredential", + "TaskBlockParametersItem_BitwardenSensitiveInformation", + "TaskBlockParametersItem_Context", + "TaskBlockParametersItem_Credential", + "TaskBlockParametersItem_Output", + "TaskBlockParametersItem_Workflow", "TaskRunRequest", "TaskRunRequestDataExtractionSchema", "TaskRunResponse", + "TaskV2Block", + "TextPromptBlock", + "TextPromptBlockParametersItem", + "TextPromptBlockParametersItem_AwsSecret", + "TextPromptBlockParametersItem_BitwardenCreditCardData", + "TextPromptBlockParametersItem_BitwardenLoginCredential", + "TextPromptBlockParametersItem_BitwardenSensitiveInformation", + "TextPromptBlockParametersItem_Context", + "TextPromptBlockParametersItem_Credential", + "TextPromptBlockParametersItem_Output", + "TextPromptBlockParametersItem_Workflow", + "UploadToS3Block", + "UrlBlock", + "UrlBlockDataSchema", + "UrlBlockParametersItem", + "UrlBlockParametersItem_AwsSecret", + "UrlBlockParametersItem_BitwardenCreditCardData", + "UrlBlockParametersItem_BitwardenLoginCredential", + "UrlBlockParametersItem_BitwardenSensitiveInformation", + "UrlBlockParametersItem_Context", + "UrlBlockParametersItem_Credential", + "UrlBlockParametersItem_Output", + "UrlBlockParametersItem_Workflow", + "ValidationBlock", + "ValidationBlockDataSchema", + "ValidationBlockParametersItem", + "ValidationBlockParametersItem_AwsSecret", + "ValidationBlockParametersItem_BitwardenCreditCardData", + "ValidationBlockParametersItem_BitwardenLoginCredential", + "ValidationBlockParametersItem_BitwardenSensitiveInformation", + "ValidationBlockParametersItem_Context", + "ValidationBlockParametersItem_Credential", + "ValidationBlockParametersItem_Output", + "ValidationBlockParametersItem_Workflow", "ValidationError", "ValidationErrorLocItem", + "Value", + "WaitBlock", + "WaitBlockParametersItem", + "WaitBlockParametersItem_AwsSecret", + "WaitBlockParametersItem_BitwardenCreditCardData", + "WaitBlockParametersItem_BitwardenLoginCredential", + "WaitBlockParametersItem_BitwardenSensitiveInformation", + "WaitBlockParametersItem_Context", + "WaitBlockParametersItem_Credential", + "WaitBlockParametersItem_Output", + "WaitBlockParametersItem_Workflow", + "Workflow", + "WorkflowDefinition", + "WorkflowDefinitionBlocksItem", + "WorkflowDefinitionBlocksItem_Action", + "WorkflowDefinitionBlocksItem_Code", + "WorkflowDefinitionBlocksItem_DownloadToS3", + "WorkflowDefinitionBlocksItem_Extraction", + "WorkflowDefinitionBlocksItem_FileDownload", + "WorkflowDefinitionBlocksItem_FileUpload", + "WorkflowDefinitionBlocksItem_FileUrlParser", + "WorkflowDefinitionBlocksItem_ForLoop", + "WorkflowDefinitionBlocksItem_GotoUrl", + "WorkflowDefinitionBlocksItem_Login", + "WorkflowDefinitionBlocksItem_Navigation", + "WorkflowDefinitionBlocksItem_PdfParser", + "WorkflowDefinitionBlocksItem_SendEmail", + "WorkflowDefinitionBlocksItem_Task", + "WorkflowDefinitionBlocksItem_TaskV2", + "WorkflowDefinitionBlocksItem_TextPrompt", + "WorkflowDefinitionBlocksItem_UploadToS3", + "WorkflowDefinitionBlocksItem_Validation", + "WorkflowDefinitionBlocksItem_Wait", + "WorkflowDefinitionParametersItem", + "WorkflowDefinitionParametersItem_AwsSecret", + "WorkflowDefinitionParametersItem_BitwardenCreditCardData", + "WorkflowDefinitionParametersItem_BitwardenLoginCredential", + "WorkflowDefinitionParametersItem_BitwardenSensitiveInformation", + "WorkflowDefinitionParametersItem_Context", + "WorkflowDefinitionParametersItem_Credential", + "WorkflowDefinitionParametersItem_Output", + "WorkflowDefinitionParametersItem_Workflow", + "WorkflowParameter", + "WorkflowParameterDefaultValue", + "WorkflowParameterType", "WorkflowRunRequest", "WorkflowRunResponse", + "WorkflowStatus", ] diff --git a/skyvern/client/types/action_block.py b/skyvern/client/types/action_block.py new file mode 100644 index 00000000..65b4277e --- /dev/null +++ b/skyvern/client/types/action_block.py @@ -0,0 +1,43 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .action_block_data_schema import ActionBlockDataSchema +from .action_block_parameters_item import ActionBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class ActionBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[ActionBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ActionBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/action_block_data_schema.py b/skyvern/client/types/action_block_data_schema.py new file mode 100644 index 00000000..7436fc08 --- /dev/null +++ b/skyvern/client/types/action_block_data_schema.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ActionBlockDataSchema = typing.Union[ + typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/action_block_parameters_item.py b/skyvern/client/types/action_block_parameters_item.py new file mode 100644 index 00000000..761b44e1 --- /dev/null +++ b/skyvern/client/types/action_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class ActionBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ActionBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ActionBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ActionBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ActionBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class ActionBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ActionBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ActionBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +ActionBlockParametersItem = typing.Union[ + ActionBlockParametersItem_AwsSecret, + ActionBlockParametersItem_BitwardenCreditCardData, + ActionBlockParametersItem_BitwardenLoginCredential, + ActionBlockParametersItem_BitwardenSensitiveInformation, + ActionBlockParametersItem_Context, + ActionBlockParametersItem_Credential, + ActionBlockParametersItem_Output, + ActionBlockParametersItem_Workflow, +] +update_forward_refs(ActionBlockParametersItem_Context) diff --git a/skyvern/client/types/aws_secret_parameter.py b/skyvern/client/types/aws_secret_parameter.py new file mode 100644 index 00000000..990763d2 --- /dev/null +++ b/skyvern/client/types/aws_secret_parameter.py @@ -0,0 +1,27 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class AwsSecretParameter(UniversalBaseModel): + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/bitwarden_credit_card_data_parameter.py b/skyvern/client/types/bitwarden_credit_card_data_parameter.py new file mode 100644 index 00000000..14d373e2 --- /dev/null +++ b/skyvern/client/types/bitwarden_credit_card_data_parameter.py @@ -0,0 +1,31 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class BitwardenCreditCardDataParameter(UniversalBaseModel): + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/bitwarden_login_credential_parameter.py b/skyvern/client/types/bitwarden_login_credential_parameter.py new file mode 100644 index 00000000..349cd2f1 --- /dev/null +++ b/skyvern/client/types/bitwarden_login_credential_parameter.py @@ -0,0 +1,32 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class BitwardenLoginCredentialParameter(UniversalBaseModel): + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/bitwarden_sensitive_information_parameter.py b/skyvern/client/types/bitwarden_sensitive_information_parameter.py new file mode 100644 index 00000000..2047780b --- /dev/null +++ b/skyvern/client/types/bitwarden_sensitive_information_parameter.py @@ -0,0 +1,32 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class BitwardenSensitiveInformationParameter(UniversalBaseModel): + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/code_block.py b/skyvern/client/types/code_block.py new file mode 100644 index 00000000..acf0ae03 --- /dev/null +++ b/skyvern/client/types/code_block.py @@ -0,0 +1,26 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .code_block_parameters_item import CodeBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class CodeBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + code: str + parameters: typing.Optional[typing.List[CodeBlockParametersItem]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/code_block_parameters_item.py b/skyvern/client/types/code_block_parameters_item.py new file mode 100644 index 00000000..54f5fc40 --- /dev/null +++ b/skyvern/client/types/code_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class CodeBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class CodeBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class CodeBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class CodeBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class CodeBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class CodeBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class CodeBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class CodeBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +CodeBlockParametersItem = typing.Union[ + CodeBlockParametersItem_AwsSecret, + CodeBlockParametersItem_BitwardenCreditCardData, + CodeBlockParametersItem_BitwardenLoginCredential, + CodeBlockParametersItem_BitwardenSensitiveInformation, + CodeBlockParametersItem_Context, + CodeBlockParametersItem_Credential, + CodeBlockParametersItem_Output, + CodeBlockParametersItem_Workflow, +] +update_forward_refs(CodeBlockParametersItem_Context) diff --git a/skyvern/client/types/context_parameter.py b/skyvern/client/types/context_parameter.py new file mode 100644 index 00000000..48fa1aae --- /dev/null +++ b/skyvern/client/types/context_parameter.py @@ -0,0 +1,30 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +from .value import Value +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from ..core.pydantic_utilities import update_forward_refs + + +class ContextParameter(UniversalBaseModel): + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .source import Source # noqa: E402 + +update_forward_refs(ContextParameter) diff --git a/skyvern/client/types/credential_parameter.py b/skyvern/client/types/credential_parameter.py new file mode 100644 index 00000000..1fcca362 --- /dev/null +++ b/skyvern/client/types/credential_parameter.py @@ -0,0 +1,27 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class CredentialParameter(UniversalBaseModel): + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/download_to_s3block.py b/skyvern/client/types/download_to_s3block.py new file mode 100644 index 00000000..b68cb0d1 --- /dev/null +++ b/skyvern/client/types/download_to_s3block.py @@ -0,0 +1,23 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .output_parameter import OutputParameter +import typing +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class DownloadToS3Block(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + url: str + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/extraction_block.py b/skyvern/client/types/extraction_block.py new file mode 100644 index 00000000..5656b1de --- /dev/null +++ b/skyvern/client/types/extraction_block.py @@ -0,0 +1,43 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .extraction_block_data_schema import ExtractionBlockDataSchema +from .extraction_block_parameters_item import ExtractionBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class ExtractionBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: str + data_schema: typing.Optional[ExtractionBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ExtractionBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/extraction_block_data_schema.py b/skyvern/client/types/extraction_block_data_schema.py new file mode 100644 index 00000000..6ec1bb8e --- /dev/null +++ b/skyvern/client/types/extraction_block_data_schema.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ExtractionBlockDataSchema = typing.Union[ + typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/extraction_block_parameters_item.py b/skyvern/client/types/extraction_block_parameters_item.py new file mode 100644 index 00000000..cd6babe0 --- /dev/null +++ b/skyvern/client/types/extraction_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class ExtractionBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ExtractionBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ExtractionBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ExtractionBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ExtractionBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class ExtractionBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ExtractionBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ExtractionBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +ExtractionBlockParametersItem = typing.Union[ + ExtractionBlockParametersItem_AwsSecret, + ExtractionBlockParametersItem_BitwardenCreditCardData, + ExtractionBlockParametersItem_BitwardenLoginCredential, + ExtractionBlockParametersItem_BitwardenSensitiveInformation, + ExtractionBlockParametersItem_Context, + ExtractionBlockParametersItem_Credential, + ExtractionBlockParametersItem_Output, + ExtractionBlockParametersItem_Workflow, +] +update_forward_refs(ExtractionBlockParametersItem_Context) diff --git a/skyvern/client/types/file_download_block.py b/skyvern/client/types/file_download_block.py new file mode 100644 index 00000000..49995244 --- /dev/null +++ b/skyvern/client/types/file_download_block.py @@ -0,0 +1,43 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .file_download_block_data_schema import FileDownloadBlockDataSchema +from .file_download_block_parameters_item import FileDownloadBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class FileDownloadBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[FileDownloadBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[FileDownloadBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/file_download_block_data_schema.py b/skyvern/client/types/file_download_block_data_schema.py new file mode 100644 index 00000000..589b7bee --- /dev/null +++ b/skyvern/client/types/file_download_block_data_schema.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +FileDownloadBlockDataSchema = typing.Union[ + typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/file_download_block_parameters_item.py b/skyvern/client/types/file_download_block_parameters_item.py new file mode 100644 index 00000000..04004d8a --- /dev/null +++ b/skyvern/client/types/file_download_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class FileDownloadBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class FileDownloadBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class FileDownloadBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class FileDownloadBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class FileDownloadBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class FileDownloadBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class FileDownloadBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class FileDownloadBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +FileDownloadBlockParametersItem = typing.Union[ + FileDownloadBlockParametersItem_AwsSecret, + FileDownloadBlockParametersItem_BitwardenCreditCardData, + FileDownloadBlockParametersItem_BitwardenLoginCredential, + FileDownloadBlockParametersItem_BitwardenSensitiveInformation, + FileDownloadBlockParametersItem_Context, + FileDownloadBlockParametersItem_Credential, + FileDownloadBlockParametersItem_Output, + FileDownloadBlockParametersItem_Workflow, +] +update_forward_refs(FileDownloadBlockParametersItem_Context) diff --git a/skyvern/client/types/file_info.py b/skyvern/client/types/file_info.py new file mode 100644 index 00000000..90aefad3 --- /dev/null +++ b/skyvern/client/types/file_info.py @@ -0,0 +1,36 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +import pydantic +import typing +from ..core.pydantic_utilities import IS_PYDANTIC_V2 + + +class FileInfo(UniversalBaseModel): + """ + Information about a downloaded file, including URL and checksum. + """ + + url: str = pydantic.Field() + """ + URL to access the file + """ + + checksum: typing.Optional[str] = pydantic.Field(default=None) + """ + SHA-256 checksum of the file + """ + + filename: typing.Optional[str] = pydantic.Field(default=None) + """ + Original filename + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/file_parser_block.py b/skyvern/client/types/file_parser_block.py new file mode 100644 index 00000000..26ac34fe --- /dev/null +++ b/skyvern/client/types/file_parser_block.py @@ -0,0 +1,25 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .output_parameter import OutputParameter +import typing +from .file_type import FileType +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class FileParserBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + file_url: str + file_type: FileType = "csv" + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/file_storage_type.py b/skyvern/client/types/file_storage_type.py new file mode 100644 index 00000000..132c3ca8 --- /dev/null +++ b/skyvern/client/types/file_storage_type.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +FileStorageType = typing.Literal["s3"] diff --git a/skyvern/client/types/file_type.py b/skyvern/client/types/file_type.py new file mode 100644 index 00000000..0c5b2d3c --- /dev/null +++ b/skyvern/client/types/file_type.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +FileType = typing.Literal["csv"] diff --git a/skyvern/client/types/file_upload_block.py b/skyvern/client/types/file_upload_block.py new file mode 100644 index 00000000..75954aa6 --- /dev/null +++ b/skyvern/client/types/file_upload_block.py @@ -0,0 +1,31 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .output_parameter import OutputParameter +import typing +from .file_storage_type import FileStorageType +import typing_extensions +from ..core.serialization import FieldMetadata +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class FileUploadBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + storage_type: typing.Optional[FileStorageType] = None + s3bucket: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="s3_bucket")] = None + aws_access_key_id: typing.Optional[str] = None + aws_secret_access_key: typing.Optional[str] = None + region_name: typing.Optional[str] = None + path: typing.Optional[str] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/for_loop_block.py b/skyvern/client/types/for_loop_block.py new file mode 100644 index 00000000..8b666de7 --- /dev/null +++ b/skyvern/client/types/for_loop_block.py @@ -0,0 +1,35 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .for_loop_block_loop_over import ForLoopBlockLoopOver +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from ..core.pydantic_utilities import update_forward_refs + + +class ForLoopBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + loop_blocks: typing.List["ForLoopBlockLoopBlocksItem"] + loop_over: typing.Optional[ForLoopBlockLoopOver] = None + loop_variable_reference: typing.Optional[str] = None + complete_if_empty: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .for_loop_block_loop_blocks_item import ForLoopBlockLoopBlocksItem # noqa: E402 + +update_forward_refs(ForLoopBlock) diff --git a/skyvern/client/types/for_loop_block_loop_blocks_item.py b/skyvern/client/types/for_loop_block_loop_blocks_item.py new file mode 100644 index 00000000..cf6dca81 --- /dev/null +++ b/skyvern/client/types/for_loop_block_loop_blocks_item.py @@ -0,0 +1,549 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +import typing +from .output_parameter import OutputParameter +from .action_block_data_schema import ActionBlockDataSchema +from .action_block_parameters_item import ActionBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .code_block_parameters_item import CodeBlockParametersItem +from .extraction_block_data_schema import ExtractionBlockDataSchema +from .extraction_block_parameters_item import ExtractionBlockParametersItem +from .file_download_block_data_schema import FileDownloadBlockDataSchema +from .file_download_block_parameters_item import FileDownloadBlockParametersItem +from .file_storage_type import FileStorageType +import typing_extensions +from ..core.serialization import FieldMetadata +from .file_type import FileType +from .for_loop_block_loop_over import ForLoopBlockLoopOver +from .url_block_data_schema import UrlBlockDataSchema +from .url_block_parameters_item import UrlBlockParametersItem +from .login_block_data_schema import LoginBlockDataSchema +from .login_block_parameters_item import LoginBlockParametersItem +from .navigation_block_data_schema import NavigationBlockDataSchema +from .navigation_block_parameters_item import NavigationBlockParametersItem +from .aws_secret_parameter import AwsSecretParameter +from .task_block_data_schema import TaskBlockDataSchema +from .task_block_parameters_item import TaskBlockParametersItem +from .text_prompt_block_parameters_item import TextPromptBlockParametersItem +from .validation_block_data_schema import ValidationBlockDataSchema +from .validation_block_parameters_item import ValidationBlockParametersItem +from .wait_block_parameters_item import WaitBlockParametersItem +from ..core.pydantic_utilities import update_forward_refs + + +class ForLoopBlockLoopBlocksItem_Action(UniversalBaseModel): + block_type: typing.Literal["action"] = "action" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[ActionBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ActionBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_Code(UniversalBaseModel): + block_type: typing.Literal["code"] = "code" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + code: str + parameters: typing.Optional[typing.List[CodeBlockParametersItem]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_DownloadToS3(UniversalBaseModel): + block_type: typing.Literal["download_to_s3"] = "download_to_s3" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + url: str + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_Extraction(UniversalBaseModel): + block_type: typing.Literal["extraction"] = "extraction" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: str + data_schema: typing.Optional[ExtractionBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ExtractionBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_FileDownload(UniversalBaseModel): + block_type: typing.Literal["file_download"] = "file_download" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[FileDownloadBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[FileDownloadBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_FileUpload(UniversalBaseModel): + block_type: typing.Literal["file_upload"] = "file_upload" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + storage_type: typing.Optional[FileStorageType] = None + s3bucket: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="s3_bucket")] = None + aws_access_key_id: typing.Optional[str] = None + aws_secret_access_key: typing.Optional[str] = None + region_name: typing.Optional[str] = None + path: typing.Optional[str] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_FileUrlParser(UniversalBaseModel): + block_type: typing.Literal["file_url_parser"] = "file_url_parser" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + file_url: str + file_type: FileType = "csv" + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_ForLoop(UniversalBaseModel): + block_type: typing.Literal["for_loop"] = "for_loop" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + loop_blocks: typing.List["ForLoopBlockLoopBlocksItem"] + loop_over: typing.Optional[ForLoopBlockLoopOver] = None + loop_variable_reference: typing.Optional[str] = None + complete_if_empty: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .for_loop_block import ForLoopBlock # noqa: E402 + + +class ForLoopBlockLoopBlocksItem_GotoUrl(UniversalBaseModel): + block_type: typing.Literal["goto_url"] = "goto_url" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: str + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[UrlBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[UrlBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_Login(UniversalBaseModel): + block_type: typing.Literal["login"] = "login" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[LoginBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[LoginBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_Navigation(UniversalBaseModel): + block_type: typing.Literal["navigation"] = "navigation" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: str + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[NavigationBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[NavigationBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_PdfParser(UniversalBaseModel): + block_type: typing.Literal["pdf_parser"] = "pdf_parser" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + file_url: str + json_schema: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_SendEmail(UniversalBaseModel): + block_type: typing.Literal["send_email"] = "send_email" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + smtp_host: AwsSecretParameter + smtp_port: AwsSecretParameter + smtp_username: AwsSecretParameter + smtp_password: AwsSecretParameter + sender: str + recipients: typing.List[str] + subject: str + body: str + file_attachments: typing.Optional[typing.List[str]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_Task(UniversalBaseModel): + block_type: typing.Literal["task"] = "task" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[TaskBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[TaskBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_TaskV2(UniversalBaseModel): + block_type: typing.Literal["task_v2"] = "task_v2" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + prompt: str + url: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + max_iterations: typing.Optional[int] = None + max_steps: typing.Optional[int] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_TextPrompt(UniversalBaseModel): + block_type: typing.Literal["text_prompt"] = "text_prompt" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + llm_key: typing.Optional[str] = None + prompt: str + parameters: typing.Optional[typing.List[TextPromptBlockParametersItem]] = None + json_schema: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_UploadToS3(UniversalBaseModel): + block_type: typing.Literal["upload_to_s3"] = "upload_to_s3" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + path: typing.Optional[str] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_Validation(UniversalBaseModel): + block_type: typing.Literal["validation"] = "validation" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[ValidationBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ValidationBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopBlocksItem_Wait(UniversalBaseModel): + block_type: typing.Literal["wait"] = "wait" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + wait_sec: int + parameters: typing.Optional[typing.List[WaitBlockParametersItem]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +ForLoopBlockLoopBlocksItem = typing.Union[ + ForLoopBlockLoopBlocksItem_Action, + ForLoopBlockLoopBlocksItem_Code, + ForLoopBlockLoopBlocksItem_DownloadToS3, + ForLoopBlockLoopBlocksItem_Extraction, + ForLoopBlockLoopBlocksItem_FileDownload, + ForLoopBlockLoopBlocksItem_FileUpload, + ForLoopBlockLoopBlocksItem_FileUrlParser, + ForLoopBlockLoopBlocksItem_ForLoop, + ForLoopBlockLoopBlocksItem_GotoUrl, + ForLoopBlockLoopBlocksItem_Login, + ForLoopBlockLoopBlocksItem_Navigation, + ForLoopBlockLoopBlocksItem_PdfParser, + ForLoopBlockLoopBlocksItem_SendEmail, + ForLoopBlockLoopBlocksItem_Task, + ForLoopBlockLoopBlocksItem_TaskV2, + ForLoopBlockLoopBlocksItem_TextPrompt, + ForLoopBlockLoopBlocksItem_UploadToS3, + ForLoopBlockLoopBlocksItem_Validation, + ForLoopBlockLoopBlocksItem_Wait, +] +update_forward_refs(ForLoopBlockLoopBlocksItem_ForLoop) diff --git a/skyvern/client/types/for_loop_block_loop_over.py b/skyvern/client/types/for_loop_block_loop_over.py new file mode 100644 index 00000000..95a58d9e --- /dev/null +++ b/skyvern/client/types/for_loop_block_loop_over.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class ForLoopBlockLoopOver_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopOver_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopOver_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopOver_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopOver_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class ForLoopBlockLoopOver_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopOver_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ForLoopBlockLoopOver_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +ForLoopBlockLoopOver = typing.Union[ + ForLoopBlockLoopOver_AwsSecret, + ForLoopBlockLoopOver_BitwardenCreditCardData, + ForLoopBlockLoopOver_BitwardenLoginCredential, + ForLoopBlockLoopOver_BitwardenSensitiveInformation, + ForLoopBlockLoopOver_Context, + ForLoopBlockLoopOver_Credential, + ForLoopBlockLoopOver_Output, + ForLoopBlockLoopOver_Workflow, +] +update_forward_refs(ForLoopBlockLoopOver_Context) diff --git a/skyvern/client/types/login_block.py b/skyvern/client/types/login_block.py new file mode 100644 index 00000000..602c5c8a --- /dev/null +++ b/skyvern/client/types/login_block.py @@ -0,0 +1,43 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .login_block_data_schema import LoginBlockDataSchema +from .login_block_parameters_item import LoginBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class LoginBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[LoginBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[LoginBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/login_block_data_schema.py b/skyvern/client/types/login_block_data_schema.py new file mode 100644 index 00000000..c8c9b523 --- /dev/null +++ b/skyvern/client/types/login_block_data_schema.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +LoginBlockDataSchema = typing.Union[ + typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/login_block_parameters_item.py b/skyvern/client/types/login_block_parameters_item.py new file mode 100644 index 00000000..615fc83f --- /dev/null +++ b/skyvern/client/types/login_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class LoginBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class LoginBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class LoginBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class LoginBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class LoginBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class LoginBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class LoginBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class LoginBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +LoginBlockParametersItem = typing.Union[ + LoginBlockParametersItem_AwsSecret, + LoginBlockParametersItem_BitwardenCreditCardData, + LoginBlockParametersItem_BitwardenLoginCredential, + LoginBlockParametersItem_BitwardenSensitiveInformation, + LoginBlockParametersItem_Context, + LoginBlockParametersItem_Credential, + LoginBlockParametersItem_Output, + LoginBlockParametersItem_Workflow, +] +update_forward_refs(LoginBlockParametersItem_Context) diff --git a/skyvern/client/types/navigation_block.py b/skyvern/client/types/navigation_block.py new file mode 100644 index 00000000..41cdbf25 --- /dev/null +++ b/skyvern/client/types/navigation_block.py @@ -0,0 +1,43 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .navigation_block_data_schema import NavigationBlockDataSchema +from .navigation_block_parameters_item import NavigationBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class NavigationBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: str + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[NavigationBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[NavigationBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/navigation_block_data_schema.py b/skyvern/client/types/navigation_block_data_schema.py new file mode 100644 index 00000000..685f5eea --- /dev/null +++ b/skyvern/client/types/navigation_block_data_schema.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +NavigationBlockDataSchema = typing.Union[ + typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/navigation_block_parameters_item.py b/skyvern/client/types/navigation_block_parameters_item.py new file mode 100644 index 00000000..47b123f2 --- /dev/null +++ b/skyvern/client/types/navigation_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class NavigationBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class NavigationBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class NavigationBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class NavigationBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class NavigationBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class NavigationBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class NavigationBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class NavigationBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +NavigationBlockParametersItem = typing.Union[ + NavigationBlockParametersItem_AwsSecret, + NavigationBlockParametersItem_BitwardenCreditCardData, + NavigationBlockParametersItem_BitwardenLoginCredential, + NavigationBlockParametersItem_BitwardenSensitiveInformation, + NavigationBlockParametersItem_Context, + NavigationBlockParametersItem_Credential, + NavigationBlockParametersItem_Output, + NavigationBlockParametersItem_Workflow, +] +update_forward_refs(NavigationBlockParametersItem_Context) diff --git a/skyvern/client/types/output_parameter.py b/skyvern/client/types/output_parameter.py new file mode 100644 index 00000000..35f89c96 --- /dev/null +++ b/skyvern/client/types/output_parameter.py @@ -0,0 +1,26 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class OutputParameter(UniversalBaseModel): + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/pdf_parser_block.py b/skyvern/client/types/pdf_parser_block.py new file mode 100644 index 00000000..3d1a5ce1 --- /dev/null +++ b/skyvern/client/types/pdf_parser_block.py @@ -0,0 +1,24 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .output_parameter import OutputParameter +import typing +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class PdfParserBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + file_url: str + json_schema: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/send_email_block.py b/skyvern/client/types/send_email_block.py new file mode 100644 index 00000000..d22bd6f4 --- /dev/null +++ b/skyvern/client/types/send_email_block.py @@ -0,0 +1,32 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .output_parameter import OutputParameter +import typing +from .aws_secret_parameter import AwsSecretParameter +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class SendEmailBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + smtp_host: AwsSecretParameter + smtp_port: AwsSecretParameter + smtp_username: AwsSecretParameter + smtp_password: AwsSecretParameter + sender: str + recipients: typing.List[str] + subject: str + body: str + file_attachments: typing.Optional[typing.List[str]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/source.py b/skyvern/client/types/source.py new file mode 100644 index 00000000..e3fbdf3e --- /dev/null +++ b/skyvern/client/types/source.py @@ -0,0 +1,206 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from ..core.pydantic_utilities import update_forward_refs + + +class Source_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class Source_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 + + +class Source_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class Source_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class Source_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class Source_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class Source_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class Source_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +Source = typing.Union[ + Source_Workflow, + Source_Context, + Source_AwsSecret, + Source_BitwardenLoginCredential, + Source_BitwardenSensitiveInformation, + Source_BitwardenCreditCardData, + Source_Output, + Source_Credential, +] +update_forward_refs(Source_Context) diff --git a/skyvern/client/types/task_block.py b/skyvern/client/types/task_block.py new file mode 100644 index 00000000..b90b391a --- /dev/null +++ b/skyvern/client/types/task_block.py @@ -0,0 +1,43 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .task_block_data_schema import TaskBlockDataSchema +from .task_block_parameters_item import TaskBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class TaskBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[TaskBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[TaskBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/task_block_data_schema.py b/skyvern/client/types/task_block_data_schema.py new file mode 100644 index 00000000..1724bc03 --- /dev/null +++ b/skyvern/client/types/task_block_data_schema.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +TaskBlockDataSchema = typing.Union[ + typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/task_block_parameters_item.py b/skyvern/client/types/task_block_parameters_item.py new file mode 100644 index 00000000..1bce86fa --- /dev/null +++ b/skyvern/client/types/task_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class TaskBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TaskBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TaskBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TaskBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TaskBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class TaskBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TaskBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TaskBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +TaskBlockParametersItem = typing.Union[ + TaskBlockParametersItem_AwsSecret, + TaskBlockParametersItem_BitwardenCreditCardData, + TaskBlockParametersItem_BitwardenLoginCredential, + TaskBlockParametersItem_BitwardenSensitiveInformation, + TaskBlockParametersItem_Context, + TaskBlockParametersItem_Credential, + TaskBlockParametersItem_Output, + TaskBlockParametersItem_Workflow, +] +update_forward_refs(TaskBlockParametersItem_Context) diff --git a/skyvern/client/types/task_run_response.py b/skyvern/client/types/task_run_response.py index 2b1c5a07..3be9f345 100644 --- a/skyvern/client/types/task_run_response.py +++ b/skyvern/client/types/task_run_response.py @@ -5,6 +5,7 @@ import pydantic from .run_status import RunStatus import typing from .output import Output +from .file_info import FileInfo import datetime as dt from .task_run_request import TaskRunRequest from ..core.pydantic_utilities import IS_PYDANTIC_V2 @@ -26,6 +27,16 @@ class TaskRunResponse(UniversalBaseModel): Output data from the run, if any. Format depends on the schema in the input """ + downloaded_files: typing.Optional[typing.List[FileInfo]] = pydantic.Field(default=None) + """ + List of files downloaded during the run + """ + + recording_url: typing.Optional[str] = pydantic.Field(default=None) + """ + URL to the recording of the run + """ + failure_reason: typing.Optional[str] = pydantic.Field(default=None) """ Reason for failure if the run failed diff --git a/skyvern/client/types/task_v2block.py b/skyvern/client/types/task_v2block.py new file mode 100644 index 00000000..4ac7484a --- /dev/null +++ b/skyvern/client/types/task_v2block.py @@ -0,0 +1,28 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .output_parameter import OutputParameter +import typing +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class TaskV2Block(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + prompt: str + url: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + max_iterations: typing.Optional[int] = None + max_steps: typing.Optional[int] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/text_prompt_block.py b/skyvern/client/types/text_prompt_block.py new file mode 100644 index 00000000..8295a83a --- /dev/null +++ b/skyvern/client/types/text_prompt_block.py @@ -0,0 +1,28 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .text_prompt_block_parameters_item import TextPromptBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class TextPromptBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + llm_key: typing.Optional[str] = None + prompt: str + parameters: typing.Optional[typing.List[TextPromptBlockParametersItem]] = None + json_schema: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/text_prompt_block_parameters_item.py b/skyvern/client/types/text_prompt_block_parameters_item.py new file mode 100644 index 00000000..0cc9250b --- /dev/null +++ b/skyvern/client/types/text_prompt_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class TextPromptBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TextPromptBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TextPromptBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TextPromptBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TextPromptBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class TextPromptBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TextPromptBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class TextPromptBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +TextPromptBlockParametersItem = typing.Union[ + TextPromptBlockParametersItem_AwsSecret, + TextPromptBlockParametersItem_BitwardenCreditCardData, + TextPromptBlockParametersItem_BitwardenLoginCredential, + TextPromptBlockParametersItem_BitwardenSensitiveInformation, + TextPromptBlockParametersItem_Context, + TextPromptBlockParametersItem_Credential, + TextPromptBlockParametersItem_Output, + TextPromptBlockParametersItem_Workflow, +] +update_forward_refs(TextPromptBlockParametersItem_Context) diff --git a/skyvern/client/types/upload_to_s3block.py b/skyvern/client/types/upload_to_s3block.py new file mode 100644 index 00000000..ba7c0d6a --- /dev/null +++ b/skyvern/client/types/upload_to_s3block.py @@ -0,0 +1,23 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .output_parameter import OutputParameter +import typing +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class UploadToS3Block(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + path: typing.Optional[str] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/url_block.py b/skyvern/client/types/url_block.py new file mode 100644 index 00000000..e82aecbb --- /dev/null +++ b/skyvern/client/types/url_block.py @@ -0,0 +1,43 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .url_block_data_schema import UrlBlockDataSchema +from .url_block_parameters_item import UrlBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class UrlBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: str + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[UrlBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[UrlBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/url_block_data_schema.py b/skyvern/client/types/url_block_data_schema.py new file mode 100644 index 00000000..d9b9e2ee --- /dev/null +++ b/skyvern/client/types/url_block_data_schema.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +UrlBlockDataSchema = typing.Union[ + typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/url_block_parameters_item.py b/skyvern/client/types/url_block_parameters_item.py new file mode 100644 index 00000000..af20e42c --- /dev/null +++ b/skyvern/client/types/url_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class UrlBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class UrlBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class UrlBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class UrlBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class UrlBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class UrlBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class UrlBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class UrlBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +UrlBlockParametersItem = typing.Union[ + UrlBlockParametersItem_AwsSecret, + UrlBlockParametersItem_BitwardenCreditCardData, + UrlBlockParametersItem_BitwardenLoginCredential, + UrlBlockParametersItem_BitwardenSensitiveInformation, + UrlBlockParametersItem_Context, + UrlBlockParametersItem_Credential, + UrlBlockParametersItem_Output, + UrlBlockParametersItem_Workflow, +] +update_forward_refs(UrlBlockParametersItem_Context) diff --git a/skyvern/client/types/validation_block.py b/skyvern/client/types/validation_block.py new file mode 100644 index 00000000..9caaa0bb --- /dev/null +++ b/skyvern/client/types/validation_block.py @@ -0,0 +1,43 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .validation_block_data_schema import ValidationBlockDataSchema +from .validation_block_parameters_item import ValidationBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class ValidationBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[ValidationBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ValidationBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/validation_block_data_schema.py b/skyvern/client/types/validation_block_data_schema.py new file mode 100644 index 00000000..11b8975c --- /dev/null +++ b/skyvern/client/types/validation_block_data_schema.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ValidationBlockDataSchema = typing.Union[ + typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/validation_block_parameters_item.py b/skyvern/client/types/validation_block_parameters_item.py new file mode 100644 index 00000000..63efc92b --- /dev/null +++ b/skyvern/client/types/validation_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class ValidationBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ValidationBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ValidationBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ValidationBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ValidationBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class ValidationBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ValidationBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class ValidationBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +ValidationBlockParametersItem = typing.Union[ + ValidationBlockParametersItem_AwsSecret, + ValidationBlockParametersItem_BitwardenCreditCardData, + ValidationBlockParametersItem_BitwardenLoginCredential, + ValidationBlockParametersItem_BitwardenSensitiveInformation, + ValidationBlockParametersItem_Context, + ValidationBlockParametersItem_Credential, + ValidationBlockParametersItem_Output, + ValidationBlockParametersItem_Workflow, +] +update_forward_refs(ValidationBlockParametersItem_Context) diff --git a/skyvern/client/types/value.py b/skyvern/client/types/value.py new file mode 100644 index 00000000..42e285e1 --- /dev/null +++ b/skyvern/client/types/value.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +Value = typing.Union[ + str, int, float, bool, typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/wait_block.py b/skyvern/client/types/wait_block.py new file mode 100644 index 00000000..3bd642bd --- /dev/null +++ b/skyvern/client/types/wait_block.py @@ -0,0 +1,26 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .output_parameter import OutputParameter +import typing +from .wait_block_parameters_item import WaitBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class WaitBlock(UniversalBaseModel): + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + wait_sec: int + parameters: typing.Optional[typing.List[WaitBlockParametersItem]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/wait_block_parameters_item.py b/skyvern/client/types/wait_block_parameters_item.py new file mode 100644 index 00000000..984f8cfc --- /dev/null +++ b/skyvern/client/types/wait_block_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class WaitBlockParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WaitBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WaitBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WaitBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WaitBlockParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class WaitBlockParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WaitBlockParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WaitBlockParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +WaitBlockParametersItem = typing.Union[ + WaitBlockParametersItem_AwsSecret, + WaitBlockParametersItem_BitwardenCreditCardData, + WaitBlockParametersItem_BitwardenLoginCredential, + WaitBlockParametersItem_BitwardenSensitiveInformation, + WaitBlockParametersItem_Context, + WaitBlockParametersItem_Credential, + WaitBlockParametersItem_Output, + WaitBlockParametersItem_Workflow, +] +update_forward_refs(WaitBlockParametersItem_Context) diff --git a/skyvern/client/types/workflow.py b/skyvern/client/types/workflow.py new file mode 100644 index 00000000..2632be63 --- /dev/null +++ b/skyvern/client/types/workflow.py @@ -0,0 +1,41 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .for_loop_block import ForLoopBlock +import typing +from .workflow_definition import WorkflowDefinition +from .proxy_location import ProxyLocation +from .workflow_status import WorkflowStatus +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class Workflow(UniversalBaseModel): + workflow_id: str + organization_id: str + title: str + workflow_permanent_id: str + version: int + is_saved_task: bool + description: typing.Optional[str] = None + workflow_definition: WorkflowDefinition + proxy_location: typing.Optional[ProxyLocation] = None + webhook_callback_url: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + persist_browser_session: typing.Optional[bool] = None + status: typing.Optional[WorkflowStatus] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/workflow_definition.py b/skyvern/client/types/workflow_definition.py new file mode 100644 index 00000000..ab9117f4 --- /dev/null +++ b/skyvern/client/types/workflow_definition.py @@ -0,0 +1,24 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +from .for_loop_block import ForLoopBlock +import typing +from .workflow_definition_parameters_item import WorkflowDefinitionParametersItem +from .workflow_definition_blocks_item import WorkflowDefinitionBlocksItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class WorkflowDefinition(UniversalBaseModel): + parameters: typing.List[WorkflowDefinitionParametersItem] + blocks: typing.List[WorkflowDefinitionBlocksItem] + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/workflow_definition_blocks_item.py b/skyvern/client/types/workflow_definition_blocks_item.py new file mode 100644 index 00000000..b24f5e0e --- /dev/null +++ b/skyvern/client/types/workflow_definition_blocks_item.py @@ -0,0 +1,550 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +from .context_parameter import ContextParameter +import typing +from .output_parameter import OutputParameter +from .action_block_data_schema import ActionBlockDataSchema +from .action_block_parameters_item import ActionBlockParametersItem +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .code_block_parameters_item import CodeBlockParametersItem +from .extraction_block_data_schema import ExtractionBlockDataSchema +from .extraction_block_parameters_item import ExtractionBlockParametersItem +from .file_download_block_data_schema import FileDownloadBlockDataSchema +from .file_download_block_parameters_item import FileDownloadBlockParametersItem +from .file_storage_type import FileStorageType +import typing_extensions +from ..core.serialization import FieldMetadata +from .file_type import FileType +from .for_loop_block_loop_over import ForLoopBlockLoopOver +from .url_block_data_schema import UrlBlockDataSchema +from .url_block_parameters_item import UrlBlockParametersItem +from .login_block_data_schema import LoginBlockDataSchema +from .login_block_parameters_item import LoginBlockParametersItem +from .navigation_block_data_schema import NavigationBlockDataSchema +from .navigation_block_parameters_item import NavigationBlockParametersItem +from .aws_secret_parameter import AwsSecretParameter +from .task_block_data_schema import TaskBlockDataSchema +from .task_block_parameters_item import TaskBlockParametersItem +from .text_prompt_block_parameters_item import TextPromptBlockParametersItem +from .validation_block_data_schema import ValidationBlockDataSchema +from .validation_block_parameters_item import ValidationBlockParametersItem +from .wait_block_parameters_item import WaitBlockParametersItem +from ..core.pydantic_utilities import update_forward_refs + + +class WorkflowDefinitionBlocksItem_Action(UniversalBaseModel): + block_type: typing.Literal["action"] = "action" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[ActionBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ActionBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_Code(UniversalBaseModel): + block_type: typing.Literal["code"] = "code" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + code: str + parameters: typing.Optional[typing.List[CodeBlockParametersItem]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_DownloadToS3(UniversalBaseModel): + block_type: typing.Literal["download_to_s3"] = "download_to_s3" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + url: str + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_Extraction(UniversalBaseModel): + block_type: typing.Literal["extraction"] = "extraction" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: str + data_schema: typing.Optional[ExtractionBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ExtractionBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_FileDownload(UniversalBaseModel): + block_type: typing.Literal["file_download"] = "file_download" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[FileDownloadBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[FileDownloadBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_FileUpload(UniversalBaseModel): + block_type: typing.Literal["file_upload"] = "file_upload" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + storage_type: typing.Optional[FileStorageType] = None + s3bucket: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="s3_bucket")] = None + aws_access_key_id: typing.Optional[str] = None + aws_secret_access_key: typing.Optional[str] = None + region_name: typing.Optional[str] = None + path: typing.Optional[str] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_FileUrlParser(UniversalBaseModel): + block_type: typing.Literal["file_url_parser"] = "file_url_parser" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + file_url: str + file_type: FileType = "csv" + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_ForLoop(UniversalBaseModel): + block_type: typing.Literal["for_loop"] = "for_loop" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + loop_blocks: typing.List["ForLoopBlockLoopBlocksItem"] + loop_over: typing.Optional[ForLoopBlockLoopOver] = None + loop_variable_reference: typing.Optional[str] = None + complete_if_empty: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .for_loop_block import ForLoopBlock # noqa: E402 +from .for_loop_block_loop_blocks_item import ForLoopBlockLoopBlocksItem # noqa: E402 + + +class WorkflowDefinitionBlocksItem_GotoUrl(UniversalBaseModel): + block_type: typing.Literal["goto_url"] = "goto_url" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: str + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[UrlBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[UrlBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_Login(UniversalBaseModel): + block_type: typing.Literal["login"] = "login" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[LoginBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[LoginBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_Navigation(UniversalBaseModel): + block_type: typing.Literal["navigation"] = "navigation" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: str + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[NavigationBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[NavigationBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_PdfParser(UniversalBaseModel): + block_type: typing.Literal["pdf_parser"] = "pdf_parser" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + file_url: str + json_schema: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_SendEmail(UniversalBaseModel): + block_type: typing.Literal["send_email"] = "send_email" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + smtp_host: AwsSecretParameter + smtp_port: AwsSecretParameter + smtp_username: AwsSecretParameter + smtp_password: AwsSecretParameter + sender: str + recipients: typing.List[str] + subject: str + body: str + file_attachments: typing.Optional[typing.List[str]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_Task(UniversalBaseModel): + block_type: typing.Literal["task"] = "task" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[TaskBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[TaskBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_TaskV2(UniversalBaseModel): + block_type: typing.Literal["task_v2"] = "task_v2" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + prompt: str + url: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + max_iterations: typing.Optional[int] = None + max_steps: typing.Optional[int] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_TextPrompt(UniversalBaseModel): + block_type: typing.Literal["text_prompt"] = "text_prompt" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + llm_key: typing.Optional[str] = None + prompt: str + parameters: typing.Optional[typing.List[TextPromptBlockParametersItem]] = None + json_schema: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_UploadToS3(UniversalBaseModel): + block_type: typing.Literal["upload_to_s3"] = "upload_to_s3" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + path: typing.Optional[str] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_Validation(UniversalBaseModel): + block_type: typing.Literal["validation"] = "validation" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + task_type: typing.Optional[str] = None + url: typing.Optional[str] = None + title: typing.Optional[str] = None + complete_criterion: typing.Optional[str] = None + terminate_criterion: typing.Optional[str] = None + navigation_goal: typing.Optional[str] = None + data_extraction_goal: typing.Optional[str] = None + data_schema: typing.Optional[ValidationBlockDataSchema] = None + error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None + max_retries: typing.Optional[int] = None + max_steps_per_run: typing.Optional[int] = None + parameters: typing.Optional[typing.List[ValidationBlockParametersItem]] = None + complete_on_download: typing.Optional[bool] = None + download_suffix: typing.Optional[str] = None + totp_verification_url: typing.Optional[str] = None + totp_identifier: typing.Optional[str] = None + cache_actions: typing.Optional[bool] = None + complete_verification: typing.Optional[bool] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionBlocksItem_Wait(UniversalBaseModel): + block_type: typing.Literal["wait"] = "wait" + label: str + output_parameter: OutputParameter + continue_on_failure: typing.Optional[bool] = None + wait_sec: int + parameters: typing.Optional[typing.List[WaitBlockParametersItem]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +WorkflowDefinitionBlocksItem = typing.Union[ + WorkflowDefinitionBlocksItem_Action, + WorkflowDefinitionBlocksItem_Code, + WorkflowDefinitionBlocksItem_DownloadToS3, + WorkflowDefinitionBlocksItem_Extraction, + WorkflowDefinitionBlocksItem_FileDownload, + WorkflowDefinitionBlocksItem_FileUpload, + WorkflowDefinitionBlocksItem_FileUrlParser, + WorkflowDefinitionBlocksItem_ForLoop, + WorkflowDefinitionBlocksItem_GotoUrl, + WorkflowDefinitionBlocksItem_Login, + WorkflowDefinitionBlocksItem_Navigation, + WorkflowDefinitionBlocksItem_PdfParser, + WorkflowDefinitionBlocksItem_SendEmail, + WorkflowDefinitionBlocksItem_Task, + WorkflowDefinitionBlocksItem_TaskV2, + WorkflowDefinitionBlocksItem_TextPrompt, + WorkflowDefinitionBlocksItem_UploadToS3, + WorkflowDefinitionBlocksItem_Validation, + WorkflowDefinitionBlocksItem_Wait, +] +update_forward_refs(WorkflowDefinitionBlocksItem_ForLoop) diff --git a/skyvern/client/types/workflow_definition_parameters_item.py b/skyvern/client/types/workflow_definition_parameters_item.py new file mode 100644 index 00000000..e8d89342 --- /dev/null +++ b/skyvern/client/types/workflow_definition_parameters_item.py @@ -0,0 +1,207 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations +from ..core.pydantic_utilities import UniversalBaseModel +import typing +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic +from .value import Value +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +from ..core.pydantic_utilities import update_forward_refs + + +class WorkflowDefinitionParametersItem_AwsSecret(UniversalBaseModel): + parameter_type: typing.Literal["aws_secret"] = "aws_secret" + key: str + description: typing.Optional[str] = None + aws_secret_parameter_id: str + workflow_id: str + aws_key: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionParametersItem_BitwardenCreditCardData(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data" + key: str + description: typing.Optional[str] = None + bitwarden_credit_card_data_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_item_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionParametersItem_BitwardenLoginCredential(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential" + key: str + description: typing.Optional[str] = None + bitwarden_login_credential_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + url_parameter_key: typing.Optional[str] = None + bitwarden_collection_id: typing.Optional[str] = None + bitwarden_item_id: typing.Optional[str] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionParametersItem_BitwardenSensitiveInformation(UniversalBaseModel): + parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information" + key: str + description: typing.Optional[str] = None + bitwarden_sensitive_information_parameter_id: str + workflow_id: str + bitwarden_client_id_aws_secret_key: str + bitwarden_client_secret_aws_secret_key: str + bitwarden_master_password_aws_secret_key: str + bitwarden_collection_id: str + bitwarden_identity_key: str + bitwarden_identity_fields: typing.List[str] + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionParametersItem_Context(UniversalBaseModel): + parameter_type: typing.Literal["context"] = "context" + key: str + description: typing.Optional[str] = None + source: "Source" + value: typing.Optional[Value] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +from .context_parameter import ContextParameter # noqa: E402 +from .source import Source # noqa: E402 + + +class WorkflowDefinitionParametersItem_Credential(UniversalBaseModel): + parameter_type: typing.Literal["credential"] = "credential" + key: str + description: typing.Optional[str] = None + credential_parameter_id: str + workflow_id: str + credential_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionParametersItem_Output(UniversalBaseModel): + parameter_type: typing.Literal["output"] = "output" + key: str + description: typing.Optional[str] = None + output_parameter_id: str + workflow_id: str + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +class WorkflowDefinitionParametersItem_Workflow(UniversalBaseModel): + parameter_type: typing.Literal["workflow"] = "workflow" + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow + + +WorkflowDefinitionParametersItem = typing.Union[ + WorkflowDefinitionParametersItem_AwsSecret, + WorkflowDefinitionParametersItem_BitwardenCreditCardData, + WorkflowDefinitionParametersItem_BitwardenLoginCredential, + WorkflowDefinitionParametersItem_BitwardenSensitiveInformation, + WorkflowDefinitionParametersItem_Context, + WorkflowDefinitionParametersItem_Credential, + WorkflowDefinitionParametersItem_Output, + WorkflowDefinitionParametersItem_Workflow, +] +update_forward_refs(WorkflowDefinitionParametersItem_Context) diff --git a/skyvern/client/types/workflow_parameter.py b/skyvern/client/types/workflow_parameter.py new file mode 100644 index 00000000..1fcafdd8 --- /dev/null +++ b/skyvern/client/types/workflow_parameter.py @@ -0,0 +1,30 @@ +# This file was auto-generated by Fern from our API Definition. + +from ..core.pydantic_utilities import UniversalBaseModel +import typing +from .workflow_parameter_type import WorkflowParameterType +from .workflow_parameter_default_value import WorkflowParameterDefaultValue +import datetime as dt +from ..core.pydantic_utilities import IS_PYDANTIC_V2 +import pydantic + + +class WorkflowParameter(UniversalBaseModel): + key: str + description: typing.Optional[str] = None + workflow_parameter_id: str + workflow_parameter_type: WorkflowParameterType + workflow_id: str + default_value: typing.Optional[WorkflowParameterDefaultValue] = None + created_at: dt.datetime + modified_at: dt.datetime + deleted_at: typing.Optional[dt.datetime] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/skyvern/client/types/workflow_parameter_default_value.py b/skyvern/client/types/workflow_parameter_default_value.py new file mode 100644 index 00000000..f4da1c6b --- /dev/null +++ b/skyvern/client/types/workflow_parameter_default_value.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +WorkflowParameterDefaultValue = typing.Union[ + str, int, float, bool, typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]] +] diff --git a/skyvern/client/types/workflow_parameter_type.py b/skyvern/client/types/workflow_parameter_type.py new file mode 100644 index 00000000..f1b98b1a --- /dev/null +++ b/skyvern/client/types/workflow_parameter_type.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +WorkflowParameterType = typing.Union[ + typing.Literal["string", "integer", "float", "boolean", "json", "file_url", "credential_id"], typing.Any +] diff --git a/skyvern/client/types/workflow_run_response.py b/skyvern/client/types/workflow_run_response.py index 90f141bd..b4a95309 100644 --- a/skyvern/client/types/workflow_run_response.py +++ b/skyvern/client/types/workflow_run_response.py @@ -5,6 +5,7 @@ import pydantic from .run_status import RunStatus import typing from .output import Output +from .file_info import FileInfo import datetime as dt from .workflow_run_request import WorkflowRunRequest from ..core.pydantic_utilities import IS_PYDANTIC_V2 @@ -26,6 +27,16 @@ class WorkflowRunResponse(UniversalBaseModel): Output data from the run, if any. Format depends on the schema in the input """ + downloaded_files: typing.Optional[typing.List[FileInfo]] = pydantic.Field(default=None) + """ + List of files downloaded during the run + """ + + recording_url: typing.Optional[str] = pydantic.Field(default=None) + """ + URL to the recording of the run + """ + failure_reason: typing.Optional[str] = pydantic.Field(default=None) """ Reason for failure if the run failed diff --git a/skyvern/client/types/workflow_status.py b/skyvern/client/types/workflow_status.py new file mode 100644 index 00000000..7d4a9cfa --- /dev/null +++ b/skyvern/client/types/workflow_status.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +WorkflowStatus = typing.Union[typing.Literal["published", "draft", "auto_generated"], typing.Any]