update openapi.json with credentials APIs (#2323)
This commit is contained in:
@@ -4,8 +4,8 @@ api:
|
||||
specs:
|
||||
- openapi: openapi/skyvern_openapi.json
|
||||
origin: https://api.skyvern.com/openapi.json
|
||||
# settings:
|
||||
# use-title: false
|
||||
settings:
|
||||
title-as-schema-name: false
|
||||
groups:
|
||||
python-sdk:
|
||||
generators:
|
||||
|
||||
@@ -78,6 +78,8 @@
|
||||
"mapping": {
|
||||
"task_v1": "#/components/schemas/TaskRunResponse",
|
||||
"task_v2": "#/components/schemas/TaskRunResponse",
|
||||
"openai_cua": "#/components/schemas/TaskRunResponse",
|
||||
"anthropic_cua": "#/components/schemas/TaskRunResponse",
|
||||
"workflow_run": "#/components/schemas/WorkflowRunResponse"
|
||||
}
|
||||
},
|
||||
@@ -1388,6 +1390,10 @@
|
||||
"title": "Title",
|
||||
"type": "string"
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/$defs/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"error_code_mapping": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -1605,6 +1611,16 @@
|
||||
"title": "ProxyLocation",
|
||||
"type": "string"
|
||||
},
|
||||
"RunEngine": {
|
||||
"enum": [
|
||||
"skyvern-1.0",
|
||||
"skyvern-2.0",
|
||||
"openai-cua",
|
||||
"anthropic-cua"
|
||||
],
|
||||
"title": "RunEngine",
|
||||
"type": "string"
|
||||
},
|
||||
"SendEmailBlockYAML": {
|
||||
"properties": {
|
||||
"block_type": {
|
||||
@@ -2878,6 +2894,360 @@
|
||||
"x-fern-sdk-method-name": "cancel_run"
|
||||
}
|
||||
},
|
||||
"/v1/credentials": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"credentials"
|
||||
],
|
||||
"summary": "Get all credentials",
|
||||
"description": "Retrieves a paginated list of credentials for the current organization",
|
||||
"operationId": "get_credentials_v1_credentials_get",
|
||||
"parameters": [
|
||||
{
|
||||
"name": "page",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"schema": {
|
||||
"type": "integer",
|
||||
"minimum": 1,
|
||||
"description": "Page number for pagination",
|
||||
"openapi_extra": {
|
||||
"x-fern-sdk-parameter-name": "page"
|
||||
},
|
||||
"default": 1,
|
||||
"title": "Page"
|
||||
},
|
||||
"description": "Page number for pagination",
|
||||
"example": 1
|
||||
},
|
||||
{
|
||||
"name": "page_size",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"schema": {
|
||||
"type": "integer",
|
||||
"minimum": 1,
|
||||
"description": "Number of items per page",
|
||||
"openapi_extra": {
|
||||
"x-fern-sdk-parameter-name": "page_size"
|
||||
},
|
||||
"default": 10,
|
||||
"title": "Page Size"
|
||||
},
|
||||
"description": "Number of items per page",
|
||||
"example": 10
|
||||
},
|
||||
{
|
||||
"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": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/components/schemas/CredentialResponse"
|
||||
},
|
||||
"title": "Response Get Credentials V1 Credentials Get"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"422": {
|
||||
"description": "Validation Error",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/HTTPValidationError"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"x-fern-sdk-group-name": "credentials",
|
||||
"x-fern-sdk-method-name": "get_credentials"
|
||||
},
|
||||
"post": {
|
||||
"tags": [
|
||||
"credentials"
|
||||
],
|
||||
"summary": "Create credential",
|
||||
"description": "Creates a new credential for the current organization",
|
||||
"operationId": "create_credential_v1_credentials_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"
|
||||
}
|
||||
}
|
||||
],
|
||||
"requestBody": {
|
||||
"required": true,
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/CreateCredentialRequest",
|
||||
"description": "The credential data to create",
|
||||
"openapi_extra": {
|
||||
"x-fern-sdk-parameter-name": "data"
|
||||
}
|
||||
},
|
||||
"example": {
|
||||
"name": "My Credential",
|
||||
"credential_type": "PASSWORD",
|
||||
"credential": {
|
||||
"username": "user@example.com",
|
||||
"password": "securepassword123",
|
||||
"totp": "JBSWY3DPEHPK3PXP"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"responses": {
|
||||
"201": {
|
||||
"description": "Successful Response",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/CredentialResponse"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"422": {
|
||||
"description": "Validation Error",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/HTTPValidationError"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"x-fern-sdk-group-name": "credentials",
|
||||
"x-fern-sdk-method-name": "create_credential"
|
||||
}
|
||||
},
|
||||
"/v1/credentials/{credential_id}": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"credentials"
|
||||
],
|
||||
"summary": "Get credential by ID",
|
||||
"description": "Retrieves a specific credential by its ID",
|
||||
"operationId": "get_credential_v1_credentials__credential_id__get",
|
||||
"parameters": [
|
||||
{
|
||||
"name": "credential_id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"description": "The unique identifier of the credential",
|
||||
"openapi_extra": {
|
||||
"x-fern-sdk-parameter-name": "credential_id"
|
||||
},
|
||||
"title": "Credential Id"
|
||||
},
|
||||
"description": "The unique identifier of the credential",
|
||||
"example": "cred_1234567890"
|
||||
},
|
||||
{
|
||||
"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": {
|
||||
"$ref": "#/components/schemas/CredentialResponse"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"422": {
|
||||
"description": "Validation Error",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/HTTPValidationError"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"x-fern-sdk-group-name": "credentials",
|
||||
"x-fern-sdk-method-name": "get_credential"
|
||||
}
|
||||
},
|
||||
"/v1/credentials/{credential_id}/delete": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"credentials"
|
||||
],
|
||||
"summary": "Delete credential",
|
||||
"description": "Deletes a specific credential by its ID",
|
||||
"operationId": "delete_credential_v1_credentials__credential_id__delete_post",
|
||||
"parameters": [
|
||||
{
|
||||
"name": "credential_id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"type": "string",
|
||||
"description": "The unique identifier of the credential to delete",
|
||||
"openapi_extra": {
|
||||
"x-fern-sdk-parameter-name": "credential_id"
|
||||
},
|
||||
"title": "Credential Id"
|
||||
},
|
||||
"description": "The unique identifier of the credential to delete",
|
||||
"example": "cred_1234567890"
|
||||
},
|
||||
{
|
||||
"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": {
|
||||
"204": {
|
||||
"description": "Successful Response"
|
||||
},
|
||||
"422": {
|
||||
"description": "Validation Error",
|
||||
"content": {
|
||||
"application/json": {
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/HTTPValidationError"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"x-fern-sdk-group-name": "credentials",
|
||||
"x-fern-sdk-method-name": "delete_credential"
|
||||
}
|
||||
},
|
||||
"/v1/browser_sessions/{browser_session_id}": {
|
||||
"get": {
|
||||
"tags": [
|
||||
@@ -3298,6 +3668,10 @@
|
||||
"title": "Title",
|
||||
"default": ""
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/components/schemas/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"complete_criterion": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -4031,6 +4405,48 @@
|
||||
],
|
||||
"title": "ContextParameter"
|
||||
},
|
||||
"CreateCredentialRequest": {
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string",
|
||||
"title": "Name",
|
||||
"description": "Name of the credential",
|
||||
"examples": [
|
||||
"My Credential"
|
||||
]
|
||||
},
|
||||
"credential_type": {
|
||||
"$ref": "#/components/schemas/CredentialType",
|
||||
"description": "Type of credential to create"
|
||||
},
|
||||
"credential": {
|
||||
"anyOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/NonEmptyPasswordCredential"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/NonEmptyCreditCardCredential"
|
||||
}
|
||||
],
|
||||
"title": "Credential",
|
||||
"description": "The credential data to store",
|
||||
"examples": [
|
||||
{
|
||||
"password": "securepassword123",
|
||||
"username": "user@example.com"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"name",
|
||||
"credential_type",
|
||||
"credential"
|
||||
],
|
||||
"title": "CreateCredentialRequest",
|
||||
"description": "Request model for creating a new credential."
|
||||
},
|
||||
"CredentialParameter": {
|
||||
"properties": {
|
||||
"parameter_type": {
|
||||
@@ -4100,6 +4516,87 @@
|
||||
],
|
||||
"title": "CredentialParameter"
|
||||
},
|
||||
"CredentialResponse": {
|
||||
"properties": {
|
||||
"credential_id": {
|
||||
"type": "string",
|
||||
"title": "Credential Id",
|
||||
"description": "Unique identifier for the credential",
|
||||
"examples": [
|
||||
"cred_1234567890"
|
||||
]
|
||||
},
|
||||
"credential": {
|
||||
"anyOf": [
|
||||
{
|
||||
"$ref": "#/components/schemas/PasswordCredentialResponse"
|
||||
},
|
||||
{
|
||||
"$ref": "#/components/schemas/CreditCardCredentialResponse"
|
||||
}
|
||||
],
|
||||
"title": "Credential",
|
||||
"description": "The credential data"
|
||||
},
|
||||
"credential_type": {
|
||||
"$ref": "#/components/schemas/CredentialType",
|
||||
"description": "Type of the credential"
|
||||
},
|
||||
"name": {
|
||||
"type": "string",
|
||||
"title": "Name",
|
||||
"description": "Name of the credential",
|
||||
"examples": [
|
||||
"My Credential"
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"credential_id",
|
||||
"credential",
|
||||
"credential_type",
|
||||
"name"
|
||||
],
|
||||
"title": "CredentialResponse",
|
||||
"description": "Response model for credential operations."
|
||||
},
|
||||
"CredentialType": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"password",
|
||||
"credit_card"
|
||||
],
|
||||
"title": "CredentialType",
|
||||
"description": "Type of credential stored in the system."
|
||||
},
|
||||
"CreditCardCredentialResponse": {
|
||||
"properties": {
|
||||
"last_four": {
|
||||
"type": "string",
|
||||
"title": "Last Four",
|
||||
"description": "Last four digits of the credit card number",
|
||||
"examples": [
|
||||
"1234"
|
||||
]
|
||||
},
|
||||
"brand": {
|
||||
"type": "string",
|
||||
"title": "Brand",
|
||||
"description": "Brand of the credit card",
|
||||
"examples": [
|
||||
"visa"
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"last_four",
|
||||
"brand"
|
||||
],
|
||||
"title": "CreditCardCredentialResponse",
|
||||
"description": "Response model for credit card credentials, containing only the last four digits and brand."
|
||||
},
|
||||
"DownloadToS3Block": {
|
||||
"properties": {
|
||||
"label": {
|
||||
@@ -4174,6 +4671,10 @@
|
||||
"title": "Title",
|
||||
"default": ""
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/components/schemas/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"complete_criterion": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -4403,6 +4904,10 @@
|
||||
"title": "Title",
|
||||
"default": ""
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/components/schemas/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"complete_criterion": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -5011,6 +5516,10 @@
|
||||
"title": "Title",
|
||||
"default": ""
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/components/schemas/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"complete_criterion": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -5246,6 +5755,10 @@
|
||||
"title": "Title",
|
||||
"default": ""
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/components/schemas/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"complete_criterion": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -5434,6 +5947,119 @@
|
||||
],
|
||||
"title": "NavigationBlock"
|
||||
},
|
||||
"NonEmptyCreditCardCredential": {
|
||||
"properties": {
|
||||
"card_number": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"title": "Card Number",
|
||||
"description": "The full credit card number (must not be empty)",
|
||||
"examples": [
|
||||
"4111111111111111"
|
||||
]
|
||||
},
|
||||
"card_cvv": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"title": "Card Cvv",
|
||||
"description": "The card's CVV (must not be empty)",
|
||||
"examples": [
|
||||
"123"
|
||||
]
|
||||
},
|
||||
"card_exp_month": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"title": "Card Exp Month",
|
||||
"description": "The card's expiration month (must not be empty)",
|
||||
"examples": [
|
||||
"12"
|
||||
]
|
||||
},
|
||||
"card_exp_year": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"title": "Card Exp Year",
|
||||
"description": "The card's expiration year (must not be empty)",
|
||||
"examples": [
|
||||
"2025"
|
||||
]
|
||||
},
|
||||
"card_brand": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"title": "Card Brand",
|
||||
"description": "The card's brand (must not be empty)",
|
||||
"examples": [
|
||||
"visa"
|
||||
]
|
||||
},
|
||||
"card_holder_name": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"title": "Card Holder Name",
|
||||
"description": "The name of the card holder (must not be empty)",
|
||||
"examples": [
|
||||
"John Doe"
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"card_number",
|
||||
"card_cvv",
|
||||
"card_exp_month",
|
||||
"card_exp_year",
|
||||
"card_brand",
|
||||
"card_holder_name"
|
||||
],
|
||||
"title": "NonEmptyCreditCardCredential",
|
||||
"description": "Credit card credential model that requires non-empty values."
|
||||
},
|
||||
"NonEmptyPasswordCredential": {
|
||||
"properties": {
|
||||
"password": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"title": "Password",
|
||||
"description": "The password value (must not be empty)",
|
||||
"examples": [
|
||||
"securepassword123"
|
||||
]
|
||||
},
|
||||
"username": {
|
||||
"type": "string",
|
||||
"minLength": 1,
|
||||
"title": "Username",
|
||||
"description": "The username associated with the credential (must not be empty)",
|
||||
"examples": [
|
||||
"user@example.com"
|
||||
]
|
||||
},
|
||||
"totp": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"type": "null"
|
||||
}
|
||||
],
|
||||
"title": "Totp",
|
||||
"description": "Optional TOTP (Time-based One-Time Password) string used to generate 2FA codes",
|
||||
"examples": [
|
||||
"JBSWY3DPEHPK3PXP"
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"password",
|
||||
"username"
|
||||
],
|
||||
"title": "NonEmptyPasswordCredential",
|
||||
"description": "Password credential model that requires non-empty values."
|
||||
},
|
||||
"OutputParameter": {
|
||||
"properties": {
|
||||
"parameter_type": {
|
||||
@@ -5543,6 +6169,24 @@
|
||||
],
|
||||
"title": "PDFParserBlock"
|
||||
},
|
||||
"PasswordCredentialResponse": {
|
||||
"properties": {
|
||||
"username": {
|
||||
"type": "string",
|
||||
"title": "Username",
|
||||
"description": "The username associated with the credential",
|
||||
"examples": [
|
||||
"user@example.com"
|
||||
]
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"required": [
|
||||
"username"
|
||||
],
|
||||
"title": "PasswordCredentialResponse",
|
||||
"description": "Response model for password credentials, containing only the username."
|
||||
},
|
||||
"ProxyLocation": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
@@ -5572,7 +6216,8 @@
|
||||
"enum": [
|
||||
"skyvern-1.0",
|
||||
"skyvern-2.0",
|
||||
"openai-cua"
|
||||
"openai-cua",
|
||||
"anthropic-cua"
|
||||
],
|
||||
"title": "RunEngine"
|
||||
},
|
||||
@@ -5706,6 +6351,10 @@
|
||||
"title": "Title",
|
||||
"default": ""
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/components/schemas/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"complete_criterion": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -6142,14 +6791,28 @@
|
||||
"title": "Modified At",
|
||||
"description": "Timestamp when this run was last modified"
|
||||
},
|
||||
"app_url": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"type": "null"
|
||||
}
|
||||
],
|
||||
"title": "App Url",
|
||||
"description": "URL to the application UI where the run can be viewed"
|
||||
},
|
||||
"run_type": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"task_v1",
|
||||
"task_v2"
|
||||
"task_v2",
|
||||
"openai_cua",
|
||||
"anthropic_cua"
|
||||
],
|
||||
"title": "Run Type",
|
||||
"description": "Type of task run - either task_v1 or task_v2"
|
||||
"description": "Types of a task run - task_v1, task_v2, openai_cua, anthropic_cua"
|
||||
},
|
||||
"run_request": {
|
||||
"anyOf": [
|
||||
@@ -6272,7 +6935,7 @@
|
||||
"llm_key": {
|
||||
"type": "string",
|
||||
"title": "Llm Key",
|
||||
"default": "AZURE_OPENAI"
|
||||
"default": "AZURE_OPENAI_GPT4_1"
|
||||
},
|
||||
"prompt": {
|
||||
"type": "string",
|
||||
@@ -6418,6 +7081,10 @@
|
||||
"title": "Title",
|
||||
"default": ""
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/components/schemas/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"complete_criterion": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -6654,6 +7321,10 @@
|
||||
"title": "Title",
|
||||
"default": ""
|
||||
},
|
||||
"engine": {
|
||||
"$ref": "#/components/schemas/RunEngine",
|
||||
"default": "skyvern-1.0"
|
||||
},
|
||||
"complete_criterion": {
|
||||
"anyOf": [
|
||||
{
|
||||
@@ -7516,6 +8187,18 @@
|
||||
"title": "Modified At",
|
||||
"description": "Timestamp when this run was last modified"
|
||||
},
|
||||
"app_url": {
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"type": "null"
|
||||
}
|
||||
],
|
||||
"title": "App Url",
|
||||
"description": "URL to the application UI where the run can be viewed"
|
||||
},
|
||||
"run_type": {
|
||||
"type": "string",
|
||||
"const": "workflow_run",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[tool.poetry]
|
||||
name = "skyvern"
|
||||
version = "0.1.81"
|
||||
version = "0.1.82"
|
||||
description = ""
|
||||
authors = ["Skyvern AI <info@skyvern.com>"]
|
||||
readme = "README.md"
|
||||
|
||||
@@ -28,7 +28,21 @@ from .types import (
|
||||
CodeBlockParametersItem_Output,
|
||||
CodeBlockParametersItem_Workflow,
|
||||
ContextParameter,
|
||||
ContextParameterSource,
|
||||
ContextParameterSource_AwsSecret,
|
||||
ContextParameterSource_BitwardenCreditCardData,
|
||||
ContextParameterSource_BitwardenLoginCredential,
|
||||
ContextParameterSource_BitwardenSensitiveInformation,
|
||||
ContextParameterSource_Context,
|
||||
ContextParameterSource_Credential,
|
||||
ContextParameterSource_Output,
|
||||
ContextParameterSource_Workflow,
|
||||
ContextParameterValue,
|
||||
CredentialParameter,
|
||||
CredentialResponse,
|
||||
CredentialResponseCredential,
|
||||
CredentialType,
|
||||
CreditCardCredentialResponse,
|
||||
DownloadToS3Block,
|
||||
ExtractionBlock,
|
||||
ExtractionBlockDataSchema,
|
||||
@@ -110,22 +124,15 @@ from .types import (
|
||||
NavigationBlockParametersItem_Credential,
|
||||
NavigationBlockParametersItem_Output,
|
||||
NavigationBlockParametersItem_Workflow,
|
||||
Output,
|
||||
NonEmptyCreditCardCredential,
|
||||
NonEmptyPasswordCredential,
|
||||
OutputParameter,
|
||||
PasswordCredentialResponse,
|
||||
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,
|
||||
@@ -140,6 +147,7 @@ from .types import (
|
||||
TaskRunRequest,
|
||||
TaskRunRequestDataExtractionSchema,
|
||||
TaskRunResponse,
|
||||
TaskRunResponseOutput,
|
||||
TaskV2Block,
|
||||
TextPromptBlock,
|
||||
TextPromptBlockParametersItem,
|
||||
@@ -176,7 +184,6 @@ from .types import (
|
||||
ValidationBlockParametersItem_Workflow,
|
||||
ValidationError,
|
||||
ValidationErrorLocItem,
|
||||
Value,
|
||||
WaitBlock,
|
||||
WaitBlockParametersItem,
|
||||
WaitBlockParametersItem_AwsSecret,
|
||||
@@ -223,17 +230,21 @@ from .types import (
|
||||
WorkflowParameterType,
|
||||
WorkflowRunRequest,
|
||||
WorkflowRunResponse,
|
||||
WorkflowRunResponseOutput,
|
||||
WorkflowStatus,
|
||||
)
|
||||
from .errors import BadRequestError, NotFoundError, UnauthorizedError, UnprocessableEntityError
|
||||
from . import agent, browser_session
|
||||
from . import agent, browser_session, credentials
|
||||
from .agent import (
|
||||
AgentGetRunResponse,
|
||||
AgentGetRunResponse_AnthropicCua,
|
||||
AgentGetRunResponse_OpenaiCua,
|
||||
AgentGetRunResponse_TaskV1,
|
||||
AgentGetRunResponse_TaskV2,
|
||||
AgentGetRunResponse_WorkflowRun,
|
||||
)
|
||||
from .client import AsyncSkyvern, Skyvern
|
||||
from .credentials import CreateCredentialRequestCredential
|
||||
from .environment import SkyvernEnvironment
|
||||
from .version import __version__
|
||||
|
||||
@@ -250,6 +261,8 @@ __all__ = [
|
||||
"ActionBlockParametersItem_Output",
|
||||
"ActionBlockParametersItem_Workflow",
|
||||
"AgentGetRunResponse",
|
||||
"AgentGetRunResponse_AnthropicCua",
|
||||
"AgentGetRunResponse_OpenaiCua",
|
||||
"AgentGetRunResponse_TaskV1",
|
||||
"AgentGetRunResponse_TaskV2",
|
||||
"AgentGetRunResponse_WorkflowRun",
|
||||
@@ -271,7 +284,22 @@ __all__ = [
|
||||
"CodeBlockParametersItem_Output",
|
||||
"CodeBlockParametersItem_Workflow",
|
||||
"ContextParameter",
|
||||
"ContextParameterSource",
|
||||
"ContextParameterSource_AwsSecret",
|
||||
"ContextParameterSource_BitwardenCreditCardData",
|
||||
"ContextParameterSource_BitwardenLoginCredential",
|
||||
"ContextParameterSource_BitwardenSensitiveInformation",
|
||||
"ContextParameterSource_Context",
|
||||
"ContextParameterSource_Credential",
|
||||
"ContextParameterSource_Output",
|
||||
"ContextParameterSource_Workflow",
|
||||
"ContextParameterValue",
|
||||
"CreateCredentialRequestCredential",
|
||||
"CredentialParameter",
|
||||
"CredentialResponse",
|
||||
"CredentialResponseCredential",
|
||||
"CredentialType",
|
||||
"CreditCardCredentialResponse",
|
||||
"DownloadToS3Block",
|
||||
"ExtractionBlock",
|
||||
"ExtractionBlockDataSchema",
|
||||
@@ -353,9 +381,11 @@ __all__ = [
|
||||
"NavigationBlockParametersItem_Credential",
|
||||
"NavigationBlockParametersItem_Output",
|
||||
"NavigationBlockParametersItem_Workflow",
|
||||
"NonEmptyCreditCardCredential",
|
||||
"NonEmptyPasswordCredential",
|
||||
"NotFoundError",
|
||||
"Output",
|
||||
"OutputParameter",
|
||||
"PasswordCredentialResponse",
|
||||
"PdfParserBlock",
|
||||
"ProxyLocation",
|
||||
"RunEngine",
|
||||
@@ -363,15 +393,6 @@ __all__ = [
|
||||
"SendEmailBlock",
|
||||
"Skyvern",
|
||||
"SkyvernEnvironment",
|
||||
"Source",
|
||||
"Source_AwsSecret",
|
||||
"Source_BitwardenCreditCardData",
|
||||
"Source_BitwardenLoginCredential",
|
||||
"Source_BitwardenSensitiveInformation",
|
||||
"Source_Context",
|
||||
"Source_Credential",
|
||||
"Source_Output",
|
||||
"Source_Workflow",
|
||||
"TaskBlock",
|
||||
"TaskBlockDataSchema",
|
||||
"TaskBlockParametersItem",
|
||||
@@ -386,6 +407,7 @@ __all__ = [
|
||||
"TaskRunRequest",
|
||||
"TaskRunRequestDataExtractionSchema",
|
||||
"TaskRunResponse",
|
||||
"TaskRunResponseOutput",
|
||||
"TaskV2Block",
|
||||
"TextPromptBlock",
|
||||
"TextPromptBlockParametersItem",
|
||||
@@ -424,7 +446,6 @@ __all__ = [
|
||||
"ValidationBlockParametersItem_Workflow",
|
||||
"ValidationError",
|
||||
"ValidationErrorLocItem",
|
||||
"Value",
|
||||
"WaitBlock",
|
||||
"WaitBlockParametersItem",
|
||||
"WaitBlockParametersItem_AwsSecret",
|
||||
@@ -471,8 +492,10 @@ __all__ = [
|
||||
"WorkflowParameterType",
|
||||
"WorkflowRunRequest",
|
||||
"WorkflowRunResponse",
|
||||
"WorkflowRunResponseOutput",
|
||||
"WorkflowStatus",
|
||||
"__version__",
|
||||
"agent",
|
||||
"browser_session",
|
||||
"credentials",
|
||||
]
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
|
||||
from .types import (
|
||||
AgentGetRunResponse,
|
||||
AgentGetRunResponse_AnthropicCua,
|
||||
AgentGetRunResponse_OpenaiCua,
|
||||
AgentGetRunResponse_TaskV1,
|
||||
AgentGetRunResponse_TaskV2,
|
||||
AgentGetRunResponse_WorkflowRun,
|
||||
@@ -9,6 +11,8 @@ from .types import (
|
||||
|
||||
__all__ = [
|
||||
"AgentGetRunResponse",
|
||||
"AgentGetRunResponse_AnthropicCua",
|
||||
"AgentGetRunResponse_OpenaiCua",
|
||||
"AgentGetRunResponse_TaskV1",
|
||||
"AgentGetRunResponse_TaskV2",
|
||||
"AgentGetRunResponse_WorkflowRun",
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
|
||||
from .agent_get_run_response import (
|
||||
AgentGetRunResponse,
|
||||
AgentGetRunResponse_AnthropicCua,
|
||||
AgentGetRunResponse_OpenaiCua,
|
||||
AgentGetRunResponse_TaskV1,
|
||||
AgentGetRunResponse_TaskV2,
|
||||
AgentGetRunResponse_WorkflowRun,
|
||||
@@ -9,6 +11,8 @@ from .agent_get_run_response import (
|
||||
|
||||
__all__ = [
|
||||
"AgentGetRunResponse",
|
||||
"AgentGetRunResponse_AnthropicCua",
|
||||
"AgentGetRunResponse_OpenaiCua",
|
||||
"AgentGetRunResponse_TaskV1",
|
||||
"AgentGetRunResponse_TaskV2",
|
||||
"AgentGetRunResponse_WorkflowRun",
|
||||
|
||||
@@ -4,12 +4,13 @@ from __future__ import annotations
|
||||
from ...core.pydantic_utilities import UniversalBaseModel
|
||||
import typing
|
||||
from ...types.run_status import RunStatus
|
||||
from ...types.output import Output
|
||||
from ...types.task_run_response_output import TaskRunResponseOutput
|
||||
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
|
||||
import pydantic
|
||||
from ...types.workflow_run_response_output import WorkflowRunResponseOutput
|
||||
from ...types.workflow_run_request import WorkflowRunRequest
|
||||
|
||||
|
||||
@@ -17,12 +18,13 @@ class AgentGetRunResponse_TaskV1(UniversalBaseModel):
|
||||
run_type: typing.Literal["task_v1"] = "task_v1"
|
||||
run_id: str
|
||||
status: RunStatus
|
||||
output: typing.Optional[Output] = None
|
||||
output: typing.Optional[TaskRunResponseOutput] = 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
|
||||
app_url: typing.Optional[str] = None
|
||||
run_request: typing.Optional[TaskRunRequest] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
@@ -39,12 +41,59 @@ class AgentGetRunResponse_TaskV2(UniversalBaseModel):
|
||||
run_type: typing.Literal["task_v2"] = "task_v2"
|
||||
run_id: str
|
||||
status: RunStatus
|
||||
output: typing.Optional[Output] = None
|
||||
output: typing.Optional[TaskRunResponseOutput] = 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
|
||||
app_url: typing.Optional[str] = None
|
||||
run_request: typing.Optional[TaskRunRequest] = 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 AgentGetRunResponse_OpenaiCua(UniversalBaseModel):
|
||||
run_type: typing.Literal["openai_cua"] = "openai_cua"
|
||||
run_id: str
|
||||
status: RunStatus
|
||||
output: typing.Optional[TaskRunResponseOutput] = 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
|
||||
app_url: typing.Optional[str] = None
|
||||
run_request: typing.Optional[TaskRunRequest] = 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 AgentGetRunResponse_AnthropicCua(UniversalBaseModel):
|
||||
run_type: typing.Literal["anthropic_cua"] = "anthropic_cua"
|
||||
run_id: str
|
||||
status: RunStatus
|
||||
output: typing.Optional[TaskRunResponseOutput] = 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
|
||||
app_url: typing.Optional[str] = None
|
||||
run_request: typing.Optional[TaskRunRequest] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
@@ -61,12 +110,13 @@ class AgentGetRunResponse_WorkflowRun(UniversalBaseModel):
|
||||
run_type: typing.Literal["workflow_run"] = "workflow_run"
|
||||
run_id: str
|
||||
status: RunStatus
|
||||
output: typing.Optional[Output] = None
|
||||
output: typing.Optional[WorkflowRunResponseOutput] = 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
|
||||
app_url: typing.Optional[str] = None
|
||||
run_request: typing.Optional[WorkflowRunRequest] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
@@ -80,5 +130,9 @@ class AgentGetRunResponse_WorkflowRun(UniversalBaseModel):
|
||||
|
||||
|
||||
AgentGetRunResponse = typing.Union[
|
||||
AgentGetRunResponse_TaskV1, AgentGetRunResponse_TaskV2, AgentGetRunResponse_WorkflowRun
|
||||
AgentGetRunResponse_TaskV1,
|
||||
AgentGetRunResponse_TaskV2,
|
||||
AgentGetRunResponse_OpenaiCua,
|
||||
AgentGetRunResponse_AnthropicCua,
|
||||
AgentGetRunResponse_WorkflowRun,
|
||||
]
|
||||
|
||||
@@ -5,9 +5,11 @@ from .environment import SkyvernEnvironment
|
||||
import httpx
|
||||
from .core.client_wrapper import SyncClientWrapper
|
||||
from .agent.client import AgentClient
|
||||
from .credentials.client import CredentialsClient
|
||||
from .browser_session.client import BrowserSessionClient
|
||||
from .core.client_wrapper import AsyncClientWrapper
|
||||
from .agent.client import AsyncAgentClient
|
||||
from .credentials.client import AsyncCredentialsClient
|
||||
from .browser_session.client import AsyncBrowserSessionClient
|
||||
|
||||
|
||||
@@ -74,6 +76,7 @@ class Skyvern:
|
||||
timeout=_defaulted_timeout,
|
||||
)
|
||||
self.agent = AgentClient(client_wrapper=self._client_wrapper)
|
||||
self.credentials = CredentialsClient(client_wrapper=self._client_wrapper)
|
||||
self.browser_session = BrowserSessionClient(client_wrapper=self._client_wrapper)
|
||||
|
||||
|
||||
@@ -140,6 +143,7 @@ class AsyncSkyvern:
|
||||
timeout=_defaulted_timeout,
|
||||
)
|
||||
self.agent = AsyncAgentClient(client_wrapper=self._client_wrapper)
|
||||
self.credentials = AsyncCredentialsClient(client_wrapper=self._client_wrapper)
|
||||
self.browser_session = AsyncBrowserSessionClient(client_wrapper=self._client_wrapper)
|
||||
|
||||
|
||||
|
||||
@@ -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.74",
|
||||
"X-Fern-SDK-Version": "0.1.82",
|
||||
}
|
||||
if self._api_key is not None:
|
||||
headers["x-api-key"] = self._api_key
|
||||
|
||||
5
skyvern/client/credentials/__init__.py
Normal file
5
skyvern/client/credentials/__init__.py
Normal file
@@ -0,0 +1,5 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
from .types import CreateCredentialRequestCredential
|
||||
|
||||
__all__ = ["CreateCredentialRequestCredential"]
|
||||
598
skyvern/client/credentials/client.py
Normal file
598
skyvern/client/credentials/client.py
Normal file
@@ -0,0 +1,598 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
import typing
|
||||
from ..core.client_wrapper import SyncClientWrapper
|
||||
from ..core.request_options import RequestOptions
|
||||
from ..types.credential_response import CredentialResponse
|
||||
from ..core.pydantic_utilities import parse_obj_as
|
||||
from ..errors.unprocessable_entity_error import UnprocessableEntityError
|
||||
from json.decoder import JSONDecodeError
|
||||
from ..core.api_error import ApiError
|
||||
from ..types.credential_type import CredentialType
|
||||
from .types.create_credential_request_credential import CreateCredentialRequestCredential
|
||||
from ..core.serialization import convert_and_respect_annotation_metadata
|
||||
from ..core.jsonable_encoder import jsonable_encoder
|
||||
from ..core.client_wrapper import AsyncClientWrapper
|
||||
|
||||
# this is used as the default value for optional parameters
|
||||
OMIT = typing.cast(typing.Any, ...)
|
||||
|
||||
|
||||
class CredentialsClient:
|
||||
def __init__(self, *, client_wrapper: SyncClientWrapper):
|
||||
self._client_wrapper = client_wrapper
|
||||
|
||||
def get_credentials(
|
||||
self,
|
||||
*,
|
||||
page: typing.Optional[int] = None,
|
||||
page_size: typing.Optional[int] = None,
|
||||
request_options: typing.Optional[RequestOptions] = None,
|
||||
) -> typing.List[CredentialResponse]:
|
||||
"""
|
||||
Retrieves a paginated list of credentials for the current organization
|
||||
|
||||
Parameters
|
||||
----------
|
||||
page : typing.Optional[int]
|
||||
Page number for pagination
|
||||
|
||||
page_size : typing.Optional[int]
|
||||
Number of items per page
|
||||
|
||||
request_options : typing.Optional[RequestOptions]
|
||||
Request-specific configuration.
|
||||
|
||||
Returns
|
||||
-------
|
||||
typing.List[CredentialResponse]
|
||||
Successful Response
|
||||
|
||||
Examples
|
||||
--------
|
||||
from skyvern import Skyvern
|
||||
|
||||
client = Skyvern(
|
||||
api_key="YOUR_API_KEY",
|
||||
authorization="YOUR_AUTHORIZATION",
|
||||
)
|
||||
client.credentials.get_credentials()
|
||||
"""
|
||||
_response = self._client_wrapper.httpx_client.request(
|
||||
"v1/credentials",
|
||||
method="GET",
|
||||
params={
|
||||
"page": page,
|
||||
"page_size": page_size,
|
||||
},
|
||||
request_options=request_options,
|
||||
)
|
||||
try:
|
||||
if 200 <= _response.status_code < 300:
|
||||
return typing.cast(
|
||||
typing.List[CredentialResponse],
|
||||
parse_obj_as(
|
||||
type_=typing.List[CredentialResponse], # 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 create_credential(
|
||||
self,
|
||||
*,
|
||||
name: str,
|
||||
credential_type: CredentialType,
|
||||
credential: CreateCredentialRequestCredential,
|
||||
request_options: typing.Optional[RequestOptions] = None,
|
||||
) -> CredentialResponse:
|
||||
"""
|
||||
Creates a new credential for the current organization
|
||||
|
||||
Parameters
|
||||
----------
|
||||
name : str
|
||||
Name of the credential
|
||||
|
||||
credential_type : CredentialType
|
||||
Type of credential to create
|
||||
|
||||
credential : CreateCredentialRequestCredential
|
||||
The credential data to store
|
||||
|
||||
request_options : typing.Optional[RequestOptions]
|
||||
Request-specific configuration.
|
||||
|
||||
Returns
|
||||
-------
|
||||
CredentialResponse
|
||||
Successful Response
|
||||
|
||||
Examples
|
||||
--------
|
||||
from skyvern import NonEmptyPasswordCredential, Skyvern
|
||||
|
||||
client = Skyvern(
|
||||
api_key="YOUR_API_KEY",
|
||||
authorization="YOUR_AUTHORIZATION",
|
||||
)
|
||||
client.credentials.create_credential(
|
||||
name="My Credential",
|
||||
credential_type="password",
|
||||
credential=NonEmptyPasswordCredential(
|
||||
password="securepassword123",
|
||||
username="user@example.com",
|
||||
totp="JBSWY3DPEHPK3PXP",
|
||||
),
|
||||
)
|
||||
"""
|
||||
_response = self._client_wrapper.httpx_client.request(
|
||||
"v1/credentials",
|
||||
method="POST",
|
||||
json={
|
||||
"name": name,
|
||||
"credential_type": credential_type,
|
||||
"credential": convert_and_respect_annotation_metadata(
|
||||
object_=credential, annotation=CreateCredentialRequestCredential, direction="write"
|
||||
),
|
||||
},
|
||||
headers={
|
||||
"content-type": "application/json",
|
||||
},
|
||||
request_options=request_options,
|
||||
omit=OMIT,
|
||||
)
|
||||
try:
|
||||
if 200 <= _response.status_code < 300:
|
||||
return typing.cast(
|
||||
CredentialResponse,
|
||||
parse_obj_as(
|
||||
type_=CredentialResponse, # 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 get_credential(
|
||||
self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
|
||||
) -> CredentialResponse:
|
||||
"""
|
||||
Retrieves a specific credential by its ID
|
||||
|
||||
Parameters
|
||||
----------
|
||||
credential_id : str
|
||||
The unique identifier of the credential
|
||||
|
||||
request_options : typing.Optional[RequestOptions]
|
||||
Request-specific configuration.
|
||||
|
||||
Returns
|
||||
-------
|
||||
CredentialResponse
|
||||
Successful Response
|
||||
|
||||
Examples
|
||||
--------
|
||||
from skyvern import Skyvern
|
||||
|
||||
client = Skyvern(
|
||||
api_key="YOUR_API_KEY",
|
||||
authorization="YOUR_AUTHORIZATION",
|
||||
)
|
||||
client.credentials.get_credential(
|
||||
credential_id="cred_1234567890",
|
||||
)
|
||||
"""
|
||||
_response = self._client_wrapper.httpx_client.request(
|
||||
f"v1/credentials/{jsonable_encoder(credential_id)}",
|
||||
method="GET",
|
||||
request_options=request_options,
|
||||
)
|
||||
try:
|
||||
if 200 <= _response.status_code < 300:
|
||||
return typing.cast(
|
||||
CredentialResponse,
|
||||
parse_obj_as(
|
||||
type_=CredentialResponse, # 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_credential(self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None:
|
||||
"""
|
||||
Deletes a specific credential by its ID
|
||||
|
||||
Parameters
|
||||
----------
|
||||
credential_id : str
|
||||
The unique identifier of the credential to delete
|
||||
|
||||
request_options : typing.Optional[RequestOptions]
|
||||
Request-specific configuration.
|
||||
|
||||
Returns
|
||||
-------
|
||||
None
|
||||
|
||||
Examples
|
||||
--------
|
||||
from skyvern import Skyvern
|
||||
|
||||
client = Skyvern(
|
||||
api_key="YOUR_API_KEY",
|
||||
authorization="YOUR_AUTHORIZATION",
|
||||
)
|
||||
client.credentials.delete_credential(
|
||||
credential_id="cred_1234567890",
|
||||
)
|
||||
"""
|
||||
_response = self._client_wrapper.httpx_client.request(
|
||||
f"v1/credentials/{jsonable_encoder(credential_id)}/delete",
|
||||
method="POST",
|
||||
request_options=request_options,
|
||||
)
|
||||
try:
|
||||
if 200 <= _response.status_code < 300:
|
||||
return
|
||||
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)
|
||||
|
||||
|
||||
class AsyncCredentialsClient:
|
||||
def __init__(self, *, client_wrapper: AsyncClientWrapper):
|
||||
self._client_wrapper = client_wrapper
|
||||
|
||||
async def get_credentials(
|
||||
self,
|
||||
*,
|
||||
page: typing.Optional[int] = None,
|
||||
page_size: typing.Optional[int] = None,
|
||||
request_options: typing.Optional[RequestOptions] = None,
|
||||
) -> typing.List[CredentialResponse]:
|
||||
"""
|
||||
Retrieves a paginated list of credentials for the current organization
|
||||
|
||||
Parameters
|
||||
----------
|
||||
page : typing.Optional[int]
|
||||
Page number for pagination
|
||||
|
||||
page_size : typing.Optional[int]
|
||||
Number of items per page
|
||||
|
||||
request_options : typing.Optional[RequestOptions]
|
||||
Request-specific configuration.
|
||||
|
||||
Returns
|
||||
-------
|
||||
typing.List[CredentialResponse]
|
||||
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.credentials.get_credentials()
|
||||
|
||||
|
||||
asyncio.run(main())
|
||||
"""
|
||||
_response = await self._client_wrapper.httpx_client.request(
|
||||
"v1/credentials",
|
||||
method="GET",
|
||||
params={
|
||||
"page": page,
|
||||
"page_size": page_size,
|
||||
},
|
||||
request_options=request_options,
|
||||
)
|
||||
try:
|
||||
if 200 <= _response.status_code < 300:
|
||||
return typing.cast(
|
||||
typing.List[CredentialResponse],
|
||||
parse_obj_as(
|
||||
type_=typing.List[CredentialResponse], # 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 create_credential(
|
||||
self,
|
||||
*,
|
||||
name: str,
|
||||
credential_type: CredentialType,
|
||||
credential: CreateCredentialRequestCredential,
|
||||
request_options: typing.Optional[RequestOptions] = None,
|
||||
) -> CredentialResponse:
|
||||
"""
|
||||
Creates a new credential for the current organization
|
||||
|
||||
Parameters
|
||||
----------
|
||||
name : str
|
||||
Name of the credential
|
||||
|
||||
credential_type : CredentialType
|
||||
Type of credential to create
|
||||
|
||||
credential : CreateCredentialRequestCredential
|
||||
The credential data to store
|
||||
|
||||
request_options : typing.Optional[RequestOptions]
|
||||
Request-specific configuration.
|
||||
|
||||
Returns
|
||||
-------
|
||||
CredentialResponse
|
||||
Successful Response
|
||||
|
||||
Examples
|
||||
--------
|
||||
import asyncio
|
||||
|
||||
from skyvern import AsyncSkyvern, NonEmptyPasswordCredential
|
||||
|
||||
client = AsyncSkyvern(
|
||||
api_key="YOUR_API_KEY",
|
||||
authorization="YOUR_AUTHORIZATION",
|
||||
)
|
||||
|
||||
|
||||
async def main() -> None:
|
||||
await client.credentials.create_credential(
|
||||
name="My Credential",
|
||||
credential_type="password",
|
||||
credential=NonEmptyPasswordCredential(
|
||||
password="securepassword123",
|
||||
username="user@example.com",
|
||||
totp="JBSWY3DPEHPK3PXP",
|
||||
),
|
||||
)
|
||||
|
||||
|
||||
asyncio.run(main())
|
||||
"""
|
||||
_response = await self._client_wrapper.httpx_client.request(
|
||||
"v1/credentials",
|
||||
method="POST",
|
||||
json={
|
||||
"name": name,
|
||||
"credential_type": credential_type,
|
||||
"credential": convert_and_respect_annotation_metadata(
|
||||
object_=credential, annotation=CreateCredentialRequestCredential, direction="write"
|
||||
),
|
||||
},
|
||||
headers={
|
||||
"content-type": "application/json",
|
||||
},
|
||||
request_options=request_options,
|
||||
omit=OMIT,
|
||||
)
|
||||
try:
|
||||
if 200 <= _response.status_code < 300:
|
||||
return typing.cast(
|
||||
CredentialResponse,
|
||||
parse_obj_as(
|
||||
type_=CredentialResponse, # 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 get_credential(
|
||||
self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
|
||||
) -> CredentialResponse:
|
||||
"""
|
||||
Retrieves a specific credential by its ID
|
||||
|
||||
Parameters
|
||||
----------
|
||||
credential_id : str
|
||||
The unique identifier of the credential
|
||||
|
||||
request_options : typing.Optional[RequestOptions]
|
||||
Request-specific configuration.
|
||||
|
||||
Returns
|
||||
-------
|
||||
CredentialResponse
|
||||
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.credentials.get_credential(
|
||||
credential_id="cred_1234567890",
|
||||
)
|
||||
|
||||
|
||||
asyncio.run(main())
|
||||
"""
|
||||
_response = await self._client_wrapper.httpx_client.request(
|
||||
f"v1/credentials/{jsonable_encoder(credential_id)}",
|
||||
method="GET",
|
||||
request_options=request_options,
|
||||
)
|
||||
try:
|
||||
if 200 <= _response.status_code < 300:
|
||||
return typing.cast(
|
||||
CredentialResponse,
|
||||
parse_obj_as(
|
||||
type_=CredentialResponse, # 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_credential(
|
||||
self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
|
||||
) -> None:
|
||||
"""
|
||||
Deletes a specific credential by its ID
|
||||
|
||||
Parameters
|
||||
----------
|
||||
credential_id : str
|
||||
The unique identifier of the credential to delete
|
||||
|
||||
request_options : typing.Optional[RequestOptions]
|
||||
Request-specific configuration.
|
||||
|
||||
Returns
|
||||
-------
|
||||
None
|
||||
|
||||
Examples
|
||||
--------
|
||||
import asyncio
|
||||
|
||||
from skyvern import AsyncSkyvern
|
||||
|
||||
client = AsyncSkyvern(
|
||||
api_key="YOUR_API_KEY",
|
||||
authorization="YOUR_AUTHORIZATION",
|
||||
)
|
||||
|
||||
|
||||
async def main() -> None:
|
||||
await client.credentials.delete_credential(
|
||||
credential_id="cred_1234567890",
|
||||
)
|
||||
|
||||
|
||||
asyncio.run(main())
|
||||
"""
|
||||
_response = await self._client_wrapper.httpx_client.request(
|
||||
f"v1/credentials/{jsonable_encoder(credential_id)}/delete",
|
||||
method="POST",
|
||||
request_options=request_options,
|
||||
)
|
||||
try:
|
||||
if 200 <= _response.status_code < 300:
|
||||
return
|
||||
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)
|
||||
5
skyvern/client/credentials/types/__init__.py
Normal file
5
skyvern/client/credentials/types/__init__.py
Normal file
@@ -0,0 +1,5 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
from .create_credential_request_credential import CreateCredentialRequestCredential
|
||||
|
||||
__all__ = ["CreateCredentialRequestCredential"]
|
||||
@@ -0,0 +1,7 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
import typing
|
||||
from ...types.non_empty_password_credential import NonEmptyPasswordCredential
|
||||
from ...types.non_empty_credit_card_credential import NonEmptyCreditCardCredential
|
||||
|
||||
CreateCredentialRequestCredential = typing.Union[NonEmptyPasswordCredential, NonEmptyCreditCardCredential]
|
||||
@@ -31,7 +31,23 @@ from .code_block_parameters_item import (
|
||||
CodeBlockParametersItem_Workflow,
|
||||
)
|
||||
from .context_parameter import ContextParameter
|
||||
from .context_parameter_source import (
|
||||
ContextParameterSource,
|
||||
ContextParameterSource_AwsSecret,
|
||||
ContextParameterSource_BitwardenCreditCardData,
|
||||
ContextParameterSource_BitwardenLoginCredential,
|
||||
ContextParameterSource_BitwardenSensitiveInformation,
|
||||
ContextParameterSource_Context,
|
||||
ContextParameterSource_Credential,
|
||||
ContextParameterSource_Output,
|
||||
ContextParameterSource_Workflow,
|
||||
)
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .credential_parameter import CredentialParameter
|
||||
from .credential_response import CredentialResponse
|
||||
from .credential_response_credential import CredentialResponseCredential
|
||||
from .credential_type import CredentialType
|
||||
from .credit_card_credential_response import CreditCardCredentialResponse
|
||||
from .download_to_s3block import DownloadToS3Block
|
||||
from .extraction_block import ExtractionBlock
|
||||
from .extraction_block_data_schema import ExtractionBlockDataSchema
|
||||
@@ -125,24 +141,15 @@ from .navigation_block_parameters_item import (
|
||||
NavigationBlockParametersItem_Output,
|
||||
NavigationBlockParametersItem_Workflow,
|
||||
)
|
||||
from .output import Output
|
||||
from .non_empty_credit_card_credential import NonEmptyCreditCardCredential
|
||||
from .non_empty_password_credential import NonEmptyPasswordCredential
|
||||
from .output_parameter import OutputParameter
|
||||
from .password_credential_response import PasswordCredentialResponse
|
||||
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 (
|
||||
@@ -159,6 +166,7 @@ from .task_block_parameters_item import (
|
||||
from .task_run_request import TaskRunRequest
|
||||
from .task_run_request_data_extraction_schema import TaskRunRequestDataExtractionSchema
|
||||
from .task_run_response import TaskRunResponse
|
||||
from .task_run_response_output import TaskRunResponseOutput
|
||||
from .task_v2block import TaskV2Block
|
||||
from .text_prompt_block import TextPromptBlock
|
||||
from .text_prompt_block_parameters_item import (
|
||||
@@ -201,7 +209,6 @@ from .validation_block_parameters_item import (
|
||||
)
|
||||
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,
|
||||
@@ -254,6 +261,7 @@ 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_run_response_output import WorkflowRunResponseOutput
|
||||
from .workflow_status import WorkflowStatus
|
||||
|
||||
__all__ = [
|
||||
@@ -284,7 +292,21 @@ __all__ = [
|
||||
"CodeBlockParametersItem_Output",
|
||||
"CodeBlockParametersItem_Workflow",
|
||||
"ContextParameter",
|
||||
"ContextParameterSource",
|
||||
"ContextParameterSource_AwsSecret",
|
||||
"ContextParameterSource_BitwardenCreditCardData",
|
||||
"ContextParameterSource_BitwardenLoginCredential",
|
||||
"ContextParameterSource_BitwardenSensitiveInformation",
|
||||
"ContextParameterSource_Context",
|
||||
"ContextParameterSource_Credential",
|
||||
"ContextParameterSource_Output",
|
||||
"ContextParameterSource_Workflow",
|
||||
"ContextParameterValue",
|
||||
"CredentialParameter",
|
||||
"CredentialResponse",
|
||||
"CredentialResponseCredential",
|
||||
"CredentialType",
|
||||
"CreditCardCredentialResponse",
|
||||
"DownloadToS3Block",
|
||||
"ExtractionBlock",
|
||||
"ExtractionBlockDataSchema",
|
||||
@@ -366,22 +388,15 @@ __all__ = [
|
||||
"NavigationBlockParametersItem_Credential",
|
||||
"NavigationBlockParametersItem_Output",
|
||||
"NavigationBlockParametersItem_Workflow",
|
||||
"Output",
|
||||
"NonEmptyCreditCardCredential",
|
||||
"NonEmptyPasswordCredential",
|
||||
"OutputParameter",
|
||||
"PasswordCredentialResponse",
|
||||
"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",
|
||||
@@ -396,6 +411,7 @@ __all__ = [
|
||||
"TaskRunRequest",
|
||||
"TaskRunRequestDataExtractionSchema",
|
||||
"TaskRunResponse",
|
||||
"TaskRunResponseOutput",
|
||||
"TaskV2Block",
|
||||
"TextPromptBlock",
|
||||
"TextPromptBlockParametersItem",
|
||||
@@ -432,7 +448,6 @@ __all__ = [
|
||||
"ValidationBlockParametersItem_Workflow",
|
||||
"ValidationError",
|
||||
"ValidationErrorLocItem",
|
||||
"Value",
|
||||
"WaitBlock",
|
||||
"WaitBlockParametersItem",
|
||||
"WaitBlockParametersItem_AwsSecret",
|
||||
@@ -479,5 +494,6 @@ __all__ = [
|
||||
"WorkflowParameterType",
|
||||
"WorkflowRunRequest",
|
||||
"WorkflowRunResponse",
|
||||
"WorkflowRunResponseOutput",
|
||||
"WorkflowStatus",
|
||||
]
|
||||
|
||||
@@ -4,6 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
from .output_parameter import OutputParameter
|
||||
import typing
|
||||
from .run_engine import RunEngine
|
||||
from .action_block_data_schema import ActionBlockDataSchema
|
||||
from .action_block_parameters_item import ActionBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -17,6 +18,7 @@ class ActionBlock(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class ActionBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class ActionBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class ActionBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class CodeBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class CodeBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class CodeBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
from __future__ import annotations
|
||||
from ..core.pydantic_utilities import UniversalBaseModel
|
||||
import typing
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -12,8 +12,8 @@ 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
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -25,6 +25,6 @@ class ContextParameter(UniversalBaseModel):
|
||||
extra = pydantic.Extra.allow
|
||||
|
||||
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
update_forward_refs(ContextParameter)
|
||||
|
||||
@@ -8,11 +8,11 @@ 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 .context_parameter_value import ContextParameterValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
|
||||
|
||||
class Source_Workflow(UniversalBaseModel):
|
||||
class ContextParameterSource_Workflow(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["workflow"] = "workflow"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
@@ -34,12 +34,12 @@ class Source_Workflow(UniversalBaseModel):
|
||||
extra = pydantic.Extra.allow
|
||||
|
||||
|
||||
class Source_Context(UniversalBaseModel):
|
||||
class ContextParameterSource_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -54,7 +54,7 @@ class Source_Context(UniversalBaseModel):
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
|
||||
|
||||
class Source_AwsSecret(UniversalBaseModel):
|
||||
class ContextParameterSource_AwsSecret(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["aws_secret"] = "aws_secret"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
@@ -75,7 +75,7 @@ class Source_AwsSecret(UniversalBaseModel):
|
||||
extra = pydantic.Extra.allow
|
||||
|
||||
|
||||
class Source_BitwardenLoginCredential(UniversalBaseModel):
|
||||
class ContextParameterSource_BitwardenLoginCredential(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
@@ -101,7 +101,7 @@ class Source_BitwardenLoginCredential(UniversalBaseModel):
|
||||
extra = pydantic.Extra.allow
|
||||
|
||||
|
||||
class Source_BitwardenSensitiveInformation(UniversalBaseModel):
|
||||
class ContextParameterSource_BitwardenSensitiveInformation(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
@@ -127,7 +127,7 @@ class Source_BitwardenSensitiveInformation(UniversalBaseModel):
|
||||
extra = pydantic.Extra.allow
|
||||
|
||||
|
||||
class Source_BitwardenCreditCardData(UniversalBaseModel):
|
||||
class ContextParameterSource_BitwardenCreditCardData(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
@@ -152,7 +152,7 @@ class Source_BitwardenCreditCardData(UniversalBaseModel):
|
||||
extra = pydantic.Extra.allow
|
||||
|
||||
|
||||
class Source_Output(UniversalBaseModel):
|
||||
class ContextParameterSource_Output(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["output"] = "output"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
@@ -172,7 +172,7 @@ class Source_Output(UniversalBaseModel):
|
||||
extra = pydantic.Extra.allow
|
||||
|
||||
|
||||
class Source_Credential(UniversalBaseModel):
|
||||
class ContextParameterSource_Credential(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["credential"] = "credential"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
@@ -193,14 +193,14 @@ class Source_Credential(UniversalBaseModel):
|
||||
extra = pydantic.Extra.allow
|
||||
|
||||
|
||||
Source = typing.Union[
|
||||
Source_Workflow,
|
||||
Source_Context,
|
||||
Source_AwsSecret,
|
||||
Source_BitwardenLoginCredential,
|
||||
Source_BitwardenSensitiveInformation,
|
||||
Source_BitwardenCreditCardData,
|
||||
Source_Output,
|
||||
Source_Credential,
|
||||
ContextParameterSource = typing.Union[
|
||||
ContextParameterSource_Workflow,
|
||||
ContextParameterSource_Context,
|
||||
ContextParameterSource_AwsSecret,
|
||||
ContextParameterSource_BitwardenLoginCredential,
|
||||
ContextParameterSource_BitwardenSensitiveInformation,
|
||||
ContextParameterSource_BitwardenCreditCardData,
|
||||
ContextParameterSource_Output,
|
||||
ContextParameterSource_Credential,
|
||||
]
|
||||
update_forward_refs(Source_Context)
|
||||
update_forward_refs(ContextParameterSource_Context)
|
||||
@@ -2,6 +2,6 @@
|
||||
|
||||
import typing
|
||||
|
||||
Value = typing.Union[
|
||||
ContextParameterValue = typing.Union[
|
||||
str, int, float, bool, typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]]
|
||||
]
|
||||
43
skyvern/client/types/credential_response.py
Normal file
43
skyvern/client/types/credential_response.py
Normal file
@@ -0,0 +1,43 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
from ..core.pydantic_utilities import UniversalBaseModel
|
||||
import pydantic
|
||||
from .credential_response_credential import CredentialResponseCredential
|
||||
from .credential_type import CredentialType
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import typing
|
||||
|
||||
|
||||
class CredentialResponse(UniversalBaseModel):
|
||||
"""
|
||||
Response model for credential operations.
|
||||
"""
|
||||
|
||||
credential_id: str = pydantic.Field()
|
||||
"""
|
||||
Unique identifier for the credential
|
||||
"""
|
||||
|
||||
credential: CredentialResponseCredential = pydantic.Field()
|
||||
"""
|
||||
The credential data
|
||||
"""
|
||||
|
||||
credential_type: CredentialType = pydantic.Field()
|
||||
"""
|
||||
Type of the credential
|
||||
"""
|
||||
|
||||
name: str = pydantic.Field()
|
||||
"""
|
||||
Name of the credential
|
||||
"""
|
||||
|
||||
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
|
||||
7
skyvern/client/types/credential_response_credential.py
Normal file
7
skyvern/client/types/credential_response_credential.py
Normal file
@@ -0,0 +1,7 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
import typing
|
||||
from .password_credential_response import PasswordCredentialResponse
|
||||
from .credit_card_credential_response import CreditCardCredentialResponse
|
||||
|
||||
CredentialResponseCredential = typing.Union[PasswordCredentialResponse, CreditCardCredentialResponse]
|
||||
5
skyvern/client/types/credential_type.py
Normal file
5
skyvern/client/types/credential_type.py
Normal file
@@ -0,0 +1,5 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
import typing
|
||||
|
||||
CredentialType = typing.Union[typing.Literal["password", "credit_card"], typing.Any]
|
||||
31
skyvern/client/types/credit_card_credential_response.py
Normal file
31
skyvern/client/types/credit_card_credential_response.py
Normal file
@@ -0,0 +1,31 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
from ..core.pydantic_utilities import UniversalBaseModel
|
||||
import pydantic
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import typing
|
||||
|
||||
|
||||
class CreditCardCredentialResponse(UniversalBaseModel):
|
||||
"""
|
||||
Response model for credit card credentials, containing only the last four digits and brand.
|
||||
"""
|
||||
|
||||
last_four: str = pydantic.Field()
|
||||
"""
|
||||
Last four digits of the credit card number
|
||||
"""
|
||||
|
||||
brand: str = pydantic.Field()
|
||||
"""
|
||||
Brand of the credit card
|
||||
"""
|
||||
|
||||
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
|
||||
@@ -4,6 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
from .output_parameter import OutputParameter
|
||||
import typing
|
||||
from .run_engine import RunEngine
|
||||
from .extraction_block_data_schema import ExtractionBlockDataSchema
|
||||
from .extraction_block_parameters_item import ExtractionBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -17,6 +18,7 @@ class ExtractionBlock(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class ExtractionBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class ExtractionBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class ExtractionBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -4,6 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
from .output_parameter import OutputParameter
|
||||
import typing
|
||||
from .run_engine import RunEngine
|
||||
from .file_download_block_data_schema import FileDownloadBlockDataSchema
|
||||
from .file_download_block_parameters_item import FileDownloadBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -17,6 +18,7 @@ class FileDownloadBlock(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class FileDownloadBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class FileDownloadBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class FileDownloadBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -5,6 +5,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
import typing
|
||||
from .output_parameter import OutputParameter
|
||||
from .run_engine import RunEngine
|
||||
from .action_block_data_schema import ActionBlockDataSchema
|
||||
from .action_block_parameters_item import ActionBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -43,6 +44,7 @@ class ForLoopBlockLoopBlocksItem_Action(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -112,6 +114,7 @@ class ForLoopBlockLoopBlocksItem_Extraction(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -146,6 +149,7 @@ class ForLoopBlockLoopBlocksItem_FileDownload(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -243,6 +247,7 @@ class ForLoopBlockLoopBlocksItem_GotoUrl(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: str
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -277,6 +282,7 @@ class ForLoopBlockLoopBlocksItem_Login(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -311,6 +317,7 @@ class ForLoopBlockLoopBlocksItem_Navigation(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: str
|
||||
@@ -388,6 +395,7 @@ class ForLoopBlockLoopBlocksItem_Task(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -481,6 +489,7 @@ class ForLoopBlockLoopBlocksItem_Validation(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class ForLoopBlockLoopOver_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class ForLoopBlockLoopOver_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class ForLoopBlockLoopOver_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -4,6 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
from .output_parameter import OutputParameter
|
||||
import typing
|
||||
from .run_engine import RunEngine
|
||||
from .login_block_data_schema import LoginBlockDataSchema
|
||||
from .login_block_parameters_item import LoginBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -17,6 +18,7 @@ class LoginBlock(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class LoginBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class LoginBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class LoginBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -4,6 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
from .output_parameter import OutputParameter
|
||||
import typing
|
||||
from .run_engine import RunEngine
|
||||
from .navigation_block_data_schema import NavigationBlockDataSchema
|
||||
from .navigation_block_parameters_item import NavigationBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -17,6 +18,7 @@ class NavigationBlock(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: str
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class NavigationBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class NavigationBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class NavigationBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
51
skyvern/client/types/non_empty_credit_card_credential.py
Normal file
51
skyvern/client/types/non_empty_credit_card_credential.py
Normal file
@@ -0,0 +1,51 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
from ..core.pydantic_utilities import UniversalBaseModel
|
||||
import pydantic
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import typing
|
||||
|
||||
|
||||
class NonEmptyCreditCardCredential(UniversalBaseModel):
|
||||
"""
|
||||
Credit card credential model that requires non-empty values.
|
||||
"""
|
||||
|
||||
card_number: str = pydantic.Field()
|
||||
"""
|
||||
The full credit card number (must not be empty)
|
||||
"""
|
||||
|
||||
card_cvv: str = pydantic.Field()
|
||||
"""
|
||||
The card's CVV (must not be empty)
|
||||
"""
|
||||
|
||||
card_exp_month: str = pydantic.Field()
|
||||
"""
|
||||
The card's expiration month (must not be empty)
|
||||
"""
|
||||
|
||||
card_exp_year: str = pydantic.Field()
|
||||
"""
|
||||
The card's expiration year (must not be empty)
|
||||
"""
|
||||
|
||||
card_brand: str = pydantic.Field()
|
||||
"""
|
||||
The card's brand (must not be empty)
|
||||
"""
|
||||
|
||||
card_holder_name: str = pydantic.Field()
|
||||
"""
|
||||
The name of the card holder (must not be empty)
|
||||
"""
|
||||
|
||||
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
|
||||
36
skyvern/client/types/non_empty_password_credential.py
Normal file
36
skyvern/client/types/non_empty_password_credential.py
Normal file
@@ -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 NonEmptyPasswordCredential(UniversalBaseModel):
|
||||
"""
|
||||
Password credential model that requires non-empty values.
|
||||
"""
|
||||
|
||||
password: str = pydantic.Field()
|
||||
"""
|
||||
The password value (must not be empty)
|
||||
"""
|
||||
|
||||
username: str = pydantic.Field()
|
||||
"""
|
||||
The username associated with the credential (must not be empty)
|
||||
"""
|
||||
|
||||
totp: typing.Optional[str] = pydantic.Field(default=None)
|
||||
"""
|
||||
Optional TOTP (Time-based One-Time Password) string used to generate 2FA codes
|
||||
"""
|
||||
|
||||
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
|
||||
@@ -1,5 +0,0 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
import typing
|
||||
|
||||
Output = typing.Union[typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]], str]
|
||||
26
skyvern/client/types/password_credential_response.py
Normal file
26
skyvern/client/types/password_credential_response.py
Normal file
@@ -0,0 +1,26 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
from ..core.pydantic_utilities import UniversalBaseModel
|
||||
import pydantic
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import typing
|
||||
|
||||
|
||||
class PasswordCredentialResponse(UniversalBaseModel):
|
||||
"""
|
||||
Response model for password credentials, containing only the username.
|
||||
"""
|
||||
|
||||
username: str = pydantic.Field()
|
||||
"""
|
||||
The username associated with the credential
|
||||
"""
|
||||
|
||||
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
|
||||
@@ -2,4 +2,4 @@
|
||||
|
||||
import typing
|
||||
|
||||
RunEngine = typing.Union[typing.Literal["skyvern-1.0", "skyvern-2.0", "openai-cua"], typing.Any]
|
||||
RunEngine = typing.Union[typing.Literal["skyvern-1.0", "skyvern-2.0", "openai-cua", "anthropic-cua"], typing.Any]
|
||||
|
||||
@@ -4,6 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
from .output_parameter import OutputParameter
|
||||
import typing
|
||||
from .run_engine import RunEngine
|
||||
from .task_block_data_schema import TaskBlockDataSchema
|
||||
from .task_block_parameters_item import TaskBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -17,6 +18,7 @@ class TaskBlock(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class TaskBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class TaskBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class TaskBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -4,7 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
import pydantic
|
||||
from .run_status import RunStatus
|
||||
import typing
|
||||
from .output import Output
|
||||
from .task_run_response_output import TaskRunResponseOutput
|
||||
from .file_info import FileInfo
|
||||
import datetime as dt
|
||||
from .task_run_request import TaskRunRequest
|
||||
@@ -22,7 +22,7 @@ class TaskRunResponse(UniversalBaseModel):
|
||||
Current status of the run
|
||||
"""
|
||||
|
||||
output: typing.Optional[Output] = pydantic.Field(default=None)
|
||||
output: typing.Optional[TaskRunResponseOutput] = pydantic.Field(default=None)
|
||||
"""
|
||||
Output data from the run, if any. Format depends on the schema in the input
|
||||
"""
|
||||
@@ -52,6 +52,11 @@ class TaskRunResponse(UniversalBaseModel):
|
||||
Timestamp when this run was last modified
|
||||
"""
|
||||
|
||||
app_url: typing.Optional[str] = pydantic.Field(default=None)
|
||||
"""
|
||||
URL to the application UI where the run can be viewed
|
||||
"""
|
||||
|
||||
run_request: typing.Optional[TaskRunRequest] = pydantic.Field(default=None)
|
||||
"""
|
||||
The original request parameters used to start this task run
|
||||
|
||||
7
skyvern/client/types/task_run_response_output.py
Normal file
7
skyvern/client/types/task_run_response_output.py
Normal file
@@ -0,0 +1,7 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
import typing
|
||||
|
||||
TaskRunResponseOutput = typing.Union[
|
||||
typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]], str
|
||||
]
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class TextPromptBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class TextPromptBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class TextPromptBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -4,6 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
from .output_parameter import OutputParameter
|
||||
import typing
|
||||
from .run_engine import RunEngine
|
||||
from .url_block_data_schema import UrlBlockDataSchema
|
||||
from .url_block_parameters_item import UrlBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -17,6 +18,7 @@ class UrlBlock(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: str
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class UrlBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class UrlBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class UrlBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -4,6 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
from .output_parameter import OutputParameter
|
||||
import typing
|
||||
from .run_engine import RunEngine
|
||||
from .validation_block_data_schema import ValidationBlockDataSchema
|
||||
from .validation_block_parameters_item import ValidationBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -17,6 +18,7 @@ class ValidationBlock(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class ValidationBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class ValidationBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class ValidationBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class WaitBlockParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class WaitBlockParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class WaitBlockParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -5,6 +5,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
from .context_parameter import ContextParameter
|
||||
import typing
|
||||
from .output_parameter import OutputParameter
|
||||
from .run_engine import RunEngine
|
||||
from .action_block_data_schema import ActionBlockDataSchema
|
||||
from .action_block_parameters_item import ActionBlockParametersItem
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
@@ -43,6 +44,7 @@ class WorkflowDefinitionBlocksItem_Action(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -112,6 +114,7 @@ class WorkflowDefinitionBlocksItem_Extraction(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -146,6 +149,7 @@ class WorkflowDefinitionBlocksItem_FileDownload(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -244,6 +248,7 @@ class WorkflowDefinitionBlocksItem_GotoUrl(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: str
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -278,6 +283,7 @@ class WorkflowDefinitionBlocksItem_Login(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -312,6 +318,7 @@ class WorkflowDefinitionBlocksItem_Navigation(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: str
|
||||
@@ -389,6 +396,7 @@ class WorkflowDefinitionBlocksItem_Task(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
@@ -482,6 +490,7 @@ class WorkflowDefinitionBlocksItem_Validation(UniversalBaseModel):
|
||||
task_type: typing.Optional[str] = None
|
||||
url: typing.Optional[str] = None
|
||||
title: typing.Optional[str] = None
|
||||
engine: typing.Optional[RunEngine] = None
|
||||
complete_criterion: typing.Optional[str] = None
|
||||
terminate_criterion: typing.Optional[str] = None
|
||||
navigation_goal: typing.Optional[str] = None
|
||||
|
||||
@@ -6,7 +6,7 @@ import typing
|
||||
import datetime as dt
|
||||
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
||||
import pydantic
|
||||
from .value import Value
|
||||
from .context_parameter_value import ContextParameterValue
|
||||
from .workflow_parameter_type import WorkflowParameterType
|
||||
from .workflow_parameter_default_value import WorkflowParameterDefaultValue
|
||||
from ..core.pydantic_utilities import update_forward_refs
|
||||
@@ -114,8 +114,8 @@ class WorkflowDefinitionParametersItem_Context(UniversalBaseModel):
|
||||
parameter_type: typing.Literal["context"] = "context"
|
||||
key: str
|
||||
description: typing.Optional[str] = None
|
||||
source: "Source"
|
||||
value: typing.Optional[Value] = None
|
||||
source: "ContextParameterSource"
|
||||
value: typing.Optional[ContextParameterValue] = None
|
||||
|
||||
if IS_PYDANTIC_V2:
|
||||
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
||||
@@ -128,7 +128,7 @@ class WorkflowDefinitionParametersItem_Context(UniversalBaseModel):
|
||||
|
||||
|
||||
from .context_parameter import ContextParameter # noqa: E402
|
||||
from .source import Source # noqa: E402
|
||||
from .context_parameter_source import ContextParameterSource # noqa: E402
|
||||
|
||||
|
||||
class WorkflowDefinitionParametersItem_Credential(UniversalBaseModel):
|
||||
|
||||
@@ -4,7 +4,7 @@ from ..core.pydantic_utilities import UniversalBaseModel
|
||||
import pydantic
|
||||
from .run_status import RunStatus
|
||||
import typing
|
||||
from .output import Output
|
||||
from .workflow_run_response_output import WorkflowRunResponseOutput
|
||||
from .file_info import FileInfo
|
||||
import datetime as dt
|
||||
from .workflow_run_request import WorkflowRunRequest
|
||||
@@ -22,7 +22,7 @@ class WorkflowRunResponse(UniversalBaseModel):
|
||||
Current status of the run
|
||||
"""
|
||||
|
||||
output: typing.Optional[Output] = pydantic.Field(default=None)
|
||||
output: typing.Optional[WorkflowRunResponseOutput] = pydantic.Field(default=None)
|
||||
"""
|
||||
Output data from the run, if any. Format depends on the schema in the input
|
||||
"""
|
||||
@@ -52,6 +52,11 @@ class WorkflowRunResponse(UniversalBaseModel):
|
||||
Timestamp when this run was last modified
|
||||
"""
|
||||
|
||||
app_url: typing.Optional[str] = pydantic.Field(default=None)
|
||||
"""
|
||||
URL to the application UI where the run can be viewed
|
||||
"""
|
||||
|
||||
run_request: typing.Optional[WorkflowRunRequest] = pydantic.Field(default=None)
|
||||
"""
|
||||
The original request parameters used to start this workflow run
|
||||
|
||||
7
skyvern/client/types/workflow_run_response_output.py
Normal file
7
skyvern/client/types/workflow_run_response_output.py
Normal file
@@ -0,0 +1,7 @@
|
||||
# This file was auto-generated by Fern from our API Definition.
|
||||
|
||||
import typing
|
||||
|
||||
WorkflowRunResponseOutput = typing.Union[
|
||||
typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]], str
|
||||
]
|
||||
Reference in New Issue
Block a user