Skip to content

Automate browser based workflows with AI

Bump version to 1.0.47 (#7481)

Shuchang Zheng9fc0b2aee079
diff --git a/packages/skyvern-ui/pyproject.toml b/packages/skyvern-ui/pyproject.toml
index 491169847..1224c82fc 100644
--- a/packages/skyvern-ui/pyproject.toml
+++ b/packages/skyvern-ui/pyproject.toml
@@ -1,6 +1,6 @@
[project]
name = "skyvern-ui"
-version = "1.0.46"
+version = "1.0.47"
description = "Prebuilt Skyvern UI assets for the Skyvern CLI"
authors = [{ name = "Skyvern AI", email = "[email protected]" }]
requires-python = ">=3.11,<3.14"
diff --git a/pyproject.toml b/pyproject.toml
index efe54d138..cc34cd58b 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,6 +1,6 @@
[project]
name = "skyvern"
-version = "1.0.46"
+version = "1.0.47"
description = ""
authors = [{ name = "Skyvern AI", email = "[email protected]" }]
requires-python = ">=3.11,<3.14"
diff --git a/skyvern-ts/client/package-lock.json b/skyvern-ts/client/package-lock.json
index 25f801812..31a17a58c 100644
--- a/skyvern-ts/client/package-lock.json
+++ b/skyvern-ts/client/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "@skyvern/client",
- "version": "1.0.46",
+ "version": "1.0.47",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "@skyvern/client",
- "version": "1.0.46",
+ "version": "1.0.47",
"dependencies": {
"playwright": "^1.48.0"
},
diff --git a/skyvern-ts/client/package.json b/skyvern-ts/client/package.json
index 5c70691c4..76deb6b5d 100644
--- a/skyvern-ts/client/package.json
+++ b/skyvern-ts/client/package.json
@@ -1,6 +1,6 @@
{
"name": "@skyvern/client",
- "version": "1.0.46",
+ "version": "1.0.47",
"private": false,
"repository": {
"type": "git",
diff --git a/skyvern-ts/client/src/Client.ts b/skyvern-ts/client/src/Client.ts
index 02a008868..32590a614 100644
--- a/skyvern-ts/client/src/Client.ts
+++ b/skyvern-ts/client/src/Client.ts
@@ -32,8 +32,8 @@ export class SkyvernClient {
"x-api-key": _options?.apiKey,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "@skyvern/client",
- "X-Fern-SDK-Version": "1.0.45",
- "User-Agent": "@skyvern/client/1.0.45",
+ "X-Fern-SDK-Version": "1.0.47",
+ "User-Agent": "@skyvern/client/1.0.47",
"X-Fern-Runtime": core.RUNTIME.type,
"X-Fern-Runtime-Version": core.RUNTIME.version,
},
@@ -1303,22 +1303,28 @@ export class SkyvernClient {
}
/**
- * List all tag keys registered for the organization with their descriptions.
+ * Get the current tag state for a workflow run.
*
+ * @param {string} workflowRunId - Workflow run ID
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
+ * @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.listTagKeys()
+ * await client.getRunTags("wr_123")
*/
- public listTagKeys(requestOptions?: SkyvernClient.RequestOptions): core.HttpResponsePromise<Skyvern.TagKey[]> {
- return core.HttpResponsePromise.fromPromise(this.__listTagKeys(requestOptions));
+ public getRunTags(
+ workflowRunId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.RunTagsResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__getRunTags(workflowRunId, requestOptions));
}
- private async __listTagKeys(
+ private async __getRunTags(
+ workflowRunId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.TagKey[]>> {
+ ): Promise<core.WithRawResponse<Skyvern.RunTagsResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -1329,7 +1335,7 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/tag-keys",
+ `v1/runs/${core.url.encodePathParam(workflowRunId)}/tags`,
),
method: "GET",
headers: _headers,
@@ -1339,11 +1345,13 @@ export class SkyvernClient {
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.TagKey[], rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.RunTagsResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -1363,7 +1371,9 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/tag-keys.");
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling GET /v1/runs/{workflow_run_id}/tags.",
+ );
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -1373,28 +1383,31 @@ export class SkyvernClient {
}
/**
- * Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
+ * Atomically apply tag changes to a workflow run. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
*
- * @param {string} key - Tag key to delete
+ * @param {string} workflowRunId - Workflow run ID
+ * @param {Skyvern.TagApplyRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.deleteTagKey("env")
+ * await client.applyRunTags("wr_123", {})
*/
- public deleteTagKey(
- key: string,
+ public applyRunTags(
+ workflowRunId: string,
+ request: Skyvern.TagApplyRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.TagKeyDeleteResponse> {
- return core.HttpResponsePromise.fromPromise(this.__deleteTagKey(key, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.RunTagsResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__applyRunTags(workflowRunId, request, requestOptions));
}
- private async __deleteTagKey(
- key: string,
+ private async __applyRunTags(
+ workflowRunId: string,
+ request: Skyvern.TagApplyRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.TagKeyDeleteResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.RunTagsResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -1405,17 +1418,20 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/tag-keys/${core.url.encodePathParam(key)}`,
+ `v1/runs/${core.url.encodePathParam(workflowRunId)}/tags`,
),
- method: "DELETE",
+ method: "POST",
headers: _headers,
+ contentType: "application/json",
queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.TagKeyDeleteResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.RunTagsResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
@@ -1441,7 +1457,9 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling DELETE /v1/tag-keys/{key}.");
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling POST /v1/runs/{workflow_run_id}/tags.",
+ );
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -1451,31 +1469,31 @@ export class SkyvernClient {
}
/**
- * Update the description for a tag key.
+ * Soft-delete a single grouped tag from a workflow run. Writes a DELETE event row.
*
- * @param {string} key - Tag key to update
- * @param {Skyvern.TagKeyUpdate} request
+ * @param {string} workflowRunId - Workflow run ID
+ * @param {string} key - Tag key to delete
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.updateTagKey("key")
+ * await client.deleteRunTag("wr_123", "env")
*/
- public updateTagKey(
+ public deleteRunTag(
+ workflowRunId: string,
key: string,
- request: Skyvern.TagKeyUpdate = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.TagKey> {
- return core.HttpResponsePromise.fromPromise(this.__updateTagKey(key, request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.RunTagsResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__deleteRunTag(workflowRunId, key, requestOptions));
}
- private async __updateTagKey(
+ private async __deleteRunTag(
+ workflowRunId: string,
key: string,
- request: Skyvern.TagKeyUpdate = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.TagKey>> {
+ ): Promise<core.WithRawResponse<Skyvern.RunTagsResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -1486,20 +1504,17 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/tag-keys/${core.url.encodePathParam(key)}`,
+ `v1/runs/${core.url.encodePathParam(workflowRunId)}/tags/${core.url.encodePathParam(key)}`,
),
- method: "PATCH",
+ method: "DELETE",
headers: _headers,
- contentType: "application/json",
queryParameters: requestOptions?.queryParams,
- requestType: "json",
- body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.TagKey, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.RunTagsResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
@@ -1525,7 +1540,9 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling PATCH /v1/tag-keys/{key}.");
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling DELETE /v1/runs/{workflow_run_id}/tags/{key}.",
+ );
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -1535,34 +1552,47 @@ export class SkyvernClient {
}
/**
- * Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
+ * Chronological tag-event log for a workflow run (newest first). Includes SET and DELETE events.
*
- * @param {Skyvern.BatchGetWorkflowTagsRequest} request
+ * @param {string} workflowRunId - Workflow run ID
+ * @param {Skyvern.GetRunTagHistoryRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.BadRequestError}
+ * @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.batchGetWorkflowTags({
- * workflow_permanent_ids: "workflow_permanent_ids"
+ * await client.getRunTagHistory("wr_123", {
+ * limit: 1,
+ * since: "2024-01-15T09:30:00Z",
+ * key: "key"
* })
*/
- public batchGetWorkflowTags(
- request: Skyvern.BatchGetWorkflowTagsRequest = {},
+ public getRunTagHistory(
+ workflowRunId: string,
+ request: Skyvern.GetRunTagHistoryRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.WorkflowTagsBatchResponse> {
- return core.HttpResponsePromise.fromPromise(this.__batchGetWorkflowTags(request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.RunTagHistoryResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__getRunTagHistory(workflowRunId, request, requestOptions));
}
- private async __batchGetWorkflowTags(
- request: Skyvern.BatchGetWorkflowTagsRequest = {},
+ private async __getRunTagHistory(
+ workflowRunId: string,
+ request: Skyvern.GetRunTagHistoryRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.WorkflowTagsBatchResponse>> {
- const { workflow_permanent_ids: workflowPermanentIds } = request;
+ ): Promise<core.WithRawResponse<Skyvern.RunTagHistoryResponse>> {
+ const { limit, since, key } = request;
const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
- if (workflowPermanentIds != null) {
- _queryParams.workflow_permanent_ids = workflowPermanentIds;
+ if (limit != null) {
+ _queryParams.limit = limit.toString();
+ }
+
+ if (since != null) {
+ _queryParams.since = since;
+ }
+
+ if (key != null) {
+ _queryParams.key = key;
}
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
@@ -1575,7 +1605,7 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/workflow-tags",
+ `v1/runs/${core.url.encodePathParam(workflowRunId)}/tags/history`,
),
method: "GET",
headers: _headers,
@@ -1585,13 +1615,13 @@ export class SkyvernClient {
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.WorkflowTagsBatchResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.RunTagHistoryResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 400:
- throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -1611,7 +1641,9 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/workflow-tags.");
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling GET /v1/runs/{workflow_run_id}/tags/history.",
+ );
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -1621,28 +1653,22 @@ export class SkyvernClient {
}
/**
- * Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
+ * List all tag keys registered for the organization with their descriptions.
*
- * @param {Skyvern.WorkflowTagsBatchRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.BadRequestError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.batchGetWorkflowTagsPost()
+ * await client.listTagKeys()
*/
- public batchGetWorkflowTagsPost(
- request: Skyvern.WorkflowTagsBatchRequest = {},
- requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.WorkflowTagsBatchResponse> {
- return core.HttpResponsePromise.fromPromise(this.__batchGetWorkflowTagsPost(request, requestOptions));
+ public listTagKeys(requestOptions?: SkyvernClient.RequestOptions): core.HttpResponsePromise<Skyvern.TagKey[]> {
+ return core.HttpResponsePromise.fromPromise(this.__listTagKeys(requestOptions));
}
- private async __batchGetWorkflowTagsPost(
- request: Skyvern.WorkflowTagsBatchRequest = {},
+ private async __listTagKeys(
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.WorkflowTagsBatchResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.TagKey[]>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -1653,26 +1679,21 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/workflow-tags",
+ "v1/tag-keys",
),
- method: "POST",
+ method: "GET",
headers: _headers,
- contentType: "application/json",
queryParameters: requestOptions?.queryParams,
- requestType: "json",
- body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.WorkflowTagsBatchResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.TagKey[], rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 400:
- throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -1692,7 +1713,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/workflow-tags.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/tag-keys.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -1702,40 +1723,28 @@ export class SkyvernClient {
}
/**
- * Get artifacts for a run
+ * Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
*
- * @param {string} runId - The id of the task run or the workflow run.
- * @param {Skyvern.GetRunArtifactsRequest} request
+ * @param {string} key - Tag key to delete
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
+ * @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.getRunArtifacts("run_id")
+ * await client.deleteTagKey("env")
*/
- public getRunArtifacts(
- runId: string,
- request: Skyvern.GetRunArtifactsRequest = {},
+ public deleteTagKey(
+ key: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.Artifact[]> {
- return core.HttpResponsePromise.fromPromise(this.__getRunArtifacts(runId, request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.TagKeyDeleteResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__deleteTagKey(key, requestOptions));
}
- private async __getRunArtifacts(
- runId: string,
- request: Skyvern.GetRunArtifactsRequest = {},
+ private async __deleteTagKey(
+ key: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.Artifact[]>> {
- const { artifact_type: artifactType } = request;
- const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
- if (artifactType != null) {
- if (Array.isArray(artifactType)) {
- _queryParams.artifact_type = artifactType.map((item) => item);
- } else {
- _queryParams.artifact_type = artifactType;
- }
- }
-
+ ): Promise<core.WithRawResponse<Skyvern.TagKeyDeleteResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -1746,21 +1755,23 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/runs/${core.url.encodePathParam(runId)}/artifacts`,
+ `v1/tag-keys/${core.url.encodePathParam(key)}`,
),
- method: "GET",
+ method: "DELETE",
headers: _headers,
- queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
+ queryParameters: requestOptions?.queryParams,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.Artifact[], rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.TagKeyDeleteResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -1780,7 +1791,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/runs/{run_id}/artifacts.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling DELETE /v1/tag-keys/{key}.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -1790,30 +1801,31 @@ export class SkyvernClient {
}
/**
- * Retry sending the webhook for a run
+ * Update the description for a tag key.
*
- * @param {string} runId - The id of the task run or the workflow run.
- * @param {Skyvern.RetryRunWebhookRequest} request
+ * @param {string} key - Tag key to update
+ * @param {Skyvern.TagKeyUpdate} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
+ * @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.retryRunWebhook("tsk_123")
+ * await client.updateTagKey("key")
*/
- public retryRunWebhook(
- runId: string,
- request?: Skyvern.RetryRunWebhookRequest,
+ public updateTagKey(
+ key: string,
+ request: Skyvern.TagKeyUpdate = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.RunWebhookReplayResponse> {
- return core.HttpResponsePromise.fromPromise(this.__retryRunWebhook(runId, request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.TagKey> {
+ return core.HttpResponsePromise.fromPromise(this.__updateTagKey(key, request, requestOptions));
}
- private async __retryRunWebhook(
- runId: string,
- request?: Skyvern.RetryRunWebhookRequest,
+ private async __updateTagKey(
+ key: string,
+ request: Skyvern.TagKeyUpdate = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.RunWebhookReplayResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.TagKey>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -1824,24 +1836,26 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/runs/${core.url.encodePathParam(runId)}/retry_webhook`,
+ `v1/tag-keys/${core.url.encodePathParam(key)}`,
),
- method: "POST",
+ method: "PATCH",
headers: _headers,
contentType: "application/json",
queryParameters: requestOptions?.queryParams,
requestType: "json",
- body: request != null ? request : undefined,
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.RunWebhookReplayResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.TagKey, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -1861,9 +1875,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling POST /v1/runs/{run_id}/retry_webhook.",
- );
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling PATCH /v1/tag-keys/{key}.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -1873,29 +1885,35 @@ export class SkyvernClient {
}
/**
- * Get timeline for a run (workflow run or task_v2 run)
+ * List the palette color and current workflow usage count for each grouped tag (key, value) for the organization. The frontend joins these onto tags by (key, value); workflow_count is the number of non-deleted workflows carrying the label and powers the per-label usage and delete blast-radius warnings.
*
- * @param {string} runId - The id of the workflow run or task_v2 run.
+ * @param {Skyvern.ListTagValuesRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.BadRequestError}
- * @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.getRunTimeline("wr_123")
+ * await client.listTagValues({
+ * key: "key"
+ * })
*/
- public getRunTimeline(
- runId: string,
+ public listTagValues(
+ request: Skyvern.ListTagValuesRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.WorkflowRunTimeline[]> {
- return core.HttpResponsePromise.fromPromise(this.__getRunTimeline(runId, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.TagValue[]> {
+ return core.HttpResponsePromise.fromPromise(this.__listTagValues(request, requestOptions));
}
- private async __getRunTimeline(
- runId: string,
+ private async __listTagValues(
+ request: Skyvern.ListTagValuesRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.WorkflowRunTimeline[]>> {
+ ): Promise<core.WithRawResponse<Skyvern.TagValue[]>> {
+ const { key } = request;
+ const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
+ if (key != null) {
+ _queryParams.key = key;
+ }
+
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -1906,25 +1924,21 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/runs/${core.url.encodePathParam(runId)}/timeline`,
+ "v1/tag-values",
),
method: "GET",
headers: _headers,
- queryParameters: requestOptions?.queryParams,
+ queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.WorkflowRunTimeline[], rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.TagValue[], rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 400:
- throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
- case 404:
- throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -1944,7 +1958,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/runs/{run_id}/timeline.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/tag-values.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -1954,20 +1968,33 @@ export class SkyvernClient {
}
/**
- * Returns the current Skyvern server version (git SHA for official builds).
+ * Soft-delete a grouped tag (key, value) and remove that label from every workflow carrying it (cascade). The value rides in the body so values containing '/' stay addressable. Returns how many workflows the label was removed from.
*
+ * @param {string} key - Tag key (group)
+ * @param {Skyvern.TagValueDelete} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
* @example
- * await client.getVersion()
+ * await client.deleteTagValue("env", {
+ * value: "value"
+ * })
*/
- public getVersion(requestOptions?: SkyvernClient.RequestOptions): core.HttpResponsePromise<Record<string, string>> {
- return core.HttpResponsePromise.fromPromise(this.__getVersion(requestOptions));
+ public deleteTagValue(
+ key: string,
+ request: Skyvern.TagValueDelete,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.TagValueDeleteResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__deleteTagValue(key, request, requestOptions));
}
- private async __getVersion(
+ private async __deleteTagValue(
+ key: string,
+ request: Skyvern.TagValueDelete,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Record<string, string>>> {
+ ): Promise<core.WithRawResponse<Skyvern.TagValueDeleteResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -1978,25 +2005,35 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/version",
+ `v1/tag-values/${core.url.encodePathParam(key)}`,
),
- method: "GET",
+ method: "DELETE",
headers: _headers,
+ contentType: "application/json",
queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Record<string, string>, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.TagValueDeleteResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
- throw new errors.SkyvernError({
- statusCode: _response.error.statusCode,
- body: _response.error.body,
- rawResponse: _response.rawResponse,
- });
+ switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
}
switch (_response.error.reason) {
@@ -2007,7 +2044,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/version.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling DELETE /v1/tag-values/{key}.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2017,51 +2054,34 @@ export class SkyvernClient {
}
/**
- * @param {Skyvern.GetRunsV2Request} request
+ * Recolor a grouped tag (key, value). The value is supplied in the body so values containing '/' stay addressable. The new color must be a palette name.
+ *
+ * @param {string} key - Tag key (group)
+ * @param {Skyvern.TagValueUpdate} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
+ * @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.getRunsV2({
- * page: 1,
- * page_size: 1,
- * search_key: "search_key"
+ * await client.updateTagValue("env", {
+ * value: "value",
+ * color: "color"
* })
*/
- public getRunsV2(
- request: Skyvern.GetRunsV2Request = {},
+ public updateTagValue(
+ key: string,
+ request: Skyvern.TagValueUpdate,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.TaskRunListItem[]> {
- return core.HttpResponsePromise.fromPromise(this.__getRunsV2(request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.TagValue> {
+ return core.HttpResponsePromise.fromPromise(this.__updateTagValue(key, request, requestOptions));
}
- private async __getRunsV2(
- request: Skyvern.GetRunsV2Request = {},
+ private async __updateTagValue(
+ key: string,
+ request: Skyvern.TagValueUpdate,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.TaskRunListItem[]>> {
- const { page, page_size: pageSize, status, search_key: searchKey } = request;
- const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
- if (page != null) {
- _queryParams.page = page.toString();
- }
-
- if (pageSize != null) {
- _queryParams.page_size = pageSize.toString();
- }
-
- if (status != null) {
- if (Array.isArray(status)) {
- _queryParams.status = status.map((item) => item);
- } else {
- _queryParams.status = status;
- }
- }
-
- if (searchKey != null) {
- _queryParams.search_key = searchKey;
- }
-
+ ): Promise<core.WithRawResponse<Skyvern.TagValue>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2072,21 +2092,26 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/runs",
+ `v1/tag-values/${core.url.encodePathParam(key)}`,
),
- method: "GET",
+ method: "PATCH",
headers: _headers,
- queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
+ contentType: "application/json",
+ queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.TaskRunListItem[], rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.TagValue, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2106,7 +2131,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/runs.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling PATCH /v1/tag-values/{key}.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2116,37 +2141,38 @@ export class SkyvernClient {
}
/**
- * @param {Skyvern.BodyUploadFileV1UploadFilePost} request
+ * Rename a grouped tag (key, value) to (key, new_value). The cascade re-tags every workflow carrying the old label; the new label inherits the old color. Both values ride in the body so values containing '/' stay addressable. Rejects with 409 when the new value already exists for the key.
+ *
+ * @param {string} key - Tag key (group)
+ * @param {Skyvern.TagValueRename} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.ConflictError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * import { createReadStream } from "fs";
- * await client.uploadFile({
- * file: "file"
+ * await client.renameTagValue("env", {
+ * value: "value",
+ * new_value: "new_value"
* })
*/
- public uploadFile(
- request: Skyvern.BodyUploadFileV1UploadFilePost,
+ public renameTagValue(
+ key: string,
+ request: Skyvern.TagValueRename,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.UploadFileResponse> {
- return core.HttpResponsePromise.fromPromise(this.__uploadFile(request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.TagValueRenameResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__renameTagValue(key, request, requestOptions));
}
- private async __uploadFile(
- request: Skyvern.BodyUploadFileV1UploadFilePost,
+ private async __renameTagValue(
+ key: string,
+ request: Skyvern.TagValueRename,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.UploadFileResponse>> {
- const _request = await core.newFormData();
- _request.append("file", request.file);
- const _maybeEncodedRequest = await _request.getRequest();
+ ): Promise<core.WithRawResponse<Skyvern.TagValueRenameResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
- mergeOnlyDefinedHeaders({
- "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey,
- ..._maybeEncodedRequest.headers,
- }),
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
requestOptions?.headers,
);
const _response = await core.fetcher({
@@ -2154,24 +2180,28 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/upload_file",
+ `v1/tag-values/${core.url.encodePathParam(key)}/rename`,
),
- method: "POST",
+ method: "PATCH",
headers: _headers,
+ contentType: "application/json",
queryParameters: requestOptions?.queryParams,
- requestType: "file",
- duplex: _maybeEncodedRequest.duplex,
- body: _maybeEncodedRequest.body,
+ requestType: "json",
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.UploadFileResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.TagValueRenameResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 409:
+ throw new Skyvern.ConflictError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2191,7 +2221,9 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/upload_file.");
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling PATCH /v1/tag-values/{key}/rename.",
+ );
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2201,48 +2233,34 @@ export class SkyvernClient {
}
/**
- * Get all browser profiles for the organization
+ * Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
*
- * @param {Skyvern.ListBrowserProfilesRequest} request
+ * @param {Skyvern.BatchGetWorkflowTagsRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
+ * @throws {@link Skyvern.BadRequestError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.listBrowserProfiles({
- * page: 1,
- * page_size: 1,
- * include_deleted: true,
- * search_key: "search_key"
+ * await client.batchGetWorkflowTags({
+ * workflow_permanent_ids: "workflow_permanent_ids"
* })
*/
- public listBrowserProfiles(
- request: Skyvern.ListBrowserProfilesRequest = {},
+ public batchGetWorkflowTags(
+ request: Skyvern.BatchGetWorkflowTagsRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.BrowserProfile[]> {
- return core.HttpResponsePromise.fromPromise(this.__listBrowserProfiles(request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.WorkflowTagsBatchResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__batchGetWorkflowTags(request, requestOptions));
}
- private async __listBrowserProfiles(
- request: Skyvern.ListBrowserProfilesRequest = {},
+ private async __batchGetWorkflowTags(
+ request: Skyvern.BatchGetWorkflowTagsRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.BrowserProfile[]>> {
- const { page, page_size: pageSize, include_deleted: includeDeleted, search_key: searchKey } = request;
+ ): Promise<core.WithRawResponse<Skyvern.WorkflowTagsBatchResponse>> {
+ const { workflow_permanent_ids: workflowPermanentIds } = request;
const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
- if (page != null) {
- _queryParams.page = page.toString();
- }
-
- if (pageSize != null) {
- _queryParams.page_size = pageSize.toString();
- }
-
- if (includeDeleted != null) {
- _queryParams.include_deleted = includeDeleted.toString();
- }
-
- if (searchKey != null) {
- _queryParams.search_key = searchKey;
+ if (workflowPermanentIds != null) {
+ _queryParams.workflow_permanent_ids = workflowPermanentIds;
}
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
@@ -2255,7 +2273,7 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/browser_profiles",
+ "v1/workflow-tags",
),
method: "GET",
headers: _headers,
@@ -2265,11 +2283,13 @@ export class SkyvernClient {
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.BrowserProfile[], rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.WorkflowTagsBatchResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
+ case 400:
+ throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2289,7 +2309,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/browser_profiles.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/workflow-tags.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2299,31 +2319,28 @@ export class SkyvernClient {
}
/**
- * Create a blank browser profile, or create one from a persistent browser session or workflow run.
+ * Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
*
- * @param {Skyvern.CreateBrowserProfileRequest} request
+ * @param {Skyvern.WorkflowTagsBatchRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.BadRequestError}
- * @throws {@link Skyvern.ConflictError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.createBrowserProfile({
- * name: "name"
- * })
+ * await client.batchGetWorkflowTagsPost()
*/
- public createBrowserProfile(
- request: Skyvern.CreateBrowserProfileRequest,
+ public batchGetWorkflowTagsPost(
+ request: Skyvern.WorkflowTagsBatchRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.BrowserProfile> {
- return core.HttpResponsePromise.fromPromise(this.__createBrowserProfile(request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.WorkflowTagsBatchResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__batchGetWorkflowTagsPost(request, requestOptions));
}
- private async __createBrowserProfile(
- request: Skyvern.CreateBrowserProfileRequest,
+ private async __batchGetWorkflowTagsPost(
+ request: Skyvern.WorkflowTagsBatchRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.BrowserProfile>> {
+ ): Promise<core.WithRawResponse<Skyvern.WorkflowTagsBatchResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2334,7 +2351,7 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/browser_profiles",
+ "v1/workflow-tags",
),
method: "POST",
headers: _headers,
@@ -2347,15 +2364,13 @@ export class SkyvernClient {
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.BrowserProfile, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.WorkflowTagsBatchResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
case 400:
throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
- case 409:
- throw new Skyvern.ConflictError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2375,7 +2390,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/browser_profiles.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/workflow-tags.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2385,28 +2400,36 @@ export class SkyvernClient {
}
/**
- * Get a specific browser profile by ID
+ * Batch fetch current tags for many workflow runs. Avoids N+1 on run-list pages.
*
- * @param {string} profileId - The ID of the browser profile. browser_profile_id starts with `bp_`
+ * @param {Skyvern.BatchGetRunTagsRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.BadRequestError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.getBrowserProfile("bp_123456")
+ * await client.batchGetRunTags({
+ * workflow_run_ids: "workflow_run_ids"
+ * })
*/
- public getBrowserProfile(
- profileId: string,
+ public batchGetRunTags(
+ request: Skyvern.BatchGetRunTagsRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.BrowserProfile> {
- return core.HttpResponsePromise.fromPromise(this.__getBrowserProfile(profileId, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.RunTagsBatchResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__batchGetRunTags(request, requestOptions));
}
- private async __getBrowserProfile(
- profileId: string,
+ private async __batchGetRunTags(
+ request: Skyvern.BatchGetRunTagsRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.BrowserProfile>> {
+ ): Promise<core.WithRawResponse<Skyvern.RunTagsBatchResponse>> {
+ const { workflow_run_ids: workflowRunIds } = request;
+ const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
+ if (workflowRunIds != null) {
+ _queryParams.workflow_run_ids = workflowRunIds;
+ }
+
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2417,23 +2440,23 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/browser_profiles/${core.url.encodePathParam(profileId)}`,
+ "v1/run-tags",
),
method: "GET",
headers: _headers,
- queryParameters: requestOptions?.queryParams,
+ queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.BrowserProfile, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.RunTagsBatchResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 404:
- throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 400:
+ throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2453,9 +2476,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling GET /v1/browser_profiles/{profile_id}.",
- );
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/run-tags.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2465,28 +2486,28 @@ export class SkyvernClient {
}
/**
- * Delete a browser profile (soft delete)
+ * Batch fetch current tags for many workflow runs (POST variant for id lists exceeding URL length).
*
- * @param {string} profileId - The ID of the browser profile to delete. browser_profile_id starts with `bp_`
+ * @param {Skyvern.RunTagsBatchRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.BadRequestError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.deleteBrowserProfile("bp_123456")
+ * await client.batchGetRunTagsPost()
*/
- public deleteBrowserProfile(
- profileId: string,
+ public batchGetRunTagsPost(
+ request: Skyvern.RunTagsBatchRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<void> {
- return core.HttpResponsePromise.fromPromise(this.__deleteBrowserProfile(profileId, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.RunTagsBatchResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__batchGetRunTagsPost(request, requestOptions));
}
- private async __deleteBrowserProfile(
- profileId: string,
+ private async __batchGetRunTagsPost(
+ request: Skyvern.RunTagsBatchRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<void>> {
+ ): Promise<core.WithRawResponse<Skyvern.RunTagsBatchResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2497,23 +2518,26 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/browser_profiles/${core.url.encodePathParam(profileId)}`,
+ "v1/run-tags",
),
- method: "DELETE",
+ method: "POST",
headers: _headers,
+ contentType: "application/json",
queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: undefined, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.RunTagsBatchResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 404:
- throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 400:
+ throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2533,7 +2557,861 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError(
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/run-tags.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Get artifacts for a run
+ *
+ * @param {string} runId - The id of the task run or the workflow run.
+ * @param {Skyvern.GetRunArtifactsRequest} request
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.getRunArtifacts("run_id")
+ */
+ public getRunArtifacts(
+ runId: string,
+ request: Skyvern.GetRunArtifactsRequest = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.Artifact[]> {
+ return core.HttpResponsePromise.fromPromise(this.__getRunArtifacts(runId, request, requestOptions));
+ }
+
+ private async __getRunArtifacts(
+ runId: string,
+ request: Skyvern.GetRunArtifactsRequest = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.Artifact[]>> {
+ const { artifact_type: artifactType } = request;
+ const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
+ if (artifactType != null) {
+ if (Array.isArray(artifactType)) {
+ _queryParams.artifact_type = artifactType.map((item) => item);
+ } else {
+ _queryParams.artifact_type = artifactType;
+ }
+ }
+
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ `v1/runs/${core.url.encodePathParam(runId)}/artifacts`,
+ ),
+ method: "GET",
+ headers: _headers,
+ queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.Artifact[], rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/runs/{run_id}/artifacts.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Retry sending the webhook for a run
+ *
+ * @param {string} runId - The id of the task run or the workflow run.
+ * @param {Skyvern.RetryRunWebhookRequest} request
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.retryRunWebhook("tsk_123")
+ */
+ public retryRunWebhook(
+ runId: string,
+ request?: Skyvern.RetryRunWebhookRequest,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.RunWebhookReplayResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__retryRunWebhook(runId, request, requestOptions));
+ }
+
+ private async __retryRunWebhook(
+ runId: string,
+ request?: Skyvern.RetryRunWebhookRequest,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.RunWebhookReplayResponse>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ `v1/runs/${core.url.encodePathParam(runId)}/retry_webhook`,
+ ),
+ method: "POST",
+ headers: _headers,
+ contentType: "application/json",
+ queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request != null ? request : undefined,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.RunWebhookReplayResponse, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling POST /v1/runs/{run_id}/retry_webhook.",
+ );
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Get timeline for a run (workflow run or task_v2 run)
+ *
+ * @param {string} runId - The id of the workflow run or task_v2 run.
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.BadRequestError}
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.getRunTimeline("wr_123")
+ */
+ public getRunTimeline(
+ runId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.WorkflowRunTimeline[]> {
+ return core.HttpResponsePromise.fromPromise(this.__getRunTimeline(runId, requestOptions));
+ }
+
+ private async __getRunTimeline(
+ runId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.WorkflowRunTimeline[]>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ `v1/runs/${core.url.encodePathParam(runId)}/timeline`,
+ ),
+ method: "GET",
+ headers: _headers,
+ queryParameters: requestOptions?.queryParams,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.WorkflowRunTimeline[], rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 400:
+ throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/runs/{run_id}/timeline.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Returns the current Skyvern server version (git SHA for official builds).
+ *
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @example
+ * await client.getVersion()
+ */
+ public getVersion(requestOptions?: SkyvernClient.RequestOptions): core.HttpResponsePromise<Record<string, string>> {
+ return core.HttpResponsePromise.fromPromise(this.__getVersion(requestOptions));
+ }
+
+ private async __getVersion(
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Record<string, string>>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ "v1/version",
+ ),
+ method: "GET",
+ headers: _headers,
+ queryParameters: requestOptions?.queryParams,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Record<string, string>, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/version.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * @param {Skyvern.GetRunsV2Request} request
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.getRunsV2({
+ * page: 1,
+ * page_size: 1,
+ * search_key: "search_key"
+ * })
+ */
+ public getRunsV2(
+ request: Skyvern.GetRunsV2Request = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.TaskRunListItem[]> {
+ return core.HttpResponsePromise.fromPromise(this.__getRunsV2(request, requestOptions));
+ }
+
+ private async __getRunsV2(
+ request: Skyvern.GetRunsV2Request = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.TaskRunListItem[]>> {
+ const { page, page_size: pageSize, status, search_key: searchKey, run_type: runType } = request;
+ const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
+ if (page != null) {
+ _queryParams.page = page.toString();
+ }
+
+ if (pageSize != null) {
+ _queryParams.page_size = pageSize.toString();
+ }
+
+ if (status != null) {
+ if (Array.isArray(status)) {
+ _queryParams.status = status.map((item) => item);
+ } else {
+ _queryParams.status = status;
+ }
+ }
+
+ if (searchKey != null) {
+ _queryParams.search_key = searchKey;
+ }
+
+ if (runType != null) {
+ if (Array.isArray(runType)) {
+ _queryParams.run_type = runType.map((item) => item);
+ } else {
+ _queryParams.run_type = runType;
+ }
+ }
+
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ "v1/runs",
+ ),
+ method: "GET",
+ headers: _headers,
+ queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.TaskRunListItem[], rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/runs.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * @param {Skyvern.BodyUploadFileV1UploadFilePost} request
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * import { createReadStream } from "fs";
+ * await client.uploadFile({
+ * file: "file"
+ * })
+ */
+ public uploadFile(
+ request: Skyvern.BodyUploadFileV1UploadFilePost,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.UploadFileResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__uploadFile(request, requestOptions));
+ }
+
+ private async __uploadFile(
+ request: Skyvern.BodyUploadFileV1UploadFilePost,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.UploadFileResponse>> {
+ const _request = await core.newFormData();
+ _request.append("file", request.file);
+ const _maybeEncodedRequest = await _request.getRequest();
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({
+ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey,
+ ..._maybeEncodedRequest.headers,
+ }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ "v1/upload_file",
+ ),
+ method: "POST",
+ headers: _headers,
+ queryParameters: requestOptions?.queryParams,
+ requestType: "file",
+ duplex: _maybeEncodedRequest.duplex,
+ body: _maybeEncodedRequest.body,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.UploadFileResponse, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/upload_file.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Get all browser profiles for the organization
+ *
+ * @param {Skyvern.ListBrowserProfilesRequest} request
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.listBrowserProfiles({
+ * page: 1,
+ * page_size: 1,
+ * include_deleted: true,
+ * search_key: "search_key",
+ * managed: true
+ * })
+ */
+ public listBrowserProfiles(
+ request: Skyvern.ListBrowserProfilesRequest = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.BrowserProfile[]> {
+ return core.HttpResponsePromise.fromPromise(this.__listBrowserProfiles(request, requestOptions));
+ }
+
+ private async __listBrowserProfiles(
+ request: Skyvern.ListBrowserProfilesRequest = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.BrowserProfile[]>> {
+ const { page, page_size: pageSize, include_deleted: includeDeleted, search_key: searchKey, managed } = request;
+ const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
+ if (page != null) {
+ _queryParams.page = page.toString();
+ }
+
+ if (pageSize != null) {
+ _queryParams.page_size = pageSize.toString();
+ }
+
+ if (includeDeleted != null) {
+ _queryParams.include_deleted = includeDeleted.toString();
+ }
+
+ if (searchKey != null) {
+ _queryParams.search_key = searchKey;
+ }
+
+ if (managed != null) {
+ _queryParams.managed = managed.toString();
+ }
+
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ "v1/browser_profiles",
+ ),
+ method: "GET",
+ headers: _headers,
+ queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.BrowserProfile[], rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/browser_profiles.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Create a blank browser profile, or create one from a persistent browser session or workflow run.
+ *
+ * @param {Skyvern.CreateBrowserProfileRequest} request
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.BadRequestError}
+ * @throws {@link Skyvern.ConflictError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.createBrowserProfile({
+ * name: "name"
+ * })
+ */
+ public createBrowserProfile(
+ request: Skyvern.CreateBrowserProfileRequest,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.BrowserProfile> {
+ return core.HttpResponsePromise.fromPromise(this.__createBrowserProfile(request, requestOptions));
+ }
+
+ private async __createBrowserProfile(
+ request: Skyvern.CreateBrowserProfileRequest,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.BrowserProfile>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ "v1/browser_profiles",
+ ),
+ method: "POST",
+ headers: _headers,
+ contentType: "application/json",
+ queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.BrowserProfile, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 400:
+ throw new Skyvern.BadRequestError(_response.error.body as unknown, _response.rawResponse);
+ case 409:
+ throw new Skyvern.ConflictError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/browser_profiles.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Get a specific browser profile by ID
+ *
+ * @param {string} profileId - The ID of the browser profile. browser_profile_id starts with `bp_`
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.getBrowserProfile("bp_123456")
+ */
+ public getBrowserProfile(
+ profileId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.BrowserProfile> {
+ return core.HttpResponsePromise.fromPromise(this.__getBrowserProfile(profileId, requestOptions));
+ }
+
+ private async __getBrowserProfile(
+ profileId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.BrowserProfile>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ `v1/browser_profiles/${core.url.encodePathParam(profileId)}`,
+ ),
+ method: "GET",
+ headers: _headers,
+ queryParameters: requestOptions?.queryParams,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.BrowserProfile, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling GET /v1/browser_profiles/{profile_id}.",
+ );
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Delete a browser profile (soft delete)
+ *
+ * @param {string} profileId - The ID of the browser profile to delete. browser_profile_id starts with `bp_`
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.deleteBrowserProfile("bp_123456")
+ */
+ public deleteBrowserProfile(
+ profileId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<void> {
+ return core.HttpResponsePromise.fromPromise(this.__deleteBrowserProfile(profileId, requestOptions));
+ }
+
+ private async __deleteBrowserProfile(
+ profileId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<void>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ `v1/browser_profiles/${core.url.encodePathParam(profileId)}`,
+ ),
+ method: "DELETE",
+ headers: _headers,
+ queryParameters: requestOptions?.queryParams,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: undefined, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError(
"Timeout exceeded when calling DELETE /v1/browser_profiles/{profile_id}.",
);
case "unknown":
@@ -2545,32 +3423,360 @@ export class SkyvernClient {
}
/**
- * Update a browser profile's name and/or description
+ * Update a browser profile's name and/or description
+ *
+ * @param {string} profileId - The ID of the browser profile to update. browser_profile_id starts with `bp_`
+ * @param {Skyvern.UpdateBrowserProfileRequest} request
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.ConflictError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.updateBrowserProfile("bp_123456")
+ */
+ public updateBrowserProfile(
+ profileId: string,
+ request: Skyvern.UpdateBrowserProfileRequest = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.BrowserProfile> {
+ return core.HttpResponsePromise.fromPromise(this.__updateBrowserProfile(profileId, request, requestOptions));
+ }
+
+ private async __updateBrowserProfile(
+ profileId: string,
+ request: Skyvern.UpdateBrowserProfileRequest = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.BrowserProfile>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ `v1/browser_profiles/${core.url.encodePathParam(profileId)}`,
+ ),
+ method: "PATCH",
+ headers: _headers,
+ contentType: "application/json",
+ queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.BrowserProfile, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 409:
+ throw new Skyvern.ConflictError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling PATCH /v1/browser_profiles/{profile_id}.",
+ );
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Get all active browser sessions for the organization
+ *
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.ForbiddenError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.getBrowserSessions()
+ */
+ public getBrowserSessions(
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.BrowserSessionResponse[]> {
+ return core.HttpResponsePromise.fromPromise(this.__getBrowserSessions(requestOptions));
+ }
+
+ private async __getBrowserSessions(
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.BrowserSessionResponse[]>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ "v1/browser_sessions",
+ ),
+ method: "GET",
+ headers: _headers,
+ queryParameters: requestOptions?.queryParams,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.BrowserSessionResponse[], rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 403:
+ throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/browser_sessions.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Create a browser session that persists across multiple runs
+ *
+ * @param {Skyvern.CreateBrowserSessionRequest} request
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.ForbiddenError}
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.createBrowserSession()
+ */
+ public createBrowserSession(
+ request: Skyvern.CreateBrowserSessionRequest = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<Skyvern.BrowserSessionResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__createBrowserSession(request, requestOptions));
+ }
+
+ private async __createBrowserSession(
+ request: Skyvern.CreateBrowserSessionRequest = {},
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<Skyvern.BrowserSessionResponse>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ "v1/browser_sessions",
+ ),
+ method: "POST",
+ headers: _headers,
+ contentType: "application/json",
+ queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body as Skyvern.BrowserSessionResponse, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 403:
+ throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/browser_sessions.");
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Close a session. Once closed, the session cannot be used again.
+ *
+ * @param {string} browserSessionId - The ID of the browser session to close. completed_at will be set when the browser session is closed. browser_session_id starts with `pbs_`
+ * @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
+ *
+ * @throws {@link Skyvern.ForbiddenError}
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.UnprocessableEntityError}
+ *
+ * @example
+ * await client.closeBrowserSession("pbs_123456")
+ */
+ public closeBrowserSession(
+ browserSessionId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): core.HttpResponsePromise<unknown> {
+ return core.HttpResponsePromise.fromPromise(this.__closeBrowserSession(browserSessionId, requestOptions));
+ }
+
+ private async __closeBrowserSession(
+ browserSessionId: string,
+ requestOptions?: SkyvernClient.RequestOptions,
+ ): Promise<core.WithRawResponse<unknown>> {
+ const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
+ this._options?.headers,
+ mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
+ requestOptions?.headers,
+ );
+ const _response = await core.fetcher({
+ url: core.url.join(
+ (await core.Supplier.get(this._options.baseUrl)) ??
+ (await core.Supplier.get(this._options.environment)) ??
+ environments.SkyvernEnvironment.Cloud,
+ `v1/browser_sessions/${core.url.encodePathParam(browserSessionId)}/close`,
+ ),
+ method: "POST",
+ headers: _headers,
+ queryParameters: requestOptions?.queryParams,
+ timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
+ maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
+ abortSignal: requestOptions?.abortSignal,
+ });
+ if (_response.ok) {
+ return { data: _response.body, rawResponse: _response.rawResponse };
+ }
+
+ if (_response.error.reason === "status-code") {
+ switch (_response.error.statusCode) {
+ case 403:
+ throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 422:
+ throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
+ default:
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.body,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ switch (_response.error.reason) {
+ case "non-json":
+ throw new errors.SkyvernError({
+ statusCode: _response.error.statusCode,
+ body: _response.error.rawBody,
+ rawResponse: _response.rawResponse,
+ });
+ case "timeout":
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling POST /v1/browser_sessions/{browser_session_id}/close.",
+ );
+ case "unknown":
+ throw new errors.SkyvernError({
+ message: _response.error.errorMessage,
+ rawResponse: _response.rawResponse,
+ });
+ }
+ }
+
+ /**
+ * Get details about a specific browser session, including the browser address for cdp connection.
*
- * @param {string} profileId - The ID of the browser profile to update. browser_profile_id starts with `bp_`
- * @param {Skyvern.UpdateBrowserProfileRequest} request
+ * @param {string} browserSessionId - The ID of the browser session. browser_session_id starts with `pbs_`
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
+ * @throws {@link Skyvern.ForbiddenError}
* @throws {@link Skyvern.NotFoundError}
- * @throws {@link Skyvern.ConflictError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.updateBrowserProfile("bp_123456")
+ * await client.getBrowserSession("pbs_123456")
*/
- public updateBrowserProfile(
- profileId: string,
- request: Skyvern.UpdateBrowserProfileRequest = {},
+ public getBrowserSession(
+ browserSessionId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.BrowserProfile> {
- return core.HttpResponsePromise.fromPromise(this.__updateBrowserProfile(profileId, request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.BrowserSessionResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__getBrowserSession(browserSessionId, requestOptions));
}
- private async __updateBrowserProfile(
- profileId: string,
- request: Skyvern.UpdateBrowserProfileRequest = {},
+ private async __getBrowserSession(
+ browserSessionId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.BrowserProfile>> {
+ ): Promise<core.WithRawResponse<Skyvern.BrowserSessionResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2581,28 +3787,25 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/browser_profiles/${core.url.encodePathParam(profileId)}`,
+ `v1/browser_sessions/${core.url.encodePathParam(browserSessionId)}`,
),
- method: "PATCH",
+ method: "GET",
headers: _headers,
- contentType: "application/json",
queryParameters: requestOptions?.queryParams,
- requestType: "json",
- body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.BrowserProfile, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.BrowserSessionResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
+ case 403:
+ throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
case 404:
throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
- case 409:
- throw new Skyvern.ConflictError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2623,7 +3826,7 @@ export class SkyvernClient {
});
case "timeout":
throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling PATCH /v1/browser_profiles/{profile_id}.",
+ "Timeout exceeded when calling GET /v1/browser_sessions/{browser_session_id}.",
);
case "unknown":
throw new errors.SkyvernError({
@@ -2634,25 +3837,37 @@ export class SkyvernClient {
}
/**
- * Get all active browser sessions for the organization
+ * Update a live browser session. Currently supports toggling generate_browser_profile, which is read when the session ends to decide whether to save its browser profile.
*
+ * @param {string} browserSessionId - The ID of the browser session. browser_session_id starts with `pbs_`
+ * @param {Skyvern.UpdateBrowserSessionRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.ForbiddenError}
+ * @throws {@link Skyvern.NotFoundError}
+ * @throws {@link Skyvern.ConflictError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.getBrowserSessions()
+ * await client.updateBrowserSession("pbs_123456", {
+ * generate_browser_profile: true
+ * })
*/
- public getBrowserSessions(
+ public updateBrowserSession(
+ browserSessionId: string,
+ request: Skyvern.UpdateBrowserSessionRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.BrowserSessionResponse[]> {
- return core.HttpResponsePromise.fromPromise(this.__getBrowserSessions(requestOptions));
+ ): core.HttpResponsePromise<Skyvern.BrowserSessionResponse> {
+ return core.HttpResponsePromise.fromPromise(
+ this.__updateBrowserSession(browserSessionId, request, requestOptions),
+ );
}
- private async __getBrowserSessions(
+ private async __updateBrowserSession(
+ browserSessionId: string,
+ request: Skyvern.UpdateBrowserSessionRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.BrowserSessionResponse[]>> {
+ ): Promise<core.WithRawResponse<Skyvern.BrowserSessionResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2663,23 +3878,30 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/browser_sessions",
+ `v1/browser_sessions/${core.url.encodePathParam(browserSessionId)}`,
),
- method: "GET",
+ method: "PATCH",
headers: _headers,
+ contentType: "application/json",
queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.BrowserSessionResponse[], rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.BrowserSessionResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
case 403:
throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
+ case 404:
+ throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
+ case 409:
+ throw new Skyvern.ConflictError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2699,7 +3921,9 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/browser_sessions.");
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling PATCH /v1/browser_sessions/{browser_session_id}.",
+ );
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2709,29 +3933,30 @@ export class SkyvernClient {
}
/**
- * Create a browser session that persists across multiple runs
+ * Forward a TOTP (2FA, MFA) email or sms message containing the code to Skyvern. This endpoint stores the code in database so that Skyvern can use it while running tasks/workflows.
*
- * @param {Skyvern.CreateBrowserSessionRequest} request
+ * @param {Skyvern.TotpCodeCreate} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.ForbiddenError}
- * @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.createBrowserSession()
+ * await client.sendTotpCode({
+ * totp_identifier: "[email protected]",
+ * content: "Hello, your verification code is 123456"
+ * })
*/
- public createBrowserSession(
- request: Skyvern.CreateBrowserSessionRequest = {},
+ public sendTotpCode(
+ request: Skyvern.TotpCodeCreate,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.BrowserSessionResponse> {
- return core.HttpResponsePromise.fromPromise(this.__createBrowserSession(request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.TotpCode> {
+ return core.HttpResponsePromise.fromPromise(this.__sendTotpCode(request, requestOptions));
}
- private async __createBrowserSession(
- request: Skyvern.CreateBrowserSessionRequest = {},
+ private async __sendTotpCode(
+ request: Skyvern.TotpCodeCreate,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.BrowserSessionResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.TotpCode>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2742,7 +3967,7 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/browser_sessions",
+ "v1/credentials/totp",
),
method: "POST",
headers: _headers,
@@ -2755,15 +3980,11 @@ export class SkyvernClient {
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.BrowserSessionResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.TotpCode, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 403:
- throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
- case 404:
- throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2783,7 +4004,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/browser_sessions.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/credentials/totp.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2793,28 +4014,55 @@ export class SkyvernClient {
}
/**
- * Close a session. Once closed, the session cannot be used again.
+ * Retrieves a paginated list of credentials for the current organization
*
- * @param {string} browserSessionId - The ID of the browser session to close. completed_at will be set when the browser session is closed. browser_session_id starts with `pbs_`
+ * @param {Skyvern.GetCredentialsRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.ForbiddenError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.closeBrowserSession("pbs_123456")
+ * await client.getCredentials({
+ * page: 1,
+ * page_size: 10,
+ * vault_type: "skyvern",
+ * credential_type: "password",
+ * search: "search"
+ * })
*/
- public closeBrowserSession(
- browserSessionId: string,
+ public getCredentials(
+ request: Skyvern.GetCredentialsRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<unknown> {
- return core.HttpResponsePromise.fromPromise(this.__closeBrowserSession(browserSessionId, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.CredentialResponse[]> {
+ return core.HttpResponsePromise.fromPromise(this.__getCredentials(request, requestOptions));
}
- private async __closeBrowserSession(
- browserSessionId: string,
+ private async __getCredentials(
+ request: Skyvern.GetCredentialsRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<unknown>> {
+ ): Promise<core.WithRawResponse<Skyvern.CredentialResponse[]>> {
+ const { page, page_size: pageSize, vault_type: vaultType, credential_type: credentialType, search } = request;
+ const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
+ if (page != null) {
+ _queryParams.page = page.toString();
+ }
+
+ if (pageSize != null) {
+ _queryParams.page_size = pageSize.toString();
+ }
+
+ if (vaultType != null) {
+ _queryParams.vault_type = vaultType;
+ }
+
+ if (credentialType != null) {
+ _queryParams.credential_type = credentialType;
+ }
+
+ if (search != null) {
+ _queryParams.search = search;
+ }
+
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2825,23 +4073,21 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/browser_sessions/${core.url.encodePathParam(browserSessionId)}/close`,
+ "v1/credentials",
),
- method: "POST",
+ method: "GET",
headers: _headers,
- queryParameters: requestOptions?.queryParams,
+ queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.CredentialResponse[], rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 403:
- throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2861,9 +4107,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling POST /v1/browser_sessions/{browser_session_id}/close.",
- );
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/credentials.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2873,29 +4117,34 @@ export class SkyvernClient {
}
/**
- * Get details about a specific browser session, including the browser address for cdp connection.
+ * Creates a new credential for the current organization
*
- * @param {string} browserSessionId - The ID of the browser session. browser_session_id starts with `pbs_`
+ * @param {Skyvern.CreateCredentialRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.ForbiddenError}
- * @throws {@link Skyvern.NotFoundError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.getBrowserSession("pbs_123456")
+ * await client.createCredential({
+ * name: "Amazon Login",
+ * credential_type: "password",
+ * credential: {
+ * password: "securepassword123",
+ * username: "[email protected]"
+ * }
+ * })
*/
- public getBrowserSession(
- browserSessionId: string,
+ public createCredential(
+ request: Skyvern.CreateCredentialRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.BrowserSessionResponse> {
- return core.HttpResponsePromise.fromPromise(this.__getBrowserSession(browserSessionId, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.CredentialResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__createCredential(request, requestOptions));
}
- private async __getBrowserSession(
- browserSessionId: string,
+ private async __createCredential(
+ request: Skyvern.CreateCredentialRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.BrowserSessionResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.CredentialResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2906,25 +4155,24 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/browser_sessions/${core.url.encodePathParam(browserSessionId)}`,
+ "v1/credentials",
),
- method: "GET",
+ method: "POST",
headers: _headers,
+ contentType: "application/json",
queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.BrowserSessionResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.CredentialResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 403:
- throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
- case 404:
- throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -2944,9 +4192,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling GET /v1/browser_sessions/{browser_session_id}.",
- );
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/credentials.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -2956,37 +4202,37 @@ export class SkyvernClient {
}
/**
- * Update a live browser session. Currently supports toggling generate_browser_profile, which is read when the session ends to decide whether to save its browser profile.
+ * Overwrites the stored credential data (e.g. username/password) while keeping the same credential_id.
*
- * @param {string} browserSessionId - The ID of the browser session. browser_session_id starts with `pbs_`
- * @param {Skyvern.UpdateBrowserSessionRequest} request
+ * @param {string} credentialId - The unique identifier of the credential to update
+ * @param {Skyvern.CreateCredentialRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
- * @throws {@link Skyvern.ForbiddenError}
- * @throws {@link Skyvern.NotFoundError}
- * @throws {@link Skyvern.ConflictError}
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.updateBrowserSession("pbs_123456", {
- * generate_browser_profile: true
+ * await client.updateCredential("cred_1234567890", {
+ * name: "Amazon Login",
+ * credential_type: "password",
+ * credential: {
+ * password: "securepassword123",
+ * username: "[email protected]"
+ * }
* })
*/
- public updateBrowserSession(
- browserSessionId: string,
- request: Skyvern.UpdateBrowserSessionRequest,
+ public updateCredential(
+ credentialId: string,
+ request: Skyvern.CreateCredentialRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.BrowserSessionResponse> {
- return core.HttpResponsePromise.fromPromise(
- this.__updateBrowserSession(browserSessionId, request, requestOptions),
- );
+ ): core.HttpResponsePromise<Skyvern.CredentialResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__updateCredential(credentialId, request, requestOptions));
}
- private async __updateBrowserSession(
- browserSessionId: string,
- request: Skyvern.UpdateBrowserSessionRequest,
+ private async __updateCredential(
+ credentialId: string,
+ request: Skyvern.CreateCredentialRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.BrowserSessionResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.CredentialResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -2997,9 +4243,9 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/browser_sessions/${core.url.encodePathParam(browserSessionId)}`,
+ `v1/credentials/${core.url.encodePathParam(credentialId)}/update`,
),
- method: "PATCH",
+ method: "POST",
headers: _headers,
contentType: "application/json",
queryParameters: requestOptions?.queryParams,
@@ -3010,17 +4256,11 @@ export class SkyvernClient {
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.BrowserSessionResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.CredentialResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
switch (_response.error.statusCode) {
- case 403:
- throw new Skyvern.ForbiddenError(_response.error.body as unknown, _response.rawResponse);
- case 404:
- throw new Skyvern.NotFoundError(_response.error.body as unknown, _response.rawResponse);
- case 409:
- throw new Skyvern.ConflictError(_response.error.body as unknown, _response.rawResponse);
case 422:
throw new Skyvern.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse);
default:
@@ -3041,7 +4281,7 @@ export class SkyvernClient {
});
case "timeout":
throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling PATCH /v1/browser_sessions/{browser_session_id}.",
+ "Timeout exceeded when calling POST /v1/credentials/{credential_id}/update.",
);
case "unknown":
throw new errors.SkyvernError({
@@ -3052,30 +4292,27 @@ export class SkyvernClient {
}
/**
- * Forward a TOTP (2FA, MFA) email or sms message containing the code to Skyvern. This endpoint stores the code in database so that Skyvern can use it while running tasks/workflows.
+ * Deletes a specific credential by its ID
*
- * @param {Skyvern.TotpCodeCreate} request
+ * @param {string} credentialId - The unique identifier of the credential to delete
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.sendTotpCode({
- * totp_identifier: "[email protected]",
- * content: "Hello, your verification code is 123456"
- * })
+ * await client.deleteCredential("cred_1234567890")
*/
- public sendTotpCode(
- request: Skyvern.TotpCodeCreate,
+ public deleteCredential(
+ credentialId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.TotpCode> {
- return core.HttpResponsePromise.fromPromise(this.__sendTotpCode(request, requestOptions));
+ ): core.HttpResponsePromise<void> {
+ return core.HttpResponsePromise.fromPromise(this.__deleteCredential(credentialId, requestOptions));
}
- private async __sendTotpCode(
- request: Skyvern.TotpCodeCreate,
+ private async __deleteCredential(
+ credentialId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.TotpCode>> {
+ ): Promise<core.WithRawResponse<void>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -3086,20 +4323,17 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/credentials/totp",
+ `v1/credentials/${core.url.encodePathParam(credentialId)}/delete`,
),
method: "POST",
headers: _headers,
- contentType: "application/json",
queryParameters: requestOptions?.queryParams,
- requestType: "json",
- body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.TotpCode, rawResponse: _response.rawResponse };
+ return { data: undefined, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
@@ -3123,7 +4357,9 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/credentials/totp.");
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling POST /v1/credentials/{credential_id}/delete.",
+ );
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -3133,55 +4369,27 @@ export class SkyvernClient {
}
/**
- * Retrieves a paginated list of credentials for the current organization
+ * Retrieves a specific credential by its ID
*
- * @param {Skyvern.GetCredentialsRequest} request
+ * @param {string} credentialId - The unique identifier of the credential
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.getCredentials({
- * page: 1,
- * page_size: 10,
- * vault_type: "skyvern",
- * credential_type: "password",
- * search: "search"
- * })
+ * await client.getCredential("cred_1234567890")
*/
- public getCredentials(
- request: Skyvern.GetCredentialsRequest = {},
+ public getCredential(
+ credentialId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.CredentialResponse[]> {
- return core.HttpResponsePromise.fromPromise(this.__getCredentials(request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.CredentialResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__getCredential(credentialId, requestOptions));
}
- private async __getCredentials(
- request: Skyvern.GetCredentialsRequest = {},
+ private async __getCredential(
+ credentialId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.CredentialResponse[]>> {
- const { page, page_size: pageSize, vault_type: vaultType, credential_type: credentialType, search } = request;
- const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
- if (page != null) {
- _queryParams.page = page.toString();
- }
-
- if (pageSize != null) {
- _queryParams.page_size = pageSize.toString();
- }
-
- if (vaultType != null) {
- _queryParams.vault_type = vaultType;
- }
-
- if (credentialType != null) {
- _queryParams.credential_type = credentialType;
- }
-
- if (search != null) {
- _queryParams.search = search;
- }
-
+ ): Promise<core.WithRawResponse<Skyvern.CredentialResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -3192,17 +4400,17 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/credentials",
+ `v1/credentials/${core.url.encodePathParam(credentialId)}`,
),
method: "GET",
headers: _headers,
- queryParameters: { ..._queryParams, ...requestOptions?.queryParams },
+ queryParameters: requestOptions?.queryParams,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.CredentialResponse[], rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.CredentialResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
@@ -3226,7 +4434,9 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/credentials.");
+ throw new errors.SkyvernTimeoutError(
+ "Timeout exceeded when calling GET /v1/credentials/{credential_id}.",
+ );
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -3236,34 +4446,24 @@ export class SkyvernClient {
}
/**
- * Creates a new credential for the current organization
+ * List the custom LLM configurations available to the current organization.
*
- * @param {Skyvern.CreateCredentialRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.createCredential({
- * name: "Amazon Login",
- * credential_type: "password",
- * credential: {
- * password: "securepassword123",
- * username: "[email protected]"
- * }
- * })
+ * await client.listCustomLlms()
*/
- public createCredential(
- request: Skyvern.CreateCredentialRequest,
+ public listCustomLlms(
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.CredentialResponse> {
- return core.HttpResponsePromise.fromPromise(this.__createCredential(request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.CustomLlmListResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__listCustomLlms(requestOptions));
}
- private async __createCredential(
- request: Skyvern.CreateCredentialRequest,
+ private async __listCustomLlms(
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.CredentialResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.CustomLlmListResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -3274,20 +4474,17 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- "v1/credentials",
+ "v1/custom-llms",
),
- method: "POST",
+ method: "GET",
headers: _headers,
- contentType: "application/json",
queryParameters: requestOptions?.queryParams,
- requestType: "json",
- body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.CredentialResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.CustomLlmListResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
@@ -3311,7 +4508,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/credentials.");
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling GET /v1/custom-llms.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -3321,37 +4518,33 @@ export class SkyvernClient {
}
/**
- * Overwrites the stored credential data (e.g. username/password) while keeping the same credential_id.
+ * Create a custom LLM configuration for the current organization.
*
- * @param {string} credentialId - The unique identifier of the credential to update
- * @param {Skyvern.CreateCredentialRequest} request
+ * @param {Skyvern.CustomLlmCreateRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.updateCredential("cred_1234567890", {
- * name: "Amazon Login",
- * credential_type: "password",
- * credential: {
- * password: "securepassword123",
- * username: "[email protected]"
+ * await client.createCustomLlm({
+ * config: {
+ * display_name: "display_name",
+ * provider: "openai_compatible",
+ * model_name: "model_name"
* }
* })
*/
- public updateCredential(
- credentialId: string,
- request: Skyvern.CreateCredentialRequest,
+ public createCustomLlm(
+ request: Skyvern.CustomLlmCreateRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.CredentialResponse> {
- return core.HttpResponsePromise.fromPromise(this.__updateCredential(credentialId, request, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.CustomLlmResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__createCustomLlm(request, requestOptions));
}
- private async __updateCredential(
- credentialId: string,
- request: Skyvern.CreateCredentialRequest,
+ private async __createCustomLlm(
+ request: Skyvern.CustomLlmCreateRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.CredentialResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.CustomLlmResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -3362,7 +4555,7 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/credentials/${core.url.encodePathParam(credentialId)}/update`,
+ "v1/custom-llms",
),
method: "POST",
headers: _headers,
@@ -3375,7 +4568,7 @@ export class SkyvernClient {
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.CredentialResponse, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.CustomLlmResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
@@ -3399,9 +4592,7 @@ export class SkyvernClient {
rawResponse: _response.rawResponse,
});
case "timeout":
- throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling POST /v1/credentials/{credential_id}/update.",
- );
+ throw new errors.SkyvernTimeoutError("Timeout exceeded when calling POST /v1/custom-llms.");
case "unknown":
throw new errors.SkyvernError({
message: _response.error.errorMessage,
@@ -3411,27 +4602,36 @@ export class SkyvernClient {
}
/**
- * Deletes a specific credential by its ID
+ * Update a custom LLM configuration for the current organization.
*
- * @param {string} credentialId - The unique identifier of the credential to delete
+ * @param {string} customLlmId - The custom LLM id.
+ * @param {Skyvern.CustomLlmUpdateRequest} request
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.deleteCredential("cred_1234567890")
+ * await client.updateCustomLlm("custom_llm_id", {
+ * config: {
+ * display_name: "display_name",
+ * provider: "openai_compatible",
+ * model_name: "model_name"
+ * }
+ * })
*/
- public deleteCredential(
- credentialId: string,
+ public updateCustomLlm(
+ customLlmId: string,
+ request: Skyvern.CustomLlmUpdateRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<void> {
- return core.HttpResponsePromise.fromPromise(this.__deleteCredential(credentialId, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.CustomLlmResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__updateCustomLlm(customLlmId, request, requestOptions));
}
- private async __deleteCredential(
- credentialId: string,
+ private async __updateCustomLlm(
+ customLlmId: string,
+ request: Skyvern.CustomLlmUpdateRequest,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<void>> {
+ ): Promise<core.WithRawResponse<Skyvern.CustomLlmResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -3442,17 +4642,20 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/credentials/${core.url.encodePathParam(credentialId)}/delete`,
+ `v1/custom-llms/${core.url.encodePathParam(customLlmId)}`,
),
- method: "POST",
+ method: "PUT",
headers: _headers,
+ contentType: "application/json",
queryParameters: requestOptions?.queryParams,
+ requestType: "json",
+ body: request,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries,
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: undefined, rawResponse: _response.rawResponse };
+ return { data: _response.body as Skyvern.CustomLlmResponse, rawResponse: _response.rawResponse };
}
if (_response.error.reason === "status-code") {
@@ -3477,7 +4680,7 @@ export class SkyvernClient {
});
case "timeout":
throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling POST /v1/credentials/{credential_id}/delete.",
+ "Timeout exceeded when calling PUT /v1/custom-llms/{custom_llm_id}.",
);
case "unknown":
throw new errors.SkyvernError({
@@ -3488,27 +4691,27 @@ export class SkyvernClient {
}
/**
- * Retrieves a specific credential by its ID
+ * Delete a custom LLM configuration for the current organization.
*
- * @param {string} credentialId - The unique identifier of the credential
+ * @param {string} customLlmId - The custom LLM id.
* @param {SkyvernClient.RequestOptions} requestOptions - Request-specific configuration.
*
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.getCredential("cred_1234567890")
+ * await client.deleteCustomLlm("custom_llm_id")
*/
- public getCredential(
- credentialId: string,
+ public deleteCustomLlm(
+ customLlmId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): core.HttpResponsePromise<Skyvern.CredentialResponse> {
- return core.HttpResponsePromise.fromPromise(this.__getCredential(credentialId, requestOptions));
+ ): core.HttpResponsePromise<Skyvern.ClearOrganizationAuthTokenResponse> {
+ return core.HttpResponsePromise.fromPromise(this.__deleteCustomLlm(customLlmId, requestOptions));
}
- private async __getCredential(
- credentialId: string,
+ private async __deleteCustomLlm(
+ customLlmId: string,
requestOptions?: SkyvernClient.RequestOptions,
- ): Promise<core.WithRawResponse<Skyvern.CredentialResponse>> {
+ ): Promise<core.WithRawResponse<Skyvern.ClearOrganizationAuthTokenResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
@@ -3519,9 +4722,9 @@ export class SkyvernClient {
(await core.Supplier.get(this._options.baseUrl)) ??
(await core.Supplier.get(this._options.environment)) ??
environments.SkyvernEnvironment.Cloud,
- `v1/credentials/${core.url.encodePathParam(credentialId)}`,
+ `v1/custom-llms/${core.url.encodePathParam(customLlmId)}`,
),
- method: "GET",
+ method: "DELETE",
headers: _headers,
queryParameters: requestOptions?.queryParams,
timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 60) * 1000,
@@ -3529,7 +4732,10 @@ export class SkyvernClient {
abortSignal: requestOptions?.abortSignal,
});
if (_response.ok) {
- return { data: _response.body as Skyvern.CredentialResponse, rawResponse: _response.rawResponse };
+ return {
+ data: _response.body as Skyvern.ClearOrganizationAuthTokenResponse,
+ rawResponse: _response.rawResponse,
+ };
}
if (_response.error.reason === "status-code") {
@@ -3554,7 +4760,7 @@ export class SkyvernClient {
});
case "timeout":
throw new errors.SkyvernTimeoutError(
- "Timeout exceeded when calling GET /v1/credentials/{credential_id}.",
+ "Timeout exceeded when calling DELETE /v1/custom-llms/{custom_llm_id}.",
);
case "unknown":
throw new errors.SkyvernError({
@@ -4330,11 +5536,11 @@ export class SkyvernClient {
* @throws {@link Skyvern.UnprocessableEntityError}
*
* @example
- * await client.applyWorkflowTags("wpid_123")
+ * await client.applyWorkflowTags("wpid_123", {})
*/
public applyWorkflowTags(
workflowPermanentId: string,
- request: Skyvern.TagApplyRequest = {},
+ request: Skyvern.TagApplyRequest,
requestOptions?: SkyvernClient.RequestOptions,
): core.HttpResponsePromise<Skyvern.TagsResponse> {
return core.HttpResponsePromise.fromPromise(
@@ -4344,7 +5550,7 @@ export class SkyvernClient {
private async __applyWorkflowTags(
workflowPermanentId: string,
- request: Skyvern.TagApplyRequest = {},
+ request: Skyvern.TagApplyRequest,
requestOptions?: SkyvernClient.RequestOptions,
): Promise<core.WithRawResponse<Skyvern.TagsResponse>> {
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
@@ -4844,7 +6050,9 @@ export class SkyvernClient {
* page: 1,
* page_size: 1,
* search_key: "search_key",
- * error_code: "error_code"
+ * error_code: "error_code",
+ * created_at_start: "2024-01-15T09:30:00Z",
+ * created_at_end: "2024-01-15T09:30:00Z"
* })
*/
public getWorkflowRunsById(
@@ -4860,7 +6068,15 @@ export class SkyvernClient {
request: Skyvern.GetWorkflowRunsByIdRequest = {},
requestOptions?: SkyvernClient.RequestOptions,
): Promise<core.WithRawResponse<Skyvern.WorkflowRun[]>> {
- const { page, page_size: pageSize, status, search_key: searchKey, error_code: errorCode } = request;
+ const {
+ page,
+ page_size: pageSize,
+ status,
+ search_key: searchKey,
+ error_code: errorCode,
+ created_at_start: createdAtStart,
+ created_at_end: createdAtEnd,
+ } = request;
const _queryParams: Record<string, string | string[] | object | object[] | null> = {};
if (page != null) {
_queryParams.page = page.toString();
@@ -4886,6 +6102,14 @@ export class SkyvernClient {
_queryParams.error_code = errorCode;
}
+ if (createdAtStart != null) {
+ _queryParams.created_at_start = createdAtStart;
+ }
+
+ if (createdAtEnd != null) {
+ _queryParams.created_at_end = createdAtEnd;
+ }
+
const _headers: core.Fetcher.Args["headers"] = mergeHeaders(
this._options?.headers,
mergeOnlyDefinedHeaders({ "x-api-key": requestOptions?.apiKey ?? this._options?.apiKey }),
diff --git a/skyvern-ts/client/src/api/client/requests/BatchGetRunTagsRequest.ts b/skyvern-ts/client/src/api/client/requests/BatchGetRunTagsRequest.ts
new file mode 100644
index 000000000..01c10423a
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/BatchGetRunTagsRequest.ts
@@ -0,0 +1,12 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * @example
+ * {
+ * workflow_run_ids: "workflow_run_ids"
+ * }
+ */
+export interface BatchGetRunTagsRequest {
+ /** Comma-separated workflow run IDs */
+ workflow_run_ids?: string;
+}
diff --git a/skyvern-ts/client/src/api/client/requests/CreateBrowserSessionRequest.ts b/skyvern-ts/client/src/api/client/requests/CreateBrowserSessionRequest.ts
index b2aa4f57a..947624f7a 100644
--- a/skyvern-ts/client/src/api/client/requests/CreateBrowserSessionRequest.ts
+++ b/skyvern-ts/client/src/api/client/requests/CreateBrowserSessionRequest.ts
@@ -46,6 +46,8 @@ export interface CreateBrowserSessionRequest {
* Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}, or a custom proxy URL dict for self-hosted deployments: {"url": "http://user:[email protected]:8080"}
*/
proxy_location?: CreateBrowserSessionRequest.ProxyLocation;
+ /** Opaque Skyvern-managed proxy sticky-session id for pinned Residential ISP sessions. */
+ proxy_session_id?: string;
/** A list of extensions to install in the browser session. */
extensions?: Skyvern.Extensions[];
/** The type of browser to use for the session. */
diff --git a/skyvern-ts/client/src/api/client/requests/CustomLlmCreateRequest.ts b/skyvern-ts/client/src/api/client/requests/CustomLlmCreateRequest.ts
new file mode 100644
index 000000000..ef25352c2
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/CustomLlmCreateRequest.ts
@@ -0,0 +1,17 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../../index.js";
+
+/**
+ * @example
+ * {
+ * config: {
+ * display_name: "display_name",
+ * provider: "openai_compatible",
+ * model_name: "model_name"
+ * }
+ * }
+ */
+export interface CustomLlmCreateRequest {
+ config: Skyvern.CustomLlmConfig;
+}
diff --git a/skyvern-ts/client/src/api/client/requests/CustomLlmUpdateRequest.ts b/skyvern-ts/client/src/api/client/requests/CustomLlmUpdateRequest.ts
new file mode 100644
index 000000000..d3e8793ac
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/CustomLlmUpdateRequest.ts
@@ -0,0 +1,17 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../../index.js";
+
+/**
+ * @example
+ * {
+ * config: {
+ * display_name: "display_name",
+ * provider: "openai_compatible",
+ * model_name: "model_name"
+ * }
+ * }
+ */
+export interface CustomLlmUpdateRequest {
+ config: Skyvern.CustomLlmConfig;
+}
diff --git a/skyvern-ts/client/src/api/client/requests/GetRunTagHistoryRequest.ts b/skyvern-ts/client/src/api/client/requests/GetRunTagHistoryRequest.ts
new file mode 100644
index 000000000..2657dcfc8
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/GetRunTagHistoryRequest.ts
@@ -0,0 +1,18 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * @example
+ * {
+ * limit: 1,
+ * since: "2024-01-15T09:30:00Z",
+ * key: "key"
+ * }
+ */
+export interface GetRunTagHistoryRequest {
+ /** Max events to return */
+ limit?: number;
+ /** Only return events at or after this timestamp */
+ since?: string;
+ /** Filter to events for a single tag key */
+ key?: string;
+}
diff --git a/skyvern-ts/client/src/api/client/requests/GetRunsV2Request.ts b/skyvern-ts/client/src/api/client/requests/GetRunsV2Request.ts
index abc7009b5..d22edddf2 100644
--- a/skyvern-ts/client/src/api/client/requests/GetRunsV2Request.ts
+++ b/skyvern-ts/client/src/api/client/requests/GetRunsV2Request.ts
@@ -16,4 +16,5 @@ export interface GetRunsV2Request {
status?: Skyvern.RunStatus | Skyvern.RunStatus[];
/** Case-insensitive substring search (min 3 chars for trigram index). */
search_key?: string;
+ run_type?: Skyvern.RunType | Skyvern.RunType[];
}
diff --git a/skyvern-ts/client/src/api/client/requests/GetWorkflowRunsByIdRequest.ts b/skyvern-ts/client/src/api/client/requests/GetWorkflowRunsByIdRequest.ts
index 84f3e79a2..99b2cdeb2 100644
--- a/skyvern-ts/client/src/api/client/requests/GetWorkflowRunsByIdRequest.ts
+++ b/skyvern-ts/client/src/api/client/requests/GetWorkflowRunsByIdRequest.ts
@@ -8,7 +8,9 @@ import type * as Skyvern from "../../index.js";
* page: 1,
* page_size: 1,
* search_key: "search_key",
- * error_code: "error_code"
+ * error_code: "error_code",
+ * created_at_start: "2024-01-15T09:30:00Z",
+ * created_at_end: "2024-01-15T09:30:00Z"
* }
*/
export interface GetWorkflowRunsByIdRequest {
@@ -22,4 +24,8 @@ export interface GetWorkflowRunsByIdRequest {
search_key?: string;
/** Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution. */
error_code?: string;
+ /** Only include runs created at or after this UTC timestamp (ISO 8601). */
+ created_at_start?: string;
+ /** Only include runs created strictly before this UTC timestamp (ISO 8601). */
+ created_at_end?: string;
}
diff --git a/skyvern-ts/client/src/api/client/requests/ListBrowserProfilesRequest.ts b/skyvern-ts/client/src/api/client/requests/ListBrowserProfilesRequest.ts
index 843060ee1..2a7c5b064 100644
--- a/skyvern-ts/client/src/api/client/requests/ListBrowserProfilesRequest.ts
+++ b/skyvern-ts/client/src/api/client/requests/ListBrowserProfilesRequest.ts
@@ -6,7 +6,8 @@
* page: 1,
* page_size: 1,
* include_deleted: true,
- * search_key: "search_key"
+ * search_key: "search_key",
+ * managed: true
* }
*/
export interface ListBrowserProfilesRequest {
@@ -16,4 +17,6 @@ export interface ListBrowserProfilesRequest {
include_deleted?: boolean;
/** Case-insensitive substring search across: browser profile name and description. A profile is returned if either field matches. */
search_key?: string;
+ /** Omit to return all profiles; false returns only user-created profiles; true returns only auto-managed profiles. */
+ managed?: boolean;
}
diff --git a/skyvern-ts/client/src/api/client/requests/ListTagValuesRequest.ts b/skyvern-ts/client/src/api/client/requests/ListTagValuesRequest.ts
new file mode 100644
index 000000000..94598ed1c
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/ListTagValuesRequest.ts
@@ -0,0 +1,12 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * @example
+ * {
+ * key: "key"
+ * }
+ */
+export interface ListTagValuesRequest {
+ /** Filter to values for a single tag key */
+ key?: string;
+}
diff --git a/skyvern-ts/client/src/api/client/requests/RunTagsBatchRequest.ts b/skyvern-ts/client/src/api/client/requests/RunTagsBatchRequest.ts
new file mode 100644
index 000000000..02690da5c
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/RunTagsBatchRequest.ts
@@ -0,0 +1,10 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * @example
+ * {}
+ */
+export interface RunTagsBatchRequest {
+ /** Workflow run IDs to fetch tags for. */
+ workflow_run_ids?: string[];
+}
diff --git a/skyvern-ts/client/src/api/client/requests/TagApplyRequest.ts b/skyvern-ts/client/src/api/client/requests/TagApplyRequest.ts
deleted file mode 100644
index 1c7146069..000000000
--- a/skyvern-ts/client/src/api/client/requests/TagApplyRequest.ts
+++ /dev/null
@@ -1,14 +0,0 @@
-// This file was auto-generated by Fern from our API Definition.
-
-import type * as Skyvern from "../../index.js";
-
-/**
- * @example
- * {}
- */
-export interface TagApplyRequest {
- /** Tags to set (overwrite). List of {key?, value} objects. */
- tags?: Skyvern.TagInput[];
- /** Tags to soft-delete. List of {key?, value?} targets. */
- tags_to_delete?: Skyvern.TagDeleteInput[];
-}
diff --git a/skyvern-ts/client/src/api/client/requests/TagValueDelete.ts b/skyvern-ts/client/src/api/client/requests/TagValueDelete.ts
new file mode 100644
index 000000000..da9ed986a
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/TagValueDelete.ts
@@ -0,0 +1,12 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * @example
+ * {
+ * value: "value"
+ * }
+ */
+export interface TagValueDelete {
+ /** Tag value (label) under the key to soft-delete. */
+ value: string;
+}
diff --git a/skyvern-ts/client/src/api/client/requests/TagValueRename.ts b/skyvern-ts/client/src/api/client/requests/TagValueRename.ts
new file mode 100644
index 000000000..76b21b826
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/TagValueRename.ts
@@ -0,0 +1,15 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * @example
+ * {
+ * value: "value",
+ * new_value: "new_value"
+ * }
+ */
+export interface TagValueRename {
+ /** Current tag value (label) under the key to rename. */
+ value: string;
+ /** New tag value (label) to rename it to. */
+ new_value: string;
+}
diff --git a/skyvern-ts/client/src/api/client/requests/TagValueUpdate.ts b/skyvern-ts/client/src/api/client/requests/TagValueUpdate.ts
new file mode 100644
index 000000000..1af1b537e
--- /dev/null
+++ b/skyvern-ts/client/src/api/client/requests/TagValueUpdate.ts
@@ -0,0 +1,15 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * @example
+ * {
+ * value: "value",
+ * color: "color"
+ * }
+ */
+export interface TagValueUpdate {
+ /** Tag value (label) under the key to recolor. */
+ value: string;
+ /** Palette color name to assign to this (key, value). */
+ color: string;
+}
diff --git a/skyvern-ts/client/src/api/client/requests/index.ts b/skyvern-ts/client/src/api/client/requests/index.ts
index d116ad137..cbc856ed8 100644
--- a/skyvern-ts/client/src/api/client/requests/index.ts
+++ b/skyvern-ts/client/src/api/client/requests/index.ts
@@ -1,3 +1,4 @@
+export type { BatchGetRunTagsRequest } from "./BatchGetRunTagsRequest.js";
export type { BatchGetWorkflowTagsRequest } from "./BatchGetWorkflowTagsRequest.js";
export type { BodyUploadFileV1UploadFilePost } from "./BodyUploadFileV1UploadFilePost.js";
export type { BulkCancelRunsRequest } from "./BulkCancelRunsRequest.js";
@@ -5,6 +6,8 @@ export type { CreateBrowserProfileRequest } from "./CreateBrowserProfileRequest.
export type { CreateBrowserSessionRequest } from "./CreateBrowserSessionRequest.js";
export type { CreateScriptRequest } from "./CreateScriptRequest.js";
export type { CreateWorkflowRequest } from "./CreateWorkflowRequest.js";
+export type { CustomLlmCreateRequest } from "./CustomLlmCreateRequest.js";
+export type { CustomLlmUpdateRequest } from "./CustomLlmUpdateRequest.js";
export type { DeleteFolderRequest } from "./DeleteFolderRequest.js";
export type { DeployScriptRequest } from "./DeployScriptRequest.js";
export type { DownloadFilesRequest } from "./DownloadFilesRequest.js";
@@ -14,6 +17,7 @@ export type { GetCredentialsRequest } from "./GetCredentialsRequest.js";
export type { GetFoldersRequest } from "./GetFoldersRequest.js";
export type { GetRunArtifactsRequest } from "./GetRunArtifactsRequest.js";
export type { GetRunsV2Request } from "./GetRunsV2Request.js";
+export type { GetRunTagHistoryRequest } from "./GetRunTagHistoryRequest.js";
export type { GetScriptsRequest } from "./GetScriptsRequest.js";
export type { GetWorkflowRequest } from "./GetWorkflowRequest.js";
export type { GetWorkflowRunsByIdRequest } from "./GetWorkflowRunsByIdRequest.js";
@@ -22,11 +26,15 @@ export type { GetWorkflowsRequest } from "./GetWorkflowsRequest.js";
export type { GetWorkflowTagHistoryRequest } from "./GetWorkflowTagHistoryRequest.js";
export type { GetWorkflowVersionsRequest } from "./GetWorkflowVersionsRequest.js";
export type { ListBrowserProfilesRequest } from "./ListBrowserProfilesRequest.js";
+export type { ListTagValuesRequest } from "./ListTagValuesRequest.js";
export type { LoginRequest } from "./LoginRequest.js";
export type { RetryWorkflowRunRequest } from "./RetryWorkflowRunRequest.js";
export type { RunSdkActionRequest } from "./RunSdkActionRequest.js";
-export type { TagApplyRequest } from "./TagApplyRequest.js";
+export type { RunTagsBatchRequest } from "./RunTagsBatchRequest.js";
export type { TagKeyUpdate } from "./TagKeyUpdate.js";
+export type { TagValueDelete } from "./TagValueDelete.js";
+export type { TagValueRename } from "./TagValueRename.js";
+export type { TagValueUpdate } from "./TagValueUpdate.js";
export type { TaskRunRequestInput } from "./TaskRunRequestInput.js";
export type { TotpCodeCreate } from "./TotpCodeCreate.js";
export type { UpdateBrowserProfileRequest } from "./UpdateBrowserProfileRequest.js";
diff --git a/skyvern-ts/client/src/api/types/BlockType.ts b/skyvern-ts/client/src/api/types/BlockType.ts
index 9ba514242..ebaade770 100644
--- a/skyvern-ts/client/src/api/types/BlockType.ts
+++ b/skyvern-ts/client/src/api/types/BlockType.ts
@@ -28,5 +28,8 @@ export const BlockType = {
WorkflowTrigger: "workflow_trigger",
GoogleSheetsRead: "google_sheets_read",
GoogleSheetsWrite: "google_sheets_write",
+ PdfFill: "pdf_fill",
+ SplitPdf: "split_pdf",
+ EmailInbox: "email_inbox",
} as const;
export type BlockType = (typeof BlockType)[keyof typeof BlockType];
diff --git a/skyvern-ts/client/src/api/types/ClearOrganizationAuthTokenResponse.ts b/skyvern-ts/client/src/api/types/ClearOrganizationAuthTokenResponse.ts
new file mode 100644
index 000000000..1f444e182
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/ClearOrganizationAuthTokenResponse.ts
@@ -0,0 +1,9 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * Response model for clearing an organization auth token.
+ */
+export interface ClearOrganizationAuthTokenResponse {
+ /** Whether the token was cleared successfully */
+ success: boolean;
+}
diff --git a/skyvern-ts/client/src/api/types/CodeBlock.ts b/skyvern-ts/client/src/api/types/CodeBlock.ts
index 40cbfef12..3844358eb 100644
--- a/skyvern-ts/client/src/api/types/CodeBlock.ts
+++ b/skyvern-ts/client/src/api/types/CodeBlock.ts
@@ -15,4 +15,6 @@ export interface CodeBlock {
next_loop_on_failure?: boolean;
code: string;
parameters?: Skyvern.CodeBlockParametersItem[];
+ prompt?: string;
+ steps?: Skyvern.CodeBlockStep[];
}
diff --git a/skyvern-ts/client/src/api/types/CodeBlockStep.ts b/skyvern-ts/client/src/api/types/CodeBlockStep.ts
new file mode 100644
index 000000000..c261a7371
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/CodeBlockStep.ts
@@ -0,0 +1,11 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface CodeBlockStep {
+ title?: string;
+ description?: string;
+ action_type?: Skyvern.ActionType;
+ line_start?: number;
+ line_end?: number;
+}
diff --git a/skyvern-ts/client/src/api/types/CodeBlockStepYaml.ts b/skyvern-ts/client/src/api/types/CodeBlockStepYaml.ts
new file mode 100644
index 000000000..32f442dc5
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/CodeBlockStepYaml.ts
@@ -0,0 +1,9 @@
+// This file was auto-generated by Fern from our API Definition.
+
+export interface CodeBlockStepYaml {
+ title?: string;
+ description?: string;
+ action_type?: string;
+ line_start?: number;
+ line_end?: number;
+}
diff --git a/skyvern-ts/client/src/api/types/CodeBlockYaml.ts b/skyvern-ts/client/src/api/types/CodeBlockYaml.ts
index 806d31f24..13b59a536 100644
--- a/skyvern-ts/client/src/api/types/CodeBlockYaml.ts
+++ b/skyvern-ts/client/src/api/types/CodeBlockYaml.ts
@@ -1,5 +1,7 @@
// This file was auto-generated by Fern from our API Definition.
+import type * as Skyvern from "../index.js";
+
export interface CodeBlockYaml {
/** Author-facing identifier; must be unique per workflow. */
label: string;
@@ -11,4 +13,6 @@ export interface CodeBlockYaml {
next_loop_on_failure?: boolean;
code: string;
parameter_keys?: string[];
+ prompt?: string;
+ steps?: Skyvern.CodeBlockStepYaml[];
}
diff --git a/skyvern-ts/client/src/api/types/CredentialParameter.ts b/skyvern-ts/client/src/api/types/CredentialParameter.ts
index 48d66e41a..4dc9122fa 100644
--- a/skyvern-ts/client/src/api/types/CredentialParameter.ts
+++ b/skyvern-ts/client/src/api/types/CredentialParameter.ts
@@ -6,6 +6,8 @@ export interface CredentialParameter {
credential_parameter_id: string;
workflow_id: string;
credential_id: string;
+ credential_ids?: string[];
+ selection_strategy?: string;
created_at: string;
modified_at: string;
deleted_at?: string;
diff --git a/skyvern-ts/client/src/api/types/CredentialParameterYaml.ts b/skyvern-ts/client/src/api/types/CredentialParameterYaml.ts
index b7087e0d4..ac1eb8e69 100644
--- a/skyvern-ts/client/src/api/types/CredentialParameterYaml.ts
+++ b/skyvern-ts/client/src/api/types/CredentialParameterYaml.ts
@@ -4,4 +4,6 @@ export interface CredentialParameterYaml {
key: string;
description?: string;
credential_id: string;
+ credential_ids?: string[];
+ selection_strategy?: string;
}
diff --git a/skyvern-ts/client/src/api/types/CredentialResponse.ts b/skyvern-ts/client/src/api/types/CredentialResponse.ts
index 3d22cf980..8c8ccf870 100644
--- a/skyvern-ts/client/src/api/types/CredentialResponse.ts
+++ b/skyvern-ts/client/src/api/types/CredentialResponse.ts
@@ -26,6 +26,10 @@ export interface CredentialResponse {
save_browser_session_intent?: boolean;
/** ID of the credential folder this credential belongs to, if any */
folder_id?: string;
+ /** Optional proxy location used for the credential's pinned proxy identity. */
+ proxy_location?: CredentialResponse.ProxyLocation;
+ /** Opaque Skyvern-managed proxy sticky-session id. */
+ proxy_session_id?: string;
}
export namespace CredentialResponse {
@@ -36,4 +40,8 @@ export namespace CredentialResponse {
| Skyvern.PasswordCredentialResponse
| Skyvern.CreditCardCredentialResponse
| Skyvern.SecretCredentialResponse;
+ /**
+ * Optional proxy location used for the credential's pinned proxy identity.
+ */
+ export type ProxyLocation = Skyvern.ProxyLocation | Skyvern.GeoTarget | Record<string, unknown>;
}
diff --git a/skyvern-ts/client/src/api/types/CreditCardBillingAddress.ts b/skyvern-ts/client/src/api/types/CreditCardBillingAddress.ts
new file mode 100644
index 000000000..e87076824
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/CreditCardBillingAddress.ts
@@ -0,0 +1,23 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * Optional billing address fields associated with a credit card credential.
+ */
+export interface CreditCardBillingAddress {
+ /** Billing address line 1 */
+ line1?: string;
+ /** Billing address line 2 */
+ line2?: string;
+ /** Billing city */
+ city?: string;
+ /** Billing state or region */
+ state?: string;
+ /** Billing state or region code */
+ state_code?: string;
+ /** Billing postal code */
+ postal_code?: string;
+ /** Billing country */
+ country?: string;
+ /** ISO 3166-1 alpha-2 billing country code */
+ country_code?: string;
+}
diff --git a/skyvern-ts/client/src/api/types/CreditCardCredentialResponse.ts b/skyvern-ts/client/src/api/types/CreditCardCredentialResponse.ts
index 74dbcb501..f27d1cd64 100644
--- a/skyvern-ts/client/src/api/types/CreditCardCredentialResponse.ts
+++ b/skyvern-ts/client/src/api/types/CreditCardCredentialResponse.ts
@@ -3,7 +3,8 @@
/**
* Response model for credit card credentials — non-sensitive fields only.
*
- * SECURITY: Must NEVER include full card number, CVV, expiration date, or card holder name.
+ * SECURITY: Must NEVER include full card number, CVV, expiration date, card holder name,
+ * billing fields, or metadata.
*/
export interface CreditCardCredentialResponse {
/** Last four digits of the credit card number */
diff --git a/skyvern-ts/client/src/api/types/CustomLlm.ts b/skyvern-ts/client/src/api/types/CustomLlm.ts
new file mode 100644
index 000000000..1d3d1e050
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/CustomLlm.ts
@@ -0,0 +1,12 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface CustomLlm {
+ id: string;
+ organization_id: string;
+ config: Skyvern.CustomLlmConfig;
+ created_at: string;
+ modified_at: string;
+ valid: boolean;
+}
diff --git a/skyvern-ts/client/src/api/types/CustomLlmConfig.ts b/skyvern-ts/client/src/api/types/CustomLlmConfig.ts
new file mode 100644
index 000000000..9071c504c
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/CustomLlmConfig.ts
@@ -0,0 +1,17 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface CustomLlmConfig {
+ display_name: string;
+ provider: Skyvern.CustomLlmProvider;
+ model_name: string;
+ api_base?: string;
+ api_key?: string;
+ api_version?: string;
+ supports_vision?: boolean;
+ add_assistant_prefix?: boolean;
+ max_completion_tokens?: number;
+ temperature?: number;
+ reasoning_effort?: string;
+}
diff --git a/skyvern-ts/client/src/api/types/CustomLlmListResponse.ts b/skyvern-ts/client/src/api/types/CustomLlmListResponse.ts
new file mode 100644
index 000000000..0a5164c48
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/CustomLlmListResponse.ts
@@ -0,0 +1,7 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface CustomLlmListResponse {
+ custom_llms: Skyvern.CustomLlm[];
+}
diff --git a/skyvern-ts/client/src/api/types/CustomLlmProvider.ts b/skyvern-ts/client/src/api/types/CustomLlmProvider.ts
new file mode 100644
index 000000000..0384a220b
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/CustomLlmProvider.ts
@@ -0,0 +1,8 @@
+// This file was auto-generated by Fern from our API Definition.
+
+export const CustomLlmProvider = {
+ OpenaiCompatible: "openai_compatible",
+ Ollama: "ollama",
+ Openrouter: "openrouter",
+} as const;
+export type CustomLlmProvider = (typeof CustomLlmProvider)[keyof typeof CustomLlmProvider];
diff --git a/skyvern-ts/client/src/api/types/CustomLlmResponse.ts b/skyvern-ts/client/src/api/types/CustomLlmResponse.ts
new file mode 100644
index 000000000..4b0c3c0b4
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/CustomLlmResponse.ts
@@ -0,0 +1,7 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface CustomLlmResponse {
+ custom_llm: Skyvern.CustomLlm;
+}
diff --git a/skyvern-ts/client/src/api/types/EmailInboxBlock.ts b/skyvern-ts/client/src/api/types/EmailInboxBlock.ts
new file mode 100644
index 000000000..8dd8a4cbb
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/EmailInboxBlock.ts
@@ -0,0 +1,34 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface EmailInboxBlock {
+ /** Author-facing identifier for a block; unique within a workflow. */
+ label: string;
+ /** Optional pointer to the next block label when constructing a DAG. Defaults to sequential order when omitted. */
+ next_block_label?: string;
+ output_parameter: Skyvern.OutputParameter;
+ continue_on_failure?: boolean;
+ model?: Record<string, unknown>;
+ disable_cache?: boolean;
+ ignore_workflow_system_prompt?: boolean;
+ next_loop_on_failure?: boolean;
+ email_client: EmailInboxBlock.EmailClient;
+ credential_id?: string;
+ folder?: string;
+ prompt?: string;
+ sender?: string;
+ subject?: string;
+ newer_than_days?: number;
+ max_results?: number;
+ include_body?: boolean;
+ parameters?: Skyvern.EmailInboxBlockParametersItem[];
+}
+
+export namespace EmailInboxBlock {
+ export const EmailClient = {
+ Gmail: "gmail",
+ Outlook: "outlook",
+ } as const;
+ export type EmailClient = (typeof EmailClient)[keyof typeof EmailClient];
+}
diff --git a/skyvern-ts/client/src/api/types/EmailInboxBlockParametersItem.ts b/skyvern-ts/client/src/api/types/EmailInboxBlockParametersItem.ts
new file mode 100644
index 000000000..12b5f9b15
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/EmailInboxBlockParametersItem.ts
@@ -0,0 +1,62 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export type EmailInboxBlockParametersItem =
+ | Skyvern.EmailInboxBlockParametersItem.AwsSecret
+ | Skyvern.EmailInboxBlockParametersItem.AzureSecret
+ | Skyvern.EmailInboxBlockParametersItem.AzureVaultCredential
+ | Skyvern.EmailInboxBlockParametersItem.BitwardenCreditCardData
+ | Skyvern.EmailInboxBlockParametersItem.BitwardenLoginCredential
+ | Skyvern.EmailInboxBlockParametersItem.BitwardenSensitiveInformation
+ | Skyvern.EmailInboxBlockParametersItem.Context
+ | Skyvern.EmailInboxBlockParametersItem.Credential
+ | Skyvern.EmailInboxBlockParametersItem.Onepassword
+ | Skyvern.EmailInboxBlockParametersItem.Output
+ | Skyvern.EmailInboxBlockParametersItem.Workflow;
+
+export namespace EmailInboxBlockParametersItem {
+ export interface AwsSecret extends Skyvern.AwsSecretParameter {
+ parameter_type: "aws_secret";
+ }
+
+ export interface AzureSecret extends Skyvern.AzureSecretParameter {
+ parameter_type: "azure_secret";
+ }
+
+ export interface AzureVaultCredential extends Skyvern.AzureVaultCredentialParameter {
+ parameter_type: "azure_vault_credential";
+ }
+
+ export interface BitwardenCreditCardData extends Skyvern.BitwardenCreditCardDataParameter {
+ parameter_type: "bitwarden_credit_card_data";
+ }
+
+ export interface BitwardenLoginCredential extends Skyvern.BitwardenLoginCredentialParameter {
+ parameter_type: "bitwarden_login_credential";
+ }
+
+ export interface BitwardenSensitiveInformation extends Skyvern.BitwardenSensitiveInformationParameter {
+ parameter_type: "bitwarden_sensitive_information";
+ }
+
+ export interface Context extends Skyvern.ContextParameter {
+ parameter_type: "context";
+ }
+
+ export interface Credential extends Skyvern.CredentialParameter {
+ parameter_type: "credential";
+ }
+
+ export interface Onepassword extends Skyvern.OnePasswordCredentialParameter {
+ parameter_type: "onepassword";
+ }
+
+ export interface Output extends Skyvern.OutputParameter {
+ parameter_type: "output";
+ }
+
+ export interface Workflow extends Skyvern.WorkflowParameter {
+ parameter_type: "workflow";
+ }
+}
diff --git a/skyvern-ts/client/src/api/types/EmailInboxBlockYaml.ts b/skyvern-ts/client/src/api/types/EmailInboxBlockYaml.ts
new file mode 100644
index 000000000..21a761bde
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/EmailInboxBlockYaml.ts
@@ -0,0 +1,30 @@
+// This file was auto-generated by Fern from our API Definition.
+
+export interface EmailInboxBlockYaml {
+ /** Author-facing identifier; must be unique per workflow. */
+ label: string;
+ /** Optional pointer to the label of the next block. When omitted, it will default to sequential order. See [[s-4bnl]]. */
+ next_block_label?: string;
+ continue_on_failure?: boolean;
+ model?: Record<string, unknown>;
+ ignore_workflow_system_prompt?: boolean;
+ next_loop_on_failure?: boolean;
+ email_client: EmailInboxBlockYaml.EmailClient;
+ credential_id?: string;
+ folder?: string;
+ prompt?: string;
+ sender?: string;
+ subject?: string;
+ newer_than_days?: number;
+ max_results?: number;
+ include_body?: boolean;
+ parameter_keys?: string[];
+}
+
+export namespace EmailInboxBlockYaml {
+ export const EmailClient = {
+ Gmail: "gmail",
+ Outlook: "outlook",
+ } as const;
+ export type EmailClient = (typeof EmailClient)[keyof typeof EmailClient];
+}
diff --git a/skyvern-ts/client/src/api/types/FileStorageType.ts b/skyvern-ts/client/src/api/types/FileStorageType.ts
index b72f6cce4..c53e755fa 100644
--- a/skyvern-ts/client/src/api/types/FileStorageType.ts
+++ b/skyvern-ts/client/src/api/types/FileStorageType.ts
@@ -4,5 +4,6 @@ export const FileStorageType = {
S3: "s3",
Azure: "azure",
GoogleDrive: "google_drive",
+ Sftp: "sftp",
} as const;
export type FileStorageType = (typeof FileStorageType)[keyof typeof FileStorageType];
diff --git a/skyvern-ts/client/src/api/types/FileType.ts b/skyvern-ts/client/src/api/types/FileType.ts
index 209d6b4d5..10827693c 100644
--- a/skyvern-ts/client/src/api/types/FileType.ts
+++ b/skyvern-ts/client/src/api/types/FileType.ts
@@ -7,5 +7,6 @@ export const FileType = {
Pdf: "pdf",
Image: "image",
Docx: "docx",
+ Zip: "zip",
} as const;
export type FileType = (typeof FileType)[keyof typeof FileType];
diff --git a/skyvern-ts/client/src/api/types/FileUploadBlock.ts b/skyvern-ts/client/src/api/types/FileUploadBlock.ts
index 1bb853e66..b856646f0 100644
--- a/skyvern-ts/client/src/api/types/FileUploadBlock.ts
+++ b/skyvern-ts/client/src/api/types/FileUploadBlock.ts
@@ -23,5 +23,17 @@ export interface FileUploadBlock {
azure_blob_container_name?: string;
google_credential_id?: string;
google_drive_folder_id?: string;
+ sftp_host?: string;
+ sftp_port?: number;
+ sftp_username?: string;
+ sftp_password?: string;
+ sftp_private_key?: string;
+ sftp_private_key_passphrase?: string;
+ sftp_remote_path?: string;
+ sftp_host_key?: string;
+ /** Optional natural-language control over which downloaded files are uploaded; empty means upload all. */
+ prompt?: string;
path?: string;
+ /** When the run download directory has no files, allow the empty upload only after confirming no registered, browser-session, or alternate candidate downloads exist (False, default). Set True to always allow an empty upload. */
+ continue_on_empty?: boolean;
}
diff --git a/skyvern-ts/client/src/api/types/FileUploadBlockYaml.ts b/skyvern-ts/client/src/api/types/FileUploadBlockYaml.ts
index 3c21f228f..87d237e68 100644
--- a/skyvern-ts/client/src/api/types/FileUploadBlockYaml.ts
+++ b/skyvern-ts/client/src/api/types/FileUploadBlockYaml.ts
@@ -22,5 +22,15 @@ export interface FileUploadBlockYaml {
azure_folder_path?: string;
google_credential_id?: string;
google_drive_folder_id?: string;
+ sftp_host?: string;
+ sftp_port?: number;
+ sftp_username?: string;
+ sftp_password?: string;
+ sftp_private_key?: string;
+ sftp_private_key_passphrase?: string;
+ sftp_remote_path?: string;
+ sftp_host_key?: string;
+ /** Optional natural-language control over which downloaded files are uploaded; empty means upload all. */
+ prompt?: string;
path?: string;
}
diff --git a/skyvern-ts/client/src/api/types/ForLoopBlockLoopBlocksItem.ts b/skyvern-ts/client/src/api/types/ForLoopBlockLoopBlocksItem.ts
index 4f57cdbe0..b77ebbf76 100644
--- a/skyvern-ts/client/src/api/types/ForLoopBlockLoopBlocksItem.ts
+++ b/skyvern-ts/client/src/api/types/ForLoopBlockLoopBlocksItem.ts
@@ -7,6 +7,7 @@ export type ForLoopBlockLoopBlocksItem =
| Skyvern.ForLoopBlockLoopBlocksItem.Code
| Skyvern.ForLoopBlockLoopBlocksItem.Conditional
| Skyvern.ForLoopBlockLoopBlocksItem.DownloadToS3
+ | Skyvern.ForLoopBlockLoopBlocksItem.EmailInbox
| Skyvern.ForLoopBlockLoopBlocksItem.Extraction
| Skyvern.ForLoopBlockLoopBlocksItem.FileDownload
| Skyvern.ForLoopBlockLoopBlocksItem.FileUpload
@@ -19,9 +20,11 @@ export type ForLoopBlockLoopBlocksItem =
| Skyvern.ForLoopBlockLoopBlocksItem.HumanInteraction
| Skyvern.ForLoopBlockLoopBlocksItem.Login
| Skyvern.ForLoopBlockLoopBlocksItem.Navigation
+ | Skyvern.ForLoopBlockLoopBlocksItem.PdfFill
| Skyvern.ForLoopBlockLoopBlocksItem.PdfParser
| Skyvern.ForLoopBlockLoopBlocksItem.PrintPage
| Skyvern.ForLoopBlockLoopBlocksItem.SendEmail
+ | Skyvern.ForLoopBlockLoopBlocksItem.SplitPdf
| Skyvern.ForLoopBlockLoopBlocksItem.Task
| Skyvern.ForLoopBlockLoopBlocksItem.TaskV2
| Skyvern.ForLoopBlockLoopBlocksItem.TextPrompt
@@ -48,6 +51,10 @@ export namespace ForLoopBlockLoopBlocksItem {
block_type: "download_to_s3";
}
+ export interface EmailInbox extends Skyvern.EmailInboxBlock {
+ block_type: "email_inbox";
+ }
+
export interface Extraction extends Skyvern.ExtractionBlock {
block_type: "extraction";
}
@@ -96,6 +103,10 @@ export namespace ForLoopBlockLoopBlocksItem {
block_type: "navigation";
}
+ export interface PdfFill extends Skyvern.PdfFillBlock {
+ block_type: "pdf_fill";
+ }
+
export interface PdfParser extends Skyvern.PdfParserBlock {
block_type: "pdf_parser";
}
@@ -108,6 +119,10 @@ export namespace ForLoopBlockLoopBlocksItem {
block_type: "send_email";
}
+ export interface SplitPdf extends Skyvern.SplitPdfBlock {
+ block_type: "split_pdf";
+ }
+
export interface Task extends Skyvern.TaskBlock {
block_type: "task";
}
diff --git a/skyvern-ts/client/src/api/types/ForLoopBlockYamlLoopBlocksItem.ts b/skyvern-ts/client/src/api/types/ForLoopBlockYamlLoopBlocksItem.ts
index dcf3026a0..c0fbb52b4 100644
--- a/skyvern-ts/client/src/api/types/ForLoopBlockYamlLoopBlocksItem.ts
+++ b/skyvern-ts/client/src/api/types/ForLoopBlockYamlLoopBlocksItem.ts
@@ -27,8 +27,11 @@ export type ForLoopBlockYamlLoopBlocksItem =
| Skyvern.ForLoopBlockYamlLoopBlocksItem.HttpRequest
| Skyvern.ForLoopBlockYamlLoopBlocksItem.Conditional
| Skyvern.ForLoopBlockYamlLoopBlocksItem.PrintPage
+ | Skyvern.ForLoopBlockYamlLoopBlocksItem.PdfFill
+ | Skyvern.ForLoopBlockYamlLoopBlocksItem.SplitPdf
| Skyvern.ForLoopBlockYamlLoopBlocksItem.WorkflowTrigger
| Skyvern.ForLoopBlockYamlLoopBlocksItem.GoogleSheetsRead
+ | Skyvern.ForLoopBlockYamlLoopBlocksItem.EmailInbox
| Skyvern.ForLoopBlockYamlLoopBlocksItem.GoogleSheetsWrite;
export namespace ForLoopBlockYamlLoopBlocksItem {
@@ -128,6 +131,14 @@ export namespace ForLoopBlockYamlLoopBlocksItem {
block_type: "print_page";
}
+ export interface PdfFill extends Skyvern.PdfFillBlockYaml {
+ block_type: "pdf_fill";
+ }
+
+ export interface SplitPdf extends Skyvern.SplitPdfBlockYaml {
+ block_type: "split_pdf";
+ }
+
export interface WorkflowTrigger extends Skyvern.WorkflowTriggerBlockYaml {
block_type: "workflow_trigger";
}
@@ -136,6 +147,10 @@ export namespace ForLoopBlockYamlLoopBlocksItem {
block_type: "google_sheets_read";
}
+ export interface EmailInbox extends Skyvern.EmailInboxBlockYaml {
+ block_type: "email_inbox";
+ }
+
export interface GoogleSheetsWrite extends Skyvern.GoogleSheetsWriteBlockYaml {
block_type: "google_sheets_write";
}
diff --git a/skyvern-ts/client/src/api/types/HttpRequestBlock.ts b/skyvern-ts/client/src/api/types/HttpRequestBlock.ts
index 0c673be30..038826075 100644
--- a/skyvern-ts/client/src/api/types/HttpRequestBlock.ts
+++ b/skyvern-ts/client/src/api/types/HttpRequestBlock.ts
@@ -22,5 +22,6 @@ export interface HttpRequestBlock {
follow_redirects?: boolean;
download_filename?: string;
save_response_as_file?: boolean;
+ secret_response_paths?: string[];
parameters?: Skyvern.HttpRequestBlockParametersItem[];
}
diff --git a/skyvern-ts/client/src/api/types/HttpRequestBlockYaml.ts b/skyvern-ts/client/src/api/types/HttpRequestBlockYaml.ts
index 6db4d0cda..f17afc73a 100644
--- a/skyvern-ts/client/src/api/types/HttpRequestBlockYaml.ts
+++ b/skyvern-ts/client/src/api/types/HttpRequestBlockYaml.ts
@@ -18,5 +18,6 @@ export interface HttpRequestBlockYaml {
follow_redirects?: boolean;
download_filename?: string;
save_response_as_file?: boolean;
+ secret_response_paths?: string[];
parameter_keys?: string[];
}
diff --git a/skyvern-ts/client/src/api/types/NonEmptyCreditCardCredential.ts b/skyvern-ts/client/src/api/types/NonEmptyCreditCardCredential.ts
index 5acebb51c..ca6c3a1e3 100644
--- a/skyvern-ts/client/src/api/types/NonEmptyCreditCardCredential.ts
+++ b/skyvern-ts/client/src/api/types/NonEmptyCreditCardCredential.ts
@@ -1,5 +1,7 @@
// This file was auto-generated by Fern from our API Definition.
+import type * as Skyvern from "../index.js";
+
/**
* Credit card credential model that requires non-empty values.
*/
@@ -16,4 +18,12 @@ export interface NonEmptyCreditCardCredential {
card_brand: string;
/** The name of the card holder (must not be empty) */
card_holder_name: string;
+ /** Optional billing address associated with the card */
+ billing_address?: Skyvern.CreditCardBillingAddress;
+ /** Optional billing email address */
+ billing_email?: string;
+ /** Optional billing phone number */
+ billing_phone?: string;
+ /** Optional additional credit card metadata fields */
+ metadata?: Record<string, string | undefined>;
}
diff --git a/skyvern-ts/client/src/api/types/PdfFillBlock.ts b/skyvern-ts/client/src/api/types/PdfFillBlock.ts
new file mode 100644
index 000000000..6145dea35
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/PdfFillBlock.ts
@@ -0,0 +1,25 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface PdfFillBlock {
+ /** Author-facing identifier for a block; unique within a workflow. */
+ label: string;
+ /** Optional pointer to the next block label when constructing a DAG. Defaults to sequential order when omitted. */
+ next_block_label?: string;
+ output_parameter: Skyvern.OutputParameter;
+ continue_on_failure?: boolean;
+ model?: Record<string, unknown>;
+ disable_cache?: boolean;
+ ignore_workflow_system_prompt?: boolean;
+ next_loop_on_failure?: boolean;
+ file_url: string;
+ prompt: string;
+ payload?: PdfFillBlock.Payload;
+ llm_key?: string;
+ parameters?: Skyvern.PdfFillBlockParametersItem[];
+}
+
+export namespace PdfFillBlock {
+ export type Payload = Record<string, unknown> | unknown[] | string;
+}
diff --git a/skyvern-ts/client/src/api/types/PdfFillBlockParametersItem.ts b/skyvern-ts/client/src/api/types/PdfFillBlockParametersItem.ts
new file mode 100644
index 000000000..95d7a8891
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/PdfFillBlockParametersItem.ts
@@ -0,0 +1,62 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export type PdfFillBlockParametersItem =
+ | Skyvern.PdfFillBlockParametersItem.AwsSecret
+ | Skyvern.PdfFillBlockParametersItem.AzureSecret
+ | Skyvern.PdfFillBlockParametersItem.AzureVaultCredential
+ | Skyvern.PdfFillBlockParametersItem.BitwardenCreditCardData
+ | Skyvern.PdfFillBlockParametersItem.BitwardenLoginCredential
+ | Skyvern.PdfFillBlockParametersItem.BitwardenSensitiveInformation
+ | Skyvern.PdfFillBlockParametersItem.Context
+ | Skyvern.PdfFillBlockParametersItem.Credential
+ | Skyvern.PdfFillBlockParametersItem.Onepassword
+ | Skyvern.PdfFillBlockParametersItem.Output
+ | Skyvern.PdfFillBlockParametersItem.Workflow;
+
+export namespace PdfFillBlockParametersItem {
+ export interface AwsSecret extends Skyvern.AwsSecretParameter {
+ parameter_type: "aws_secret";
+ }
+
+ export interface AzureSecret extends Skyvern.AzureSecretParameter {
+ parameter_type: "azure_secret";
+ }
+
+ export interface AzureVaultCredential extends Skyvern.AzureVaultCredentialParameter {
+ parameter_type: "azure_vault_credential";
+ }
+
+ export interface BitwardenCreditCardData extends Skyvern.BitwardenCreditCardDataParameter {
+ parameter_type: "bitwarden_credit_card_data";
+ }
+
+ export interface BitwardenLoginCredential extends Skyvern.BitwardenLoginCredentialParameter {
+ parameter_type: "bitwarden_login_credential";
+ }
+
+ export interface BitwardenSensitiveInformation extends Skyvern.BitwardenSensitiveInformationParameter {
+ parameter_type: "bitwarden_sensitive_information";
+ }
+
+ export interface Context extends Skyvern.ContextParameter {
+ parameter_type: "context";
+ }
+
+ export interface Credential extends Skyvern.CredentialParameter {
+ parameter_type: "credential";
+ }
+
+ export interface Onepassword extends Skyvern.OnePasswordCredentialParameter {
+ parameter_type: "onepassword";
+ }
+
+ export interface Output extends Skyvern.OutputParameter {
+ parameter_type: "output";
+ }
+
+ export interface Workflow extends Skyvern.WorkflowParameter {
+ parameter_type: "workflow";
+ }
+}
diff --git a/skyvern-ts/client/src/api/types/PdfFillBlockYaml.ts b/skyvern-ts/client/src/api/types/PdfFillBlockYaml.ts
new file mode 100644
index 000000000..decb5f765
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/PdfFillBlockYaml.ts
@@ -0,0 +1,21 @@
+// This file was auto-generated by Fern from our API Definition.
+
+export interface PdfFillBlockYaml {
+ /** Author-facing identifier; must be unique per workflow. */
+ label: string;
+ /** Optional pointer to the label of the next block. When omitted, it will default to sequential order. See [[s-4bnl]]. */
+ next_block_label?: string;
+ continue_on_failure?: boolean;
+ model?: Record<string, unknown>;
+ ignore_workflow_system_prompt?: boolean;
+ next_loop_on_failure?: boolean;
+ file_url: string;
+ prompt: string;
+ payload?: PdfFillBlockYaml.Payload;
+ llm_key?: string;
+ parameter_keys?: string[];
+}
+
+export namespace PdfFillBlockYaml {
+ export type Payload = Record<string, unknown> | unknown[] | string;
+}
diff --git a/skyvern-ts/client/src/api/types/RunTagHistoryResponse.ts b/skyvern-ts/client/src/api/types/RunTagHistoryResponse.ts
new file mode 100644
index 000000000..8187cf4d2
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/RunTagHistoryResponse.ts
@@ -0,0 +1,8 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface RunTagHistoryResponse {
+ workflow_run_id: string;
+ events: Skyvern.TagHistoryItem[];
+}
diff --git a/skyvern-ts/client/src/api/types/RunTagsBatchResponse.ts b/skyvern-ts/client/src/api/types/RunTagsBatchResponse.ts
new file mode 100644
index 000000000..86b64f1f8
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/RunTagsBatchResponse.ts
@@ -0,0 +1,14 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+/**
+ * Response for the run-tags batch endpoint.
+ *
+ * Runs with no tags are present with an empty list so the frontend can
+ * distinguish "fetched, none set" from "not fetched" without a second call.
+ * Runs outside the caller's org are silently absent (no leakage).
+ */
+export interface RunTagsBatchResponse {
+ run_tags: Record<string, Skyvern.TagItem[]>;
+}
diff --git a/skyvern-ts/client/src/api/types/RunTagsResponse.ts b/skyvern-ts/client/src/api/types/RunTagsResponse.ts
new file mode 100644
index 000000000..33eb66b0c
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/RunTagsResponse.ts
@@ -0,0 +1,11 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+/**
+ * Current tags for a workflow run.
+ */
+export interface RunTagsResponse {
+ workflow_run_id: string;
+ tags: Skyvern.TagResponse[];
+}
diff --git a/skyvern-ts/client/src/api/types/RunType.ts b/skyvern-ts/client/src/api/types/RunType.ts
new file mode 100644
index 000000000..e54f14aad
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/RunType.ts
@@ -0,0 +1,12 @@
+// This file was auto-generated by Fern from our API Definition.
+
+export const RunType = {
+ TaskV1: "task_v1",
+ TaskV2: "task_v2",
+ WorkflowRun: "workflow_run",
+ OpenaiCua: "openai_cua",
+ AnthropicCua: "anthropic_cua",
+ UiTars: "ui_tars",
+ YutoriNavigator: "yutori_navigator",
+} as const;
+export type RunType = (typeof RunType)[keyof typeof RunType];
diff --git a/skyvern-ts/client/src/api/types/SplitPdfBlock.ts b/skyvern-ts/client/src/api/types/SplitPdfBlock.ts
new file mode 100644
index 000000000..93b5cfc20
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/SplitPdfBlock.ts
@@ -0,0 +1,20 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export interface SplitPdfBlock {
+ /** Author-facing identifier for a block; unique within a workflow. */
+ label: string;
+ /** Optional pointer to the next block label when constructing a DAG. Defaults to sequential order when omitted. */
+ next_block_label?: string;
+ output_parameter: Skyvern.OutputParameter;
+ continue_on_failure?: boolean;
+ model?: Record<string, unknown>;
+ disable_cache?: boolean;
+ ignore_workflow_system_prompt?: boolean;
+ next_loop_on_failure?: boolean;
+ file_url: string;
+ prompt: string;
+ llm_key?: string;
+ parameters?: Skyvern.SplitPdfBlockParametersItem[];
+}
diff --git a/skyvern-ts/client/src/api/types/SplitPdfBlockParametersItem.ts b/skyvern-ts/client/src/api/types/SplitPdfBlockParametersItem.ts
new file mode 100644
index 000000000..1ab78bd02
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/SplitPdfBlockParametersItem.ts
@@ -0,0 +1,62 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+export type SplitPdfBlockParametersItem =
+ | Skyvern.SplitPdfBlockParametersItem.AwsSecret
+ | Skyvern.SplitPdfBlockParametersItem.AzureSecret
+ | Skyvern.SplitPdfBlockParametersItem.AzureVaultCredential
+ | Skyvern.SplitPdfBlockParametersItem.BitwardenCreditCardData
+ | Skyvern.SplitPdfBlockParametersItem.BitwardenLoginCredential
+ | Skyvern.SplitPdfBlockParametersItem.BitwardenSensitiveInformation
+ | Skyvern.SplitPdfBlockParametersItem.Context
+ | Skyvern.SplitPdfBlockParametersItem.Credential
+ | Skyvern.SplitPdfBlockParametersItem.Onepassword
+ | Skyvern.SplitPdfBlockParametersItem.Output
+ | Skyvern.SplitPdfBlockParametersItem.Workflow;
+
+export namespace SplitPdfBlockParametersItem {
+ export interface AwsSecret extends Skyvern.AwsSecretParameter {
+ parameter_type: "aws_secret";
+ }
+
+ export interface AzureSecret extends Skyvern.AzureSecretParameter {
+ parameter_type: "azure_secret";
+ }
+
+ export interface AzureVaultCredential extends Skyvern.AzureVaultCredentialParameter {
+ parameter_type: "azure_vault_credential";
+ }
+
+ export interface BitwardenCreditCardData extends Skyvern.BitwardenCreditCardDataParameter {
+ parameter_type: "bitwarden_credit_card_data";
+ }
+
+ export interface BitwardenLoginCredential extends Skyvern.BitwardenLoginCredentialParameter {
+ parameter_type: "bitwarden_login_credential";
+ }
+
+ export interface BitwardenSensitiveInformation extends Skyvern.BitwardenSensitiveInformationParameter {
+ parameter_type: "bitwarden_sensitive_information";
+ }
+
+ export interface Context extends Skyvern.ContextParameter {
+ parameter_type: "context";
+ }
+
+ export interface Credential extends Skyvern.CredentialParameter {
+ parameter_type: "credential";
+ }
+
+ export interface Onepassword extends Skyvern.OnePasswordCredentialParameter {
+ parameter_type: "onepassword";
+ }
+
+ export interface Output extends Skyvern.OutputParameter {
+ parameter_type: "output";
+ }
+
+ export interface Workflow extends Skyvern.WorkflowParameter {
+ parameter_type: "workflow";
+ }
+}
diff --git a/skyvern-ts/client/src/api/types/SplitPdfBlockYaml.ts b/skyvern-ts/client/src/api/types/SplitPdfBlockYaml.ts
new file mode 100644
index 000000000..99f3cfcf4
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/SplitPdfBlockYaml.ts
@@ -0,0 +1,16 @@
+// This file was auto-generated by Fern from our API Definition.
+
+export interface SplitPdfBlockYaml {
+ /** Author-facing identifier; must be unique per workflow. */
+ label: string;
+ /** Optional pointer to the label of the next block. When omitted, it will default to sequential order. See [[s-4bnl]]. */
+ next_block_label?: string;
+ continue_on_failure?: boolean;
+ model?: Record<string, unknown>;
+ ignore_workflow_system_prompt?: boolean;
+ next_loop_on_failure?: boolean;
+ file_url: string;
+ prompt: string;
+ llm_key?: string;
+ parameter_keys?: string[];
+}
diff --git a/skyvern-ts/client/src/api/types/TagApplyRequest.ts b/skyvern-ts/client/src/api/types/TagApplyRequest.ts
new file mode 100644
index 000000000..699ee0478
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/TagApplyRequest.ts
@@ -0,0 +1,16 @@
+// This file was auto-generated by Fern from our API Definition.
+
+import type * as Skyvern from "../index.js";
+
+/**
+ * Body for ``POST /v1/workflows/{wpid}/tags``. Either field may be empty (both
+ * empty is a no-op). On a same-identity collision, set wins over delete.
+ */
+export interface TagApplyRequest {
+ /** Tags to set (overwrite). List of {key?, value} objects. */
+ tags?: Skyvern.TagInput[];
+ /** Tags to soft-delete. List of {key?, value?} targets. */
+ tags_to_delete?: Skyvern.TagDeleteInput[];
+ /** Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color. */
+ colors?: Record<string, string | undefined>;
+}
diff --git a/skyvern-ts/client/src/api/types/TagKeyDeleteResponse.ts b/skyvern-ts/client/src/api/types/TagKeyDeleteResponse.ts
index 9869f0d55..56212225f 100644
--- a/skyvern-ts/client/src/api/types/TagKeyDeleteResponse.ts
+++ b/skyvern-ts/client/src/api/types/TagKeyDeleteResponse.ts
@@ -6,4 +6,6 @@
export interface TagKeyDeleteResponse {
key: string;
removed_from_workflow_count: number;
+ removed_from_run_count?: number;
+ removed_count?: number;
}
diff --git a/skyvern-ts/client/src/api/types/TagValue.ts b/skyvern-ts/client/src/api/types/TagValue.ts
new file mode 100644
index 000000000..423e77686
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/TagValue.ts
@@ -0,0 +1,13 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * Tag-value color registry entry: the palette color assigned to a grouped
+ * (key, value) pair.
+ */
+export interface TagValue {
+ key: string;
+ value: string;
+ color: string;
+ /** Number of non-deleted workflows currently carrying this (key, value) label. */
+ workflow_count?: number;
+}
diff --git a/skyvern-ts/client/src/api/types/TagValueDeleteResponse.ts b/skyvern-ts/client/src/api/types/TagValueDeleteResponse.ts
new file mode 100644
index 000000000..ca8ea2997
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/TagValueDeleteResponse.ts
@@ -0,0 +1,12 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * Response for ``DELETE /v1/tag-values/{key}``.
+ */
+export interface TagValueDeleteResponse {
+ key: string;
+ value: string;
+ removed_from_workflow_count: number;
+ removed_from_run_count?: number;
+ removed_count?: number;
+}
diff --git a/skyvern-ts/client/src/api/types/TagValueRenameResponse.ts b/skyvern-ts/client/src/api/types/TagValueRenameResponse.ts
new file mode 100644
index 000000000..89cf14c50
--- /dev/null
+++ b/skyvern-ts/client/src/api/types/TagValueRenameResponse.ts
@@ -0,0 +1,12 @@
+// This file was auto-generated by Fern from our API Definition.
+
+/**
+ * Response for ``PATCH /v1/tag-values/{key}/rename``: the renamed label with its
+ * carried-over color and the number of workflows re-tagged.
+ */
+export interface TagValueRenameResponse {
+ key: string;
+ value: string;
+ color: string;
+ renamed_workflow_count: number;
+}
diff --git a/skyvern-ts/client/src/api/types/TaskRunListItem.ts b/skyvern-ts/client/src/api/types/TaskRunListItem.ts
index 7ad9ce022..aa97e63e2 100644
--- a/skyvern-ts/client/src/api/types/TaskRunListItem.ts
+++ b/skyvern-ts/client/src/api/types/TaskRunListItem.ts
@@ -1,5 +1,7 @@
// This file was auto-generated by Fern from our API Definition.
+import type * as Skyvern from "../index.js";
+
/**
* Lightweight run-history item backed by the task_runs table.
*/
@@ -15,4 +17,5 @@ export interface TaskRunListItem {
workflow_permanent_id?: string;
workflow_deleted?: boolean;
script_run?: boolean;
+ trigger_type?: Skyvern.WorkflowRunTriggerType;
}
diff --git a/skyvern-ts/client/src/api/types/ValidationBlock.ts b/skyvern-ts/client/src/api/types/ValidationBlock.ts
index 94279b42f..37c0a3b82 100644
--- a/skyvern-ts/client/src/api/types/ValidationBlock.ts
+++ b/skyvern-ts/client/src/api/types/ValidationBlock.ts
@@ -34,6 +34,7 @@ export interface ValidationBlock {
include_action_history_in_verification?: boolean;
download_timeout?: number;
include_extracted_text?: boolean;
+ without_page_information?: boolean;
}
export namespace ValidationBlock {
diff --git a/skyvern-ts/client/src/api/types/ValidationBlockYaml.ts b/skyvern-ts/client/src/api/types/ValidationBlockYaml.ts
index efd7eac7d..e026db748 100644
--- a/skyvern-ts/client/src/api/types/ValidationBlockYaml.ts
+++ b/skyvern-ts/client/src/api/types/ValidationBlockYaml.ts
@@ -14,4 +14,5 @@ export interface ValidationBlockYaml {
error_code_mapping?: Record<string, string | undefined>;
parameter_keys?: string[];
disable_cache?: boolean;
+ without_page_information?: boolean;
}
diff --git a/skyvern-ts/client/src/api/types/WhileLoopBlockLoopBlocksItem.ts b/skyvern-ts/client/src/api/types/WhileLoopBlockLoopBlocksItem.ts
index 6816f865c..23617a152 100644
--- a/skyvern-ts/client/src/api/types/WhileLoopBlockLoopBlocksItem.ts
+++ b/skyvern-ts/client/src/api/types/WhileLoopBlockLoopBlocksItem.ts
@@ -7,6 +7,7 @@ export type WhileLoopBlockLoopBlocksItem =
| Skyvern.WhileLoopBlockLoopBlocksItem.Code
| Skyvern.WhileLoopBlockLoopBlocksItem.Conditional
| Skyvern.WhileLoopBlockLoopBlocksItem.DownloadToS3
+ | Skyvern.WhileLoopBlockLoopBlocksItem.EmailInbox
| Skyvern.WhileLoopBlockLoopBlocksItem.Extraction
| Skyvern.WhileLoopBlockLoopBlocksItem.FileDownload
| Skyvern.WhileLoopBlockLoopBlocksItem.FileUpload
@@ -19,9 +20,11 @@ export type WhileLoopBlockLoopBlocksItem =
| Skyvern.WhileLoopBlockLoopBlocksItem.HumanInteraction
| Skyvern.WhileLoopBlockLoopBlocksItem.Login
| Skyvern.WhileLoopBlockLoopBlocksItem.Navigation
+ | Skyvern.WhileLoopBlockLoopBlocksItem.PdfFill
| Skyvern.WhileLoopBlockLoopBlocksItem.PdfParser
| Skyvern.WhileLoopBlockLoopBlocksItem.PrintPage
| Skyvern.WhileLoopBlockLoopBlocksItem.SendEmail
+ | Skyvern.WhileLoopBlockLoopBlocksItem.SplitPdf
| Skyvern.WhileLoopBlockLoopBlocksItem.Task
| Skyvern.WhileLoopBlockLoopBlocksItem.TaskV2
| Skyvern.WhileLoopBlockLoopBlocksItem.TextPrompt
@@ -48,6 +51,10 @@ export namespace WhileLoopBlockLoopBlocksItem {
block_type: "download_to_s3";
}
+ export interface EmailInbox extends Skyvern.EmailInboxBlock {
+ block_type: "email_inbox";
+ }
+
export interface Extraction extends Skyvern.ExtractionBlock {
block_type: "extraction";
}
@@ -96,6 +103,10 @@ export namespace WhileLoopBlockLoopBlocksItem {
block_type: "navigation";
}
+ export interface PdfFill extends Skyvern.PdfFillBlock {
+ block_type: "pdf_fill";
+ }
+
export interface PdfParser extends Skyvern.PdfParserBlock {
block_type: "pdf_parser";
}
@@ -108,6 +119,10 @@ export namespace WhileLoopBlockLoopBlocksItem {
block_type: "send_email";
}
+ export interface SplitPdf extends Skyvern.SplitPdfBlock {
+ block_type: "split_pdf";
+ }
+
export interface Task extends Skyvern.TaskBlock {
block_type: "task";
}
diff --git a/skyvern-ts/client/src/api/types/WhileLoopBlockYamlLoopBlocksItem.ts b/skyvern-ts/client/src/api/types/WhileLoopBlockYamlLoopBlocksItem.ts
index 4194efdbd..b4143c567 100644
--- a/skyvern-ts/client/src/api/types/WhileLoopBlockYamlLoopBlocksItem.ts
+++ b/skyvern-ts/client/src/api/types/WhileLoopBlockYamlLoopBlocksItem.ts
@@ -27,8 +27,11 @@ export type WhileLoopBlockYamlLoopBlocksItem =
| Skyvern.WhileLoopBlockYamlLoopBlocksItem.HttpRequest
| Skyvern.WhileLoopBlockYamlLoopBlocksItem.Conditional
| Skyvern.WhileLoopBlockYamlLoopBlocksItem.PrintPage
+ | Skyvern.WhileLoopBlockYamlLoopBlocksItem.PdfFill
+ | Skyvern.WhileLoopBlockYamlLoopBlocksItem.SplitPdf
| Skyvern.WhileLoopBlockYamlLoopBlocksItem.WorkflowTrigger
| Skyvern.WhileLoopBlockYamlLoopBlocksItem.GoogleSheetsRead
+ | Skyvern.WhileLoopBlockYamlLoopBlocksItem.EmailInbox
| Skyvern.WhileLoopBlockYamlLoopBlocksItem.GoogleSheetsWrite;
export namespace WhileLoopBlockYamlLoopBlocksItem {
@@ -128,6 +131,14 @@ export namespace WhileLoopBlockYamlLoopBlocksItem {
block_type: "print_page";
}
+ export interface PdfFill extends Skyvern.PdfFillBlockYaml {
+ block_type: "pdf_fill";
+ }
+
+ export interface SplitPdf extends Skyvern.SplitPdfBlockYaml {
+ block_type: "split_pdf";
+ }
+
export interface WorkflowTrigger extends Skyvern.WorkflowTriggerBlockYaml {
block_type: "workflow_trigger";
}
@@ -136,6 +147,10 @@ export namespace WhileLoopBlockYamlLoopBlocksItem {
block_type: "google_sheets_read";
}
+ export interface EmailInbox extends Skyvern.EmailInboxBlockYaml {
+ block_type: "email_inbox";
+ }
+
export interface GoogleSheetsWrite extends Skyvern.GoogleSheetsWriteBlockYaml {
block_type: "google_sheets_write";
}
diff --git a/skyvern-ts/client/src/api/types/Workflow.ts b/skyvern-ts/client/src/api/types/Workflow.ts
index 2ac49403b..d4a22b2d9 100644
--- a/skyvern-ts/client/src/api/types/Workflow.ts
+++ b/skyvern-ts/client/src/api/types/Workflow.ts
@@ -17,7 +17,9 @@ export interface Workflow {
totp_verification_url?: string;
totp_identifier?: string;
persist_browser_session?: boolean;
+ pin_saved_session_ip?: boolean;
browser_profile_id?: string;
+ browser_profile_key?: string;
model?: Record<string, unknown>;
status?: Skyvern.WorkflowStatus;
max_screenshot_scrolls?: number;
@@ -28,6 +30,7 @@ export interface Workflow {
ai_fallback?: boolean;
cache_key?: string;
adaptive_caching?: boolean;
+ enable_self_healing?: boolean;
code_version?: number;
generate_script_on_terminal?: boolean;
run_sequentially?: boolean;
@@ -36,6 +39,7 @@ export interface Workflow {
import_error?: string;
created_by?: string;
edited_by?: string;
+ copilot_authored?: boolean;
created_at: string;
modified_at: string;
deleted_at?: string;
diff --git a/skyvern-ts/client/src/api/types/WorkflowCreateYamlRequest.ts b/skyvern-ts/client/src/api/types/WorkflowCreateYamlRequest.ts
index c3f581003..51d62439d 100644
--- a/skyvern-ts/client/src/api/types/WorkflowCreateYamlRequest.ts
+++ b/skyvern-ts/client/src/api/types/WorkflowCreateYamlRequest.ts
@@ -10,7 +10,9 @@ export interface WorkflowCreateYamlRequest {
totp_verification_url?: string;
totp_identifier?: string;
persist_browser_session?: boolean;
+ pin_saved_session_ip?: boolean;
browser_profile_id?: string;
+ browser_profile_key?: string;
model?: Record<string, unknown>;
workflow_definition: Skyvern.WorkflowDefinitionYaml;
is_saved_task?: boolean;
@@ -23,6 +25,7 @@ export interface WorkflowCreateYamlRequest {
ai_fallback?: boolean;
cache_key?: string;
adaptive_caching?: boolean;
+ enable_self_healing?: boolean;
code_version?: number;
generate_script_on_terminal?: boolean;
run_sequentially?: boolean;
diff --git a/skyvern-ts/client/src/api/types/WorkflowDefinitionBlocksItem.ts b/skyvern-ts/client/src/api/types/WorkflowDefinitionBlocksItem.ts
index a6727388a..31c0c6dff 100644
--- a/skyvern-ts/client/src/api/types/WorkflowDefinitionBlocksItem.ts
+++ b/skyvern-ts/client/src/api/types/WorkflowDefinitionBlocksItem.ts
@@ -7,6 +7,7 @@ export type WorkflowDefinitionBlocksItem =
| Skyvern.WorkflowDefinitionBlocksItem.Code
| Skyvern.WorkflowDefinitionBlocksItem.Conditional
| Skyvern.WorkflowDefinitionBlocksItem.DownloadToS3
+ | Skyvern.WorkflowDefinitionBlocksItem.EmailInbox
| Skyvern.WorkflowDefinitionBlocksItem.Extraction
| Skyvern.WorkflowDefinitionBlocksItem.FileDownload
| Skyvern.WorkflowDefinitionBlocksItem.FileUpload
@@ -19,9 +20,11 @@ export type WorkflowDefinitionBlocksItem =
| Skyvern.WorkflowDefinitionBlocksItem.HumanInteraction
| Skyvern.WorkflowDefinitionBlocksItem.Login
| Skyvern.WorkflowDefinitionBlocksItem.Navigation
+ | Skyvern.WorkflowDefinitionBlocksItem.PdfFill
| Skyvern.WorkflowDefinitionBlocksItem.PdfParser
| Skyvern.WorkflowDefinitionBlocksItem.PrintPage
| Skyvern.WorkflowDefinitionBlocksItem.SendEmail
+ | Skyvern.WorkflowDefinitionBlocksItem.SplitPdf
| Skyvern.WorkflowDefinitionBlocksItem.Task
| Skyvern.WorkflowDefinitionBlocksItem.TaskV2
| Skyvern.WorkflowDefinitionBlocksItem.TextPrompt
@@ -48,6 +51,10 @@ export namespace WorkflowDefinitionBlocksItem {
block_type: "download_to_s3";
}
+ export interface EmailInbox extends Skyvern.EmailInboxBlock {
+ block_type: "email_inbox";
+ }
+
export interface Extraction extends Skyvern.ExtractionBlock {
block_type: "extraction";
}
@@ -96,6 +103,10 @@ export namespace WorkflowDefinitionBlocksItem {
block_type: "navigation";
}
+ export interface PdfFill extends Skyvern.PdfFillBlock {
+ block_type: "pdf_fill";
+ }
+
export interface PdfParser extends Skyvern.PdfParserBlock {
block_type: "pdf_parser";
}
@@ -108,6 +119,10 @@ export namespace WorkflowDefinitionBlocksItem {
block_type: "send_email";
}
+ export interface SplitPdf extends Skyvern.SplitPdfBlock {
+ block_type: "split_pdf";
+ }
+
export interface Task extends Skyvern.TaskBlock {
block_type: "task";
}
diff --git a/skyvern-ts/client/src/api/types/WorkflowDefinitionYamlBlocksItem.ts b/skyvern-ts/client/src/api/types/WorkflowDefinitionYamlBlocksItem.ts
index 617fd1336..337886db4 100644
--- a/skyvern-ts/client/src/api/types/WorkflowDefinitionYamlBlocksItem.ts
+++ b/skyvern-ts/client/src/api/types/WorkflowDefinitionYamlBlocksItem.ts
@@ -7,6 +7,7 @@ export type WorkflowDefinitionYamlBlocksItem =
| Skyvern.WorkflowDefinitionYamlBlocksItem.Code
| Skyvern.WorkflowDefinitionYamlBlocksItem.Conditional
| Skyvern.WorkflowDefinitionYamlBlocksItem.DownloadToS3
+ | Skyvern.WorkflowDefinitionYamlBlocksItem.EmailInbox
| Skyvern.WorkflowDefinitionYamlBlocksItem.Extraction
| Skyvern.WorkflowDefinitionYamlBlocksItem.FileDownload
| Skyvern.WorkflowDefinitionYamlBlocksItem.FileUpload
@@ -19,9 +20,11 @@ export type WorkflowDefinitionYamlBlocksItem =
| Skyvern.WorkflowDefinitionYamlBlocksItem.HumanInteraction
| Skyvern.WorkflowDefinitionYamlBlocksItem.Login
| Skyvern.WorkflowDefinitionYamlBlocksItem.Navigation
+ | Skyvern.WorkflowDefinitionYamlBlocksItem.PdfFill
| Skyvern.WorkflowDefinitionYamlBlocksItem.PdfParser
| Skyvern.WorkflowDefinitionYamlBlocksItem.PrintPage
| Skyvern.WorkflowDefinitionYamlBlocksItem.SendEmail
+ | Skyvern.WorkflowDefinitionYamlBlocksItem.SplitPdf
| Skyvern.WorkflowDefinitionYamlBlocksItem.Task
| Skyvern.WorkflowDefinitionYamlBlocksItem.TaskV2
| Skyvern.WorkflowDefinitionYamlBlocksItem.TextPrompt
@@ -48,6 +51,10 @@ export namespace WorkflowDefinitionYamlBlocksItem {
block_type: "download_to_s3";
}
+ export interface EmailInbox extends Skyvern.EmailInboxBlockYaml {
+ block_type: "email_inbox";
+ }
+
export interface Extraction extends Skyvern.ExtractionBlockYaml {
block_type: "extraction";
}
@@ -96,6 +103,10 @@ export namespace WorkflowDefinitionYamlBlocksItem {
block_type: "navigation";
}
+ export interface PdfFill extends Skyvern.PdfFillBlockYaml {
+ block_type: "pdf_fill";
+ }
+
export interface PdfParser extends Skyvern.PdfParserBlockYaml {
block_type: "pdf_parser";
}
@@ -108,6 +119,10 @@ export namespace WorkflowDefinitionYamlBlocksItem {
block_type: "send_email";
}
+ export interface SplitPdf extends Skyvern.SplitPdfBlockYaml {
+ block_type: "split_pdf";
+ }
+
export interface Task extends Skyvern.TaskBlockYaml {
block_type: "task";
}
diff --git a/skyvern-ts/client/src/api/types/WorkflowRunBlock.ts b/skyvern-ts/client/src/api/types/WorkflowRunBlock.ts
index e5d25f196..d86abbf4d 100644
--- a/skyvern-ts/client/src/api/types/WorkflowRunBlock.ts
+++ b/skyvern-ts/client/src/api/types/WorkflowRunBlock.ts
@@ -38,6 +38,7 @@ export interface WorkflowRunBlock {
attachments?: string[];
subject?: string;
body?: string;
+ prompt?: string;
instructions?: string;
positive_descriptor?: string;
negative_descriptor?: string;
@@ -46,6 +47,7 @@ export interface WorkflowRunBlock {
executed_branch_result?: boolean;
executed_branch_next_block?: string;
script_run?: Skyvern.ScriptRunResponse;
+ downloaded_file_count?: number;
}
export namespace WorkflowRunBlock {
diff --git a/skyvern-ts/client/src/api/types/WorkflowRunTriggerType.ts b/skyvern-ts/client/src/api/types/WorkflowRunTriggerType.ts
index 8748ad2aa..629c24e89 100644
--- a/skyvern-ts/client/src/api/types/WorkflowRunTriggerType.ts
+++ b/skyvern-ts/client/src/api/types/WorkflowRunTriggerType.ts
@@ -4,12 +4,14 @@
* How a workflow run was initiated.
*
* - manual: User clicked "Run" in the UI
+ * - mcp: First-party MCP client request
* - api: Direct API call to the run endpoint
* - scheduled: Triggered by a cron schedule
* - webhook: Triggered by an external system via the webhook endpoint
*/
export const WorkflowRunTriggerType = {
Manual: "manual",
+ Mcp: "mcp",
Api: "api",
Scheduled: "scheduled",
Webhook: "webhook",
diff --git a/skyvern-ts/client/src/api/types/index.ts b/skyvern-ts/client/src/api/types/index.ts
index 90b552590..1af1bb314 100644
--- a/skyvern-ts/client/src/api/types/index.ts
+++ b/skyvern-ts/client/src/api/types/index.ts
@@ -27,10 +27,13 @@ export * from "./BranchCriteriaYaml.js";
export * from "./BrowserProfile.js";
export * from "./BrowserSessionResponse.js";
export * from "./BulkCancelRunsResponse.js";
+export * from "./ClearOrganizationAuthTokenResponse.js";
export * from "./ClickAction.js";
export * from "./ClickContext.js";
export * from "./CodeBlock.js";
export * from "./CodeBlockParametersItem.js";
+export * from "./CodeBlockStep.js";
+export * from "./CodeBlockStepYaml.js";
export * from "./CodeBlockYaml.js";
export * from "./ConditionalBlock.js";
export * from "./ConditionalBlockYaml.js";
@@ -44,10 +47,19 @@ export * from "./CredentialParameterYaml.js";
export * from "./CredentialResponse.js";
export * from "./CredentialTypeOutput.js";
export * from "./CredentialVaultType.js";
+export * from "./CreditCardBillingAddress.js";
export * from "./CreditCardCredentialResponse.js";
+export * from "./CustomLlm.js";
+export * from "./CustomLlmConfig.js";
+export * from "./CustomLlmListResponse.js";
+export * from "./CustomLlmProvider.js";
+export * from "./CustomLlmResponse.js";
export * from "./DeleteScheduleResponse.js";
export * from "./DownloadToS3Block.js";
export * from "./DownloadToS3BlockYaml.js";
+export * from "./EmailInboxBlock.js";
+export * from "./EmailInboxBlockParametersItem.js";
+export * from "./EmailInboxBlockYaml.js";
export * from "./Extensions.js";
export * from "./ExtractAction.js";
export * from "./ExtractionBlock.js";
@@ -106,6 +118,9 @@ export * from "./OtpType.js";
export * from "./OutputParameter.js";
export * from "./OutputParameterYaml.js";
export * from "./PasswordCredentialResponse.js";
+export * from "./PdfFillBlock.js";
+export * from "./PdfFillBlockParametersItem.js";
+export * from "./PdfFillBlockYaml.js";
export * from "./PdfFormat.js";
export * from "./PdfParserBlock.js";
export * from "./PdfParserBlockYaml.js";
@@ -121,6 +136,10 @@ export * from "./RunEngine.js";
export * from "./RunSdkActionRequestAction.js";
export * from "./RunSdkActionResponse.js";
export * from "./RunStatus.js";
+export * from "./RunTagHistoryResponse.js";
+export * from "./RunTagsBatchResponse.js";
+export * from "./RunTagsResponse.js";
+export * from "./RunType.js";
export * from "./RunWebhookReplayResponse.js";
export * from "./Script.js";
export * from "./ScriptFileCreate.js";
@@ -133,6 +152,10 @@ export * from "./SendEmailBlock.js";
export * from "./SendEmailBlockYaml.js";
export * from "./SkyvernForgeSdkSchemasCredentialsCredentialType.js";
export * from "./SkyvernSchemasCredentialTypeCredentialType.js";
+export * from "./SplitPdfBlock.js";
+export * from "./SplitPdfBlockParametersItem.js";
+export * from "./SplitPdfBlockYaml.js";
+export * from "./TagApplyRequest.js";
export * from "./TagDeleteInput.js";
export * from "./TagHistoryItem.js";
export * from "./TagHistoryResponse.js";
@@ -142,6 +165,9 @@ export * from "./TagKey.js";
export * from "./TagKeyDeleteResponse.js";
export * from "./TagResponse.js";
export * from "./TagsResponse.js";
+export * from "./TagValue.js";
+export * from "./TagValueDeleteResponse.js";
+export * from "./TagValueRenameResponse.js";
export * from "./TaskBlock.js";
export * from "./TaskBlockParametersItem.js";
export * from "./TaskBlockYaml.js";
diff --git a/skyvern-ts/client/src/version.ts b/skyvern-ts/client/src/version.ts
index 7ef1f0ee1..6836c5fc2 100644
--- a/skyvern-ts/client/src/version.ts
+++ b/skyvern-ts/client/src/version.ts
@@ -1 +1 @@
-export const SDK_VERSION = "1.0.45";
+export const SDK_VERSION = "1.0.47";
diff --git a/skyvern-ts/client/tests/wire/main.test.ts b/skyvern-ts/client/tests/wire/main.test.ts
index 1dcac2a57..53e3f8ec6 100644
--- a/skyvern-ts/client/tests/wire/main.test.ts
+++ b/skyvern-ts/client/tests/wire/main.test.ts
@@ -681,7 +681,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: { key: "value" },
status: "published",
max_screenshot_scrolls: 1,
@@ -692,6 +694,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -700,6 +703,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -764,7 +768,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: {
key: "value",
},
@@ -781,6 +787,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -789,6 +796,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -857,7 +865,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: { key: "value" },
status: "published",
max_screenshot_scrolls: 1,
@@ -868,6 +878,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -876,6 +887,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -940,7 +952,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: {
key: "value",
},
@@ -957,6 +971,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -965,6 +980,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -1041,7 +1057,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: { key: "value" },
status: "published",
max_screenshot_scrolls: 1,
@@ -1052,6 +1070,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -1060,6 +1079,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -1121,7 +1141,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: {
key: "value",
},
@@ -1138,6 +1160,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -1146,6 +1169,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -1532,140 +1556,813 @@ describe("SkyvernClient", () => {
}).rejects.toThrow(Skyvern.UnprocessableEntityError);
});
+ test("get_run_tags (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = {
+ workflow_run_id: "workflow_run_id",
+ tags: [{ key: "key", value: "value", source: "source", set_at: "2024-01-15T09:30:00Z", set_by: "set_by" }],
+ };
+ server
+ .mockEndpoint()
+ .get("/v1/runs/wr_123/tags")
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.getRunTags("wr_123");
+ expect(response).toEqual({
+ workflow_run_id: "workflow_run_id",
+ tags: [
+ {
+ key: "key",
+ value: "value",
+ source: "source",
+ set_at: "2024-01-15T09:30:00Z",
+ set_by: "set_by",
+ },
+ ],
+ });
+ });
+
+ test("get_run_tags (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .get("/v1/runs/workflow_run_id/tags")
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.getRunTags("workflow_run_id");
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("get_run_tags (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .get("/v1/runs/workflow_run_id/tags")
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.getRunTags("workflow_run_id");
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("apply_run_tags (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = {};
+ const rawResponseBody = {
+ workflow_run_id: "workflow_run_id",
+ tags: [{ key: "key", value: "value", source: "source", set_at: "2024-01-15T09:30:00Z", set_by: "set_by" }],
+ };
+ server
+ .mockEndpoint()
+ .post("/v1/runs/wr_123/tags")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.applyRunTags("wr_123", {});
+ expect(response).toEqual({
+ workflow_run_id: "workflow_run_id",
+ tags: [
+ {
+ key: "key",
+ value: "value",
+ source: "source",
+ set_at: "2024-01-15T09:30:00Z",
+ set_by: "set_by",
+ },
+ ],
+ });
+ });
+
+ test("apply_run_tags (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = {};
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .post("/v1/runs/workflow_run_id/tags")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.applyRunTags("workflow_run_id", {});
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("apply_run_tags (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = {};
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .post("/v1/runs/workflow_run_id/tags")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.applyRunTags("workflow_run_id", {});
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("delete_run_tag (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = {
+ workflow_run_id: "workflow_run_id",
+ tags: [{ key: "key", value: "value", source: "source", set_at: "2024-01-15T09:30:00Z", set_by: "set_by" }],
+ };
+ server
+ .mockEndpoint()
+ .delete("/v1/runs/wr_123/tags/env")
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.deleteRunTag("wr_123", "env");
+ expect(response).toEqual({
+ workflow_run_id: "workflow_run_id",
+ tags: [
+ {
+ key: "key",
+ value: "value",
+ source: "source",
+ set_at: "2024-01-15T09:30:00Z",
+ set_by: "set_by",
+ },
+ ],
+ });
+ });
+
+ test("delete_run_tag (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .delete("/v1/runs/workflow_run_id/tags/key")
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.deleteRunTag("workflow_run_id", "key");
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("delete_run_tag (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .delete("/v1/runs/workflow_run_id/tags/key")
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.deleteRunTag("workflow_run_id", "key");
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("get_run_tag_history (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = {
+ workflow_run_id: "workflow_run_id",
+ events: [
+ {
+ tag_event_id: "tag_event_id",
+ key: "key",
+ value: "value",
+ event_type: "event_type",
+ source: "source",
+ set_at: "2024-01-15T09:30:00Z",
+ set_by: "set_by",
+ superseded_at: "2024-01-15T09:30:00Z",
+ },
+ ],
+ };
+ server
+ .mockEndpoint()
+ .get("/v1/runs/wr_123/tags/history")
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.getRunTagHistory("wr_123", {
+ limit: 1,
+ since: "2024-01-15T09:30:00Z",
+ key: "key",
+ });
+ expect(response).toEqual({
+ workflow_run_id: "workflow_run_id",
+ events: [
+ {
+ tag_event_id: "tag_event_id",
+ key: "key",
+ value: "value",
+ event_type: "event_type",
+ source: "source",
+ set_at: "2024-01-15T09:30:00Z",
+ set_by: "set_by",
+ superseded_at: "2024-01-15T09:30:00Z",
+ },
+ ],
+ });
+ });
+
+ test("get_run_tag_history (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .get("/v1/runs/workflow_run_id/tags/history")
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.getRunTagHistory("workflow_run_id");
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("get_run_tag_history (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .get("/v1/runs/workflow_run_id/tags/history")
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.getRunTagHistory("workflow_run_id");
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
test("list_tag_keys (1)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
- const rawResponseBody = [{ key: "key", description: "description", workflow_count: 1 }];
- server.mockEndpoint().get("/v1/tag-keys").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
+ const rawResponseBody = [{ key: "key", description: "description", workflow_count: 1 }];
+ server.mockEndpoint().get("/v1/tag-keys").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
+
+ const response = await client.listTagKeys();
+ expect(response).toEqual([
+ {
+ key: "key",
+ description: "description",
+ workflow_count: 1,
+ },
+ ]);
+ });
+
+ test("list_tag_keys (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server.mockEndpoint().get("/v1/tag-keys").respondWith().statusCode(422).jsonBody(rawResponseBody).build();
+
+ await expect(async () => {
+ return await client.listTagKeys();
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("delete_tag_key (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = {
+ key: "key",
+ removed_from_workflow_count: 1,
+ removed_from_run_count: 1,
+ removed_count: 1,
+ };
+ server
+ .mockEndpoint()
+ .delete("/v1/tag-keys/env")
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.deleteTagKey("env");
+ expect(response).toEqual({
+ key: "key",
+ removed_from_workflow_count: 1,
+ removed_from_run_count: 1,
+ removed_count: 1,
+ });
+ });
+
+ test("delete_tag_key (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .delete("/v1/tag-keys/key")
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.deleteTagKey("key");
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("delete_tag_key (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .delete("/v1/tag-keys/key")
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
- const response = await client.listTagKeys();
+ await expect(async () => {
+ return await client.deleteTagKey("key");
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("update_tag_key (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = {};
+ const rawResponseBody = { key: "key", description: "description", workflow_count: 1 };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-keys/key")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.updateTagKey("key");
+ expect(response).toEqual({
+ key: "key",
+ description: "description",
+ workflow_count: 1,
+ });
+ });
+
+ test("update_tag_key (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = {};
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-keys/key")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.updateTagKey("key");
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("update_tag_key (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = {};
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-keys/key")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.updateTagKey("key");
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("list_tag_values (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = [{ key: "key", value: "value", color: "color", workflow_count: 1 }];
+ server.mockEndpoint().get("/v1/tag-values").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
+
+ const response = await client.listTagValues({
+ key: "key",
+ });
expect(response).toEqual([
{
key: "key",
- description: "description",
+ value: "value",
+ color: "color",
workflow_count: 1,
},
]);
});
- test("list_tag_keys (2)", async () => {
+ test("list_tag_values (2)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawResponseBody = { key: "value" };
- server.mockEndpoint().get("/v1/tag-keys").respondWith().statusCode(422).jsonBody(rawResponseBody).build();
+ server.mockEndpoint().get("/v1/tag-values").respondWith().statusCode(422).jsonBody(rawResponseBody).build();
await expect(async () => {
- return await client.listTagKeys();
+ return await client.listTagValues();
}).rejects.toThrow(Skyvern.UnprocessableEntityError);
});
- test("delete_tag_key (1)", async () => {
+ test("delete_tag_value (1)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
-
- const rawResponseBody = { key: "key", removed_from_workflow_count: 1 };
+ const rawRequestBody = { value: "value" };
+ const rawResponseBody = {
+ key: "key",
+ value: "value",
+ removed_from_workflow_count: 1,
+ removed_from_run_count: 1,
+ removed_count: 1,
+ };
server
.mockEndpoint()
- .delete("/v1/tag-keys/env")
+ .delete("/v1/tag-values/env")
+ .jsonBody(rawRequestBody)
.respondWith()
.statusCode(200)
.jsonBody(rawResponseBody)
.build();
- const response = await client.deleteTagKey("env");
+ const response = await client.deleteTagValue("env", {
+ value: "value",
+ });
expect(response).toEqual({
key: "key",
+ value: "value",
removed_from_workflow_count: 1,
+ removed_from_run_count: 1,
+ removed_count: 1,
});
});
- test("delete_tag_key (2)", async () => {
+ test("delete_tag_value (2)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value" };
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .delete("/v1/tag-values/key")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.deleteTagValue("key", {
+ value: "value",
+ });
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+ test("delete_tag_value (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value" };
const rawResponseBody = { key: "value" };
server
.mockEndpoint()
- .delete("/v1/tag-keys/key")
+ .delete("/v1/tag-values/key")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.deleteTagValue("key", {
+ value: "value",
+ });
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("update_tag_value (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value", color: "color" };
+ const rawResponseBody = { key: "key", value: "value", color: "color", workflow_count: 1 };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-values/env")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.updateTagValue("env", {
+ value: "value",
+ color: "color",
+ });
+ expect(response).toEqual({
+ key: "key",
+ value: "value",
+ color: "color",
+ workflow_count: 1,
+ });
+ });
+
+ test("update_tag_value (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value", color: "color" };
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-values/key")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.updateTagValue("key", {
+ value: "value",
+ color: "color",
+ });
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("update_tag_value (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value", color: "color" };
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-values/key")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.updateTagValue("key", {
+ value: "value",
+ color: "color",
+ });
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("rename_tag_value (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value", new_value: "new_value" };
+ const rawResponseBody = { key: "key", value: "value", color: "color", renamed_workflow_count: 1 };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-values/env/rename")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.renameTagValue("env", {
+ value: "value",
+ new_value: "new_value",
+ });
+ expect(response).toEqual({
+ key: "key",
+ value: "value",
+ color: "color",
+ renamed_workflow_count: 1,
+ });
+ });
+
+ test("rename_tag_value (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value", new_value: "new_value" };
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-values/key/rename")
+ .jsonBody(rawRequestBody)
.respondWith()
.statusCode(404)
.jsonBody(rawResponseBody)
.build();
await expect(async () => {
- return await client.deleteTagKey("key");
- }).rejects.toThrow(Skyvern.NotFoundError);
+ return await client.renameTagValue("key", {
+ value: "value",
+ new_value: "new_value",
+ });
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("rename_tag_value (3)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value", new_value: "new_value" };
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-values/key/rename")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(409)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.renameTagValue("key", {
+ value: "value",
+ new_value: "new_value",
+ });
+ }).rejects.toThrow(Skyvern.ConflictError);
+ });
+
+ test("rename_tag_value (4)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { value: "value", new_value: "new_value" };
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .patch("/v1/tag-values/key/rename")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.renameTagValue("key", {
+ value: "value",
+ new_value: "new_value",
+ });
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("batch_get_workflow_tags (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { workflow_tags: { key: [{ value: "value" }] } };
+ server.mockEndpoint().get("/v1/workflow-tags").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
+
+ const response = await client.batchGetWorkflowTags({
+ workflow_permanent_ids: "workflow_permanent_ids",
+ });
+ expect(response).toEqual({
+ workflow_tags: {
+ key: [
+ {
+ value: "value",
+ },
+ ],
+ },
+ });
+ });
+
+ test("batch_get_workflow_tags (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server.mockEndpoint().get("/v1/workflow-tags").respondWith().statusCode(400).jsonBody(rawResponseBody).build();
+
+ await expect(async () => {
+ return await client.batchGetWorkflowTags();
+ }).rejects.toThrow(Skyvern.BadRequestError);
});
- test("delete_tag_key (3)", async () => {
+ test("batch_get_workflow_tags (3)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawResponseBody = { key: "value" };
- server
- .mockEndpoint()
- .delete("/v1/tag-keys/key")
- .respondWith()
- .statusCode(422)
- .jsonBody(rawResponseBody)
- .build();
+ server.mockEndpoint().get("/v1/workflow-tags").respondWith().statusCode(422).jsonBody(rawResponseBody).build();
await expect(async () => {
- return await client.deleteTagKey("key");
+ return await client.batchGetWorkflowTags();
}).rejects.toThrow(Skyvern.UnprocessableEntityError);
});
- test("update_tag_key (1)", async () => {
+ test("batch_get_workflow_tags_post (1)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawRequestBody = {};
- const rawResponseBody = { key: "key", description: "description", workflow_count: 1 };
+ const rawResponseBody = { workflow_tags: { key: [{ value: "value" }] } };
server
.mockEndpoint()
- .patch("/v1/tag-keys/key")
+ .post("/v1/workflow-tags")
.jsonBody(rawRequestBody)
.respondWith()
.statusCode(200)
.jsonBody(rawResponseBody)
.build();
- const response = await client.updateTagKey("key");
+ const response = await client.batchGetWorkflowTagsPost();
expect(response).toEqual({
- key: "key",
- description: "description",
- workflow_count: 1,
+ workflow_tags: {
+ key: [
+ {
+ value: "value",
+ },
+ ],
+ },
});
});
- test("update_tag_key (2)", async () => {
+ test("batch_get_workflow_tags_post (2)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawRequestBody = {};
const rawResponseBody = { key: "value" };
server
.mockEndpoint()
- .patch("/v1/tag-keys/key")
+ .post("/v1/workflow-tags")
.jsonBody(rawRequestBody)
.respondWith()
- .statusCode(404)
+ .statusCode(400)
.jsonBody(rawResponseBody)
.build();
await expect(async () => {
- return await client.updateTagKey("key");
- }).rejects.toThrow(Skyvern.NotFoundError);
+ return await client.batchGetWorkflowTagsPost();
+ }).rejects.toThrow(Skyvern.BadRequestError);
});
- test("update_tag_key (3)", async () => {
+ test("batch_get_workflow_tags_post (3)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawRequestBody = {};
const rawResponseBody = { key: "value" };
server
.mockEndpoint()
- .patch("/v1/tag-keys/key")
+ .post("/v1/workflow-tags")
.jsonBody(rawRequestBody)
.respondWith()
.statusCode(422)
@@ -1673,22 +2370,22 @@ describe("SkyvernClient", () => {
.build();
await expect(async () => {
- return await client.updateTagKey("key");
+ return await client.batchGetWorkflowTagsPost();
}).rejects.toThrow(Skyvern.UnprocessableEntityError);
});
- test("batch_get_workflow_tags (1)", async () => {
+ test("batch_get_run_tags (1)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
- const rawResponseBody = { workflow_tags: { key: [{ value: "value" }] } };
- server.mockEndpoint().get("/v1/workflow-tags").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
+ const rawResponseBody = { run_tags: { key: [{ value: "value" }] } };
+ server.mockEndpoint().get("/v1/run-tags").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
- const response = await client.batchGetWorkflowTags({
- workflow_permanent_ids: "workflow_permanent_ids",
+ const response = await client.batchGetRunTags({
+ workflow_run_ids: "workflow_run_ids",
});
expect(response).toEqual({
- workflow_tags: {
+ run_tags: {
key: [
{
value: "value",
@@ -1698,47 +2395,47 @@ describe("SkyvernClient", () => {
});
});
- test("batch_get_workflow_tags (2)", async () => {
+ test("batch_get_run_tags (2)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawResponseBody = { key: "value" };
- server.mockEndpoint().get("/v1/workflow-tags").respondWith().statusCode(400).jsonBody(rawResponseBody).build();
+ server.mockEndpoint().get("/v1/run-tags").respondWith().statusCode(400).jsonBody(rawResponseBody).build();
await expect(async () => {
- return await client.batchGetWorkflowTags();
+ return await client.batchGetRunTags();
}).rejects.toThrow(Skyvern.BadRequestError);
});
- test("batch_get_workflow_tags (3)", async () => {
+ test("batch_get_run_tags (3)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawResponseBody = { key: "value" };
- server.mockEndpoint().get("/v1/workflow-tags").respondWith().statusCode(422).jsonBody(rawResponseBody).build();
+ server.mockEndpoint().get("/v1/run-tags").respondWith().statusCode(422).jsonBody(rawResponseBody).build();
await expect(async () => {
- return await client.batchGetWorkflowTags();
+ return await client.batchGetRunTags();
}).rejects.toThrow(Skyvern.UnprocessableEntityError);
});
- test("batch_get_workflow_tags_post (1)", async () => {
+ test("batch_get_run_tags_post (1)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawRequestBody = {};
- const rawResponseBody = { workflow_tags: { key: [{ value: "value" }] } };
+ const rawResponseBody = { run_tags: { key: [{ value: "value" }] } };
server
.mockEndpoint()
- .post("/v1/workflow-tags")
+ .post("/v1/run-tags")
.jsonBody(rawRequestBody)
.respondWith()
.statusCode(200)
.jsonBody(rawResponseBody)
.build();
- const response = await client.batchGetWorkflowTagsPost();
+ const response = await client.batchGetRunTagsPost();
expect(response).toEqual({
- workflow_tags: {
+ run_tags: {
key: [
{
value: "value",
@@ -1748,14 +2445,14 @@ describe("SkyvernClient", () => {
});
});
- test("batch_get_workflow_tags_post (2)", async () => {
+ test("batch_get_run_tags_post (2)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawRequestBody = {};
const rawResponseBody = { key: "value" };
server
.mockEndpoint()
- .post("/v1/workflow-tags")
+ .post("/v1/run-tags")
.jsonBody(rawRequestBody)
.respondWith()
.statusCode(400)
@@ -1763,18 +2460,18 @@ describe("SkyvernClient", () => {
.build();
await expect(async () => {
- return await client.batchGetWorkflowTagsPost();
+ return await client.batchGetRunTagsPost();
}).rejects.toThrow(Skyvern.BadRequestError);
});
- test("batch_get_workflow_tags_post (3)", async () => {
+ test("batch_get_run_tags_post (3)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
const rawRequestBody = {};
const rawResponseBody = { key: "value" };
server
.mockEndpoint()
- .post("/v1/workflow-tags")
+ .post("/v1/run-tags")
.jsonBody(rawRequestBody)
.respondWith()
.statusCode(422)
@@ -1782,7 +2479,7 @@ describe("SkyvernClient", () => {
.build();
await expect(async () => {
- return await client.batchGetWorkflowTagsPost();
+ return await client.batchGetRunTagsPost();
}).rejects.toThrow(Skyvern.UnprocessableEntityError);
});
@@ -1969,6 +2666,7 @@ describe("SkyvernClient", () => {
attachments: ["attachments"],
subject: "subject",
body: "body",
+ prompt: "prompt",
instructions: "instructions",
positive_descriptor: "positive_descriptor",
negative_descriptor: "negative_descriptor",
@@ -1977,6 +2675,7 @@ describe("SkyvernClient", () => {
executed_branch_result: true,
executed_branch_next_block: "executed_branch_next_block",
script_run: {},
+ downloaded_file_count: 1,
},
thought: {
thought_id: "thought_id",
@@ -2064,6 +2763,7 @@ describe("SkyvernClient", () => {
attachments: ["attachments"],
subject: "subject",
body: "body",
+ prompt: "prompt",
instructions: "instructions",
positive_descriptor: "positive_descriptor",
negative_descriptor: "negative_descriptor",
@@ -2072,6 +2772,7 @@ describe("SkyvernClient", () => {
executed_branch_result: true,
executed_branch_next_block: "executed_branch_next_block",
script_run: {},
+ downloaded_file_count: 1,
},
thought: {
thought_id: "thought_id",
@@ -2189,6 +2890,7 @@ describe("SkyvernClient", () => {
workflow_permanent_id: "workflow_permanent_id",
workflow_deleted: true,
script_run: true,
+ trigger_type: "manual",
},
];
server.mockEndpoint().get("/v1/runs").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
@@ -2211,6 +2913,7 @@ describe("SkyvernClient", () => {
workflow_permanent_id: "workflow_permanent_id",
workflow_deleted: true,
script_run: true,
+ trigger_type: "manual",
},
]);
});
@@ -2261,6 +2964,7 @@ describe("SkyvernClient", () => {
page_size: 1,
include_deleted: true,
search_key: "search_key",
+ managed: true,
});
expect(response).toEqual([
{
@@ -2945,6 +3649,24 @@ describe("SkyvernClient", () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .post("/v1/browser_sessions/browser_session_id/close")
+ .respondWith()
+ .statusCode(404)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.closeBrowserSession("browser_session_id");
+ }).rejects.toThrow(Skyvern.NotFoundError);
+ });
+
+ test("close_browser_session (4)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
const rawResponseBody = { key: "value" };
server
.mockEndpoint()
@@ -3390,6 +4112,8 @@ describe("SkyvernClient", () => {
user_context: "user_context",
save_browser_session_intent: true,
folder_id: "folder_id",
+ proxy_location: "RESIDENTIAL",
+ proxy_session_id: "proxy_session_id",
},
];
server.mockEndpoint().get("/v1/credentials").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
@@ -3417,6 +4141,8 @@ describe("SkyvernClient", () => {
user_context: "user_context",
save_browser_session_intent: true,
folder_id: "folder_id",
+ proxy_location: "RESIDENTIAL",
+ proxy_session_id: "proxy_session_id",
},
]);
});
@@ -3456,6 +4182,8 @@ describe("SkyvernClient", () => {
user_context: "user_context",
save_browser_session_intent: true,
folder_id: "folder_id",
+ proxy_location: "RESIDENTIAL",
+ proxy_session_id: "proxy_session_id",
};
server
.mockEndpoint()
@@ -3489,6 +4217,8 @@ describe("SkyvernClient", () => {
user_context: "user_context",
save_browser_session_intent: true,
folder_id: "folder_id",
+ proxy_location: "RESIDENTIAL",
+ proxy_session_id: "proxy_session_id",
});
});
@@ -3545,6 +4275,8 @@ describe("SkyvernClient", () => {
user_context: "user_context",
save_browser_session_intent: true,
folder_id: "folder_id",
+ proxy_location: "RESIDENTIAL",
+ proxy_session_id: "proxy_session_id",
};
server
.mockEndpoint()
@@ -3578,6 +4310,8 @@ describe("SkyvernClient", () => {
user_context: "user_context",
save_browser_session_intent: true,
folder_id: "folder_id",
+ proxy_location: "RESIDENTIAL",
+ proxy_session_id: "proxy_session_id",
});
});
@@ -3658,6 +4392,8 @@ describe("SkyvernClient", () => {
user_context: "user_context",
save_browser_session_intent: true,
folder_id: "folder_id",
+ proxy_location: "RESIDENTIAL",
+ proxy_session_id: "proxy_session_id",
};
server
.mockEndpoint()
@@ -3683,6 +4419,8 @@ describe("SkyvernClient", () => {
user_context: "user_context",
save_browser_session_intent: true,
folder_id: "folder_id",
+ proxy_location: "RESIDENTIAL",
+ proxy_session_id: "proxy_session_id",
});
});
@@ -3704,6 +4442,278 @@ describe("SkyvernClient", () => {
}).rejects.toThrow(Skyvern.UnprocessableEntityError);
});
+ test("list_custom_llms (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = {
+ custom_llms: [
+ {
+ id: "id",
+ organization_id: "organization_id",
+ config: { display_name: "display_name", provider: "openai_compatible", model_name: "model_name" },
+ created_at: "created_at",
+ modified_at: "modified_at",
+ valid: true,
+ },
+ ],
+ };
+ server.mockEndpoint().get("/v1/custom-llms").respondWith().statusCode(200).jsonBody(rawResponseBody).build();
+
+ const response = await client.listCustomLlms();
+ expect(response).toEqual({
+ custom_llms: [
+ {
+ id: "id",
+ organization_id: "organization_id",
+ config: {
+ display_name: "display_name",
+ provider: "openai_compatible",
+ model_name: "model_name",
+ },
+ created_at: "created_at",
+ modified_at: "modified_at",
+ valid: true,
+ },
+ ],
+ });
+ });
+
+ test("list_custom_llms (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server.mockEndpoint().get("/v1/custom-llms").respondWith().statusCode(422).jsonBody(rawResponseBody).build();
+
+ await expect(async () => {
+ return await client.listCustomLlms();
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("create_custom_llm (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = {
+ config: { display_name: "display_name", provider: "openai_compatible", model_name: "model_name" },
+ };
+ const rawResponseBody = {
+ custom_llm: {
+ id: "id",
+ organization_id: "organization_id",
+ config: {
+ display_name: "display_name",
+ provider: "openai_compatible",
+ model_name: "model_name",
+ api_base: "api_base",
+ api_key: "api_key",
+ api_version: "api_version",
+ supports_vision: true,
+ add_assistant_prefix: true,
+ max_completion_tokens: 1,
+ temperature: 1.1,
+ reasoning_effort: "reasoning_effort",
+ },
+ created_at: "created_at",
+ modified_at: "modified_at",
+ valid: true,
+ },
+ };
+ server
+ .mockEndpoint()
+ .post("/v1/custom-llms")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.createCustomLlm({
+ config: {
+ display_name: "display_name",
+ provider: "openai_compatible",
+ model_name: "model_name",
+ },
+ });
+ expect(response).toEqual({
+ custom_llm: {
+ id: "id",
+ organization_id: "organization_id",
+ config: {
+ display_name: "display_name",
+ provider: "openai_compatible",
+ model_name: "model_name",
+ api_base: "api_base",
+ api_key: "api_key",
+ api_version: "api_version",
+ supports_vision: true,
+ add_assistant_prefix: true,
+ max_completion_tokens: 1,
+ temperature: 1.1,
+ reasoning_effort: "reasoning_effort",
+ },
+ created_at: "created_at",
+ modified_at: "modified_at",
+ valid: true,
+ },
+ });
+ });
+
+ test("create_custom_llm (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { config: { display_name: "x", provider: "openai_compatible", model_name: "x" } };
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .post("/v1/custom-llms")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.createCustomLlm({
+ config: {
+ display_name: "x",
+ provider: "openai_compatible",
+ model_name: "x",
+ },
+ });
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("update_custom_llm (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = {
+ config: { display_name: "display_name", provider: "openai_compatible", model_name: "model_name" },
+ };
+ const rawResponseBody = {
+ custom_llm: {
+ id: "id",
+ organization_id: "organization_id",
+ config: {
+ display_name: "display_name",
+ provider: "openai_compatible",
+ model_name: "model_name",
+ api_base: "api_base",
+ api_key: "api_key",
+ api_version: "api_version",
+ supports_vision: true,
+ add_assistant_prefix: true,
+ max_completion_tokens: 1,
+ temperature: 1.1,
+ reasoning_effort: "reasoning_effort",
+ },
+ created_at: "created_at",
+ modified_at: "modified_at",
+ valid: true,
+ },
+ };
+ server
+ .mockEndpoint()
+ .put("/v1/custom-llms/custom_llm_id")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.updateCustomLlm("custom_llm_id", {
+ config: {
+ display_name: "display_name",
+ provider: "openai_compatible",
+ model_name: "model_name",
+ },
+ });
+ expect(response).toEqual({
+ custom_llm: {
+ id: "id",
+ organization_id: "organization_id",
+ config: {
+ display_name: "display_name",
+ provider: "openai_compatible",
+ model_name: "model_name",
+ api_base: "api_base",
+ api_key: "api_key",
+ api_version: "api_version",
+ supports_vision: true,
+ add_assistant_prefix: true,
+ max_completion_tokens: 1,
+ temperature: 1.1,
+ reasoning_effort: "reasoning_effort",
+ },
+ created_at: "created_at",
+ modified_at: "modified_at",
+ valid: true,
+ },
+ });
+ });
+
+ test("update_custom_llm (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+ const rawRequestBody = { config: { display_name: "x", provider: "openai_compatible", model_name: "x" } };
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .put("/v1/custom-llms/custom_llm_id")
+ .jsonBody(rawRequestBody)
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.updateCustomLlm("custom_llm_id", {
+ config: {
+ display_name: "x",
+ provider: "openai_compatible",
+ model_name: "x",
+ },
+ });
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
+ test("delete_custom_llm (1)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { success: true };
+ server
+ .mockEndpoint()
+ .delete("/v1/custom-llms/custom_llm_id")
+ .respondWith()
+ .statusCode(200)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ const response = await client.deleteCustomLlm("custom_llm_id");
+ expect(response).toEqual({
+ success: true,
+ });
+ });
+
+ test("delete_custom_llm (2)", async () => {
+ const server = mockServerPool.createServer();
+ const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
+
+ const rawResponseBody = { key: "value" };
+ server
+ .mockEndpoint()
+ .delete("/v1/custom-llms/custom_llm_id")
+ .respondWith()
+ .statusCode(422)
+ .jsonBody(rawResponseBody)
+ .build();
+
+ await expect(async () => {
+ return await client.deleteCustomLlm("custom_llm_id");
+ }).rejects.toThrow(Skyvern.UnprocessableEntityError);
+ });
+
test("login (1)", async () => {
const server = mockServerPool.createServer();
const client = new SkyvernClient({ apiKey: "test", environment: server.baseUrl });
@@ -4404,7 +5414,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: { key: "value" },
status: "published",
max_screenshot_scrolls: 1,
@@ -4415,6 +5427,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -4423,6 +5436,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -4484,7 +5498,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: {
key: "value",
},
@@ -4501,6 +5517,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -4509,6 +5526,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -4657,7 +5675,7 @@ describe("SkyvernClient", () => {
.jsonBody(rawResponseBody)
.build();
- const response = await client.applyWorkflowTags("wpid_123");
+ const response = await client.applyWorkflowTags("wpid_123", {});
expect(response).toEqual({
workflow_permanent_id: "workflow_permanent_id",
tags: [
@@ -4687,7 +5705,7 @@ describe("SkyvernClient", () => {
.build();
await expect(async () => {
- return await client.applyWorkflowTags("workflow_permanent_id");
+ return await client.applyWorkflowTags("workflow_permanent_id", {});
}).rejects.toThrow(Skyvern.NotFoundError);
});
@@ -4706,7 +5724,7 @@ describe("SkyvernClient", () => {
.build();
await expect(async () => {
- return await client.applyWorkflowTags("workflow_permanent_id");
+ return await client.applyWorkflowTags("workflow_permanent_id", {});
}).rejects.toThrow(Skyvern.UnprocessableEntityError);
});
@@ -5259,6 +6277,8 @@ describe("SkyvernClient", () => {
page_size: 1,
search_key: "search_key",
error_code: "error_code",
+ created_at_start: "2024-01-15T09:30:00Z",
+ created_at_end: "2024-01-15T09:30:00Z",
});
expect(response).toEqual([
{
@@ -5384,7 +6404,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: { key: "value" },
status: "published",
max_screenshot_scrolls: 1,
@@ -5395,6 +6417,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -5403,6 +6426,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -5466,7 +6490,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: {
key: "value",
},
@@ -5483,6 +6509,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -5491,6 +6518,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -5565,7 +6593,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: { key: "value" },
status: "published",
max_screenshot_scrolls: 1,
@@ -5576,6 +6606,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -5584,6 +6615,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
@@ -5646,7 +6678,9 @@ describe("SkyvernClient", () => {
totp_verification_url: "totp_verification_url",
totp_identifier: "totp_identifier",
persist_browser_session: true,
+ pin_saved_session_ip: true,
browser_profile_id: "browser_profile_id",
+ browser_profile_key: "browser_profile_key",
model: {
key: "value",
},
@@ -5663,6 +6697,7 @@ describe("SkyvernClient", () => {
ai_fallback: true,
cache_key: "cache_key",
adaptive_caching: true,
+ enable_self_healing: true,
code_version: 1,
generate_script_on_terminal: true,
run_sequentially: true,
@@ -5671,6 +6706,7 @@ describe("SkyvernClient", () => {
import_error: "import_error",
created_by: "created_by",
edited_by: "edited_by",
+ copilot_authored: true,
created_at: "2024-01-15T09:30:00Z",
modified_at: "2024-01-15T09:30:00Z",
deleted_at: "2024-01-15T09:30:00Z",
diff --git a/skyvern/client/__init__.py b/skyvern/client/__init__.py
index add7d0b01..536e4d6ff 100644
--- a/skyvern/client/__init__.py
+++ b/skyvern/client/__init__.py
@@ -54,6 +54,7 @@ if typing.TYPE_CHECKING:
BrowserProfileProxyLocation,
BrowserSessionResponse,
BulkCancelRunsResponse,
+ ClearOrganizationAuthTokenResponse,
ClickAction,
ClickActionData,
ClickContext,
@@ -70,6 +71,8 @@ if typing.TYPE_CHECKING:
CodeBlockParametersItem_Onepassword,
CodeBlockParametersItem_Output,
CodeBlockParametersItem_Workflow,
+ CodeBlockStep,
+ CodeBlockStepYaml,
CodeBlockYaml,
ConditionalBlock,
ConditionalBlockYaml,
@@ -98,12 +101,35 @@ if typing.TYPE_CHECKING:
CredentialParameterYaml,
CredentialResponse,
CredentialResponseCredential,
+ CredentialResponseProxyLocation,
CredentialTypeOutput,
CredentialVaultType,
+ CreditCardBillingAddress,
CreditCardCredentialResponse,
+ CustomLlm,
+ CustomLlmConfig,
+ CustomLlmListResponse,
+ CustomLlmProvider,
+ CustomLlmResponse,
DeleteScheduleResponse,
DownloadToS3Block,
DownloadToS3BlockYaml,
+ EmailInboxBlock,
+ EmailInboxBlockEmailClient,
+ EmailInboxBlockParametersItem,
+ EmailInboxBlockParametersItem_AwsSecret,
+ EmailInboxBlockParametersItem_AzureSecret,
+ EmailInboxBlockParametersItem_AzureVaultCredential,
+ EmailInboxBlockParametersItem_BitwardenCreditCardData,
+ EmailInboxBlockParametersItem_BitwardenLoginCredential,
+ EmailInboxBlockParametersItem_BitwardenSensitiveInformation,
+ EmailInboxBlockParametersItem_Context,
+ EmailInboxBlockParametersItem_Credential,
+ EmailInboxBlockParametersItem_Onepassword,
+ EmailInboxBlockParametersItem_Output,
+ EmailInboxBlockParametersItem_Workflow,
+ EmailInboxBlockYaml,
+ EmailInboxBlockYamlEmailClient,
Extensions,
ExtractAction,
ExtractActionData,
@@ -156,6 +182,7 @@ if typing.TYPE_CHECKING:
ForLoopBlockLoopBlocksItem_Code,
ForLoopBlockLoopBlocksItem_Conditional,
ForLoopBlockLoopBlocksItem_DownloadToS3,
+ ForLoopBlockLoopBlocksItem_EmailInbox,
ForLoopBlockLoopBlocksItem_Extraction,
ForLoopBlockLoopBlocksItem_FileDownload,
ForLoopBlockLoopBlocksItem_FileUpload,
@@ -168,9 +195,11 @@ if typing.TYPE_CHECKING:
ForLoopBlockLoopBlocksItem_HumanInteraction,
ForLoopBlockLoopBlocksItem_Login,
ForLoopBlockLoopBlocksItem_Navigation,
+ ForLoopBlockLoopBlocksItem_PdfFill,
ForLoopBlockLoopBlocksItem_PdfParser,
ForLoopBlockLoopBlocksItem_PrintPage,
ForLoopBlockLoopBlocksItem_SendEmail,
+ ForLoopBlockLoopBlocksItem_SplitPdf,
ForLoopBlockLoopBlocksItem_Task,
ForLoopBlockLoopBlocksItem_TaskV2,
ForLoopBlockLoopBlocksItem_TextPrompt,
@@ -198,6 +227,7 @@ if typing.TYPE_CHECKING:
ForLoopBlockYamlLoopBlocksItem_Code,
ForLoopBlockYamlLoopBlocksItem_Conditional,
ForLoopBlockYamlLoopBlocksItem_DownloadToS3,
+ ForLoopBlockYamlLoopBlocksItem_EmailInbox,
ForLoopBlockYamlLoopBlocksItem_Extraction,
ForLoopBlockYamlLoopBlocksItem_FileDownload,
ForLoopBlockYamlLoopBlocksItem_FileUpload,
@@ -210,9 +240,11 @@ if typing.TYPE_CHECKING:
ForLoopBlockYamlLoopBlocksItem_HumanInteraction,
ForLoopBlockYamlLoopBlocksItem_Login,
ForLoopBlockYamlLoopBlocksItem_Navigation,
+ ForLoopBlockYamlLoopBlocksItem_PdfFill,
ForLoopBlockYamlLoopBlocksItem_PdfParser,
ForLoopBlockYamlLoopBlocksItem_PrintPage,
ForLoopBlockYamlLoopBlocksItem_SendEmail,
+ ForLoopBlockYamlLoopBlocksItem_SplitPdf,
ForLoopBlockYamlLoopBlocksItem_Task,
ForLoopBlockYamlLoopBlocksItem_TaskV2,
ForLoopBlockYamlLoopBlocksItem_TextPrompt,
@@ -335,6 +367,22 @@ if typing.TYPE_CHECKING:
OutputParameter,
OutputParameterYaml,
PasswordCredentialResponse,
+ PdfFillBlock,
+ PdfFillBlockParametersItem,
+ PdfFillBlockParametersItem_AwsSecret,
+ PdfFillBlockParametersItem_AzureSecret,
+ PdfFillBlockParametersItem_AzureVaultCredential,
+ PdfFillBlockParametersItem_BitwardenCreditCardData,
+ PdfFillBlockParametersItem_BitwardenLoginCredential,
+ PdfFillBlockParametersItem_BitwardenSensitiveInformation,
+ PdfFillBlockParametersItem_Context,
+ PdfFillBlockParametersItem_Credential,
+ PdfFillBlockParametersItem_Onepassword,
+ PdfFillBlockParametersItem_Output,
+ PdfFillBlockParametersItem_Workflow,
+ PdfFillBlockPayload,
+ PdfFillBlockYaml,
+ PdfFillBlockYamlPayload,
PdfFormat,
PdfParserBlock,
PdfParserBlockYaml,
@@ -370,6 +418,10 @@ if typing.TYPE_CHECKING:
RunSdkActionRequestAction_Validate,
RunSdkActionResponse,
RunStatus,
+ RunTagHistoryResponse,
+ RunTagsBatchResponse,
+ RunTagsResponse,
+ RunType,
RunWebhookReplayResponse,
Script,
ScriptFileCreate,
@@ -383,6 +435,21 @@ if typing.TYPE_CHECKING:
SendEmailBlockYaml,
SkyvernForgeSdkSchemasCredentialsCredentialType,
SkyvernSchemasCredentialTypeCredentialType,
+ SplitPdfBlock,
+ SplitPdfBlockParametersItem,
+ SplitPdfBlockParametersItem_AwsSecret,
+ SplitPdfBlockParametersItem_AzureSecret,
+ SplitPdfBlockParametersItem_AzureVaultCredential,
+ SplitPdfBlockParametersItem_BitwardenCreditCardData,
+ SplitPdfBlockParametersItem_BitwardenLoginCredential,
+ SplitPdfBlockParametersItem_BitwardenSensitiveInformation,
+ SplitPdfBlockParametersItem_Context,
+ SplitPdfBlockParametersItem_Credential,
+ SplitPdfBlockParametersItem_Onepassword,
+ SplitPdfBlockParametersItem_Output,
+ SplitPdfBlockParametersItem_Workflow,
+ SplitPdfBlockYaml,
+ TagApplyRequest,
TagDeleteInput,
TagHistoryItem,
TagHistoryResponse,
@@ -391,6 +458,9 @@ if typing.TYPE_CHECKING:
TagKey,
TagKeyDeleteResponse,
TagResponse,
+ TagValue,
+ TagValueDeleteResponse,
+ TagValueRenameResponse,
TagsResponse,
TaskBlock,
TaskBlockDataSchema,
@@ -500,6 +570,7 @@ if typing.TYPE_CHECKING:
WhileLoopBlockLoopBlocksItem_Code,
WhileLoopBlockLoopBlocksItem_Conditional,
WhileLoopBlockLoopBlocksItem_DownloadToS3,
+ WhileLoopBlockLoopBlocksItem_EmailInbox,
WhileLoopBlockLoopBlocksItem_Extraction,
WhileLoopBlockLoopBlocksItem_FileDownload,
WhileLoopBlockLoopBlocksItem_FileUpload,
@@ -512,9 +583,11 @@ if typing.TYPE_CHECKING:
WhileLoopBlockLoopBlocksItem_HumanInteraction,
WhileLoopBlockLoopBlocksItem_Login,
WhileLoopBlockLoopBlocksItem_Navigation,
+ WhileLoopBlockLoopBlocksItem_PdfFill,
WhileLoopBlockLoopBlocksItem_PdfParser,
WhileLoopBlockLoopBlocksItem_PrintPage,
WhileLoopBlockLoopBlocksItem_SendEmail,
+ WhileLoopBlockLoopBlocksItem_SplitPdf,
WhileLoopBlockLoopBlocksItem_Task,
WhileLoopBlockLoopBlocksItem_TaskV2,
WhileLoopBlockLoopBlocksItem_TextPrompt,
@@ -529,6 +602,7 @@ if typing.TYPE_CHECKING:
WhileLoopBlockYamlLoopBlocksItem_Code,
WhileLoopBlockYamlLoopBlocksItem_Conditional,
WhileLoopBlockYamlLoopBlocksItem_DownloadToS3,
+ WhileLoopBlockYamlLoopBlocksItem_EmailInbox,
WhileLoopBlockYamlLoopBlocksItem_Extraction,
WhileLoopBlockYamlLoopBlocksItem_FileDownload,
WhileLoopBlockYamlLoopBlocksItem_FileUpload,
@@ -541,9 +615,11 @@ if typing.TYPE_CHECKING:
WhileLoopBlockYamlLoopBlocksItem_HumanInteraction,
WhileLoopBlockYamlLoopBlocksItem_Login,
WhileLoopBlockYamlLoopBlocksItem_Navigation,
+ WhileLoopBlockYamlLoopBlocksItem_PdfFill,
WhileLoopBlockYamlLoopBlocksItem_PdfParser,
WhileLoopBlockYamlLoopBlocksItem_PrintPage,
WhileLoopBlockYamlLoopBlocksItem_SendEmail,
+ WhileLoopBlockYamlLoopBlocksItem_SplitPdf,
WhileLoopBlockYamlLoopBlocksItem_Task,
WhileLoopBlockYamlLoopBlocksItem_TaskV2,
WhileLoopBlockYamlLoopBlocksItem_TextPrompt,
@@ -561,6 +637,7 @@ if typing.TYPE_CHECKING:
WorkflowDefinitionBlocksItem_Code,
WorkflowDefinitionBlocksItem_Conditional,
WorkflowDefinitionBlocksItem_DownloadToS3,
+ WorkflowDefinitionBlocksItem_EmailInbox,
WorkflowDefinitionBlocksItem_Extraction,
WorkflowDefinitionBlocksItem_FileDownload,
WorkflowDefinitionBlocksItem_FileUpload,
@@ -573,9 +650,11 @@ if typing.TYPE_CHECKING:
WorkflowDefinitionBlocksItem_HumanInteraction,
WorkflowDefinitionBlocksItem_Login,
WorkflowDefinitionBlocksItem_Navigation,
+ WorkflowDefinitionBlocksItem_PdfFill,
WorkflowDefinitionBlocksItem_PdfParser,
WorkflowDefinitionBlocksItem_PrintPage,
WorkflowDefinitionBlocksItem_SendEmail,
+ WorkflowDefinitionBlocksItem_SplitPdf,
WorkflowDefinitionBlocksItem_Task,
WorkflowDefinitionBlocksItem_TaskV2,
WorkflowDefinitionBlocksItem_TextPrompt,
@@ -602,6 +681,7 @@ if typing.TYPE_CHECKING:
WorkflowDefinitionYamlBlocksItem_Code,
WorkflowDefinitionYamlBlocksItem_Conditional,
WorkflowDefinitionYamlBlocksItem_DownloadToS3,
+ WorkflowDefinitionYamlBlocksItem_EmailInbox,
WorkflowDefinitionYamlBlocksItem_Extraction,
WorkflowDefinitionYamlBlocksItem_FileDownload,
WorkflowDefinitionYamlBlocksItem_FileUpload,
@@ -614,9 +694,11 @@ if typing.TYPE_CHECKING:
WorkflowDefinitionYamlBlocksItem_HumanInteraction,
WorkflowDefinitionYamlBlocksItem_Login,
WorkflowDefinitionYamlBlocksItem_Navigation,
+ WorkflowDefinitionYamlBlocksItem_PdfFill,
WorkflowDefinitionYamlBlocksItem_PdfParser,
WorkflowDefinitionYamlBlocksItem_PrintPage,
WorkflowDefinitionYamlBlocksItem_SendEmail,
+ WorkflowDefinitionYamlBlocksItem_SplitPdf,
WorkflowDefinitionYamlBlocksItem_Task,
WorkflowDefinitionYamlBlocksItem_TaskV2,
WorkflowDefinitionYamlBlocksItem_TextPrompt,
@@ -743,6 +825,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"BrowserProfileProxyLocation": ".types",
"BrowserSessionResponse": ".types",
"BulkCancelRunsResponse": ".types",
+ "ClearOrganizationAuthTokenResponse": ".types",
"ClickAction": ".types",
"ClickActionData": ".types",
"ClickContext": ".types",
@@ -759,6 +842,8 @@ _dynamic_imports: typing.Dict[str, str] = {
"CodeBlockParametersItem_Onepassword": ".types",
"CodeBlockParametersItem_Output": ".types",
"CodeBlockParametersItem_Workflow": ".types",
+ "CodeBlockStep": ".types",
+ "CodeBlockStepYaml": ".types",
"CodeBlockYaml": ".types",
"ConditionalBlock": ".types",
"ConditionalBlockYaml": ".types",
@@ -788,12 +873,35 @@ _dynamic_imports: typing.Dict[str, str] = {
"CredentialParameterYaml": ".types",
"CredentialResponse": ".types",
"CredentialResponseCredential": ".types",
+ "CredentialResponseProxyLocation": ".types",
"CredentialTypeOutput": ".types",
"CredentialVaultType": ".types",
+ "CreditCardBillingAddress": ".types",
"CreditCardCredentialResponse": ".types",
+ "CustomLlm": ".types",
+ "CustomLlmConfig": ".types",
+ "CustomLlmListResponse": ".types",
+ "CustomLlmProvider": ".types",
+ "CustomLlmResponse": ".types",
"DeleteScheduleResponse": ".types",
"DownloadToS3Block": ".types",
"DownloadToS3BlockYaml": ".types",
+ "EmailInboxBlock": ".types",
+ "EmailInboxBlockEmailClient": ".types",
+ "EmailInboxBlockParametersItem": ".types",
+ "EmailInboxBlockParametersItem_AwsSecret": ".types",
+ "EmailInboxBlockParametersItem_AzureSecret": ".types",
+ "EmailInboxBlockParametersItem_AzureVaultCredential": ".types",
+ "EmailInboxBlockParametersItem_BitwardenCreditCardData": ".types",
+ "EmailInboxBlockParametersItem_BitwardenLoginCredential": ".types",
+ "EmailInboxBlockParametersItem_BitwardenSensitiveInformation": ".types",
+ "EmailInboxBlockParametersItem_Context": ".types",
+ "EmailInboxBlockParametersItem_Credential": ".types",
+ "EmailInboxBlockParametersItem_Onepassword": ".types",
+ "EmailInboxBlockParametersItem_Output": ".types",
+ "EmailInboxBlockParametersItem_Workflow": ".types",
+ "EmailInboxBlockYaml": ".types",
+ "EmailInboxBlockYamlEmailClient": ".types",
"Extensions": ".types",
"ExtractAction": ".types",
"ExtractActionData": ".types",
@@ -846,6 +954,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"ForLoopBlockLoopBlocksItem_Code": ".types",
"ForLoopBlockLoopBlocksItem_Conditional": ".types",
"ForLoopBlockLoopBlocksItem_DownloadToS3": ".types",
+ "ForLoopBlockLoopBlocksItem_EmailInbox": ".types",
"ForLoopBlockLoopBlocksItem_Extraction": ".types",
"ForLoopBlockLoopBlocksItem_FileDownload": ".types",
"ForLoopBlockLoopBlocksItem_FileUpload": ".types",
@@ -858,9 +967,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"ForLoopBlockLoopBlocksItem_HumanInteraction": ".types",
"ForLoopBlockLoopBlocksItem_Login": ".types",
"ForLoopBlockLoopBlocksItem_Navigation": ".types",
+ "ForLoopBlockLoopBlocksItem_PdfFill": ".types",
"ForLoopBlockLoopBlocksItem_PdfParser": ".types",
"ForLoopBlockLoopBlocksItem_PrintPage": ".types",
"ForLoopBlockLoopBlocksItem_SendEmail": ".types",
+ "ForLoopBlockLoopBlocksItem_SplitPdf": ".types",
"ForLoopBlockLoopBlocksItem_Task": ".types",
"ForLoopBlockLoopBlocksItem_TaskV2": ".types",
"ForLoopBlockLoopBlocksItem_TextPrompt": ".types",
@@ -888,6 +999,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"ForLoopBlockYamlLoopBlocksItem_Code": ".types",
"ForLoopBlockYamlLoopBlocksItem_Conditional": ".types",
"ForLoopBlockYamlLoopBlocksItem_DownloadToS3": ".types",
+ "ForLoopBlockYamlLoopBlocksItem_EmailInbox": ".types",
"ForLoopBlockYamlLoopBlocksItem_Extraction": ".types",
"ForLoopBlockYamlLoopBlocksItem_FileDownload": ".types",
"ForLoopBlockYamlLoopBlocksItem_FileUpload": ".types",
@@ -900,9 +1012,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"ForLoopBlockYamlLoopBlocksItem_HumanInteraction": ".types",
"ForLoopBlockYamlLoopBlocksItem_Login": ".types",
"ForLoopBlockYamlLoopBlocksItem_Navigation": ".types",
+ "ForLoopBlockYamlLoopBlocksItem_PdfFill": ".types",
"ForLoopBlockYamlLoopBlocksItem_PdfParser": ".types",
"ForLoopBlockYamlLoopBlocksItem_PrintPage": ".types",
"ForLoopBlockYamlLoopBlocksItem_SendEmail": ".types",
+ "ForLoopBlockYamlLoopBlocksItem_SplitPdf": ".types",
"ForLoopBlockYamlLoopBlocksItem_Task": ".types",
"ForLoopBlockYamlLoopBlocksItem_TaskV2": ".types",
"ForLoopBlockYamlLoopBlocksItem_TextPrompt": ".types",
@@ -1028,6 +1142,22 @@ _dynamic_imports: typing.Dict[str, str] = {
"OutputParameter": ".types",
"OutputParameterYaml": ".types",
"PasswordCredentialResponse": ".types",
+ "PdfFillBlock": ".types",
+ "PdfFillBlockParametersItem": ".types",
+ "PdfFillBlockParametersItem_AwsSecret": ".types",
+ "PdfFillBlockParametersItem_AzureSecret": ".types",
+ "PdfFillBlockParametersItem_AzureVaultCredential": ".types",
+ "PdfFillBlockParametersItem_BitwardenCreditCardData": ".types",
+ "PdfFillBlockParametersItem_BitwardenLoginCredential": ".types",
+ "PdfFillBlockParametersItem_BitwardenSensitiveInformation": ".types",
+ "PdfFillBlockParametersItem_Context": ".types",
+ "PdfFillBlockParametersItem_Credential": ".types",
+ "PdfFillBlockParametersItem_Onepassword": ".types",
+ "PdfFillBlockParametersItem_Output": ".types",
+ "PdfFillBlockParametersItem_Workflow": ".types",
+ "PdfFillBlockPayload": ".types",
+ "PdfFillBlockYaml": ".types",
+ "PdfFillBlockYamlPayload": ".types",
"PdfFormat": ".types",
"PdfParserBlock": ".types",
"PdfParserBlockYaml": ".types",
@@ -1064,6 +1194,10 @@ _dynamic_imports: typing.Dict[str, str] = {
"RunSdkActionRequestAction_Validate": ".types",
"RunSdkActionResponse": ".types",
"RunStatus": ".types",
+ "RunTagHistoryResponse": ".types",
+ "RunTagsBatchResponse": ".types",
+ "RunTagsResponse": ".types",
+ "RunType": ".types",
"RunWebhookReplayResponse": ".types",
"SchedulesListAllRequestStatus": ".schedules",
"Script": ".types",
@@ -1080,6 +1214,21 @@ _dynamic_imports: typing.Dict[str, str] = {
"SkyvernEnvironment": ".environment",
"SkyvernForgeSdkSchemasCredentialsCredentialType": ".types",
"SkyvernSchemasCredentialTypeCredentialType": ".types",
+ "SplitPdfBlock": ".types",
+ "SplitPdfBlockParametersItem": ".types",
+ "SplitPdfBlockParametersItem_AwsSecret": ".types",
+ "SplitPdfBlockParametersItem_AzureSecret": ".types",
+ "SplitPdfBlockParametersItem_AzureVaultCredential": ".types",
+ "SplitPdfBlockParametersItem_BitwardenCreditCardData": ".types",
+ "SplitPdfBlockParametersItem_BitwardenLoginCredential": ".types",
+ "SplitPdfBlockParametersItem_BitwardenSensitiveInformation": ".types",
+ "SplitPdfBlockParametersItem_Context": ".types",
+ "SplitPdfBlockParametersItem_Credential": ".types",
+ "SplitPdfBlockParametersItem_Onepassword": ".types",
+ "SplitPdfBlockParametersItem_Output": ".types",
+ "SplitPdfBlockParametersItem_Workflow": ".types",
+ "SplitPdfBlockYaml": ".types",
+ "TagApplyRequest": ".types",
"TagDeleteInput": ".types",
"TagHistoryItem": ".types",
"TagHistoryResponse": ".types",
@@ -1088,6 +1237,9 @@ _dynamic_imports: typing.Dict[str, str] = {
"TagKey": ".types",
"TagKeyDeleteResponse": ".types",
"TagResponse": ".types",
+ "TagValue": ".types",
+ "TagValueDeleteResponse": ".types",
+ "TagValueRenameResponse": ".types",
"TagsResponse": ".types",
"TaskBlock": ".types",
"TaskBlockDataSchema": ".types",
@@ -1198,6 +1350,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"WhileLoopBlockLoopBlocksItem_Code": ".types",
"WhileLoopBlockLoopBlocksItem_Conditional": ".types",
"WhileLoopBlockLoopBlocksItem_DownloadToS3": ".types",
+ "WhileLoopBlockLoopBlocksItem_EmailInbox": ".types",
"WhileLoopBlockLoopBlocksItem_Extraction": ".types",
"WhileLoopBlockLoopBlocksItem_FileDownload": ".types",
"WhileLoopBlockLoopBlocksItem_FileUpload": ".types",
@@ -1210,9 +1363,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"WhileLoopBlockLoopBlocksItem_HumanInteraction": ".types",
"WhileLoopBlockLoopBlocksItem_Login": ".types",
"WhileLoopBlockLoopBlocksItem_Navigation": ".types",
+ "WhileLoopBlockLoopBlocksItem_PdfFill": ".types",
"WhileLoopBlockLoopBlocksItem_PdfParser": ".types",
"WhileLoopBlockLoopBlocksItem_PrintPage": ".types",
"WhileLoopBlockLoopBlocksItem_SendEmail": ".types",
+ "WhileLoopBlockLoopBlocksItem_SplitPdf": ".types",
"WhileLoopBlockLoopBlocksItem_Task": ".types",
"WhileLoopBlockLoopBlocksItem_TaskV2": ".types",
"WhileLoopBlockLoopBlocksItem_TextPrompt": ".types",
@@ -1227,6 +1382,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"WhileLoopBlockYamlLoopBlocksItem_Code": ".types",
"WhileLoopBlockYamlLoopBlocksItem_Conditional": ".types",
"WhileLoopBlockYamlLoopBlocksItem_DownloadToS3": ".types",
+ "WhileLoopBlockYamlLoopBlocksItem_EmailInbox": ".types",
"WhileLoopBlockYamlLoopBlocksItem_Extraction": ".types",
"WhileLoopBlockYamlLoopBlocksItem_FileDownload": ".types",
"WhileLoopBlockYamlLoopBlocksItem_FileUpload": ".types",
@@ -1239,9 +1395,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"WhileLoopBlockYamlLoopBlocksItem_HumanInteraction": ".types",
"WhileLoopBlockYamlLoopBlocksItem_Login": ".types",
"WhileLoopBlockYamlLoopBlocksItem_Navigation": ".types",
+ "WhileLoopBlockYamlLoopBlocksItem_PdfFill": ".types",
"WhileLoopBlockYamlLoopBlocksItem_PdfParser": ".types",
"WhileLoopBlockYamlLoopBlocksItem_PrintPage": ".types",
"WhileLoopBlockYamlLoopBlocksItem_SendEmail": ".types",
+ "WhileLoopBlockYamlLoopBlocksItem_SplitPdf": ".types",
"WhileLoopBlockYamlLoopBlocksItem_Task": ".types",
"WhileLoopBlockYamlLoopBlocksItem_TaskV2": ".types",
"WhileLoopBlockYamlLoopBlocksItem_TextPrompt": ".types",
@@ -1259,6 +1417,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"WorkflowDefinitionBlocksItem_Code": ".types",
"WorkflowDefinitionBlocksItem_Conditional": ".types",
"WorkflowDefinitionBlocksItem_DownloadToS3": ".types",
+ "WorkflowDefinitionBlocksItem_EmailInbox": ".types",
"WorkflowDefinitionBlocksItem_Extraction": ".types",
"WorkflowDefinitionBlocksItem_FileDownload": ".types",
"WorkflowDefinitionBlocksItem_FileUpload": ".types",
@@ -1271,9 +1430,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"WorkflowDefinitionBlocksItem_HumanInteraction": ".types",
"WorkflowDefinitionBlocksItem_Login": ".types",
"WorkflowDefinitionBlocksItem_Navigation": ".types",
+ "WorkflowDefinitionBlocksItem_PdfFill": ".types",
"WorkflowDefinitionBlocksItem_PdfParser": ".types",
"WorkflowDefinitionBlocksItem_PrintPage": ".types",
"WorkflowDefinitionBlocksItem_SendEmail": ".types",
+ "WorkflowDefinitionBlocksItem_SplitPdf": ".types",
"WorkflowDefinitionBlocksItem_Task": ".types",
"WorkflowDefinitionBlocksItem_TaskV2": ".types",
"WorkflowDefinitionBlocksItem_TextPrompt": ".types",
@@ -1300,6 +1461,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"WorkflowDefinitionYamlBlocksItem_Code": ".types",
"WorkflowDefinitionYamlBlocksItem_Conditional": ".types",
"WorkflowDefinitionYamlBlocksItem_DownloadToS3": ".types",
+ "WorkflowDefinitionYamlBlocksItem_EmailInbox": ".types",
"WorkflowDefinitionYamlBlocksItem_Extraction": ".types",
"WorkflowDefinitionYamlBlocksItem_FileDownload": ".types",
"WorkflowDefinitionYamlBlocksItem_FileUpload": ".types",
@@ -1312,9 +1474,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"WorkflowDefinitionYamlBlocksItem_HumanInteraction": ".types",
"WorkflowDefinitionYamlBlocksItem_Login": ".types",
"WorkflowDefinitionYamlBlocksItem_Navigation": ".types",
+ "WorkflowDefinitionYamlBlocksItem_PdfFill": ".types",
"WorkflowDefinitionYamlBlocksItem_PdfParser": ".types",
"WorkflowDefinitionYamlBlocksItem_PrintPage": ".types",
"WorkflowDefinitionYamlBlocksItem_SendEmail": ".types",
+ "WorkflowDefinitionYamlBlocksItem_SplitPdf": ".types",
"WorkflowDefinitionYamlBlocksItem_Task": ".types",
"WorkflowDefinitionYamlBlocksItem_TaskV2": ".types",
"WorkflowDefinitionYamlBlocksItem_TextPrompt": ".types",
@@ -1455,6 +1619,7 @@ __all__ = [
"BrowserProfileProxyLocation",
"BrowserSessionResponse",
"BulkCancelRunsResponse",
+ "ClearOrganizationAuthTokenResponse",
"ClickAction",
"ClickActionData",
"ClickContext",
@@ -1471,6 +1636,8 @@ __all__ = [
"CodeBlockParametersItem_Onepassword",
"CodeBlockParametersItem_Output",
"CodeBlockParametersItem_Workflow",
+ "CodeBlockStep",
+ "CodeBlockStepYaml",
"CodeBlockYaml",
"ConditionalBlock",
"ConditionalBlockYaml",
@@ -1500,12 +1667,35 @@ __all__ = [
"CredentialParameterYaml",
"CredentialResponse",
"CredentialResponseCredential",
+ "CredentialResponseProxyLocation",
"CredentialTypeOutput",
"CredentialVaultType",
+ "CreditCardBillingAddress",
"CreditCardCredentialResponse",
+ "CustomLlm",
+ "CustomLlmConfig",
+ "CustomLlmListResponse",
+ "CustomLlmProvider",
+ "CustomLlmResponse",
"DeleteScheduleResponse",
"DownloadToS3Block",
"DownloadToS3BlockYaml",
+ "EmailInboxBlock",
+ "EmailInboxBlockEmailClient",
+ "EmailInboxBlockParametersItem",
+ "EmailInboxBlockParametersItem_AwsSecret",
+ "EmailInboxBlockParametersItem_AzureSecret",
+ "EmailInboxBlockParametersItem_AzureVaultCredential",
+ "EmailInboxBlockParametersItem_BitwardenCreditCardData",
+ "EmailInboxBlockParametersItem_BitwardenLoginCredential",
+ "EmailInboxBlockParametersItem_BitwardenSensitiveInformation",
+ "EmailInboxBlockParametersItem_Context",
+ "EmailInboxBlockParametersItem_Credential",
+ "EmailInboxBlockParametersItem_Onepassword",
+ "EmailInboxBlockParametersItem_Output",
+ "EmailInboxBlockParametersItem_Workflow",
+ "EmailInboxBlockYaml",
+ "EmailInboxBlockYamlEmailClient",
"Extensions",
"ExtractAction",
"ExtractActionData",
@@ -1558,6 +1748,7 @@ __all__ = [
"ForLoopBlockLoopBlocksItem_Code",
"ForLoopBlockLoopBlocksItem_Conditional",
"ForLoopBlockLoopBlocksItem_DownloadToS3",
+ "ForLoopBlockLoopBlocksItem_EmailInbox",
"ForLoopBlockLoopBlocksItem_Extraction",
"ForLoopBlockLoopBlocksItem_FileDownload",
"ForLoopBlockLoopBlocksItem_FileUpload",
@@ -1570,9 +1761,11 @@ __all__ = [
"ForLoopBlockLoopBlocksItem_HumanInteraction",
"ForLoopBlockLoopBlocksItem_Login",
"ForLoopBlockLoopBlocksItem_Navigation",
+ "ForLoopBlockLoopBlocksItem_PdfFill",
"ForLoopBlockLoopBlocksItem_PdfParser",
"ForLoopBlockLoopBlocksItem_PrintPage",
"ForLoopBlockLoopBlocksItem_SendEmail",
+ "ForLoopBlockLoopBlocksItem_SplitPdf",
"ForLoopBlockLoopBlocksItem_Task",
"ForLoopBlockLoopBlocksItem_TaskV2",
"ForLoopBlockLoopBlocksItem_TextPrompt",
@@ -1600,6 +1793,7 @@ __all__ = [
"ForLoopBlockYamlLoopBlocksItem_Code",
"ForLoopBlockYamlLoopBlocksItem_Conditional",
"ForLoopBlockYamlLoopBlocksItem_DownloadToS3",
+ "ForLoopBlockYamlLoopBlocksItem_EmailInbox",
"ForLoopBlockYamlLoopBlocksItem_Extraction",
"ForLoopBlockYamlLoopBlocksItem_FileDownload",
"ForLoopBlockYamlLoopBlocksItem_FileUpload",
@@ -1612,9 +1806,11 @@ __all__ = [
"ForLoopBlockYamlLoopBlocksItem_HumanInteraction",
"ForLoopBlockYamlLoopBlocksItem_Login",
"ForLoopBlockYamlLoopBlocksItem_Navigation",
+ "ForLoopBlockYamlLoopBlocksItem_PdfFill",
"ForLoopBlockYamlLoopBlocksItem_PdfParser",
"ForLoopBlockYamlLoopBlocksItem_PrintPage",
"ForLoopBlockYamlLoopBlocksItem_SendEmail",
+ "ForLoopBlockYamlLoopBlocksItem_SplitPdf",
"ForLoopBlockYamlLoopBlocksItem_Task",
"ForLoopBlockYamlLoopBlocksItem_TaskV2",
"ForLoopBlockYamlLoopBlocksItem_TextPrompt",
@@ -1740,6 +1936,22 @@ __all__ = [
"OutputParameter",
"OutputParameterYaml",
"PasswordCredentialResponse",
+ "PdfFillBlock",
+ "PdfFillBlockParametersItem",
+ "PdfFillBlockParametersItem_AwsSecret",
+ "PdfFillBlockParametersItem_AzureSecret",
+ "PdfFillBlockParametersItem_AzureVaultCredential",
+ "PdfFillBlockParametersItem_BitwardenCreditCardData",
+ "PdfFillBlockParametersItem_BitwardenLoginCredential",
+ "PdfFillBlockParametersItem_BitwardenSensitiveInformation",
+ "PdfFillBlockParametersItem_Context",
+ "PdfFillBlockParametersItem_Credential",
+ "PdfFillBlockParametersItem_Onepassword",
+ "PdfFillBlockParametersItem_Output",
+ "PdfFillBlockParametersItem_Workflow",
+ "PdfFillBlockPayload",
+ "PdfFillBlockYaml",
+ "PdfFillBlockYamlPayload",
"PdfFormat",
"PdfParserBlock",
"PdfParserBlockYaml",
@@ -1776,6 +1988,10 @@ __all__ = [
"RunSdkActionRequestAction_Validate",
"RunSdkActionResponse",
"RunStatus",
+ "RunTagHistoryResponse",
+ "RunTagsBatchResponse",
+ "RunTagsResponse",
+ "RunType",
"RunWebhookReplayResponse",
"SchedulesListAllRequestStatus",
"Script",
@@ -1792,6 +2008,21 @@ __all__ = [
"SkyvernEnvironment",
"SkyvernForgeSdkSchemasCredentialsCredentialType",
"SkyvernSchemasCredentialTypeCredentialType",
+ "SplitPdfBlock",
+ "SplitPdfBlockParametersItem",
+ "SplitPdfBlockParametersItem_AwsSecret",
+ "SplitPdfBlockParametersItem_AzureSecret",
+ "SplitPdfBlockParametersItem_AzureVaultCredential",
+ "SplitPdfBlockParametersItem_BitwardenCreditCardData",
+ "SplitPdfBlockParametersItem_BitwardenLoginCredential",
+ "SplitPdfBlockParametersItem_BitwardenSensitiveInformation",
+ "SplitPdfBlockParametersItem_Context",
+ "SplitPdfBlockParametersItem_Credential",
+ "SplitPdfBlockParametersItem_Onepassword",
+ "SplitPdfBlockParametersItem_Output",
+ "SplitPdfBlockParametersItem_Workflow",
+ "SplitPdfBlockYaml",
+ "TagApplyRequest",
"TagDeleteInput",
"TagHistoryItem",
"TagHistoryResponse",
@@ -1800,6 +2031,9 @@ __all__ = [
"TagKey",
"TagKeyDeleteResponse",
"TagResponse",
+ "TagValue",
+ "TagValueDeleteResponse",
+ "TagValueRenameResponse",
"TagsResponse",
"TaskBlock",
"TaskBlockDataSchema",
@@ -1910,6 +2144,7 @@ __all__ = [
"WhileLoopBlockLoopBlocksItem_Code",
"WhileLoopBlockLoopBlocksItem_Conditional",
"WhileLoopBlockLoopBlocksItem_DownloadToS3",
+ "WhileLoopBlockLoopBlocksItem_EmailInbox",
"WhileLoopBlockLoopBlocksItem_Extraction",
"WhileLoopBlockLoopBlocksItem_FileDownload",
"WhileLoopBlockLoopBlocksItem_FileUpload",
@@ -1922,9 +2157,11 @@ __all__ = [
"WhileLoopBlockLoopBlocksItem_HumanInteraction",
"WhileLoopBlockLoopBlocksItem_Login",
"WhileLoopBlockLoopBlocksItem_Navigation",
+ "WhileLoopBlockLoopBlocksItem_PdfFill",
"WhileLoopBlockLoopBlocksItem_PdfParser",
"WhileLoopBlockLoopBlocksItem_PrintPage",
"WhileLoopBlockLoopBlocksItem_SendEmail",
+ "WhileLoopBlockLoopBlocksItem_SplitPdf",
"WhileLoopBlockLoopBlocksItem_Task",
"WhileLoopBlockLoopBlocksItem_TaskV2",
"WhileLoopBlockLoopBlocksItem_TextPrompt",
@@ -1939,6 +2176,7 @@ __all__ = [
"WhileLoopBlockYamlLoopBlocksItem_Code",
"WhileLoopBlockYamlLoopBlocksItem_Conditional",
"WhileLoopBlockYamlLoopBlocksItem_DownloadToS3",
+ "WhileLoopBlockYamlLoopBlocksItem_EmailInbox",
"WhileLoopBlockYamlLoopBlocksItem_Extraction",
"WhileLoopBlockYamlLoopBlocksItem_FileDownload",
"WhileLoopBlockYamlLoopBlocksItem_FileUpload",
@@ -1951,9 +2189,11 @@ __all__ = [
"WhileLoopBlockYamlLoopBlocksItem_HumanInteraction",
"WhileLoopBlockYamlLoopBlocksItem_Login",
"WhileLoopBlockYamlLoopBlocksItem_Navigation",
+ "WhileLoopBlockYamlLoopBlocksItem_PdfFill",
"WhileLoopBlockYamlLoopBlocksItem_PdfParser",
"WhileLoopBlockYamlLoopBlocksItem_PrintPage",
"WhileLoopBlockYamlLoopBlocksItem_SendEmail",
+ "WhileLoopBlockYamlLoopBlocksItem_SplitPdf",
"WhileLoopBlockYamlLoopBlocksItem_Task",
"WhileLoopBlockYamlLoopBlocksItem_TaskV2",
"WhileLoopBlockYamlLoopBlocksItem_TextPrompt",
@@ -1971,6 +2211,7 @@ __all__ = [
"WorkflowDefinitionBlocksItem_Code",
"WorkflowDefinitionBlocksItem_Conditional",
"WorkflowDefinitionBlocksItem_DownloadToS3",
+ "WorkflowDefinitionBlocksItem_EmailInbox",
"WorkflowDefinitionBlocksItem_Extraction",
"WorkflowDefinitionBlocksItem_FileDownload",
"WorkflowDefinitionBlocksItem_FileUpload",
@@ -1983,9 +2224,11 @@ __all__ = [
"WorkflowDefinitionBlocksItem_HumanInteraction",
"WorkflowDefinitionBlocksItem_Login",
"WorkflowDefinitionBlocksItem_Navigation",
+ "WorkflowDefinitionBlocksItem_PdfFill",
"WorkflowDefinitionBlocksItem_PdfParser",
"WorkflowDefinitionBlocksItem_PrintPage",
"WorkflowDefinitionBlocksItem_SendEmail",
+ "WorkflowDefinitionBlocksItem_SplitPdf",
"WorkflowDefinitionBlocksItem_Task",
"WorkflowDefinitionBlocksItem_TaskV2",
"WorkflowDefinitionBlocksItem_TextPrompt",
@@ -2012,6 +2255,7 @@ __all__ = [
"WorkflowDefinitionYamlBlocksItem_Code",
"WorkflowDefinitionYamlBlocksItem_Conditional",
"WorkflowDefinitionYamlBlocksItem_DownloadToS3",
+ "WorkflowDefinitionYamlBlocksItem_EmailInbox",
"WorkflowDefinitionYamlBlocksItem_Extraction",
"WorkflowDefinitionYamlBlocksItem_FileDownload",
"WorkflowDefinitionYamlBlocksItem_FileUpload",
@@ -2024,9 +2268,11 @@ __all__ = [
"WorkflowDefinitionYamlBlocksItem_HumanInteraction",
"WorkflowDefinitionYamlBlocksItem_Login",
"WorkflowDefinitionYamlBlocksItem_Navigation",
+ "WorkflowDefinitionYamlBlocksItem_PdfFill",
"WorkflowDefinitionYamlBlocksItem_PdfParser",
"WorkflowDefinitionYamlBlocksItem_PrintPage",
"WorkflowDefinitionYamlBlocksItem_SendEmail",
+ "WorkflowDefinitionYamlBlocksItem_SplitPdf",
"WorkflowDefinitionYamlBlocksItem_Task",
"WorkflowDefinitionYamlBlocksItem_TaskV2",
"WorkflowDefinitionYamlBlocksItem_TextPrompt",
diff --git a/skyvern/client/client.py b/skyvern/client/client.py
index ccf9194e2..a76bd2074 100644
--- a/skyvern/client/client.py
+++ b/skyvern/client/client.py
@@ -15,6 +15,7 @@ from .types.artifact_type import ArtifactType
from .types.browser_profile import BrowserProfile
from .types.browser_session_response import BrowserSessionResponse
from .types.bulk_cancel_runs_response import BulkCancelRunsResponse
+from .types.clear_organization_auth_token_response import ClearOrganizationAuthTokenResponse
from .types.create_browser_profile_request_proxy_location import CreateBrowserProfileRequestProxyLocation
from .types.create_browser_session_request_proxy_location import CreateBrowserSessionRequestProxyLocation
from .types.create_credential_request_credential import CreateCredentialRequestCredential
@@ -22,6 +23,9 @@ from .types.create_credential_request_proxy_location import CreateCredentialRequ
from .types.create_script_response import CreateScriptResponse
from .types.credential_response import CredentialResponse
from .types.credential_vault_type import CredentialVaultType
+from .types.custom_llm_config import CustomLlmConfig
+from .types.custom_llm_list_response import CustomLlmListResponse
+from .types.custom_llm_response import CustomLlmResponse
from .types.extensions import Extensions
from .types.folder import Folder
from .types.get_run_response import GetRunResponse
@@ -33,6 +37,10 @@ from .types.run_engine import RunEngine
from .types.run_sdk_action_request_action import RunSdkActionRequestAction
from .types.run_sdk_action_response import RunSdkActionResponse
from .types.run_status import RunStatus
+from .types.run_tag_history_response import RunTagHistoryResponse
+from .types.run_tags_batch_response import RunTagsBatchResponse
+from .types.run_tags_response import RunTagsResponse
+from .types.run_type import RunType
from .types.run_webhook_replay_response import RunWebhookReplayResponse
from .types.script import Script
from .types.script_file_create import ScriptFileCreate
@@ -43,6 +51,9 @@ from .types.tag_history_response import TagHistoryResponse
from .types.tag_input import TagInput
from .types.tag_key import TagKey
from .types.tag_key_delete_response import TagKeyDeleteResponse
+from .types.tag_value import TagValue
+from .types.tag_value_delete_response import TagValueDeleteResponse
+from .types.tag_value_rename_response import TagValueRenameResponse
from .types.tags_response import TagsResponse
from .types.task_run_list_item import TaskRunListItem
from .types.task_run_request_input_data_extraction_schema import TaskRunRequestInputDataExtractionSchema
@@ -1041,19 +1052,24 @@ class Skyvern:
)
return _response.data
- def list_tag_keys(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.List[TagKey]:
+ def get_run_tags(
+ self, workflow_run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> RunTagsResponse:
"""
- List all tag keys registered for the organization with their descriptions.
+ Get the current tag state for a workflow run.
Parameters
----------
+ workflow_run_id : str
+ Workflow run ID
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[TagKey]
- Successfully retrieved tag keys
+ RunTagsResponse
+ Successfully retrieved tags
Examples
--------
@@ -1062,29 +1078,46 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.list_tag_keys()
+ client.get_run_tags(
+ workflow_run_id="wr_123",
+ )
"""
- _response = self._raw_client.list_tag_keys(request_options=request_options)
+ _response = self._raw_client.get_run_tags(workflow_run_id, request_options=request_options)
return _response.data
- def delete_tag_key(
- self, key: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> TagKeyDeleteResponse:
+ def apply_run_tags(
+ self,
+ workflow_run_id: str,
+ *,
+ tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
+ tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> RunTagsResponse:
"""
- Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
+ Atomically apply tag changes to a workflow run. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
Parameters
----------
- key : str
- Tag key to delete
+ workflow_run_id : str
+ Workflow run ID
+
+ tags : typing.Optional[typing.Sequence[TagInput]]
+ Tags to set (overwrite). List of {key?, value} objects.
+
+ tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
+ Tags to soft-delete. List of {key?, value?} targets.
+
+ colors : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TagKeyDeleteResponse
- Successfully deleted tag key
+ RunTagsResponse
+ Successfully applied tag changes
Examples
--------
@@ -1093,38 +1126,36 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.delete_tag_key(
- key="env",
+ client.apply_run_tags(
+ workflow_run_id="wr_123",
)
"""
- _response = self._raw_client.delete_tag_key(key, request_options=request_options)
+ _response = self._raw_client.apply_run_tags(
+ workflow_run_id, tags=tags, tags_to_delete=tags_to_delete, colors=colors, request_options=request_options
+ )
return _response.data
- def update_tag_key(
- self,
- key: str,
- *,
- description: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> TagKey:
+ def delete_run_tag(
+ self, workflow_run_id: str, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> RunTagsResponse:
"""
- Update the description for a tag key.
+ Soft-delete a single grouped tag from a workflow run. Writes a DELETE event row.
Parameters
----------
- key : str
- Tag key to update
+ workflow_run_id : str
+ Workflow run ID
- description : typing.Optional[str]
- Free-form description (max 500 chars). Pass null to clear.
+ key : str
+ Tag key to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TagKey
- Successfully updated tag key
+ RunTagsResponse
+ Successfully deleted tag (or no-op if absent)
Examples
--------
@@ -1133,72 +1164,84 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.update_tag_key(
- key="key",
+ client.delete_run_tag(
+ workflow_run_id="wr_123",
+ key="env",
)
"""
- _response = self._raw_client.update_tag_key(key, description=description, request_options=request_options)
+ _response = self._raw_client.delete_run_tag(workflow_run_id, key, request_options=request_options)
return _response.data
- def batch_get_workflow_tags(
+ def get_run_tag_history(
self,
+ workflow_run_id: str,
*,
- workflow_permanent_ids: typing.Optional[str] = None,
+ limit: typing.Optional[int] = None,
+ since: typing.Optional[dt.datetime] = None,
+ key: typing.Optional[str] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> WorkflowTagsBatchResponse:
+ ) -> RunTagHistoryResponse:
"""
- Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
+ Chronological tag-event log for a workflow run (newest first). Includes SET and DELETE events.
Parameters
----------
- workflow_permanent_ids : typing.Optional[str]
- Comma-separated workflow permanent IDs
+ workflow_run_id : str
+ Workflow run ID
+
+ limit : typing.Optional[int]
+ Max events to return
+
+ since : typing.Optional[dt.datetime]
+ Only return events at or after this timestamp
+
+ key : typing.Optional[str]
+ Filter to events for a single tag key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- WorkflowTagsBatchResponse
- Successfully retrieved tags
+ RunTagHistoryResponse
+ Successfully retrieved tag history
Examples
--------
+ import datetime
+
from skyvern import Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.batch_get_workflow_tags(
- workflow_permanent_ids="workflow_permanent_ids",
+ client.get_run_tag_history(
+ workflow_run_id="wr_123",
+ limit=1,
+ since=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+ key="key",
)
"""
- _response = self._raw_client.batch_get_workflow_tags(
- workflow_permanent_ids=workflow_permanent_ids, request_options=request_options
+ _response = self._raw_client.get_run_tag_history(
+ workflow_run_id, limit=limit, since=since, key=key, request_options=request_options
)
return _response.data
- def batch_get_workflow_tags_post(
- self,
- *,
- workflow_permanent_ids: typing.Optional[typing.Sequence[str]] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> WorkflowTagsBatchResponse:
+ def list_tag_keys(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.List[TagKey]:
"""
- Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
+ List all tag keys registered for the organization with their descriptions.
Parameters
----------
- workflow_permanent_ids : typing.Optional[typing.Sequence[str]]
- Workflow permanent IDs to fetch tags for.
-
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- WorkflowTagsBatchResponse
- Successfully retrieved tags
+ typing.List[TagKey]
+ Successfully retrieved tag keys
Examples
--------
@@ -1207,37 +1250,29 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.batch_get_workflow_tags_post()
+ client.list_tag_keys()
"""
- _response = self._raw_client.batch_get_workflow_tags_post(
- workflow_permanent_ids=workflow_permanent_ids, request_options=request_options
- )
+ _response = self._raw_client.list_tag_keys(request_options=request_options)
return _response.data
- def get_run_artifacts(
- self,
- run_id: str,
- *,
- artifact_type: typing.Optional[typing.Union[ArtifactType, typing.Sequence[ArtifactType]]] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[Artifact]:
+ def delete_tag_key(
+ self, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagKeyDeleteResponse:
"""
- Get artifacts for a run
+ Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
Parameters
----------
- run_id : str
- The id of the task run or the workflow run.
-
- artifact_type : typing.Optional[typing.Union[ArtifactType, typing.Sequence[ArtifactType]]]
+ key : str
+ Tag key to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[Artifact]
- Successful Response
+ TagKeyDeleteResponse
+ Successfully deleted tag key
Examples
--------
@@ -1246,73 +1281,71 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_run_artifacts(
- run_id="run_id",
+ client.delete_tag_key(
+ key="env",
)
"""
- _response = self._raw_client.get_run_artifacts(
- run_id, artifact_type=artifact_type, request_options=request_options
- )
+ _response = self._raw_client.delete_tag_key(key, request_options=request_options)
return _response.data
- def retry_run_webhook(
+ def update_tag_key(
self,
- run_id: str,
+ key: str,
*,
- request: typing.Optional[RetryRunWebhookRequest] = None,
+ description: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> RunWebhookReplayResponse:
+ ) -> TagKey:
"""
- Retry sending the webhook for a run
+ Update the description for a tag key.
Parameters
----------
- run_id : str
- The id of the task run or the workflow run.
+ key : str
+ Tag key to update
- request : typing.Optional[RetryRunWebhookRequest]
+ description : typing.Optional[str]
+ Free-form description (max 500 chars). Pass null to clear.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- RunWebhookReplayResponse
- Successful Response
+ TagKey
+ Successfully updated tag key
Examples
--------
- from skyvern import RetryRunWebhookRequest, Skyvern
+ from skyvern import Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.retry_run_webhook(
- run_id="tsk_123",
- request=RetryRunWebhookRequest(),
+ client.update_tag_key(
+ key="key",
)
"""
- _response = self._raw_client.retry_run_webhook(run_id, request=request, request_options=request_options)
+ _response = self._raw_client.update_tag_key(key, description=description, request_options=request_options)
return _response.data
- def get_run_timeline(
- self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> typing.List[WorkflowRunTimeline]:
+ def list_tag_values(
+ self, *, key: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.List[TagValue]:
"""
- Get timeline for a run (workflow run or task_v2 run)
+ List the palette color and current workflow usage count for each grouped tag (key, value) for the organization. The frontend joins these onto tags by (key, value); workflow_count is the number of non-deleted workflows carrying the label and powers the per-label usage and delete blast-radius warnings.
Parameters
----------
- run_id : str
- The id of the workflow run or task_v2 run.
+ key : typing.Optional[str]
+ Filter to values for a single tag key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[WorkflowRunTimeline]
- Successfully retrieved run timeline
+ typing.List[TagValue]
+ Successfully retrieved tag values
Examples
--------
@@ -1321,26 +1354,34 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_run_timeline(
- run_id="wr_123",
+ client.list_tag_values(
+ key="key",
)
"""
- _response = self._raw_client.get_run_timeline(run_id, request_options=request_options)
+ _response = self._raw_client.list_tag_values(key=key, request_options=request_options)
return _response.data
- def get_version(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.Dict[str, str]:
+ def delete_tag_value(
+ self, key: str, *, value: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagValueDeleteResponse:
"""
- Returns the current Skyvern server version (git SHA for official builds).
+ Soft-delete a grouped tag (key, value) and remove that label from every workflow carrying it (cascade). The value rides in the body so values containing '/' stay addressable. Returns how many workflows the label was removed from.
Parameters
----------
+ key : str
+ Tag key (group)
+
+ value : str
+ Tag value (label) under the key to soft-delete.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.Dict[str, str]
- Current server version
+ TagValueDeleteResponse
+ Successfully deleted tag value
Examples
--------
@@ -1349,39 +1390,38 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_version()
+ client.delete_tag_value(
+ key="env",
+ value="value",
+ )
"""
- _response = self._raw_client.get_version(request_options=request_options)
+ _response = self._raw_client.delete_tag_value(key, value=value, request_options=request_options)
return _response.data
- def get_runs_v2(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- status: typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]] = None,
- search_key: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[TaskRunListItem]:
+ def update_tag_value(
+ self, key: str, *, value: str, color: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagValue:
"""
+ Recolor a grouped tag (key, value). The value is supplied in the body so values containing '/' stay addressable. The new color must be a palette name.
+
Parameters
----------
- page : typing.Optional[int]
-
- page_size : typing.Optional[int]
+ key : str
+ Tag key (group)
- status : typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]]
+ value : str
+ Tag value (label) under the key to recolor.
- search_key : typing.Optional[str]
- Case-insensitive substring search (min 3 chars for trigram index).
+ color : str
+ Palette color name to assign to this (key, value).
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[TaskRunListItem]
- Successful Response
+ TagValue
+ Successfully recolored tag value
Examples
--------
@@ -1390,30 +1430,39 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_runs_v2(
- page=1,
- page_size=1,
- search_key="search_key",
+ client.update_tag_value(
+ key="env",
+ value="value",
+ color="color",
)
"""
- _response = self._raw_client.get_runs_v2(
- page=page, page_size=page_size, status=status, search_key=search_key, request_options=request_options
- )
+ _response = self._raw_client.update_tag_value(key, value=value, color=color, request_options=request_options)
return _response.data
- def upload_file(self, *, file: str, request_options: typing.Optional[RequestOptions] = None) -> UploadFileResponse:
+ def rename_tag_value(
+ self, key: str, *, value: str, new_value: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagValueRenameResponse:
"""
+ Rename a grouped tag (key, value) to (key, new_value). The cascade re-tags every workflow carrying the old label; the new label inherits the old color. Both values ride in the body so values containing '/' stay addressable. Rejects with 409 when the new value already exists for the key.
+
Parameters
----------
- file : str
+ key : str
+ Tag key (group)
+
+ value : str
+ Current tag value (label) under the key to rename.
+
+ new_value : str
+ New tag value (label) to rename it to.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- UploadFileResponse
- Successful Response
+ TagValueRenameResponse
+ Successfully renamed tag value
Examples
--------
@@ -1422,44 +1471,38 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.upload_file(
- file="file",
+ client.rename_tag_value(
+ key="env",
+ value="value",
+ new_value="new_value",
)
"""
- _response = self._raw_client.upload_file(file=file, request_options=request_options)
+ _response = self._raw_client.rename_tag_value(
+ key, value=value, new_value=new_value, request_options=request_options
+ )
return _response.data
- def list_browser_profiles(
+ def batch_get_workflow_tags(
self,
*,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- include_deleted: typing.Optional[bool] = None,
- search_key: typing.Optional[str] = None,
+ workflow_permanent_ids: typing.Optional[str] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[BrowserProfile]:
+ ) -> WorkflowTagsBatchResponse:
"""
- Get all browser profiles for the organization
+ Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
Parameters
----------
- page : typing.Optional[int]
-
- page_size : typing.Optional[int]
-
- include_deleted : typing.Optional[bool]
- Include deleted browser profiles
-
- search_key : typing.Optional[str]
- Case-insensitive substring search across: browser profile name and description. A profile is returned if either field matches.
+ workflow_permanent_ids : typing.Optional[str]
+ Comma-separated workflow permanent IDs
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[BrowserProfile]
- Successfully retrieved browser profiles
+ WorkflowTagsBatchResponse
+ Successfully retrieved tags
Examples
--------
@@ -1468,63 +1511,69 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.list_browser_profiles(
- page=1,
- page_size=1,
- include_deleted=True,
- search_key="search_key",
+ client.batch_get_workflow_tags(
+ workflow_permanent_ids="workflow_permanent_ids",
)
"""
- _response = self._raw_client.list_browser_profiles(
- page=page,
- page_size=page_size,
- include_deleted=include_deleted,
- search_key=search_key,
- request_options=request_options,
+ _response = self._raw_client.batch_get_workflow_tags(
+ workflow_permanent_ids=workflow_permanent_ids, request_options=request_options
)
return _response.data
- def create_browser_profile(
+ def batch_get_workflow_tags_post(
self,
*,
- name: str,
- description: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- workflow_run_id: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[CreateBrowserProfileRequestProxyLocation] = OMIT,
- proxy_session_id: typing.Optional[str] = OMIT,
+ workflow_permanent_ids: typing.Optional[typing.Sequence[str]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> BrowserProfile:
+ ) -> WorkflowTagsBatchResponse:
"""
- Create a blank browser profile, or create one from a persistent browser session or workflow run.
+ Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
Parameters
----------
- name : str
- Name for the browser profile
+ workflow_permanent_ids : typing.Optional[typing.Sequence[str]]
+ Workflow permanent IDs to fetch tags for.
- description : typing.Optional[str]
- Optional profile description
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
- browser_session_id : typing.Optional[str]
- Persistent browser session to convert into a profile. Omit for a blank profile.
+ Returns
+ -------
+ WorkflowTagsBatchResponse
+ Successfully retrieved tags
- workflow_run_id : typing.Optional[str]
- Workflow run whose persisted session should be captured. Omit for a blank profile.
+ Examples
+ --------
+ from skyvern import Skyvern
- proxy_location : typing.Optional[CreateBrowserProfileRequestProxyLocation]
- Optional proxy location for this profile's pinned proxy identity.
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.batch_get_workflow_tags_post()
+ """
+ _response = self._raw_client.batch_get_workflow_tags_post(
+ workflow_permanent_ids=workflow_permanent_ids, request_options=request_options
+ )
+ return _response.data
- proxy_session_id : typing.Optional[str]
- Explicit sticky-session id for this profile's pinned proxy identity.
+ def batch_get_run_tags(
+ self, *, workflow_run_ids: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
+ ) -> RunTagsBatchResponse:
+ """
+ Batch fetch current tags for many workflow runs. Avoids N+1 on run-list pages.
+
+ Parameters
+ ----------
+ workflow_run_ids : typing.Optional[str]
+ Comma-separated workflow run IDs
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- BrowserProfile
- Successfully created browser profile
+ RunTagsBatchResponse
+ Successfully retrieved tags
Examples
--------
@@ -1533,39 +1582,36 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.create_browser_profile(
- name="name",
+ client.batch_get_run_tags(
+ workflow_run_ids="workflow_run_ids",
)
"""
- _response = self._raw_client.create_browser_profile(
- name=name,
- description=description,
- browser_session_id=browser_session_id,
- workflow_run_id=workflow_run_id,
- proxy_location=proxy_location,
- proxy_session_id=proxy_session_id,
- request_options=request_options,
+ _response = self._raw_client.batch_get_run_tags(
+ workflow_run_ids=workflow_run_ids, request_options=request_options
)
return _response.data
- def get_browser_profile(
- self, profile_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> BrowserProfile:
+ def batch_get_run_tags_post(
+ self,
+ *,
+ workflow_run_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> RunTagsBatchResponse:
"""
- Get a specific browser profile by ID
+ Batch fetch current tags for many workflow runs (POST variant for id lists exceeding URL length).
Parameters
----------
- profile_id : str
- The ID of the browser profile. browser_profile_id starts with `bp_`
+ workflow_run_ids : typing.Optional[typing.Sequence[str]]
+ Workflow run IDs to fetch tags for.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- BrowserProfile
- Successfully retrieved browser profile
+ RunTagsBatchResponse
+ Successfully retrieved tags
Examples
--------
@@ -1574,30 +1620,37 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_browser_profile(
- profile_id="bp_123456",
- )
+ client.batch_get_run_tags_post()
"""
- _response = self._raw_client.get_browser_profile(profile_id, request_options=request_options)
+ _response = self._raw_client.batch_get_run_tags_post(
+ workflow_run_ids=workflow_run_ids, request_options=request_options
+ )
return _response.data
- def delete_browser_profile(
- self, profile_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> None:
+ def get_run_artifacts(
+ self,
+ run_id: str,
+ *,
+ artifact_type: typing.Optional[typing.Union[ArtifactType, typing.Sequence[ArtifactType]]] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> typing.List[Artifact]:
"""
- Delete a browser profile (soft delete)
+ Get artifacts for a run
Parameters
----------
- profile_id : str
- The ID of the browser profile to delete. browser_profile_id starts with `bp_`
+ run_id : str
+ The id of the task run or the workflow run.
+
+ artifact_type : typing.Optional[typing.Union[ArtifactType, typing.Sequence[ArtifactType]]]
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- None
+ typing.List[Artifact]
+ Successful Response
Examples
--------
@@ -1606,54 +1659,73 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.delete_browser_profile(
- profile_id="bp_123456",
+ client.get_run_artifacts(
+ run_id="run_id",
)
"""
- _response = self._raw_client.delete_browser_profile(profile_id, request_options=request_options)
+ _response = self._raw_client.get_run_artifacts(
+ run_id, artifact_type=artifact_type, request_options=request_options
+ )
return _response.data
- def update_browser_profile(
+ def retry_run_webhook(
self,
- profile_id: str,
+ run_id: str,
*,
- name: typing.Optional[str] = OMIT,
- description: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[UpdateBrowserProfileRequestProxyLocation] = OMIT,
- proxy_session_id: typing.Optional[str] = OMIT,
- rotate_proxy_session_id: typing.Optional[bool] = OMIT,
+ request: typing.Optional[RetryRunWebhookRequest] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> BrowserProfile:
+ ) -> RunWebhookReplayResponse:
"""
- Update a browser profile's name and/or description
+ Retry sending the webhook for a run
Parameters
----------
- profile_id : str
- The ID of the browser profile to update. browser_profile_id starts with `bp_`
+ run_id : str
+ The id of the task run or the workflow run.
- name : typing.Optional[str]
- New name for the browser profile
+ request : typing.Optional[RetryRunWebhookRequest]
- description : typing.Optional[str]
- New description for the browser profile
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
- proxy_location : typing.Optional[UpdateBrowserProfileRequestProxyLocation]
- Optional proxy location for this profile's pinned proxy identity.
+ Returns
+ -------
+ RunWebhookReplayResponse
+ Successful Response
- proxy_session_id : typing.Optional[str]
- Opaque Skyvern-managed proxy sticky-session id.
+ Examples
+ --------
+ from skyvern import RetryRunWebhookRequest, Skyvern
- rotate_proxy_session_id : typing.Optional[bool]
- Rotate the Skyvern-managed proxy sticky-session id for this profile.
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.retry_run_webhook(
+ run_id="tsk_123",
+ request=RetryRunWebhookRequest(),
+ )
+ """
+ _response = self._raw_client.retry_run_webhook(run_id, request=request, request_options=request_options)
+ return _response.data
+
+ def get_run_timeline(
+ self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.List[WorkflowRunTimeline]:
+ """
+ Get timeline for a run (workflow run or task_v2 run)
+
+ Parameters
+ ----------
+ run_id : str
+ The id of the workflow run or task_v2 run.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- BrowserProfile
- Successfully updated browser profile
+ typing.List[WorkflowRunTimeline]
+ Successfully retrieved run timeline
Examples
--------
@@ -1662,26 +1734,16 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.update_browser_profile(
- profile_id="bp_123456",
+ client.get_run_timeline(
+ run_id="wr_123",
)
"""
- _response = self._raw_client.update_browser_profile(
- profile_id,
- name=name,
- description=description,
- proxy_location=proxy_location,
- proxy_session_id=proxy_session_id,
- rotate_proxy_session_id=rotate_proxy_session_id,
- request_options=request_options,
- )
+ _response = self._raw_client.get_run_timeline(run_id, request_options=request_options)
return _response.data
- def get_browser_sessions(
- self, *, request_options: typing.Optional[RequestOptions] = None
- ) -> typing.List[BrowserSessionResponse]:
+ def get_version(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.Dict[str, str]:
"""
- Get all active browser sessions for the organization
+ Returns the current Skyvern server version (git SHA for official builds).
Parameters
----------
@@ -1690,8 +1752,8 @@ class Skyvern:
Returns
-------
- typing.List[BrowserSessionResponse]
- Successfully retrieved all active browser sessions
+ typing.Dict[str, str]
+ Current server version
Examples
--------
@@ -1700,86 +1762,42 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_browser_sessions()
+ client.get_version()
"""
- _response = self._raw_client.get_browser_sessions(request_options=request_options)
+ _response = self._raw_client.get_version(request_options=request_options)
return _response.data
- def create_browser_session(
+ def get_runs_v2(
self,
*,
- timeout: typing.Optional[int] = OMIT,
- proxy_location: typing.Optional[CreateBrowserSessionRequestProxyLocation] = OMIT,
- extensions: typing.Optional[typing.Sequence[Extensions]] = OMIT,
- browser_type: typing.Optional[PersistentBrowserType] = OMIT,
- browser_profile_id: typing.Optional[str] = OMIT,
- generate_browser_profile: typing.Optional[bool] = OMIT,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ status: typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]] = None,
+ search_key: typing.Optional[str] = None,
+ run_type: typing.Optional[typing.Union[RunType, typing.Sequence[RunType]]] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> BrowserSessionResponse:
+ ) -> typing.List[TaskRunListItem]:
"""
- Create a browser session that persists across multiple runs
-
Parameters
----------
- timeout : typing.Optional[int]
- Timeout in minutes for the session. Timeout is applied after the session is started. Must be between 5 and 1440. Defaults to 60.
+ page : typing.Optional[int]
- proxy_location : typing.Optional[CreateBrowserSessionRequestProxyLocation]
+ page_size : typing.Optional[int]
- Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
+ status : typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]]
- Available geotargeting options:
- - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
- - RESIDENTIAL_ES: Spain
- - RESIDENTIAL_IE: Ireland
- - RESIDENTIAL_GB: United Kingdom
- - RESIDENTIAL_IN: India
- - RESIDENTIAL_JP: Japan
- - RESIDENTIAL_FR: France
- - RESIDENTIAL_DE: Germany
- - RESIDENTIAL_NZ: New Zealand
- - RESIDENTIAL_PH: Philippines
- - RESIDENTIAL_KR: South Korea
- - RESIDENTIAL_SA: Saudi Arabia
- - RESIDENTIAL_ZA: South Africa
- - RESIDENTIAL_AR: Argentina
- - RESIDENTIAL_AU: Australia
- - RESIDENTIAL_BR: Brazil
- - RESIDENTIAL_TR: Turkey
- - RESIDENTIAL_CA: Canada
- - RESIDENTIAL_MX: Mexico
- - RESIDENTIAL_IT: Italy
- - RESIDENTIAL_NL: Netherlands
- - RESIDENTIAL_ISP: ISP proxy
- - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
- - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
- - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
- - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
- - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
- - NONE: No proxy
-
- For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
- Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}, or a custom proxy URL dict for self-hosted deployments: {"url": "http://user:[email protected]:8080"}
-
- extensions : typing.Optional[typing.Sequence[Extensions]]
- A list of extensions to install in the browser session.
-
- browser_type : typing.Optional[PersistentBrowserType]
- The type of browser to use for the session.
-
- browser_profile_id : typing.Optional[str]
- ID of a browser profile to load into this session (restores cookies, localStorage, etc.). browser_profile_id starts with `bp_`.
+ search_key : typing.Optional[str]
+ Case-insensitive substring search (min 3 chars for trigram index).
- generate_browser_profile : typing.Optional[bool]
- When true, the session's browser profile (cookies, localStorage, etc.) is saved to storage when the session ends so it can be turned into a reusable browser profile. Defaults to false to avoid storing profiles for sessions that never need them. Sessions started with a browser_profile_id always persist their profile regardless of this flag.
+ run_type : typing.Optional[typing.Union[RunType, typing.Sequence[RunType]]]
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- BrowserSessionResponse
- Successfully created browser session
+ typing.List[TaskRunListItem]
+ Successful Response
Examples
--------
@@ -1788,37 +1806,35 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.create_browser_session()
+ client.get_runs_v2(
+ page=1,
+ page_size=1,
+ search_key="search_key",
+ )
"""
- _response = self._raw_client.create_browser_session(
- timeout=timeout,
- proxy_location=proxy_location,
- extensions=extensions,
- browser_type=browser_type,
- browser_profile_id=browser_profile_id,
- generate_browser_profile=generate_browser_profile,
+ _response = self._raw_client.get_runs_v2(
+ page=page,
+ page_size=page_size,
+ status=status,
+ search_key=search_key,
+ run_type=run_type,
request_options=request_options,
)
return _response.data
- def close_browser_session(
- self, browser_session_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> typing.Optional[typing.Any]:
+ def upload_file(self, *, file: str, request_options: typing.Optional[RequestOptions] = None) -> UploadFileResponse:
"""
- Close a session. Once closed, the session cannot be used again.
-
Parameters
----------
- browser_session_id : str
- The ID of the browser session to close. completed_at will be set when the browser session is closed. browser_session_id starts with `pbs_`
+ file : str
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.Optional[typing.Any]
- Successfully closed browser session
+ UploadFileResponse
+ Successful Response
Examples
--------
@@ -1827,31 +1843,48 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.close_browser_session(
- browser_session_id="pbs_123456",
+ client.upload_file(
+ file="file",
)
"""
- _response = self._raw_client.close_browser_session(browser_session_id, request_options=request_options)
+ _response = self._raw_client.upload_file(file=file, request_options=request_options)
return _response.data
- def get_browser_session(
- self, browser_session_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> BrowserSessionResponse:
+ def list_browser_profiles(
+ self,
+ *,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ include_deleted: typing.Optional[bool] = None,
+ search_key: typing.Optional[str] = None,
+ managed: typing.Optional[bool] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> typing.List[BrowserProfile]:
"""
- Get details about a specific browser session, including the browser address for cdp connection.
+ Get all browser profiles for the organization
Parameters
----------
- browser_session_id : str
- The ID of the browser session. browser_session_id starts with `pbs_`
+ page : typing.Optional[int]
+
+ page_size : typing.Optional[int]
+
+ include_deleted : typing.Optional[bool]
+ Include deleted browser profiles
+
+ search_key : typing.Optional[str]
+ Case-insensitive substring search across: browser profile name and description. A profile is returned if either field matches.
+
+ managed : typing.Optional[bool]
+ Omit to return all profiles; false returns only user-created profiles; true returns only auto-managed profiles.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- BrowserSessionResponse
- Successfully retrieved browser session details
+ typing.List[BrowserProfile]
+ Successfully retrieved browser profiles
Examples
--------
@@ -1860,38 +1893,65 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_browser_session(
- browser_session_id="pbs_123456",
+ client.list_browser_profiles(
+ page=1,
+ page_size=1,
+ include_deleted=True,
+ search_key="search_key",
+ managed=True,
)
"""
- _response = self._raw_client.get_browser_session(browser_session_id, request_options=request_options)
+ _response = self._raw_client.list_browser_profiles(
+ page=page,
+ page_size=page_size,
+ include_deleted=include_deleted,
+ search_key=search_key,
+ managed=managed,
+ request_options=request_options,
+ )
return _response.data
- def update_browser_session(
+ def create_browser_profile(
self,
- browser_session_id: str,
*,
- generate_browser_profile: bool,
+ name: str,
+ description: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ workflow_run_id: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[CreateBrowserProfileRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> BrowserSessionResponse:
+ ) -> BrowserProfile:
"""
- Update a live browser session. Currently supports toggling generate_browser_profile, which is read when the session ends to decide whether to save its browser profile.
+ Create a blank browser profile, or create one from a persistent browser session or workflow run.
Parameters
----------
- browser_session_id : str
- The ID of the browser session. browser_session_id starts with `pbs_`
+ name : str
+ Name for the browser profile
- generate_browser_profile : bool
- Enable or disable saving this session's browser profile when it ends. Can be toggled while the session is still alive; the value is read at session teardown.
+ description : typing.Optional[str]
+ Optional profile description
+
+ browser_session_id : typing.Optional[str]
+ Persistent browser session to convert into a profile. Omit for a blank profile.
+
+ workflow_run_id : typing.Optional[str]
+ Workflow run whose persisted session should be captured. Omit for a blank profile.
+
+ proxy_location : typing.Optional[CreateBrowserProfileRequestProxyLocation]
+ Optional proxy location for this profile's pinned proxy identity.
+
+ proxy_session_id : typing.Optional[str]
+ Explicit sticky-session id for this profile's pinned proxy identity.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- BrowserSessionResponse
- Successfully updated browser session
+ BrowserProfile
+ Successfully created browser profile
Examples
--------
@@ -1900,65 +1960,39 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.update_browser_session(
- browser_session_id="pbs_123456",
- generate_browser_profile=True,
+ client.create_browser_profile(
+ name="name",
)
"""
- _response = self._raw_client.update_browser_session(
- browser_session_id, generate_browser_profile=generate_browser_profile, request_options=request_options
+ _response = self._raw_client.create_browser_profile(
+ name=name,
+ description=description,
+ browser_session_id=browser_session_id,
+ workflow_run_id=workflow_run_id,
+ proxy_location=proxy_location,
+ proxy_session_id=proxy_session_id,
+ request_options=request_options,
)
return _response.data
- def send_totp_code(
- self,
- *,
- totp_identifier: str,
- content: str,
- task_id: typing.Optional[str] = OMIT,
- workflow_id: typing.Optional[str] = OMIT,
- workflow_run_id: typing.Optional[str] = OMIT,
- source: typing.Optional[str] = OMIT,
- expired_at: typing.Optional[dt.datetime] = OMIT,
- type: typing.Optional[OtpType] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> TotpCode:
+ def get_browser_profile(
+ self, profile_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> BrowserProfile:
"""
- Forward a TOTP (2FA, MFA) email or sms message containing the code to Skyvern. This endpoint stores the code in database so that Skyvern can use it while running tasks/workflows.
+ Get a specific browser profile by ID
Parameters
----------
- totp_identifier : str
- The identifier of the TOTP code. It can be the email address, phone number, or the identifier of the user.
-
- content : str
- The content of the TOTP code. It can be the email content that contains the TOTP code, or the sms message that contains the TOTP code. Skyvern will automatically extract the TOTP code from the content.
-
- task_id : typing.Optional[str]
- The task_id the totp code is for. It can be the task_id of the task that the TOTP code is for.
-
- workflow_id : typing.Optional[str]
- The workflow ID the TOTP code is for. It can be the workflow ID of the workflow that the TOTP code is for.
-
- workflow_run_id : typing.Optional[str]
- The workflow run id that the TOTP code is for. It can be the workflow run id of the workflow run that the TOTP code is for.
-
- source : typing.Optional[str]
- An optional field. The source of the TOTP code. e.g. email, sms, etc.
-
- expired_at : typing.Optional[dt.datetime]
- The timestamp when the TOTP code expires
-
- type : typing.Optional[OtpType]
- Optional. If provided, forces extraction of this specific OTP type (totp or magic_link). Use this when the content contains multiple OTP types and you want to specify which one to extract.
+ profile_id : str
+ The ID of the browser profile. browser_profile_id starts with `bp_`
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TotpCode
- Successful Response
+ BrowserProfile
+ Successfully retrieved browser profile
Examples
--------
@@ -1967,61 +2001,30 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.send_totp_code(
- totp_identifier="[email protected]",
- content="Hello, your verification code is 123456",
+ client.get_browser_profile(
+ profile_id="bp_123456",
)
"""
- _response = self._raw_client.send_totp_code(
- totp_identifier=totp_identifier,
- content=content,
- task_id=task_id,
- workflow_id=workflow_id,
- workflow_run_id=workflow_run_id,
- source=source,
- expired_at=expired_at,
- type=type,
- request_options=request_options,
- )
+ _response = self._raw_client.get_browser_profile(profile_id, request_options=request_options)
return _response.data
- def get_credentials(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- vault_type: typing.Optional[CredentialVaultType] = None,
- credential_type: typing.Optional[SkyvernForgeSdkSchemasCredentialsCredentialType] = None,
- search: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[CredentialResponse]:
+ def delete_browser_profile(
+ self, profile_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> None:
"""
- Retrieves a paginated list of credentials for the current organization
+ Delete a browser profile (soft delete)
Parameters
----------
- page : typing.Optional[int]
- Page number for pagination
-
- page_size : typing.Optional[int]
- Number of items per page
-
- vault_type : typing.Optional[CredentialVaultType]
- Filter credentials by vault type (e.g. 'skyvern', 'custom', 'bitwarden', 'azure_vault')
-
- credential_type : typing.Optional[SkyvernForgeSdkSchemasCredentialsCredentialType]
- Filter credentials by type (e.g. 'password', 'credit_card', 'secret')
-
- search : typing.Optional[str]
- Case-insensitive search across credential name, username, secret label, and card details
+ profile_id : str
+ The ID of the browser profile to delete. browser_profile_id starts with `bp_`
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[CredentialResponse]
- Successful Response
+ None
Examples
--------
@@ -2030,91 +2033,70 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_credentials(
- page=1,
- page_size=10,
- vault_type="skyvern",
- credential_type="password",
- search="search",
+ client.delete_browser_profile(
+ profile_id="bp_123456",
)
"""
- _response = self._raw_client.get_credentials(
- page=page,
- page_size=page_size,
- vault_type=vault_type,
- credential_type=credential_type,
- search=search,
- request_options=request_options,
- )
+ _response = self._raw_client.delete_browser_profile(profile_id, request_options=request_options)
return _response.data
- def create_credential(
+ def update_browser_profile(
self,
+ profile_id: str,
*,
- name: str,
- credential_type: SkyvernForgeSdkSchemasCredentialsCredentialType,
- credential: CreateCredentialRequestCredential,
- vault_type: typing.Optional[CredentialVaultType] = OMIT,
- proxy_location: typing.Optional[CreateCredentialRequestProxyLocation] = OMIT,
+ name: typing.Optional[str] = OMIT,
+ description: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[UpdateBrowserProfileRequestProxyLocation] = OMIT,
proxy_session_id: typing.Optional[str] = OMIT,
rotate_proxy_session_id: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> CredentialResponse:
+ ) -> BrowserProfile:
"""
- Creates a new credential for the current organization
+ Update a browser profile's name and/or description
Parameters
----------
- name : str
- Name of the credential
-
- credential_type : SkyvernForgeSdkSchemasCredentialsCredentialType
- Type of credential to create
+ profile_id : str
+ The ID of the browser profile to update. browser_profile_id starts with `bp_`
- credential : CreateCredentialRequestCredential
- The credential data to store
+ name : typing.Optional[str]
+ New name for the browser profile
- vault_type : typing.Optional[CredentialVaultType]
- Which vault to store this credential in. If omitted, uses the instance default. Use this to mix Skyvern-hosted and custom credentials within the same organization.
+ description : typing.Optional[str]
+ New description for the browser profile
- proxy_location : typing.Optional[CreateCredentialRequestProxyLocation]
- Optional proxy location for this credential's pinned proxy identity.
+ proxy_location : typing.Optional[UpdateBrowserProfileRequestProxyLocation]
+ Optional proxy location for this profile's pinned proxy identity.
proxy_session_id : typing.Optional[str]
- Optional advanced reuse key for this credential's pinned proxy identity.
+ Opaque Skyvern-managed proxy sticky-session id.
rotate_proxy_session_id : typing.Optional[bool]
- Rotate the Skyvern-managed proxy sticky-session id when updating this credential.
+ Rotate the Skyvern-managed proxy sticky-session id for this profile.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- CredentialResponse
- Successful Response
+ BrowserProfile
+ Successfully updated browser profile
Examples
--------
- from skyvern import NonEmptyPasswordCredential, Skyvern
+ from skyvern import Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.create_credential(
- name="Amazon Login",
- credential_type="password",
- credential=NonEmptyPasswordCredential(
- password="securepassword123",
- username="[email protected]",
- ),
+ client.update_browser_profile(
+ profile_id="bp_123456",
)
"""
- _response = self._raw_client.create_credential(
+ _response = self._raw_client.update_browser_profile(
+ profile_id,
name=name,
- credential_type=credential_type,
- credential=credential,
- vault_type=vault_type,
+ description=description,
proxy_location=proxy_location,
proxy_session_id=proxy_session_id,
rotate_proxy_session_id=rotate_proxy_session_id,
@@ -2122,101 +2104,153 @@ class Skyvern:
)
return _response.data
- def update_credential(
+ def get_browser_sessions(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.List[BrowserSessionResponse]:
+ """
+ Get all active browser sessions for the organization
+
+ Parameters
+ ----------
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.List[BrowserSessionResponse]
+ Successfully retrieved all active browser sessions
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.get_browser_sessions()
+ """
+ _response = self._raw_client.get_browser_sessions(request_options=request_options)
+ return _response.data
+
+ def create_browser_session(
self,
- credential_id: str,
*,
- name: str,
- credential_type: SkyvernForgeSdkSchemasCredentialsCredentialType,
- credential: CreateCredentialRequestCredential,
- vault_type: typing.Optional[CredentialVaultType] = OMIT,
- proxy_location: typing.Optional[CreateCredentialRequestProxyLocation] = OMIT,
+ timeout: typing.Optional[int] = OMIT,
+ proxy_location: typing.Optional[CreateBrowserSessionRequestProxyLocation] = OMIT,
proxy_session_id: typing.Optional[str] = OMIT,
- rotate_proxy_session_id: typing.Optional[bool] = OMIT,
+ extensions: typing.Optional[typing.Sequence[Extensions]] = OMIT,
+ browser_type: typing.Optional[PersistentBrowserType] = OMIT,
+ browser_profile_id: typing.Optional[str] = OMIT,
+ generate_browser_profile: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> CredentialResponse:
+ ) -> BrowserSessionResponse:
"""
- Overwrites the stored credential data (e.g. username/password) while keeping the same credential_id.
+ Create a browser session that persists across multiple runs
Parameters
----------
- credential_id : str
- The unique identifier of the credential to update
-
- name : str
- Name of the credential
+ timeout : typing.Optional[int]
+ Timeout in minutes for the session. Timeout is applied after the session is started. Must be between 5 and 1440. Defaults to 60.
- credential_type : SkyvernForgeSdkSchemasCredentialsCredentialType
- Type of credential to create
+ proxy_location : typing.Optional[CreateBrowserSessionRequestProxyLocation]
- credential : CreateCredentialRequestCredential
- The credential data to store
+ Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
- vault_type : typing.Optional[CredentialVaultType]
- Which vault to store this credential in. If omitted, uses the instance default. Use this to mix Skyvern-hosted and custom credentials within the same organization.
+ Available geotargeting options:
+ - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
+ - RESIDENTIAL_ES: Spain
+ - RESIDENTIAL_IE: Ireland
+ - RESIDENTIAL_GB: United Kingdom
+ - RESIDENTIAL_IN: India
+ - RESIDENTIAL_JP: Japan
+ - RESIDENTIAL_FR: France
+ - RESIDENTIAL_DE: Germany
+ - RESIDENTIAL_NZ: New Zealand
+ - RESIDENTIAL_PH: Philippines
+ - RESIDENTIAL_KR: South Korea
+ - RESIDENTIAL_SA: Saudi Arabia
+ - RESIDENTIAL_ZA: South Africa
+ - RESIDENTIAL_AR: Argentina
+ - RESIDENTIAL_AU: Australia
+ - RESIDENTIAL_BR: Brazil
+ - RESIDENTIAL_TR: Turkey
+ - RESIDENTIAL_CA: Canada
+ - RESIDENTIAL_MX: Mexico
+ - RESIDENTIAL_IT: Italy
+ - RESIDENTIAL_NL: Netherlands
+ - RESIDENTIAL_ISP: ISP proxy
+ - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
+ - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
+ - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
+ - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
+ - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
+ - NONE: No proxy
- proxy_location : typing.Optional[CreateCredentialRequestProxyLocation]
- Optional proxy location for this credential's pinned proxy identity.
+ For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
+ Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}, or a custom proxy URL dict for self-hosted deployments: {"url": "http://user:[email protected]:8080"}
proxy_session_id : typing.Optional[str]
- Optional advanced reuse key for this credential's pinned proxy identity.
+ Opaque Skyvern-managed proxy sticky-session id for pinned Residential ISP sessions.
- rotate_proxy_session_id : typing.Optional[bool]
- Rotate the Skyvern-managed proxy sticky-session id when updating this credential.
+ extensions : typing.Optional[typing.Sequence[Extensions]]
+ A list of extensions to install in the browser session.
+
+ browser_type : typing.Optional[PersistentBrowserType]
+ The type of browser to use for the session.
+
+ browser_profile_id : typing.Optional[str]
+ ID of a browser profile to load into this session (restores cookies, localStorage, etc.). browser_profile_id starts with `bp_`.
+
+ generate_browser_profile : typing.Optional[bool]
+ When true, the session's browser profile (cookies, localStorage, etc.) is saved to storage when the session ends so it can be turned into a reusable browser profile. Defaults to false to avoid storing profiles for sessions that never need them. Sessions started with a browser_profile_id always persist their profile regardless of this flag.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- CredentialResponse
- Successful Response
+ BrowserSessionResponse
+ Successfully created browser session
Examples
--------
- from skyvern import NonEmptyPasswordCredential, Skyvern
+ from skyvern import Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.update_credential(
- credential_id="cred_1234567890",
- name="Amazon Login",
- credential_type="password",
- credential=NonEmptyPasswordCredential(
- password="securepassword123",
- username="[email protected]",
- ),
- )
+ client.create_browser_session()
"""
- _response = self._raw_client.update_credential(
- credential_id,
- name=name,
- credential_type=credential_type,
- credential=credential,
- vault_type=vault_type,
+ _response = self._raw_client.create_browser_session(
+ timeout=timeout,
proxy_location=proxy_location,
proxy_session_id=proxy_session_id,
- rotate_proxy_session_id=rotate_proxy_session_id,
+ extensions=extensions,
+ browser_type=browser_type,
+ browser_profile_id=browser_profile_id,
+ generate_browser_profile=generate_browser_profile,
request_options=request_options,
)
return _response.data
- def delete_credential(self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None:
+ def close_browser_session(
+ self, browser_session_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.Optional[typing.Any]:
"""
- Deletes a specific credential by its ID
+ Close a session. Once closed, the session cannot be used again.
Parameters
----------
- credential_id : str
- The unique identifier of the credential to delete
+ browser_session_id : str
+ The ID of the browser session to close. completed_at will be set when the browser session is closed. browser_session_id starts with `pbs_`
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- None
+ typing.Optional[typing.Any]
+ Successfully closed browser session
Examples
--------
@@ -2225,31 +2259,31 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.delete_credential(
- credential_id="cred_1234567890",
+ client.close_browser_session(
+ browser_session_id="pbs_123456",
)
"""
- _response = self._raw_client.delete_credential(credential_id, request_options=request_options)
+ _response = self._raw_client.close_browser_session(browser_session_id, request_options=request_options)
return _response.data
- def get_credential(
- self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> CredentialResponse:
+ def get_browser_session(
+ self, browser_session_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> BrowserSessionResponse:
"""
- Retrieves a specific credential by its ID
+ Get details about a specific browser session, including the browser address for cdp connection.
Parameters
----------
- credential_id : str
- The unique identifier of the credential
+ browser_session_id : str
+ The ID of the browser session. browser_session_id starts with `pbs_`
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- CredentialResponse
- Successful Response
+ BrowserSessionResponse
+ Successfully retrieved browser session details
Examples
--------
@@ -2258,121 +2292,38 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_credential(
- credential_id="cred_1234567890",
+ client.get_browser_session(
+ browser_session_id="pbs_123456",
)
"""
- _response = self._raw_client.get_credential(credential_id, request_options=request_options)
+ _response = self._raw_client.get_browser_session(browser_session_id, request_options=request_options)
return _response.data
- def login(
+ def update_browser_session(
self,
+ browser_session_id: str,
*,
- credential_type: SkyvernSchemasCredentialTypeCredentialType,
- user_agent: typing.Optional[str] = None,
- url: typing.Optional[str] = OMIT,
- webhook_url: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[ProxyLocation] = OMIT,
- totp_identifier: typing.Optional[str] = OMIT,
- totp_url: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- browser_profile_id: typing.Optional[str] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- max_screenshot_scrolling_times: typing.Optional[int] = OMIT,
- prompt: typing.Optional[str] = OMIT,
- credential_id: typing.Optional[str] = OMIT,
- bitwarden_collection_id: typing.Optional[str] = OMIT,
- bitwarden_item_id: typing.Optional[str] = OMIT,
- onepassword_vault_id: typing.Optional[str] = OMIT,
- onepassword_item_id: typing.Optional[str] = OMIT,
- azure_vault_name: typing.Optional[str] = OMIT,
- azure_vault_username_key: typing.Optional[str] = OMIT,
- azure_vault_password_key: typing.Optional[str] = OMIT,
- azure_vault_totp_secret_key: typing.Optional[str] = OMIT,
+ generate_browser_profile: bool,
request_options: typing.Optional[RequestOptions] = None,
- ) -> WorkflowRunResponse:
+ ) -> BrowserSessionResponse:
"""
- Log in to a website using either credential stored in Skyvern, Bitwarden, 1Password, or Azure Vault
+ Update a live browser session. Currently supports toggling generate_browser_profile, which is read when the session ends to decide whether to save its browser profile.
Parameters
----------
- credential_type : SkyvernSchemasCredentialTypeCredentialType
- Where to get the credential from
-
- user_agent : typing.Optional[str]
-
- url : typing.Optional[str]
- Website URL
-
- webhook_url : typing.Optional[str]
- Webhook URL to send status updates
-
- proxy_location : typing.Optional[ProxyLocation]
- Proxy location to use
-
- totp_identifier : typing.Optional[str]
- Identifier for TOTP (Time-based One-Time Password) if required
-
- totp_url : typing.Optional[str]
- TOTP URL to fetch one-time passwords
-
- browser_session_id : typing.Optional[str]
- ID of the browser session to use, which is prefixed by `pbs_` e.g. `pbs_123456`
-
- browser_profile_id : typing.Optional[str]
- ID of a browser profile to reuse for this run
-
- browser_address : typing.Optional[str]
- The CDP address for the task.
-
- extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- Additional HTTP headers to include in requests
-
- cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Never forwarded to target websites.
-
- max_screenshot_scrolling_times : typing.Optional[int]
- Maximum number of times to scroll for screenshots
-
- prompt : typing.Optional[str]
- Login instructions. Skyvern has default prompt/instruction for login if this field is not provided.
-
- credential_id : typing.Optional[str]
- ID of the Skyvern credential to use for login.
-
- bitwarden_collection_id : typing.Optional[str]
- Bitwarden collection ID. You can find it in the Bitwarden collection URL. e.g. `https://vault.bitwarden.com/vaults/collection_id/items`
-
- bitwarden_item_id : typing.Optional[str]
- Bitwarden item ID
-
- onepassword_vault_id : typing.Optional[str]
- 1Password vault ID
-
- onepassword_item_id : typing.Optional[str]
- 1Password item ID
-
- azure_vault_name : typing.Optional[str]
- Azure Vault Name
-
- azure_vault_username_key : typing.Optional[str]
- Azure Vault username key
-
- azure_vault_password_key : typing.Optional[str]
- Azure Vault password key
+ browser_session_id : str
+ The ID of the browser session. browser_session_id starts with `pbs_`
- azure_vault_totp_secret_key : typing.Optional[str]
- Azure Vault TOTP secret key
+ generate_browser_profile : bool
+ Enable or disable saving this session's browser profile when it ends. Can be toggled while the session is still alive; the value is read at session teardown.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- WorkflowRunResponse
- Successful Response
+ BrowserSessionResponse
+ Successfully updated browser session
Examples
--------
@@ -2381,118 +2332,64 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.login(
- user_agent="x-user-agent",
- credential_type="skyvern",
+ client.update_browser_session(
+ browser_session_id="pbs_123456",
+ generate_browser_profile=True,
)
"""
- _response = self._raw_client.login(
- credential_type=credential_type,
- user_agent=user_agent,
- url=url,
- webhook_url=webhook_url,
- proxy_location=proxy_location,
- totp_identifier=totp_identifier,
- totp_url=totp_url,
- browser_session_id=browser_session_id,
- browser_profile_id=browser_profile_id,
- browser_address=browser_address,
- extra_http_headers=extra_http_headers,
- cdp_connect_headers=cdp_connect_headers,
- max_screenshot_scrolling_times=max_screenshot_scrolling_times,
- prompt=prompt,
- credential_id=credential_id,
- bitwarden_collection_id=bitwarden_collection_id,
- bitwarden_item_id=bitwarden_item_id,
- onepassword_vault_id=onepassword_vault_id,
- onepassword_item_id=onepassword_item_id,
- azure_vault_name=azure_vault_name,
- azure_vault_username_key=azure_vault_username_key,
- azure_vault_password_key=azure_vault_password_key,
- azure_vault_totp_secret_key=azure_vault_totp_secret_key,
- request_options=request_options,
+ _response = self._raw_client.update_browser_session(
+ browser_session_id, generate_browser_profile=generate_browser_profile, request_options=request_options
)
return _response.data
- def download_files(
+ def send_totp_code(
self,
*,
- navigation_goal: str,
- user_agent: typing.Optional[str] = None,
- url: typing.Optional[str] = OMIT,
- webhook_url: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[ProxyLocation] = OMIT,
- totp_identifier: typing.Optional[str] = OMIT,
- totp_url: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- browser_profile_id: typing.Optional[str] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- max_screenshot_scrolling_times: typing.Optional[int] = OMIT,
- download_suffix: typing.Optional[str] = OMIT,
- download_timeout: typing.Optional[float] = OMIT,
- max_steps_per_run: typing.Optional[int] = OMIT,
+ totp_identifier: str,
+ content: str,
+ task_id: typing.Optional[str] = OMIT,
+ workflow_id: typing.Optional[str] = OMIT,
+ workflow_run_id: typing.Optional[str] = OMIT,
+ source: typing.Optional[str] = OMIT,
+ expired_at: typing.Optional[dt.datetime] = OMIT,
+ type: typing.Optional[OtpType] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> WorkflowRunResponse:
+ ) -> TotpCode:
"""
- Download a file from a website by navigating and clicking download buttons
+ Forward a TOTP (2FA, MFA) email or sms message containing the code to Skyvern. This endpoint stores the code in database so that Skyvern can use it while running tasks/workflows.
Parameters
----------
- navigation_goal : str
- Instructions for navigating to and downloading the file
-
- user_agent : typing.Optional[str]
-
- url : typing.Optional[str]
- Website URL
-
- webhook_url : typing.Optional[str]
- Webhook URL to send status updates
-
- proxy_location : typing.Optional[ProxyLocation]
- Proxy location to use
-
- totp_identifier : typing.Optional[str]
- Identifier for TOTP (Time-based One-Time Password) if required
-
- totp_url : typing.Optional[str]
- TOTP URL to fetch one-time passwords
-
- browser_session_id : typing.Optional[str]
- ID of the browser session to use, which is prefixed by `pbs_` e.g. `pbs_123456`
-
- browser_profile_id : typing.Optional[str]
- ID of a browser profile to reuse for this run
+ totp_identifier : str
+ The identifier of the TOTP code. It can be the email address, phone number, or the identifier of the user.
- browser_address : typing.Optional[str]
- The CDP address for the task.
+ content : str
+ The content of the TOTP code. It can be the email content that contains the TOTP code, or the sms message that contains the TOTP code. Skyvern will automatically extract the TOTP code from the content.
- extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- Additional HTTP headers to include in requests
+ task_id : typing.Optional[str]
+ The task_id the totp code is for. It can be the task_id of the task that the TOTP code is for.
- cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Never forwarded to target websites.
+ workflow_id : typing.Optional[str]
+ The workflow ID the TOTP code is for. It can be the workflow ID of the workflow that the TOTP code is for.
- max_screenshot_scrolling_times : typing.Optional[int]
- Maximum number of times to scroll for screenshots
+ workflow_run_id : typing.Optional[str]
+ The workflow run id that the TOTP code is for. It can be the workflow run id of the workflow run that the TOTP code is for.
- download_suffix : typing.Optional[str]
- Suffix or complete filename for the downloaded file
+ source : typing.Optional[str]
+ An optional field. The source of the TOTP code. e.g. email, sms, etc.
- download_timeout : typing.Optional[float]
- Timeout in seconds for the download operation
+ expired_at : typing.Optional[dt.datetime]
+ The timestamp when the TOTP code expires
- max_steps_per_run : typing.Optional[int]
- Maximum number of steps to execute
+ type : typing.Optional[OtpType]
+ Optional. If provided, forces extraction of this specific OTP type (totp or magic_link). Use this when the content contains multiple OTP types and you want to specify which one to extract.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- WorkflowRunResponse
+ TotpCode
Successful Response
Examples
@@ -2502,41 +2399,36 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.download_files(
- user_agent="x-user-agent",
- navigation_goal="navigation_goal",
+ client.send_totp_code(
+ totp_identifier="[email protected]",
+ content="Hello, your verification code is 123456",
)
"""
- _response = self._raw_client.download_files(
- navigation_goal=navigation_goal,
- user_agent=user_agent,
- url=url,
- webhook_url=webhook_url,
- proxy_location=proxy_location,
+ _response = self._raw_client.send_totp_code(
totp_identifier=totp_identifier,
- totp_url=totp_url,
- browser_session_id=browser_session_id,
- browser_profile_id=browser_profile_id,
- browser_address=browser_address,
- extra_http_headers=extra_http_headers,
- cdp_connect_headers=cdp_connect_headers,
- max_screenshot_scrolling_times=max_screenshot_scrolling_times,
- download_suffix=download_suffix,
- download_timeout=download_timeout,
- max_steps_per_run=max_steps_per_run,
+ content=content,
+ task_id=task_id,
+ workflow_id=workflow_id,
+ workflow_run_id=workflow_run_id,
+ source=source,
+ expired_at=expired_at,
+ type=type,
request_options=request_options,
)
return _response.data
- def get_scripts(
+ def get_credentials(
self,
*,
page: typing.Optional[int] = None,
page_size: typing.Optional[int] = None,
+ vault_type: typing.Optional[CredentialVaultType] = None,
+ credential_type: typing.Optional[SkyvernForgeSdkSchemasCredentialsCredentialType] = None,
+ search: typing.Optional[str] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[Script]:
+ ) -> typing.List[CredentialResponse]:
"""
- Retrieves a paginated list of scripts for the current organization
+ Retrieves a paginated list of credentials for the current organization
Parameters
----------
@@ -2546,12 +2438,21 @@ class Skyvern:
page_size : typing.Optional[int]
Number of items per page
+ vault_type : typing.Optional[CredentialVaultType]
+ Filter credentials by vault type (e.g. 'skyvern', 'custom', 'bitwarden', 'azure_vault')
+
+ credential_type : typing.Optional[SkyvernForgeSdkSchemasCredentialsCredentialType]
+ Filter credentials by type (e.g. 'password', 'credit_card', 'secret')
+
+ search : typing.Optional[str]
+ Case-insensitive search across credential name, username, secret label, and card details
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[Script]
+ typing.List[CredentialResponse]
Successful Response
Examples
@@ -2561,220 +2462,254 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_scripts(
+ client.get_credentials(
page=1,
page_size=10,
+ vault_type="skyvern",
+ credential_type="password",
+ search="search",
)
"""
- _response = self._raw_client.get_scripts(page=page, page_size=page_size, request_options=request_options)
+ _response = self._raw_client.get_credentials(
+ page=page,
+ page_size=page_size,
+ vault_type=vault_type,
+ credential_type=credential_type,
+ search=search,
+ request_options=request_options,
+ )
return _response.data
- def create_script(
+ def create_credential(
self,
*,
- workflow_id: typing.Optional[str] = OMIT,
- run_id: typing.Optional[str] = OMIT,
- files: typing.Optional[typing.Sequence[ScriptFileCreate]] = OMIT,
+ name: str,
+ credential_type: SkyvernForgeSdkSchemasCredentialsCredentialType,
+ credential: CreateCredentialRequestCredential,
+ vault_type: typing.Optional[CredentialVaultType] = OMIT,
+ proxy_location: typing.Optional[CreateCredentialRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
+ rotate_proxy_session_id: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> CreateScriptResponse:
+ ) -> CredentialResponse:
"""
- Create a new script with optional files and metadata
+ Creates a new credential for the current organization
Parameters
----------
- workflow_id : typing.Optional[str]
- Associated workflow ID
+ name : str
+ Name of the credential
- run_id : typing.Optional[str]
- Associated run ID
+ credential_type : SkyvernForgeSdkSchemasCredentialsCredentialType
+ Type of credential to create
- files : typing.Optional[typing.Sequence[ScriptFileCreate]]
- Array of files to include in the script
+ credential : CreateCredentialRequestCredential
+ The credential data to store
+
+ vault_type : typing.Optional[CredentialVaultType]
+ Which vault to store this credential in. If omitted, uses the instance default. Use this to mix Skyvern-hosted and custom credentials within the same organization.
+
+ proxy_location : typing.Optional[CreateCredentialRequestProxyLocation]
+ Optional proxy location for this credential's pinned proxy identity.
+
+ proxy_session_id : typing.Optional[str]
+ Optional advanced reuse key for this credential's pinned proxy identity.
+
+ rotate_proxy_session_id : typing.Optional[bool]
+ Rotate the Skyvern-managed proxy sticky-session id when updating this credential.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- CreateScriptResponse
+ CredentialResponse
Successful Response
Examples
--------
- from skyvern import Skyvern
+ from skyvern import NonEmptyPasswordCredential, Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.create_script()
+ client.create_credential(
+ name="Amazon Login",
+ credential_type="password",
+ credential=NonEmptyPasswordCredential(
+ password="securepassword123",
+ username="[email protected]",
+ ),
+ )
"""
- _response = self._raw_client.create_script(
- workflow_id=workflow_id, run_id=run_id, files=files, request_options=request_options
+ _response = self._raw_client.create_credential(
+ name=name,
+ credential_type=credential_type,
+ credential=credential,
+ vault_type=vault_type,
+ proxy_location=proxy_location,
+ proxy_session_id=proxy_session_id,
+ rotate_proxy_session_id=rotate_proxy_session_id,
+ request_options=request_options,
)
return _response.data
- def get_script(self, script_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> Script:
+ def update_credential(
+ self,
+ credential_id: str,
+ *,
+ name: str,
+ credential_type: SkyvernForgeSdkSchemasCredentialsCredentialType,
+ credential: CreateCredentialRequestCredential,
+ vault_type: typing.Optional[CredentialVaultType] = OMIT,
+ proxy_location: typing.Optional[CreateCredentialRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
+ rotate_proxy_session_id: typing.Optional[bool] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> CredentialResponse:
"""
- Retrieves a specific script by its ID
+ Overwrites the stored credential data (e.g. username/password) while keeping the same credential_id.
Parameters
----------
- script_id : str
- The unique identifier of the script
+ credential_id : str
+ The unique identifier of the credential to update
+
+ name : str
+ Name of the credential
+
+ credential_type : SkyvernForgeSdkSchemasCredentialsCredentialType
+ Type of credential to create
+
+ credential : CreateCredentialRequestCredential
+ The credential data to store
+
+ vault_type : typing.Optional[CredentialVaultType]
+ Which vault to store this credential in. If omitted, uses the instance default. Use this to mix Skyvern-hosted and custom credentials within the same organization.
+
+ proxy_location : typing.Optional[CreateCredentialRequestProxyLocation]
+ Optional proxy location for this credential's pinned proxy identity.
+
+ proxy_session_id : typing.Optional[str]
+ Optional advanced reuse key for this credential's pinned proxy identity.
+
+ rotate_proxy_session_id : typing.Optional[bool]
+ Rotate the Skyvern-managed proxy sticky-session id when updating this credential.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Script
+ CredentialResponse
Successful Response
Examples
--------
- from skyvern import Skyvern
+ from skyvern import NonEmptyPasswordCredential, Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_script(
- script_id="s_abc123",
+ client.update_credential(
+ credential_id="cred_1234567890",
+ name="Amazon Login",
+ credential_type="password",
+ credential=NonEmptyPasswordCredential(
+ password="securepassword123",
+ username="[email protected]",
+ ),
)
"""
- _response = self._raw_client.get_script(script_id, request_options=request_options)
+ _response = self._raw_client.update_credential(
+ credential_id,
+ name=name,
+ credential_type=credential_type,
+ credential=credential,
+ vault_type=vault_type,
+ proxy_location=proxy_location,
+ proxy_session_id=proxy_session_id,
+ rotate_proxy_session_id=rotate_proxy_session_id,
+ request_options=request_options,
+ )
return _response.data
- def deploy_script(
- self,
- script_id: str,
- *,
- files: typing.Sequence[ScriptFileCreate],
- request_options: typing.Optional[RequestOptions] = None,
- ) -> CreateScriptResponse:
+ def delete_credential(self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None:
"""
- Deploy a script with updated files, creating a new version
+ Deletes a specific credential by its ID
Parameters
----------
- script_id : str
- The unique identifier of the script
-
- files : typing.Sequence[ScriptFileCreate]
- Array of files to include in the script
+ credential_id : str
+ The unique identifier of the credential to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- CreateScriptResponse
- Successful Response
+ None
Examples
--------
- from skyvern import ScriptFileCreate, Skyvern
+ from skyvern import Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.deploy_script(
- script_id="s_abc123",
- files=[
- ScriptFileCreate(
- path="src/main.py",
- content="content",
- )
- ],
+ client.delete_credential(
+ credential_id="cred_1234567890",
)
"""
- _response = self._raw_client.deploy_script(script_id, files=files, request_options=request_options)
+ _response = self._raw_client.delete_credential(credential_id, request_options=request_options)
return _response.data
- def run_sdk_action(
- self,
- *,
- url: str,
- action: RunSdkActionRequestAction,
- browser_session_id: typing.Optional[str] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- workflow_run_id: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> RunSdkActionResponse:
+ def get_credential(
+ self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> CredentialResponse:
"""
- Execute a single SDK action with the specified parameters
+ Retrieves a specific credential by its ID
Parameters
----------
- url : str
- The URL where the action should be executed
-
- action : RunSdkActionRequestAction
- The action to execute with its specific parameters
-
- browser_session_id : typing.Optional[str]
- The browser session ID
-
- browser_address : typing.Optional[str]
- The browser address
-
- workflow_run_id : typing.Optional[str]
- Optional workflow run ID to continue an existing workflow run
+ credential_id : str
+ The unique identifier of the credential
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- RunSdkActionResponse
+ CredentialResponse
Successful Response
Examples
--------
- from skyvern import RunSdkActionRequestAction_AiAct, Skyvern
+ from skyvern import Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.run_sdk_action(
- url="url",
- action=RunSdkActionRequestAction_AiAct(),
- )
- """
- _response = self._raw_client.run_sdk_action(
- url=url,
- action=action,
- browser_session_id=browser_session_id,
- browser_address=browser_address,
- workflow_run_id=workflow_run_id,
- request_options=request_options,
+ client.get_credential(
+ credential_id="cred_1234567890",
)
+ """
+ _response = self._raw_client.get_credential(credential_id, request_options=request_options)
return _response.data
- def update_workflow_folder(
- self,
- workflow_permanent_id: str,
- *,
- folder_id: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> Workflow:
+ def list_custom_llms(self, *, request_options: typing.Optional[RequestOptions] = None) -> CustomLlmListResponse:
"""
- Update a workflow's folder assignment for the latest version
+ List the custom LLM configurations available to the current organization.
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
-
- folder_id : typing.Optional[str]
- Folder ID to assign workflow to. Set to null to remove from folder.
-
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Workflow
- Successfully updated workflow folder
+ CustomLlmListResponse
+ Successful Response
Examples
--------
@@ -2783,115 +2718,105 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.update_workflow_folder(
- workflow_permanent_id="wpid_123",
- )
+ client.list_custom_llms()
"""
- _response = self._raw_client.update_workflow_folder(
- workflow_permanent_id, folder_id=folder_id, request_options=request_options
- )
+ _response = self._raw_client.list_custom_llms(request_options=request_options)
return _response.data
- def get_workflow_tags(
- self, workflow_permanent_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> TagsResponse:
+ def create_custom_llm(
+ self, *, config: CustomLlmConfig, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomLlmResponse:
"""
- Get the current tag state for a workflow.
+ Create a custom LLM configuration for the current organization.
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
+ config : CustomLlmConfig
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TagsResponse
- Successfully retrieved tags
+ CustomLlmResponse
+ Successful Response
Examples
--------
- from skyvern import Skyvern
+ from skyvern import CustomLlmConfig, Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_workflow_tags(
- workflow_permanent_id="wpid_123",
+ client.create_custom_llm(
+ config=CustomLlmConfig(
+ display_name="display_name",
+ provider="openai_compatible",
+ model_name="model_name",
+ ),
)
"""
- _response = self._raw_client.get_workflow_tags(workflow_permanent_id, request_options=request_options)
+ _response = self._raw_client.create_custom_llm(config=config, request_options=request_options)
return _response.data
- def apply_workflow_tags(
- self,
- workflow_permanent_id: str,
- *,
- tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
- tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> TagsResponse:
+ def update_custom_llm(
+ self, custom_llm_id: str, *, config: CustomLlmConfig, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomLlmResponse:
"""
- Atomically apply tag changes to a workflow. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
+ Update a custom LLM configuration for the current organization.
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
+ custom_llm_id : str
+ The custom LLM id.
- tags : typing.Optional[typing.Sequence[TagInput]]
- Tags to set (overwrite). List of {key?, value} objects.
-
- tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
- Tags to soft-delete. List of {key?, value?} targets.
+ config : CustomLlmConfig
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TagsResponse
- Successfully applied tag changes
+ CustomLlmResponse
+ Successful Response
Examples
--------
- from skyvern import Skyvern
+ from skyvern import CustomLlmConfig, Skyvern
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.apply_workflow_tags(
- workflow_permanent_id="wpid_123",
+ client.update_custom_llm(
+ custom_llm_id="custom_llm_id",
+ config=CustomLlmConfig(
+ display_name="display_name",
+ provider="openai_compatible",
+ model_name="model_name",
+ ),
)
"""
- _response = self._raw_client.apply_workflow_tags(
- workflow_permanent_id, tags=tags, tags_to_delete=tags_to_delete, request_options=request_options
- )
+ _response = self._raw_client.update_custom_llm(custom_llm_id, config=config, request_options=request_options)
return _response.data
- def delete_workflow_tag(
- self, workflow_permanent_id: str, key: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> TagsResponse:
+ def delete_custom_llm(
+ self, custom_llm_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> ClearOrganizationAuthTokenResponse:
"""
- Soft-delete a single tag from a workflow. Writes a DELETE event row.
+ Delete a custom LLM configuration for the current organization.
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
-
- key : str
- Tag key to delete
+ custom_llm_id : str
+ The custom LLM id.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TagsResponse
- Successfully deleted tag (or no-op if absent)
+ ClearOrganizationAuthTokenResponse
+ Successful Response
Examples
--------
@@ -2900,90 +2825,113 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.delete_workflow_tag(
- workflow_permanent_id="wpid_123",
- key="env",
+ client.delete_custom_llm(
+ custom_llm_id="custom_llm_id",
)
"""
- _response = self._raw_client.delete_workflow_tag(workflow_permanent_id, key, request_options=request_options)
+ _response = self._raw_client.delete_custom_llm(custom_llm_id, request_options=request_options)
return _response.data
- def get_workflow_tag_history(
+ def login(
self,
- workflow_permanent_id: str,
*,
- limit: typing.Optional[int] = None,
- since: typing.Optional[dt.datetime] = None,
- key: typing.Optional[str] = None,
+ credential_type: SkyvernSchemasCredentialTypeCredentialType,
+ user_agent: typing.Optional[str] = None,
+ url: typing.Optional[str] = OMIT,
+ webhook_url: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[ProxyLocation] = OMIT,
+ totp_identifier: typing.Optional[str] = OMIT,
+ totp_url: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ browser_profile_id: typing.Optional[str] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ max_screenshot_scrolling_times: typing.Optional[int] = OMIT,
+ prompt: typing.Optional[str] = OMIT,
+ credential_id: typing.Optional[str] = OMIT,
+ bitwarden_collection_id: typing.Optional[str] = OMIT,
+ bitwarden_item_id: typing.Optional[str] = OMIT,
+ onepassword_vault_id: typing.Optional[str] = OMIT,
+ onepassword_item_id: typing.Optional[str] = OMIT,
+ azure_vault_name: typing.Optional[str] = OMIT,
+ azure_vault_username_key: typing.Optional[str] = OMIT,
+ azure_vault_password_key: typing.Optional[str] = OMIT,
+ azure_vault_totp_secret_key: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> TagHistoryResponse:
+ ) -> WorkflowRunResponse:
"""
- Chronological tag-event log for a workflow (newest first). Includes SET and DELETE events.
+ Log in to a website using either credential stored in Skyvern, Bitwarden, 1Password, or Azure Vault
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
+ credential_type : SkyvernSchemasCredentialTypeCredentialType
+ Where to get the credential from
- limit : typing.Optional[int]
- Max events to return
+ user_agent : typing.Optional[str]
- since : typing.Optional[dt.datetime]
- Only return events at or after this timestamp
+ url : typing.Optional[str]
+ Website URL
- key : typing.Optional[str]
- Filter to events for a single tag key
+ webhook_url : typing.Optional[str]
+ Webhook URL to send status updates
- request_options : typing.Optional[RequestOptions]
- Request-specific configuration.
+ proxy_location : typing.Optional[ProxyLocation]
+ Proxy location to use
- Returns
- -------
- TagHistoryResponse
- Successfully retrieved tag history
+ totp_identifier : typing.Optional[str]
+ Identifier for TOTP (Time-based One-Time Password) if required
- Examples
- --------
- import datetime
+ totp_url : typing.Optional[str]
+ TOTP URL to fetch one-time passwords
- from skyvern import Skyvern
+ browser_session_id : typing.Optional[str]
+ ID of the browser session to use, which is prefixed by `pbs_` e.g. `pbs_123456`
- client = Skyvern(
- api_key="YOUR_API_KEY",
- )
- client.get_workflow_tag_history(
- workflow_permanent_id="wpid_123",
- limit=1,
- since=datetime.datetime.fromisoformat(
- "2024-01-15 09:30:00+00:00",
- ),
- key="key",
- )
- """
- _response = self._raw_client.get_workflow_tag_history(
- workflow_permanent_id, limit=limit, since=since, key=key, request_options=request_options
- )
- return _response.data
+ browser_profile_id : typing.Optional[str]
+ ID of a browser profile to reuse for this run
- def retry_workflow_run(
- self,
- workflow_run_id: str,
- *,
- max_steps_override: typing.Optional[int] = None,
- user_agent: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> WorkflowRunResponse:
- """
- Retry a workflow run using the original run parameters.
+ browser_address : typing.Optional[str]
+ The CDP address for the task.
- Parameters
- ----------
- workflow_run_id : str
- The id of the workflow run to retry.
+ extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Additional HTTP headers to include in requests
- max_steps_override : typing.Optional[int]
+ cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Never forwarded to target websites.
- user_agent : typing.Optional[str]
+ max_screenshot_scrolling_times : typing.Optional[int]
+ Maximum number of times to scroll for screenshots
+
+ prompt : typing.Optional[str]
+ Login instructions. Skyvern has default prompt/instruction for login if this field is not provided.
+
+ credential_id : typing.Optional[str]
+ ID of the Skyvern credential to use for login.
+
+ bitwarden_collection_id : typing.Optional[str]
+ Bitwarden collection ID. You can find it in the Bitwarden collection URL. e.g. `https://vault.bitwarden.com/vaults/collection_id/items`
+
+ bitwarden_item_id : typing.Optional[str]
+ Bitwarden item ID
+
+ onepassword_vault_id : typing.Optional[str]
+ 1Password vault ID
+
+ onepassword_item_id : typing.Optional[str]
+ 1Password item ID
+
+ azure_vault_name : typing.Optional[str]
+ Azure Vault Name
+
+ azure_vault_username_key : typing.Optional[str]
+ Azure Vault username key
+
+ azure_vault_password_key : typing.Optional[str]
+ Azure Vault password key
+
+ azure_vault_totp_secret_key : typing.Optional[str]
+ Azure Vault TOTP secret key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -2991,7 +2939,7 @@ class Skyvern:
Returns
-------
WorkflowRunResponse
- Successfully retried workflow run
+ Successful Response
Examples
--------
@@ -3000,83 +2948,118 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.retry_workflow_run(
- workflow_run_id="wr_123",
- max_steps_override=1,
+ client.login(
user_agent="x-user-agent",
+ credential_type="skyvern",
)
"""
- _response = self._raw_client.retry_workflow_run(
- workflow_run_id,
- max_steps_override=max_steps_override,
+ _response = self._raw_client.login(
+ credential_type=credential_type,
user_agent=user_agent,
- request_options=request_options,
- )
- return _response.data
-
- def get_workflow_runs(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
- search_key: typing.Optional[str] = None,
- error_code: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[WorkflowRun]:
- """
- List workflow runs across all workflows for the current organization.
+ url=url,
+ webhook_url=webhook_url,
+ proxy_location=proxy_location,
+ totp_identifier=totp_identifier,
+ totp_url=totp_url,
+ browser_session_id=browser_session_id,
+ browser_profile_id=browser_profile_id,
+ browser_address=browser_address,
+ extra_http_headers=extra_http_headers,
+ cdp_connect_headers=cdp_connect_headers,
+ max_screenshot_scrolling_times=max_screenshot_scrolling_times,
+ prompt=prompt,
+ credential_id=credential_id,
+ bitwarden_collection_id=bitwarden_collection_id,
+ bitwarden_item_id=bitwarden_item_id,
+ onepassword_vault_id=onepassword_vault_id,
+ onepassword_item_id=onepassword_item_id,
+ azure_vault_name=azure_vault_name,
+ azure_vault_username_key=azure_vault_username_key,
+ azure_vault_password_key=azure_vault_password_key,
+ azure_vault_totp_secret_key=azure_vault_totp_secret_key,
+ request_options=request_options,
+ )
+ return _response.data
- Results are paginated and can be filtered by **status**, **search_key**, and **error_code**. All filters are combined with **AND** logic — a run must match every supplied filter to be returned.
+ def download_files(
+ self,
+ *,
+ navigation_goal: str,
+ user_agent: typing.Optional[str] = None,
+ url: typing.Optional[str] = OMIT,
+ webhook_url: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[ProxyLocation] = OMIT,
+ totp_identifier: typing.Optional[str] = OMIT,
+ totp_url: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ browser_profile_id: typing.Optional[str] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ max_screenshot_scrolling_times: typing.Optional[int] = OMIT,
+ download_suffix: typing.Optional[str] = OMIT,
+ download_timeout: typing.Optional[float] = OMIT,
+ max_steps_per_run: typing.Optional[int] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> WorkflowRunResponse:
+ """
+ Download a file from a website by navigating and clicking download buttons
- ### search_key
+ Parameters
+ ----------
+ navigation_goal : str
+ Instructions for navigating to and downloading the file
- A case-insensitive substring search that matches against **any** of the following fields:
+ user_agent : typing.Optional[str]
- | Searched field | Description |
- |---|---|
- | `workflow_run_id` | The unique run identifier (e.g. `wr_123…`) |
- | Parameter **key** | The `key` of any workflow parameter definition associated with the run |
- | Parameter **description** | The `description` of any workflow parameter definition |
- | Run parameter **value** | The actual value supplied for any parameter when the run was created |
- | `extra_http_headers` | Extra HTTP headers attached to the run (searched as raw JSON text) |
+ url : typing.Optional[str]
+ Website URL
- Soft-deleted parameter definitions are excluded from key/description matching. A run is returned if **any** of the fields above contain the search term.
+ webhook_url : typing.Optional[str]
+ Webhook URL to send status updates
- ### error_code
+ proxy_location : typing.Optional[ProxyLocation]
+ Proxy location to use
- An **exact-match** filter against the `error_code` field inside each task's `errors` JSON array. A run matches if **any** of its tasks contains an error object with a matching `error_code` value. Error codes are user-defined strings set during workflow execution (e.g. `INVALID_CREDENTIALS`, `LOGIN_FAILED`, `CAPTCHA_DETECTED`).
+ totp_identifier : typing.Optional[str]
+ Identifier for TOTP (Time-based One-Time Password) if required
- ### Combining filters
+ totp_url : typing.Optional[str]
+ TOTP URL to fetch one-time passwords
- All query parameters use AND logic:
- - `?status=failed` — only failed runs
- - `?status=failed&error_code=LOGIN_FAILED` — failed runs **and** have a LOGIN_FAILED error
- - `?status=failed&error_code=LOGIN_FAILED&search_key=prod_credential` — all three conditions must match
+ browser_session_id : typing.Optional[str]
+ ID of the browser session to use, which is prefixed by `pbs_` e.g. `pbs_123456`
- Parameters
- ----------
- page : typing.Optional[int]
- Page number for pagination.
+ browser_profile_id : typing.Optional[str]
+ ID of a browser profile to reuse for this run
- page_size : typing.Optional[int]
- Number of runs to return per page.
+ browser_address : typing.Optional[str]
+ The CDP address for the task.
- status : typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]]
- Filter by one or more run statuses.
+ extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Additional HTTP headers to include in requests
- search_key : typing.Optional[str]
- Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. A run is returned if any of these fields match. Soft-deleted parameter definitions are excluded from key/description matching.
+ cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Never forwarded to target websites.
- error_code : typing.Optional[str]
- Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+ max_screenshot_scrolling_times : typing.Optional[int]
+ Maximum number of times to scroll for screenshots
+
+ download_suffix : typing.Optional[str]
+ Suffix or complete filename for the downloaded file
+
+ download_timeout : typing.Optional[float]
+ Timeout in seconds for the download operation
+
+ max_steps_per_run : typing.Optional[int]
+ Maximum number of steps to execute
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[WorkflowRun]
+ WorkflowRunResponse
Successful Response
Examples
@@ -3086,72 +3069,56 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_workflow_runs(
- page=1,
- page_size=1,
- search_key="search_key",
- error_code="error_code",
+ client.download_files(
+ user_agent="x-user-agent",
+ navigation_goal="navigation_goal",
)
"""
- _response = self._raw_client.get_workflow_runs(
- page=page,
- page_size=page_size,
- status=status,
- search_key=search_key,
- error_code=error_code,
+ _response = self._raw_client.download_files(
+ navigation_goal=navigation_goal,
+ user_agent=user_agent,
+ url=url,
+ webhook_url=webhook_url,
+ proxy_location=proxy_location,
+ totp_identifier=totp_identifier,
+ totp_url=totp_url,
+ browser_session_id=browser_session_id,
+ browser_profile_id=browser_profile_id,
+ browser_address=browser_address,
+ extra_http_headers=extra_http_headers,
+ cdp_connect_headers=cdp_connect_headers,
+ max_screenshot_scrolling_times=max_screenshot_scrolling_times,
+ download_suffix=download_suffix,
+ download_timeout=download_timeout,
+ max_steps_per_run=max_steps_per_run,
request_options=request_options,
)
return _response.data
- def get_workflow_runs_by_id(
+ def get_scripts(
self,
- workflow_id: str,
*,
page: typing.Optional[int] = None,
page_size: typing.Optional[int] = None,
- status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
- search_key: typing.Optional[str] = None,
- error_code: typing.Optional[str] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[WorkflowRun]:
+ ) -> typing.List[Script]:
"""
- List runs for a specific workflow.
-
- Supports filtering by **status**, **search_key**, and **error_code**. All filters are combined with **AND** logic.
-
- ### search_key
-
- Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. Soft-deleted parameter definitions are excluded.
-
- ### error_code
-
- Exact-match filter on the `error_code` field inside each task's `errors` JSON array. A run matches if any of its tasks contains an error with a matching `error_code`.
+ Retrieves a paginated list of scripts for the current organization
Parameters
----------
- workflow_id : str
-
page : typing.Optional[int]
- Page number for pagination.
+ Page number for pagination
page_size : typing.Optional[int]
- Number of runs to return per page.
-
- status : typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]]
- Filter by one or more run statuses.
-
- search_key : typing.Optional[str]
- Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. A run is returned if any of these fields match. Soft-deleted parameter definitions are excluded from key/description matching.
-
- error_code : typing.Optional[str]
- Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+ Number of items per page
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[WorkflowRun]
+ typing.List[Script]
Successful Response
Examples
@@ -3161,48 +3128,42 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_workflow_runs_by_id(
- workflow_id="workflow_id",
+ client.get_scripts(
page=1,
- page_size=1,
- search_key="search_key",
- error_code="error_code",
+ page_size=10,
)
"""
- _response = self._raw_client.get_workflow_runs_by_id(
- workflow_id,
- page=page,
- page_size=page_size,
- status=status,
- search_key=search_key,
- error_code=error_code,
- request_options=request_options,
- )
+ _response = self._raw_client.get_scripts(page=page, page_size=page_size, request_options=request_options)
return _response.data
- def get_workflow(
+ def create_script(
self,
- workflow_permanent_id: str,
*,
- version: typing.Optional[int] = None,
- template: typing.Optional[bool] = None,
+ workflow_id: typing.Optional[str] = OMIT,
+ run_id: typing.Optional[str] = OMIT,
+ files: typing.Optional[typing.Sequence[ScriptFileCreate]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> Workflow:
+ ) -> CreateScriptResponse:
"""
+ Create a new script with optional files and metadata
+
Parameters
----------
- workflow_permanent_id : str
+ workflow_id : typing.Optional[str]
+ Associated workflow ID
- version : typing.Optional[int]
+ run_id : typing.Optional[str]
+ Associated run ID
- template : typing.Optional[bool]
+ files : typing.Optional[typing.Sequence[ScriptFileCreate]]
+ Array of files to include in the script
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Workflow
+ CreateScriptResponse
Successful Response
Examples
@@ -3212,39 +3173,28 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_workflow(
- workflow_permanent_id="workflow_permanent_id",
- version=1,
- template=True,
- )
+ client.create_script()
"""
- _response = self._raw_client.get_workflow(
- workflow_permanent_id, version=version, template=template, request_options=request_options
+ _response = self._raw_client.create_script(
+ workflow_id=workflow_id, run_id=run_id, files=files, request_options=request_options
)
return _response.data
- def get_workflow_versions(
- self,
- workflow_permanent_id: str,
- *,
- template: typing.Optional[bool] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[Workflow]:
+ def get_script(self, script_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> Script:
"""
- Get all versions of a workflow by its permanent ID.
+ Retrieves a specific script by its ID
Parameters
----------
- workflow_permanent_id : str
-
- template : typing.Optional[bool]
+ script_id : str
+ The unique identifier of the script
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[Workflow]
+ Script
Successful Response
Examples
@@ -3254,276 +3204,1456 @@ class Skyvern:
client = Skyvern(
api_key="YOUR_API_KEY",
)
- client.get_workflow_versions(
- workflow_permanent_id="workflow_permanent_id",
- template=True,
+ client.get_script(
+ script_id="s_abc123",
)
"""
- _response = self._raw_client.get_workflow_versions(
+ _response = self._raw_client.get_script(script_id, request_options=request_options)
+ return _response.data
+
+ def deploy_script(
+ self,
+ script_id: str,
+ *,
+ files: typing.Sequence[ScriptFileCreate],
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> CreateScriptResponse:
+ """
+ Deploy a script with updated files, creating a new version
+
+ Parameters
+ ----------
+ script_id : str
+ The unique identifier of the script
+
+ files : typing.Sequence[ScriptFileCreate]
+ Array of files to include in the script
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CreateScriptResponse
+ Successful Response
+
+ Examples
+ --------
+ from skyvern import ScriptFileCreate, Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.deploy_script(
+ script_id="s_abc123",
+ files=[
+ ScriptFileCreate(
+ path="src/main.py",
+ content="content",
+ )
+ ],
+ )
+ """
+ _response = self._raw_client.deploy_script(script_id, files=files, request_options=request_options)
+ return _response.data
+
+ def run_sdk_action(
+ self,
+ *,
+ url: str,
+ action: RunSdkActionRequestAction,
+ browser_session_id: typing.Optional[str] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ workflow_run_id: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> RunSdkActionResponse:
+ """
+ Execute a single SDK action with the specified parameters
+
+ Parameters
+ ----------
+ url : str
+ The URL where the action should be executed
+
+ action : RunSdkActionRequestAction
+ The action to execute with its specific parameters
+
+ browser_session_id : typing.Optional[str]
+ The browser session ID
+
+ browser_address : typing.Optional[str]
+ The browser address
+
+ workflow_run_id : typing.Optional[str]
+ Optional workflow run ID to continue an existing workflow run
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ RunSdkActionResponse
+ Successful Response
+
+ Examples
+ --------
+ from skyvern import RunSdkActionRequestAction_AiAct, Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.run_sdk_action(
+ url="url",
+ action=RunSdkActionRequestAction_AiAct(),
+ )
+ """
+ _response = self._raw_client.run_sdk_action(
+ url=url,
+ action=action,
+ browser_session_id=browser_session_id,
+ browser_address=browser_address,
+ workflow_run_id=workflow_run_id,
+ request_options=request_options,
+ )
+ return _response.data
+
+ def update_workflow_folder(
+ self,
+ workflow_permanent_id: str,
+ *,
+ folder_id: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> Workflow:
+ """
+ Update a workflow's folder assignment for the latest version
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ folder_id : typing.Optional[str]
+ Folder ID to assign workflow to. Set to null to remove from folder.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ Workflow
+ Successfully updated workflow folder
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.update_workflow_folder(
+ workflow_permanent_id="wpid_123",
+ )
+ """
+ _response = self._raw_client.update_workflow_folder(
+ workflow_permanent_id, folder_id=folder_id, request_options=request_options
+ )
+ return _response.data
+
+ def get_workflow_tags(
+ self, workflow_permanent_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagsResponse:
+ """
+ Get the current tag state for a workflow.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ TagsResponse
+ Successfully retrieved tags
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.get_workflow_tags(
+ workflow_permanent_id="wpid_123",
+ )
+ """
+ _response = self._raw_client.get_workflow_tags(workflow_permanent_id, request_options=request_options)
+ return _response.data
+
+ def apply_workflow_tags(
+ self,
+ workflow_permanent_id: str,
+ *,
+ tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
+ tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> TagsResponse:
+ """
+ Atomically apply tag changes to a workflow. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ tags : typing.Optional[typing.Sequence[TagInput]]
+ Tags to set (overwrite). List of {key?, value} objects.
+
+ tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
+ Tags to soft-delete. List of {key?, value?} targets.
+
+ colors : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ TagsResponse
+ Successfully applied tag changes
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.apply_workflow_tags(
+ workflow_permanent_id="wpid_123",
+ )
+ """
+ _response = self._raw_client.apply_workflow_tags(
+ workflow_permanent_id,
+ tags=tags,
+ tags_to_delete=tags_to_delete,
+ colors=colors,
+ request_options=request_options,
+ )
+ return _response.data
+
+ def delete_workflow_tag(
+ self, workflow_permanent_id: str, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagsResponse:
+ """
+ Soft-delete a single tag from a workflow. Writes a DELETE event row.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ key : str
+ Tag key to delete
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ TagsResponse
+ Successfully deleted tag (or no-op if absent)
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.delete_workflow_tag(
+ workflow_permanent_id="wpid_123",
+ key="env",
+ )
+ """
+ _response = self._raw_client.delete_workflow_tag(workflow_permanent_id, key, request_options=request_options)
+ return _response.data
+
+ def get_workflow_tag_history(
+ self,
+ workflow_permanent_id: str,
+ *,
+ limit: typing.Optional[int] = None,
+ since: typing.Optional[dt.datetime] = None,
+ key: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> TagHistoryResponse:
+ """
+ Chronological tag-event log for a workflow (newest first). Includes SET and DELETE events.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ limit : typing.Optional[int]
+ Max events to return
+
+ since : typing.Optional[dt.datetime]
+ Only return events at or after this timestamp
+
+ key : typing.Optional[str]
+ Filter to events for a single tag key
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ TagHistoryResponse
+ Successfully retrieved tag history
+
+ Examples
+ --------
+ import datetime
+
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.get_workflow_tag_history(
+ workflow_permanent_id="wpid_123",
+ limit=1,
+ since=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+ key="key",
+ )
+ """
+ _response = self._raw_client.get_workflow_tag_history(
+ workflow_permanent_id, limit=limit, since=since, key=key, request_options=request_options
+ )
+ return _response.data
+
+ def retry_workflow_run(
+ self,
+ workflow_run_id: str,
+ *,
+ max_steps_override: typing.Optional[int] = None,
+ user_agent: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> WorkflowRunResponse:
+ """
+ Retry a workflow run using the original run parameters.
+
+ Parameters
+ ----------
+ workflow_run_id : str
+ The id of the workflow run to retry.
+
+ max_steps_override : typing.Optional[int]
+
+ user_agent : typing.Optional[str]
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ WorkflowRunResponse
+ Successfully retried workflow run
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.retry_workflow_run(
+ workflow_run_id="wr_123",
+ max_steps_override=1,
+ user_agent="x-user-agent",
+ )
+ """
+ _response = self._raw_client.retry_workflow_run(
+ workflow_run_id,
+ max_steps_override=max_steps_override,
+ user_agent=user_agent,
+ request_options=request_options,
+ )
+ return _response.data
+
+ def get_workflow_runs(
+ self,
+ *,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
+ search_key: typing.Optional[str] = None,
+ error_code: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> typing.List[WorkflowRun]:
+ """
+ List workflow runs across all workflows for the current organization.
+
+ Results are paginated and can be filtered by **status**, **search_key**, and **error_code**. All filters are combined with **AND** logic — a run must match every supplied filter to be returned.
+
+ ### search_key
+
+ A case-insensitive substring search that matches against **any** of the following fields:
+
+ | Searched field | Description |
+ |---|---|
+ | `workflow_run_id` | The unique run identifier (e.g. `wr_123…`) |
+ | Parameter **key** | The `key` of any workflow parameter definition associated with the run |
+ | Parameter **description** | The `description` of any workflow parameter definition |
+ | Run parameter **value** | The actual value supplied for any parameter when the run was created |
+ | `extra_http_headers` | Extra HTTP headers attached to the run (searched as raw JSON text) |
+
+ Soft-deleted parameter definitions are excluded from key/description matching. A run is returned if **any** of the fields above contain the search term.
+
+ ### error_code
+
+ An **exact-match** filter against the `error_code` field inside each task's `errors` JSON array. A run matches if **any** of its tasks contains an error object with a matching `error_code` value. Error codes are user-defined strings set during workflow execution (e.g. `INVALID_CREDENTIALS`, `LOGIN_FAILED`, `CAPTCHA_DETECTED`).
+
+ ### Combining filters
+
+ All query parameters use AND logic:
+ - `?status=failed` — only failed runs
+ - `?status=failed&error_code=LOGIN_FAILED` — failed runs **and** have a LOGIN_FAILED error
+ - `?status=failed&error_code=LOGIN_FAILED&search_key=prod_credential` — all three conditions must match
+
+ Parameters
+ ----------
+ page : typing.Optional[int]
+ Page number for pagination.
+
+ page_size : typing.Optional[int]
+ Number of runs to return per page.
+
+ status : typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]]
+ Filter by one or more run statuses.
+
+ search_key : typing.Optional[str]
+ Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. A run is returned if any of these fields match. Soft-deleted parameter definitions are excluded from key/description matching.
+
+ error_code : typing.Optional[str]
+ Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.List[WorkflowRun]
+ Successful Response
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.get_workflow_runs(
+ page=1,
+ page_size=1,
+ search_key="search_key",
+ error_code="error_code",
+ )
+ """
+ _response = self._raw_client.get_workflow_runs(
+ page=page,
+ page_size=page_size,
+ status=status,
+ search_key=search_key,
+ error_code=error_code,
+ request_options=request_options,
+ )
+ return _response.data
+
+ def get_workflow_runs_by_id(
+ self,
+ workflow_id: str,
+ *,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
+ search_key: typing.Optional[str] = None,
+ error_code: typing.Optional[str] = None,
+ created_at_start: typing.Optional[dt.datetime] = None,
+ created_at_end: typing.Optional[dt.datetime] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> typing.List[WorkflowRun]:
+ """
+ List runs for a specific workflow.
+
+ Supports filtering by **status**, **search_key**, and **error_code**. All filters are combined with **AND** logic.
+
+ ### search_key
+
+ Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. Soft-deleted parameter definitions are excluded.
+
+ ### error_code
+
+ Exact-match filter on the `error_code` field inside each task's `errors` JSON array. A run matches if any of its tasks contains an error with a matching `error_code`.
+
+ Parameters
+ ----------
+ workflow_id : str
+
+ page : typing.Optional[int]
+ Page number for pagination.
+
+ page_size : typing.Optional[int]
+ Number of runs to return per page.
+
+ status : typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]]
+ Filter by one or more run statuses.
+
+ search_key : typing.Optional[str]
+ Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. A run is returned if any of these fields match. Soft-deleted parameter definitions are excluded from key/description matching.
+
+ error_code : typing.Optional[str]
+ Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+
+ created_at_start : typing.Optional[dt.datetime]
+ Only include runs created at or after this UTC timestamp (ISO 8601).
+
+ created_at_end : typing.Optional[dt.datetime]
+ Only include runs created strictly before this UTC timestamp (ISO 8601).
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.List[WorkflowRun]
+ Successful Response
+
+ Examples
+ --------
+ import datetime
+
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.get_workflow_runs_by_id(
+ workflow_id="workflow_id",
+ page=1,
+ page_size=1,
+ search_key="search_key",
+ error_code="error_code",
+ created_at_start=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+ created_at_end=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+ )
+ """
+ _response = self._raw_client.get_workflow_runs_by_id(
+ workflow_id,
+ page=page,
+ page_size=page_size,
+ status=status,
+ search_key=search_key,
+ error_code=error_code,
+ created_at_start=created_at_start,
+ created_at_end=created_at_end,
+ request_options=request_options,
+ )
+ return _response.data
+
+ def get_workflow(
+ self,
+ workflow_permanent_id: str,
+ *,
+ version: typing.Optional[int] = None,
+ template: typing.Optional[bool] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> Workflow:
+ """
+ Parameters
+ ----------
+ workflow_permanent_id : str
+
+ version : typing.Optional[int]
+
+ template : typing.Optional[bool]
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ Workflow
+ Successful Response
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.get_workflow(
+ workflow_permanent_id="workflow_permanent_id",
+ version=1,
+ template=True,
+ )
+ """
+ _response = self._raw_client.get_workflow(
+ workflow_permanent_id, version=version, template=template, request_options=request_options
+ )
+ return _response.data
+
+ def get_workflow_versions(
+ self,
+ workflow_permanent_id: str,
+ *,
+ template: typing.Optional[bool] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> typing.List[Workflow]:
+ """
+ Get all versions of a workflow by its permanent ID.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+
+ template : typing.Optional[bool]
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.List[Workflow]
+ Successful Response
+
+ Examples
+ --------
+ from skyvern import Skyvern
+
+ client = Skyvern(
+ api_key="YOUR_API_KEY",
+ )
+ client.get_workflow_versions(
+ workflow_permanent_id="workflow_permanent_id",
+ template=True,
+ )
+ """
+ _response = self._raw_client.get_workflow_versions(
workflow_permanent_id, template=template, request_options=request_options
)
return _response.data
- @property
- def artifacts(self):
- if self._artifacts is None:
- from .artifacts.client import ArtifactsClient # noqa: E402
+ @property
+ def artifacts(self):
+ if self._artifacts is None:
+ from .artifacts.client import ArtifactsClient # noqa: E402
+
+ self._artifacts = ArtifactsClient(client_wrapper=self._client_wrapper)
+ return self._artifacts
+
+ @property
+ def scripts(self):
+ if self._scripts is None:
+ from .scripts.client import ScriptsClient # noqa: E402
+
+ self._scripts = ScriptsClient(client_wrapper=self._client_wrapper)
+ return self._scripts
+
+ @property
+ def schedules(self):
+ if self._schedules is None:
+ from .schedules.client import SchedulesClient # noqa: E402
+
+ self._schedules = SchedulesClient(client_wrapper=self._client_wrapper)
+ return self._schedules
+
+ @property
+ def agents(self):
+ if self._agents is None:
+ from .agents.client import AgentsClient # noqa: E402
+
+ self._agents = AgentsClient(client_wrapper=self._client_wrapper)
+ return self._agents
+
+
+class AsyncSkyvern:
+ """
+ Use this class to access the different functions within the SDK. You can instantiate any number of clients with different configuration that will propagate to these functions.
+
+ Parameters
+ ----------
+ base_url : typing.Optional[str]
+ The base url to use for requests from the client.
+
+ environment : SkyvernEnvironment
+ The environment to use for requests from the client. from .environment import SkyvernEnvironment
+
+
+
+ Defaults to SkyvernEnvironment.CLOUD
+
+
+
+ api_key : typing.Optional[str]
+ headers : typing.Optional[typing.Dict[str, str]]
+ Additional headers to send with every request.
+
+ timeout : typing.Optional[float]
+ The timeout to be used, in seconds, for requests. By default the timeout is 60 seconds, unless a custom httpx client is used, in which case this default is not enforced.
+
+ follow_redirects : typing.Optional[bool]
+ Whether the default httpx client follows redirects or not, this is irrelevant if a custom httpx client is passed in.
+
+ httpx_client : typing.Optional[httpx.AsyncClient]
+ The httpx client to use for making requests, a preconfigured client is used by default, however this is useful should you want to pass in any custom httpx configuration.
+
+ Examples
+ --------
+ from skyvern import AsyncSkyvern
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
+ """
+
+ def __init__(
+ self,
+ *,
+ base_url: typing.Optional[str] = None,
+ environment: SkyvernEnvironment = SkyvernEnvironment.CLOUD,
+ api_key: typing.Optional[str] = None,
+ headers: typing.Optional[typing.Dict[str, str]] = None,
+ timeout: typing.Optional[float] = None,
+ follow_redirects: typing.Optional[bool] = True,
+ httpx_client: typing.Optional[httpx.AsyncClient] = None,
+ ):
+ _defaulted_timeout = (
+ timeout if timeout is not None else 60 if httpx_client is None else httpx_client.timeout.read
+ )
+ self._client_wrapper = AsyncClientWrapper(
+ base_url=_get_base_url(base_url=base_url, environment=environment),
+ api_key=api_key,
+ headers=headers,
+ httpx_client=httpx_client
+ if httpx_client is not None
+ else httpx.AsyncClient(timeout=_defaulted_timeout, follow_redirects=follow_redirects)
+ if follow_redirects is not None
+ else httpx.AsyncClient(timeout=_defaulted_timeout),
+ timeout=_defaulted_timeout,
+ )
+ self._raw_client = AsyncRawSkyvern(client_wrapper=self._client_wrapper)
+ self._artifacts: typing.Optional[AsyncArtifactsClient] = None
+ self._scripts: typing.Optional[AsyncScriptsClient] = None
+ self._schedules: typing.Optional[AsyncSchedulesClient] = None
+ self._agents: typing.Optional[AsyncAgentsClient] = None
+
+ @property
+ def with_raw_response(self) -> AsyncRawSkyvern:
+ """
+ Retrieves a raw implementation of this client that returns raw responses.
+
+ Returns
+ -------
+ AsyncRawSkyvern
+ """
+ return self._raw_client
+
+ async def run_task(
+ self,
+ *,
+ prompt: str,
+ user_agent: typing.Optional[str] = None,
+ url: typing.Optional[str] = OMIT,
+ engine: typing.Optional[RunEngine] = OMIT,
+ title: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[TaskRunRequestInputProxyLocation] = OMIT,
+ data_extraction_schema: typing.Optional[TaskRunRequestInputDataExtractionSchema] = OMIT,
+ error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ max_steps: typing.Optional[int] = OMIT,
+ webhook_url: typing.Optional[str] = OMIT,
+ totp_identifier: typing.Optional[str] = OMIT,
+ totp_url: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
+ extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ publish_workflow: typing.Optional[bool] = OMIT,
+ include_action_history_in_verification: typing.Optional[bool] = OMIT,
+ max_screenshot_scrolls: typing.Optional[int] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ run_with: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> TaskRunResponse:
+ """
+ Run a task
+
+ Parameters
+ ----------
+ prompt : str
+
+ The goal or task description for Skyvern to accomplish
+
+ user_agent : typing.Optional[str]
+
+ url : typing.Optional[str]
+
+ The starting URL for the task. If not provided, Skyvern will attempt to determine an appropriate URL
+
+ engine : typing.Optional[RunEngine]
+
+ The engine that powers the agent task. The default value is `skyvern-1.0`, which is good for simple tasks like filling a form, or searching for information on Google. `skyvern-2.0` remains available for existing V2 workflows and explicitly requested V2 task runs. The `openai-cua` engine uses OpenAI's CUA model. The `anthropic-cua` uses Anthropic's Claude Sonnet 3.7 model with the computer use tool.
+
+ title : typing.Optional[str]
+ The title for the task
+
+ proxy_location : typing.Optional[TaskRunRequestInputProxyLocation]
+
+ Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
+
+ Available geotargeting options:
+ - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
+ - RESIDENTIAL_ES: Spain
+ - RESIDENTIAL_IE: Ireland
+ - RESIDENTIAL_GB: United Kingdom
+ - RESIDENTIAL_IN: India
+ - RESIDENTIAL_JP: Japan
+ - RESIDENTIAL_FR: France
+ - RESIDENTIAL_DE: Germany
+ - RESIDENTIAL_NZ: New Zealand
+ - RESIDENTIAL_PH: Philippines
+ - RESIDENTIAL_KR: South Korea
+ - RESIDENTIAL_SA: Saudi Arabia
+ - RESIDENTIAL_ZA: South Africa
+ - RESIDENTIAL_AR: Argentina
+ - RESIDENTIAL_AU: Australia
+ - RESIDENTIAL_BR: Brazil
+ - RESIDENTIAL_TR: Turkey
+ - RESIDENTIAL_CA: Canada
+ - RESIDENTIAL_MX: Mexico
+ - RESIDENTIAL_IT: Italy
+ - RESIDENTIAL_NL: Netherlands
+ - RESIDENTIAL_ISP: ISP proxy
+ - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
+ - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
+ - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
+ - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
+ - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
+ - NONE: No proxy
+
+ For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
+ Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}
+
+ data_extraction_schema : typing.Optional[TaskRunRequestInputDataExtractionSchema]
+
+ The schema for data to be extracted from the webpage. If you're looking for consistent data schema being returned by the agent, it's highly recommended to use https://json-schema.org/.
+
+ error_code_mapping : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+
+ Custom mapping of error codes to error messages if Skyvern encounters an error.
+
+ max_steps : typing.Optional[int]
+
+ Maximum number of steps the task can take. Task will fail if it exceeds this number. Cautions: you are charged per step so please set this number to a reasonable value. Contact [email protected] for custom pricing.
+
+ webhook_url : typing.Optional[str]
+
+ After a run is finished, send an update to this URL. Refer to https://www.skyvern.com/docs/running-tasks/webhooks-faq for more details.
+
+ totp_identifier : typing.Optional[str]
+
+ Identifier for the TOTP/2FA/MFA code when the code is pushed to Skyvern. Refer to https://www.skyvern.com/docs/credentials/totp#option-3-push-code-to-skyvern for more details.
+
+ totp_url : typing.Optional[str]
+
+ URL that serves TOTP/2FA/MFA codes for Skyvern to use during the workflow run. Refer to https://www.skyvern.com/docs/credentials/totp#option-2-get-code-from-your-endpoint for more details.
+
+ browser_session_id : typing.Optional[str]
+
+ Run the task or workflow in the specific Skyvern browser session. Having a browser session can persist the real-time state of the browser, so that the next run can continue from where the previous run left off.
+
+ model : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
+
+ Optional model configuration.
+
+ extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ The extra HTTP headers for the requests in browser.
+
+ cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Use this for browser-provider auth (e.g., x-api-key for Skyvern Cloud, Browserless, or similar). These headers are NEVER forwarded to target websites.
+
+ publish_workflow : typing.Optional[bool]
+ Deprecated. Whether to publish a `skyvern-2.0` task as a reusable workflow. For backwards compatibility, this routes the request through the legacy `skyvern-2.0` publish path. Prefer creating reusable workflows through the workflow APIs.
+
+ include_action_history_in_verification : typing.Optional[bool]
+ Whether to include action history when verifying that the task is complete
+
+ max_screenshot_scrolls : typing.Optional[int]
+ The maximum number of scrolls for the post action screenshot. When it's None or 0, it takes the current viewpoint screenshot.
+
+ browser_address : typing.Optional[str]
+ The CDP address for the task.
+
+ run_with : typing.Optional[str]
+ Whether to run the task with agent or code. Null means use the default.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ TaskRunResponse
+ Successfully run task
+
+ Examples
+ --------
+ import asyncio
+
+ from skyvern import AsyncSkyvern
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
+
+
+ async def main() -> None:
+ await client.run_task(
+ user_agent="x-user-agent",
+ prompt="Find the top 3 posts on Hacker News.",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.run_task(
+ prompt=prompt,
+ user_agent=user_agent,
+ url=url,
+ engine=engine,
+ title=title,
+ proxy_location=proxy_location,
+ data_extraction_schema=data_extraction_schema,
+ error_code_mapping=error_code_mapping,
+ max_steps=max_steps,
+ webhook_url=webhook_url,
+ totp_identifier=totp_identifier,
+ totp_url=totp_url,
+ browser_session_id=browser_session_id,
+ model=model,
+ extra_http_headers=extra_http_headers,
+ cdp_connect_headers=cdp_connect_headers,
+ publish_workflow=publish_workflow,
+ include_action_history_in_verification=include_action_history_in_verification,
+ max_screenshot_scrolls=max_screenshot_scrolls,
+ browser_address=browser_address,
+ run_with=run_with,
+ request_options=request_options,
+ )
+ return _response.data
+
+ async def run_workflow(
+ self,
+ *,
+ agent_id: str,
+ template: typing.Optional[bool] = None,
+ max_steps_override: typing.Optional[int] = None,
+ user_agent: typing.Optional[str] = None,
+ parameters: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
+ title: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[WorkflowRunRequestInputProxyLocation] = OMIT,
+ webhook_url: typing.Optional[str] = OMIT,
+ totp_url: typing.Optional[str] = OMIT,
+ totp_identifier: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ browser_profile_id: typing.Optional[str] = OMIT,
+ max_screenshot_scrolls: typing.Optional[int] = OMIT,
+ max_elapsed_time_minutes: typing.Optional[int] = OMIT,
+ extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ ai_fallback: typing.Optional[bool] = OMIT,
+ run_with: typing.Optional[str] = OMIT,
+ run_metadata: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> WorkflowRunResponse:
+ """
+ Run an agent
- self._artifacts = ArtifactsClient(client_wrapper=self._client_wrapper)
- return self._artifacts
+ Parameters
+ ----------
+ agent_id : str
+ ID of the agent to run. Starts with `wpid_`. `workflow_id` is accepted as an alias.
- @property
- def scripts(self):
- if self._scripts is None:
- from .scripts.client import ScriptsClient # noqa: E402
+ template : typing.Optional[bool]
+
+ max_steps_override : typing.Optional[int]
+
+ user_agent : typing.Optional[str]
+
+ parameters : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
+ Parameters to pass to the workflow
+
+ title : typing.Optional[str]
+ The title for this workflow run
+
+ proxy_location : typing.Optional[WorkflowRunRequestInputProxyLocation]
+
+ Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
+
+ Available geotargeting options:
+ - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
+ - RESIDENTIAL_ES: Spain
+ - RESIDENTIAL_IE: Ireland
+ - RESIDENTIAL_GB: United Kingdom
+ - RESIDENTIAL_IN: India
+ - RESIDENTIAL_JP: Japan
+ - RESIDENTIAL_FR: France
+ - RESIDENTIAL_DE: Germany
+ - RESIDENTIAL_NZ: New Zealand
+ - RESIDENTIAL_PH: Philippines
+ - RESIDENTIAL_KR: South Korea
+ - RESIDENTIAL_SA: Saudi Arabia
+ - RESIDENTIAL_ZA: South Africa
+ - RESIDENTIAL_AR: Argentina
+ - RESIDENTIAL_AU: Australia
+ - RESIDENTIAL_BR: Brazil
+ - RESIDENTIAL_TR: Turkey
+ - RESIDENTIAL_CA: Canada
+ - RESIDENTIAL_MX: Mexico
+ - RESIDENTIAL_IT: Italy
+ - RESIDENTIAL_NL: Netherlands
+ - RESIDENTIAL_ISP: ISP proxy
+ - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
+ - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
+ - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
+ - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
+ - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
+ - NONE: No proxy
+
+ For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
+ Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}
+
+ webhook_url : typing.Optional[str]
+ URL to send workflow status updates to after a run is finished. Refer to https://www.skyvern.com/docs/running-tasks/webhooks-faq for webhook questions.
+
+ totp_url : typing.Optional[str]
+
+ URL that serves TOTP/2FA/MFA codes for Skyvern to use during the workflow run. Refer to https://www.skyvern.com/docs/credentials/totp#option-2-get-code-from-your-endpoint for more details.
+
+ totp_identifier : typing.Optional[str]
+
+ Identifier for the TOTP/2FA/MFA code when the code is pushed to Skyvern. Refer to https://www.skyvern.com/docs/credentials/totp#option-3-push-code-to-skyvern for more details.
+
+ browser_session_id : typing.Optional[str]
+ ID of a Skyvern browser session to reuse, having it continue from the current screen state
+
+ browser_profile_id : typing.Optional[str]
+ ID of a browser profile to reuse for this workflow run
+
+ max_screenshot_scrolls : typing.Optional[int]
+ The maximum number of scrolls for the post action screenshot. When it's None or 0, it takes the current viewpoint screenshot.
+
+ max_elapsed_time_minutes : typing.Optional[int]
+ Timeout this workflow run after the configured elapsed runtime in minutes. When omitted, the platform default is 240 minutes. The maximum configurable value is 480 minutes.
+
+ extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ The extra HTTP headers for the requests in browser.
+
+ cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Use this for browser-provider auth (e.g., x-api-key for Skyvern Cloud, Browserless, or similar). These headers are NEVER forwarded to target websites.
+
+ browser_address : typing.Optional[str]
+ The CDP address for the workflow run.
+
+ ai_fallback : typing.Optional[bool]
+ Whether to fallback to AI if the workflow run fails.
+
+ run_with : typing.Optional[str]
+ Whether to run the workflow with agent or code. Null inherits from the workflow setting.
+
+ run_metadata : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ String key/value metadata to attach to this workflow run for analytics tag filtering.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ WorkflowRunResponse
+ Successfully ran agent
+
+ Examples
+ --------
+ import asyncio
+
+ from skyvern import AsyncSkyvern
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
+
+
+ async def main() -> None:
+ await client.run_workflow(
+ max_steps_override=1,
+ user_agent="x-user-agent",
+ template=True,
+ agent_id="wpid_123",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.run_workflow(
+ agent_id=agent_id,
+ template=template,
+ max_steps_override=max_steps_override,
+ user_agent=user_agent,
+ parameters=parameters,
+ title=title,
+ proxy_location=proxy_location,
+ webhook_url=webhook_url,
+ totp_url=totp_url,
+ totp_identifier=totp_identifier,
+ browser_session_id=browser_session_id,
+ browser_profile_id=browser_profile_id,
+ max_screenshot_scrolls=max_screenshot_scrolls,
+ max_elapsed_time_minutes=max_elapsed_time_minutes,
+ extra_http_headers=extra_http_headers,
+ cdp_connect_headers=cdp_connect_headers,
+ browser_address=browser_address,
+ ai_fallback=ai_fallback,
+ run_with=run_with,
+ run_metadata=run_metadata,
+ request_options=request_options,
+ )
+ return _response.data
+
+ async def get_run(self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> GetRunResponse:
+ """
+ Get run information (task run, workflow run)
+
+ Parameters
+ ----------
+ run_id : str
+ The id of the task run or the workflow run.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ GetRunResponse
+ Successfully got run
+
+ Examples
+ --------
+ import asyncio
+
+ from skyvern import AsyncSkyvern
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
- self._scripts = ScriptsClient(client_wrapper=self._client_wrapper)
- return self._scripts
- @property
- def schedules(self):
- if self._schedules is None:
- from .schedules.client import SchedulesClient # noqa: E402
+ async def main() -> None:
+ await client.get_run(
+ run_id="tsk_123",
+ )
- self._schedules = SchedulesClient(client_wrapper=self._client_wrapper)
- return self._schedules
- @property
- def agents(self):
- if self._agents is None:
- from .agents.client import AgentsClient # noqa: E402
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.get_run(run_id, request_options=request_options)
+ return _response.data
- self._agents = AgentsClient(client_wrapper=self._client_wrapper)
- return self._agents
+ async def cancel_run(
+ self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.Optional[typing.Any]:
+ """
+ Cancel a run (task or workflow)
+ Parameters
+ ----------
+ run_id : str
+ The id of the task run or the workflow run to cancel.
-class AsyncSkyvern:
- """
- Use this class to access the different functions within the SDK. You can instantiate any number of clients with different configuration that will propagate to these functions.
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
- Parameters
- ----------
- base_url : typing.Optional[str]
- The base url to use for requests from the client.
+ Returns
+ -------
+ typing.Optional[typing.Any]
+ Successful Response
- environment : SkyvernEnvironment
- The environment to use for requests from the client. from .environment import SkyvernEnvironment
+ Examples
+ --------
+ import asyncio
+ from skyvern import AsyncSkyvern
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
- Defaults to SkyvernEnvironment.CLOUD
+ async def main() -> None:
+ await client.cancel_run(
+ run_id="run_id",
+ )
- api_key : typing.Optional[str]
- headers : typing.Optional[typing.Dict[str, str]]
- Additional headers to send with every request.
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.cancel_run(run_id, request_options=request_options)
+ return _response.data
- timeout : typing.Optional[float]
- The timeout to be used, in seconds, for requests. By default the timeout is 60 seconds, unless a custom httpx client is used, in which case this default is not enforced.
+ async def bulk_cancel_runs(
+ self, *, run_ids: typing.Sequence[str], request_options: typing.Optional[RequestOptions] = None
+ ) -> BulkCancelRunsResponse:
+ """
+ Cancel multiple runs (tasks or workflows) in a single request
- follow_redirects : typing.Optional[bool]
- Whether the default httpx client follows redirects or not, this is irrelevant if a custom httpx client is passed in.
+ Parameters
+ ----------
+ run_ids : typing.Sequence[str]
+ List of run IDs to cancel
- httpx_client : typing.Optional[httpx.AsyncClient]
- The httpx client to use for making requests, a preconfigured client is used by default, however this is useful should you want to pass in any custom httpx configuration.
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
- Examples
- --------
- from skyvern import AsyncSkyvern
+ Returns
+ -------
+ BulkCancelRunsResponse
+ Successful Response
- client = AsyncSkyvern(
- api_key="YOUR_API_KEY",
- )
- """
+ Examples
+ --------
+ import asyncio
- def __init__(
- self,
- *,
- base_url: typing.Optional[str] = None,
- environment: SkyvernEnvironment = SkyvernEnvironment.CLOUD,
- api_key: typing.Optional[str] = None,
- headers: typing.Optional[typing.Dict[str, str]] = None,
- timeout: typing.Optional[float] = None,
- follow_redirects: typing.Optional[bool] = True,
- httpx_client: typing.Optional[httpx.AsyncClient] = None,
- ):
- _defaulted_timeout = (
- timeout if timeout is not None else 60 if httpx_client is None else httpx_client.timeout.read
- )
- self._client_wrapper = AsyncClientWrapper(
- base_url=_get_base_url(base_url=base_url, environment=environment),
- api_key=api_key,
- headers=headers,
- httpx_client=httpx_client
- if httpx_client is not None
- else httpx.AsyncClient(timeout=_defaulted_timeout, follow_redirects=follow_redirects)
- if follow_redirects is not None
- else httpx.AsyncClient(timeout=_defaulted_timeout),
- timeout=_defaulted_timeout,
+ from skyvern import AsyncSkyvern
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
)
- self._raw_client = AsyncRawSkyvern(client_wrapper=self._client_wrapper)
- self._artifacts: typing.Optional[AsyncArtifactsClient] = None
- self._scripts: typing.Optional[AsyncScriptsClient] = None
- self._schedules: typing.Optional[AsyncSchedulesClient] = None
- self._agents: typing.Optional[AsyncAgentsClient] = None
- @property
- def with_raw_response(self) -> AsyncRawSkyvern:
- """
- Retrieves a raw implementation of this client that returns raw responses.
- Returns
- -------
- AsyncRawSkyvern
+ async def main() -> None:
+ await client.bulk_cancel_runs(
+ run_ids=["run_ids"],
+ )
+
+
+ asyncio.run(main())
"""
- return self._raw_client
+ _response = await self._raw_client.bulk_cancel_runs(run_ids=run_ids, request_options=request_options)
+ return _response.data
- async def run_task(
+ async def get_workflows(
self,
*,
- prompt: str,
- user_agent: typing.Optional[str] = None,
- url: typing.Optional[str] = OMIT,
- engine: typing.Optional[RunEngine] = OMIT,
- title: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[TaskRunRequestInputProxyLocation] = OMIT,
- data_extraction_schema: typing.Optional[TaskRunRequestInputDataExtractionSchema] = OMIT,
- error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- max_steps: typing.Optional[int] = OMIT,
- webhook_url: typing.Optional[str] = OMIT,
- totp_identifier: typing.Optional[str] = OMIT,
- totp_url: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
- extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- publish_workflow: typing.Optional[bool] = OMIT,
- include_action_history_in_verification: typing.Optional[bool] = OMIT,
- max_screenshot_scrolls: typing.Optional[int] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- run_with: typing.Optional[str] = OMIT,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ only_saved_tasks: typing.Optional[bool] = None,
+ only_workflows: typing.Optional[bool] = None,
+ only_templates: typing.Optional[bool] = None,
+ search_key: typing.Optional[str] = None,
+ title: typing.Optional[str] = None,
+ folder_id: typing.Optional[str] = None,
+ status: typing.Optional[typing.Union[WorkflowStatus, typing.Sequence[WorkflowStatus]]] = None,
+ tags: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ template: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> TaskRunResponse:
+ ) -> typing.List[Workflow]:
"""
- Run a task
+ Get all workflows with the latest version for the organization.
+
+ Search semantics:
+ - If `search_key` is provided, its value is used as a unified search term for
+ `workflows.title`, `folders.title`, and workflow parameter metadata (key, description, and default_value for
+ `WorkflowParameterModel`).
+ - Falls back to deprecated `title` (title-only search) if `search_key` is not provided.
+ - Parameter metadata search excludes soft-deleted parameter rows across all parameter tables.
Parameters
----------
- prompt : str
-
- The goal or task description for Skyvern to accomplish
+ page : typing.Optional[int]
- user_agent : typing.Optional[str]
+ page_size : typing.Optional[int]
- url : typing.Optional[str]
+ only_saved_tasks : typing.Optional[bool]
- The starting URL for the task. If not provided, Skyvern will attempt to determine an appropriate URL
+ only_workflows : typing.Optional[bool]
- engine : typing.Optional[RunEngine]
+ only_templates : typing.Optional[bool]
- The engine that powers the agent task. The default value is `skyvern-1.0`, which is good for simple tasks like filling a form, or searching for information on Google. `skyvern-2.0` remains available for existing V2 workflows and explicitly requested V2 task runs. The `openai-cua` engine uses OpenAI's CUA model. The `anthropic-cua` uses Anthropic's Claude Sonnet 3.7 model with the computer use tool.
+ search_key : typing.Optional[str]
+ Case-insensitive substring search across: workflow title, folder name, and parameter metadata (key, description, default_value). A workflow is returned if any of these fields match. Soft-deleted parameter definitions are excluded. Takes precedence over the deprecated `title` parameter.
title : typing.Optional[str]
- The title for the task
+ Deprecated: use search_key instead. Falls back to title-only search if search_key is not provided.
- proxy_location : typing.Optional[TaskRunRequestInputProxyLocation]
+ folder_id : typing.Optional[str]
+ Filter workflows by folder ID
- Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
+ status : typing.Optional[typing.Union[WorkflowStatus, typing.Sequence[WorkflowStatus]]]
- Available geotargeting options:
- - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
- - RESIDENTIAL_ES: Spain
- - RESIDENTIAL_IE: Ireland
- - RESIDENTIAL_GB: United Kingdom
- - RESIDENTIAL_IN: India
- - RESIDENTIAL_JP: Japan
- - RESIDENTIAL_FR: France
- - RESIDENTIAL_DE: Germany
- - RESIDENTIAL_NZ: New Zealand
- - RESIDENTIAL_PH: Philippines
- - RESIDENTIAL_KR: South Korea
- - RESIDENTIAL_SA: Saudi Arabia
- - RESIDENTIAL_ZA: South Africa
- - RESIDENTIAL_AR: Argentina
- - RESIDENTIAL_AU: Australia
- - RESIDENTIAL_BR: Brazil
- - RESIDENTIAL_TR: Turkey
- - RESIDENTIAL_CA: Canada
- - RESIDENTIAL_MX: Mexico
- - RESIDENTIAL_IT: Italy
- - RESIDENTIAL_NL: Netherlands
- - RESIDENTIAL_ISP: ISP proxy
- - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
- - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
- - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
- - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
- - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
- - NONE: No proxy
+ tags : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ Filter by tags. Each term is a label (`production`), a group (`env:*`), or a group:label (`env:prod`). Repeat the param or comma-separate (`?tags=env:prod,env:staging`). AND across distinct terms, OR within a group's labels (`?tags=customer:acme,env:prod,env:staging` -> customer=acme AND env in (prod, staging)). A label term matches the value across any/no group. Matches current tag values only. Not supported with `template=true`.
- For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
- Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}
+ template : typing.Optional[bool]
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ typing.List[Workflow]
+ Successful Response
- data_extraction_schema : typing.Optional[TaskRunRequestInputDataExtractionSchema]
+ Examples
+ --------
+ import asyncio
- The schema for data to be extracted from the webpage. If you're looking for consistent data schema being returned by the agent, it's highly recommended to use https://json-schema.org/.
+ from skyvern import AsyncSkyvern
- error_code_mapping : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
- Custom mapping of error codes to error messages if Skyvern encounters an error.
- max_steps : typing.Optional[int]
+ async def main() -> None:
+ await client.get_workflows(
+ page=1,
+ page_size=1,
+ only_saved_tasks=True,
+ only_workflows=True,
+ only_templates=True,
+ search_key="search_key",
+ title="title",
+ folder_id="folder_id",
+ template=True,
+ )
- Maximum number of steps the task can take. Task will fail if it exceeds this number. Cautions: you are charged per step so please set this number to a reasonable value. Contact [email protected] for custom pricing.
- webhook_url : typing.Optional[str]
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.get_workflows(
+ page=page,
+ page_size=page_size,
+ only_saved_tasks=only_saved_tasks,
+ only_workflows=only_workflows,
+ only_templates=only_templates,
+ search_key=search_key,
+ title=title,
+ folder_id=folder_id,
+ status=status,
+ tags=tags,
+ template=template,
+ request_options=request_options,
+ )
+ return _response.data
- After a run is finished, send an update to this URL. Refer to https://www.skyvern.com/docs/running-tasks/webhooks-faq for more details.
+ async def create_workflow(
+ self,
+ *,
+ folder_id: typing.Optional[str] = None,
+ json_definition: typing.Optional[WorkflowCreateYamlRequest] = OMIT,
+ yaml_definition: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> Workflow:
+ """
+ Create a new agent
- totp_identifier : typing.Optional[str]
+ Parameters
+ ----------
+ folder_id : typing.Optional[str]
+ Optional folder ID to assign the workflow to
- Identifier for the TOTP/2FA/MFA code when the code is pushed to Skyvern. Refer to https://www.skyvern.com/docs/credentials/totp#option-3-push-code-to-skyvern for more details.
+ json_definition : typing.Optional[WorkflowCreateYamlRequest]
+ Workflow definition in JSON format
- totp_url : typing.Optional[str]
+ yaml_definition : typing.Optional[str]
+ Workflow definition in YAML format
- URL that serves TOTP/2FA/MFA codes for Skyvern to use during the workflow run. Refer to https://www.skyvern.com/docs/credentials/totp#option-2-get-code-from-your-endpoint for more details.
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
- browser_session_id : typing.Optional[str]
+ Returns
+ -------
+ Workflow
+ Successfully created agent
- Run the task or workflow in the specific Skyvern browser session. Having a browser session can persist the real-time state of the browser, so that the next run can continue from where the previous run left off.
+ Examples
+ --------
+ import asyncio
- model : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
+ from skyvern import AsyncSkyvern
- Optional model configuration.
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
- extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- The extra HTTP headers for the requests in browser.
- cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Use this for browser-provider auth (e.g., x-api-key for Skyvern Cloud, Browserless, or similar). These headers are NEVER forwarded to target websites.
+ async def main() -> None:
+ await client.create_workflow(
+ folder_id="folder_id",
+ )
- publish_workflow : typing.Optional[bool]
- Deprecated. Whether to publish a `skyvern-2.0` task as a reusable workflow. For backwards compatibility, this routes the request through the legacy `skyvern-2.0` publish path. Prefer creating reusable workflows through the workflow APIs.
- include_action_history_in_verification : typing.Optional[bool]
- Whether to include action history when verifying that the task is complete
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.create_workflow(
+ folder_id=folder_id,
+ json_definition=json_definition,
+ yaml_definition=yaml_definition,
+ request_options=request_options,
+ )
+ return _response.data
- max_screenshot_scrolls : typing.Optional[int]
- The maximum number of scrolls for the post action screenshot. When it's None or 0, it takes the current viewpoint screenshot.
+ async def update_workflow(
+ self,
+ workflow_id: str,
+ *,
+ json_definition: typing.Optional[WorkflowCreateYamlRequest] = OMIT,
+ yaml_definition: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> Workflow:
+ """
+ Update an agent
- browser_address : typing.Optional[str]
- The CDP address for the task.
+ Parameters
+ ----------
+ workflow_id : str
+ The ID of the agent to update. Starts with `wpid_`.
- run_with : typing.Optional[str]
- Whether to run the task with agent or code. Null means use the default.
+ json_definition : typing.Optional[WorkflowCreateYamlRequest]
+ Workflow definition in JSON format
+
+ yaml_definition : typing.Optional[str]
+ Workflow definition in YAML format
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TaskRunResponse
- Successfully run task
+ Workflow
+ Successfully updated agent
Examples
--------
@@ -3537,170 +4667,143 @@ class AsyncSkyvern:
async def main() -> None:
- await client.run_task(
- user_agent="x-user-agent",
- prompt="Find the top 3 posts on Hacker News.",
+ await client.update_workflow(
+ workflow_id="wpid_123",
)
asyncio.run(main())
"""
- _response = await self._raw_client.run_task(
- prompt=prompt,
- user_agent=user_agent,
- url=url,
- engine=engine,
- title=title,
- proxy_location=proxy_location,
- data_extraction_schema=data_extraction_schema,
- error_code_mapping=error_code_mapping,
- max_steps=max_steps,
- webhook_url=webhook_url,
- totp_identifier=totp_identifier,
- totp_url=totp_url,
- browser_session_id=browser_session_id,
- model=model,
- extra_http_headers=extra_http_headers,
- cdp_connect_headers=cdp_connect_headers,
- publish_workflow=publish_workflow,
- include_action_history_in_verification=include_action_history_in_verification,
- max_screenshot_scrolls=max_screenshot_scrolls,
- browser_address=browser_address,
- run_with=run_with,
+ _response = await self._raw_client.update_workflow(
+ workflow_id,
+ json_definition=json_definition,
+ yaml_definition=yaml_definition,
request_options=request_options,
)
return _response.data
- async def run_workflow(
- self,
- *,
- agent_id: str,
- template: typing.Optional[bool] = None,
- max_steps_override: typing.Optional[int] = None,
- user_agent: typing.Optional[str] = None,
- parameters: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
- title: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[WorkflowRunRequestInputProxyLocation] = OMIT,
- webhook_url: typing.Optional[str] = OMIT,
- totp_url: typing.Optional[str] = OMIT,
- totp_identifier: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- browser_profile_id: typing.Optional[str] = OMIT,
- max_screenshot_scrolls: typing.Optional[int] = OMIT,
- max_elapsed_time_minutes: typing.Optional[int] = OMIT,
- extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- ai_fallback: typing.Optional[bool] = OMIT,
- run_with: typing.Optional[str] = OMIT,
- run_metadata: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> WorkflowRunResponse:
+ async def delete_workflow(
+ self, workflow_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.Optional[typing.Any]:
"""
- Run an agent
+ Delete an agent
Parameters
----------
- agent_id : str
- ID of the agent to run. Starts with `wpid_`. `workflow_id` is accepted as an alias.
+ workflow_id : str
+ The ID of the agent to delete. Starts with `wpid_`.
- template : typing.Optional[bool]
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
- max_steps_override : typing.Optional[int]
+ Returns
+ -------
+ typing.Optional[typing.Any]
+ Successfully deleted agent
- user_agent : typing.Optional[str]
+ Examples
+ --------
+ import asyncio
- parameters : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
- Parameters to pass to the workflow
+ from skyvern import AsyncSkyvern
- title : typing.Optional[str]
- The title for this workflow run
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
- proxy_location : typing.Optional[WorkflowRunRequestInputProxyLocation]
- Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
+ async def main() -> None:
+ await client.delete_workflow(
+ workflow_id="wpid_123",
+ )
- Available geotargeting options:
- - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
- - RESIDENTIAL_ES: Spain
- - RESIDENTIAL_IE: Ireland
- - RESIDENTIAL_GB: United Kingdom
- - RESIDENTIAL_IN: India
- - RESIDENTIAL_JP: Japan
- - RESIDENTIAL_FR: France
- - RESIDENTIAL_DE: Germany
- - RESIDENTIAL_NZ: New Zealand
- - RESIDENTIAL_PH: Philippines
- - RESIDENTIAL_KR: South Korea
- - RESIDENTIAL_SA: Saudi Arabia
- - RESIDENTIAL_ZA: South Africa
- - RESIDENTIAL_AR: Argentina
- - RESIDENTIAL_AU: Australia
- - RESIDENTIAL_BR: Brazil
- - RESIDENTIAL_TR: Turkey
- - RESIDENTIAL_CA: Canada
- - RESIDENTIAL_MX: Mexico
- - RESIDENTIAL_IT: Italy
- - RESIDENTIAL_NL: Netherlands
- - RESIDENTIAL_ISP: ISP proxy
- - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
- - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
- - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
- - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
- - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
- - NONE: No proxy
- For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
- Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.delete_workflow(workflow_id, request_options=request_options)
+ return _response.data
+
+ async def get_folders(
+ self,
+ *,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ search: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> typing.List[Folder]:
+ """
+ Get all folders for the organization
- webhook_url : typing.Optional[str]
- URL to send workflow status updates to after a run is finished. Refer to https://www.skyvern.com/docs/running-tasks/webhooks-faq for webhook questions.
+ Parameters
+ ----------
+ page : typing.Optional[int]
+ Page number
- totp_url : typing.Optional[str]
+ page_size : typing.Optional[int]
+ Number of folders per page
- URL that serves TOTP/2FA/MFA codes for Skyvern to use during the workflow run. Refer to https://www.skyvern.com/docs/credentials/totp#option-2-get-code-from-your-endpoint for more details.
+ search : typing.Optional[str]
+ Search folders by title or description
- totp_identifier : typing.Optional[str]
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
- Identifier for the TOTP/2FA/MFA code when the code is pushed to Skyvern. Refer to https://www.skyvern.com/docs/credentials/totp#option-3-push-code-to-skyvern for more details.
+ Returns
+ -------
+ typing.List[Folder]
+ Successfully retrieved folders
- browser_session_id : typing.Optional[str]
- ID of a Skyvern browser session to reuse, having it continue from the current screen state
+ Examples
+ --------
+ import asyncio
- browser_profile_id : typing.Optional[str]
- ID of a browser profile to reuse for this workflow run
+ from skyvern import AsyncSkyvern
- max_screenshot_scrolls : typing.Optional[int]
- The maximum number of scrolls for the post action screenshot. When it's None or 0, it takes the current viewpoint screenshot.
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
- max_elapsed_time_minutes : typing.Optional[int]
- Timeout this workflow run after the configured elapsed runtime in minutes. When omitted, the platform default is 240 minutes. The maximum configurable value is 480 minutes.
- extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- The extra HTTP headers for the requests in browser.
+ async def main() -> None:
+ await client.get_folders(
+ page=1,
+ page_size=1,
+ search="search",
+ )
- cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Use this for browser-provider auth (e.g., x-api-key for Skyvern Cloud, Browserless, or similar). These headers are NEVER forwarded to target websites.
- browser_address : typing.Optional[str]
- The CDP address for the workflow run.
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.get_folders(
+ page=page, page_size=page_size, search=search, request_options=request_options
+ )
+ return _response.data
- ai_fallback : typing.Optional[bool]
- Whether to fallback to AI if the workflow run fails.
+ async def create_folder(
+ self,
+ *,
+ title: str,
+ description: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> Folder:
+ """
+ Create a new folder to organize workflows
- run_with : typing.Optional[str]
- Whether to run the workflow with agent or code. Null inherits from the workflow setting.
+ Parameters
+ ----------
+ title : str
+ Folder title
- run_metadata : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- String key/value metadata to attach to this workflow run for analytics tag filtering.
+ description : typing.Optional[str]
+ Folder description
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- WorkflowRunResponse
- Successfully ran agent
+ Folder
+ Successfully created folder
Examples
--------
@@ -3714,57 +4817,34 @@ class AsyncSkyvern:
async def main() -> None:
- await client.run_workflow(
- max_steps_override=1,
- user_agent="x-user-agent",
- template=True,
- agent_id="wpid_123",
+ await client.create_folder(
+ title="title",
)
asyncio.run(main())
"""
- _response = await self._raw_client.run_workflow(
- agent_id=agent_id,
- template=template,
- max_steps_override=max_steps_override,
- user_agent=user_agent,
- parameters=parameters,
- title=title,
- proxy_location=proxy_location,
- webhook_url=webhook_url,
- totp_url=totp_url,
- totp_identifier=totp_identifier,
- browser_session_id=browser_session_id,
- browser_profile_id=browser_profile_id,
- max_screenshot_scrolls=max_screenshot_scrolls,
- max_elapsed_time_minutes=max_elapsed_time_minutes,
- extra_http_headers=extra_http_headers,
- cdp_connect_headers=cdp_connect_headers,
- browser_address=browser_address,
- ai_fallback=ai_fallback,
- run_with=run_with,
- run_metadata=run_metadata,
- request_options=request_options,
+ _response = await self._raw_client.create_folder(
+ title=title, description=description, request_options=request_options
)
return _response.data
- async def get_run(self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> GetRunResponse:
+ async def get_folder(self, folder_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> Folder:
"""
- Get run information (task run, workflow run)
+ Get a specific folder by ID
Parameters
----------
- run_id : str
- The id of the task run or the workflow run.
+ folder_id : str
+ Folder ID
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- GetRunResponse
- Successfully got run
+ Folder
+ Successfully retrieved folder
Examples
--------
@@ -3778,34 +4858,45 @@ class AsyncSkyvern:
async def main() -> None:
- await client.get_run(
- run_id="tsk_123",
+ await client.get_folder(
+ folder_id="fld_123",
)
asyncio.run(main())
"""
- _response = await self._raw_client.get_run(run_id, request_options=request_options)
+ _response = await self._raw_client.get_folder(folder_id, request_options=request_options)
return _response.data
- async def cancel_run(
- self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> typing.Optional[typing.Any]:
+ async def update_folder(
+ self,
+ folder_id: str,
+ *,
+ title: typing.Optional[str] = OMIT,
+ description: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> Folder:
"""
- Cancel a run (task or workflow)
+ Update a folder's title or description
Parameters
----------
- run_id : str
- The id of the task run or the workflow run to cancel.
+ folder_id : str
+ Folder ID
+
+ title : typing.Optional[str]
+ Folder title
+
+ description : typing.Optional[str]
+ Folder description
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.Optional[typing.Any]
- Successful Response
+ Folder
+ Successfully updated folder
Examples
--------
@@ -3819,34 +4910,43 @@ class AsyncSkyvern:
async def main() -> None:
- await client.cancel_run(
- run_id="run_id",
+ await client.update_folder(
+ folder_id="fld_123",
)
asyncio.run(main())
"""
- _response = await self._raw_client.cancel_run(run_id, request_options=request_options)
+ _response = await self._raw_client.update_folder(
+ folder_id, title=title, description=description, request_options=request_options
+ )
return _response.data
- async def bulk_cancel_runs(
- self, *, run_ids: typing.Sequence[str], request_options: typing.Optional[RequestOptions] = None
- ) -> BulkCancelRunsResponse:
+ async def delete_folder(
+ self,
+ folder_id: str,
+ *,
+ delete_workflows: typing.Optional[bool] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> typing.Dict[str, typing.Optional[typing.Any]]:
"""
- Cancel multiple runs (tasks or workflows) in a single request
+ Delete a folder. Optionally delete all workflows in the folder.
Parameters
----------
- run_ids : typing.Sequence[str]
- List of run IDs to cancel
+ folder_id : str
+ Folder ID
+
+ delete_workflows : typing.Optional[bool]
+ If true, also delete all workflows in this folder
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- BulkCancelRunsResponse
- Successful Response
+ typing.Dict[str, typing.Optional[typing.Any]]
+ Successfully deleted folder
Examples
--------
@@ -3860,77 +4960,93 @@ class AsyncSkyvern:
async def main() -> None:
- await client.bulk_cancel_runs(
- run_ids=["run_ids"],
+ await client.delete_folder(
+ folder_id="fld_123",
+ delete_workflows=True,
)
asyncio.run(main())
"""
- _response = await self._raw_client.bulk_cancel_runs(run_ids=run_ids, request_options=request_options)
+ _response = await self._raw_client.delete_folder(
+ folder_id, delete_workflows=delete_workflows, request_options=request_options
+ )
return _response.data
- async def get_workflows(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- only_saved_tasks: typing.Optional[bool] = None,
- only_workflows: typing.Optional[bool] = None,
- only_templates: typing.Optional[bool] = None,
- search_key: typing.Optional[str] = None,
- title: typing.Optional[str] = None,
- folder_id: typing.Optional[str] = None,
- status: typing.Optional[typing.Union[WorkflowStatus, typing.Sequence[WorkflowStatus]]] = None,
- tags: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
- template: typing.Optional[bool] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[Workflow]:
+ async def get_run_tags(
+ self, workflow_run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> RunTagsResponse:
"""
- Get all workflows with the latest version for the organization.
-
- Search semantics:
- - If `search_key` is provided, its value is used as a unified search term for
- `workflows.title`, `folders.title`, and workflow parameter metadata (key, description, and default_value for
- `WorkflowParameterModel`).
- - Falls back to deprecated `title` (title-only search) if `search_key` is not provided.
- - Parameter metadata search excludes soft-deleted parameter rows across all parameter tables.
+ Get the current tag state for a workflow run.
Parameters
----------
- page : typing.Optional[int]
+ workflow_run_id : str
+ Workflow run ID
- page_size : typing.Optional[int]
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
- only_saved_tasks : typing.Optional[bool]
+ Returns
+ -------
+ RunTagsResponse
+ Successfully retrieved tags
- only_workflows : typing.Optional[bool]
+ Examples
+ --------
+ import asyncio
+
+ from skyvern import AsyncSkyvern
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
+
+
+ async def main() -> None:
+ await client.get_run_tags(
+ workflow_run_id="wr_123",
+ )
- only_templates : typing.Optional[bool]
- search_key : typing.Optional[str]
- Case-insensitive substring search across: workflow title, folder name, and parameter metadata (key, description, default_value). A workflow is returned if any of these fields match. Soft-deleted parameter definitions are excluded. Takes precedence over the deprecated `title` parameter.
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.get_run_tags(workflow_run_id, request_options=request_options)
+ return _response.data
- title : typing.Optional[str]
- Deprecated: use search_key instead. Falls back to title-only search if search_key is not provided.
+ async def apply_run_tags(
+ self,
+ workflow_run_id: str,
+ *,
+ tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
+ tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> RunTagsResponse:
+ """
+ Atomically apply tag changes to a workflow run. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
- folder_id : typing.Optional[str]
- Filter workflows by folder ID
+ Parameters
+ ----------
+ workflow_run_id : str
+ Workflow run ID
- status : typing.Optional[typing.Union[WorkflowStatus, typing.Sequence[WorkflowStatus]]]
+ tags : typing.Optional[typing.Sequence[TagInput]]
+ Tags to set (overwrite). List of {key?, value} objects.
- tags : typing.Optional[typing.Union[str, typing.Sequence[str]]]
- Filter by tags. Each term is a label (`production`), a group (`env:*`), or a group:label (`env:prod`). Repeat the param or comma-separate (`?tags=env:prod,env:staging`). AND across distinct terms, OR within a group's labels (`?tags=customer:acme,env:prod,env:staging` -> customer=acme AND env in (prod, staging)). A label term matches the value across any/no group. Matches current tag values only. Not supported with `template=true`.
+ tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
+ Tags to soft-delete. List of {key?, value?} targets.
- template : typing.Optional[bool]
+ colors : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[Workflow]
- Successful Response
+ RunTagsResponse
+ Successfully applied tag changes
Examples
--------
@@ -3944,66 +5060,39 @@ class AsyncSkyvern:
async def main() -> None:
- await client.get_workflows(
- page=1,
- page_size=1,
- only_saved_tasks=True,
- only_workflows=True,
- only_templates=True,
- search_key="search_key",
- title="title",
- folder_id="folder_id",
- template=True,
+ await client.apply_run_tags(
+ workflow_run_id="wr_123",
)
asyncio.run(main())
"""
- _response = await self._raw_client.get_workflows(
- page=page,
- page_size=page_size,
- only_saved_tasks=only_saved_tasks,
- only_workflows=only_workflows,
- only_templates=only_templates,
- search_key=search_key,
- title=title,
- folder_id=folder_id,
- status=status,
- tags=tags,
- template=template,
- request_options=request_options,
+ _response = await self._raw_client.apply_run_tags(
+ workflow_run_id, tags=tags, tags_to_delete=tags_to_delete, colors=colors, request_options=request_options
)
return _response.data
- async def create_workflow(
- self,
- *,
- folder_id: typing.Optional[str] = None,
- json_definition: typing.Optional[WorkflowCreateYamlRequest] = OMIT,
- yaml_definition: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> Workflow:
+ async def delete_run_tag(
+ self, workflow_run_id: str, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> RunTagsResponse:
"""
- Create a new agent
+ Soft-delete a single grouped tag from a workflow run. Writes a DELETE event row.
Parameters
----------
- folder_id : typing.Optional[str]
- Optional folder ID to assign the workflow to
-
- json_definition : typing.Optional[WorkflowCreateYamlRequest]
- Workflow definition in JSON format
+ workflow_run_id : str
+ Workflow run ID
- yaml_definition : typing.Optional[str]
- Workflow definition in YAML format
+ key : str
+ Tag key to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Workflow
- Successfully created agent
+ RunTagsResponse
+ Successfully deleted tag (or no-op if absent)
Examples
--------
@@ -4017,54 +5106,55 @@ class AsyncSkyvern:
async def main() -> None:
- await client.create_workflow(
- folder_id="folder_id",
+ await client.delete_run_tag(
+ workflow_run_id="wr_123",
+ key="env",
)
asyncio.run(main())
"""
- _response = await self._raw_client.create_workflow(
- folder_id=folder_id,
- json_definition=json_definition,
- yaml_definition=yaml_definition,
- request_options=request_options,
- )
+ _response = await self._raw_client.delete_run_tag(workflow_run_id, key, request_options=request_options)
return _response.data
- async def update_workflow(
+ async def get_run_tag_history(
self,
- workflow_id: str,
+ workflow_run_id: str,
*,
- json_definition: typing.Optional[WorkflowCreateYamlRequest] = OMIT,
- yaml_definition: typing.Optional[str] = OMIT,
+ limit: typing.Optional[int] = None,
+ since: typing.Optional[dt.datetime] = None,
+ key: typing.Optional[str] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> Workflow:
+ ) -> RunTagHistoryResponse:
"""
- Update an agent
+ Chronological tag-event log for a workflow run (newest first). Includes SET and DELETE events.
Parameters
----------
- workflow_id : str
- The ID of the agent to update. Starts with `wpid_`.
+ workflow_run_id : str
+ Workflow run ID
- json_definition : typing.Optional[WorkflowCreateYamlRequest]
- Workflow definition in JSON format
+ limit : typing.Optional[int]
+ Max events to return
- yaml_definition : typing.Optional[str]
- Workflow definition in YAML format
+ since : typing.Optional[dt.datetime]
+ Only return events at or after this timestamp
+
+ key : typing.Optional[str]
+ Filter to events for a single tag key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Workflow
- Successfully updated agent
+ RunTagHistoryResponse
+ Successfully retrieved tag history
Examples
--------
import asyncio
+ import datetime
from skyvern import AsyncSkyvern
@@ -4074,39 +5164,36 @@ class AsyncSkyvern:
async def main() -> None:
- await client.update_workflow(
- workflow_id="wpid_123",
+ await client.get_run_tag_history(
+ workflow_run_id="wr_123",
+ limit=1,
+ since=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+ key="key",
)
asyncio.run(main())
"""
- _response = await self._raw_client.update_workflow(
- workflow_id,
- json_definition=json_definition,
- yaml_definition=yaml_definition,
- request_options=request_options,
+ _response = await self._raw_client.get_run_tag_history(
+ workflow_run_id, limit=limit, since=since, key=key, request_options=request_options
)
return _response.data
- async def delete_workflow(
- self, workflow_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> typing.Optional[typing.Any]:
+ async def list_tag_keys(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.List[TagKey]:
"""
- Delete an agent
+ List all tag keys registered for the organization with their descriptions.
Parameters
----------
- workflow_id : str
- The ID of the agent to delete. Starts with `wpid_`.
-
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.Optional[typing.Any]
- Successfully deleted agent
+ typing.List[TagKey]
+ Successfully retrieved tag keys
Examples
--------
@@ -4120,45 +5207,32 @@ class AsyncSkyvern:
async def main() -> None:
- await client.delete_workflow(
- workflow_id="wpid_123",
- )
+ await client.list_tag_keys()
asyncio.run(main())
"""
- _response = await self._raw_client.delete_workflow(workflow_id, request_options=request_options)
+ _response = await self._raw_client.list_tag_keys(request_options=request_options)
return _response.data
- async def get_folders(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- search: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.List[Folder]:
+ async def delete_tag_key(
+ self, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagKeyDeleteResponse:
"""
- Get all folders for the organization
+ Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
Parameters
----------
- page : typing.Optional[int]
- Page number
-
- page_size : typing.Optional[int]
- Number of folders per page
-
- search : typing.Optional[str]
- Search folders by title or description
+ key : str
+ Tag key to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[Folder]
- Successfully retrieved folders
+ TagKeyDeleteResponse
+ Successfully deleted tag key
Examples
--------
@@ -4172,45 +5246,41 @@ class AsyncSkyvern:
async def main() -> None:
- await client.get_folders(
- page=1,
- page_size=1,
- search="search",
+ await client.delete_tag_key(
+ key="env",
)
asyncio.run(main())
"""
- _response = await self._raw_client.get_folders(
- page=page, page_size=page_size, search=search, request_options=request_options
- )
+ _response = await self._raw_client.delete_tag_key(key, request_options=request_options)
return _response.data
- async def create_folder(
+ async def update_tag_key(
self,
+ key: str,
*,
- title: str,
description: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> Folder:
+ ) -> TagKey:
"""
- Create a new folder to organize workflows
+ Update the description for a tag key.
Parameters
----------
- title : str
- Folder title
+ key : str
+ Tag key to update
description : typing.Optional[str]
- Folder description
+ Free-form description (max 500 chars). Pass null to clear.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Folder
- Successfully created folder
+ TagKey
+ Successfully updated tag key
Examples
--------
@@ -4224,34 +5294,34 @@ class AsyncSkyvern:
async def main() -> None:
- await client.create_folder(
- title="title",
+ await client.update_tag_key(
+ key="key",
)
asyncio.run(main())
"""
- _response = await self._raw_client.create_folder(
- title=title, description=description, request_options=request_options
- )
+ _response = await self._raw_client.update_tag_key(key, description=description, request_options=request_options)
return _response.data
- async def get_folder(self, folder_id: str, *, request_options: typing.Optional[RequestOptions] = None) -> Folder:
+ async def list_tag_values(
+ self, *, key: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
+ ) -> typing.List[TagValue]:
"""
- Get a specific folder by ID
+ List the palette color and current workflow usage count for each grouped tag (key, value) for the organization. The frontend joins these onto tags by (key, value); workflow_count is the number of non-deleted workflows carrying the label and powers the per-label usage and delete blast-radius warnings.
Parameters
----------
- folder_id : str
- Folder ID
+ key : typing.Optional[str]
+ Filter to values for a single tag key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Folder
- Successfully retrieved folder
+ typing.List[TagValue]
+ Successfully retrieved tag values
Examples
--------
@@ -4265,45 +5335,37 @@ class AsyncSkyvern:
async def main() -> None:
- await client.get_folder(
- folder_id="fld_123",
+ await client.list_tag_values(
+ key="key",
)
asyncio.run(main())
"""
- _response = await self._raw_client.get_folder(folder_id, request_options=request_options)
+ _response = await self._raw_client.list_tag_values(key=key, request_options=request_options)
return _response.data
- async def update_folder(
- self,
- folder_id: str,
- *,
- title: typing.Optional[str] = OMIT,
- description: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> Folder:
+ async def delete_tag_value(
+ self, key: str, *, value: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagValueDeleteResponse:
"""
- Update a folder's title or description
+ Soft-delete a grouped tag (key, value) and remove that label from every workflow carrying it (cascade). The value rides in the body so values containing '/' stay addressable. Returns how many workflows the label was removed from.
Parameters
----------
- folder_id : str
- Folder ID
-
- title : typing.Optional[str]
- Folder title
+ key : str
+ Tag key (group)
- description : typing.Optional[str]
- Folder description
+ value : str
+ Tag value (label) under the key to soft-delete.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- Folder
- Successfully updated folder
+ TagValueDeleteResponse
+ Successfully deleted tag value
Examples
--------
@@ -4317,43 +5379,41 @@ class AsyncSkyvern:
async def main() -> None:
- await client.update_folder(
- folder_id="fld_123",
+ await client.delete_tag_value(
+ key="env",
+ value="value",
)
asyncio.run(main())
"""
- _response = await self._raw_client.update_folder(
- folder_id, title=title, description=description, request_options=request_options
- )
- return _response.data
-
- async def delete_folder(
- self,
- folder_id: str,
- *,
- delete_workflows: typing.Optional[bool] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> typing.Dict[str, typing.Optional[typing.Any]]:
- """
- Delete a folder. Optionally delete all workflows in the folder.
+ _response = await self._raw_client.delete_tag_value(key, value=value, request_options=request_options)
+ return _response.data
+
+ async def update_tag_value(
+ self, key: str, *, value: str, color: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagValue:
+ """
+ Recolor a grouped tag (key, value). The value is supplied in the body so values containing '/' stay addressable. The new color must be a palette name.
Parameters
----------
- folder_id : str
- Folder ID
+ key : str
+ Tag key (group)
- delete_workflows : typing.Optional[bool]
- If true, also delete all workflows in this folder
+ value : str
+ Tag value (label) under the key to recolor.
+
+ color : str
+ Palette color name to assign to this (key, value).
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.Dict[str, typing.Optional[typing.Any]]
- Successfully deleted folder
+ TagValue
+ Successfully recolored tag value
Examples
--------
@@ -4367,32 +5427,44 @@ class AsyncSkyvern:
async def main() -> None:
- await client.delete_folder(
- folder_id="fld_123",
- delete_workflows=True,
+ await client.update_tag_value(
+ key="env",
+ value="value",
+ color="color",
)
asyncio.run(main())
"""
- _response = await self._raw_client.delete_folder(
- folder_id, delete_workflows=delete_workflows, request_options=request_options
+ _response = await self._raw_client.update_tag_value(
+ key, value=value, color=color, request_options=request_options
)
return _response.data
- async def list_tag_keys(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.List[TagKey]:
+ async def rename_tag_value(
+ self, key: str, *, value: str, new_value: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> TagValueRenameResponse:
"""
- List all tag keys registered for the organization with their descriptions.
+ Rename a grouped tag (key, value) to (key, new_value). The cascade re-tags every workflow carrying the old label; the new label inherits the old color. Both values ride in the body so values containing '/' stay addressable. Rejects with 409 when the new value already exists for the key.
Parameters
----------
+ key : str
+ Tag key (group)
+
+ value : str
+ Current tag value (label) under the key to rename.
+
+ new_value : str
+ New tag value (label) to rename it to.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- typing.List[TagKey]
- Successfully retrieved tag keys
+ TagValueRenameResponse
+ Successfully renamed tag value
Examples
--------
@@ -4406,32 +5478,41 @@ class AsyncSkyvern:
async def main() -> None:
- await client.list_tag_keys()
+ await client.rename_tag_value(
+ key="env",
+ value="value",
+ new_value="new_value",
+ )
asyncio.run(main())
"""
- _response = await self._raw_client.list_tag_keys(request_options=request_options)
+ _response = await self._raw_client.rename_tag_value(
+ key, value=value, new_value=new_value, request_options=request_options
+ )
return _response.data
- async def delete_tag_key(
- self, key: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> TagKeyDeleteResponse:
+ async def batch_get_workflow_tags(
+ self,
+ *,
+ workflow_permanent_ids: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> WorkflowTagsBatchResponse:
"""
- Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
+ Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
Parameters
----------
- key : str
- Tag key to delete
+ workflow_permanent_ids : typing.Optional[str]
+ Comma-separated workflow permanent IDs
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TagKeyDeleteResponse
- Successfully deleted tag key
+ WorkflowTagsBatchResponse
+ Successfully retrieved tags
Examples
--------
@@ -4445,41 +5526,39 @@ class AsyncSkyvern:
async def main() -> None:
- await client.delete_tag_key(
- key="env",
+ await client.batch_get_workflow_tags(
+ workflow_permanent_ids="workflow_permanent_ids",
)
asyncio.run(main())
"""
- _response = await self._raw_client.delete_tag_key(key, request_options=request_options)
+ _response = await self._raw_client.batch_get_workflow_tags(
+ workflow_permanent_ids=workflow_permanent_ids, request_options=request_options
+ )
return _response.data
- async def update_tag_key(
+ async def batch_get_workflow_tags_post(
self,
- key: str,
*,
- description: typing.Optional[str] = OMIT,
+ workflow_permanent_ids: typing.Optional[typing.Sequence[str]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> TagKey:
+ ) -> WorkflowTagsBatchResponse:
"""
- Update the description for a tag key.
+ Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
Parameters
----------
- key : str
- Tag key to update
-
- description : typing.Optional[str]
- Free-form description (max 500 chars). Pass null to clear.
+ workflow_permanent_ids : typing.Optional[typing.Sequence[str]]
+ Workflow permanent IDs to fetch tags for.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- TagKey
- Successfully updated tag key
+ WorkflowTagsBatchResponse
+ Successfully retrieved tags
Examples
--------
@@ -4493,36 +5572,33 @@ class AsyncSkyvern:
async def main() -> None:
- await client.update_tag_key(
- key="key",
- )
+ await client.batch_get_workflow_tags_post()
asyncio.run(main())
"""
- _response = await self._raw_client.update_tag_key(key, description=description, request_options=request_options)
+ _response = await self._raw_client.batch_get_workflow_tags_post(
+ workflow_permanent_ids=workflow_permanent_ids, request_options=request_options
+ )
return _response.data
- async def batch_get_workflow_tags(
- self,
- *,
- workflow_permanent_ids: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> WorkflowTagsBatchResponse:
+ async def batch_get_run_tags(
+ self, *, workflow_run_ids: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
+ ) -> RunTagsBatchResponse:
"""
- Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
+ Batch fetch current tags for many workflow runs. Avoids N+1 on run-list pages.
Parameters
----------
- workflow_permanent_ids : typing.Optional[str]
- Comma-separated workflow permanent IDs
+ workflow_run_ids : typing.Optional[str]
+ Comma-separated workflow run IDs
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- WorkflowTagsBatchResponse
+ RunTagsBatchResponse
Successfully retrieved tags
Examples
@@ -4537,38 +5613,38 @@ class AsyncSkyvern:
async def main() -> None:
- await client.batch_get_workflow_tags(
- workflow_permanent_ids="workflow_permanent_ids",
+ await client.batch_get_run_tags(
+ workflow_run_ids="workflow_run_ids",
)
asyncio.run(main())
"""
- _response = await self._raw_client.batch_get_workflow_tags(
- workflow_permanent_ids=workflow_permanent_ids, request_options=request_options
+ _response = await self._raw_client.batch_get_run_tags(
+ workflow_run_ids=workflow_run_ids, request_options=request_options
)
return _response.data
- async def batch_get_workflow_tags_post(
+ async def batch_get_run_tags_post(
self,
*,
- workflow_permanent_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ workflow_run_ids: typing.Optional[typing.Sequence[str]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> WorkflowTagsBatchResponse:
+ ) -> RunTagsBatchResponse:
"""
- Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
+ Batch fetch current tags for many workflow runs (POST variant for id lists exceeding URL length).
Parameters
----------
- workflow_permanent_ids : typing.Optional[typing.Sequence[str]]
- Workflow permanent IDs to fetch tags for.
+ workflow_run_ids : typing.Optional[typing.Sequence[str]]
+ Workflow run IDs to fetch tags for.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- WorkflowTagsBatchResponse
+ RunTagsBatchResponse
Successfully retrieved tags
Examples
@@ -4583,13 +5659,13 @@ class AsyncSkyvern:
async def main() -> None:
- await client.batch_get_workflow_tags_post()
+ await client.batch_get_run_tags_post()
asyncio.run(main())
"""
- _response = await self._raw_client.batch_get_workflow_tags_post(
- workflow_permanent_ids=workflow_permanent_ids, request_options=request_options
+ _response = await self._raw_client.batch_get_run_tags_post(
+ workflow_run_ids=workflow_run_ids, request_options=request_options
)
return _response.data
@@ -4772,6 +5848,7 @@ class AsyncSkyvern:
page_size: typing.Optional[int] = None,
status: typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]] = None,
search_key: typing.Optional[str] = None,
+ run_type: typing.Optional[typing.Union[RunType, typing.Sequence[RunType]]] = None,
request_options: typing.Optional[RequestOptions] = None,
) -> typing.List[TaskRunListItem]:
"""
@@ -4786,6 +5863,8 @@ class AsyncSkyvern:
search_key : typing.Optional[str]
Case-insensitive substring search (min 3 chars for trigram index).
+ run_type : typing.Optional[typing.Union[RunType, typing.Sequence[RunType]]]
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -4816,7 +5895,12 @@ class AsyncSkyvern:
asyncio.run(main())
"""
_response = await self._raw_client.get_runs_v2(
- page=page, page_size=page_size, status=status, search_key=search_key, request_options=request_options
+ page=page,
+ page_size=page_size,
+ status=status,
+ search_key=search_key,
+ run_type=run_type,
+ request_options=request_options,
)
return _response.data
@@ -4865,6 +5949,7 @@ class AsyncSkyvern:
page_size: typing.Optional[int] = None,
include_deleted: typing.Optional[bool] = None,
search_key: typing.Optional[str] = None,
+ managed: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
) -> typing.List[BrowserProfile]:
"""
@@ -4882,6 +5967,9 @@ class AsyncSkyvern:
search_key : typing.Optional[str]
Case-insensitive substring search across: browser profile name and description. A profile is returned if either field matches.
+ managed : typing.Optional[bool]
+ Omit to return all profiles; false returns only user-created profiles; true returns only auto-managed profiles.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -4907,6 +5995,7 @@ class AsyncSkyvern:
page_size=1,
include_deleted=True,
search_key="search_key",
+ managed=True,
)
@@ -4917,6 +6006,7 @@ class AsyncSkyvern:
page_size=page_size,
include_deleted=include_deleted,
search_key=search_key,
+ managed=managed,
request_options=request_options,
)
return _response.data
@@ -5187,6 +6277,7 @@ class AsyncSkyvern:
*,
timeout: typing.Optional[int] = OMIT,
proxy_location: typing.Optional[CreateBrowserSessionRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
extensions: typing.Optional[typing.Sequence[Extensions]] = OMIT,
browser_type: typing.Optional[PersistentBrowserType] = OMIT,
browser_profile_id: typing.Optional[str] = OMIT,
@@ -5238,6 +6329,9 @@ class AsyncSkyvern:
For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}, or a custom proxy URL dict for self-hosted deployments: {"url": "http://user:[email protected]:8080"}
+ proxy_session_id : typing.Optional[str]
+ Opaque Skyvern-managed proxy sticky-session id for pinned Residential ISP sessions.
+
extensions : typing.Optional[typing.Sequence[Extensions]]
A list of extensions to install in the browser session.
@@ -5278,6 +6372,7 @@ class AsyncSkyvern:
_response = await self._raw_client.create_browser_session(
timeout=timeout,
proxy_location=proxy_location,
+ proxy_session_id=proxy_session_id,
extensions=extensions,
browser_type=browser_type,
browser_profile_id=browser_profile_id,
@@ -5824,6 +6919,177 @@ class AsyncSkyvern:
_response = await self._raw_client.get_credential(credential_id, request_options=request_options)
return _response.data
+ async def list_custom_llms(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomLlmListResponse:
+ """
+ List the custom LLM configurations available to the current organization.
+
+ Parameters
+ ----------
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomLlmListResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from skyvern import AsyncSkyvern
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
+
+
+ async def main() -> None:
+ await client.list_custom_llms()
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.list_custom_llms(request_options=request_options)
+ return _response.data
+
+ async def create_custom_llm(
+ self, *, config: CustomLlmConfig, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomLlmResponse:
+ """
+ Create a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ config : CustomLlmConfig
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomLlmResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from skyvern import AsyncSkyvern, CustomLlmConfig
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
+
+
+ async def main() -> None:
+ await client.create_custom_llm(
+ config=CustomLlmConfig(
+ display_name="display_name",
+ provider="openai_compatible",
+ model_name="model_name",
+ ),
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.create_custom_llm(config=config, request_options=request_options)
+ return _response.data
+
+ async def update_custom_llm(
+ self, custom_llm_id: str, *, config: CustomLlmConfig, request_options: typing.Optional[RequestOptions] = None
+ ) -> CustomLlmResponse:
+ """
+ Update a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ custom_llm_id : str
+ The custom LLM id.
+
+ config : CustomLlmConfig
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ CustomLlmResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from skyvern import AsyncSkyvern, CustomLlmConfig
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
+
+
+ async def main() -> None:
+ await client.update_custom_llm(
+ custom_llm_id="custom_llm_id",
+ config=CustomLlmConfig(
+ display_name="display_name",
+ provider="openai_compatible",
+ model_name="model_name",
+ ),
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.update_custom_llm(
+ custom_llm_id, config=config, request_options=request_options
+ )
+ return _response.data
+
+ async def delete_custom_llm(
+ self, custom_llm_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> ClearOrganizationAuthTokenResponse:
+ """
+ Delete a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ custom_llm_id : str
+ The custom LLM id.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ ClearOrganizationAuthTokenResponse
+ Successful Response
+
+ Examples
+ --------
+ import asyncio
+
+ from skyvern import AsyncSkyvern
+
+ client = AsyncSkyvern(
+ api_key="YOUR_API_KEY",
+ )
+
+
+ async def main() -> None:
+ await client.delete_custom_llm(
+ custom_llm_id="custom_llm_id",
+ )
+
+
+ asyncio.run(main())
+ """
+ _response = await self._raw_client.delete_custom_llm(custom_llm_id, request_options=request_options)
+ return _response.data
+
async def login(
self,
*,
@@ -6462,6 +7728,7 @@ class AsyncSkyvern:
*,
tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> TagsResponse:
"""
@@ -6478,6 +7745,9 @@ class AsyncSkyvern:
tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
Tags to soft-delete. List of {key?, value?} targets.
+ colors : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -6506,7 +7776,11 @@ class AsyncSkyvern:
asyncio.run(main())
"""
_response = await self._raw_client.apply_workflow_tags(
- workflow_permanent_id, tags=tags, tags_to_delete=tags_to_delete, request_options=request_options
+ workflow_permanent_id,
+ tags=tags,
+ tags_to_delete=tags_to_delete,
+ colors=colors,
+ request_options=request_options,
)
return _response.data
@@ -6784,6 +8058,8 @@ class AsyncSkyvern:
status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
search_key: typing.Optional[str] = None,
error_code: typing.Optional[str] = None,
+ created_at_start: typing.Optional[dt.datetime] = None,
+ created_at_end: typing.Optional[dt.datetime] = None,
request_options: typing.Optional[RequestOptions] = None,
) -> typing.List[WorkflowRun]:
"""
@@ -6818,6 +8094,12 @@ class AsyncSkyvern:
error_code : typing.Optional[str]
Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+ created_at_start : typing.Optional[dt.datetime]
+ Only include runs created at or after this UTC timestamp (ISO 8601).
+
+ created_at_end : typing.Optional[dt.datetime]
+ Only include runs created strictly before this UTC timestamp (ISO 8601).
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -6829,6 +8111,7 @@ class AsyncSkyvern:
Examples
--------
import asyncio
+ import datetime
from skyvern import AsyncSkyvern
@@ -6844,6 +8127,12 @@ class AsyncSkyvern:
page_size=1,
search_key="search_key",
error_code="error_code",
+ created_at_start=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
+ created_at_end=datetime.datetime.fromisoformat(
+ "2024-01-15 09:30:00+00:00",
+ ),
)
@@ -6856,6 +8145,8 @@ class AsyncSkyvern:
status=status,
search_key=search_key,
error_code=error_code,
+ created_at_start=created_at_start,
+ created_at_end=created_at_end,
request_options=request_options,
)
return _response.data
diff --git a/skyvern/client/core/client_wrapper.py b/skyvern/client/core/client_wrapper.py
index 0e89bf1e6..7c02341d1 100644
--- a/skyvern/client/core/client_wrapper.py
+++ b/skyvern/client/core/client_wrapper.py
@@ -22,10 +22,10 @@ class BaseClientWrapper:
def get_headers(self) -> typing.Dict[str, str]:
headers: typing.Dict[str, str] = {
- "User-Agent": "skyvern/1.0.45",
+ "User-Agent": "skyvern/1.0.47",
"X-Fern-Language": "Python",
"X-Fern-SDK-Name": "skyvern",
- "X-Fern-SDK-Version": "1.0.45",
+ "X-Fern-SDK-Version": "1.0.47",
**(self.get_custom_headers() or {}),
}
if self._api_key is not None:
diff --git a/skyvern/client/raw_client.py b/skyvern/client/raw_client.py
index 7938c1c57..2b386f51d 100644
--- a/skyvern/client/raw_client.py
+++ b/skyvern/client/raw_client.py
@@ -22,6 +22,7 @@ from .types.artifact_type import ArtifactType
from .types.browser_profile import BrowserProfile
from .types.browser_session_response import BrowserSessionResponse
from .types.bulk_cancel_runs_response import BulkCancelRunsResponse
+from .types.clear_organization_auth_token_response import ClearOrganizationAuthTokenResponse
from .types.create_browser_profile_request_proxy_location import CreateBrowserProfileRequestProxyLocation
from .types.create_browser_session_request_proxy_location import CreateBrowserSessionRequestProxyLocation
from .types.create_credential_request_credential import CreateCredentialRequestCredential
@@ -29,6 +30,9 @@ from .types.create_credential_request_proxy_location import CreateCredentialRequ
from .types.create_script_response import CreateScriptResponse
from .types.credential_response import CredentialResponse
from .types.credential_vault_type import CredentialVaultType
+from .types.custom_llm_config import CustomLlmConfig
+from .types.custom_llm_list_response import CustomLlmListResponse
+from .types.custom_llm_response import CustomLlmResponse
from .types.extensions import Extensions
from .types.folder import Folder
from .types.get_run_response import GetRunResponse
@@ -40,6 +44,10 @@ from .types.run_engine import RunEngine
from .types.run_sdk_action_request_action import RunSdkActionRequestAction
from .types.run_sdk_action_response import RunSdkActionResponse
from .types.run_status import RunStatus
+from .types.run_tag_history_response import RunTagHistoryResponse
+from .types.run_tags_batch_response import RunTagsBatchResponse
+from .types.run_tags_response import RunTagsResponse
+from .types.run_type import RunType
from .types.run_webhook_replay_response import RunWebhookReplayResponse
from .types.script import Script
from .types.script_file_create import ScriptFileCreate
@@ -50,6 +58,9 @@ from .types.tag_history_response import TagHistoryResponse
from .types.tag_input import TagInput
from .types.tag_key import TagKey
from .types.tag_key_delete_response import TagKeyDeleteResponse
+from .types.tag_value import TagValue
+from .types.tag_value_delete_response import TagValueDeleteResponse
+from .types.tag_value_rename_response import TagValueRenameResponse
from .types.tags_response import TagsResponse
from .types.task_run_list_item import TaskRunListItem
from .types.task_run_request_input_data_extraction_schema import TaskRunRequestInputDataExtractionSchema
@@ -1327,37 +1338,51 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def list_tag_keys(
- self, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[typing.List[TagKey]]:
+ def get_run_tags(
+ self, workflow_run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[RunTagsResponse]:
"""
- List all tag keys registered for the organization with their descriptions.
+ Get the current tag state for a workflow run.
Parameters
----------
+ workflow_run_id : str
+ Workflow run ID
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[TagKey]]
- Successfully retrieved tag keys
+ HttpResponse[RunTagsResponse]
+ Successfully retrieved tags
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/tag-keys",
+ f"v1/runs/{jsonable_encoder(workflow_run_id)}/tags",
method="GET",
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[TagKey],
+ RunTagsResponse,
parse_obj_as(
- type_=typing.List[TagKey], # type: ignore
+ type_=RunTagsResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -1374,36 +1399,64 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def delete_tag_key(
- self, key: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[TagKeyDeleteResponse]:
+ def apply_run_tags(
+ self,
+ workflow_run_id: str,
+ *,
+ tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
+ tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[RunTagsResponse]:
"""
- Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
+ Atomically apply tag changes to a workflow run. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
Parameters
----------
- key : str
- Tag key to delete
+ workflow_run_id : str
+ Workflow run ID
+
+ tags : typing.Optional[typing.Sequence[TagInput]]
+ Tags to set (overwrite). List of {key?, value} objects.
+
+ tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
+ Tags to soft-delete. List of {key?, value?} targets.
+
+ colors : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[TagKeyDeleteResponse]
- Successfully deleted tag key
+ HttpResponse[RunTagsResponse]
+ Successfully applied tag changes
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/tag-keys/{jsonable_encoder(key)}",
- method="DELETE",
+ f"v1/runs/{jsonable_encoder(workflow_run_id)}/tags",
+ method="POST",
+ json={
+ "tags": convert_and_respect_annotation_metadata(
+ object_=tags, annotation=typing.Sequence[TagInput], direction="write"
+ ),
+ "tags_to_delete": convert_and_respect_annotation_metadata(
+ object_=tags_to_delete, annotation=typing.Sequence[TagDeleteInput], direction="write"
+ ),
+ "colors": colors,
+ },
+ headers={
+ "content-type": "application/json",
+ },
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TagKeyDeleteResponse,
+ RunTagsResponse,
parse_obj_as(
- type_=TagKeyDeleteResponse, # type: ignore
+ type_=RunTagsResponse, # type: ignore
object_=_response.json(),
),
)
@@ -1435,50 +1488,39 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def update_tag_key(
- self,
- key: str,
- *,
- description: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[TagKey]:
+ def delete_run_tag(
+ self, workflow_run_id: str, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[RunTagsResponse]:
"""
- Update the description for a tag key.
+ Soft-delete a single grouped tag from a workflow run. Writes a DELETE event row.
Parameters
----------
- key : str
- Tag key to update
+ workflow_run_id : str
+ Workflow run ID
- description : typing.Optional[str]
- Free-form description (max 500 chars). Pass null to clear.
+ key : str
+ Tag key to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[TagKey]
- Successfully updated tag key
+ HttpResponse[RunTagsResponse]
+ Successfully deleted tag (or no-op if absent)
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/tag-keys/{jsonable_encoder(key)}",
- method="PATCH",
- json={
- "description": description,
- },
- headers={
- "content-type": "application/json",
- },
+ f"v1/runs/{jsonable_encoder(workflow_run_id)}/tags/{jsonable_encoder(key)}",
+ method="DELETE",
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TagKey,
+ RunTagsResponse,
parse_obj_as(
- type_=TagKey, # type: ignore
+ type_=RunTagsResponse, # type: ignore
object_=_response.json(),
),
)
@@ -1510,48 +1552,62 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def batch_get_workflow_tags(
+ def get_run_tag_history(
self,
+ workflow_run_id: str,
*,
- workflow_permanent_ids: typing.Optional[str] = None,
+ limit: typing.Optional[int] = None,
+ since: typing.Optional[dt.datetime] = None,
+ key: typing.Optional[str] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[WorkflowTagsBatchResponse]:
+ ) -> HttpResponse[RunTagHistoryResponse]:
"""
- Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
+ Chronological tag-event log for a workflow run (newest first). Includes SET and DELETE events.
Parameters
----------
- workflow_permanent_ids : typing.Optional[str]
- Comma-separated workflow permanent IDs
+ workflow_run_id : str
+ Workflow run ID
+
+ limit : typing.Optional[int]
+ Max events to return
+
+ since : typing.Optional[dt.datetime]
+ Only return events at or after this timestamp
+
+ key : typing.Optional[str]
+ Filter to events for a single tag key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[WorkflowTagsBatchResponse]
- Successfully retrieved tags
+ HttpResponse[RunTagHistoryResponse]
+ Successfully retrieved tag history
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/workflow-tags",
+ f"v1/runs/{jsonable_encoder(workflow_run_id)}/tags/history",
method="GET",
params={
- "workflow_permanent_ids": workflow_permanent_ids,
+ "limit": limit,
+ "since": serialize_datetime(since) if since is not None else None,
+ "key": key,
},
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- WorkflowTagsBatchResponse,
+ RunTagHistoryResponse,
parse_obj_as(
- type_=WorkflowTagsBatchResponse, # type: ignore
+ type_=RunTagHistoryResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 400:
- raise BadRequestError(
+ if _response.status_code == 404:
+ raise NotFoundError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -1577,61 +1633,37 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def batch_get_workflow_tags_post(
- self,
- *,
- workflow_permanent_ids: typing.Optional[typing.Sequence[str]] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[WorkflowTagsBatchResponse]:
+ def list_tag_keys(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[typing.List[TagKey]]:
"""
- Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
+ List all tag keys registered for the organization with their descriptions.
Parameters
----------
- workflow_permanent_ids : typing.Optional[typing.Sequence[str]]
- Workflow permanent IDs to fetch tags for.
-
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[WorkflowTagsBatchResponse]
- Successfully retrieved tags
+ HttpResponse[typing.List[TagKey]]
+ Successfully retrieved tag keys
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/workflow-tags",
- method="POST",
- json={
- "workflow_permanent_ids": workflow_permanent_ids,
- },
- headers={
- "content-type": "application/json",
- },
+ "v1/tag-keys",
+ method="GET",
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- WorkflowTagsBatchResponse,
+ typing.List[TagKey],
parse_obj_as(
- type_=WorkflowTagsBatchResponse, # type: ignore
+ type_=typing.List[TagKey], # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 400:
- raise BadRequestError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -1648,49 +1680,51 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_run_artifacts(
- self,
- run_id: str,
- *,
- artifact_type: typing.Optional[typing.Union[ArtifactType, typing.Sequence[ArtifactType]]] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[typing.List[Artifact]]:
+ def delete_tag_key(
+ self, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[TagKeyDeleteResponse]:
"""
- Get artifacts for a run
+ Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
Parameters
----------
- run_id : str
- The id of the task run or the workflow run.
-
- artifact_type : typing.Optional[typing.Union[ArtifactType, typing.Sequence[ArtifactType]]]
+ key : str
+ Tag key to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[Artifact]]
- Successful Response
+ HttpResponse[TagKeyDeleteResponse]
+ Successfully deleted tag key
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/runs/{jsonable_encoder(run_id)}/artifacts",
- method="GET",
- params={
- "artifact_type": artifact_type,
- },
+ f"v1/tag-keys/{jsonable_encoder(key)}",
+ method="DELETE",
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[Artifact],
+ TagKeyDeleteResponse,
parse_obj_as(
- type_=typing.List[Artifact], # type: ignore
+ type_=TagKeyDeleteResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -1707,37 +1741,38 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def retry_run_webhook(
+ def update_tag_key(
self,
- run_id: str,
+ key: str,
*,
- request: typing.Optional[RetryRunWebhookRequest] = None,
+ description: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[RunWebhookReplayResponse]:
+ ) -> HttpResponse[TagKey]:
"""
- Retry sending the webhook for a run
+ Update the description for a tag key.
Parameters
----------
- run_id : str
- The id of the task run or the workflow run.
+ key : str
+ Tag key to update
- request : typing.Optional[RetryRunWebhookRequest]
+ description : typing.Optional[str]
+ Free-form description (max 500 chars). Pass null to clear.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[RunWebhookReplayResponse]
- Successful Response
+ HttpResponse[TagKey]
+ Successfully updated tag key
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/runs/{jsonable_encoder(run_id)}/retry_webhook",
- method="POST",
- json=convert_and_respect_annotation_metadata(
- object_=request, annotation=RetryRunWebhookRequest, direction="write"
- ),
+ f"v1/tag-keys/{jsonable_encoder(key)}",
+ method="PATCH",
+ json={
+ "description": description,
+ },
headers={
"content-type": "application/json",
},
@@ -1747,76 +1782,15 @@ class RawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- RunWebhookReplayResponse,
+ TagKey,
parse_obj_as(
- type_=RunWebhookReplayResponse, # type: ignore
+ type_=TagKey, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 422:
- raise UnprocessableEntityError(
- headers=dict(_response.headers),
- body=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, headers=dict(_response.headers), body=_response.text)
- raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
-
- def get_run_timeline(
- self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[typing.List[WorkflowRunTimeline]]:
- """
- Get timeline for a run (workflow run or task_v2 run)
-
- Parameters
- ----------
- run_id : str
- The id of the workflow run or task_v2 run.
-
- request_options : typing.Optional[RequestOptions]
- Request-specific configuration.
-
- Returns
- -------
- HttpResponse[typing.List[WorkflowRunTimeline]]
- Successfully retrieved run timeline
- """
- _response = self._client_wrapper.httpx_client.request(
- f"v1/runs/{jsonable_encoder(run_id)}/timeline",
- method="GET",
- request_options=request_options,
- )
- try:
- if 200 <= _response.status_code < 300:
- _data = typing.cast(
- typing.List[WorkflowRunTimeline],
- parse_obj_as(
- type_=typing.List[WorkflowRunTimeline], # type: ignore
- object_=_response.json(),
- ),
- )
- return HttpResponse(response=_response, data=_data)
- if _response.status_code == 400:
- raise BadRequestError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
- if _response.status_code == 404:
- raise NotFoundError(
+ if _response.status_code == 404:
+ raise NotFoundError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -1842,88 +1816,39 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_version(
- self, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[typing.Dict[str, str]]:
- """
- Returns the current Skyvern server version (git SHA for official builds).
-
- Parameters
- ----------
- request_options : typing.Optional[RequestOptions]
- Request-specific configuration.
-
- Returns
- -------
- HttpResponse[typing.Dict[str, str]]
- Current server version
+ def list_tag_values(
+ self, *, key: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[typing.List[TagValue]]:
"""
- _response = self._client_wrapper.httpx_client.request(
- "v1/version",
- method="GET",
- request_options=request_options,
- )
- try:
- if 200 <= _response.status_code < 300:
- _data = typing.cast(
- typing.Dict[str, str],
- parse_obj_as(
- type_=typing.Dict[str, str], # type: ignore
- object_=_response.json(),
- ),
- )
- return HttpResponse(response=_response, data=_data)
- _response_json = _response.json()
- except JSONDecodeError:
- raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
- raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ List the palette color and current workflow usage count for each grouped tag (key, value) for the organization. The frontend joins these onto tags by (key, value); workflow_count is the number of non-deleted workflows carrying the label and powers the per-label usage and delete blast-radius warnings.
- def get_runs_v2(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- status: typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]] = None,
- search_key: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[typing.List[TaskRunListItem]]:
- """
Parameters
----------
- page : typing.Optional[int]
-
- page_size : typing.Optional[int]
-
- status : typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]]
-
- search_key : typing.Optional[str]
- Case-insensitive substring search (min 3 chars for trigram index).
+ key : typing.Optional[str]
+ Filter to values for a single tag key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[TaskRunListItem]]
- Successful Response
+ HttpResponse[typing.List[TagValue]]
+ Successfully retrieved tag values
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/runs",
+ "v1/tag-values",
method="GET",
params={
- "page": page,
- "page_size": page_size,
- "status": status,
- "search_key": search_key,
+ "key": key,
},
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[TaskRunListItem],
+ typing.List[TagValue],
parse_obj_as(
- type_=typing.List[TaskRunListItem], # type: ignore
+ type_=typing.List[TagValue], # type: ignore
object_=_response.json(),
),
)
@@ -1944,43 +1869,61 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def upload_file(
- self, *, file: str, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[UploadFileResponse]:
+ def delete_tag_value(
+ self, key: str, *, value: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[TagValueDeleteResponse]:
"""
+ Soft-delete a grouped tag (key, value) and remove that label from every workflow carrying it (cascade). The value rides in the body so values containing '/' stay addressable. Returns how many workflows the label was removed from.
+
Parameters
----------
- file : str
+ key : str
+ Tag key (group)
+
+ value : str
+ Tag value (label) under the key to soft-delete.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[UploadFileResponse]
- Successful Response
+ HttpResponse[TagValueDeleteResponse]
+ Successfully deleted tag value
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/upload_file",
- method="POST",
- data={
- "file": file,
+ f"v1/tag-values/{jsonable_encoder(key)}",
+ method="DELETE",
+ json={
+ "value": value,
+ },
+ headers={
+ "content-type": "application/json",
},
- files={},
request_options=request_options,
omit=OMIT,
- force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- UploadFileResponse,
+ TagValueDeleteResponse,
parse_obj_as(
- type_=UploadFileResponse, # type: ignore
+ type_=TagValueDeleteResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -1997,59 +1940,65 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def list_browser_profiles(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- include_deleted: typing.Optional[bool] = None,
- search_key: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[typing.List[BrowserProfile]]:
+ def update_tag_value(
+ self, key: str, *, value: str, color: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[TagValue]:
"""
- Get all browser profiles for the organization
+ Recolor a grouped tag (key, value). The value is supplied in the body so values containing '/' stay addressable. The new color must be a palette name.
Parameters
----------
- page : typing.Optional[int]
-
- page_size : typing.Optional[int]
+ key : str
+ Tag key (group)
- include_deleted : typing.Optional[bool]
- Include deleted browser profiles
+ value : str
+ Tag value (label) under the key to recolor.
- search_key : typing.Optional[str]
- Case-insensitive substring search across: browser profile name and description. A profile is returned if either field matches.
+ color : str
+ Palette color name to assign to this (key, value).
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[BrowserProfile]]
- Successfully retrieved browser profiles
+ HttpResponse[TagValue]
+ Successfully recolored tag value
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/browser_profiles",
- method="GET",
- params={
- "page": page,
- "page_size": page_size,
- "include_deleted": include_deleted,
- "search_key": search_key,
+ f"v1/tag-values/{jsonable_encoder(key)}",
+ method="PATCH",
+ json={
+ "value": value,
+ "color": color,
+ },
+ headers={
+ "content-type": "application/json",
},
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[BrowserProfile],
+ TagValue,
parse_obj_as(
- type_=typing.List[BrowserProfile], # type: ignore
+ type_=TagValue, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -2066,60 +2015,37 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def create_browser_profile(
- self,
- *,
- name: str,
- description: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- workflow_run_id: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[CreateBrowserProfileRequestProxyLocation] = OMIT,
- proxy_session_id: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[BrowserProfile]:
+ def rename_tag_value(
+ self, key: str, *, value: str, new_value: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[TagValueRenameResponse]:
"""
- Create a blank browser profile, or create one from a persistent browser session or workflow run.
+ Rename a grouped tag (key, value) to (key, new_value). The cascade re-tags every workflow carrying the old label; the new label inherits the old color. Both values ride in the body so values containing '/' stay addressable. Rejects with 409 when the new value already exists for the key.
Parameters
----------
- name : str
- Name for the browser profile
-
- description : typing.Optional[str]
- Optional profile description
-
- browser_session_id : typing.Optional[str]
- Persistent browser session to convert into a profile. Omit for a blank profile.
-
- workflow_run_id : typing.Optional[str]
- Workflow run whose persisted session should be captured. Omit for a blank profile.
+ key : str
+ Tag key (group)
- proxy_location : typing.Optional[CreateBrowserProfileRequestProxyLocation]
- Optional proxy location for this profile's pinned proxy identity.
+ value : str
+ Current tag value (label) under the key to rename.
- proxy_session_id : typing.Optional[str]
- Explicit sticky-session id for this profile's pinned proxy identity.
+ new_value : str
+ New tag value (label) to rename it to.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[BrowserProfile]
- Successfully created browser profile
+ HttpResponse[TagValueRenameResponse]
+ Successfully renamed tag value
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/browser_profiles",
- method="POST",
+ f"v1/tag-values/{jsonable_encoder(key)}/rename",
+ method="PATCH",
json={
- "name": name,
- "description": description,
- "browser_session_id": browser_session_id,
- "workflow_run_id": workflow_run_id,
- "proxy_location": convert_and_respect_annotation_metadata(
- object_=proxy_location, annotation=CreateBrowserProfileRequestProxyLocation, direction="write"
- ),
- "proxy_session_id": proxy_session_id,
+ "value": value,
+ "new_value": new_value,
},
headers={
"content-type": "application/json",
@@ -2130,15 +2056,15 @@ class RawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- BrowserProfile,
+ TagValueRenameResponse,
parse_obj_as(
- type_=BrowserProfile, # type: ignore
+ type_=TagValueRenameResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 400:
- raise BadRequestError(
+ if _response.status_code == 404:
+ raise NotFoundError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -2175,42 +2101,48 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_browser_profile(
- self, profile_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[BrowserProfile]:
- """
- Get a specific browser profile by ID
-
- Parameters
- ----------
- profile_id : str
- The ID of the browser profile. browser_profile_id starts with `bp_`
+ def batch_get_workflow_tags(
+ self,
+ *,
+ workflow_permanent_ids: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[WorkflowTagsBatchResponse]:
+ """
+ Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
+
+ Parameters
+ ----------
+ workflow_permanent_ids : typing.Optional[str]
+ Comma-separated workflow permanent IDs
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[BrowserProfile]
- Successfully retrieved browser profile
+ HttpResponse[WorkflowTagsBatchResponse]
+ Successfully retrieved tags
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/browser_profiles/{jsonable_encoder(profile_id)}",
+ "v1/workflow-tags",
method="GET",
+ params={
+ "workflow_permanent_ids": workflow_permanent_ids,
+ },
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- BrowserProfile,
+ WorkflowTagsBatchResponse,
parse_obj_as(
- type_=BrowserProfile, # type: ignore
+ type_=WorkflowTagsBatchResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 404:
- raise NotFoundError(
+ if _response.status_code == 400:
+ raise BadRequestError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -2236,34 +2168,52 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def delete_browser_profile(
- self, profile_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[None]:
+ def batch_get_workflow_tags_post(
+ self,
+ *,
+ workflow_permanent_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[WorkflowTagsBatchResponse]:
"""
- Delete a browser profile (soft delete)
+ Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
Parameters
----------
- profile_id : str
- The ID of the browser profile to delete. browser_profile_id starts with `bp_`
+ workflow_permanent_ids : typing.Optional[typing.Sequence[str]]
+ Workflow permanent IDs to fetch tags for.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[None]
+ HttpResponse[WorkflowTagsBatchResponse]
+ Successfully retrieved tags
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/browser_profiles/{jsonable_encoder(profile_id)}",
- method="DELETE",
+ "v1/workflow-tags",
+ method="POST",
+ json={
+ "workflow_permanent_ids": workflow_permanent_ids,
+ },
+ headers={
+ "content-type": "application/json",
+ },
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
- return HttpResponse(response=_response, data=None)
- if _response.status_code == 404:
- raise NotFoundError(
+ _data = typing.cast(
+ WorkflowTagsBatchResponse,
+ parse_obj_as(
+ type_=WorkflowTagsBatchResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -2289,89 +2239,45 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def update_browser_profile(
- self,
- profile_id: str,
- *,
- name: typing.Optional[str] = OMIT,
- description: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[UpdateBrowserProfileRequestProxyLocation] = OMIT,
- proxy_session_id: typing.Optional[str] = OMIT,
- rotate_proxy_session_id: typing.Optional[bool] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[BrowserProfile]:
+ def batch_get_run_tags(
+ self, *, workflow_run_ids: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[RunTagsBatchResponse]:
"""
- Update a browser profile's name and/or description
+ Batch fetch current tags for many workflow runs. Avoids N+1 on run-list pages.
Parameters
----------
- profile_id : str
- The ID of the browser profile to update. browser_profile_id starts with `bp_`
-
- name : typing.Optional[str]
- New name for the browser profile
-
- description : typing.Optional[str]
- New description for the browser profile
-
- proxy_location : typing.Optional[UpdateBrowserProfileRequestProxyLocation]
- Optional proxy location for this profile's pinned proxy identity.
-
- proxy_session_id : typing.Optional[str]
- Opaque Skyvern-managed proxy sticky-session id.
-
- rotate_proxy_session_id : typing.Optional[bool]
- Rotate the Skyvern-managed proxy sticky-session id for this profile.
+ workflow_run_ids : typing.Optional[str]
+ Comma-separated workflow run IDs
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[BrowserProfile]
- Successfully updated browser profile
+ HttpResponse[RunTagsBatchResponse]
+ Successfully retrieved tags
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/browser_profiles/{jsonable_encoder(profile_id)}",
- method="PATCH",
- json={
- "name": name,
- "description": description,
- "proxy_location": convert_and_respect_annotation_metadata(
- object_=proxy_location, annotation=UpdateBrowserProfileRequestProxyLocation, direction="write"
- ),
- "proxy_session_id": proxy_session_id,
- "rotate_proxy_session_id": rotate_proxy_session_id,
- },
- headers={
- "content-type": "application/json",
+ "v1/run-tags",
+ method="GET",
+ params={
+ "workflow_run_ids": workflow_run_ids,
},
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- BrowserProfile,
+ RunTagsBatchResponse,
parse_obj_as(
- type_=BrowserProfile, # type: ignore
+ type_=RunTagsBatchResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 404:
- raise NotFoundError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
- if _response.status_code == 409:
- raise ConflictError(
+ if _response.status_code == 400:
+ raise BadRequestError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -2397,39 +2303,52 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_browser_sessions(
- self, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[typing.List[BrowserSessionResponse]]:
+ def batch_get_run_tags_post(
+ self,
+ *,
+ workflow_run_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[RunTagsBatchResponse]:
"""
- Get all active browser sessions for the organization
+ Batch fetch current tags for many workflow runs (POST variant for id lists exceeding URL length).
Parameters
----------
+ workflow_run_ids : typing.Optional[typing.Sequence[str]]
+ Workflow run IDs to fetch tags for.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[BrowserSessionResponse]]
- Successfully retrieved all active browser sessions
+ HttpResponse[RunTagsBatchResponse]
+ Successfully retrieved tags
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/browser_sessions",
- method="GET",
+ "v1/run-tags",
+ method="POST",
+ json={
+ "workflow_run_ids": workflow_run_ids,
+ },
+ headers={
+ "content-type": "application/json",
+ },
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[BrowserSessionResponse],
+ RunTagsBatchResponse,
parse_obj_as(
- type_=typing.List[BrowserSessionResponse], # type: ignore
+ type_=RunTagsBatchResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 403:
- raise ForbiddenError(
+ if _response.status_code == 400:
+ raise BadRequestError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -2455,133 +2374,49 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def create_browser_session(
+ def get_run_artifacts(
self,
+ run_id: str,
*,
- timeout: typing.Optional[int] = OMIT,
- proxy_location: typing.Optional[CreateBrowserSessionRequestProxyLocation] = OMIT,
- extensions: typing.Optional[typing.Sequence[Extensions]] = OMIT,
- browser_type: typing.Optional[PersistentBrowserType] = OMIT,
- browser_profile_id: typing.Optional[str] = OMIT,
- generate_browser_profile: typing.Optional[bool] = OMIT,
+ artifact_type: typing.Optional[typing.Union[ArtifactType, typing.Sequence[ArtifactType]]] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[BrowserSessionResponse]:
+ ) -> HttpResponse[typing.List[Artifact]]:
"""
- Create a browser session that persists across multiple runs
+ Get artifacts for a run
Parameters
----------
- timeout : typing.Optional[int]
- Timeout in minutes for the session. Timeout is applied after the session is started. Must be between 5 and 1440. Defaults to 60.
-
- proxy_location : typing.Optional[CreateBrowserSessionRequestProxyLocation]
-
- Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
-
- Available geotargeting options:
- - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
- - RESIDENTIAL_ES: Spain
- - RESIDENTIAL_IE: Ireland
- - RESIDENTIAL_GB: United Kingdom
- - RESIDENTIAL_IN: India
- - RESIDENTIAL_JP: Japan
- - RESIDENTIAL_FR: France
- - RESIDENTIAL_DE: Germany
- - RESIDENTIAL_NZ: New Zealand
- - RESIDENTIAL_PH: Philippines
- - RESIDENTIAL_KR: South Korea
- - RESIDENTIAL_SA: Saudi Arabia
- - RESIDENTIAL_ZA: South Africa
- - RESIDENTIAL_AR: Argentina
- - RESIDENTIAL_AU: Australia
- - RESIDENTIAL_BR: Brazil
- - RESIDENTIAL_TR: Turkey
- - RESIDENTIAL_CA: Canada
- - RESIDENTIAL_MX: Mexico
- - RESIDENTIAL_IT: Italy
- - RESIDENTIAL_NL: Netherlands
- - RESIDENTIAL_ISP: ISP proxy
- - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
- - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
- - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
- - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
- - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
- - NONE: No proxy
-
- For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
- Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}, or a custom proxy URL dict for self-hosted deployments: {"url": "http://user:[email protected]:8080"}
-
- extensions : typing.Optional[typing.Sequence[Extensions]]
- A list of extensions to install in the browser session.
-
- browser_type : typing.Optional[PersistentBrowserType]
- The type of browser to use for the session.
-
- browser_profile_id : typing.Optional[str]
- ID of a browser profile to load into this session (restores cookies, localStorage, etc.). browser_profile_id starts with `bp_`.
+ run_id : str
+ The id of the task run or the workflow run.
- generate_browser_profile : typing.Optional[bool]
- When true, the session's browser profile (cookies, localStorage, etc.) is saved to storage when the session ends so it can be turned into a reusable browser profile. Defaults to false to avoid storing profiles for sessions that never need them. Sessions started with a browser_profile_id always persist their profile regardless of this flag.
+ artifact_type : typing.Optional[typing.Union[ArtifactType, typing.Sequence[ArtifactType]]]
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[BrowserSessionResponse]
- Successfully created browser session
+ HttpResponse[typing.List[Artifact]]
+ Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/browser_sessions",
- method="POST",
- json={
- "timeout": timeout,
- "proxy_location": convert_and_respect_annotation_metadata(
- object_=proxy_location, annotation=CreateBrowserSessionRequestProxyLocation, direction="write"
- ),
- "extensions": extensions,
- "browser_type": browser_type,
- "browser_profile_id": browser_profile_id,
- "generate_browser_profile": generate_browser_profile,
- },
- headers={
- "content-type": "application/json",
+ f"v1/runs/{jsonable_encoder(run_id)}/artifacts",
+ method="GET",
+ params={
+ "artifact_type": artifact_type,
},
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- BrowserSessionResponse,
+ typing.List[Artifact],
parse_obj_as(
- type_=BrowserSessionResponse, # type: ignore
+ type_=typing.List[Artifact], # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 403:
- raise ForbiddenError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
- if _response.status_code == 404:
- raise NotFoundError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -2598,53 +2433,53 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def close_browser_session(
- self, browser_session_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[typing.Optional[typing.Any]]:
+ def retry_run_webhook(
+ self,
+ run_id: str,
+ *,
+ request: typing.Optional[RetryRunWebhookRequest] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[RunWebhookReplayResponse]:
"""
- Close a session. Once closed, the session cannot be used again.
+ Retry sending the webhook for a run
Parameters
----------
- browser_session_id : str
- The ID of the browser session to close. completed_at will be set when the browser session is closed. browser_session_id starts with `pbs_`
+ run_id : str
+ The id of the task run or the workflow run.
+
+ request : typing.Optional[RetryRunWebhookRequest]
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.Optional[typing.Any]]
- Successfully closed browser session
+ HttpResponse[RunWebhookReplayResponse]
+ Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/browser_sessions/{jsonable_encoder(browser_session_id)}/close",
+ f"v1/runs/{jsonable_encoder(run_id)}/retry_webhook",
method="POST",
+ json=convert_and_respect_annotation_metadata(
+ object_=request, annotation=RetryRunWebhookRequest, direction="write"
+ ),
+ headers={
+ "content-type": "application/json",
+ },
request_options=request_options,
+ omit=OMIT,
)
try:
- if _response is None or not _response.text.strip():
- return HttpResponse(response=_response, data=None)
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.Optional[typing.Any],
+ RunWebhookReplayResponse,
parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
+ type_=RunWebhookReplayResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 403:
- raise ForbiddenError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -2661,42 +2496,42 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_browser_session(
- self, browser_session_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[BrowserSessionResponse]:
+ def get_run_timeline(
+ self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[typing.List[WorkflowRunTimeline]]:
"""
- Get details about a specific browser session, including the browser address for cdp connection.
+ Get timeline for a run (workflow run or task_v2 run)
Parameters
----------
- browser_session_id : str
- The ID of the browser session. browser_session_id starts with `pbs_`
+ run_id : str
+ The id of the workflow run or task_v2 run.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[BrowserSessionResponse]
- Successfully retrieved browser session details
+ HttpResponse[typing.List[WorkflowRunTimeline]]
+ Successfully retrieved run timeline
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/browser_sessions/{jsonable_encoder(browser_session_id)}",
+ f"v1/runs/{jsonable_encoder(run_id)}/timeline",
method="GET",
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- BrowserSessionResponse,
+ typing.List[WorkflowRunTimeline],
parse_obj_as(
- type_=BrowserSessionResponse, # type: ignore
+ type_=typing.List[WorkflowRunTimeline], # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 403:
- raise ForbiddenError(
+ if _response.status_code == 400:
+ raise BadRequestError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -2733,178 +2568,92 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def update_browser_session(
- self,
- browser_session_id: str,
- *,
- generate_browser_profile: bool,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[BrowserSessionResponse]:
+ def get_version(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[typing.Dict[str, str]]:
"""
- Update a live browser session. Currently supports toggling generate_browser_profile, which is read when the session ends to decide whether to save its browser profile.
+ Returns the current Skyvern server version (git SHA for official builds).
Parameters
----------
- browser_session_id : str
- The ID of the browser session. browser_session_id starts with `pbs_`
-
- generate_browser_profile : bool
- Enable or disable saving this session's browser profile when it ends. Can be toggled while the session is still alive; the value is read at session teardown.
-
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[BrowserSessionResponse]
- Successfully updated browser session
+ HttpResponse[typing.Dict[str, str]]
+ Current server version
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/browser_sessions/{jsonable_encoder(browser_session_id)}",
- method="PATCH",
- json={
- "generate_browser_profile": generate_browser_profile,
- },
- headers={
- "content-type": "application/json",
- },
+ "v1/version",
+ method="GET",
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- BrowserSessionResponse,
+ typing.Dict[str, str],
parse_obj_as(
- type_=BrowserSessionResponse, # type: ignore
+ type_=typing.Dict[str, str], # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 403:
- raise ForbiddenError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
- if _response.status_code == 404:
- raise NotFoundError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
- if _response.status_code == 409:
- raise ConflictError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
- if _response.status_code == 422:
- raise UnprocessableEntityError(
- headers=dict(_response.headers),
- body=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, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def send_totp_code(
+ def get_runs_v2(
self,
*,
- totp_identifier: str,
- content: str,
- task_id: typing.Optional[str] = OMIT,
- workflow_id: typing.Optional[str] = OMIT,
- workflow_run_id: typing.Optional[str] = OMIT,
- source: typing.Optional[str] = OMIT,
- expired_at: typing.Optional[dt.datetime] = OMIT,
- type: typing.Optional[OtpType] = OMIT,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ status: typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]] = None,
+ search_key: typing.Optional[str] = None,
+ run_type: typing.Optional[typing.Union[RunType, typing.Sequence[RunType]]] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[TotpCode]:
+ ) -> HttpResponse[typing.List[TaskRunListItem]]:
"""
- Forward a TOTP (2FA, MFA) email or sms message containing the code to Skyvern. This endpoint stores the code in database so that Skyvern can use it while running tasks/workflows.
-
Parameters
----------
- totp_identifier : str
- The identifier of the TOTP code. It can be the email address, phone number, or the identifier of the user.
-
- content : str
- The content of the TOTP code. It can be the email content that contains the TOTP code, or the sms message that contains the TOTP code. Skyvern will automatically extract the TOTP code from the content.
-
- task_id : typing.Optional[str]
- The task_id the totp code is for. It can be the task_id of the task that the TOTP code is for.
-
- workflow_id : typing.Optional[str]
- The workflow ID the TOTP code is for. It can be the workflow ID of the workflow that the TOTP code is for.
+ page : typing.Optional[int]
- workflow_run_id : typing.Optional[str]
- The workflow run id that the TOTP code is for. It can be the workflow run id of the workflow run that the TOTP code is for.
+ page_size : typing.Optional[int]
- source : typing.Optional[str]
- An optional field. The source of the TOTP code. e.g. email, sms, etc.
+ status : typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]]
- expired_at : typing.Optional[dt.datetime]
- The timestamp when the TOTP code expires
+ search_key : typing.Optional[str]
+ Case-insensitive substring search (min 3 chars for trigram index).
- type : typing.Optional[OtpType]
- Optional. If provided, forces extraction of this specific OTP type (totp or magic_link). Use this when the content contains multiple OTP types and you want to specify which one to extract.
+ run_type : typing.Optional[typing.Union[RunType, typing.Sequence[RunType]]]
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[TotpCode]
+ HttpResponse[typing.List[TaskRunListItem]]
Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/credentials/totp",
- method="POST",
- json={
- "totp_identifier": totp_identifier,
- "task_id": task_id,
- "workflow_id": workflow_id,
- "workflow_run_id": workflow_run_id,
- "source": source,
- "content": content,
- "expired_at": expired_at,
- "type": type,
- },
- headers={
- "content-type": "application/json",
+ "v1/runs",
+ method="GET",
+ params={
+ "page": page,
+ "page_size": page_size,
+ "status": status,
+ "search_key": search_key,
+ "run_type": run_type,
},
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TotpCode,
+ typing.List[TaskRunListItem],
parse_obj_as(
- type_=TotpCode, # type: ignore
+ type_=typing.List[TaskRunListItem], # type: ignore
object_=_response.json(),
),
)
@@ -2925,62 +2674,39 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_credentials(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- vault_type: typing.Optional[CredentialVaultType] = None,
- credential_type: typing.Optional[SkyvernForgeSdkSchemasCredentialsCredentialType] = None,
- search: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[typing.List[CredentialResponse]]:
+ def upload_file(
+ self, *, file: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[UploadFileResponse]:
"""
- 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
-
- vault_type : typing.Optional[CredentialVaultType]
- Filter credentials by vault type (e.g. 'skyvern', 'custom', 'bitwarden', 'azure_vault')
-
- credential_type : typing.Optional[SkyvernForgeSdkSchemasCredentialsCredentialType]
- Filter credentials by type (e.g. 'password', 'credit_card', 'secret')
-
- search : typing.Optional[str]
- Case-insensitive search across credential name, username, secret label, and card details
+ file : str
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[CredentialResponse]]
+ HttpResponse[UploadFileResponse]
Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/credentials",
- method="GET",
- params={
- "page": page,
- "page_size": page_size,
- "vault_type": vault_type,
- "credential_type": credential_type,
- "search": search,
+ "v1/upload_file",
+ method="POST",
+ data={
+ "file": file,
},
+ files={},
request_options=request_options,
+ omit=OMIT,
+ force_multipart=True,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[CredentialResponse],
+ UploadFileResponse,
parse_obj_as(
- type_=typing.List[CredentialResponse], # type: ignore
+ type_=UploadFileResponse, # type: ignore
object_=_response.json(),
),
)
@@ -3001,80 +2727,60 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def create_credential(
+ def list_browser_profiles(
self,
*,
- name: str,
- credential_type: SkyvernForgeSdkSchemasCredentialsCredentialType,
- credential: CreateCredentialRequestCredential,
- vault_type: typing.Optional[CredentialVaultType] = OMIT,
- proxy_location: typing.Optional[CreateCredentialRequestProxyLocation] = OMIT,
- proxy_session_id: typing.Optional[str] = OMIT,
- rotate_proxy_session_id: typing.Optional[bool] = OMIT,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ include_deleted: typing.Optional[bool] = None,
+ search_key: typing.Optional[str] = None,
+ managed: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[CredentialResponse]:
+ ) -> HttpResponse[typing.List[BrowserProfile]]:
"""
- Creates a new credential for the current organization
+ Get all browser profiles for the organization
Parameters
----------
- name : str
- Name of the credential
-
- credential_type : SkyvernForgeSdkSchemasCredentialsCredentialType
- Type of credential to create
-
- credential : CreateCredentialRequestCredential
- The credential data to store
+ page : typing.Optional[int]
- vault_type : typing.Optional[CredentialVaultType]
- Which vault to store this credential in. If omitted, uses the instance default. Use this to mix Skyvern-hosted and custom credentials within the same organization.
+ page_size : typing.Optional[int]
- proxy_location : typing.Optional[CreateCredentialRequestProxyLocation]
- Optional proxy location for this credential's pinned proxy identity.
+ include_deleted : typing.Optional[bool]
+ Include deleted browser profiles
- proxy_session_id : typing.Optional[str]
- Optional advanced reuse key for this credential's pinned proxy identity.
+ search_key : typing.Optional[str]
+ Case-insensitive substring search across: browser profile name and description. A profile is returned if either field matches.
- rotate_proxy_session_id : typing.Optional[bool]
- Rotate the Skyvern-managed proxy sticky-session id when updating this credential.
+ managed : typing.Optional[bool]
+ Omit to return all profiles; false returns only user-created profiles; true returns only auto-managed profiles.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[CredentialResponse]
- Successful Response
+ HttpResponse[typing.List[BrowserProfile]]
+ Successfully retrieved browser profiles
"""
_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"
- ),
- "vault_type": vault_type,
- "proxy_location": convert_and_respect_annotation_metadata(
- object_=proxy_location, annotation=CreateCredentialRequestProxyLocation, direction="write"
- ),
- "proxy_session_id": proxy_session_id,
- "rotate_proxy_session_id": rotate_proxy_session_id,
- },
- headers={
- "content-type": "application/json",
+ "v1/browser_profiles",
+ method="GET",
+ params={
+ "page": page,
+ "page_size": page_size,
+ "include_deleted": include_deleted,
+ "search_key": search_key,
+ "managed": managed,
},
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- CredentialResponse,
+ typing.List[BrowserProfile],
parse_obj_as(
- type_=CredentialResponse, # type: ignore
+ type_=typing.List[BrowserProfile], # type: ignore
object_=_response.json(),
),
)
@@ -3095,71 +2801,60 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def update_credential(
+ def create_browser_profile(
self,
- credential_id: str,
*,
name: str,
- credential_type: SkyvernForgeSdkSchemasCredentialsCredentialType,
- credential: CreateCredentialRequestCredential,
- vault_type: typing.Optional[CredentialVaultType] = OMIT,
- proxy_location: typing.Optional[CreateCredentialRequestProxyLocation] = OMIT,
+ description: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ workflow_run_id: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[CreateBrowserProfileRequestProxyLocation] = OMIT,
proxy_session_id: typing.Optional[str] = OMIT,
- rotate_proxy_session_id: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[CredentialResponse]:
+ ) -> HttpResponse[BrowserProfile]:
"""
- Overwrites the stored credential data (e.g. username/password) while keeping the same credential_id.
+ Create a blank browser profile, or create one from a persistent browser session or workflow run.
Parameters
----------
- credential_id : str
- The unique identifier of the credential to update
-
name : str
- Name of the credential
+ Name for the browser profile
- credential_type : SkyvernForgeSdkSchemasCredentialsCredentialType
- Type of credential to create
+ description : typing.Optional[str]
+ Optional profile description
- credential : CreateCredentialRequestCredential
- The credential data to store
+ browser_session_id : typing.Optional[str]
+ Persistent browser session to convert into a profile. Omit for a blank profile.
- vault_type : typing.Optional[CredentialVaultType]
- Which vault to store this credential in. If omitted, uses the instance default. Use this to mix Skyvern-hosted and custom credentials within the same organization.
+ workflow_run_id : typing.Optional[str]
+ Workflow run whose persisted session should be captured. Omit for a blank profile.
- proxy_location : typing.Optional[CreateCredentialRequestProxyLocation]
- Optional proxy location for this credential's pinned proxy identity.
+ proxy_location : typing.Optional[CreateBrowserProfileRequestProxyLocation]
+ Optional proxy location for this profile's pinned proxy identity.
proxy_session_id : typing.Optional[str]
- Optional advanced reuse key for this credential's pinned proxy identity.
-
- rotate_proxy_session_id : typing.Optional[bool]
- Rotate the Skyvern-managed proxy sticky-session id when updating this credential.
+ Explicit sticky-session id for this profile's pinned proxy identity.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[CredentialResponse]
- Successful Response
+ HttpResponse[BrowserProfile]
+ Successfully created browser profile
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/credentials/{jsonable_encoder(credential_id)}/update",
+ "v1/browser_profiles",
method="POST",
json={
"name": name,
- "credential_type": credential_type,
- "credential": convert_and_respect_annotation_metadata(
- object_=credential, annotation=CreateCredentialRequestCredential, direction="write"
- ),
- "vault_type": vault_type,
+ "description": description,
+ "browser_session_id": browser_session_id,
+ "workflow_run_id": workflow_run_id,
"proxy_location": convert_and_respect_annotation_metadata(
- object_=proxy_location, annotation=CreateCredentialRequestProxyLocation, direction="write"
+ object_=proxy_location, annotation=CreateBrowserProfileRequestProxyLocation, direction="write"
),
"proxy_session_id": proxy_session_id,
- "rotate_proxy_session_id": rotate_proxy_session_id,
},
headers={
"content-type": "application/json",
@@ -3170,13 +2865,35 @@ class RawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- CredentialResponse,
+ BrowserProfile,
parse_obj_as(
- type_=CredentialResponse, # type: ignore
+ type_=BrowserProfile, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -3193,32 +2910,51 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def delete_credential(
- self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[None]:
+ def get_browser_profile(
+ self, profile_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[BrowserProfile]:
"""
- Deletes a specific credential by its ID
+ Get a specific browser profile by ID
Parameters
----------
- credential_id : str
- The unique identifier of the credential to delete
+ profile_id : str
+ The ID of the browser profile. browser_profile_id starts with `bp_`
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[None]
+ HttpResponse[BrowserProfile]
+ Successfully retrieved browser profile
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/credentials/{jsonable_encoder(credential_id)}/delete",
- method="POST",
+ f"v1/browser_profiles/{jsonable_encoder(profile_id)}",
+ method="GET",
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
- return HttpResponse(response=_response, data=None)
+ _data = typing.cast(
+ BrowserProfile,
+ parse_obj_as(
+ type_=BrowserProfile, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -3235,40 +2971,43 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_credential(
- self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[CredentialResponse]:
+ def delete_browser_profile(
+ self, profile_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[None]:
"""
- Retrieves a specific credential by its ID
+ Delete a browser profile (soft delete)
Parameters
----------
- credential_id : str
- The unique identifier of the credential
+ profile_id : str
+ The ID of the browser profile to delete. browser_profile_id starts with `bp_`
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[CredentialResponse]
- Successful Response
+ HttpResponse[None]
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/credentials/{jsonable_encoder(credential_id)}",
- method="GET",
+ f"v1/browser_profiles/{jsonable_encoder(profile_id)}",
+ method="DELETE",
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
- _data = typing.cast(
- CredentialResponse,
- parse_obj_as(
- type_=CredentialResponse, # type: ignore
- object_=_response.json(),
+ return HttpResponse(response=_response, data=None)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
),
)
- return HttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -3285,145 +3024,62 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def login(
+ def update_browser_profile(
self,
+ profile_id: str,
*,
- credential_type: SkyvernSchemasCredentialTypeCredentialType,
- user_agent: typing.Optional[str] = None,
- url: typing.Optional[str] = OMIT,
- webhook_url: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[ProxyLocation] = OMIT,
- totp_identifier: typing.Optional[str] = OMIT,
- totp_url: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- browser_profile_id: typing.Optional[str] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- max_screenshot_scrolling_times: typing.Optional[int] = OMIT,
- prompt: typing.Optional[str] = OMIT,
- credential_id: typing.Optional[str] = OMIT,
- bitwarden_collection_id: typing.Optional[str] = OMIT,
- bitwarden_item_id: typing.Optional[str] = OMIT,
- onepassword_vault_id: typing.Optional[str] = OMIT,
- onepassword_item_id: typing.Optional[str] = OMIT,
- azure_vault_name: typing.Optional[str] = OMIT,
- azure_vault_username_key: typing.Optional[str] = OMIT,
- azure_vault_password_key: typing.Optional[str] = OMIT,
- azure_vault_totp_secret_key: typing.Optional[str] = OMIT,
+ name: typing.Optional[str] = OMIT,
+ description: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[UpdateBrowserProfileRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
+ rotate_proxy_session_id: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[WorkflowRunResponse]:
+ ) -> HttpResponse[BrowserProfile]:
"""
- Log in to a website using either credential stored in Skyvern, Bitwarden, 1Password, or Azure Vault
+ Update a browser profile's name and/or description
Parameters
----------
- credential_type : SkyvernSchemasCredentialTypeCredentialType
- Where to get the credential from
-
- user_agent : typing.Optional[str]
-
- url : typing.Optional[str]
- Website URL
-
- webhook_url : typing.Optional[str]
- Webhook URL to send status updates
-
- proxy_location : typing.Optional[ProxyLocation]
- Proxy location to use
-
- totp_identifier : typing.Optional[str]
- Identifier for TOTP (Time-based One-Time Password) if required
-
- totp_url : typing.Optional[str]
- TOTP URL to fetch one-time passwords
-
- browser_session_id : typing.Optional[str]
- ID of the browser session to use, which is prefixed by `pbs_` e.g. `pbs_123456`
-
- browser_profile_id : typing.Optional[str]
- ID of a browser profile to reuse for this run
-
- browser_address : typing.Optional[str]
- The CDP address for the task.
-
- extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- Additional HTTP headers to include in requests
-
- cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Never forwarded to target websites.
-
- max_screenshot_scrolling_times : typing.Optional[int]
- Maximum number of times to scroll for screenshots
-
- prompt : typing.Optional[str]
- Login instructions. Skyvern has default prompt/instruction for login if this field is not provided.
-
- credential_id : typing.Optional[str]
- ID of the Skyvern credential to use for login.
-
- bitwarden_collection_id : typing.Optional[str]
- Bitwarden collection ID. You can find it in the Bitwarden collection URL. e.g. `https://vault.bitwarden.com/vaults/collection_id/items`
-
- bitwarden_item_id : typing.Optional[str]
- Bitwarden item ID
-
- onepassword_vault_id : typing.Optional[str]
- 1Password vault ID
+ profile_id : str
+ The ID of the browser profile to update. browser_profile_id starts with `bp_`
- onepassword_item_id : typing.Optional[str]
- 1Password item ID
+ name : typing.Optional[str]
+ New name for the browser profile
- azure_vault_name : typing.Optional[str]
- Azure Vault Name
+ description : typing.Optional[str]
+ New description for the browser profile
- azure_vault_username_key : typing.Optional[str]
- Azure Vault username key
+ proxy_location : typing.Optional[UpdateBrowserProfileRequestProxyLocation]
+ Optional proxy location for this profile's pinned proxy identity.
- azure_vault_password_key : typing.Optional[str]
- Azure Vault password key
+ proxy_session_id : typing.Optional[str]
+ Opaque Skyvern-managed proxy sticky-session id.
- azure_vault_totp_secret_key : typing.Optional[str]
- Azure Vault TOTP secret key
+ rotate_proxy_session_id : typing.Optional[bool]
+ Rotate the Skyvern-managed proxy sticky-session id for this profile.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[WorkflowRunResponse]
- Successful Response
+ HttpResponse[BrowserProfile]
+ Successfully updated browser profile
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/run/tasks/login",
- method="POST",
+ f"v1/browser_profiles/{jsonable_encoder(profile_id)}",
+ method="PATCH",
json={
- "url": url,
- "webhook_url": webhook_url,
- "proxy_location": proxy_location,
- "totp_identifier": totp_identifier,
- "totp_url": totp_url,
- "browser_session_id": browser_session_id,
- "browser_profile_id": browser_profile_id,
- "browser_address": browser_address,
- "extra_http_headers": extra_http_headers,
- "cdp_connect_headers": cdp_connect_headers,
- "max_screenshot_scrolling_times": max_screenshot_scrolling_times,
- "credential_type": credential_type,
- "prompt": prompt,
- "credential_id": credential_id,
- "bitwarden_collection_id": bitwarden_collection_id,
- "bitwarden_item_id": bitwarden_item_id,
- "onepassword_vault_id": onepassword_vault_id,
- "onepassword_item_id": onepassword_item_id,
- "azure_vault_name": azure_vault_name,
- "azure_vault_username_key": azure_vault_username_key,
- "azure_vault_password_key": azure_vault_password_key,
- "azure_vault_totp_secret_key": azure_vault_totp_secret_key,
+ "name": name,
+ "description": description,
+ "proxy_location": convert_and_respect_annotation_metadata(
+ object_=proxy_location, annotation=UpdateBrowserProfileRequestProxyLocation, direction="write"
+ ),
+ "proxy_session_id": proxy_session_id,
+ "rotate_proxy_session_id": rotate_proxy_session_id,
},
headers={
"content-type": "application/json",
- "x-user-agent": str(user_agent) if user_agent is not None else None,
},
request_options=request_options,
omit=OMIT,
@@ -3431,13 +3087,35 @@ class RawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- WorkflowRunResponse,
+ BrowserProfile,
parse_obj_as(
- type_=WorkflowRunResponse, # type: ignore
+ type_=BrowserProfile, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -3454,126 +3132,39 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def download_files(
- self,
- *,
- navigation_goal: str,
- user_agent: typing.Optional[str] = None,
- url: typing.Optional[str] = OMIT,
- webhook_url: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[ProxyLocation] = OMIT,
- totp_identifier: typing.Optional[str] = OMIT,
- totp_url: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- browser_profile_id: typing.Optional[str] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- max_screenshot_scrolling_times: typing.Optional[int] = OMIT,
- download_suffix: typing.Optional[str] = OMIT,
- download_timeout: typing.Optional[float] = OMIT,
- max_steps_per_run: typing.Optional[int] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[WorkflowRunResponse]:
+ def get_browser_sessions(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[typing.List[BrowserSessionResponse]]:
"""
- Download a file from a website by navigating and clicking download buttons
+ Get all active browser sessions for the organization
Parameters
----------
- navigation_goal : str
- Instructions for navigating to and downloading the file
-
- user_agent : typing.Optional[str]
-
- url : typing.Optional[str]
- Website URL
-
- webhook_url : typing.Optional[str]
- Webhook URL to send status updates
-
- proxy_location : typing.Optional[ProxyLocation]
- Proxy location to use
-
- totp_identifier : typing.Optional[str]
- Identifier for TOTP (Time-based One-Time Password) if required
-
- totp_url : typing.Optional[str]
- TOTP URL to fetch one-time passwords
-
- browser_session_id : typing.Optional[str]
- ID of the browser session to use, which is prefixed by `pbs_` e.g. `pbs_123456`
-
- browser_profile_id : typing.Optional[str]
- ID of a browser profile to reuse for this run
-
- browser_address : typing.Optional[str]
- The CDP address for the task.
-
- extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- Additional HTTP headers to include in requests
-
- cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Never forwarded to target websites.
-
- max_screenshot_scrolling_times : typing.Optional[int]
- Maximum number of times to scroll for screenshots
-
- download_suffix : typing.Optional[str]
- Suffix or complete filename for the downloaded file
-
- download_timeout : typing.Optional[float]
- Timeout in seconds for the download operation
-
- max_steps_per_run : typing.Optional[int]
- Maximum number of steps to execute
-
- request_options : typing.Optional[RequestOptions]
- Request-specific configuration.
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
Returns
-------
- HttpResponse[WorkflowRunResponse]
- Successful Response
+ HttpResponse[typing.List[BrowserSessionResponse]]
+ Successfully retrieved all active browser sessions
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/run/tasks/download_files",
- method="POST",
- json={
- "url": url,
- "webhook_url": webhook_url,
- "proxy_location": proxy_location,
- "totp_identifier": totp_identifier,
- "totp_url": totp_url,
- "browser_session_id": browser_session_id,
- "browser_profile_id": browser_profile_id,
- "browser_address": browser_address,
- "extra_http_headers": extra_http_headers,
- "cdp_connect_headers": cdp_connect_headers,
- "max_screenshot_scrolling_times": max_screenshot_scrolling_times,
- "navigation_goal": navigation_goal,
- "download_suffix": download_suffix,
- "download_timeout": download_timeout,
- "max_steps_per_run": max_steps_per_run,
- },
- headers={
- "content-type": "application/json",
- "x-user-agent": str(user_agent) if user_agent is not None else None,
- },
+ "v1/browser_sessions",
+ method="GET",
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- WorkflowRunResponse,
+ typing.List[BrowserSessionResponse],
parse_obj_as(
- type_=WorkflowRunResponse, # type: ignore
+ type_=typing.List[BrowserSessionResponse], # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 422:
- raise UnprocessableEntityError(
+ if _response.status_code == 403:
+ raise ForbiddenError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -3583,56 +3174,6 @@ class RawSkyvern:
),
),
)
- _response_json = _response.json()
- except JSONDecodeError:
- raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
- raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
-
- def get_scripts(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[typing.List[Script]]:
- """
- Retrieves a paginated list of scripts 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
- -------
- HttpResponse[typing.List[Script]]
- Successful Response
- """
- _response = self._client_wrapper.httpx_client.request(
- "v1/scripts",
- method="GET",
- params={
- "page": page,
- "page_size": page_size,
- },
- request_options=request_options,
- )
- try:
- if 200 <= _response.status_code < 300:
- _data = typing.cast(
- typing.List[Script],
- parse_obj_as(
- type_=typing.List[Script], # type: ignore
- object_=_response.json(),
- ),
- )
- return HttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -3649,45 +3190,99 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def create_script(
+ def create_browser_session(
self,
*,
- workflow_id: typing.Optional[str] = OMIT,
- run_id: typing.Optional[str] = OMIT,
- files: typing.Optional[typing.Sequence[ScriptFileCreate]] = OMIT,
+ timeout: typing.Optional[int] = OMIT,
+ proxy_location: typing.Optional[CreateBrowserSessionRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
+ extensions: typing.Optional[typing.Sequence[Extensions]] = OMIT,
+ browser_type: typing.Optional[PersistentBrowserType] = OMIT,
+ browser_profile_id: typing.Optional[str] = OMIT,
+ generate_browser_profile: typing.Optional[bool] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[CreateScriptResponse]:
+ ) -> HttpResponse[BrowserSessionResponse]:
"""
- Create a new script with optional files and metadata
+ Create a browser session that persists across multiple runs
Parameters
----------
- workflow_id : typing.Optional[str]
- Associated workflow ID
+ timeout : typing.Optional[int]
+ Timeout in minutes for the session. Timeout is applied after the session is started. Must be between 5 and 1440. Defaults to 60.
- run_id : typing.Optional[str]
- Associated run ID
+ proxy_location : typing.Optional[CreateBrowserSessionRequestProxyLocation]
- files : typing.Optional[typing.Sequence[ScriptFileCreate]]
- Array of files to include in the script
+ Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
+
+ Available geotargeting options:
+ - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
+ - RESIDENTIAL_ES: Spain
+ - RESIDENTIAL_IE: Ireland
+ - RESIDENTIAL_GB: United Kingdom
+ - RESIDENTIAL_IN: India
+ - RESIDENTIAL_JP: Japan
+ - RESIDENTIAL_FR: France
+ - RESIDENTIAL_DE: Germany
+ - RESIDENTIAL_NZ: New Zealand
+ - RESIDENTIAL_PH: Philippines
+ - RESIDENTIAL_KR: South Korea
+ - RESIDENTIAL_SA: Saudi Arabia
+ - RESIDENTIAL_ZA: South Africa
+ - RESIDENTIAL_AR: Argentina
+ - RESIDENTIAL_AU: Australia
+ - RESIDENTIAL_BR: Brazil
+ - RESIDENTIAL_TR: Turkey
+ - RESIDENTIAL_CA: Canada
+ - RESIDENTIAL_MX: Mexico
+ - RESIDENTIAL_IT: Italy
+ - RESIDENTIAL_NL: Netherlands
+ - RESIDENTIAL_ISP: ISP proxy
+ - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
+ - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
+ - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
+ - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
+ - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
+ - NONE: No proxy
+
+ For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
+ Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}, or a custom proxy URL dict for self-hosted deployments: {"url": "http://user:[email protected]:8080"}
+
+ proxy_session_id : typing.Optional[str]
+ Opaque Skyvern-managed proxy sticky-session id for pinned Residential ISP sessions.
+
+ extensions : typing.Optional[typing.Sequence[Extensions]]
+ A list of extensions to install in the browser session.
+
+ browser_type : typing.Optional[PersistentBrowserType]
+ The type of browser to use for the session.
+
+ browser_profile_id : typing.Optional[str]
+ ID of a browser profile to load into this session (restores cookies, localStorage, etc.). browser_profile_id starts with `bp_`.
+
+ generate_browser_profile : typing.Optional[bool]
+ When true, the session's browser profile (cookies, localStorage, etc.) is saved to storage when the session ends so it can be turned into a reusable browser profile. Defaults to false to avoid storing profiles for sessions that never need them. Sessions started with a browser_profile_id always persist their profile regardless of this flag.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[CreateScriptResponse]
- Successful Response
+ HttpResponse[BrowserSessionResponse]
+ Successfully created browser session
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/scripts",
+ "v1/browser_sessions",
method="POST",
json={
- "workflow_id": workflow_id,
- "run_id": run_id,
- "files": convert_and_respect_annotation_metadata(
- object_=files, annotation=typing.Sequence[ScriptFileCreate], direction="write"
+ "timeout": timeout,
+ "proxy_location": convert_and_respect_annotation_metadata(
+ object_=proxy_location, annotation=CreateBrowserSessionRequestProxyLocation, direction="write"
),
+ "proxy_session_id": proxy_session_id,
+ "extensions": extensions,
+ "browser_type": browser_type,
+ "browser_profile_id": browser_profile_id,
+ "generate_browser_profile": generate_browser_profile,
},
headers={
"content-type": "application/json",
@@ -3698,13 +3293,35 @@ class RawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- CreateScriptResponse,
+ BrowserSessionResponse,
parse_obj_as(
- type_=CreateScriptResponse, # type: ignore
+ type_=BrowserSessionResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -3721,42 +3338,44 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_script(
- self, script_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[Script]:
+ def close_browser_session(
+ self, browser_session_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[typing.Optional[typing.Any]]:
"""
- Retrieves a specific script by its ID
+ Close a session. Once closed, the session cannot be used again.
Parameters
----------
- script_id : str
- The unique identifier of the script
+ browser_session_id : str
+ The ID of the browser session to close. completed_at will be set when the browser session is closed. browser_session_id starts with `pbs_`
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[Script]
- Successful Response
+ HttpResponse[typing.Optional[typing.Any]]
+ Successfully closed browser session
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/scripts/{jsonable_encoder(script_id)}",
- method="GET",
+ f"v1/browser_sessions/{jsonable_encoder(browser_session_id)}/close",
+ method="POST",
request_options=request_options,
)
try:
+ if _response is None or not _response.text.strip():
+ return HttpResponse(response=_response, data=None)
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Script,
+ typing.Optional[typing.Any],
parse_obj_as(
- type_=Script, # type: ignore
+ type_=typing.Optional[typing.Any], # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 422:
- raise UnprocessableEntityError(
+ if _response.status_code == 403:
+ raise ForbiddenError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -3766,61 +3385,17 @@ class RawSkyvern:
),
),
)
- _response_json = _response.json()
- except JSONDecodeError:
- raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
- raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
-
- def deploy_script(
- self,
- script_id: str,
- *,
- files: typing.Sequence[ScriptFileCreate],
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[CreateScriptResponse]:
- """
- Deploy a script with updated files, creating a new version
-
- Parameters
- ----------
- script_id : str
- The unique identifier of the script
-
- files : typing.Sequence[ScriptFileCreate]
- Array of files to include in the script
-
- request_options : typing.Optional[RequestOptions]
- Request-specific configuration.
-
- Returns
- -------
- HttpResponse[CreateScriptResponse]
- Successful Response
- """
- _response = self._client_wrapper.httpx_client.request(
- f"v1/scripts/{jsonable_encoder(script_id)}/deploy",
- method="POST",
- json={
- "files": convert_and_respect_annotation_metadata(
- object_=files, annotation=typing.Sequence[ScriptFileCreate], direction="write"
- ),
- },
- headers={
- "content-type": "application/json",
- },
- request_options=request_options,
- omit=OMIT,
- )
- try:
- if 200 <= _response.status_code < 300:
- _data = typing.cast(
- CreateScriptResponse,
- parse_obj_as(
- type_=CreateScriptResponse, # type: ignore
- object_=_response.json(),
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
),
)
- return HttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -3837,72 +3412,62 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def run_sdk_action(
- self,
- *,
- url: str,
- action: RunSdkActionRequestAction,
- browser_session_id: typing.Optional[str] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- workflow_run_id: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[RunSdkActionResponse]:
+ def get_browser_session(
+ self, browser_session_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[BrowserSessionResponse]:
"""
- Execute a single SDK action with the specified parameters
+ Get details about a specific browser session, including the browser address for cdp connection.
Parameters
----------
- url : str
- The URL where the action should be executed
-
- action : RunSdkActionRequestAction
- The action to execute with its specific parameters
-
- browser_session_id : typing.Optional[str]
- The browser session ID
-
- browser_address : typing.Optional[str]
- The browser address
-
- workflow_run_id : typing.Optional[str]
- Optional workflow run ID to continue an existing workflow run
+ browser_session_id : str
+ The ID of the browser session. browser_session_id starts with `pbs_`
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[RunSdkActionResponse]
- Successful Response
+ HttpResponse[BrowserSessionResponse]
+ Successfully retrieved browser session details
"""
_response = self._client_wrapper.httpx_client.request(
- "v1/sdk/run_action",
- method="POST",
- json={
- "url": url,
- "browser_session_id": browser_session_id,
- "browser_address": browser_address,
- "workflow_run_id": workflow_run_id,
- "action": convert_and_respect_annotation_metadata(
- object_=action, annotation=RunSdkActionRequestAction, direction="write"
- ),
- },
- headers={
- "content-type": "application/json",
- },
+ f"v1/browser_sessions/{jsonable_encoder(browser_session_id)}",
+ method="GET",
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- RunSdkActionResponse,
+ BrowserSessionResponse,
parse_obj_as(
- type_=RunSdkActionResponse, # type: ignore
+ type_=BrowserSessionResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 403:
+ raise ForbiddenError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -3919,37 +3484,37 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def update_workflow_folder(
+ def update_browser_session(
self,
- workflow_permanent_id: str,
+ browser_session_id: str,
*,
- folder_id: typing.Optional[str] = OMIT,
+ generate_browser_profile: bool,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[Workflow]:
+ ) -> HttpResponse[BrowserSessionResponse]:
"""
- Update a workflow's folder assignment for the latest version
+ Update a live browser session. Currently supports toggling generate_browser_profile, which is read when the session ends to decide whether to save its browser profile.
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
+ browser_session_id : str
+ The ID of the browser session. browser_session_id starts with `pbs_`
- folder_id : typing.Optional[str]
- Folder ID to assign workflow to. Set to null to remove from folder.
+ generate_browser_profile : bool
+ Enable or disable saving this session's browser profile when it ends. Can be toggled while the session is still alive; the value is read at session teardown.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[Workflow]
- Successfully updated workflow folder
+ HttpResponse[BrowserSessionResponse]
+ Successfully updated browser session
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/folder",
- method="PUT",
+ f"v1/browser_sessions/{jsonable_encoder(browser_session_id)}",
+ method="PATCH",
json={
- "folder_id": folder_id,
+ "generate_browser_profile": generate_browser_profile,
},
headers={
"content-type": "application/json",
@@ -3960,15 +3525,15 @@ class RawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Workflow,
+ BrowserSessionResponse,
parse_obj_as(
- type_=Workflow, # type: ignore
+ type_=BrowserSessionResponse, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 400:
- raise BadRequestError(
+ if _response.status_code == 403:
+ raise ForbiddenError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -3989,6 +3554,17 @@ class RawSkyvern:
),
),
)
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -4005,42 +3581,87 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_workflow_tags(
- self, workflow_permanent_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[TagsResponse]:
+ def send_totp_code(
+ self,
+ *,
+ totp_identifier: str,
+ content: str,
+ task_id: typing.Optional[str] = OMIT,
+ workflow_id: typing.Optional[str] = OMIT,
+ workflow_run_id: typing.Optional[str] = OMIT,
+ source: typing.Optional[str] = OMIT,
+ expired_at: typing.Optional[dt.datetime] = OMIT,
+ type: typing.Optional[OtpType] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[TotpCode]:
"""
- Get the current tag state for a workflow.
+ Forward a TOTP (2FA, MFA) email or sms message containing the code to Skyvern. This endpoint stores the code in database so that Skyvern can use it while running tasks/workflows.
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
+ totp_identifier : str
+ The identifier of the TOTP code. It can be the email address, phone number, or the identifier of the user.
+
+ content : str
+ The content of the TOTP code. It can be the email content that contains the TOTP code, or the sms message that contains the TOTP code. Skyvern will automatically extract the TOTP code from the content.
+
+ task_id : typing.Optional[str]
+ The task_id the totp code is for. It can be the task_id of the task that the TOTP code is for.
+
+ workflow_id : typing.Optional[str]
+ The workflow ID the TOTP code is for. It can be the workflow ID of the workflow that the TOTP code is for.
+
+ workflow_run_id : typing.Optional[str]
+ The workflow run id that the TOTP code is for. It can be the workflow run id of the workflow run that the TOTP code is for.
+
+ source : typing.Optional[str]
+ An optional field. The source of the TOTP code. e.g. email, sms, etc.
+
+ expired_at : typing.Optional[dt.datetime]
+ The timestamp when the TOTP code expires
+
+ type : typing.Optional[OtpType]
+ Optional. If provided, forces extraction of this specific OTP type (totp or magic_link). Use this when the content contains multiple OTP types and you want to specify which one to extract.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[TagsResponse]
- Successfully retrieved tags
+ HttpResponse[TotpCode]
+ Successful Response
"""
_response = self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/tags",
- method="GET",
+ "v1/credentials/totp",
+ method="POST",
+ json={
+ "totp_identifier": totp_identifier,
+ "task_id": task_id,
+ "workflow_id": workflow_id,
+ "workflow_run_id": workflow_run_id,
+ "source": source,
+ "content": content,
+ "expired_at": expired_at,
+ "type": type,
+ },
+ headers={
+ "content-type": "application/json",
+ },
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TagsResponse,
+ TotpCode,
parse_obj_as(
- type_=TagsResponse, # type: ignore
+ type_=TotpCode, # type: ignore
object_=_response.json(),
),
)
return HttpResponse(response=_response, data=_data)
- if _response.status_code == 404:
- raise NotFoundError(
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -4050,9 +3671,2220 @@ class RawSkyvern:
),
),
)
- if _response.status_code == 422:
- raise UnprocessableEntityError(
- headers=dict(_response.headers),
+ _response_json = _response.json()
+ except JSONDecodeError:
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_credentials(
+ self,
+ *,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ vault_type: typing.Optional[CredentialVaultType] = None,
+ credential_type: typing.Optional[SkyvernForgeSdkSchemasCredentialsCredentialType] = None,
+ search: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[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
+
+ vault_type : typing.Optional[CredentialVaultType]
+ Filter credentials by vault type (e.g. 'skyvern', 'custom', 'bitwarden', 'azure_vault')
+
+ credential_type : typing.Optional[SkyvernForgeSdkSchemasCredentialsCredentialType]
+ Filter credentials by type (e.g. 'password', 'credit_card', 'secret')
+
+ search : typing.Optional[str]
+ Case-insensitive search across credential name, username, secret label, and card details
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[typing.List[CredentialResponse]]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/credentials",
+ method="GET",
+ params={
+ "page": page,
+ "page_size": page_size,
+ "vault_type": vault_type,
+ "credential_type": credential_type,
+ "search": search,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.List[CredentialResponse],
+ parse_obj_as(
+ type_=typing.List[CredentialResponse], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def create_credential(
+ self,
+ *,
+ name: str,
+ credential_type: SkyvernForgeSdkSchemasCredentialsCredentialType,
+ credential: CreateCredentialRequestCredential,
+ vault_type: typing.Optional[CredentialVaultType] = OMIT,
+ proxy_location: typing.Optional[CreateCredentialRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
+ rotate_proxy_session_id: typing.Optional[bool] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[CredentialResponse]:
+ """
+ Creates a new credential for the current organization
+
+ Parameters
+ ----------
+ name : str
+ Name of the credential
+
+ credential_type : SkyvernForgeSdkSchemasCredentialsCredentialType
+ Type of credential to create
+
+ credential : CreateCredentialRequestCredential
+ The credential data to store
+
+ vault_type : typing.Optional[CredentialVaultType]
+ Which vault to store this credential in. If omitted, uses the instance default. Use this to mix Skyvern-hosted and custom credentials within the same organization.
+
+ proxy_location : typing.Optional[CreateCredentialRequestProxyLocation]
+ Optional proxy location for this credential's pinned proxy identity.
+
+ proxy_session_id : typing.Optional[str]
+ Optional advanced reuse key for this credential's pinned proxy identity.
+
+ rotate_proxy_session_id : typing.Optional[bool]
+ Rotate the Skyvern-managed proxy sticky-session id when updating this credential.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CredentialResponse]
+ Successful Response
+ """
+ _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"
+ ),
+ "vault_type": vault_type,
+ "proxy_location": convert_and_respect_annotation_metadata(
+ object_=proxy_location, annotation=CreateCredentialRequestProxyLocation, direction="write"
+ ),
+ "proxy_session_id": proxy_session_id,
+ "rotate_proxy_session_id": rotate_proxy_session_id,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CredentialResponse,
+ parse_obj_as(
+ type_=CredentialResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def update_credential(
+ self,
+ credential_id: str,
+ *,
+ name: str,
+ credential_type: SkyvernForgeSdkSchemasCredentialsCredentialType,
+ credential: CreateCredentialRequestCredential,
+ vault_type: typing.Optional[CredentialVaultType] = OMIT,
+ proxy_location: typing.Optional[CreateCredentialRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
+ rotate_proxy_session_id: typing.Optional[bool] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[CredentialResponse]:
+ """
+ Overwrites the stored credential data (e.g. username/password) while keeping the same credential_id.
+
+ Parameters
+ ----------
+ credential_id : str
+ The unique identifier of the credential to update
+
+ name : str
+ Name of the credential
+
+ credential_type : SkyvernForgeSdkSchemasCredentialsCredentialType
+ Type of credential to create
+
+ credential : CreateCredentialRequestCredential
+ The credential data to store
+
+ vault_type : typing.Optional[CredentialVaultType]
+ Which vault to store this credential in. If omitted, uses the instance default. Use this to mix Skyvern-hosted and custom credentials within the same organization.
+
+ proxy_location : typing.Optional[CreateCredentialRequestProxyLocation]
+ Optional proxy location for this credential's pinned proxy identity.
+
+ proxy_session_id : typing.Optional[str]
+ Optional advanced reuse key for this credential's pinned proxy identity.
+
+ rotate_proxy_session_id : typing.Optional[bool]
+ Rotate the Skyvern-managed proxy sticky-session id when updating this credential.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CredentialResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/credentials/{jsonable_encoder(credential_id)}/update",
+ method="POST",
+ json={
+ "name": name,
+ "credential_type": credential_type,
+ "credential": convert_and_respect_annotation_metadata(
+ object_=credential, annotation=CreateCredentialRequestCredential, direction="write"
+ ),
+ "vault_type": vault_type,
+ "proxy_location": convert_and_respect_annotation_metadata(
+ object_=proxy_location, annotation=CreateCredentialRequestProxyLocation, direction="write"
+ ),
+ "proxy_session_id": proxy_session_id,
+ "rotate_proxy_session_id": rotate_proxy_session_id,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CredentialResponse,
+ parse_obj_as(
+ type_=CredentialResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def delete_credential(
+ self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[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
+ -------
+ HttpResponse[None]
+ """
+ _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 HttpResponse(response=_response, data=None)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_credential(
+ self, credential_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[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
+ -------
+ HttpResponse[CredentialResponse]
+ Successful Response
+ """
+ _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:
+ _data = typing.cast(
+ CredentialResponse,
+ parse_obj_as(
+ type_=CredentialResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def list_custom_llms(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[CustomLlmListResponse]:
+ """
+ List the custom LLM configurations available to the current organization.
+
+ Parameters
+ ----------
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CustomLlmListResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/custom-llms",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomLlmListResponse,
+ parse_obj_as(
+ type_=CustomLlmListResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def create_custom_llm(
+ self, *, config: CustomLlmConfig, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[CustomLlmResponse]:
+ """
+ Create a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ config : CustomLlmConfig
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CustomLlmResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/custom-llms",
+ method="POST",
+ json={
+ "config": convert_and_respect_annotation_metadata(
+ object_=config, annotation=CustomLlmConfig, direction="write"
+ ),
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomLlmResponse,
+ parse_obj_as(
+ type_=CustomLlmResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def update_custom_llm(
+ self, custom_llm_id: str, *, config: CustomLlmConfig, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[CustomLlmResponse]:
+ """
+ Update a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ custom_llm_id : str
+ The custom LLM id.
+
+ config : CustomLlmConfig
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CustomLlmResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/custom-llms/{jsonable_encoder(custom_llm_id)}",
+ method="PUT",
+ json={
+ "config": convert_and_respect_annotation_metadata(
+ object_=config, annotation=CustomLlmConfig, direction="write"
+ ),
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomLlmResponse,
+ parse_obj_as(
+ type_=CustomLlmResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def delete_custom_llm(
+ self, custom_llm_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[ClearOrganizationAuthTokenResponse]:
+ """
+ Delete a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ custom_llm_id : str
+ The custom LLM id.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[ClearOrganizationAuthTokenResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/custom-llms/{jsonable_encoder(custom_llm_id)}",
+ method="DELETE",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ ClearOrganizationAuthTokenResponse,
+ parse_obj_as(
+ type_=ClearOrganizationAuthTokenResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def login(
+ self,
+ *,
+ credential_type: SkyvernSchemasCredentialTypeCredentialType,
+ user_agent: typing.Optional[str] = None,
+ url: typing.Optional[str] = OMIT,
+ webhook_url: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[ProxyLocation] = OMIT,
+ totp_identifier: typing.Optional[str] = OMIT,
+ totp_url: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ browser_profile_id: typing.Optional[str] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ max_screenshot_scrolling_times: typing.Optional[int] = OMIT,
+ prompt: typing.Optional[str] = OMIT,
+ credential_id: typing.Optional[str] = OMIT,
+ bitwarden_collection_id: typing.Optional[str] = OMIT,
+ bitwarden_item_id: typing.Optional[str] = OMIT,
+ onepassword_vault_id: typing.Optional[str] = OMIT,
+ onepassword_item_id: typing.Optional[str] = OMIT,
+ azure_vault_name: typing.Optional[str] = OMIT,
+ azure_vault_username_key: typing.Optional[str] = OMIT,
+ azure_vault_password_key: typing.Optional[str] = OMIT,
+ azure_vault_totp_secret_key: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[WorkflowRunResponse]:
+ """
+ Log in to a website using either credential stored in Skyvern, Bitwarden, 1Password, or Azure Vault
+
+ Parameters
+ ----------
+ credential_type : SkyvernSchemasCredentialTypeCredentialType
+ Where to get the credential from
+
+ user_agent : typing.Optional[str]
+
+ url : typing.Optional[str]
+ Website URL
+
+ webhook_url : typing.Optional[str]
+ Webhook URL to send status updates
+
+ proxy_location : typing.Optional[ProxyLocation]
+ Proxy location to use
+
+ totp_identifier : typing.Optional[str]
+ Identifier for TOTP (Time-based One-Time Password) if required
+
+ totp_url : typing.Optional[str]
+ TOTP URL to fetch one-time passwords
+
+ browser_session_id : typing.Optional[str]
+ ID of the browser session to use, which is prefixed by `pbs_` e.g. `pbs_123456`
+
+ browser_profile_id : typing.Optional[str]
+ ID of a browser profile to reuse for this run
+
+ browser_address : typing.Optional[str]
+ The CDP address for the task.
+
+ extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Additional HTTP headers to include in requests
+
+ cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Never forwarded to target websites.
+
+ max_screenshot_scrolling_times : typing.Optional[int]
+ Maximum number of times to scroll for screenshots
+
+ prompt : typing.Optional[str]
+ Login instructions. Skyvern has default prompt/instruction for login if this field is not provided.
+
+ credential_id : typing.Optional[str]
+ ID of the Skyvern credential to use for login.
+
+ bitwarden_collection_id : typing.Optional[str]
+ Bitwarden collection ID. You can find it in the Bitwarden collection URL. e.g. `https://vault.bitwarden.com/vaults/collection_id/items`
+
+ bitwarden_item_id : typing.Optional[str]
+ Bitwarden item ID
+
+ onepassword_vault_id : typing.Optional[str]
+ 1Password vault ID
+
+ onepassword_item_id : typing.Optional[str]
+ 1Password item ID
+
+ azure_vault_name : typing.Optional[str]
+ Azure Vault Name
+
+ azure_vault_username_key : typing.Optional[str]
+ Azure Vault username key
+
+ azure_vault_password_key : typing.Optional[str]
+ Azure Vault password key
+
+ azure_vault_totp_secret_key : typing.Optional[str]
+ Azure Vault TOTP secret key
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[WorkflowRunResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/run/tasks/login",
+ method="POST",
+ json={
+ "url": url,
+ "webhook_url": webhook_url,
+ "proxy_location": proxy_location,
+ "totp_identifier": totp_identifier,
+ "totp_url": totp_url,
+ "browser_session_id": browser_session_id,
+ "browser_profile_id": browser_profile_id,
+ "browser_address": browser_address,
+ "extra_http_headers": extra_http_headers,
+ "cdp_connect_headers": cdp_connect_headers,
+ "max_screenshot_scrolling_times": max_screenshot_scrolling_times,
+ "credential_type": credential_type,
+ "prompt": prompt,
+ "credential_id": credential_id,
+ "bitwarden_collection_id": bitwarden_collection_id,
+ "bitwarden_item_id": bitwarden_item_id,
+ "onepassword_vault_id": onepassword_vault_id,
+ "onepassword_item_id": onepassword_item_id,
+ "azure_vault_name": azure_vault_name,
+ "azure_vault_username_key": azure_vault_username_key,
+ "azure_vault_password_key": azure_vault_password_key,
+ "azure_vault_totp_secret_key": azure_vault_totp_secret_key,
+ },
+ headers={
+ "content-type": "application/json",
+ "x-user-agent": str(user_agent) if user_agent is not None else None,
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ WorkflowRunResponse,
+ parse_obj_as(
+ type_=WorkflowRunResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def download_files(
+ self,
+ *,
+ navigation_goal: str,
+ user_agent: typing.Optional[str] = None,
+ url: typing.Optional[str] = OMIT,
+ webhook_url: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[ProxyLocation] = OMIT,
+ totp_identifier: typing.Optional[str] = OMIT,
+ totp_url: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ browser_profile_id: typing.Optional[str] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ max_screenshot_scrolling_times: typing.Optional[int] = OMIT,
+ download_suffix: typing.Optional[str] = OMIT,
+ download_timeout: typing.Optional[float] = OMIT,
+ max_steps_per_run: typing.Optional[int] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[WorkflowRunResponse]:
+ """
+ Download a file from a website by navigating and clicking download buttons
+
+ Parameters
+ ----------
+ navigation_goal : str
+ Instructions for navigating to and downloading the file
+
+ user_agent : typing.Optional[str]
+
+ url : typing.Optional[str]
+ Website URL
+
+ webhook_url : typing.Optional[str]
+ Webhook URL to send status updates
+
+ proxy_location : typing.Optional[ProxyLocation]
+ Proxy location to use
+
+ totp_identifier : typing.Optional[str]
+ Identifier for TOTP (Time-based One-Time Password) if required
+
+ totp_url : typing.Optional[str]
+ TOTP URL to fetch one-time passwords
+
+ browser_session_id : typing.Optional[str]
+ ID of the browser session to use, which is prefixed by `pbs_` e.g. `pbs_123456`
+
+ browser_profile_id : typing.Optional[str]
+ ID of a browser profile to reuse for this run
+
+ browser_address : typing.Optional[str]
+ The CDP address for the task.
+
+ extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Additional HTTP headers to include in requests
+
+ cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Never forwarded to target websites.
+
+ max_screenshot_scrolling_times : typing.Optional[int]
+ Maximum number of times to scroll for screenshots
+
+ download_suffix : typing.Optional[str]
+ Suffix or complete filename for the downloaded file
+
+ download_timeout : typing.Optional[float]
+ Timeout in seconds for the download operation
+
+ max_steps_per_run : typing.Optional[int]
+ Maximum number of steps to execute
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[WorkflowRunResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/run/tasks/download_files",
+ method="POST",
+ json={
+ "url": url,
+ "webhook_url": webhook_url,
+ "proxy_location": proxy_location,
+ "totp_identifier": totp_identifier,
+ "totp_url": totp_url,
+ "browser_session_id": browser_session_id,
+ "browser_profile_id": browser_profile_id,
+ "browser_address": browser_address,
+ "extra_http_headers": extra_http_headers,
+ "cdp_connect_headers": cdp_connect_headers,
+ "max_screenshot_scrolling_times": max_screenshot_scrolling_times,
+ "navigation_goal": navigation_goal,
+ "download_suffix": download_suffix,
+ "download_timeout": download_timeout,
+ "max_steps_per_run": max_steps_per_run,
+ },
+ headers={
+ "content-type": "application/json",
+ "x-user-agent": str(user_agent) if user_agent is not None else None,
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ WorkflowRunResponse,
+ parse_obj_as(
+ type_=WorkflowRunResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_scripts(
+ self,
+ *,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[typing.List[Script]]:
+ """
+ Retrieves a paginated list of scripts 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
+ -------
+ HttpResponse[typing.List[Script]]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/scripts",
+ method="GET",
+ params={
+ "page": page,
+ "page_size": page_size,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.List[Script],
+ parse_obj_as(
+ type_=typing.List[Script], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def create_script(
+ self,
+ *,
+ workflow_id: typing.Optional[str] = OMIT,
+ run_id: typing.Optional[str] = OMIT,
+ files: typing.Optional[typing.Sequence[ScriptFileCreate]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[CreateScriptResponse]:
+ """
+ Create a new script with optional files and metadata
+
+ Parameters
+ ----------
+ workflow_id : typing.Optional[str]
+ Associated workflow ID
+
+ run_id : typing.Optional[str]
+ Associated run ID
+
+ files : typing.Optional[typing.Sequence[ScriptFileCreate]]
+ Array of files to include in the script
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CreateScriptResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/scripts",
+ method="POST",
+ json={
+ "workflow_id": workflow_id,
+ "run_id": run_id,
+ "files": convert_and_respect_annotation_metadata(
+ object_=files, annotation=typing.Sequence[ScriptFileCreate], direction="write"
+ ),
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CreateScriptResponse,
+ parse_obj_as(
+ type_=CreateScriptResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_script(
+ self, script_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[Script]:
+ """
+ Retrieves a specific script by its ID
+
+ Parameters
+ ----------
+ script_id : str
+ The unique identifier of the script
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[Script]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/scripts/{jsonable_encoder(script_id)}",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ Script,
+ parse_obj_as(
+ type_=Script, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def deploy_script(
+ self,
+ script_id: str,
+ *,
+ files: typing.Sequence[ScriptFileCreate],
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[CreateScriptResponse]:
+ """
+ Deploy a script with updated files, creating a new version
+
+ Parameters
+ ----------
+ script_id : str
+ The unique identifier of the script
+
+ files : typing.Sequence[ScriptFileCreate]
+ Array of files to include in the script
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[CreateScriptResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/scripts/{jsonable_encoder(script_id)}/deploy",
+ method="POST",
+ json={
+ "files": convert_and_respect_annotation_metadata(
+ object_=files, annotation=typing.Sequence[ScriptFileCreate], direction="write"
+ ),
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CreateScriptResponse,
+ parse_obj_as(
+ type_=CreateScriptResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def run_sdk_action(
+ self,
+ *,
+ url: str,
+ action: RunSdkActionRequestAction,
+ browser_session_id: typing.Optional[str] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ workflow_run_id: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[RunSdkActionResponse]:
+ """
+ Execute a single SDK action with the specified parameters
+
+ Parameters
+ ----------
+ url : str
+ The URL where the action should be executed
+
+ action : RunSdkActionRequestAction
+ The action to execute with its specific parameters
+
+ browser_session_id : typing.Optional[str]
+ The browser session ID
+
+ browser_address : typing.Optional[str]
+ The browser address
+
+ workflow_run_id : typing.Optional[str]
+ Optional workflow run ID to continue an existing workflow run
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[RunSdkActionResponse]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/sdk/run_action",
+ method="POST",
+ json={
+ "url": url,
+ "browser_session_id": browser_session_id,
+ "browser_address": browser_address,
+ "workflow_run_id": workflow_run_id,
+ "action": convert_and_respect_annotation_metadata(
+ object_=action, annotation=RunSdkActionRequestAction, direction="write"
+ ),
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ RunSdkActionResponse,
+ parse_obj_as(
+ type_=RunSdkActionResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def update_workflow_folder(
+ self,
+ workflow_permanent_id: str,
+ *,
+ folder_id: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[Workflow]:
+ """
+ Update a workflow's folder assignment for the latest version
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ folder_id : typing.Optional[str]
+ Folder ID to assign workflow to. Set to null to remove from folder.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[Workflow]
+ Successfully updated workflow folder
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/folder",
+ method="PUT",
+ json={
+ "folder_id": folder_id,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ Workflow,
+ parse_obj_as(
+ type_=Workflow, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_workflow_tags(
+ self, workflow_permanent_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[TagsResponse]:
+ """
+ Get the current tag state for a workflow.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[TagsResponse]
+ Successfully retrieved tags
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/tags",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ TagsResponse,
+ parse_obj_as(
+ type_=TagsResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def apply_workflow_tags(
+ self,
+ workflow_permanent_id: str,
+ *,
+ tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
+ tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[TagsResponse]:
+ """
+ Atomically apply tag changes to a workflow. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ tags : typing.Optional[typing.Sequence[TagInput]]
+ Tags to set (overwrite). List of {key?, value} objects.
+
+ tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
+ Tags to soft-delete. List of {key?, value?} targets.
+
+ colors : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[TagsResponse]
+ Successfully applied tag changes
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/tags",
+ method="POST",
+ json={
+ "tags": convert_and_respect_annotation_metadata(
+ object_=tags, annotation=typing.Sequence[TagInput], direction="write"
+ ),
+ "tags_to_delete": convert_and_respect_annotation_metadata(
+ object_=tags_to_delete, annotation=typing.Sequence[TagDeleteInput], direction="write"
+ ),
+ "colors": colors,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ TagsResponse,
+ parse_obj_as(
+ type_=TagsResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def delete_workflow_tag(
+ self, workflow_permanent_id: str, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> HttpResponse[TagsResponse]:
+ """
+ Soft-delete a single tag from a workflow. Writes a DELETE event row.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ key : str
+ Tag key to delete
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[TagsResponse]
+ Successfully deleted tag (or no-op if absent)
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/tags/{jsonable_encoder(key)}",
+ method="DELETE",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ TagsResponse,
+ parse_obj_as(
+ type_=TagsResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_workflow_tag_history(
+ self,
+ workflow_permanent_id: str,
+ *,
+ limit: typing.Optional[int] = None,
+ since: typing.Optional[dt.datetime] = None,
+ key: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[TagHistoryResponse]:
+ """
+ Chronological tag-event log for a workflow (newest first). Includes SET and DELETE events.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+ Workflow permanent ID
+
+ limit : typing.Optional[int]
+ Max events to return
+
+ since : typing.Optional[dt.datetime]
+ Only return events at or after this timestamp
+
+ key : typing.Optional[str]
+ Filter to events for a single tag key
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[TagHistoryResponse]
+ Successfully retrieved tag history
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/tags/history",
+ method="GET",
+ params={
+ "limit": limit,
+ "since": serialize_datetime(since) if since is not None else None,
+ "key": key,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ TagHistoryResponse,
+ parse_obj_as(
+ type_=TagHistoryResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def retry_workflow_run(
+ self,
+ workflow_run_id: str,
+ *,
+ max_steps_override: typing.Optional[int] = None,
+ user_agent: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[WorkflowRunResponse]:
+ """
+ Retry a workflow run using the original run parameters.
+
+ Parameters
+ ----------
+ workflow_run_id : str
+ The id of the workflow run to retry.
+
+ max_steps_override : typing.Optional[int]
+
+ user_agent : typing.Optional[str]
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[WorkflowRunResponse]
+ Successfully retried workflow run
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/runs/{jsonable_encoder(workflow_run_id)}/retry",
+ method="POST",
+ headers={
+ "x-max-steps-override": str(max_steps_override) if max_steps_override is not None else None,
+ "x-user-agent": str(user_agent) if user_agent is not None else None,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ WorkflowRunResponse,
+ parse_obj_as(
+ type_=WorkflowRunResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_workflow_runs(
+ self,
+ *,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
+ search_key: typing.Optional[str] = None,
+ error_code: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[typing.List[WorkflowRun]]:
+ """
+ List workflow runs across all workflows for the current organization.
+
+ Results are paginated and can be filtered by **status**, **search_key**, and **error_code**. All filters are combined with **AND** logic — a run must match every supplied filter to be returned.
+
+ ### search_key
+
+ A case-insensitive substring search that matches against **any** of the following fields:
+
+ | Searched field | Description |
+ |---|---|
+ | `workflow_run_id` | The unique run identifier (e.g. `wr_123…`) |
+ | Parameter **key** | The `key` of any workflow parameter definition associated with the run |
+ | Parameter **description** | The `description` of any workflow parameter definition |
+ | Run parameter **value** | The actual value supplied for any parameter when the run was created |
+ | `extra_http_headers` | Extra HTTP headers attached to the run (searched as raw JSON text) |
+
+ Soft-deleted parameter definitions are excluded from key/description matching. A run is returned if **any** of the fields above contain the search term.
+
+ ### error_code
+
+ An **exact-match** filter against the `error_code` field inside each task's `errors` JSON array. A run matches if **any** of its tasks contains an error object with a matching `error_code` value. Error codes are user-defined strings set during workflow execution (e.g. `INVALID_CREDENTIALS`, `LOGIN_FAILED`, `CAPTCHA_DETECTED`).
+
+ ### Combining filters
+
+ All query parameters use AND logic:
+ - `?status=failed` — only failed runs
+ - `?status=failed&error_code=LOGIN_FAILED` — failed runs **and** have a LOGIN_FAILED error
+ - `?status=failed&error_code=LOGIN_FAILED&search_key=prod_credential` — all three conditions must match
+
+ Parameters
+ ----------
+ page : typing.Optional[int]
+ Page number for pagination.
+
+ page_size : typing.Optional[int]
+ Number of runs to return per page.
+
+ status : typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]]
+ Filter by one or more run statuses.
+
+ search_key : typing.Optional[str]
+ Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. A run is returned if any of these fields match. Soft-deleted parameter definitions are excluded from key/description matching.
+
+ error_code : typing.Optional[str]
+ Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[typing.List[WorkflowRun]]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ "v1/agents/runs",
+ method="GET",
+ params={
+ "page": page,
+ "page_size": page_size,
+ "status": status,
+ "search_key": search_key,
+ "error_code": error_code,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.List[WorkflowRun],
+ parse_obj_as(
+ type_=typing.List[WorkflowRun], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_workflow_runs_by_id(
+ self,
+ workflow_id: str,
+ *,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
+ search_key: typing.Optional[str] = None,
+ error_code: typing.Optional[str] = None,
+ created_at_start: typing.Optional[dt.datetime] = None,
+ created_at_end: typing.Optional[dt.datetime] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[typing.List[WorkflowRun]]:
+ """
+ List runs for a specific workflow.
+
+ Supports filtering by **status**, **search_key**, and **error_code**. All filters are combined with **AND** logic.
+
+ ### search_key
+
+ Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. Soft-deleted parameter definitions are excluded.
+
+ ### error_code
+
+ Exact-match filter on the `error_code` field inside each task's `errors` JSON array. A run matches if any of its tasks contains an error with a matching `error_code`.
+
+ Parameters
+ ----------
+ workflow_id : str
+
+ page : typing.Optional[int]
+ Page number for pagination.
+
+ page_size : typing.Optional[int]
+ Number of runs to return per page.
+
+ status : typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]]
+ Filter by one or more run statuses.
+
+ search_key : typing.Optional[str]
+ Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. A run is returned if any of these fields match. Soft-deleted parameter definitions are excluded from key/description matching.
+
+ error_code : typing.Optional[str]
+ Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+
+ created_at_start : typing.Optional[dt.datetime]
+ Only include runs created at or after this UTC timestamp (ISO 8601).
+
+ created_at_end : typing.Optional[dt.datetime]
+ Only include runs created strictly before this UTC timestamp (ISO 8601).
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[typing.List[WorkflowRun]]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_id)}/runs",
+ method="GET",
+ params={
+ "page": page,
+ "page_size": page_size,
+ "status": status,
+ "search_key": search_key,
+ "error_code": error_code,
+ "created_at_start": serialize_datetime(created_at_start) if created_at_start is not None else None,
+ "created_at_end": serialize_datetime(created_at_end) if created_at_end is not None else None,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.List[WorkflowRun],
+ parse_obj_as(
+ type_=typing.List[WorkflowRun], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_workflow(
+ self,
+ workflow_permanent_id: str,
+ *,
+ version: typing.Optional[int] = None,
+ template: typing.Optional[bool] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[Workflow]:
+ """
+ Parameters
+ ----------
+ workflow_permanent_id : str
+
+ version : typing.Optional[int]
+
+ template : typing.Optional[bool]
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[Workflow]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_permanent_id)}",
+ method="GET",
+ params={
+ "version": version,
+ "template": template,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ Workflow,
+ parse_obj_as(
+ type_=Workflow, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ def get_workflow_versions(
+ self,
+ workflow_permanent_id: str,
+ *,
+ template: typing.Optional[bool] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> HttpResponse[typing.List[Workflow]]:
+ """
+ Get all versions of a workflow by its permanent ID.
+
+ Parameters
+ ----------
+ workflow_permanent_id : str
+
+ template : typing.Optional[bool]
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ HttpResponse[typing.List[Workflow]]
+ Successful Response
+ """
+ _response = self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/versions",
+ method="GET",
+ params={
+ "template": template,
+ },
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ typing.List[Workflow],
+ parse_obj_as(
+ type_=typing.List[Workflow], # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return HttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+
+class AsyncRawSkyvern:
+ def __init__(self, *, client_wrapper: AsyncClientWrapper):
+ self._client_wrapper = client_wrapper
+
+ async def run_task(
+ self,
+ *,
+ prompt: str,
+ user_agent: typing.Optional[str] = None,
+ url: typing.Optional[str] = OMIT,
+ engine: typing.Optional[RunEngine] = OMIT,
+ title: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[TaskRunRequestInputProxyLocation] = OMIT,
+ data_extraction_schema: typing.Optional[TaskRunRequestInputDataExtractionSchema] = OMIT,
+ error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ max_steps: typing.Optional[int] = OMIT,
+ webhook_url: typing.Optional[str] = OMIT,
+ totp_identifier: typing.Optional[str] = OMIT,
+ totp_url: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
+ extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ publish_workflow: typing.Optional[bool] = OMIT,
+ include_action_history_in_verification: typing.Optional[bool] = OMIT,
+ max_screenshot_scrolls: typing.Optional[int] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ run_with: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[TaskRunResponse]:
+ """
+ Run a task
+
+ Parameters
+ ----------
+ prompt : str
+
+ The goal or task description for Skyvern to accomplish
+
+ user_agent : typing.Optional[str]
+
+ url : typing.Optional[str]
+
+ The starting URL for the task. If not provided, Skyvern will attempt to determine an appropriate URL
+
+ engine : typing.Optional[RunEngine]
+
+ The engine that powers the agent task. The default value is `skyvern-1.0`, which is good for simple tasks like filling a form, or searching for information on Google. `skyvern-2.0` remains available for existing V2 workflows and explicitly requested V2 task runs. The `openai-cua` engine uses OpenAI's CUA model. The `anthropic-cua` uses Anthropic's Claude Sonnet 3.7 model with the computer use tool.
+
+ title : typing.Optional[str]
+ The title for the task
+
+ proxy_location : typing.Optional[TaskRunRequestInputProxyLocation]
+
+ Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
+
+ Available geotargeting options:
+ - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
+ - RESIDENTIAL_ES: Spain
+ - RESIDENTIAL_IE: Ireland
+ - RESIDENTIAL_GB: United Kingdom
+ - RESIDENTIAL_IN: India
+ - RESIDENTIAL_JP: Japan
+ - RESIDENTIAL_FR: France
+ - RESIDENTIAL_DE: Germany
+ - RESIDENTIAL_NZ: New Zealand
+ - RESIDENTIAL_PH: Philippines
+ - RESIDENTIAL_KR: South Korea
+ - RESIDENTIAL_SA: Saudi Arabia
+ - RESIDENTIAL_ZA: South Africa
+ - RESIDENTIAL_AR: Argentina
+ - RESIDENTIAL_AU: Australia
+ - RESIDENTIAL_BR: Brazil
+ - RESIDENTIAL_TR: Turkey
+ - RESIDENTIAL_CA: Canada
+ - RESIDENTIAL_MX: Mexico
+ - RESIDENTIAL_IT: Italy
+ - RESIDENTIAL_NL: Netherlands
+ - RESIDENTIAL_ISP: ISP proxy
+ - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
+ - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
+ - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
+ - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
+ - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
+ - NONE: No proxy
+
+ For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
+ Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}
+
+ data_extraction_schema : typing.Optional[TaskRunRequestInputDataExtractionSchema]
+
+ The schema for data to be extracted from the webpage. If you're looking for consistent data schema being returned by the agent, it's highly recommended to use https://json-schema.org/.
+
+ error_code_mapping : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+
+ Custom mapping of error codes to error messages if Skyvern encounters an error.
+
+ max_steps : typing.Optional[int]
+
+ Maximum number of steps the task can take. Task will fail if it exceeds this number. Cautions: you are charged per step so please set this number to a reasonable value. Contact [email protected] for custom pricing.
+
+ webhook_url : typing.Optional[str]
+
+ After a run is finished, send an update to this URL. Refer to https://www.skyvern.com/docs/running-tasks/webhooks-faq for more details.
+
+ totp_identifier : typing.Optional[str]
+
+ Identifier for the TOTP/2FA/MFA code when the code is pushed to Skyvern. Refer to https://www.skyvern.com/docs/credentials/totp#option-3-push-code-to-skyvern for more details.
+
+ totp_url : typing.Optional[str]
+
+ URL that serves TOTP/2FA/MFA codes for Skyvern to use during the workflow run. Refer to https://www.skyvern.com/docs/credentials/totp#option-2-get-code-from-your-endpoint for more details.
+
+ browser_session_id : typing.Optional[str]
+
+ Run the task or workflow in the specific Skyvern browser session. Having a browser session can persist the real-time state of the browser, so that the next run can continue from where the previous run left off.
+
+ model : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
+
+ Optional model configuration.
+
+ extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ The extra HTTP headers for the requests in browser.
+
+ cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Use this for browser-provider auth (e.g., x-api-key for Skyvern Cloud, Browserless, or similar). These headers are NEVER forwarded to target websites.
+
+ publish_workflow : typing.Optional[bool]
+ Deprecated. Whether to publish a `skyvern-2.0` task as a reusable workflow. For backwards compatibility, this routes the request through the legacy `skyvern-2.0` publish path. Prefer creating reusable workflows through the workflow APIs.
+
+ include_action_history_in_verification : typing.Optional[bool]
+ Whether to include action history when verifying that the task is complete
+
+ max_screenshot_scrolls : typing.Optional[int]
+ The maximum number of scrolls for the post action screenshot. When it's None or 0, it takes the current viewpoint screenshot.
+
+ browser_address : typing.Optional[str]
+ The CDP address for the task.
+
+ run_with : typing.Optional[str]
+ Whether to run the task with agent or code. Null means use the default.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[TaskRunResponse]
+ Successfully run task
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/run/tasks",
+ method="POST",
+ json={
+ "prompt": prompt,
+ "url": url,
+ "engine": engine,
+ "title": title,
+ "proxy_location": convert_and_respect_annotation_metadata(
+ object_=proxy_location, annotation=TaskRunRequestInputProxyLocation, direction="write"
+ ),
+ "data_extraction_schema": convert_and_respect_annotation_metadata(
+ object_=data_extraction_schema,
+ annotation=TaskRunRequestInputDataExtractionSchema,
+ direction="write",
+ ),
+ "error_code_mapping": error_code_mapping,
+ "max_steps": max_steps,
+ "webhook_url": webhook_url,
+ "totp_identifier": totp_identifier,
+ "totp_url": totp_url,
+ "browser_session_id": browser_session_id,
+ "model": model,
+ "extra_http_headers": extra_http_headers,
+ "cdp_connect_headers": cdp_connect_headers,
+ "publish_workflow": publish_workflow,
+ "include_action_history_in_verification": include_action_history_in_verification,
+ "max_screenshot_scrolls": max_screenshot_scrolls,
+ "browser_address": browser_address,
+ "run_with": run_with,
+ },
+ headers={
+ "content-type": "application/json",
+ "x-user-agent": str(user_agent) if user_agent is not None else None,
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ TaskRunResponse,
+ parse_obj_as(
+ type_=TaskRunResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
parse_obj_as(
@@ -4066,49 +5898,168 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def apply_workflow_tags(
- self,
- workflow_permanent_id: str,
- *,
- tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
- tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[TagsResponse]:
- """
- Atomically apply tag changes to a workflow. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
+ async def run_workflow(
+ self,
+ *,
+ agent_id: str,
+ template: typing.Optional[bool] = None,
+ max_steps_override: typing.Optional[int] = None,
+ user_agent: typing.Optional[str] = None,
+ parameters: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
+ title: typing.Optional[str] = OMIT,
+ proxy_location: typing.Optional[WorkflowRunRequestInputProxyLocation] = OMIT,
+ webhook_url: typing.Optional[str] = OMIT,
+ totp_url: typing.Optional[str] = OMIT,
+ totp_identifier: typing.Optional[str] = OMIT,
+ browser_session_id: typing.Optional[str] = OMIT,
+ browser_profile_id: typing.Optional[str] = OMIT,
+ max_screenshot_scrolls: typing.Optional[int] = OMIT,
+ max_elapsed_time_minutes: typing.Optional[int] = OMIT,
+ extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ browser_address: typing.Optional[str] = OMIT,
+ ai_fallback: typing.Optional[bool] = OMIT,
+ run_with: typing.Optional[str] = OMIT,
+ run_metadata: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[WorkflowRunResponse]:
+ """
+ Run an agent
+
+ Parameters
+ ----------
+ agent_id : str
+ ID of the agent to run. Starts with `wpid_`. `workflow_id` is accepted as an alias.
+
+ template : typing.Optional[bool]
+
+ max_steps_override : typing.Optional[int]
+
+ user_agent : typing.Optional[str]
+
+ parameters : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
+ Parameters to pass to the workflow
+
+ title : typing.Optional[str]
+ The title for this workflow run
+
+ proxy_location : typing.Optional[WorkflowRunRequestInputProxyLocation]
+
+ Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
+
+ Available geotargeting options:
+ - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
+ - RESIDENTIAL_ES: Spain
+ - RESIDENTIAL_IE: Ireland
+ - RESIDENTIAL_GB: United Kingdom
+ - RESIDENTIAL_IN: India
+ - RESIDENTIAL_JP: Japan
+ - RESIDENTIAL_FR: France
+ - RESIDENTIAL_DE: Germany
+ - RESIDENTIAL_NZ: New Zealand
+ - RESIDENTIAL_PH: Philippines
+ - RESIDENTIAL_KR: South Korea
+ - RESIDENTIAL_SA: Saudi Arabia
+ - RESIDENTIAL_ZA: South Africa
+ - RESIDENTIAL_AR: Argentina
+ - RESIDENTIAL_AU: Australia
+ - RESIDENTIAL_BR: Brazil
+ - RESIDENTIAL_TR: Turkey
+ - RESIDENTIAL_CA: Canada
+ - RESIDENTIAL_MX: Mexico
+ - RESIDENTIAL_IT: Italy
+ - RESIDENTIAL_NL: Netherlands
+ - RESIDENTIAL_ISP: ISP proxy
+ - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
+ - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
+ - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
+ - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
+ - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
+ - NONE: No proxy
+
+ For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
+ Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}
+
+ webhook_url : typing.Optional[str]
+ URL to send workflow status updates to after a run is finished. Refer to https://www.skyvern.com/docs/running-tasks/webhooks-faq for webhook questions.
+
+ totp_url : typing.Optional[str]
- Parameters
- ----------
- workflow_permanent_id : str
- Workflow permanent ID
+ URL that serves TOTP/2FA/MFA codes for Skyvern to use during the workflow run. Refer to https://www.skyvern.com/docs/credentials/totp#option-2-get-code-from-your-endpoint for more details.
- tags : typing.Optional[typing.Sequence[TagInput]]
- Tags to set (overwrite). List of {key?, value} objects.
+ totp_identifier : typing.Optional[str]
- tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
- Tags to soft-delete. List of {key?, value?} targets.
+ Identifier for the TOTP/2FA/MFA code when the code is pushed to Skyvern. Refer to https://www.skyvern.com/docs/credentials/totp#option-3-push-code-to-skyvern for more details.
+
+ browser_session_id : typing.Optional[str]
+ ID of a Skyvern browser session to reuse, having it continue from the current screen state
+
+ browser_profile_id : typing.Optional[str]
+ ID of a browser profile to reuse for this workflow run
+
+ max_screenshot_scrolls : typing.Optional[int]
+ The maximum number of scrolls for the post action screenshot. When it's None or 0, it takes the current viewpoint screenshot.
+
+ max_elapsed_time_minutes : typing.Optional[int]
+ Timeout this workflow run after the configured elapsed runtime in minutes. When omitted, the platform default is 240 minutes. The maximum configurable value is 480 minutes.
+
+ extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ The extra HTTP headers for the requests in browser.
+
+ cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Use this for browser-provider auth (e.g., x-api-key for Skyvern Cloud, Browserless, or similar). These headers are NEVER forwarded to target websites.
+
+ browser_address : typing.Optional[str]
+ The CDP address for the workflow run.
+
+ ai_fallback : typing.Optional[bool]
+ Whether to fallback to AI if the workflow run fails.
+
+ run_with : typing.Optional[str]
+ Whether to run the workflow with agent or code. Null inherits from the workflow setting.
+
+ run_metadata : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ String key/value metadata to attach to this workflow run for analytics tag filtering.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[TagsResponse]
- Successfully applied tag changes
+ AsyncHttpResponse[WorkflowRunResponse]
+ Successfully ran agent
"""
- _response = self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/tags",
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/run/agents",
method="POST",
+ params={
+ "template": template,
+ },
json={
- "tags": convert_and_respect_annotation_metadata(
- object_=tags, annotation=typing.Sequence[TagInput], direction="write"
- ),
- "tags_to_delete": convert_and_respect_annotation_metadata(
- object_=tags_to_delete, annotation=typing.Sequence[TagDeleteInput], direction="write"
+ "agent_id": agent_id,
+ "parameters": parameters,
+ "title": title,
+ "proxy_location": convert_and_respect_annotation_metadata(
+ object_=proxy_location, annotation=WorkflowRunRequestInputProxyLocation, direction="write"
),
+ "webhook_url": webhook_url,
+ "totp_url": totp_url,
+ "totp_identifier": totp_identifier,
+ "browser_session_id": browser_session_id,
+ "browser_profile_id": browser_profile_id,
+ "max_screenshot_scrolls": max_screenshot_scrolls,
+ "max_elapsed_time_minutes": max_elapsed_time_minutes,
+ "extra_http_headers": extra_http_headers,
+ "cdp_connect_headers": cdp_connect_headers,
+ "browser_address": browser_address,
+ "ai_fallback": ai_fallback,
+ "run_with": run_with,
+ "run_metadata": run_metadata,
},
headers={
"content-type": "application/json",
+ "x-max-steps-override": str(max_steps_override) if max_steps_override is not None else None,
+ "x-user-agent": str(user_agent) if user_agent is not None else None,
},
request_options=request_options,
omit=OMIT,
@@ -4116,15 +6067,15 @@ class RawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TagsResponse,
+ WorkflowRunResponse,
parse_obj_as(
- type_=TagsResponse, # type: ignore
+ type_=WorkflowRunResponse, # type: ignore
object_=_response.json(),
),
)
- return HttpResponse(response=_response, data=_data)
- if _response.status_code == 404:
- raise NotFoundError(
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 400:
+ raise BadRequestError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -4150,43 +6101,40 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def delete_workflow_tag(
- self, workflow_permanent_id: str, key: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> HttpResponse[TagsResponse]:
+ async def get_run(
+ self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[GetRunResponse]:
"""
- Soft-delete a single tag from a workflow. Writes a DELETE event row.
+ Get run information (task run, workflow run)
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
-
- key : str
- Tag key to delete
+ run_id : str
+ The id of the task run or the workflow run.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[TagsResponse]
- Successfully deleted tag (or no-op if absent)
+ AsyncHttpResponse[GetRunResponse]
+ Successfully got run
"""
- _response = self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/tags/{jsonable_encoder(key)}",
- method="DELETE",
+ _response = await self._client_wrapper.httpx_client.request(
+ f"v1/runs/{jsonable_encoder(run_id)}",
+ method="GET",
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TagsResponse,
+ GetRunResponse,
parse_obj_as(
- type_=TagsResponse, # type: ignore
+ type_=GetRunResponse, # type: ignore
object_=_response.json(),
),
)
- return HttpResponse(response=_response, data=_data)
+ return AsyncHttpResponse(response=_response, data=_data)
if _response.status_code == 404:
raise NotFoundError(
headers=dict(_response.headers),
@@ -4214,71 +6162,42 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_workflow_tag_history(
- self,
- workflow_permanent_id: str,
- *,
- limit: typing.Optional[int] = None,
- since: typing.Optional[dt.datetime] = None,
- key: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[TagHistoryResponse]:
+ async def cancel_run(
+ self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[typing.Optional[typing.Any]]:
"""
- Chronological tag-event log for a workflow (newest first). Includes SET and DELETE events.
+ Cancel a run (task or workflow)
Parameters
----------
- workflow_permanent_id : str
- Workflow permanent ID
-
- limit : typing.Optional[int]
- Max events to return
-
- since : typing.Optional[dt.datetime]
- Only return events at or after this timestamp
-
- key : typing.Optional[str]
- Filter to events for a single tag key
+ run_id : str
+ The id of the task run or the workflow run to cancel.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[TagHistoryResponse]
- Successfully retrieved tag history
+ AsyncHttpResponse[typing.Optional[typing.Any]]
+ Successful Response
"""
- _response = self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/tags/history",
- method="GET",
- params={
- "limit": limit,
- "since": serialize_datetime(since) if since is not None else None,
- "key": key,
- },
+ _response = await self._client_wrapper.httpx_client.request(
+ f"v1/runs/{jsonable_encoder(run_id)}/cancel",
+ method="POST",
request_options=request_options,
)
try:
+ if _response is None or not _response.text.strip():
+ return AsyncHttpResponse(response=_response, data=None)
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TagHistoryResponse,
+ typing.Optional[typing.Any],
parse_obj_as(
- type_=TagHistoryResponse, # type: ignore
+ type_=typing.Optional[typing.Any], # type: ignore
object_=_response.json(),
),
)
- return HttpResponse(response=_response, data=_data)
- if _response.status_code == 404:
- raise NotFoundError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
+ return AsyncHttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -4295,75 +6214,47 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def retry_workflow_run(
- self,
- workflow_run_id: str,
- *,
- max_steps_override: typing.Optional[int] = None,
- user_agent: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[WorkflowRunResponse]:
+ async def bulk_cancel_runs(
+ self, *, run_ids: typing.Sequence[str], request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[BulkCancelRunsResponse]:
"""
- Retry a workflow run using the original run parameters.
+ Cancel multiple runs (tasks or workflows) in a single request
Parameters
----------
- workflow_run_id : str
- The id of the workflow run to retry.
-
- max_steps_override : typing.Optional[int]
-
- user_agent : typing.Optional[str]
+ run_ids : typing.Sequence[str]
+ List of run IDs to cancel
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[WorkflowRunResponse]
- Successfully retried workflow run
+ AsyncHttpResponse[BulkCancelRunsResponse]
+ Successful Response
"""
- _response = self._client_wrapper.httpx_client.request(
- f"v1/agents/runs/{jsonable_encoder(workflow_run_id)}/retry",
- method="POST",
- headers={
- "x-max-steps-override": str(max_steps_override) if max_steps_override is not None else None,
- "x-user-agent": str(user_agent) if user_agent is not None else None,
- },
- request_options=request_options,
- )
- try:
- if 200 <= _response.status_code < 300:
- _data = typing.cast(
- WorkflowRunResponse,
- parse_obj_as(
- type_=WorkflowRunResponse, # type: ignore
- object_=_response.json(),
- ),
- )
- return HttpResponse(response=_response, data=_data)
- if _response.status_code == 400:
- raise BadRequestError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
- if _response.status_code == 404:
- raise NotFoundError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/runs/cancel",
+ method="POST",
+ json={
+ "run_ids": run_ids,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ BulkCancelRunsResponse,
+ parse_obj_as(
+ type_=BulkCancelRunsResponse, # type: ignore
+ object_=_response.json(),
),
)
+ return AsyncHttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -4380,93 +6271,96 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_workflow_runs(
+ async def get_workflows(
self,
*,
page: typing.Optional[int] = None,
page_size: typing.Optional[int] = None,
- status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
+ only_saved_tasks: typing.Optional[bool] = None,
+ only_workflows: typing.Optional[bool] = None,
+ only_templates: typing.Optional[bool] = None,
search_key: typing.Optional[str] = None,
- error_code: typing.Optional[str] = None,
+ title: typing.Optional[str] = None,
+ folder_id: typing.Optional[str] = None,
+ status: typing.Optional[typing.Union[WorkflowStatus, typing.Sequence[WorkflowStatus]]] = None,
+ tags: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
+ template: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[typing.List[WorkflowRun]]:
+ ) -> AsyncHttpResponse[typing.List[Workflow]]:
"""
- List workflow runs across all workflows for the current organization.
-
- Results are paginated and can be filtered by **status**, **search_key**, and **error_code**. All filters are combined with **AND** logic — a run must match every supplied filter to be returned.
-
- ### search_key
+ Get all workflows with the latest version for the organization.
- A case-insensitive substring search that matches against **any** of the following fields:
+ Search semantics:
+ - If `search_key` is provided, its value is used as a unified search term for
+ `workflows.title`, `folders.title`, and workflow parameter metadata (key, description, and default_value for
+ `WorkflowParameterModel`).
+ - Falls back to deprecated `title` (title-only search) if `search_key` is not provided.
+ - Parameter metadata search excludes soft-deleted parameter rows across all parameter tables.
- | Searched field | Description |
- |---|---|
- | `workflow_run_id` | The unique run identifier (e.g. `wr_123…`) |
- | Parameter **key** | The `key` of any workflow parameter definition associated with the run |
- | Parameter **description** | The `description` of any workflow parameter definition |
- | Run parameter **value** | The actual value supplied for any parameter when the run was created |
- | `extra_http_headers` | Extra HTTP headers attached to the run (searched as raw JSON text) |
+ Parameters
+ ----------
+ page : typing.Optional[int]
- Soft-deleted parameter definitions are excluded from key/description matching. A run is returned if **any** of the fields above contain the search term.
+ page_size : typing.Optional[int]
- ### error_code
+ only_saved_tasks : typing.Optional[bool]
- An **exact-match** filter against the `error_code` field inside each task's `errors` JSON array. A run matches if **any** of its tasks contains an error object with a matching `error_code` value. Error codes are user-defined strings set during workflow execution (e.g. `INVALID_CREDENTIALS`, `LOGIN_FAILED`, `CAPTCHA_DETECTED`).
+ only_workflows : typing.Optional[bool]
- ### Combining filters
+ only_templates : typing.Optional[bool]
- All query parameters use AND logic:
- - `?status=failed` — only failed runs
- - `?status=failed&error_code=LOGIN_FAILED` — failed runs **and** have a LOGIN_FAILED error
- - `?status=failed&error_code=LOGIN_FAILED&search_key=prod_credential` — all three conditions must match
+ search_key : typing.Optional[str]
+ Case-insensitive substring search across: workflow title, folder name, and parameter metadata (key, description, default_value). A workflow is returned if any of these fields match. Soft-deleted parameter definitions are excluded. Takes precedence over the deprecated `title` parameter.
- Parameters
- ----------
- page : typing.Optional[int]
- Page number for pagination.
+ title : typing.Optional[str]
+ Deprecated: use search_key instead. Falls back to title-only search if search_key is not provided.
- page_size : typing.Optional[int]
- Number of runs to return per page.
+ folder_id : typing.Optional[str]
+ Filter workflows by folder ID
- status : typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]]
- Filter by one or more run statuses.
+ status : typing.Optional[typing.Union[WorkflowStatus, typing.Sequence[WorkflowStatus]]]
- search_key : typing.Optional[str]
- Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. A run is returned if any of these fields match. Soft-deleted parameter definitions are excluded from key/description matching.
+ tags : typing.Optional[typing.Union[str, typing.Sequence[str]]]
+ Filter by tags. Each term is a label (`production`), a group (`env:*`), or a group:label (`env:prod`). Repeat the param or comma-separate (`?tags=env:prod,env:staging`). AND across distinct terms, OR within a group's labels (`?tags=customer:acme,env:prod,env:staging` -> customer=acme AND env in (prod, staging)). A label term matches the value across any/no group. Matches current tag values only. Not supported with `template=true`.
- error_code : typing.Optional[str]
- Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+ template : typing.Optional[bool]
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[WorkflowRun]]
+ AsyncHttpResponse[typing.List[Workflow]]
Successful Response
"""
- _response = self._client_wrapper.httpx_client.request(
- "v1/agents/runs",
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/agents",
method="GET",
params={
"page": page,
"page_size": page_size,
- "status": status,
+ "only_saved_tasks": only_saved_tasks,
+ "only_workflows": only_workflows,
+ "only_templates": only_templates,
"search_key": search_key,
- "error_code": error_code,
+ "title": title,
+ "folder_id": folder_id,
+ "status": status,
+ "tags": tags,
+ "template": template,
},
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[WorkflowRun],
+ typing.List[Workflow],
parse_obj_as(
- type_=typing.List[WorkflowRun], # type: ignore
+ type_=typing.List[Workflow], # type: ignore
object_=_response.json(),
),
)
- return HttpResponse(response=_response, data=_data)
+ return AsyncHttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -4483,79 +6377,64 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_workflow_runs_by_id(
+ async def create_workflow(
self,
- workflow_id: str,
*,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
- search_key: typing.Optional[str] = None,
- error_code: typing.Optional[str] = None,
+ folder_id: typing.Optional[str] = None,
+ json_definition: typing.Optional[WorkflowCreateYamlRequest] = OMIT,
+ yaml_definition: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[typing.List[WorkflowRun]]:
+ ) -> AsyncHttpResponse[Workflow]:
"""
- List runs for a specific workflow.
-
- Supports filtering by **status**, **search_key**, and **error_code**. All filters are combined with **AND** logic.
-
- ### search_key
-
- Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. Soft-deleted parameter definitions are excluded.
-
- ### error_code
-
- Exact-match filter on the `error_code` field inside each task's `errors` JSON array. A run matches if any of its tasks contains an error with a matching `error_code`.
+ Create a new agent
Parameters
----------
- workflow_id : str
-
- page : typing.Optional[int]
- Page number for pagination.
-
- page_size : typing.Optional[int]
- Number of runs to return per page.
-
- status : typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]]
- Filter by one or more run statuses.
+ folder_id : typing.Optional[str]
+ Optional folder ID to assign the workflow to
- search_key : typing.Optional[str]
- Case-insensitive substring search across: workflow run ID, parameter key, parameter description, run parameter value, and extra HTTP headers. A run is returned if any of these fields match. Soft-deleted parameter definitions are excluded from key/description matching.
+ json_definition : typing.Optional[WorkflowCreateYamlRequest]
+ Workflow definition in JSON format
- error_code : typing.Optional[str]
- Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+ yaml_definition : typing.Optional[str]
+ Workflow definition in YAML format
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[WorkflowRun]]
- Successful Response
+ AsyncHttpResponse[Workflow]
+ Successfully created agent
"""
- _response = self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_id)}/runs",
- method="GET",
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/agents",
+ method="POST",
params={
- "page": page,
- "page_size": page_size,
- "status": status,
- "search_key": search_key,
- "error_code": error_code,
+ "folder_id": folder_id,
+ },
+ json={
+ "json_definition": convert_and_respect_annotation_metadata(
+ object_=json_definition, annotation=WorkflowCreateYamlRequest, direction="write"
+ ),
+ "yaml_definition": yaml_definition,
+ },
+ headers={
+ "content-type": "application/json",
},
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[WorkflowRun],
+ Workflow,
parse_obj_as(
- type_=typing.List[WorkflowRun], # type: ignore
+ type_=Workflow, # type: ignore
object_=_response.json(),
),
)
- return HttpResponse(response=_response, data=_data)
+ return AsyncHttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -4572,50 +6451,113 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_workflow(
+ async def update_workflow(
self,
- workflow_permanent_id: str,
+ workflow_id: str,
*,
- version: typing.Optional[int] = None,
- template: typing.Optional[bool] = None,
+ json_definition: typing.Optional[WorkflowCreateYamlRequest] = OMIT,
+ yaml_definition: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[Workflow]:
+ ) -> AsyncHttpResponse[Workflow]:
+ """
+ Update an agent
+
+ Parameters
+ ----------
+ workflow_id : str
+ The ID of the agent to update. Starts with `wpid_`.
+
+ json_definition : typing.Optional[WorkflowCreateYamlRequest]
+ Workflow definition in JSON format
+
+ yaml_definition : typing.Optional[str]
+ Workflow definition in YAML format
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[Workflow]
+ Successfully updated agent
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_id)}",
+ method="POST",
+ json={
+ "json_definition": convert_and_respect_annotation_metadata(
+ object_=json_definition, annotation=WorkflowCreateYamlRequest, direction="write"
+ ),
+ "yaml_definition": yaml_definition,
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ Workflow,
+ parse_obj_as(
+ type_=Workflow, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def delete_workflow(
+ self, workflow_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[typing.Optional[typing.Any]]:
"""
+ Delete an agent
+
Parameters
----------
- workflow_permanent_id : str
-
- version : typing.Optional[int]
-
- template : typing.Optional[bool]
+ workflow_id : str
+ The ID of the agent to delete. Starts with `wpid_`.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[Workflow]
- Successful Response
+ AsyncHttpResponse[typing.Optional[typing.Any]]
+ Successfully deleted agent
"""
- _response = self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_permanent_id)}",
- method="GET",
- params={
- "version": version,
- "template": template,
- },
+ _response = await self._client_wrapper.httpx_client.request(
+ f"v1/agents/{jsonable_encoder(workflow_id)}/delete",
+ method="POST",
request_options=request_options,
)
try:
+ if _response is None or not _response.text.strip():
+ return AsyncHttpResponse(response=_response, data=None)
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Workflow,
+ typing.Optional[typing.Any],
parse_obj_as(
- type_=Workflow, # type: ignore
+ type_=typing.Optional[typing.Any], # type: ignore
object_=_response.json(),
),
)
- return HttpResponse(response=_response, data=_data)
+ return AsyncHttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -4632,48 +6574,56 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- def get_workflow_versions(
+ async def get_folders(
self,
- workflow_permanent_id: str,
*,
- template: typing.Optional[bool] = None,
+ page: typing.Optional[int] = None,
+ page_size: typing.Optional[int] = None,
+ search: typing.Optional[str] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> HttpResponse[typing.List[Workflow]]:
+ ) -> AsyncHttpResponse[typing.List[Folder]]:
"""
- Get all versions of a workflow by its permanent ID.
+ Get all folders for the organization
Parameters
----------
- workflow_permanent_id : str
+ page : typing.Optional[int]
+ Page number
- template : typing.Optional[bool]
+ page_size : typing.Optional[int]
+ Number of folders per page
+
+ search : typing.Optional[str]
+ Search folders by title or description
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- HttpResponse[typing.List[Workflow]]
- Successful Response
+ AsyncHttpResponse[typing.List[Folder]]
+ Successfully retrieved folders
"""
- _response = self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_permanent_id)}/versions",
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/folders",
method="GET",
params={
- "template": template,
+ "page": page,
+ "page_size": page_size,
+ "search": search,
},
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[Workflow],
+ typing.List[Folder],
parse_obj_as(
- type_=typing.List[Workflow], # type: ignore
+ type_=typing.List[Folder], # type: ignore
object_=_response.json(),
),
)
- return HttpResponse(response=_response, data=_data)
+ return AsyncHttpResponse(response=_response, data=_data)
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -4690,191 +6640,41 @@ class RawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
-
-class AsyncRawSkyvern:
- def __init__(self, *, client_wrapper: AsyncClientWrapper):
- self._client_wrapper = client_wrapper
-
- async def run_task(
+ async def create_folder(
self,
*,
- prompt: str,
- user_agent: typing.Optional[str] = None,
- url: typing.Optional[str] = OMIT,
- engine: typing.Optional[RunEngine] = OMIT,
- title: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[TaskRunRequestInputProxyLocation] = OMIT,
- data_extraction_schema: typing.Optional[TaskRunRequestInputDataExtractionSchema] = OMIT,
- error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- max_steps: typing.Optional[int] = OMIT,
- webhook_url: typing.Optional[str] = OMIT,
- totp_identifier: typing.Optional[str] = OMIT,
- totp_url: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
- extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- publish_workflow: typing.Optional[bool] = OMIT,
- include_action_history_in_verification: typing.Optional[bool] = OMIT,
- max_screenshot_scrolls: typing.Optional[int] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- run_with: typing.Optional[str] = OMIT,
+ title: str,
+ description: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[TaskRunResponse]:
+ ) -> AsyncHttpResponse[Folder]:
"""
- Run a task
+ Create a new folder to organize workflows
Parameters
----------
- prompt : str
-
- The goal or task description for Skyvern to accomplish
-
- user_agent : typing.Optional[str]
-
- url : typing.Optional[str]
-
- The starting URL for the task. If not provided, Skyvern will attempt to determine an appropriate URL
-
- engine : typing.Optional[RunEngine]
-
- The engine that powers the agent task. The default value is `skyvern-1.0`, which is good for simple tasks like filling a form, or searching for information on Google. `skyvern-2.0` remains available for existing V2 workflows and explicitly requested V2 task runs. The `openai-cua` engine uses OpenAI's CUA model. The `anthropic-cua` uses Anthropic's Claude Sonnet 3.7 model with the computer use tool.
-
- title : typing.Optional[str]
- The title for the task
-
- proxy_location : typing.Optional[TaskRunRequestInputProxyLocation]
-
- Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
-
- Available geotargeting options:
- - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
- - RESIDENTIAL_ES: Spain
- - RESIDENTIAL_IE: Ireland
- - RESIDENTIAL_GB: United Kingdom
- - RESIDENTIAL_IN: India
- - RESIDENTIAL_JP: Japan
- - RESIDENTIAL_FR: France
- - RESIDENTIAL_DE: Germany
- - RESIDENTIAL_NZ: New Zealand
- - RESIDENTIAL_PH: Philippines
- - RESIDENTIAL_KR: South Korea
- - RESIDENTIAL_SA: Saudi Arabia
- - RESIDENTIAL_ZA: South Africa
- - RESIDENTIAL_AR: Argentina
- - RESIDENTIAL_AU: Australia
- - RESIDENTIAL_BR: Brazil
- - RESIDENTIAL_TR: Turkey
- - RESIDENTIAL_CA: Canada
- - RESIDENTIAL_MX: Mexico
- - RESIDENTIAL_IT: Italy
- - RESIDENTIAL_NL: Netherlands
- - RESIDENTIAL_ISP: ISP proxy
- - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
- - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
- - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
- - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
- - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
- - NONE: No proxy
-
- For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
- Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}
-
- data_extraction_schema : typing.Optional[TaskRunRequestInputDataExtractionSchema]
-
- The schema for data to be extracted from the webpage. If you're looking for consistent data schema being returned by the agent, it's highly recommended to use https://json-schema.org/.
-
- error_code_mapping : typing.Optional[typing.Dict[str, typing.Optional[str]]]
-
- Custom mapping of error codes to error messages if Skyvern encounters an error.
-
- max_steps : typing.Optional[int]
-
- Maximum number of steps the task can take. Task will fail if it exceeds this number. Cautions: you are charged per step so please set this number to a reasonable value. Contact [email protected] for custom pricing.
-
- webhook_url : typing.Optional[str]
-
- After a run is finished, send an update to this URL. Refer to https://www.skyvern.com/docs/running-tasks/webhooks-faq for more details.
-
- totp_identifier : typing.Optional[str]
-
- Identifier for the TOTP/2FA/MFA code when the code is pushed to Skyvern. Refer to https://www.skyvern.com/docs/credentials/totp#option-3-push-code-to-skyvern for more details.
-
- totp_url : typing.Optional[str]
-
- URL that serves TOTP/2FA/MFA codes for Skyvern to use during the workflow run. Refer to https://www.skyvern.com/docs/credentials/totp#option-2-get-code-from-your-endpoint for more details.
-
- browser_session_id : typing.Optional[str]
-
- Run the task or workflow in the specific Skyvern browser session. Having a browser session can persist the real-time state of the browser, so that the next run can continue from where the previous run left off.
-
- model : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
-
- Optional model configuration.
-
- extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- The extra HTTP headers for the requests in browser.
-
- cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Use this for browser-provider auth (e.g., x-api-key for Skyvern Cloud, Browserless, or similar). These headers are NEVER forwarded to target websites.
-
- publish_workflow : typing.Optional[bool]
- Deprecated. Whether to publish a `skyvern-2.0` task as a reusable workflow. For backwards compatibility, this routes the request through the legacy `skyvern-2.0` publish path. Prefer creating reusable workflows through the workflow APIs.
-
- include_action_history_in_verification : typing.Optional[bool]
- Whether to include action history when verifying that the task is complete
-
- max_screenshot_scrolls : typing.Optional[int]
- The maximum number of scrolls for the post action screenshot. When it's None or 0, it takes the current viewpoint screenshot.
-
- browser_address : typing.Optional[str]
- The CDP address for the task.
+ title : str
+ Folder title
- run_with : typing.Optional[str]
- Whether to run the task with agent or code. Null means use the default.
+ description : typing.Optional[str]
+ Folder description
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[TaskRunResponse]
- Successfully run task
- """
- _response = await self._client_wrapper.httpx_client.request(
- "v1/run/tasks",
- method="POST",
- json={
- "prompt": prompt,
- "url": url,
- "engine": engine,
- "title": title,
- "proxy_location": convert_and_respect_annotation_metadata(
- object_=proxy_location, annotation=TaskRunRequestInputProxyLocation, direction="write"
- ),
- "data_extraction_schema": convert_and_respect_annotation_metadata(
- object_=data_extraction_schema,
- annotation=TaskRunRequestInputDataExtractionSchema,
- direction="write",
- ),
- "error_code_mapping": error_code_mapping,
- "max_steps": max_steps,
- "webhook_url": webhook_url,
- "totp_identifier": totp_identifier,
- "totp_url": totp_url,
- "browser_session_id": browser_session_id,
- "model": model,
- "extra_http_headers": extra_http_headers,
- "cdp_connect_headers": cdp_connect_headers,
- "publish_workflow": publish_workflow,
- "include_action_history_in_verification": include_action_history_in_verification,
- "max_screenshot_scrolls": max_screenshot_scrolls,
- "browser_address": browser_address,
- "run_with": run_with,
+ AsyncHttpResponse[Folder]
+ Successfully created folder
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/folders",
+ method="POST",
+ json={
+ "title": title,
+ "description": description,
},
headers={
"content-type": "application/json",
- "x-user-agent": str(user_agent) if user_agent is not None else None,
},
request_options=request_options,
omit=OMIT,
@@ -4882,9 +6682,9 @@ class AsyncRawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TaskRunResponse,
+ Folder,
parse_obj_as(
- type_=TaskRunResponse, # type: ignore
+ type_=Folder, # type: ignore
object_=_response.json(),
),
)
@@ -4916,184 +6716,42 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def run_workflow(
- self,
- *,
- agent_id: str,
- template: typing.Optional[bool] = None,
- max_steps_override: typing.Optional[int] = None,
- user_agent: typing.Optional[str] = None,
- parameters: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,
- title: typing.Optional[str] = OMIT,
- proxy_location: typing.Optional[WorkflowRunRequestInputProxyLocation] = OMIT,
- webhook_url: typing.Optional[str] = OMIT,
- totp_url: typing.Optional[str] = OMIT,
- totp_identifier: typing.Optional[str] = OMIT,
- browser_session_id: typing.Optional[str] = OMIT,
- browser_profile_id: typing.Optional[str] = OMIT,
- max_screenshot_scrolls: typing.Optional[int] = OMIT,
- max_elapsed_time_minutes: typing.Optional[int] = OMIT,
- extra_http_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- cdp_connect_headers: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- browser_address: typing.Optional[str] = OMIT,
- ai_fallback: typing.Optional[bool] = OMIT,
- run_with: typing.Optional[str] = OMIT,
- run_metadata: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[WorkflowRunResponse]:
+ async def get_folder(
+ self, folder_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[Folder]:
"""
- Run an agent
+ Get a specific folder by ID
Parameters
----------
- agent_id : str
- ID of the agent to run. Starts with `wpid_`. `workflow_id` is accepted as an alias.
-
- template : typing.Optional[bool]
-
- max_steps_override : typing.Optional[int]
-
- user_agent : typing.Optional[str]
-
- parameters : typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]]
- Parameters to pass to the workflow
-
- title : typing.Optional[str]
- The title for this workflow run
-
- proxy_location : typing.Optional[WorkflowRunRequestInputProxyLocation]
-
- Geographic Proxy location to route the browser traffic through. This is only available in Skyvern Cloud.
-
- Available geotargeting options:
- - RESIDENTIAL: the default value. Skyvern Cloud uses a random US residential proxy.
- - RESIDENTIAL_ES: Spain
- - RESIDENTIAL_IE: Ireland
- - RESIDENTIAL_GB: United Kingdom
- - RESIDENTIAL_IN: India
- - RESIDENTIAL_JP: Japan
- - RESIDENTIAL_FR: France
- - RESIDENTIAL_DE: Germany
- - RESIDENTIAL_NZ: New Zealand
- - RESIDENTIAL_PH: Philippines
- - RESIDENTIAL_KR: South Korea
- - RESIDENTIAL_SA: Saudi Arabia
- - RESIDENTIAL_ZA: South Africa
- - RESIDENTIAL_AR: Argentina
- - RESIDENTIAL_AU: Australia
- - RESIDENTIAL_BR: Brazil
- - RESIDENTIAL_TR: Turkey
- - RESIDENTIAL_CA: Canada
- - RESIDENTIAL_MX: Mexico
- - RESIDENTIAL_IT: Italy
- - RESIDENTIAL_NL: Netherlands
- - RESIDENTIAL_ISP: ISP proxy
- - US-CA: California (deprecated, routes through RESIDENTIAL_ISP)
- - US-NY: New York (deprecated, routes through RESIDENTIAL_ISP)
- - US-TX: Texas (deprecated, routes through RESIDENTIAL_ISP)
- - US-FL: Florida (deprecated, routes through RESIDENTIAL_ISP)
- - US-WA: Washington (deprecated, routes through RESIDENTIAL_ISP)
- - NONE: No proxy
-
- For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
- Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}
-
- webhook_url : typing.Optional[str]
- URL to send workflow status updates to after a run is finished. Refer to https://www.skyvern.com/docs/running-tasks/webhooks-faq for webhook questions.
-
- totp_url : typing.Optional[str]
-
- URL that serves TOTP/2FA/MFA codes for Skyvern to use during the workflow run. Refer to https://www.skyvern.com/docs/credentials/totp#option-2-get-code-from-your-endpoint for more details.
-
- totp_identifier : typing.Optional[str]
-
- Identifier for the TOTP/2FA/MFA code when the code is pushed to Skyvern. Refer to https://www.skyvern.com/docs/credentials/totp#option-3-push-code-to-skyvern for more details.
-
- browser_session_id : typing.Optional[str]
- ID of a Skyvern browser session to reuse, having it continue from the current screen state
-
- browser_profile_id : typing.Optional[str]
- ID of a browser profile to reuse for this workflow run
-
- max_screenshot_scrolls : typing.Optional[int]
- The maximum number of scrolls for the post action screenshot. When it's None or 0, it takes the current viewpoint screenshot.
-
- max_elapsed_time_minutes : typing.Optional[int]
- Timeout this workflow run after the configured elapsed runtime in minutes. When omitted, the platform default is 240 minutes. The maximum configurable value is 480 minutes.
-
- extra_http_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- The extra HTTP headers for the requests in browser.
-
- cdp_connect_headers : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- HTTP headers attached ONLY to the CDP WebSocket handshake when connecting to a remote browser via browser_address. Use this for browser-provider auth (e.g., x-api-key for Skyvern Cloud, Browserless, or similar). These headers are NEVER forwarded to target websites.
-
- browser_address : typing.Optional[str]
- The CDP address for the workflow run.
-
- ai_fallback : typing.Optional[bool]
- Whether to fallback to AI if the workflow run fails.
-
- run_with : typing.Optional[str]
- Whether to run the workflow with agent or code. Null inherits from the workflow setting.
-
- run_metadata : typing.Optional[typing.Dict[str, typing.Optional[str]]]
- String key/value metadata to attach to this workflow run for analytics tag filtering.
+ folder_id : str
+ Folder ID
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[WorkflowRunResponse]
- Successfully ran agent
+ AsyncHttpResponse[Folder]
+ Successfully retrieved folder
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/run/agents",
- method="POST",
- params={
- "template": template,
- },
- json={
- "agent_id": agent_id,
- "parameters": parameters,
- "title": title,
- "proxy_location": convert_and_respect_annotation_metadata(
- object_=proxy_location, annotation=WorkflowRunRequestInputProxyLocation, direction="write"
- ),
- "webhook_url": webhook_url,
- "totp_url": totp_url,
- "totp_identifier": totp_identifier,
- "browser_session_id": browser_session_id,
- "browser_profile_id": browser_profile_id,
- "max_screenshot_scrolls": max_screenshot_scrolls,
- "max_elapsed_time_minutes": max_elapsed_time_minutes,
- "extra_http_headers": extra_http_headers,
- "cdp_connect_headers": cdp_connect_headers,
- "browser_address": browser_address,
- "ai_fallback": ai_fallback,
- "run_with": run_with,
- "run_metadata": run_metadata,
- },
- headers={
- "content-type": "application/json",
- "x-max-steps-override": str(max_steps_override) if max_steps_override is not None else None,
- "x-user-agent": str(user_agent) if user_agent is not None else None,
- },
+ f"v1/folders/{jsonable_encoder(folder_id)}",
+ method="GET",
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- WorkflowRunResponse,
+ Folder,
parse_obj_as(
- type_=WorkflowRunResponse, # type: ignore
+ type_=Folder, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
- if _response.status_code == 400:
- raise BadRequestError(
+ if _response.status_code == 404:
+ raise NotFoundError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -5119,36 +6777,55 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def get_run(
- self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[GetRunResponse]:
+ async def update_folder(
+ self,
+ folder_id: str,
+ *,
+ title: typing.Optional[str] = OMIT,
+ description: typing.Optional[str] = OMIT,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[Folder]:
"""
- Get run information (task run, workflow run)
+ Update a folder's title or description
Parameters
----------
- run_id : str
- The id of the task run or the workflow run.
+ folder_id : str
+ Folder ID
+
+ title : typing.Optional[str]
+ Folder title
+
+ description : typing.Optional[str]
+ Folder description
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[GetRunResponse]
- Successfully got run
+ AsyncHttpResponse[Folder]
+ Successfully updated folder
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/runs/{jsonable_encoder(run_id)}",
- method="GET",
+ f"v1/folders/{jsonable_encoder(folder_id)}",
+ method="PUT",
+ json={
+ "title": title,
+ "description": description,
+ },
+ headers={
+ "content-type": "application/json",
+ },
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- GetRunResponse,
+ Folder,
parse_obj_as(
- type_=GetRunResponse, # type: ignore
+ type_=Folder, # type: ignore
object_=_response.json(),
),
)
@@ -5180,42 +6857,61 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def cancel_run(
- self, run_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[typing.Optional[typing.Any]]:
+ async def delete_folder(
+ self,
+ folder_id: str,
+ *,
+ delete_workflows: typing.Optional[bool] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[typing.Dict[str, typing.Optional[typing.Any]]]:
"""
- Cancel a run (task or workflow)
+ Delete a folder. Optionally delete all workflows in the folder.
Parameters
----------
- run_id : str
- The id of the task run or the workflow run to cancel.
+ folder_id : str
+ Folder ID
+
+ delete_workflows : typing.Optional[bool]
+ If true, also delete all workflows in this folder
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[typing.Optional[typing.Any]]
- Successful Response
+ AsyncHttpResponse[typing.Dict[str, typing.Optional[typing.Any]]]
+ Successfully deleted folder
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/runs/{jsonable_encoder(run_id)}/cancel",
- method="POST",
+ f"v1/folders/{jsonable_encoder(folder_id)}",
+ method="DELETE",
+ params={
+ "delete_workflows": delete_workflows,
+ },
request_options=request_options,
)
try:
- if _response is None or not _response.text.strip():
- return AsyncHttpResponse(response=_response, data=None)
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.Optional[typing.Any],
+ typing.Dict[str, typing.Optional[typing.Any]],
parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
+ type_=typing.Dict[str, typing.Optional[typing.Any]], # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -5232,47 +6928,51 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def bulk_cancel_runs(
- self, *, run_ids: typing.Sequence[str], request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[BulkCancelRunsResponse]:
+ async def get_run_tags(
+ self, workflow_run_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[RunTagsResponse]:
"""
- Cancel multiple runs (tasks or workflows) in a single request
+ Get the current tag state for a workflow run.
Parameters
----------
- run_ids : typing.Sequence[str]
- List of run IDs to cancel
+ workflow_run_id : str
+ Workflow run ID
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[BulkCancelRunsResponse]
- Successful Response
+ AsyncHttpResponse[RunTagsResponse]
+ Successfully retrieved tags
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/runs/cancel",
- method="POST",
- json={
- "run_ids": run_ids,
- },
- headers={
- "content-type": "application/json",
- },
+ f"v1/runs/{jsonable_encoder(workflow_run_id)}/tags",
+ method="GET",
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- BulkCancelRunsResponse,
+ RunTagsResponse,
parse_obj_as(
- type_=BulkCancelRunsResponse, # type: ignore
+ type_=RunTagsResponse, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -5289,96 +6989,79 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def get_workflows(
+ async def apply_run_tags(
self,
+ workflow_run_id: str,
*,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- only_saved_tasks: typing.Optional[bool] = None,
- only_workflows: typing.Optional[bool] = None,
- only_templates: typing.Optional[bool] = None,
- search_key: typing.Optional[str] = None,
- title: typing.Optional[str] = None,
- folder_id: typing.Optional[str] = None,
- status: typing.Optional[typing.Union[WorkflowStatus, typing.Sequence[WorkflowStatus]]] = None,
- tags: typing.Optional[typing.Union[str, typing.Sequence[str]]] = None,
- template: typing.Optional[bool] = None,
+ tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
+ tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[typing.List[Workflow]]:
+ ) -> AsyncHttpResponse[RunTagsResponse]:
"""
- Get all workflows with the latest version for the organization.
-
- Search semantics:
- - If `search_key` is provided, its value is used as a unified search term for
- `workflows.title`, `folders.title`, and workflow parameter metadata (key, description, and default_value for
- `WorkflowParameterModel`).
- - Falls back to deprecated `title` (title-only search) if `search_key` is not provided.
- - Parameter metadata search excludes soft-deleted parameter rows across all parameter tables.
+ Atomically apply tag changes to a workflow run. Sets and deletes happen in one transaction; same-key collisions resolve set-wins.
Parameters
----------
- page : typing.Optional[int]
-
- page_size : typing.Optional[int]
-
- only_saved_tasks : typing.Optional[bool]
-
- only_workflows : typing.Optional[bool]
-
- only_templates : typing.Optional[bool]
-
- search_key : typing.Optional[str]
- Case-insensitive substring search across: workflow title, folder name, and parameter metadata (key, description, default_value). A workflow is returned if any of these fields match. Soft-deleted parameter definitions are excluded. Takes precedence over the deprecated `title` parameter.
-
- title : typing.Optional[str]
- Deprecated: use search_key instead. Falls back to title-only search if search_key is not provided.
-
- folder_id : typing.Optional[str]
- Filter workflows by folder ID
+ workflow_run_id : str
+ Workflow run ID
- status : typing.Optional[typing.Union[WorkflowStatus, typing.Sequence[WorkflowStatus]]]
+ tags : typing.Optional[typing.Sequence[TagInput]]
+ Tags to set (overwrite). List of {key?, value} objects.
- tags : typing.Optional[typing.Union[str, typing.Sequence[str]]]
- Filter by tags. Each term is a label (`production`), a group (`env:*`), or a group:label (`env:prod`). Repeat the param or comma-separate (`?tags=env:prod,env:staging`). AND across distinct terms, OR within a group's labels (`?tags=customer:acme,env:prod,env:staging` -> customer=acme AND env in (prod, staging)). A label term matches the value across any/no group. Matches current tag values only. Not supported with `template=true`.
+ tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
+ Tags to soft-delete. List of {key?, value?} targets.
- template : typing.Optional[bool]
+ colors : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[typing.List[Workflow]]
- Successful Response
+ AsyncHttpResponse[RunTagsResponse]
+ Successfully applied tag changes
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/agents",
- method="GET",
- params={
- "page": page,
- "page_size": page_size,
- "only_saved_tasks": only_saved_tasks,
- "only_workflows": only_workflows,
- "only_templates": only_templates,
- "search_key": search_key,
- "title": title,
- "folder_id": folder_id,
- "status": status,
- "tags": tags,
- "template": template,
+ f"v1/runs/{jsonable_encoder(workflow_run_id)}/tags",
+ method="POST",
+ json={
+ "tags": convert_and_respect_annotation_metadata(
+ object_=tags, annotation=typing.Sequence[TagInput], direction="write"
+ ),
+ "tags_to_delete": convert_and_respect_annotation_metadata(
+ object_=tags_to_delete, annotation=typing.Sequence[TagDeleteInput], direction="write"
+ ),
+ "colors": colors,
+ },
+ headers={
+ "content-type": "application/json",
},
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[Workflow],
+ RunTagsResponse,
parse_obj_as(
- type_=typing.List[Workflow], # type: ignore
+ type_=RunTagsResponse, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -5395,64 +7078,54 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def create_workflow(
- self,
- *,
- folder_id: typing.Optional[str] = None,
- json_definition: typing.Optional[WorkflowCreateYamlRequest] = OMIT,
- yaml_definition: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[Workflow]:
+ async def delete_run_tag(
+ self, workflow_run_id: str, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[RunTagsResponse]:
"""
- Create a new agent
+ Soft-delete a single grouped tag from a workflow run. Writes a DELETE event row.
Parameters
----------
- folder_id : typing.Optional[str]
- Optional folder ID to assign the workflow to
-
- json_definition : typing.Optional[WorkflowCreateYamlRequest]
- Workflow definition in JSON format
+ workflow_run_id : str
+ Workflow run ID
- yaml_definition : typing.Optional[str]
- Workflow definition in YAML format
+ key : str
+ Tag key to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[Workflow]
- Successfully created agent
+ AsyncHttpResponse[RunTagsResponse]
+ Successfully deleted tag (or no-op if absent)
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/agents",
- method="POST",
- params={
- "folder_id": folder_id,
- },
- json={
- "json_definition": convert_and_respect_annotation_metadata(
- object_=json_definition, annotation=WorkflowCreateYamlRequest, direction="write"
- ),
- "yaml_definition": yaml_definition,
- },
- headers={
- "content-type": "application/json",
- },
+ f"v1/runs/{jsonable_encoder(workflow_run_id)}/tags/{jsonable_encoder(key)}",
+ method="DELETE",
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Workflow,
+ RunTagsResponse,
parse_obj_as(
- type_=Workflow, # type: ignore
+ type_=RunTagsResponse, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -5469,61 +7142,71 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def update_workflow(
+ async def get_run_tag_history(
self,
- workflow_id: str,
+ workflow_run_id: str,
*,
- json_definition: typing.Optional[WorkflowCreateYamlRequest] = OMIT,
- yaml_definition: typing.Optional[str] = OMIT,
+ limit: typing.Optional[int] = None,
+ since: typing.Optional[dt.datetime] = None,
+ key: typing.Optional[str] = None,
request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[Workflow]:
+ ) -> AsyncHttpResponse[RunTagHistoryResponse]:
"""
- Update an agent
+ Chronological tag-event log for a workflow run (newest first). Includes SET and DELETE events.
Parameters
----------
- workflow_id : str
- The ID of the agent to update. Starts with `wpid_`.
+ workflow_run_id : str
+ Workflow run ID
- json_definition : typing.Optional[WorkflowCreateYamlRequest]
- Workflow definition in JSON format
+ limit : typing.Optional[int]
+ Max events to return
- yaml_definition : typing.Optional[str]
- Workflow definition in YAML format
+ since : typing.Optional[dt.datetime]
+ Only return events at or after this timestamp
+
+ key : typing.Optional[str]
+ Filter to events for a single tag key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[Workflow]
- Successfully updated agent
+ AsyncHttpResponse[RunTagHistoryResponse]
+ Successfully retrieved tag history
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_id)}",
- method="POST",
- json={
- "json_definition": convert_and_respect_annotation_metadata(
- object_=json_definition, annotation=WorkflowCreateYamlRequest, direction="write"
- ),
- "yaml_definition": yaml_definition,
- },
- headers={
- "content-type": "application/json",
+ f"v1/runs/{jsonable_encoder(workflow_run_id)}/tags/history",
+ method="GET",
+ params={
+ "limit": limit,
+ "since": serialize_datetime(since) if since is not None else None,
+ "key": key,
},
request_options=request_options,
- omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Workflow,
+ RunTagHistoryResponse,
parse_obj_as(
- type_=Workflow, # type: ignore
+ type_=RunTagHistoryResponse, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -5540,38 +7223,33 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def delete_workflow(
- self, workflow_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[typing.Optional[typing.Any]]:
+ async def list_tag_keys(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[typing.List[TagKey]]:
"""
- Delete an agent
+ List all tag keys registered for the organization with their descriptions.
Parameters
----------
- workflow_id : str
- The ID of the agent to delete. Starts with `wpid_`.
-
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[typing.Optional[typing.Any]]
- Successfully deleted agent
+ AsyncHttpResponse[typing.List[TagKey]]
+ Successfully retrieved tag keys
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/agents/{jsonable_encoder(workflow_id)}/delete",
- method="POST",
+ "v1/tag-keys",
+ method="GET",
request_options=request_options,
)
try:
- if _response is None or not _response.text.strip():
- return AsyncHttpResponse(response=_response, data=None)
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.Optional[typing.Any],
+ typing.List[TagKey],
parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
+ type_=typing.List[TagKey], # type: ignore
object_=_response.json(),
),
)
@@ -5592,56 +7270,51 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def get_folders(
- self,
- *,
- page: typing.Optional[int] = None,
- page_size: typing.Optional[int] = None,
- search: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[typing.List[Folder]]:
+ async def delete_tag_key(
+ self, key: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[TagKeyDeleteResponse]:
"""
- Get all folders for the organization
+ Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
Parameters
----------
- page : typing.Optional[int]
- Page number
-
- page_size : typing.Optional[int]
- Number of folders per page
-
- search : typing.Optional[str]
- Search folders by title or description
+ key : str
+ Tag key to delete
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[typing.List[Folder]]
- Successfully retrieved folders
+ AsyncHttpResponse[TagKeyDeleteResponse]
+ Successfully deleted tag key
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/folders",
- method="GET",
- params={
- "page": page,
- "page_size": page_size,
- "search": search,
- },
+ f"v1/tag-keys/{jsonable_encoder(key)}",
+ method="DELETE",
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[Folder],
+ TagKeyDeleteResponse,
parse_obj_as(
- type_=typing.List[Folder], # type: ignore
+ type_=TagKeyDeleteResponse, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -5658,37 +7331,36 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def create_folder(
+ async def update_tag_key(
self,
+ key: str,
*,
- title: str,
description: typing.Optional[str] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[Folder]:
+ ) -> AsyncHttpResponse[TagKey]:
"""
- Create a new folder to organize workflows
+ Update the description for a tag key.
Parameters
----------
- title : str
- Folder title
+ key : str
+ Tag key to update
description : typing.Optional[str]
- Folder description
+ Free-form description (max 500 chars). Pass null to clear.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[Folder]
- Successfully created folder
+ AsyncHttpResponse[TagKey]
+ Successfully updated tag key
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/folders",
- method="POST",
+ f"v1/tag-keys/{jsonable_encoder(key)}",
+ method="PATCH",
json={
- "title": title,
"description": description,
},
headers={
@@ -5700,15 +7372,15 @@ class AsyncRawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Folder,
+ TagKey,
parse_obj_as(
- type_=Folder, # type: ignore
+ type_=TagKey, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
- if _response.status_code == 400:
- raise BadRequestError(
+ if _response.status_code == 404:
+ raise NotFoundError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -5734,51 +7406,43 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def get_folder(
- self, folder_id: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[Folder]:
+ async def list_tag_values(
+ self, *, key: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[typing.List[TagValue]]:
"""
- Get a specific folder by ID
+ List the palette color and current workflow usage count for each grouped tag (key, value) for the organization. The frontend joins these onto tags by (key, value); workflow_count is the number of non-deleted workflows carrying the label and powers the per-label usage and delete blast-radius warnings.
Parameters
----------
- folder_id : str
- Folder ID
+ key : typing.Optional[str]
+ Filter to values for a single tag key
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[Folder]
- Successfully retrieved folder
+ AsyncHttpResponse[typing.List[TagValue]]
+ Successfully retrieved tag values
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/folders/{jsonable_encoder(folder_id)}",
+ "v1/tag-values",
method="GET",
+ params={
+ "key": key,
+ },
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Folder,
+ typing.List[TagValue],
parse_obj_as(
- type_=Folder, # type: ignore
+ type_=typing.List[TagValue], # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
- if _response.status_code == 404:
- raise NotFoundError(
- headers=dict(_response.headers),
- body=typing.cast(
- typing.Optional[typing.Any],
- parse_obj_as(
- type_=typing.Optional[typing.Any], # type: ignore
- object_=_response.json(),
- ),
- ),
- )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -5795,42 +7459,33 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def update_folder(
- self,
- folder_id: str,
- *,
- title: typing.Optional[str] = OMIT,
- description: typing.Optional[str] = OMIT,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[Folder]:
+ async def delete_tag_value(
+ self, key: str, *, value: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[TagValueDeleteResponse]:
"""
- Update a folder's title or description
+ Soft-delete a grouped tag (key, value) and remove that label from every workflow carrying it (cascade). The value rides in the body so values containing '/' stay addressable. Returns how many workflows the label was removed from.
Parameters
----------
- folder_id : str
- Folder ID
-
- title : typing.Optional[str]
- Folder title
+ key : str
+ Tag key (group)
- description : typing.Optional[str]
- Folder description
+ value : str
+ Tag value (label) under the key to soft-delete.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[Folder]
- Successfully updated folder
+ AsyncHttpResponse[TagValueDeleteResponse]
+ Successfully deleted tag value
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/folders/{jsonable_encoder(folder_id)}",
- method="PUT",
+ f"v1/tag-values/{jsonable_encoder(key)}",
+ method="DELETE",
json={
- "title": title,
- "description": description,
+ "value": value,
},
headers={
"content-type": "application/json",
@@ -5841,9 +7496,9 @@ class AsyncRawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- Folder,
+ TagValueDeleteResponse,
parse_obj_as(
- type_=Folder, # type: ignore
+ type_=TagValueDeleteResponse, # type: ignore
object_=_response.json(),
),
)
@@ -5875,46 +7530,50 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def delete_folder(
- self,
- folder_id: str,
- *,
- delete_workflows: typing.Optional[bool] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[typing.Dict[str, typing.Optional[typing.Any]]]:
+ async def update_tag_value(
+ self, key: str, *, value: str, color: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[TagValue]:
"""
- Delete a folder. Optionally delete all workflows in the folder.
+ Recolor a grouped tag (key, value). The value is supplied in the body so values containing '/' stay addressable. The new color must be a palette name.
Parameters
----------
- folder_id : str
- Folder ID
+ key : str
+ Tag key (group)
- delete_workflows : typing.Optional[bool]
- If true, also delete all workflows in this folder
+ value : str
+ Tag value (label) under the key to recolor.
+
+ color : str
+ Palette color name to assign to this (key, value).
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[typing.Dict[str, typing.Optional[typing.Any]]]
- Successfully deleted folder
+ AsyncHttpResponse[TagValue]
+ Successfully recolored tag value
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/folders/{jsonable_encoder(folder_id)}",
- method="DELETE",
- params={
- "delete_workflows": delete_workflows,
+ f"v1/tag-values/{jsonable_encoder(key)}",
+ method="PATCH",
+ json={
+ "value": value,
+ "color": color,
+ },
+ headers={
+ "content-type": "application/json",
},
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.Dict[str, typing.Optional[typing.Any]],
+ TagValue,
parse_obj_as(
- type_=typing.Dict[str, typing.Optional[typing.Any]], # type: ignore
+ type_=TagValue, # type: ignore
object_=_response.json(),
),
)
@@ -5946,37 +7605,76 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def list_tag_keys(
- self, *, request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[typing.List[TagKey]]:
+ async def rename_tag_value(
+ self, key: str, *, value: str, new_value: str, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[TagValueRenameResponse]:
"""
- List all tag keys registered for the organization with their descriptions.
+ Rename a grouped tag (key, value) to (key, new_value). The cascade re-tags every workflow carrying the old label; the new label inherits the old color. Both values ride in the body so values containing '/' stay addressable. Rejects with 409 when the new value already exists for the key.
Parameters
----------
+ key : str
+ Tag key (group)
+
+ value : str
+ Current tag value (label) under the key to rename.
+
+ new_value : str
+ New tag value (label) to rename it to.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[typing.List[TagKey]]
- Successfully retrieved tag keys
+ AsyncHttpResponse[TagValueRenameResponse]
+ Successfully renamed tag value
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/tag-keys",
- method="GET",
+ f"v1/tag-values/{jsonable_encoder(key)}/rename",
+ method="PATCH",
+ json={
+ "value": value,
+ "new_value": new_value,
+ },
+ headers={
+ "content-type": "application/json",
+ },
request_options=request_options,
+ omit=OMIT,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- typing.List[TagKey],
+ TagValueRenameResponse,
parse_obj_as(
- type_=typing.List[TagKey], # type: ignore
+ type_=TagValueRenameResponse, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
+ if _response.status_code == 409:
+ raise ConflictError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -5993,42 +7691,48 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def delete_tag_key(
- self, key: str, *, request_options: typing.Optional[RequestOptions] = None
- ) -> AsyncHttpResponse[TagKeyDeleteResponse]:
+ async def batch_get_workflow_tags(
+ self,
+ *,
+ workflow_permanent_ids: typing.Optional[str] = None,
+ request_options: typing.Optional[RequestOptions] = None,
+ ) -> AsyncHttpResponse[WorkflowTagsBatchResponse]:
"""
- Delete a tag key from the organization registry and remove that tag from every workflow that currently has it (cascade). Returns how many workflows the tag was removed from.
+ Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
Parameters
----------
- key : str
- Tag key to delete
+ workflow_permanent_ids : typing.Optional[str]
+ Comma-separated workflow permanent IDs
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[TagKeyDeleteResponse]
- Successfully deleted tag key
+ AsyncHttpResponse[WorkflowTagsBatchResponse]
+ Successfully retrieved tags
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/tag-keys/{jsonable_encoder(key)}",
- method="DELETE",
+ "v1/workflow-tags",
+ method="GET",
+ params={
+ "workflow_permanent_ids": workflow_permanent_ids,
+ },
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TagKeyDeleteResponse,
+ WorkflowTagsBatchResponse,
parse_obj_as(
- type_=TagKeyDeleteResponse, # type: ignore
+ type_=WorkflowTagsBatchResponse, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
- if _response.status_code == 404:
- raise NotFoundError(
+ if _response.status_code == 400:
+ raise BadRequestError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -6054,37 +7758,33 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def update_tag_key(
+ async def batch_get_workflow_tags_post(
self,
- key: str,
*,
- description: typing.Optional[str] = OMIT,
+ workflow_permanent_ids: typing.Optional[typing.Sequence[str]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[TagKey]:
+ ) -> AsyncHttpResponse[WorkflowTagsBatchResponse]:
"""
- Update the description for a tag key.
+ Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
Parameters
----------
- key : str
- Tag key to update
-
- description : typing.Optional[str]
- Free-form description (max 500 chars). Pass null to clear.
+ workflow_permanent_ids : typing.Optional[typing.Sequence[str]]
+ Workflow permanent IDs to fetch tags for.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[TagKey]
- Successfully updated tag key
+ AsyncHttpResponse[WorkflowTagsBatchResponse]
+ Successfully retrieved tags
"""
_response = await self._client_wrapper.httpx_client.request(
- f"v1/tag-keys/{jsonable_encoder(key)}",
- method="PATCH",
+ "v1/workflow-tags",
+ method="POST",
json={
- "description": description,
+ "workflow_permanent_ids": workflow_permanent_ids,
},
headers={
"content-type": "application/json",
@@ -6095,15 +7795,15 @@ class AsyncRawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- TagKey,
+ WorkflowTagsBatchResponse,
parse_obj_as(
- type_=TagKey, # type: ignore
+ type_=WorkflowTagsBatchResponse, # type: ignore
object_=_response.json(),
),
)
return AsyncHttpResponse(response=_response, data=_data)
- if _response.status_code == 404:
- raise NotFoundError(
+ if _response.status_code == 400:
+ raise BadRequestError(
headers=dict(_response.headers),
body=typing.cast(
typing.Optional[typing.Any],
@@ -6129,42 +7829,39 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def batch_get_workflow_tags(
- self,
- *,
- workflow_permanent_ids: typing.Optional[str] = None,
- request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[WorkflowTagsBatchResponse]:
+ async def batch_get_run_tags(
+ self, *, workflow_run_ids: typing.Optional[str] = None, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[RunTagsBatchResponse]:
"""
- Batch fetch current tags for many workflows. Avoids N+1 on the workflows-list page.
+ Batch fetch current tags for many workflow runs. Avoids N+1 on run-list pages.
Parameters
----------
- workflow_permanent_ids : typing.Optional[str]
- Comma-separated workflow permanent IDs
+ workflow_run_ids : typing.Optional[str]
+ Comma-separated workflow run IDs
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[WorkflowTagsBatchResponse]
+ AsyncHttpResponse[RunTagsBatchResponse]
Successfully retrieved tags
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/workflow-tags",
+ "v1/run-tags",
method="GET",
params={
- "workflow_permanent_ids": workflow_permanent_ids,
+ "workflow_run_ids": workflow_run_ids,
},
request_options=request_options,
)
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- WorkflowTagsBatchResponse,
+ RunTagsBatchResponse,
parse_obj_as(
- type_=WorkflowTagsBatchResponse, # type: ignore
+ type_=RunTagsBatchResponse, # type: ignore
object_=_response.json(),
),
)
@@ -6196,33 +7893,33 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
- async def batch_get_workflow_tags_post(
+ async def batch_get_run_tags_post(
self,
*,
- workflow_permanent_ids: typing.Optional[typing.Sequence[str]] = OMIT,
+ workflow_run_ids: typing.Optional[typing.Sequence[str]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
- ) -> AsyncHttpResponse[WorkflowTagsBatchResponse]:
+ ) -> AsyncHttpResponse[RunTagsBatchResponse]:
"""
- Batch fetch current tags for many workflows (POST variant for id lists exceeding URL length).
+ Batch fetch current tags for many workflow runs (POST variant for id lists exceeding URL length).
Parameters
----------
- workflow_permanent_ids : typing.Optional[typing.Sequence[str]]
- Workflow permanent IDs to fetch tags for.
+ workflow_run_ids : typing.Optional[typing.Sequence[str]]
+ Workflow run IDs to fetch tags for.
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
Returns
-------
- AsyncHttpResponse[WorkflowTagsBatchResponse]
+ AsyncHttpResponse[RunTagsBatchResponse]
Successfully retrieved tags
"""
_response = await self._client_wrapper.httpx_client.request(
- "v1/workflow-tags",
+ "v1/run-tags",
method="POST",
json={
- "workflow_permanent_ids": workflow_permanent_ids,
+ "workflow_run_ids": workflow_run_ids,
},
headers={
"content-type": "application/json",
@@ -6233,9 +7930,9 @@ class AsyncRawSkyvern:
try:
if 200 <= _response.status_code < 300:
_data = typing.cast(
- WorkflowTagsBatchResponse,
+ RunTagsBatchResponse,
parse_obj_as(
- type_=WorkflowTagsBatchResponse, # type: ignore
+ type_=RunTagsBatchResponse, # type: ignore
object_=_response.json(),
),
)
@@ -6504,6 +8201,7 @@ class AsyncRawSkyvern:
page_size: typing.Optional[int] = None,
status: typing.Optional[typing.Union[RunStatus, typing.Sequence[RunStatus]]] = None,
search_key: typing.Optional[str] = None,
+ run_type: typing.Optional[typing.Union[RunType, typing.Sequence[RunType]]] = None,
request_options: typing.Optional[RequestOptions] = None,
) -> AsyncHttpResponse[typing.List[TaskRunListItem]]:
"""
@@ -6518,6 +8216,8 @@ class AsyncRawSkyvern:
search_key : typing.Optional[str]
Case-insensitive substring search (min 3 chars for trigram index).
+ run_type : typing.Optional[typing.Union[RunType, typing.Sequence[RunType]]]
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -6534,6 +8234,7 @@ class AsyncRawSkyvern:
"page_size": page_size,
"status": status,
"search_key": search_key,
+ "run_type": run_type,
},
request_options=request_options,
)
@@ -6623,6 +8324,7 @@ class AsyncRawSkyvern:
page_size: typing.Optional[int] = None,
include_deleted: typing.Optional[bool] = None,
search_key: typing.Optional[str] = None,
+ managed: typing.Optional[bool] = None,
request_options: typing.Optional[RequestOptions] = None,
) -> AsyncHttpResponse[typing.List[BrowserProfile]]:
"""
@@ -6640,6 +8342,9 @@ class AsyncRawSkyvern:
search_key : typing.Optional[str]
Case-insensitive substring search across: browser profile name and description. A profile is returned if either field matches.
+ managed : typing.Optional[bool]
+ Omit to return all profiles; false returns only user-created profiles; true returns only auto-managed profiles.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -6656,6 +8361,7 @@ class AsyncRawSkyvern:
"page_size": page_size,
"include_deleted": include_deleted,
"search_key": search_key,
+ "managed": managed,
},
request_options=request_options,
)
@@ -7079,6 +8785,7 @@ class AsyncRawSkyvern:
*,
timeout: typing.Optional[int] = OMIT,
proxy_location: typing.Optional[CreateBrowserSessionRequestProxyLocation] = OMIT,
+ proxy_session_id: typing.Optional[str] = OMIT,
extensions: typing.Optional[typing.Sequence[Extensions]] = OMIT,
browser_type: typing.Optional[PersistentBrowserType] = OMIT,
browser_profile_id: typing.Optional[str] = OMIT,
@@ -7130,6 +8837,9 @@ class AsyncRawSkyvern:
For self-hosted deployments, you can pass a custom proxy URL as a dict: {"url": "http://user:[email protected]:8080"}. This routes the browser through your own proxy server and takes precedence over any globally configured proxy pool.
Can also be a GeoTarget object for granular city/state targeting: {"country": "US", "subdivision": "CA", "city": "San Francisco"}, or a custom proxy URL dict for self-hosted deployments: {"url": "http://user:[email protected]:8080"}
+ proxy_session_id : typing.Optional[str]
+ Opaque Skyvern-managed proxy sticky-session id for pinned Residential ISP sessions.
+
extensions : typing.Optional[typing.Sequence[Extensions]]
A list of extensions to install in the browser session.
@@ -7158,6 +8868,7 @@ class AsyncRawSkyvern:
"proxy_location": convert_and_respect_annotation_metadata(
object_=proxy_location, annotation=CreateBrowserSessionRequestProxyLocation, direction="write"
),
+ "proxy_session_id": proxy_session_id,
"extensions": extensions,
"browser_type": browser_type,
"browser_profile_id": browser_profile_id,
@@ -7264,6 +8975,17 @@ class AsyncRawSkyvern:
),
),
)
+ if _response.status_code == 404:
+ raise NotFoundError(
+ headers=dict(_response.headers),
+ body=typing.cast(
+ typing.Optional[typing.Any],
+ parse_obj_as(
+ type_=typing.Optional[typing.Any], # type: ignore
+ object_=_response.json(),
+ ),
+ ),
+ )
if _response.status_code == 422:
raise UnprocessableEntityError(
headers=dict(_response.headers),
@@ -7904,6 +9626,222 @@ class AsyncRawSkyvern:
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text)
raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+ async def list_custom_llms(
+ self, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[CustomLlmListResponse]:
+ """
+ List the custom LLM configurations available to the current organization.
+
+ Parameters
+ ----------
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[CustomLlmListResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/custom-llms",
+ method="GET",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomLlmListResponse,
+ parse_obj_as(
+ type_=CustomLlmListResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def create_custom_llm(
+ self, *, config: CustomLlmConfig, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[CustomLlmResponse]:
+ """
+ Create a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ config : CustomLlmConfig
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[CustomLlmResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ "v1/custom-llms",
+ method="POST",
+ json={
+ "config": convert_and_respect_annotation_metadata(
+ object_=config, annotation=CustomLlmConfig, direction="write"
+ ),
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomLlmResponse,
+ parse_obj_as(
+ type_=CustomLlmResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def update_custom_llm(
+ self, custom_llm_id: str, *, config: CustomLlmConfig, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[CustomLlmResponse]:
+ """
+ Update a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ custom_llm_id : str
+ The custom LLM id.
+
+ config : CustomLlmConfig
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[CustomLlmResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"v1/custom-llms/{jsonable_encoder(custom_llm_id)}",
+ method="PUT",
+ json={
+ "config": convert_and_respect_annotation_metadata(
+ object_=config, annotation=CustomLlmConfig, direction="write"
+ ),
+ },
+ headers={
+ "content-type": "application/json",
+ },
+ request_options=request_options,
+ omit=OMIT,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ CustomLlmResponse,
+ parse_obj_as(
+ type_=CustomLlmResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
+ async def delete_custom_llm(
+ self, custom_llm_id: str, *, request_options: typing.Optional[RequestOptions] = None
+ ) -> AsyncHttpResponse[ClearOrganizationAuthTokenResponse]:
+ """
+ Delete a custom LLM configuration for the current organization.
+
+ Parameters
+ ----------
+ custom_llm_id : str
+ The custom LLM id.
+
+ request_options : typing.Optional[RequestOptions]
+ Request-specific configuration.
+
+ Returns
+ -------
+ AsyncHttpResponse[ClearOrganizationAuthTokenResponse]
+ Successful Response
+ """
+ _response = await self._client_wrapper.httpx_client.request(
+ f"v1/custom-llms/{jsonable_encoder(custom_llm_id)}",
+ method="DELETE",
+ request_options=request_options,
+ )
+ try:
+ if 200 <= _response.status_code < 300:
+ _data = typing.cast(
+ ClearOrganizationAuthTokenResponse,
+ parse_obj_as(
+ type_=ClearOrganizationAuthTokenResponse, # type: ignore
+ object_=_response.json(),
+ ),
+ )
+ return AsyncHttpResponse(response=_response, data=_data)
+ if _response.status_code == 422:
+ raise UnprocessableEntityError(
+ headers=dict(_response.headers),
+ body=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, headers=dict(_response.headers), body=_response.text)
+ raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json)
+
async def login(
self,
*,
@@ -8691,6 +10629,7 @@ class AsyncRawSkyvern:
*,
tags: typing.Optional[typing.Sequence[TagInput]] = OMIT,
tags_to_delete: typing.Optional[typing.Sequence[TagDeleteInput]] = OMIT,
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT,
request_options: typing.Optional[RequestOptions] = None,
) -> AsyncHttpResponse[TagsResponse]:
"""
@@ -8707,6 +10646,9 @@ class AsyncRawSkyvern:
tags_to_delete : typing.Optional[typing.Sequence[TagDeleteInput]]
Tags to soft-delete. List of {key?, value?} targets.
+ colors : typing.Optional[typing.Dict[str, typing.Optional[str]]]
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -8725,6 +10667,7 @@ class AsyncRawSkyvern:
"tags_to_delete": convert_and_respect_annotation_metadata(
object_=tags_to_delete, annotation=typing.Sequence[TagDeleteInput], direction="write"
),
+ "colors": colors,
},
headers={
"content-type": "application/json",
@@ -9111,6 +11054,8 @@ class AsyncRawSkyvern:
status: typing.Optional[typing.Union[WorkflowRunStatus, typing.Sequence[WorkflowRunStatus]]] = None,
search_key: typing.Optional[str] = None,
error_code: typing.Optional[str] = None,
+ created_at_start: typing.Optional[dt.datetime] = None,
+ created_at_end: typing.Optional[dt.datetime] = None,
request_options: typing.Optional[RequestOptions] = None,
) -> AsyncHttpResponse[typing.List[WorkflowRun]]:
"""
@@ -9145,6 +11090,12 @@ class AsyncRawSkyvern:
error_code : typing.Optional[str]
Exact-match filter on the error_code field inside each task's errors JSON array. A run matches if any of its tasks contains an error with a matching error_code. Error codes are user-defined strings set during workflow execution.
+ created_at_start : typing.Optional[dt.datetime]
+ Only include runs created at or after this UTC timestamp (ISO 8601).
+
+ created_at_end : typing.Optional[dt.datetime]
+ Only include runs created strictly before this UTC timestamp (ISO 8601).
+
request_options : typing.Optional[RequestOptions]
Request-specific configuration.
@@ -9162,6 +11113,8 @@ class AsyncRawSkyvern:
"status": status,
"search_key": search_key,
"error_code": error_code,
+ "created_at_start": serialize_datetime(created_at_start) if created_at_start is not None else None,
+ "created_at_end": serialize_datetime(created_at_end) if created_at_end is not None else None,
},
request_options=request_options,
)
diff --git a/skyvern/client/types/__init__.py b/skyvern/client/types/__init__.py
index ae34a4694..68752a4ab 100644
--- a/skyvern/client/types/__init__.py
+++ b/skyvern/client/types/__init__.py
@@ -57,6 +57,7 @@ if typing.TYPE_CHECKING:
from .browser_profile_proxy_location import BrowserProfileProxyLocation
from .browser_session_response import BrowserSessionResponse
from .bulk_cancel_runs_response import BulkCancelRunsResponse
+ from .clear_organization_auth_token_response import ClearOrganizationAuthTokenResponse
from .click_action import ClickAction
from .click_action_data import ClickActionData
from .click_context import ClickContext
@@ -75,6 +76,8 @@ if typing.TYPE_CHECKING:
CodeBlockParametersItem_Output,
CodeBlockParametersItem_Workflow,
)
+ from .code_block_step import CodeBlockStep
+ from .code_block_step_yaml import CodeBlockStepYaml
from .code_block_yaml import CodeBlockYaml
from .conditional_block import ConditionalBlock
from .conditional_block_yaml import ConditionalBlockYaml
@@ -105,12 +108,37 @@ if typing.TYPE_CHECKING:
from .credential_parameter_yaml import CredentialParameterYaml
from .credential_response import CredentialResponse
from .credential_response_credential import CredentialResponseCredential
+ from .credential_response_proxy_location import CredentialResponseProxyLocation
from .credential_type_output import CredentialTypeOutput
from .credential_vault_type import CredentialVaultType
+ from .credit_card_billing_address import CreditCardBillingAddress
from .credit_card_credential_response import CreditCardCredentialResponse
+ from .custom_llm import CustomLlm
+ from .custom_llm_config import CustomLlmConfig
+ from .custom_llm_list_response import CustomLlmListResponse
+ from .custom_llm_provider import CustomLlmProvider
+ from .custom_llm_response import CustomLlmResponse
from .delete_schedule_response import DeleteScheduleResponse
from .download_to_s3block import DownloadToS3Block
from .download_to_s3block_yaml import DownloadToS3BlockYaml
+ from .email_inbox_block import EmailInboxBlock
+ from .email_inbox_block_email_client import EmailInboxBlockEmailClient
+ from .email_inbox_block_parameters_item import (
+ EmailInboxBlockParametersItem,
+ EmailInboxBlockParametersItem_AwsSecret,
+ EmailInboxBlockParametersItem_AzureSecret,
+ EmailInboxBlockParametersItem_AzureVaultCredential,
+ EmailInboxBlockParametersItem_BitwardenCreditCardData,
+ EmailInboxBlockParametersItem_BitwardenLoginCredential,
+ EmailInboxBlockParametersItem_BitwardenSensitiveInformation,
+ EmailInboxBlockParametersItem_Context,
+ EmailInboxBlockParametersItem_Credential,
+ EmailInboxBlockParametersItem_Onepassword,
+ EmailInboxBlockParametersItem_Output,
+ EmailInboxBlockParametersItem_Workflow,
+ )
+ from .email_inbox_block_yaml import EmailInboxBlockYaml
+ from .email_inbox_block_yaml_email_client import EmailInboxBlockYamlEmailClient
from .extensions import Extensions
from .extract_action import ExtractAction
from .extract_action_data import ExtractActionData
@@ -168,6 +196,7 @@ if typing.TYPE_CHECKING:
ForLoopBlockLoopBlocksItem_Code,
ForLoopBlockLoopBlocksItem_Conditional,
ForLoopBlockLoopBlocksItem_DownloadToS3,
+ ForLoopBlockLoopBlocksItem_EmailInbox,
ForLoopBlockLoopBlocksItem_Extraction,
ForLoopBlockLoopBlocksItem_FileDownload,
ForLoopBlockLoopBlocksItem_FileUpload,
@@ -180,9 +209,11 @@ if typing.TYPE_CHECKING:
ForLoopBlockLoopBlocksItem_HumanInteraction,
ForLoopBlockLoopBlocksItem_Login,
ForLoopBlockLoopBlocksItem_Navigation,
+ ForLoopBlockLoopBlocksItem_PdfFill,
ForLoopBlockLoopBlocksItem_PdfParser,
ForLoopBlockLoopBlocksItem_PrintPage,
ForLoopBlockLoopBlocksItem_SendEmail,
+ ForLoopBlockLoopBlocksItem_SplitPdf,
ForLoopBlockLoopBlocksItem_Task,
ForLoopBlockLoopBlocksItem_TaskV2,
ForLoopBlockLoopBlocksItem_TextPrompt,
@@ -214,6 +245,7 @@ if typing.TYPE_CHECKING:
ForLoopBlockYamlLoopBlocksItem_Code,
ForLoopBlockYamlLoopBlocksItem_Conditional,
ForLoopBlockYamlLoopBlocksItem_DownloadToS3,
+ ForLoopBlockYamlLoopBlocksItem_EmailInbox,
ForLoopBlockYamlLoopBlocksItem_Extraction,
ForLoopBlockYamlLoopBlocksItem_FileDownload,
ForLoopBlockYamlLoopBlocksItem_FileUpload,
@@ -226,9 +258,11 @@ if typing.TYPE_CHECKING:
ForLoopBlockYamlLoopBlocksItem_HumanInteraction,
ForLoopBlockYamlLoopBlocksItem_Login,
ForLoopBlockYamlLoopBlocksItem_Navigation,
+ ForLoopBlockYamlLoopBlocksItem_PdfFill,
ForLoopBlockYamlLoopBlocksItem_PdfParser,
ForLoopBlockYamlLoopBlocksItem_PrintPage,
ForLoopBlockYamlLoopBlocksItem_SendEmail,
+ ForLoopBlockYamlLoopBlocksItem_SplitPdf,
ForLoopBlockYamlLoopBlocksItem_Task,
ForLoopBlockYamlLoopBlocksItem_TaskV2,
ForLoopBlockYamlLoopBlocksItem_TextPrompt,
@@ -366,6 +400,24 @@ if typing.TYPE_CHECKING:
from .output_parameter import OutputParameter
from .output_parameter_yaml import OutputParameterYaml
from .password_credential_response import PasswordCredentialResponse
+ from .pdf_fill_block import PdfFillBlock
+ from .pdf_fill_block_parameters_item import (
+ PdfFillBlockParametersItem,
+ PdfFillBlockParametersItem_AwsSecret,
+ PdfFillBlockParametersItem_AzureSecret,
+ PdfFillBlockParametersItem_AzureVaultCredential,
+ PdfFillBlockParametersItem_BitwardenCreditCardData,
+ PdfFillBlockParametersItem_BitwardenLoginCredential,
+ PdfFillBlockParametersItem_BitwardenSensitiveInformation,
+ PdfFillBlockParametersItem_Context,
+ PdfFillBlockParametersItem_Credential,
+ PdfFillBlockParametersItem_Onepassword,
+ PdfFillBlockParametersItem_Output,
+ PdfFillBlockParametersItem_Workflow,
+ )
+ from .pdf_fill_block_payload import PdfFillBlockPayload
+ from .pdf_fill_block_yaml import PdfFillBlockYaml
+ from .pdf_fill_block_yaml_payload import PdfFillBlockYamlPayload
from .pdf_format import PdfFormat
from .pdf_parser_block import PdfParserBlock
from .pdf_parser_block_yaml import PdfParserBlockYaml
@@ -405,6 +457,10 @@ if typing.TYPE_CHECKING:
)
from .run_sdk_action_response import RunSdkActionResponse
from .run_status import RunStatus
+ from .run_tag_history_response import RunTagHistoryResponse
+ from .run_tags_batch_response import RunTagsBatchResponse
+ from .run_tags_response import RunTagsResponse
+ from .run_type import RunType
from .run_webhook_replay_response import RunWebhookReplayResponse
from .script import Script
from .script_file_create import ScriptFileCreate
@@ -418,6 +474,23 @@ if typing.TYPE_CHECKING:
from .send_email_block_yaml import SendEmailBlockYaml
from .skyvern_forge_sdk_schemas_credentials_credential_type import SkyvernForgeSdkSchemasCredentialsCredentialType
from .skyvern_schemas_credential_type_credential_type import SkyvernSchemasCredentialTypeCredentialType
+ from .split_pdf_block import SplitPdfBlock
+ from .split_pdf_block_parameters_item import (
+ SplitPdfBlockParametersItem,
+ SplitPdfBlockParametersItem_AwsSecret,
+ SplitPdfBlockParametersItem_AzureSecret,
+ SplitPdfBlockParametersItem_AzureVaultCredential,
+ SplitPdfBlockParametersItem_BitwardenCreditCardData,
+ SplitPdfBlockParametersItem_BitwardenLoginCredential,
+ SplitPdfBlockParametersItem_BitwardenSensitiveInformation,
+ SplitPdfBlockParametersItem_Context,
+ SplitPdfBlockParametersItem_Credential,
+ SplitPdfBlockParametersItem_Onepassword,
+ SplitPdfBlockParametersItem_Output,
+ SplitPdfBlockParametersItem_Workflow,
+ )
+ from .split_pdf_block_yaml import SplitPdfBlockYaml
+ from .tag_apply_request import TagApplyRequest
from .tag_delete_input import TagDeleteInput
from .tag_history_item import TagHistoryItem
from .tag_history_response import TagHistoryResponse
@@ -426,6 +499,9 @@ if typing.TYPE_CHECKING:
from .tag_key import TagKey
from .tag_key_delete_response import TagKeyDeleteResponse
from .tag_response import TagResponse
+ from .tag_value import TagValue
+ from .tag_value_delete_response import TagValueDeleteResponse
+ from .tag_value_rename_response import TagValueRenameResponse
from .tags_response import TagsResponse
from .task_block import TaskBlock
from .task_block_data_schema import TaskBlockDataSchema
@@ -548,6 +624,7 @@ if typing.TYPE_CHECKING:
WhileLoopBlockLoopBlocksItem_Code,
WhileLoopBlockLoopBlocksItem_Conditional,
WhileLoopBlockLoopBlocksItem_DownloadToS3,
+ WhileLoopBlockLoopBlocksItem_EmailInbox,
WhileLoopBlockLoopBlocksItem_Extraction,
WhileLoopBlockLoopBlocksItem_FileDownload,
WhileLoopBlockLoopBlocksItem_FileUpload,
@@ -560,9 +637,11 @@ if typing.TYPE_CHECKING:
WhileLoopBlockLoopBlocksItem_HumanInteraction,
WhileLoopBlockLoopBlocksItem_Login,
WhileLoopBlockLoopBlocksItem_Navigation,
+ WhileLoopBlockLoopBlocksItem_PdfFill,
WhileLoopBlockLoopBlocksItem_PdfParser,
WhileLoopBlockLoopBlocksItem_PrintPage,
WhileLoopBlockLoopBlocksItem_SendEmail,
+ WhileLoopBlockLoopBlocksItem_SplitPdf,
WhileLoopBlockLoopBlocksItem_Task,
WhileLoopBlockLoopBlocksItem_TaskV2,
WhileLoopBlockLoopBlocksItem_TextPrompt,
@@ -579,6 +658,7 @@ if typing.TYPE_CHECKING:
WhileLoopBlockYamlLoopBlocksItem_Code,
WhileLoopBlockYamlLoopBlocksItem_Conditional,
WhileLoopBlockYamlLoopBlocksItem_DownloadToS3,
+ WhileLoopBlockYamlLoopBlocksItem_EmailInbox,
WhileLoopBlockYamlLoopBlocksItem_Extraction,
WhileLoopBlockYamlLoopBlocksItem_FileDownload,
WhileLoopBlockYamlLoopBlocksItem_FileUpload,
@@ -591,9 +671,11 @@ if typing.TYPE_CHECKING:
WhileLoopBlockYamlLoopBlocksItem_HumanInteraction,
WhileLoopBlockYamlLoopBlocksItem_Login,
WhileLoopBlockYamlLoopBlocksItem_Navigation,
+ WhileLoopBlockYamlLoopBlocksItem_PdfFill,
WhileLoopBlockYamlLoopBlocksItem_PdfParser,
WhileLoopBlockYamlLoopBlocksItem_PrintPage,
WhileLoopBlockYamlLoopBlocksItem_SendEmail,
+ WhileLoopBlockYamlLoopBlocksItem_SplitPdf,
WhileLoopBlockYamlLoopBlocksItem_Task,
WhileLoopBlockYamlLoopBlocksItem_TaskV2,
WhileLoopBlockYamlLoopBlocksItem_TextPrompt,
@@ -613,6 +695,7 @@ if typing.TYPE_CHECKING:
WorkflowDefinitionBlocksItem_Code,
WorkflowDefinitionBlocksItem_Conditional,
WorkflowDefinitionBlocksItem_DownloadToS3,
+ WorkflowDefinitionBlocksItem_EmailInbox,
WorkflowDefinitionBlocksItem_Extraction,
WorkflowDefinitionBlocksItem_FileDownload,
WorkflowDefinitionBlocksItem_FileUpload,
@@ -625,9 +708,11 @@ if typing.TYPE_CHECKING:
WorkflowDefinitionBlocksItem_HumanInteraction,
WorkflowDefinitionBlocksItem_Login,
WorkflowDefinitionBlocksItem_Navigation,
+ WorkflowDefinitionBlocksItem_PdfFill,
WorkflowDefinitionBlocksItem_PdfParser,
WorkflowDefinitionBlocksItem_PrintPage,
WorkflowDefinitionBlocksItem_SendEmail,
+ WorkflowDefinitionBlocksItem_SplitPdf,
WorkflowDefinitionBlocksItem_Task,
WorkflowDefinitionBlocksItem_TaskV2,
WorkflowDefinitionBlocksItem_TextPrompt,
@@ -658,6 +743,7 @@ if typing.TYPE_CHECKING:
WorkflowDefinitionYamlBlocksItem_Code,
WorkflowDefinitionYamlBlocksItem_Conditional,
WorkflowDefinitionYamlBlocksItem_DownloadToS3,
+ WorkflowDefinitionYamlBlocksItem_EmailInbox,
WorkflowDefinitionYamlBlocksItem_Extraction,
WorkflowDefinitionYamlBlocksItem_FileDownload,
WorkflowDefinitionYamlBlocksItem_FileUpload,
@@ -670,9 +756,11 @@ if typing.TYPE_CHECKING:
WorkflowDefinitionYamlBlocksItem_HumanInteraction,
WorkflowDefinitionYamlBlocksItem_Login,
WorkflowDefinitionYamlBlocksItem_Navigation,
+ WorkflowDefinitionYamlBlocksItem_PdfFill,
WorkflowDefinitionYamlBlocksItem_PdfParser,
WorkflowDefinitionYamlBlocksItem_PrintPage,
WorkflowDefinitionYamlBlocksItem_SendEmail,
+ WorkflowDefinitionYamlBlocksItem_SplitPdf,
WorkflowDefinitionYamlBlocksItem_Task,
WorkflowDefinitionYamlBlocksItem_TaskV2,
WorkflowDefinitionYamlBlocksItem_TextPrompt,
@@ -787,6 +875,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"BrowserProfileProxyLocation": ".browser_profile_proxy_location",
"BrowserSessionResponse": ".browser_session_response",
"BulkCancelRunsResponse": ".bulk_cancel_runs_response",
+ "ClearOrganizationAuthTokenResponse": ".clear_organization_auth_token_response",
"ClickAction": ".click_action",
"ClickActionData": ".click_action_data",
"ClickContext": ".click_context",
@@ -803,6 +892,8 @@ _dynamic_imports: typing.Dict[str, str] = {
"CodeBlockParametersItem_Onepassword": ".code_block_parameters_item",
"CodeBlockParametersItem_Output": ".code_block_parameters_item",
"CodeBlockParametersItem_Workflow": ".code_block_parameters_item",
+ "CodeBlockStep": ".code_block_step",
+ "CodeBlockStepYaml": ".code_block_step_yaml",
"CodeBlockYaml": ".code_block_yaml",
"ConditionalBlock": ".conditional_block",
"ConditionalBlockYaml": ".conditional_block_yaml",
@@ -831,12 +922,35 @@ _dynamic_imports: typing.Dict[str, str] = {
"CredentialParameterYaml": ".credential_parameter_yaml",
"CredentialResponse": ".credential_response",
"CredentialResponseCredential": ".credential_response_credential",
+ "CredentialResponseProxyLocation": ".credential_response_proxy_location",
"CredentialTypeOutput": ".credential_type_output",
"CredentialVaultType": ".credential_vault_type",
+ "CreditCardBillingAddress": ".credit_card_billing_address",
"CreditCardCredentialResponse": ".credit_card_credential_response",
+ "CustomLlm": ".custom_llm",
+ "CustomLlmConfig": ".custom_llm_config",
+ "CustomLlmListResponse": ".custom_llm_list_response",
+ "CustomLlmProvider": ".custom_llm_provider",
+ "CustomLlmResponse": ".custom_llm_response",
"DeleteScheduleResponse": ".delete_schedule_response",
"DownloadToS3Block": ".download_to_s3block",
"DownloadToS3BlockYaml": ".download_to_s3block_yaml",
+ "EmailInboxBlock": ".email_inbox_block",
+ "EmailInboxBlockEmailClient": ".email_inbox_block_email_client",
+ "EmailInboxBlockParametersItem": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_AwsSecret": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_AzureSecret": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_AzureVaultCredential": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_BitwardenCreditCardData": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_BitwardenLoginCredential": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_BitwardenSensitiveInformation": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_Context": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_Credential": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_Onepassword": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_Output": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockParametersItem_Workflow": ".email_inbox_block_parameters_item",
+ "EmailInboxBlockYaml": ".email_inbox_block_yaml",
+ "EmailInboxBlockYamlEmailClient": ".email_inbox_block_yaml_email_client",
"Extensions": ".extensions",
"ExtractAction": ".extract_action",
"ExtractActionData": ".extract_action_data",
@@ -889,6 +1003,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"ForLoopBlockLoopBlocksItem_Code": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_Conditional": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_DownloadToS3": ".for_loop_block_loop_blocks_item",
+ "ForLoopBlockLoopBlocksItem_EmailInbox": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_Extraction": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_FileDownload": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_FileUpload": ".for_loop_block_loop_blocks_item",
@@ -901,9 +1016,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"ForLoopBlockLoopBlocksItem_HumanInteraction": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_Login": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_Navigation": ".for_loop_block_loop_blocks_item",
+ "ForLoopBlockLoopBlocksItem_PdfFill": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_PdfParser": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_PrintPage": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_SendEmail": ".for_loop_block_loop_blocks_item",
+ "ForLoopBlockLoopBlocksItem_SplitPdf": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_Task": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_TaskV2": ".for_loop_block_loop_blocks_item",
"ForLoopBlockLoopBlocksItem_TextPrompt": ".for_loop_block_loop_blocks_item",
@@ -931,6 +1048,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"ForLoopBlockYamlLoopBlocksItem_Code": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_Conditional": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_DownloadToS3": ".for_loop_block_yaml_loop_blocks_item",
+ "ForLoopBlockYamlLoopBlocksItem_EmailInbox": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_Extraction": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_FileDownload": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_FileUpload": ".for_loop_block_yaml_loop_blocks_item",
@@ -943,9 +1061,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"ForLoopBlockYamlLoopBlocksItem_HumanInteraction": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_Login": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_Navigation": ".for_loop_block_yaml_loop_blocks_item",
+ "ForLoopBlockYamlLoopBlocksItem_PdfFill": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_PdfParser": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_PrintPage": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_SendEmail": ".for_loop_block_yaml_loop_blocks_item",
+ "ForLoopBlockYamlLoopBlocksItem_SplitPdf": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_Task": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_TaskV2": ".for_loop_block_yaml_loop_blocks_item",
"ForLoopBlockYamlLoopBlocksItem_TextPrompt": ".for_loop_block_yaml_loop_blocks_item",
@@ -1068,6 +1188,22 @@ _dynamic_imports: typing.Dict[str, str] = {
"OutputParameter": ".output_parameter",
"OutputParameterYaml": ".output_parameter_yaml",
"PasswordCredentialResponse": ".password_credential_response",
+ "PdfFillBlock": ".pdf_fill_block",
+ "PdfFillBlockParametersItem": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_AwsSecret": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_AzureSecret": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_AzureVaultCredential": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_BitwardenCreditCardData": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_BitwardenLoginCredential": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_BitwardenSensitiveInformation": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_Context": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_Credential": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_Onepassword": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_Output": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockParametersItem_Workflow": ".pdf_fill_block_parameters_item",
+ "PdfFillBlockPayload": ".pdf_fill_block_payload",
+ "PdfFillBlockYaml": ".pdf_fill_block_yaml",
+ "PdfFillBlockYamlPayload": ".pdf_fill_block_yaml_payload",
"PdfFormat": ".pdf_format",
"PdfParserBlock": ".pdf_parser_block",
"PdfParserBlockYaml": ".pdf_parser_block_yaml",
@@ -1103,6 +1239,10 @@ _dynamic_imports: typing.Dict[str, str] = {
"RunSdkActionRequestAction_Validate": ".run_sdk_action_request_action",
"RunSdkActionResponse": ".run_sdk_action_response",
"RunStatus": ".run_status",
+ "RunTagHistoryResponse": ".run_tag_history_response",
+ "RunTagsBatchResponse": ".run_tags_batch_response",
+ "RunTagsResponse": ".run_tags_response",
+ "RunType": ".run_type",
"RunWebhookReplayResponse": ".run_webhook_replay_response",
"Script": ".script",
"ScriptFileCreate": ".script_file_create",
@@ -1116,6 +1256,21 @@ _dynamic_imports: typing.Dict[str, str] = {
"SendEmailBlockYaml": ".send_email_block_yaml",
"SkyvernForgeSdkSchemasCredentialsCredentialType": ".skyvern_forge_sdk_schemas_credentials_credential_type",
"SkyvernSchemasCredentialTypeCredentialType": ".skyvern_schemas_credential_type_credential_type",
+ "SplitPdfBlock": ".split_pdf_block",
+ "SplitPdfBlockParametersItem": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_AwsSecret": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_AzureSecret": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_AzureVaultCredential": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_BitwardenCreditCardData": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_BitwardenLoginCredential": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_BitwardenSensitiveInformation": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_Context": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_Credential": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_Onepassword": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_Output": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockParametersItem_Workflow": ".split_pdf_block_parameters_item",
+ "SplitPdfBlockYaml": ".split_pdf_block_yaml",
+ "TagApplyRequest": ".tag_apply_request",
"TagDeleteInput": ".tag_delete_input",
"TagHistoryItem": ".tag_history_item",
"TagHistoryResponse": ".tag_history_response",
@@ -1124,6 +1279,9 @@ _dynamic_imports: typing.Dict[str, str] = {
"TagKey": ".tag_key",
"TagKeyDeleteResponse": ".tag_key_delete_response",
"TagResponse": ".tag_response",
+ "TagValue": ".tag_value",
+ "TagValueDeleteResponse": ".tag_value_delete_response",
+ "TagValueRenameResponse": ".tag_value_rename_response",
"TagsResponse": ".tags_response",
"TaskBlock": ".task_block",
"TaskBlockDataSchema": ".task_block_data_schema",
@@ -1233,6 +1391,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"WhileLoopBlockLoopBlocksItem_Code": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_Conditional": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_DownloadToS3": ".while_loop_block_loop_blocks_item",
+ "WhileLoopBlockLoopBlocksItem_EmailInbox": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_Extraction": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_FileDownload": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_FileUpload": ".while_loop_block_loop_blocks_item",
@@ -1245,9 +1404,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"WhileLoopBlockLoopBlocksItem_HumanInteraction": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_Login": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_Navigation": ".while_loop_block_loop_blocks_item",
+ "WhileLoopBlockLoopBlocksItem_PdfFill": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_PdfParser": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_PrintPage": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_SendEmail": ".while_loop_block_loop_blocks_item",
+ "WhileLoopBlockLoopBlocksItem_SplitPdf": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_Task": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_TaskV2": ".while_loop_block_loop_blocks_item",
"WhileLoopBlockLoopBlocksItem_TextPrompt": ".while_loop_block_loop_blocks_item",
@@ -1262,6 +1423,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"WhileLoopBlockYamlLoopBlocksItem_Code": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_Conditional": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_DownloadToS3": ".while_loop_block_yaml_loop_blocks_item",
+ "WhileLoopBlockYamlLoopBlocksItem_EmailInbox": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_Extraction": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_FileDownload": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_FileUpload": ".while_loop_block_yaml_loop_blocks_item",
@@ -1274,9 +1436,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"WhileLoopBlockYamlLoopBlocksItem_HumanInteraction": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_Login": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_Navigation": ".while_loop_block_yaml_loop_blocks_item",
+ "WhileLoopBlockYamlLoopBlocksItem_PdfFill": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_PdfParser": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_PrintPage": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_SendEmail": ".while_loop_block_yaml_loop_blocks_item",
+ "WhileLoopBlockYamlLoopBlocksItem_SplitPdf": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_Task": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_TaskV2": ".while_loop_block_yaml_loop_blocks_item",
"WhileLoopBlockYamlLoopBlocksItem_TextPrompt": ".while_loop_block_yaml_loop_blocks_item",
@@ -1294,6 +1458,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"WorkflowDefinitionBlocksItem_Code": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_Conditional": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_DownloadToS3": ".workflow_definition_blocks_item",
+ "WorkflowDefinitionBlocksItem_EmailInbox": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_Extraction": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_FileDownload": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_FileUpload": ".workflow_definition_blocks_item",
@@ -1306,9 +1471,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"WorkflowDefinitionBlocksItem_HumanInteraction": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_Login": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_Navigation": ".workflow_definition_blocks_item",
+ "WorkflowDefinitionBlocksItem_PdfFill": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_PdfParser": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_PrintPage": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_SendEmail": ".workflow_definition_blocks_item",
+ "WorkflowDefinitionBlocksItem_SplitPdf": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_Task": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_TaskV2": ".workflow_definition_blocks_item",
"WorkflowDefinitionBlocksItem_TextPrompt": ".workflow_definition_blocks_item",
@@ -1335,6 +1502,7 @@ _dynamic_imports: typing.Dict[str, str] = {
"WorkflowDefinitionYamlBlocksItem_Code": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_Conditional": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_DownloadToS3": ".workflow_definition_yaml_blocks_item",
+ "WorkflowDefinitionYamlBlocksItem_EmailInbox": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_Extraction": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_FileDownload": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_FileUpload": ".workflow_definition_yaml_blocks_item",
@@ -1347,9 +1515,11 @@ _dynamic_imports: typing.Dict[str, str] = {
"WorkflowDefinitionYamlBlocksItem_HumanInteraction": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_Login": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_Navigation": ".workflow_definition_yaml_blocks_item",
+ "WorkflowDefinitionYamlBlocksItem_PdfFill": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_PdfParser": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_PrintPage": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_SendEmail": ".workflow_definition_yaml_blocks_item",
+ "WorkflowDefinitionYamlBlocksItem_SplitPdf": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_Task": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_TaskV2": ".workflow_definition_yaml_blocks_item",
"WorkflowDefinitionYamlBlocksItem_TextPrompt": ".workflow_definition_yaml_blocks_item",
@@ -1483,6 +1653,7 @@ __all__ = [
"BrowserProfileProxyLocation",
"BrowserSessionResponse",
"BulkCancelRunsResponse",
+ "ClearOrganizationAuthTokenResponse",
"ClickAction",
"ClickActionData",
"ClickContext",
@@ -1499,6 +1670,8 @@ __all__ = [
"CodeBlockParametersItem_Onepassword",
"CodeBlockParametersItem_Output",
"CodeBlockParametersItem_Workflow",
+ "CodeBlockStep",
+ "CodeBlockStepYaml",
"CodeBlockYaml",
"ConditionalBlock",
"ConditionalBlockYaml",
@@ -1527,12 +1700,35 @@ __all__ = [
"CredentialParameterYaml",
"CredentialResponse",
"CredentialResponseCredential",
+ "CredentialResponseProxyLocation",
"CredentialTypeOutput",
"CredentialVaultType",
+ "CreditCardBillingAddress",
"CreditCardCredentialResponse",
+ "CustomLlm",
+ "CustomLlmConfig",
+ "CustomLlmListResponse",
+ "CustomLlmProvider",
+ "CustomLlmResponse",
"DeleteScheduleResponse",
"DownloadToS3Block",
"DownloadToS3BlockYaml",
+ "EmailInboxBlock",
+ "EmailInboxBlockEmailClient",
+ "EmailInboxBlockParametersItem",
+ "EmailInboxBlockParametersItem_AwsSecret",
+ "EmailInboxBlockParametersItem_AzureSecret",
+ "EmailInboxBlockParametersItem_AzureVaultCredential",
+ "EmailInboxBlockParametersItem_BitwardenCreditCardData",
+ "EmailInboxBlockParametersItem_BitwardenLoginCredential",
+ "EmailInboxBlockParametersItem_BitwardenSensitiveInformation",
+ "EmailInboxBlockParametersItem_Context",
+ "EmailInboxBlockParametersItem_Credential",
+ "EmailInboxBlockParametersItem_Onepassword",
+ "EmailInboxBlockParametersItem_Output",
+ "EmailInboxBlockParametersItem_Workflow",
+ "EmailInboxBlockYaml",
+ "EmailInboxBlockYamlEmailClient",
"Extensions",
"ExtractAction",
"ExtractActionData",
@@ -1585,6 +1781,7 @@ __all__ = [
"ForLoopBlockLoopBlocksItem_Code",
"ForLoopBlockLoopBlocksItem_Conditional",
"ForLoopBlockLoopBlocksItem_DownloadToS3",
+ "ForLoopBlockLoopBlocksItem_EmailInbox",
"ForLoopBlockLoopBlocksItem_Extraction",
"ForLoopBlockLoopBlocksItem_FileDownload",
"ForLoopBlockLoopBlocksItem_FileUpload",
@@ -1597,9 +1794,11 @@ __all__ = [
"ForLoopBlockLoopBlocksItem_HumanInteraction",
"ForLoopBlockLoopBlocksItem_Login",
"ForLoopBlockLoopBlocksItem_Navigation",
+ "ForLoopBlockLoopBlocksItem_PdfFill",
"ForLoopBlockLoopBlocksItem_PdfParser",
"ForLoopBlockLoopBlocksItem_PrintPage",
"ForLoopBlockLoopBlocksItem_SendEmail",
+ "ForLoopBlockLoopBlocksItem_SplitPdf",
"ForLoopBlockLoopBlocksItem_Task",
"ForLoopBlockLoopBlocksItem_TaskV2",
"ForLoopBlockLoopBlocksItem_TextPrompt",
@@ -1627,6 +1826,7 @@ __all__ = [
"ForLoopBlockYamlLoopBlocksItem_Code",
"ForLoopBlockYamlLoopBlocksItem_Conditional",
"ForLoopBlockYamlLoopBlocksItem_DownloadToS3",
+ "ForLoopBlockYamlLoopBlocksItem_EmailInbox",
"ForLoopBlockYamlLoopBlocksItem_Extraction",
"ForLoopBlockYamlLoopBlocksItem_FileDownload",
"ForLoopBlockYamlLoopBlocksItem_FileUpload",
@@ -1639,9 +1839,11 @@ __all__ = [
"ForLoopBlockYamlLoopBlocksItem_HumanInteraction",
"ForLoopBlockYamlLoopBlocksItem_Login",
"ForLoopBlockYamlLoopBlocksItem_Navigation",
+ "ForLoopBlockYamlLoopBlocksItem_PdfFill",
"ForLoopBlockYamlLoopBlocksItem_PdfParser",
"ForLoopBlockYamlLoopBlocksItem_PrintPage",
"ForLoopBlockYamlLoopBlocksItem_SendEmail",
+ "ForLoopBlockYamlLoopBlocksItem_SplitPdf",
"ForLoopBlockYamlLoopBlocksItem_Task",
"ForLoopBlockYamlLoopBlocksItem_TaskV2",
"ForLoopBlockYamlLoopBlocksItem_TextPrompt",
@@ -1764,6 +1966,22 @@ __all__ = [
"OutputParameter",
"OutputParameterYaml",
"PasswordCredentialResponse",
+ "PdfFillBlock",
+ "PdfFillBlockParametersItem",
+ "PdfFillBlockParametersItem_AwsSecret",
+ "PdfFillBlockParametersItem_AzureSecret",
+ "PdfFillBlockParametersItem_AzureVaultCredential",
+ "PdfFillBlockParametersItem_BitwardenCreditCardData",
+ "PdfFillBlockParametersItem_BitwardenLoginCredential",
+ "PdfFillBlockParametersItem_BitwardenSensitiveInformation",
+ "PdfFillBlockParametersItem_Context",
+ "PdfFillBlockParametersItem_Credential",
+ "PdfFillBlockParametersItem_Onepassword",
+ "PdfFillBlockParametersItem_Output",
+ "PdfFillBlockParametersItem_Workflow",
+ "PdfFillBlockPayload",
+ "PdfFillBlockYaml",
+ "PdfFillBlockYamlPayload",
"PdfFormat",
"PdfParserBlock",
"PdfParserBlockYaml",
@@ -1799,6 +2017,10 @@ __all__ = [
"RunSdkActionRequestAction_Validate",
"RunSdkActionResponse",
"RunStatus",
+ "RunTagHistoryResponse",
+ "RunTagsBatchResponse",
+ "RunTagsResponse",
+ "RunType",
"RunWebhookReplayResponse",
"Script",
"ScriptFileCreate",
@@ -1812,6 +2034,21 @@ __all__ = [
"SendEmailBlockYaml",
"SkyvernForgeSdkSchemasCredentialsCredentialType",
"SkyvernSchemasCredentialTypeCredentialType",
+ "SplitPdfBlock",
+ "SplitPdfBlockParametersItem",
+ "SplitPdfBlockParametersItem_AwsSecret",
+ "SplitPdfBlockParametersItem_AzureSecret",
+ "SplitPdfBlockParametersItem_AzureVaultCredential",
+ "SplitPdfBlockParametersItem_BitwardenCreditCardData",
+ "SplitPdfBlockParametersItem_BitwardenLoginCredential",
+ "SplitPdfBlockParametersItem_BitwardenSensitiveInformation",
+ "SplitPdfBlockParametersItem_Context",
+ "SplitPdfBlockParametersItem_Credential",
+ "SplitPdfBlockParametersItem_Onepassword",
+ "SplitPdfBlockParametersItem_Output",
+ "SplitPdfBlockParametersItem_Workflow",
+ "SplitPdfBlockYaml",
+ "TagApplyRequest",
"TagDeleteInput",
"TagHistoryItem",
"TagHistoryResponse",
@@ -1820,6 +2057,9 @@ __all__ = [
"TagKey",
"TagKeyDeleteResponse",
"TagResponse",
+ "TagValue",
+ "TagValueDeleteResponse",
+ "TagValueRenameResponse",
"TagsResponse",
"TaskBlock",
"TaskBlockDataSchema",
@@ -1929,6 +2169,7 @@ __all__ = [
"WhileLoopBlockLoopBlocksItem_Code",
"WhileLoopBlockLoopBlocksItem_Conditional",
"WhileLoopBlockLoopBlocksItem_DownloadToS3",
+ "WhileLoopBlockLoopBlocksItem_EmailInbox",
"WhileLoopBlockLoopBlocksItem_Extraction",
"WhileLoopBlockLoopBlocksItem_FileDownload",
"WhileLoopBlockLoopBlocksItem_FileUpload",
@@ -1941,9 +2182,11 @@ __all__ = [
"WhileLoopBlockLoopBlocksItem_HumanInteraction",
"WhileLoopBlockLoopBlocksItem_Login",
"WhileLoopBlockLoopBlocksItem_Navigation",
+ "WhileLoopBlockLoopBlocksItem_PdfFill",
"WhileLoopBlockLoopBlocksItem_PdfParser",
"WhileLoopBlockLoopBlocksItem_PrintPage",
"WhileLoopBlockLoopBlocksItem_SendEmail",
+ "WhileLoopBlockLoopBlocksItem_SplitPdf",
"WhileLoopBlockLoopBlocksItem_Task",
"WhileLoopBlockLoopBlocksItem_TaskV2",
"WhileLoopBlockLoopBlocksItem_TextPrompt",
@@ -1958,6 +2201,7 @@ __all__ = [
"WhileLoopBlockYamlLoopBlocksItem_Code",
"WhileLoopBlockYamlLoopBlocksItem_Conditional",
"WhileLoopBlockYamlLoopBlocksItem_DownloadToS3",
+ "WhileLoopBlockYamlLoopBlocksItem_EmailInbox",
"WhileLoopBlockYamlLoopBlocksItem_Extraction",
"WhileLoopBlockYamlLoopBlocksItem_FileDownload",
"WhileLoopBlockYamlLoopBlocksItem_FileUpload",
@@ -1970,9 +2214,11 @@ __all__ = [
"WhileLoopBlockYamlLoopBlocksItem_HumanInteraction",
"WhileLoopBlockYamlLoopBlocksItem_Login",
"WhileLoopBlockYamlLoopBlocksItem_Navigation",
+ "WhileLoopBlockYamlLoopBlocksItem_PdfFill",
"WhileLoopBlockYamlLoopBlocksItem_PdfParser",
"WhileLoopBlockYamlLoopBlocksItem_PrintPage",
"WhileLoopBlockYamlLoopBlocksItem_SendEmail",
+ "WhileLoopBlockYamlLoopBlocksItem_SplitPdf",
"WhileLoopBlockYamlLoopBlocksItem_Task",
"WhileLoopBlockYamlLoopBlocksItem_TaskV2",
"WhileLoopBlockYamlLoopBlocksItem_TextPrompt",
@@ -1990,6 +2236,7 @@ __all__ = [
"WorkflowDefinitionBlocksItem_Code",
"WorkflowDefinitionBlocksItem_Conditional",
"WorkflowDefinitionBlocksItem_DownloadToS3",
+ "WorkflowDefinitionBlocksItem_EmailInbox",
"WorkflowDefinitionBlocksItem_Extraction",
"WorkflowDefinitionBlocksItem_FileDownload",
"WorkflowDefinitionBlocksItem_FileUpload",
@@ -2002,9 +2249,11 @@ __all__ = [
"WorkflowDefinitionBlocksItem_HumanInteraction",
"WorkflowDefinitionBlocksItem_Login",
"WorkflowDefinitionBlocksItem_Navigation",
+ "WorkflowDefinitionBlocksItem_PdfFill",
"WorkflowDefinitionBlocksItem_PdfParser",
"WorkflowDefinitionBlocksItem_PrintPage",
"WorkflowDefinitionBlocksItem_SendEmail",
+ "WorkflowDefinitionBlocksItem_SplitPdf",
"WorkflowDefinitionBlocksItem_Task",
"WorkflowDefinitionBlocksItem_TaskV2",
"WorkflowDefinitionBlocksItem_TextPrompt",
@@ -2031,6 +2280,7 @@ __all__ = [
"WorkflowDefinitionYamlBlocksItem_Code",
"WorkflowDefinitionYamlBlocksItem_Conditional",
"WorkflowDefinitionYamlBlocksItem_DownloadToS3",
+ "WorkflowDefinitionYamlBlocksItem_EmailInbox",
"WorkflowDefinitionYamlBlocksItem_Extraction",
"WorkflowDefinitionYamlBlocksItem_FileDownload",
"WorkflowDefinitionYamlBlocksItem_FileUpload",
@@ -2043,9 +2293,11 @@ __all__ = [
"WorkflowDefinitionYamlBlocksItem_HumanInteraction",
"WorkflowDefinitionYamlBlocksItem_Login",
"WorkflowDefinitionYamlBlocksItem_Navigation",
+ "WorkflowDefinitionYamlBlocksItem_PdfFill",
"WorkflowDefinitionYamlBlocksItem_PdfParser",
"WorkflowDefinitionYamlBlocksItem_PrintPage",
"WorkflowDefinitionYamlBlocksItem_SendEmail",
+ "WorkflowDefinitionYamlBlocksItem_SplitPdf",
"WorkflowDefinitionYamlBlocksItem_Task",
"WorkflowDefinitionYamlBlocksItem_TaskV2",
"WorkflowDefinitionYamlBlocksItem_TextPrompt",
diff --git a/skyvern/client/types/action_block_parameters_item.py b/skyvern/client/types/action_block_parameters_item.py
index d2662830e..3009ac670 100644
--- a/skyvern/client/types/action_block_parameters_item.py
+++ b/skyvern/client/types/action_block_parameters_item.py
@@ -183,6 +183,8 @@ class ActionBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/block_type.py b/skyvern/client/types/block_type.py
index 8aacc37a1..aeb0d83c5 100644
--- a/skyvern/client/types/block_type.py
+++ b/skyvern/client/types/block_type.py
@@ -31,6 +31,9 @@ BlockType = typing.Union[
"workflow_trigger",
"google_sheets_read",
"google_sheets_write",
+ "pdf_fill",
+ "split_pdf",
+ "email_inbox",
],
typing.Any,
]
diff --git a/skyvern/client/types/clear_organization_auth_token_response.py b/skyvern/client/types/clear_organization_auth_token_response.py
new file mode 100644
index 000000000..2d37d1eeb
--- /dev/null
+++ b/skyvern/client/types/clear_organization_auth_token_response.py
@@ -0,0 +1,26 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class ClearOrganizationAuthTokenResponse(UniversalBaseModel):
+ """
+ Response model for clearing an organization auth token.
+ """
+
+ success: bool = pydantic.Field()
+ """
+ Whether the token was cleared successfully
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/code_block.py b/skyvern/client/types/code_block.py
index ca9857bb6..7c1294d0b 100644
--- a/skyvern/client/types/code_block.py
+++ b/skyvern/client/types/code_block.py
@@ -7,6 +7,7 @@ import typing
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs
from .code_block_parameters_item import CodeBlockParametersItem
+from .code_block_step import CodeBlockStep
from .output_parameter import OutputParameter
@@ -29,6 +30,8 @@ class CodeBlock(UniversalBaseModel):
next_loop_on_failure: typing.Optional[bool] = None
code: str
parameters: typing.Optional[typing.List[CodeBlockParametersItem]] = None
+ prompt: typing.Optional[str] = None
+ steps: typing.Optional[typing.List[CodeBlockStep]] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/code_block_parameters_item.py b/skyvern/client/types/code_block_parameters_item.py
index 9124c170b..56f97a9f5 100644
--- a/skyvern/client/types/code_block_parameters_item.py
+++ b/skyvern/client/types/code_block_parameters_item.py
@@ -183,6 +183,8 @@ class CodeBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/code_block_step.py b/skyvern/client/types/code_block_step.py
new file mode 100644
index 000000000..43bd300b2
--- /dev/null
+++ b/skyvern/client/types/code_block_step.py
@@ -0,0 +1,24 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .action_type import ActionType
+
+
+class CodeBlockStep(UniversalBaseModel):
+ title: typing.Optional[str] = None
+ description: typing.Optional[str] = None
+ action_type: typing.Optional[ActionType] = None
+ line_start: typing.Optional[int] = None
+ line_end: typing.Optional[int] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/code_block_step_yaml.py b/skyvern/client/types/code_block_step_yaml.py
new file mode 100644
index 000000000..cfb742c29
--- /dev/null
+++ b/skyvern/client/types/code_block_step_yaml.py
@@ -0,0 +1,23 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class CodeBlockStepYaml(UniversalBaseModel):
+ title: typing.Optional[str] = None
+ description: typing.Optional[str] = None
+ action_type: typing.Optional[str] = None
+ line_start: typing.Optional[int] = None
+ line_end: typing.Optional[int] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/code_block_yaml.py b/skyvern/client/types/code_block_yaml.py
index 0cea41310..b6d7f2f52 100644
--- a/skyvern/client/types/code_block_yaml.py
+++ b/skyvern/client/types/code_block_yaml.py
@@ -4,6 +4,7 @@ import typing
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .code_block_step_yaml import CodeBlockStepYaml
class CodeBlockYaml(UniversalBaseModel):
@@ -23,6 +24,8 @@ class CodeBlockYaml(UniversalBaseModel):
next_loop_on_failure: typing.Optional[bool] = None
code: str
parameter_keys: typing.Optional[typing.List[str]] = None
+ prompt: typing.Optional[str] = None
+ steps: typing.Optional[typing.List[CodeBlockStepYaml]] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/context_parameter_source.py b/skyvern/client/types/context_parameter_source.py
index 3240a6b82..bf629f7d1 100644
--- a/skyvern/client/types/context_parameter_source.py
+++ b/skyvern/client/types/context_parameter_source.py
@@ -246,6 +246,8 @@ class ContextParameterSource_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/credential_parameter.py b/skyvern/client/types/credential_parameter.py
index 6d4705bdf..e06bb2d75 100644
--- a/skyvern/client/types/credential_parameter.py
+++ b/skyvern/client/types/credential_parameter.py
@@ -13,6 +13,8 @@ class CredentialParameter(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/credential_parameter_yaml.py b/skyvern/client/types/credential_parameter_yaml.py
index aa8a22e10..bc5ca5ecf 100644
--- a/skyvern/client/types/credential_parameter_yaml.py
+++ b/skyvern/client/types/credential_parameter_yaml.py
@@ -10,6 +10,8 @@ class CredentialParameterYaml(UniversalBaseModel):
key: str
description: typing.Optional[str] = None
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/credential_response.py b/skyvern/client/types/credential_response.py
index ceeb22370..6e534b482 100644
--- a/skyvern/client/types/credential_response.py
+++ b/skyvern/client/types/credential_response.py
@@ -5,6 +5,7 @@ import typing
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .credential_response_credential import CredentialResponseCredential
+from .credential_response_proxy_location import CredentialResponseProxyLocation
from .credential_type_output import CredentialTypeOutput
from .credential_vault_type import CredentialVaultType
@@ -64,6 +65,16 @@ class CredentialResponse(UniversalBaseModel):
ID of the credential folder this credential belongs to, if any
"""
+ proxy_location: typing.Optional[CredentialResponseProxyLocation] = pydantic.Field(default=None)
+ """
+ Optional proxy location used for the credential's pinned proxy identity.
+ """
+
+ proxy_session_id: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Opaque Skyvern-managed proxy sticky-session id.
+ """
+
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
else:
diff --git a/skyvern/client/types/credential_response_proxy_location.py b/skyvern/client/types/credential_response_proxy_location.py
new file mode 100644
index 000000000..8856473ba
--- /dev/null
+++ b/skyvern/client/types/credential_response_proxy_location.py
@@ -0,0 +1,8 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+from .geo_target import GeoTarget
+from .proxy_location import ProxyLocation
+
+CredentialResponseProxyLocation = typing.Union[ProxyLocation, GeoTarget, typing.Dict[str, typing.Optional[typing.Any]]]
diff --git a/skyvern/client/types/credit_card_billing_address.py b/skyvern/client/types/credit_card_billing_address.py
new file mode 100644
index 000000000..0e10b245e
--- /dev/null
+++ b/skyvern/client/types/credit_card_billing_address.py
@@ -0,0 +1,61 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class CreditCardBillingAddress(UniversalBaseModel):
+ """
+ Optional billing address fields associated with a credit card credential.
+ """
+
+ line1: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Billing address line 1
+ """
+
+ line2: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Billing address line 2
+ """
+
+ city: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Billing city
+ """
+
+ state: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Billing state or region
+ """
+
+ state_code: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Billing state or region code
+ """
+
+ postal_code: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Billing postal code
+ """
+
+ country: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Billing country
+ """
+
+ country_code: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ ISO 3166-1 alpha-2 billing country code
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/credit_card_credential_response.py b/skyvern/client/types/credit_card_credential_response.py
index 33c487039..3b812074b 100644
--- a/skyvern/client/types/credit_card_credential_response.py
+++ b/skyvern/client/types/credit_card_credential_response.py
@@ -10,7 +10,8 @@ class CreditCardCredentialResponse(UniversalBaseModel):
"""
Response model for credit card credentials — non-sensitive fields only.
- SECURITY: Must NEVER include full card number, CVV, expiration date, or card holder name.
+ SECURITY: Must NEVER include full card number, CVV, expiration date, card holder name,
+ billing fields, or metadata.
"""
last_four: str = pydantic.Field()
diff --git a/skyvern/client/types/custom_llm.py b/skyvern/client/types/custom_llm.py
new file mode 100644
index 000000000..02623127d
--- /dev/null
+++ b/skyvern/client/types/custom_llm.py
@@ -0,0 +1,25 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .custom_llm_config import CustomLlmConfig
+
+
+class CustomLlm(UniversalBaseModel):
+ id: str
+ organization_id: str
+ config: CustomLlmConfig
+ created_at: str
+ modified_at: str
+ valid: bool
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/custom_llm_config.py b/skyvern/client/types/custom_llm_config.py
new file mode 100644
index 000000000..b6fe4ad14
--- /dev/null
+++ b/skyvern/client/types/custom_llm_config.py
@@ -0,0 +1,30 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .custom_llm_provider import CustomLlmProvider
+
+
+class CustomLlmConfig(UniversalBaseModel):
+ display_name: str
+ provider: CustomLlmProvider
+ model_name: str
+ api_base: typing.Optional[str] = None
+ api_key: typing.Optional[str] = None
+ api_version: typing.Optional[str] = None
+ supports_vision: typing.Optional[bool] = None
+ add_assistant_prefix: typing.Optional[bool] = None
+ max_completion_tokens: typing.Optional[int] = None
+ temperature: typing.Optional[float] = None
+ reasoning_effort: typing.Optional[str] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/custom_llm_list_response.py b/skyvern/client/types/custom_llm_list_response.py
new file mode 100644
index 000000000..f634764e0
--- /dev/null
+++ b/skyvern/client/types/custom_llm_list_response.py
@@ -0,0 +1,20 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .custom_llm import CustomLlm
+
+
+class CustomLlmListResponse(UniversalBaseModel):
+ custom_llms: typing.List[CustomLlm]
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/custom_llm_provider.py b/skyvern/client/types/custom_llm_provider.py
new file mode 100644
index 000000000..a87d7fb3f
--- /dev/null
+++ b/skyvern/client/types/custom_llm_provider.py
@@ -0,0 +1,5 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+CustomLlmProvider = typing.Union[typing.Literal["openai_compatible", "ollama", "openrouter"], typing.Any]
diff --git a/skyvern/client/types/custom_llm_response.py b/skyvern/client/types/custom_llm_response.py
new file mode 100644
index 000000000..91bd9cf78
--- /dev/null
+++ b/skyvern/client/types/custom_llm_response.py
@@ -0,0 +1,20 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .custom_llm import CustomLlm
+
+
+class CustomLlmResponse(UniversalBaseModel):
+ custom_llm: CustomLlm
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/email_inbox_block.py b/skyvern/client/types/email_inbox_block.py
new file mode 100644
index 000000000..5e301ae5e
--- /dev/null
+++ b/skyvern/client/types/email_inbox_block.py
@@ -0,0 +1,54 @@
+# This file was auto-generated by Fern from our API Definition.
+
+from __future__ import annotations
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs
+from .email_inbox_block_email_client import EmailInboxBlockEmailClient
+from .email_inbox_block_parameters_item import EmailInboxBlockParametersItem
+from .output_parameter import OutputParameter
+
+
+class EmailInboxBlock(UniversalBaseModel):
+ label: str = pydantic.Field()
+ """
+ Author-facing identifier for a block; unique within a workflow.
+ """
+
+ next_block_label: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional pointer to the next block label when constructing a DAG. Defaults to sequential order when omitted.
+ """
+
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ email_client: EmailInboxBlockEmailClient
+ credential_id: typing.Optional[str] = None
+ folder: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
+ sender: typing.Optional[str] = None
+ subject: typing.Optional[str] = None
+ newer_than_days: typing.Optional[int] = None
+ max_results: typing.Optional[int] = None
+ include_body: typing.Optional[bool] = None
+ parameters: typing.Optional[typing.List[EmailInboxBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+from .context_parameter import ContextParameter # noqa: E402, F401, I001
+
+update_forward_refs(EmailInboxBlock)
diff --git a/skyvern/client/types/email_inbox_block_email_client.py b/skyvern/client/types/email_inbox_block_email_client.py
new file mode 100644
index 000000000..01b84354a
--- /dev/null
+++ b/skyvern/client/types/email_inbox_block_email_client.py
@@ -0,0 +1,5 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+EmailInboxBlockEmailClient = typing.Union[typing.Literal["gmail", "outlook"], typing.Any]
diff --git a/skyvern/client/types/email_inbox_block_parameters_item.py b/skyvern/client/types/email_inbox_block_parameters_item.py
new file mode 100644
index 000000000..0ff3c324b
--- /dev/null
+++ b/skyvern/client/types/email_inbox_block_parameters_item.py
@@ -0,0 +1,279 @@
+# This file was auto-generated by Fern from our API Definition.
+
+from __future__ import annotations
+
+import datetime as dt
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs
+from .context_parameter_value import ContextParameterValue
+from .workflow_parameter_default_value import WorkflowParameterDefaultValue
+from .workflow_parameter_type import WorkflowParameterType
+
+
+class EmailInboxBlockParametersItem_AwsSecret(UniversalBaseModel):
+ parameter_type: typing.Literal["aws_secret"] = "aws_secret"
+ key: str
+ description: typing.Optional[str] = None
+ aws_secret_parameter_id: str
+ workflow_id: str
+ aws_key: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_AzureSecret(UniversalBaseModel):
+ parameter_type: typing.Literal["azure_secret"] = "azure_secret"
+ key: str
+ description: typing.Optional[str] = None
+ azure_secret_parameter_id: str
+ workflow_id: str
+ azure_key: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_AzureVaultCredential(UniversalBaseModel):
+ parameter_type: typing.Literal["azure_vault_credential"] = "azure_vault_credential"
+ key: str
+ description: typing.Optional[str] = None
+ azure_vault_credential_parameter_id: str
+ workflow_id: str
+ vault_name: str
+ username_key: str
+ password_key: str
+ totp_secret_key: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_credit_card_data_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ bitwarden_collection_id: str
+ bitwarden_item_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_login_credential_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ url_parameter_key: typing.Optional[str] = None
+ bitwarden_collection_id: typing.Optional[str] = None
+ bitwarden_item_id: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_sensitive_information_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ bitwarden_collection_id: str
+ bitwarden_identity_key: str
+ bitwarden_identity_fields: typing.List[str]
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_Context(UniversalBaseModel):
+ parameter_type: typing.Literal["context"] = "context"
+ key: str
+ description: typing.Optional[str] = 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
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+from .context_parameter import ContextParameter # noqa: E402, F401, I001
+from .context_parameter_source import ContextParameterSource # noqa: E402, F401, I001
+
+
+class EmailInboxBlockParametersItem_Credential(UniversalBaseModel):
+ parameter_type: typing.Literal["credential"] = "credential"
+ key: str
+ description: typing.Optional[str] = None
+ credential_parameter_id: str
+ workflow_id: str
+ credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_Onepassword(UniversalBaseModel):
+ parameter_type: typing.Literal["onepassword"] = "onepassword"
+ key: str
+ description: typing.Optional[str] = None
+ onepassword_credential_parameter_id: str
+ workflow_id: str
+ vault_id: str
+ item_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_Output(UniversalBaseModel):
+ parameter_type: typing.Literal["output"] = "output"
+ key: str
+ description: typing.Optional[str] = None
+ output_parameter_id: str
+ workflow_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class EmailInboxBlockParametersItem_Workflow(UniversalBaseModel):
+ parameter_type: typing.Literal["workflow"] = "workflow"
+ key: str
+ description: typing.Optional[str] = None
+ workflow_parameter_id: str
+ workflow_parameter_type: WorkflowParameterType
+ workflow_id: str
+ default_value: typing.Optional[WorkflowParameterDefaultValue] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+EmailInboxBlockParametersItem = typing.Union[
+ EmailInboxBlockParametersItem_AwsSecret,
+ EmailInboxBlockParametersItem_AzureSecret,
+ EmailInboxBlockParametersItem_AzureVaultCredential,
+ EmailInboxBlockParametersItem_BitwardenCreditCardData,
+ EmailInboxBlockParametersItem_BitwardenLoginCredential,
+ EmailInboxBlockParametersItem_BitwardenSensitiveInformation,
+ EmailInboxBlockParametersItem_Context,
+ EmailInboxBlockParametersItem_Credential,
+ EmailInboxBlockParametersItem_Onepassword,
+ EmailInboxBlockParametersItem_Output,
+ EmailInboxBlockParametersItem_Workflow,
+]
+update_forward_refs(EmailInboxBlockParametersItem_Context)
diff --git a/skyvern/client/types/email_inbox_block_yaml.py b/skyvern/client/types/email_inbox_block_yaml.py
new file mode 100644
index 000000000..bb5f958b2
--- /dev/null
+++ b/skyvern/client/types/email_inbox_block_yaml.py
@@ -0,0 +1,43 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .email_inbox_block_yaml_email_client import EmailInboxBlockYamlEmailClient
+
+
+class EmailInboxBlockYaml(UniversalBaseModel):
+ label: str = pydantic.Field()
+ """
+ Author-facing identifier; must be unique per workflow.
+ """
+
+ next_block_label: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional pointer to the label of the next block. When omitted, it will default to sequential order. See [[s-4bnl]].
+ """
+
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ email_client: EmailInboxBlockYamlEmailClient
+ credential_id: typing.Optional[str] = None
+ folder: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
+ sender: typing.Optional[str] = None
+ subject: typing.Optional[str] = None
+ newer_than_days: typing.Optional[int] = None
+ max_results: typing.Optional[int] = None
+ include_body: typing.Optional[bool] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/email_inbox_block_yaml_email_client.py b/skyvern/client/types/email_inbox_block_yaml_email_client.py
new file mode 100644
index 000000000..2df4bef1a
--- /dev/null
+++ b/skyvern/client/types/email_inbox_block_yaml_email_client.py
@@ -0,0 +1,5 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+EmailInboxBlockYamlEmailClient = typing.Union[typing.Literal["gmail", "outlook"], typing.Any]
diff --git a/skyvern/client/types/extraction_block_parameters_item.py b/skyvern/client/types/extraction_block_parameters_item.py
index 437380f4a..a0c6d5ed2 100644
--- a/skyvern/client/types/extraction_block_parameters_item.py
+++ b/skyvern/client/types/extraction_block_parameters_item.py
@@ -183,6 +183,8 @@ class ExtractionBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/file_download_block_parameters_item.py b/skyvern/client/types/file_download_block_parameters_item.py
index 07e4b0425..bab25d011 100644
--- a/skyvern/client/types/file_download_block_parameters_item.py
+++ b/skyvern/client/types/file_download_block_parameters_item.py
@@ -183,6 +183,8 @@ class FileDownloadBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/file_type.py b/skyvern/client/types/file_type.py
index 619ce5455..6575b7e3a 100644
--- a/skyvern/client/types/file_type.py
+++ b/skyvern/client/types/file_type.py
@@ -2,4 +2,4 @@
import typing
-FileType = typing.Union[typing.Literal["auto_detect", "csv", "excel", "pdf", "image", "docx"], typing.Any]
+FileType = typing.Union[typing.Literal["auto_detect", "csv", "excel", "pdf", "image", "docx", "zip"], typing.Any]
diff --git a/skyvern/client/types/file_upload_block.py b/skyvern/client/types/file_upload_block.py
index 79a16e8cc..9cc020147 100644
--- a/skyvern/client/types/file_upload_block.py
+++ b/skyvern/client/types/file_upload_block.py
@@ -45,8 +45,16 @@ class FileUploadBlock(UniversalBaseModel):
sftp_private_key_passphrase: typing.Optional[str] = None
sftp_remote_path: typing.Optional[str] = None
sftp_host_key: typing.Optional[str] = None
- prompt: typing.Optional[str] = None
+ prompt: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional natural-language control over which downloaded files are uploaded; empty means upload all.
+ """
+
path: typing.Optional[str] = None
+ continue_on_empty: typing.Optional[bool] = pydantic.Field(default=None)
+ """
+ When the run download directory has no files, allow the empty upload only after confirming no registered, browser-session, or alternate candidate downloads exist (False, default). Set True to always allow an empty upload.
+ """
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/file_upload_block_yaml.py b/skyvern/client/types/file_upload_block_yaml.py
index fe6d4efb1..e03b20255 100644
--- a/skyvern/client/types/file_upload_block_yaml.py
+++ b/skyvern/client/types/file_upload_block_yaml.py
@@ -43,7 +43,11 @@ class FileUploadBlockYaml(UniversalBaseModel):
sftp_private_key_passphrase: typing.Optional[str] = None
sftp_remote_path: typing.Optional[str] = None
sftp_host_key: typing.Optional[str] = None
- prompt: typing.Optional[str] = None
+ prompt: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional natural-language control over which downloaded files are uploaded; empty means upload all.
+ """
+
path: typing.Optional[str] = None
if IS_PYDANTIC_V2:
diff --git a/skyvern/client/types/for_loop_block_loop_blocks_item.py b/skyvern/client/types/for_loop_block_loop_blocks_item.py
index ff67f4bda..86d8d112f 100644
--- a/skyvern/client/types/for_loop_block_loop_blocks_item.py
+++ b/skyvern/client/types/for_loop_block_loop_blocks_item.py
@@ -14,6 +14,9 @@ from .ai_fallback_mode import AiFallbackMode
from .aws_secret_parameter import AwsSecretParameter
from .branch_condition import BranchCondition
from .code_block_parameters_item import CodeBlockParametersItem
+from .code_block_step import CodeBlockStep
+from .email_inbox_block_email_client import EmailInboxBlockEmailClient
+from .email_inbox_block_parameters_item import EmailInboxBlockParametersItem
from .extraction_block_data_schema import ExtractionBlockDataSchema
from .extraction_block_parameters_item import ExtractionBlockParametersItem
from .file_download_block_data_schema import FileDownloadBlockDataSchema
@@ -33,8 +36,11 @@ from .login_block_parameters_item import LoginBlockParametersItem
from .navigation_block_data_schema import NavigationBlockDataSchema
from .navigation_block_parameters_item import NavigationBlockParametersItem
from .output_parameter import OutputParameter
+from .pdf_fill_block_parameters_item import PdfFillBlockParametersItem
+from .pdf_fill_block_payload import PdfFillBlockPayload
from .print_page_block_parameters_item import PrintPageBlockParametersItem
from .run_engine import RunEngine
+from .split_pdf_block_parameters_item import SplitPdfBlockParametersItem
from .task_block_data_schema import TaskBlockDataSchema
from .task_block_parameters_item import TaskBlockParametersItem
from .text_prompt_block_parameters_item import TextPromptBlockParametersItem
@@ -103,6 +109,8 @@ class ForLoopBlockLoopBlocksItem_Code(UniversalBaseModel):
next_loop_on_failure: typing.Optional[bool] = None
code: str
parameters: typing.Optional[typing.List[CodeBlockParametersItem]] = None
+ prompt: typing.Optional[str] = None
+ steps: typing.Optional[typing.List[CodeBlockStep]] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -158,6 +166,37 @@ class ForLoopBlockLoopBlocksItem_DownloadToS3(UniversalBaseModel):
extra = pydantic.Extra.allow
+class ForLoopBlockLoopBlocksItem_EmailInbox(UniversalBaseModel):
+ block_type: typing.Literal["email_inbox"] = "email_inbox"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ email_client: EmailInboxBlockEmailClient
+ credential_id: typing.Optional[str] = None
+ folder: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
+ sender: typing.Optional[str] = None
+ subject: typing.Optional[str] = None
+ newer_than_days: typing.Optional[int] = None
+ max_results: typing.Optional[int] = None
+ include_body: typing.Optional[bool] = None
+ parameters: typing.Optional[typing.List[EmailInboxBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class ForLoopBlockLoopBlocksItem_Extraction(UniversalBaseModel):
block_type: typing.Literal["extraction"] = "extraction"
label: str
@@ -262,7 +301,17 @@ class ForLoopBlockLoopBlocksItem_FileUpload(UniversalBaseModel):
azure_blob_container_name: typing.Optional[str] = None
google_credential_id: typing.Optional[str] = None
google_drive_folder_id: typing.Optional[str] = None
+ sftp_host: typing.Optional[str] = None
+ sftp_port: typing.Optional[int] = None
+ sftp_username: typing.Optional[str] = None
+ sftp_password: typing.Optional[str] = None
+ sftp_private_key: typing.Optional[str] = None
+ sftp_private_key_passphrase: typing.Optional[str] = None
+ sftp_remote_path: typing.Optional[str] = None
+ sftp_host_key: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
path: typing.Optional[str] = None
+ continue_on_empty: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -442,6 +491,7 @@ class ForLoopBlockLoopBlocksItem_HttpRequest(UniversalBaseModel):
follow_redirects: typing.Optional[bool] = None
download_filename: typing.Optional[str] = None
save_response_as_file: typing.Optional[bool] = None
+ secret_response_paths: typing.Optional[typing.List[str]] = None
parameters: typing.Optional[typing.List[HttpRequestBlockParametersItem]] = None
if IS_PYDANTIC_V2:
@@ -589,6 +639,32 @@ class ForLoopBlockLoopBlocksItem_Navigation(UniversalBaseModel):
extra = pydantic.Extra.allow
+class ForLoopBlockLoopBlocksItem_PdfFill(UniversalBaseModel):
+ block_type: typing.Literal["pdf_fill"] = "pdf_fill"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ payload: typing.Optional[PdfFillBlockPayload] = None
+ llm_key: typing.Optional[str] = None
+ parameters: typing.Optional[typing.List[PdfFillBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class ForLoopBlockLoopBlocksItem_PdfParser(UniversalBaseModel):
block_type: typing.Literal["pdf_parser"] = "pdf_parser"
label: str
@@ -669,6 +745,31 @@ class ForLoopBlockLoopBlocksItem_SendEmail(UniversalBaseModel):
extra = pydantic.Extra.allow
+class ForLoopBlockLoopBlocksItem_SplitPdf(UniversalBaseModel):
+ block_type: typing.Literal["split_pdf"] = "split_pdf"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ llm_key: typing.Optional[str] = None
+ parameters: typing.Optional[typing.List[SplitPdfBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class ForLoopBlockLoopBlocksItem_Task(UniversalBaseModel):
block_type: typing.Literal["task"] = "task"
label: str
@@ -816,6 +917,7 @@ class ForLoopBlockLoopBlocksItem_Validation(UniversalBaseModel):
include_action_history_in_verification: typing.Optional[bool] = None
download_timeout: typing.Optional[float] = None
include_extracted_text: typing.Optional[bool] = None
+ without_page_information: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -911,6 +1013,7 @@ ForLoopBlockLoopBlocksItem = typing.Union[
ForLoopBlockLoopBlocksItem_Code,
ForLoopBlockLoopBlocksItem_Conditional,
ForLoopBlockLoopBlocksItem_DownloadToS3,
+ ForLoopBlockLoopBlocksItem_EmailInbox,
ForLoopBlockLoopBlocksItem_Extraction,
ForLoopBlockLoopBlocksItem_FileDownload,
ForLoopBlockLoopBlocksItem_FileUpload,
@@ -923,9 +1026,11 @@ ForLoopBlockLoopBlocksItem = typing.Union[
ForLoopBlockLoopBlocksItem_HumanInteraction,
ForLoopBlockLoopBlocksItem_Login,
ForLoopBlockLoopBlocksItem_Navigation,
+ ForLoopBlockLoopBlocksItem_PdfFill,
ForLoopBlockLoopBlocksItem_PdfParser,
ForLoopBlockLoopBlocksItem_PrintPage,
ForLoopBlockLoopBlocksItem_SendEmail,
+ ForLoopBlockLoopBlocksItem_SplitPdf,
ForLoopBlockLoopBlocksItem_Task,
ForLoopBlockLoopBlocksItem_TaskV2,
ForLoopBlockLoopBlocksItem_TextPrompt,
@@ -939,6 +1044,7 @@ from .while_loop_block_loop_blocks_item import WhileLoopBlockLoopBlocksItem # n
update_forward_refs(ForLoopBlockLoopBlocksItem_Action)
update_forward_refs(ForLoopBlockLoopBlocksItem_Code)
+update_forward_refs(ForLoopBlockLoopBlocksItem_EmailInbox)
update_forward_refs(ForLoopBlockLoopBlocksItem_Extraction)
update_forward_refs(ForLoopBlockLoopBlocksItem_FileDownload)
update_forward_refs(ForLoopBlockLoopBlocksItem_ForLoop)
@@ -949,7 +1055,9 @@ update_forward_refs(ForLoopBlockLoopBlocksItem_HttpRequest)
update_forward_refs(ForLoopBlockLoopBlocksItem_HumanInteraction)
update_forward_refs(ForLoopBlockLoopBlocksItem_Login)
update_forward_refs(ForLoopBlockLoopBlocksItem_Navigation)
+update_forward_refs(ForLoopBlockLoopBlocksItem_PdfFill)
update_forward_refs(ForLoopBlockLoopBlocksItem_PrintPage)
+update_forward_refs(ForLoopBlockLoopBlocksItem_SplitPdf)
update_forward_refs(ForLoopBlockLoopBlocksItem_Task)
update_forward_refs(ForLoopBlockLoopBlocksItem_TextPrompt)
update_forward_refs(ForLoopBlockLoopBlocksItem_Validation)
diff --git a/skyvern/client/types/for_loop_block_loop_over.py b/skyvern/client/types/for_loop_block_loop_over.py
index 8da93d7d1..65c6cd0d0 100644
--- a/skyvern/client/types/for_loop_block_loop_over.py
+++ b/skyvern/client/types/for_loop_block_loop_over.py
@@ -183,6 +183,8 @@ class ForLoopBlockLoopOver_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/for_loop_block_yaml_loop_blocks_item.py b/skyvern/client/types/for_loop_block_yaml_loop_blocks_item.py
index 428623ff4..4eaf9e12b 100644
--- a/skyvern/client/types/for_loop_block_yaml_loop_blocks_item.py
+++ b/skyvern/client/types/for_loop_block_yaml_loop_blocks_item.py
@@ -11,11 +11,14 @@ from ..core.serialization import FieldMetadata
from .ai_fallback_mode import AiFallbackMode
from .branch_condition_yaml import BranchConditionYaml
from .branch_criteria_yaml import BranchCriteriaYaml
+from .code_block_step_yaml import CodeBlockStepYaml
+from .email_inbox_block_yaml_email_client import EmailInboxBlockYamlEmailClient
from .extraction_block_yaml_data_schema import ExtractionBlockYamlDataSchema
from .file_storage_type import FileStorageType
from .file_type import FileType
from .for_loop_block_yaml_data_schema import ForLoopBlockYamlDataSchema
from .google_sheets_write_block_yaml_write_mode import GoogleSheetsWriteBlockYamlWriteMode
+from .pdf_fill_block_yaml_payload import PdfFillBlockYamlPayload
from .pdf_format import PdfFormat
from .run_engine import RunEngine
from .task_block_yaml_data_schema import TaskBlockYamlDataSchema
@@ -118,6 +121,8 @@ class ForLoopBlockYamlLoopBlocksItem_Code(UniversalBaseModel):
next_loop_on_failure: typing.Optional[bool] = None
code: str
parameter_keys: typing.Optional[typing.List[str]] = None
+ prompt: typing.Optional[str] = None
+ steps: typing.Optional[typing.List[CodeBlockStepYaml]] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -211,6 +216,15 @@ class ForLoopBlockYamlLoopBlocksItem_FileUpload(UniversalBaseModel):
azure_folder_path: typing.Optional[str] = None
google_credential_id: typing.Optional[str] = None
google_drive_folder_id: typing.Optional[str] = None
+ sftp_host: typing.Optional[str] = None
+ sftp_port: typing.Optional[int] = None
+ sftp_username: typing.Optional[str] = None
+ sftp_password: typing.Optional[str] = None
+ sftp_private_key: typing.Optional[str] = None
+ sftp_private_key_passphrase: typing.Optional[str] = None
+ sftp_remote_path: typing.Optional[str] = None
+ sftp_host_key: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
path: typing.Optional[str] = None
if IS_PYDANTIC_V2:
@@ -286,6 +300,7 @@ class ForLoopBlockYamlLoopBlocksItem_Validation(UniversalBaseModel):
error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None
parameter_keys: typing.Optional[typing.List[str]] = None
disable_cache: typing.Optional[bool] = None
+ without_page_information: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -591,6 +606,7 @@ class ForLoopBlockYamlLoopBlocksItem_HttpRequest(UniversalBaseModel):
follow_redirects: typing.Optional[bool] = None
download_filename: typing.Optional[str] = None
save_response_as_file: typing.Optional[bool] = None
+ secret_response_paths: typing.Optional[typing.List[str]] = None
parameter_keys: typing.Optional[typing.List[str]] = None
if IS_PYDANTIC_V2:
@@ -648,6 +664,53 @@ class ForLoopBlockYamlLoopBlocksItem_PrintPage(UniversalBaseModel):
extra = pydantic.Extra.allow
+class ForLoopBlockYamlLoopBlocksItem_PdfFill(UniversalBaseModel):
+ block_type: typing.Literal["pdf_fill"] = "pdf_fill"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ payload: typing.Optional[PdfFillBlockYamlPayload] = None
+ llm_key: typing.Optional[str] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class ForLoopBlockYamlLoopBlocksItem_SplitPdf(UniversalBaseModel):
+ block_type: typing.Literal["split_pdf"] = "split_pdf"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ llm_key: typing.Optional[str] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class ForLoopBlockYamlLoopBlocksItem_WorkflowTrigger(UniversalBaseModel):
block_type: typing.Literal["workflow_trigger"] = "workflow_trigger"
label: str
@@ -698,6 +761,35 @@ class ForLoopBlockYamlLoopBlocksItem_GoogleSheetsRead(UniversalBaseModel):
extra = pydantic.Extra.allow
+class ForLoopBlockYamlLoopBlocksItem_EmailInbox(UniversalBaseModel):
+ block_type: typing.Literal["email_inbox"] = "email_inbox"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ email_client: EmailInboxBlockYamlEmailClient
+ credential_id: typing.Optional[str] = None
+ folder: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
+ sender: typing.Optional[str] = None
+ subject: typing.Optional[str] = None
+ newer_than_days: typing.Optional[int] = None
+ max_results: typing.Optional[int] = None
+ include_body: typing.Optional[bool] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class ForLoopBlockYamlLoopBlocksItem_GoogleSheetsWrite(UniversalBaseModel):
block_type: typing.Literal["google_sheets_write"] = "google_sheets_write"
label: str
@@ -751,8 +843,11 @@ ForLoopBlockYamlLoopBlocksItem = typing.Union[
ForLoopBlockYamlLoopBlocksItem_HttpRequest,
ForLoopBlockYamlLoopBlocksItem_Conditional,
ForLoopBlockYamlLoopBlocksItem_PrintPage,
+ ForLoopBlockYamlLoopBlocksItem_PdfFill,
+ ForLoopBlockYamlLoopBlocksItem_SplitPdf,
ForLoopBlockYamlLoopBlocksItem_WorkflowTrigger,
ForLoopBlockYamlLoopBlocksItem_GoogleSheetsRead,
+ ForLoopBlockYamlLoopBlocksItem_EmailInbox,
ForLoopBlockYamlLoopBlocksItem_GoogleSheetsWrite,
]
from .while_loop_block_yaml_loop_blocks_item import WhileLoopBlockYamlLoopBlocksItem # noqa: E402, F401, I001
diff --git a/skyvern/client/types/google_sheets_read_block_parameters_item.py b/skyvern/client/types/google_sheets_read_block_parameters_item.py
index d06af1366..b429dd264 100644
--- a/skyvern/client/types/google_sheets_read_block_parameters_item.py
+++ b/skyvern/client/types/google_sheets_read_block_parameters_item.py
@@ -183,6 +183,8 @@ class GoogleSheetsReadBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/google_sheets_write_block_parameters_item.py b/skyvern/client/types/google_sheets_write_block_parameters_item.py
index 0497c61a0..221ee13c9 100644
--- a/skyvern/client/types/google_sheets_write_block_parameters_item.py
+++ b/skyvern/client/types/google_sheets_write_block_parameters_item.py
@@ -183,6 +183,8 @@ class GoogleSheetsWriteBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/http_request_block.py b/skyvern/client/types/http_request_block.py
index 4fc1e6e8f..f9fa26d4c 100644
--- a/skyvern/client/types/http_request_block.py
+++ b/skyvern/client/types/http_request_block.py
@@ -36,6 +36,7 @@ class HttpRequestBlock(UniversalBaseModel):
follow_redirects: typing.Optional[bool] = None
download_filename: typing.Optional[str] = None
save_response_as_file: typing.Optional[bool] = None
+ secret_response_paths: typing.Optional[typing.List[str]] = None
parameters: typing.Optional[typing.List[HttpRequestBlockParametersItem]] = None
if IS_PYDANTIC_V2:
diff --git a/skyvern/client/types/http_request_block_parameters_item.py b/skyvern/client/types/http_request_block_parameters_item.py
index aa6bec5e6..9e74ba7ad 100644
--- a/skyvern/client/types/http_request_block_parameters_item.py
+++ b/skyvern/client/types/http_request_block_parameters_item.py
@@ -183,6 +183,8 @@ class HttpRequestBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/http_request_block_yaml.py b/skyvern/client/types/http_request_block_yaml.py
index b2bd6ae15..93af114f4 100644
--- a/skyvern/client/types/http_request_block_yaml.py
+++ b/skyvern/client/types/http_request_block_yaml.py
@@ -30,6 +30,7 @@ class HttpRequestBlockYaml(UniversalBaseModel):
follow_redirects: typing.Optional[bool] = None
download_filename: typing.Optional[str] = None
save_response_as_file: typing.Optional[bool] = None
+ secret_response_paths: typing.Optional[typing.List[str]] = None
parameter_keys: typing.Optional[typing.List[str]] = None
if IS_PYDANTIC_V2:
diff --git a/skyvern/client/types/human_interaction_block_parameters_item.py b/skyvern/client/types/human_interaction_block_parameters_item.py
index f9e760ff0..55ff237cb 100644
--- a/skyvern/client/types/human_interaction_block_parameters_item.py
+++ b/skyvern/client/types/human_interaction_block_parameters_item.py
@@ -183,6 +183,8 @@ class HumanInteractionBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/login_block_parameters_item.py b/skyvern/client/types/login_block_parameters_item.py
index 37f026ceb..5159dbde7 100644
--- a/skyvern/client/types/login_block_parameters_item.py
+++ b/skyvern/client/types/login_block_parameters_item.py
@@ -183,6 +183,8 @@ class LoginBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/navigation_block_parameters_item.py b/skyvern/client/types/navigation_block_parameters_item.py
index ebd7d01ad..bf07f06dc 100644
--- a/skyvern/client/types/navigation_block_parameters_item.py
+++ b/skyvern/client/types/navigation_block_parameters_item.py
@@ -183,6 +183,8 @@ class NavigationBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/non_empty_credit_card_credential.py b/skyvern/client/types/non_empty_credit_card_credential.py
index 6f8ee4c95..44b9e4147 100644
--- a/skyvern/client/types/non_empty_credit_card_credential.py
+++ b/skyvern/client/types/non_empty_credit_card_credential.py
@@ -4,6 +4,7 @@ import typing
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .credit_card_billing_address import CreditCardBillingAddress
class NonEmptyCreditCardCredential(UniversalBaseModel):
@@ -41,6 +42,26 @@ class NonEmptyCreditCardCredential(UniversalBaseModel):
The name of the card holder (must not be empty)
"""
+ billing_address: typing.Optional[CreditCardBillingAddress] = pydantic.Field(default=None)
+ """
+ Optional billing address associated with the card
+ """
+
+ billing_email: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional billing email address
+ """
+
+ billing_phone: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional billing phone number
+ """
+
+ metadata: typing.Optional[typing.Dict[str, typing.Optional[str]]] = pydantic.Field(default=None)
+ """
+ Optional additional credit card metadata fields
+ """
+
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
else:
diff --git a/skyvern/client/types/pdf_fill_block.py b/skyvern/client/types/pdf_fill_block.py
new file mode 100644
index 000000000..bbc281067
--- /dev/null
+++ b/skyvern/client/types/pdf_fill_block.py
@@ -0,0 +1,49 @@
+# This file was auto-generated by Fern from our API Definition.
+
+from __future__ import annotations
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs
+from .output_parameter import OutputParameter
+from .pdf_fill_block_parameters_item import PdfFillBlockParametersItem
+from .pdf_fill_block_payload import PdfFillBlockPayload
+
+
+class PdfFillBlock(UniversalBaseModel):
+ label: str = pydantic.Field()
+ """
+ Author-facing identifier for a block; unique within a workflow.
+ """
+
+ next_block_label: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional pointer to the next block label when constructing a DAG. Defaults to sequential order when omitted.
+ """
+
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ payload: typing.Optional[PdfFillBlockPayload] = None
+ llm_key: typing.Optional[str] = None
+ parameters: typing.Optional[typing.List[PdfFillBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+from .context_parameter import ContextParameter # noqa: E402, F401, I001
+
+update_forward_refs(PdfFillBlock)
diff --git a/skyvern/client/types/pdf_fill_block_parameters_item.py b/skyvern/client/types/pdf_fill_block_parameters_item.py
new file mode 100644
index 000000000..341525b84
--- /dev/null
+++ b/skyvern/client/types/pdf_fill_block_parameters_item.py
@@ -0,0 +1,279 @@
+# This file was auto-generated by Fern from our API Definition.
+
+from __future__ import annotations
+
+import datetime as dt
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs
+from .context_parameter_value import ContextParameterValue
+from .workflow_parameter_default_value import WorkflowParameterDefaultValue
+from .workflow_parameter_type import WorkflowParameterType
+
+
+class PdfFillBlockParametersItem_AwsSecret(UniversalBaseModel):
+ parameter_type: typing.Literal["aws_secret"] = "aws_secret"
+ key: str
+ description: typing.Optional[str] = None
+ aws_secret_parameter_id: str
+ workflow_id: str
+ aws_key: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_AzureSecret(UniversalBaseModel):
+ parameter_type: typing.Literal["azure_secret"] = "azure_secret"
+ key: str
+ description: typing.Optional[str] = None
+ azure_secret_parameter_id: str
+ workflow_id: str
+ azure_key: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_AzureVaultCredential(UniversalBaseModel):
+ parameter_type: typing.Literal["azure_vault_credential"] = "azure_vault_credential"
+ key: str
+ description: typing.Optional[str] = None
+ azure_vault_credential_parameter_id: str
+ workflow_id: str
+ vault_name: str
+ username_key: str
+ password_key: str
+ totp_secret_key: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_credit_card_data_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ bitwarden_collection_id: str
+ bitwarden_item_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_login_credential_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ url_parameter_key: typing.Optional[str] = None
+ bitwarden_collection_id: typing.Optional[str] = None
+ bitwarden_item_id: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_sensitive_information_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ bitwarden_collection_id: str
+ bitwarden_identity_key: str
+ bitwarden_identity_fields: typing.List[str]
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_Context(UniversalBaseModel):
+ parameter_type: typing.Literal["context"] = "context"
+ key: str
+ description: typing.Optional[str] = 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
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+from .context_parameter import ContextParameter # noqa: E402, F401, I001
+from .context_parameter_source import ContextParameterSource # noqa: E402, F401, I001
+
+
+class PdfFillBlockParametersItem_Credential(UniversalBaseModel):
+ parameter_type: typing.Literal["credential"] = "credential"
+ key: str
+ description: typing.Optional[str] = None
+ credential_parameter_id: str
+ workflow_id: str
+ credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_Onepassword(UniversalBaseModel):
+ parameter_type: typing.Literal["onepassword"] = "onepassword"
+ key: str
+ description: typing.Optional[str] = None
+ onepassword_credential_parameter_id: str
+ workflow_id: str
+ vault_id: str
+ item_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_Output(UniversalBaseModel):
+ parameter_type: typing.Literal["output"] = "output"
+ key: str
+ description: typing.Optional[str] = None
+ output_parameter_id: str
+ workflow_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class PdfFillBlockParametersItem_Workflow(UniversalBaseModel):
+ parameter_type: typing.Literal["workflow"] = "workflow"
+ key: str
+ description: typing.Optional[str] = None
+ workflow_parameter_id: str
+ workflow_parameter_type: WorkflowParameterType
+ workflow_id: str
+ default_value: typing.Optional[WorkflowParameterDefaultValue] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+PdfFillBlockParametersItem = typing.Union[
+ PdfFillBlockParametersItem_AwsSecret,
+ PdfFillBlockParametersItem_AzureSecret,
+ PdfFillBlockParametersItem_AzureVaultCredential,
+ PdfFillBlockParametersItem_BitwardenCreditCardData,
+ PdfFillBlockParametersItem_BitwardenLoginCredential,
+ PdfFillBlockParametersItem_BitwardenSensitiveInformation,
+ PdfFillBlockParametersItem_Context,
+ PdfFillBlockParametersItem_Credential,
+ PdfFillBlockParametersItem_Onepassword,
+ PdfFillBlockParametersItem_Output,
+ PdfFillBlockParametersItem_Workflow,
+]
+update_forward_refs(PdfFillBlockParametersItem_Context)
diff --git a/skyvern/client/types/pdf_fill_block_payload.py b/skyvern/client/types/pdf_fill_block_payload.py
new file mode 100644
index 000000000..8c8f5acdd
--- /dev/null
+++ b/skyvern/client/types/pdf_fill_block_payload.py
@@ -0,0 +1,7 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+PdfFillBlockPayload = typing.Union[
+ typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]], str
+]
diff --git a/skyvern/client/types/pdf_fill_block_yaml.py b/skyvern/client/types/pdf_fill_block_yaml.py
new file mode 100644
index 000000000..385ba3b14
--- /dev/null
+++ b/skyvern/client/types/pdf_fill_block_yaml.py
@@ -0,0 +1,38 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .pdf_fill_block_yaml_payload import PdfFillBlockYamlPayload
+
+
+class PdfFillBlockYaml(UniversalBaseModel):
+ label: str = pydantic.Field()
+ """
+ Author-facing identifier; must be unique per workflow.
+ """
+
+ next_block_label: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional pointer to the label of the next block. When omitted, it will default to sequential order. See [[s-4bnl]].
+ """
+
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ payload: typing.Optional[PdfFillBlockYamlPayload] = None
+ llm_key: typing.Optional[str] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/pdf_fill_block_yaml_payload.py b/skyvern/client/types/pdf_fill_block_yaml_payload.py
new file mode 100644
index 000000000..4bc2a4fd9
--- /dev/null
+++ b/skyvern/client/types/pdf_fill_block_yaml_payload.py
@@ -0,0 +1,7 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+PdfFillBlockYamlPayload = typing.Union[
+ typing.Dict[str, typing.Optional[typing.Any]], typing.List[typing.Optional[typing.Any]], str
+]
diff --git a/skyvern/client/types/print_page_block_parameters_item.py b/skyvern/client/types/print_page_block_parameters_item.py
index 4b50e99c2..d1a279baa 100644
--- a/skyvern/client/types/print_page_block_parameters_item.py
+++ b/skyvern/client/types/print_page_block_parameters_item.py
@@ -183,6 +183,8 @@ class PrintPageBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/run_tag_history_response.py b/skyvern/client/types/run_tag_history_response.py
new file mode 100644
index 000000000..7222c3224
--- /dev/null
+++ b/skyvern/client/types/run_tag_history_response.py
@@ -0,0 +1,21 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .tag_history_item import TagHistoryItem
+
+
+class RunTagHistoryResponse(UniversalBaseModel):
+ workflow_run_id: str
+ events: typing.List[TagHistoryItem]
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/run_tags_batch_response.py b/skyvern/client/types/run_tags_batch_response.py
new file mode 100644
index 000000000..8e02ac9ab
--- /dev/null
+++ b/skyvern/client/types/run_tags_batch_response.py
@@ -0,0 +1,28 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .tag_item import TagItem
+
+
+class RunTagsBatchResponse(UniversalBaseModel):
+ """
+ Response for the run-tags batch endpoint.
+
+ Runs with no tags are present with an empty list so the frontend can
+ distinguish "fetched, none set" from "not fetched" without a second call.
+ Runs outside the caller's org are silently absent (no leakage).
+ """
+
+ run_tags: typing.Dict[str, typing.List[TagItem]]
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/run_tags_response.py b/skyvern/client/types/run_tags_response.py
new file mode 100644
index 000000000..fb43dbb50
--- /dev/null
+++ b/skyvern/client/types/run_tags_response.py
@@ -0,0 +1,25 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .tag_response import TagResponse
+
+
+class RunTagsResponse(UniversalBaseModel):
+ """
+ Current tags for a workflow run.
+ """
+
+ workflow_run_id: str
+ tags: typing.List[TagResponse]
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/run_type.py b/skyvern/client/types/run_type.py
new file mode 100644
index 000000000..29b8f40cb
--- /dev/null
+++ b/skyvern/client/types/run_type.py
@@ -0,0 +1,8 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+RunType = typing.Union[
+ typing.Literal["task_v1", "task_v2", "workflow_run", "openai_cua", "anthropic_cua", "ui_tars", "yutori_navigator"],
+ typing.Any,
+]
diff --git a/skyvern/client/types/split_pdf_block.py b/skyvern/client/types/split_pdf_block.py
new file mode 100644
index 000000000..6516bf098
--- /dev/null
+++ b/skyvern/client/types/split_pdf_block.py
@@ -0,0 +1,47 @@
+# This file was auto-generated by Fern from our API Definition.
+
+from __future__ import annotations
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs
+from .output_parameter import OutputParameter
+from .split_pdf_block_parameters_item import SplitPdfBlockParametersItem
+
+
+class SplitPdfBlock(UniversalBaseModel):
+ label: str = pydantic.Field()
+ """
+ Author-facing identifier for a block; unique within a workflow.
+ """
+
+ next_block_label: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional pointer to the next block label when constructing a DAG. Defaults to sequential order when omitted.
+ """
+
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ llm_key: typing.Optional[str] = None
+ parameters: typing.Optional[typing.List[SplitPdfBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+from .context_parameter import ContextParameter # noqa: E402, F401, I001
+
+update_forward_refs(SplitPdfBlock)
diff --git a/skyvern/client/types/split_pdf_block_parameters_item.py b/skyvern/client/types/split_pdf_block_parameters_item.py
new file mode 100644
index 000000000..eb61be434
--- /dev/null
+++ b/skyvern/client/types/split_pdf_block_parameters_item.py
@@ -0,0 +1,279 @@
+# This file was auto-generated by Fern from our API Definition.
+
+from __future__ import annotations
+
+import datetime as dt
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel, update_forward_refs
+from .context_parameter_value import ContextParameterValue
+from .workflow_parameter_default_value import WorkflowParameterDefaultValue
+from .workflow_parameter_type import WorkflowParameterType
+
+
+class SplitPdfBlockParametersItem_AwsSecret(UniversalBaseModel):
+ parameter_type: typing.Literal["aws_secret"] = "aws_secret"
+ key: str
+ description: typing.Optional[str] = None
+ aws_secret_parameter_id: str
+ workflow_id: str
+ aws_key: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_AzureSecret(UniversalBaseModel):
+ parameter_type: typing.Literal["azure_secret"] = "azure_secret"
+ key: str
+ description: typing.Optional[str] = None
+ azure_secret_parameter_id: str
+ workflow_id: str
+ azure_key: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_AzureVaultCredential(UniversalBaseModel):
+ parameter_type: typing.Literal["azure_vault_credential"] = "azure_vault_credential"
+ key: str
+ description: typing.Optional[str] = None
+ azure_vault_credential_parameter_id: str
+ workflow_id: str
+ vault_name: str
+ username_key: str
+ password_key: str
+ totp_secret_key: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_BitwardenCreditCardData(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_credit_card_data"] = "bitwarden_credit_card_data"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_credit_card_data_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ bitwarden_collection_id: str
+ bitwarden_item_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_BitwardenLoginCredential(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_login_credential"] = "bitwarden_login_credential"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_login_credential_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ url_parameter_key: typing.Optional[str] = None
+ bitwarden_collection_id: typing.Optional[str] = None
+ bitwarden_item_id: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_BitwardenSensitiveInformation(UniversalBaseModel):
+ parameter_type: typing.Literal["bitwarden_sensitive_information"] = "bitwarden_sensitive_information"
+ key: str
+ description: typing.Optional[str] = None
+ bitwarden_sensitive_information_parameter_id: str
+ workflow_id: str
+ bitwarden_client_id_aws_secret_key: str
+ bitwarden_client_secret_aws_secret_key: str
+ bitwarden_master_password_aws_secret_key: str
+ bitwarden_collection_id: str
+ bitwarden_identity_key: str
+ bitwarden_identity_fields: typing.List[str]
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_Context(UniversalBaseModel):
+ parameter_type: typing.Literal["context"] = "context"
+ key: str
+ description: typing.Optional[str] = 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
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+from .context_parameter import ContextParameter # noqa: E402, F401, I001
+from .context_parameter_source import ContextParameterSource # noqa: E402, F401, I001
+
+
+class SplitPdfBlockParametersItem_Credential(UniversalBaseModel):
+ parameter_type: typing.Literal["credential"] = "credential"
+ key: str
+ description: typing.Optional[str] = None
+ credential_parameter_id: str
+ workflow_id: str
+ credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_Onepassword(UniversalBaseModel):
+ parameter_type: typing.Literal["onepassword"] = "onepassword"
+ key: str
+ description: typing.Optional[str] = None
+ onepassword_credential_parameter_id: str
+ workflow_id: str
+ vault_id: str
+ item_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_Output(UniversalBaseModel):
+ parameter_type: typing.Literal["output"] = "output"
+ key: str
+ description: typing.Optional[str] = None
+ output_parameter_id: str
+ workflow_id: str
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class SplitPdfBlockParametersItem_Workflow(UniversalBaseModel):
+ parameter_type: typing.Literal["workflow"] = "workflow"
+ key: str
+ description: typing.Optional[str] = None
+ workflow_parameter_id: str
+ workflow_parameter_type: WorkflowParameterType
+ workflow_id: str
+ default_value: typing.Optional[WorkflowParameterDefaultValue] = None
+ created_at: dt.datetime
+ modified_at: dt.datetime
+ deleted_at: typing.Optional[dt.datetime] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+SplitPdfBlockParametersItem = typing.Union[
+ SplitPdfBlockParametersItem_AwsSecret,
+ SplitPdfBlockParametersItem_AzureSecret,
+ SplitPdfBlockParametersItem_AzureVaultCredential,
+ SplitPdfBlockParametersItem_BitwardenCreditCardData,
+ SplitPdfBlockParametersItem_BitwardenLoginCredential,
+ SplitPdfBlockParametersItem_BitwardenSensitiveInformation,
+ SplitPdfBlockParametersItem_Context,
+ SplitPdfBlockParametersItem_Credential,
+ SplitPdfBlockParametersItem_Onepassword,
+ SplitPdfBlockParametersItem_Output,
+ SplitPdfBlockParametersItem_Workflow,
+]
+update_forward_refs(SplitPdfBlockParametersItem_Context)
diff --git a/skyvern/client/types/split_pdf_block_yaml.py b/skyvern/client/types/split_pdf_block_yaml.py
new file mode 100644
index 000000000..e6495a2e8
--- /dev/null
+++ b/skyvern/client/types/split_pdf_block_yaml.py
@@ -0,0 +1,36 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class SplitPdfBlockYaml(UniversalBaseModel):
+ label: str = pydantic.Field()
+ """
+ Author-facing identifier; must be unique per workflow.
+ """
+
+ next_block_label: typing.Optional[str] = pydantic.Field(default=None)
+ """
+ Optional pointer to the label of the next block. When omitted, it will default to sequential order. See [[s-4bnl]].
+ """
+
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ llm_key: typing.Optional[str] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/tag_apply_request.py b/skyvern/client/types/tag_apply_request.py
new file mode 100644
index 000000000..6929fd54b
--- /dev/null
+++ b/skyvern/client/types/tag_apply_request.py
@@ -0,0 +1,39 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+from .tag_delete_input import TagDeleteInput
+from .tag_input import TagInput
+
+
+class TagApplyRequest(UniversalBaseModel):
+ """
+ Body for ``POST /v1/workflows/{wpid}/tags``. Either field may be empty (both
+ empty is a no-op). On a same-identity collision, set wins over delete.
+ """
+
+ tags: typing.Optional[typing.List[TagInput]] = pydantic.Field(default=None)
+ """
+ Tags to set (overwrite). List of {key?, value} objects.
+ """
+
+ tags_to_delete: typing.Optional[typing.List[TagDeleteInput]] = pydantic.Field(default=None)
+ """
+ Tags to soft-delete. List of {key?, value?} targets.
+ """
+
+ colors: typing.Optional[typing.Dict[str, typing.Optional[str]]] = pydantic.Field(default=None)
+ """
+ Optional map of grouped tag key to palette color name for the value being set. Keys absent from this map keep their existing color or receive a random palette color.
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/tag_key_delete_response.py b/skyvern/client/types/tag_key_delete_response.py
index 92717e45b..1f8453eb4 100644
--- a/skyvern/client/types/tag_key_delete_response.py
+++ b/skyvern/client/types/tag_key_delete_response.py
@@ -13,6 +13,8 @@ class TagKeyDeleteResponse(UniversalBaseModel):
key: str
removed_from_workflow_count: int
+ removed_from_run_count: typing.Optional[int] = None
+ removed_count: typing.Optional[int] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/tag_value.py b/skyvern/client/types/tag_value.py
new file mode 100644
index 000000000..88215208c
--- /dev/null
+++ b/skyvern/client/types/tag_value.py
@@ -0,0 +1,30 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class TagValue(UniversalBaseModel):
+ """
+ Tag-value color registry entry: the palette color assigned to a grouped
+ (key, value) pair.
+ """
+
+ key: str
+ value: str
+ color: str
+ workflow_count: typing.Optional[int] = pydantic.Field(default=None)
+ """
+ Number of non-deleted workflows currently carrying this (key, value) label.
+ """
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/tag_value_delete_response.py b/skyvern/client/types/tag_value_delete_response.py
new file mode 100644
index 000000000..0100d7088
--- /dev/null
+++ b/skyvern/client/types/tag_value_delete_response.py
@@ -0,0 +1,27 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class TagValueDeleteResponse(UniversalBaseModel):
+ """
+ Response for ``DELETE /v1/tag-values/{key}``.
+ """
+
+ key: str
+ value: str
+ removed_from_workflow_count: int
+ removed_from_run_count: typing.Optional[int] = None
+ removed_count: typing.Optional[int] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/tag_value_rename_response.py b/skyvern/client/types/tag_value_rename_response.py
new file mode 100644
index 000000000..93bdddde9
--- /dev/null
+++ b/skyvern/client/types/tag_value_rename_response.py
@@ -0,0 +1,27 @@
+# This file was auto-generated by Fern from our API Definition.
+
+import typing
+
+import pydantic
+from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
+
+
+class TagValueRenameResponse(UniversalBaseModel):
+ """
+ Response for ``PATCH /v1/tag-values/{key}/rename``: the renamed label with its
+ carried-over color and the number of workflows re-tagged.
+ """
+
+ key: str
+ value: str
+ color: str
+ renamed_workflow_count: int
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
diff --git a/skyvern/client/types/task_block_parameters_item.py b/skyvern/client/types/task_block_parameters_item.py
index 63ca5a120..8584652d8 100644
--- a/skyvern/client/types/task_block_parameters_item.py
+++ b/skyvern/client/types/task_block_parameters_item.py
@@ -183,6 +183,8 @@ class TaskBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/text_prompt_block_parameters_item.py b/skyvern/client/types/text_prompt_block_parameters_item.py
index e8bcf29d4..acda20725 100644
--- a/skyvern/client/types/text_prompt_block_parameters_item.py
+++ b/skyvern/client/types/text_prompt_block_parameters_item.py
@@ -183,6 +183,8 @@ class TextPromptBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/url_block_parameters_item.py b/skyvern/client/types/url_block_parameters_item.py
index 0ca3a0680..10b1be6ce 100644
--- a/skyvern/client/types/url_block_parameters_item.py
+++ b/skyvern/client/types/url_block_parameters_item.py
@@ -183,6 +183,8 @@ class UrlBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/validation_block.py b/skyvern/client/types/validation_block.py
index 8b9869c65..aeb8a00ad 100644
--- a/skyvern/client/types/validation_block.py
+++ b/skyvern/client/types/validation_block.py
@@ -50,6 +50,7 @@ class ValidationBlock(UniversalBaseModel):
include_action_history_in_verification: typing.Optional[bool] = None
download_timeout: typing.Optional[float] = None
include_extracted_text: typing.Optional[bool] = None
+ without_page_information: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/validation_block_parameters_item.py b/skyvern/client/types/validation_block_parameters_item.py
index 05b929df4..778de767d 100644
--- a/skyvern/client/types/validation_block_parameters_item.py
+++ b/skyvern/client/types/validation_block_parameters_item.py
@@ -183,6 +183,8 @@ class ValidationBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/validation_block_yaml.py b/skyvern/client/types/validation_block_yaml.py
index ff9ba78a4..877a8fa46 100644
--- a/skyvern/client/types/validation_block_yaml.py
+++ b/skyvern/client/types/validation_block_yaml.py
@@ -26,6 +26,7 @@ class ValidationBlockYaml(UniversalBaseModel):
error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None
parameter_keys: typing.Optional[typing.List[str]] = None
disable_cache: typing.Optional[bool] = None
+ without_page_information: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/wait_block_parameters_item.py b/skyvern/client/types/wait_block_parameters_item.py
index 9529dba88..b50694eb7 100644
--- a/skyvern/client/types/wait_block_parameters_item.py
+++ b/skyvern/client/types/wait_block_parameters_item.py
@@ -183,6 +183,8 @@ class WaitBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/while_loop_block_loop_blocks_item.py b/skyvern/client/types/while_loop_block_loop_blocks_item.py
index af7560111..786dcf93a 100644
--- a/skyvern/client/types/while_loop_block_loop_blocks_item.py
+++ b/skyvern/client/types/while_loop_block_loop_blocks_item.py
@@ -14,6 +14,9 @@ from .ai_fallback_mode import AiFallbackMode
from .aws_secret_parameter import AwsSecretParameter
from .branch_condition import BranchCondition
from .code_block_parameters_item import CodeBlockParametersItem
+from .code_block_step import CodeBlockStep
+from .email_inbox_block_email_client import EmailInboxBlockEmailClient
+from .email_inbox_block_parameters_item import EmailInboxBlockParametersItem
from .extraction_block_data_schema import ExtractionBlockDataSchema
from .extraction_block_parameters_item import ExtractionBlockParametersItem
from .file_download_block_data_schema import FileDownloadBlockDataSchema
@@ -33,8 +36,11 @@ from .login_block_parameters_item import LoginBlockParametersItem
from .navigation_block_data_schema import NavigationBlockDataSchema
from .navigation_block_parameters_item import NavigationBlockParametersItem
from .output_parameter import OutputParameter
+from .pdf_fill_block_parameters_item import PdfFillBlockParametersItem
+from .pdf_fill_block_payload import PdfFillBlockPayload
from .print_page_block_parameters_item import PrintPageBlockParametersItem
from .run_engine import RunEngine
+from .split_pdf_block_parameters_item import SplitPdfBlockParametersItem
from .task_block_data_schema import TaskBlockDataSchema
from .task_block_parameters_item import TaskBlockParametersItem
from .text_prompt_block_parameters_item import TextPromptBlockParametersItem
@@ -103,6 +109,8 @@ class WhileLoopBlockLoopBlocksItem_Code(UniversalBaseModel):
next_loop_on_failure: typing.Optional[bool] = None
code: str
parameters: typing.Optional[typing.List[CodeBlockParametersItem]] = None
+ prompt: typing.Optional[str] = None
+ steps: typing.Optional[typing.List[CodeBlockStep]] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -158,6 +166,37 @@ class WhileLoopBlockLoopBlocksItem_DownloadToS3(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WhileLoopBlockLoopBlocksItem_EmailInbox(UniversalBaseModel):
+ block_type: typing.Literal["email_inbox"] = "email_inbox"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ email_client: EmailInboxBlockEmailClient
+ credential_id: typing.Optional[str] = None
+ folder: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
+ sender: typing.Optional[str] = None
+ subject: typing.Optional[str] = None
+ newer_than_days: typing.Optional[int] = None
+ max_results: typing.Optional[int] = None
+ include_body: typing.Optional[bool] = None
+ parameters: typing.Optional[typing.List[EmailInboxBlockParametersItem]] = 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 WhileLoopBlockLoopBlocksItem_Extraction(UniversalBaseModel):
block_type: typing.Literal["extraction"] = "extraction"
label: str
@@ -262,7 +301,17 @@ class WhileLoopBlockLoopBlocksItem_FileUpload(UniversalBaseModel):
azure_blob_container_name: typing.Optional[str] = None
google_credential_id: typing.Optional[str] = None
google_drive_folder_id: typing.Optional[str] = None
+ sftp_host: typing.Optional[str] = None
+ sftp_port: typing.Optional[int] = None
+ sftp_username: typing.Optional[str] = None
+ sftp_password: typing.Optional[str] = None
+ sftp_private_key: typing.Optional[str] = None
+ sftp_private_key_passphrase: typing.Optional[str] = None
+ sftp_remote_path: typing.Optional[str] = None
+ sftp_host_key: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
path: typing.Optional[str] = None
+ continue_on_empty: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -442,6 +491,7 @@ class WhileLoopBlockLoopBlocksItem_HttpRequest(UniversalBaseModel):
follow_redirects: typing.Optional[bool] = None
download_filename: typing.Optional[str] = None
save_response_as_file: typing.Optional[bool] = None
+ secret_response_paths: typing.Optional[typing.List[str]] = None
parameters: typing.Optional[typing.List[HttpRequestBlockParametersItem]] = None
if IS_PYDANTIC_V2:
@@ -589,6 +639,32 @@ class WhileLoopBlockLoopBlocksItem_Navigation(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WhileLoopBlockLoopBlocksItem_PdfFill(UniversalBaseModel):
+ block_type: typing.Literal["pdf_fill"] = "pdf_fill"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ payload: typing.Optional[PdfFillBlockPayload] = None
+ llm_key: typing.Optional[str] = None
+ parameters: typing.Optional[typing.List[PdfFillBlockParametersItem]] = 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 WhileLoopBlockLoopBlocksItem_PdfParser(UniversalBaseModel):
block_type: typing.Literal["pdf_parser"] = "pdf_parser"
label: str
@@ -669,6 +745,31 @@ class WhileLoopBlockLoopBlocksItem_SendEmail(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WhileLoopBlockLoopBlocksItem_SplitPdf(UniversalBaseModel):
+ block_type: typing.Literal["split_pdf"] = "split_pdf"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ llm_key: typing.Optional[str] = None
+ parameters: typing.Optional[typing.List[SplitPdfBlockParametersItem]] = 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 WhileLoopBlockLoopBlocksItem_Task(UniversalBaseModel):
block_type: typing.Literal["task"] = "task"
label: str
@@ -816,6 +917,7 @@ class WhileLoopBlockLoopBlocksItem_Validation(UniversalBaseModel):
include_action_history_in_verification: typing.Optional[bool] = None
download_timeout: typing.Optional[float] = None
include_extracted_text: typing.Optional[bool] = None
+ without_page_information: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -911,6 +1013,7 @@ WhileLoopBlockLoopBlocksItem = typing.Union[
WhileLoopBlockLoopBlocksItem_Code,
WhileLoopBlockLoopBlocksItem_Conditional,
WhileLoopBlockLoopBlocksItem_DownloadToS3,
+ WhileLoopBlockLoopBlocksItem_EmailInbox,
WhileLoopBlockLoopBlocksItem_Extraction,
WhileLoopBlockLoopBlocksItem_FileDownload,
WhileLoopBlockLoopBlocksItem_FileUpload,
@@ -923,9 +1026,11 @@ WhileLoopBlockLoopBlocksItem = typing.Union[
WhileLoopBlockLoopBlocksItem_HumanInteraction,
WhileLoopBlockLoopBlocksItem_Login,
WhileLoopBlockLoopBlocksItem_Navigation,
+ WhileLoopBlockLoopBlocksItem_PdfFill,
WhileLoopBlockLoopBlocksItem_PdfParser,
WhileLoopBlockLoopBlocksItem_PrintPage,
WhileLoopBlockLoopBlocksItem_SendEmail,
+ WhileLoopBlockLoopBlocksItem_SplitPdf,
WhileLoopBlockLoopBlocksItem_Task,
WhileLoopBlockLoopBlocksItem_TaskV2,
WhileLoopBlockLoopBlocksItem_TextPrompt,
@@ -939,6 +1044,7 @@ from .for_loop_block_loop_blocks_item import ForLoopBlockLoopBlocksItem # noqa:
update_forward_refs(WhileLoopBlockLoopBlocksItem_Action)
update_forward_refs(WhileLoopBlockLoopBlocksItem_Code)
+update_forward_refs(WhileLoopBlockLoopBlocksItem_EmailInbox)
update_forward_refs(WhileLoopBlockLoopBlocksItem_Extraction)
update_forward_refs(WhileLoopBlockLoopBlocksItem_FileDownload)
update_forward_refs(WhileLoopBlockLoopBlocksItem_ForLoop)
@@ -949,7 +1055,9 @@ update_forward_refs(WhileLoopBlockLoopBlocksItem_HttpRequest)
update_forward_refs(WhileLoopBlockLoopBlocksItem_HumanInteraction)
update_forward_refs(WhileLoopBlockLoopBlocksItem_Login)
update_forward_refs(WhileLoopBlockLoopBlocksItem_Navigation)
+update_forward_refs(WhileLoopBlockLoopBlocksItem_PdfFill)
update_forward_refs(WhileLoopBlockLoopBlocksItem_PrintPage)
+update_forward_refs(WhileLoopBlockLoopBlocksItem_SplitPdf)
update_forward_refs(WhileLoopBlockLoopBlocksItem_Task)
update_forward_refs(WhileLoopBlockLoopBlocksItem_TextPrompt)
update_forward_refs(WhileLoopBlockLoopBlocksItem_Validation)
diff --git a/skyvern/client/types/while_loop_block_yaml_loop_blocks_item.py b/skyvern/client/types/while_loop_block_yaml_loop_blocks_item.py
index 19604a1fc..aa16928cb 100644
--- a/skyvern/client/types/while_loop_block_yaml_loop_blocks_item.py
+++ b/skyvern/client/types/while_loop_block_yaml_loop_blocks_item.py
@@ -11,11 +11,14 @@ from ..core.serialization import FieldMetadata
from .ai_fallback_mode import AiFallbackMode
from .branch_condition_yaml import BranchConditionYaml
from .branch_criteria_yaml import BranchCriteriaYaml
+from .code_block_step_yaml import CodeBlockStepYaml
+from .email_inbox_block_yaml_email_client import EmailInboxBlockYamlEmailClient
from .extraction_block_yaml_data_schema import ExtractionBlockYamlDataSchema
from .file_storage_type import FileStorageType
from .file_type import FileType
from .for_loop_block_yaml_data_schema import ForLoopBlockYamlDataSchema
from .google_sheets_write_block_yaml_write_mode import GoogleSheetsWriteBlockYamlWriteMode
+from .pdf_fill_block_yaml_payload import PdfFillBlockYamlPayload
from .pdf_format import PdfFormat
from .run_engine import RunEngine
from .task_block_yaml_data_schema import TaskBlockYamlDataSchema
@@ -118,6 +121,8 @@ class WhileLoopBlockYamlLoopBlocksItem_Code(UniversalBaseModel):
next_loop_on_failure: typing.Optional[bool] = None
code: str
parameter_keys: typing.Optional[typing.List[str]] = None
+ prompt: typing.Optional[str] = None
+ steps: typing.Optional[typing.List[CodeBlockStepYaml]] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -211,6 +216,15 @@ class WhileLoopBlockYamlLoopBlocksItem_FileUpload(UniversalBaseModel):
azure_folder_path: typing.Optional[str] = None
google_credential_id: typing.Optional[str] = None
google_drive_folder_id: typing.Optional[str] = None
+ sftp_host: typing.Optional[str] = None
+ sftp_port: typing.Optional[int] = None
+ sftp_username: typing.Optional[str] = None
+ sftp_password: typing.Optional[str] = None
+ sftp_private_key: typing.Optional[str] = None
+ sftp_private_key_passphrase: typing.Optional[str] = None
+ sftp_remote_path: typing.Optional[str] = None
+ sftp_host_key: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
path: typing.Optional[str] = None
if IS_PYDANTIC_V2:
@@ -286,6 +300,7 @@ class WhileLoopBlockYamlLoopBlocksItem_Validation(UniversalBaseModel):
error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None
parameter_keys: typing.Optional[typing.List[str]] = None
disable_cache: typing.Optional[bool] = None
+ without_page_information: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -591,6 +606,7 @@ class WhileLoopBlockYamlLoopBlocksItem_HttpRequest(UniversalBaseModel):
follow_redirects: typing.Optional[bool] = None
download_filename: typing.Optional[str] = None
save_response_as_file: typing.Optional[bool] = None
+ secret_response_paths: typing.Optional[typing.List[str]] = None
parameter_keys: typing.Optional[typing.List[str]] = None
if IS_PYDANTIC_V2:
@@ -648,6 +664,53 @@ class WhileLoopBlockYamlLoopBlocksItem_PrintPage(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WhileLoopBlockYamlLoopBlocksItem_PdfFill(UniversalBaseModel):
+ block_type: typing.Literal["pdf_fill"] = "pdf_fill"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ payload: typing.Optional[PdfFillBlockYamlPayload] = None
+ llm_key: typing.Optional[str] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
+class WhileLoopBlockYamlLoopBlocksItem_SplitPdf(UniversalBaseModel):
+ block_type: typing.Literal["split_pdf"] = "split_pdf"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ llm_key: typing.Optional[str] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class WhileLoopBlockYamlLoopBlocksItem_WorkflowTrigger(UniversalBaseModel):
block_type: typing.Literal["workflow_trigger"] = "workflow_trigger"
label: str
@@ -698,6 +761,35 @@ class WhileLoopBlockYamlLoopBlocksItem_GoogleSheetsRead(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WhileLoopBlockYamlLoopBlocksItem_EmailInbox(UniversalBaseModel):
+ block_type: typing.Literal["email_inbox"] = "email_inbox"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ email_client: EmailInboxBlockYamlEmailClient
+ credential_id: typing.Optional[str] = None
+ folder: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
+ sender: typing.Optional[str] = None
+ subject: typing.Optional[str] = None
+ newer_than_days: typing.Optional[int] = None
+ max_results: typing.Optional[int] = None
+ include_body: typing.Optional[bool] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class WhileLoopBlockYamlLoopBlocksItem_GoogleSheetsWrite(UniversalBaseModel):
block_type: typing.Literal["google_sheets_write"] = "google_sheets_write"
label: str
@@ -751,8 +843,11 @@ WhileLoopBlockYamlLoopBlocksItem = typing.Union[
WhileLoopBlockYamlLoopBlocksItem_HttpRequest,
WhileLoopBlockYamlLoopBlocksItem_Conditional,
WhileLoopBlockYamlLoopBlocksItem_PrintPage,
+ WhileLoopBlockYamlLoopBlocksItem_PdfFill,
+ WhileLoopBlockYamlLoopBlocksItem_SplitPdf,
WhileLoopBlockYamlLoopBlocksItem_WorkflowTrigger,
WhileLoopBlockYamlLoopBlocksItem_GoogleSheetsRead,
+ WhileLoopBlockYamlLoopBlocksItem_EmailInbox,
WhileLoopBlockYamlLoopBlocksItem_GoogleSheetsWrite,
]
from .for_loop_block_yaml_loop_blocks_item import ForLoopBlockYamlLoopBlocksItem # noqa: E402, F401, I001
diff --git a/skyvern/client/types/workflow.py b/skyvern/client/types/workflow.py
index 607fbc0bc..7c262cebb 100644
--- a/skyvern/client/types/workflow.py
+++ b/skyvern/client/types/workflow.py
@@ -29,6 +29,7 @@ class Workflow(UniversalBaseModel):
persist_browser_session: typing.Optional[bool] = None
pin_saved_session_ip: typing.Optional[bool] = None
browser_profile_id: typing.Optional[str] = None
+ browser_profile_key: typing.Optional[str] = None
model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
status: typing.Optional[WorkflowStatus] = None
max_screenshot_scrolls: typing.Optional[int] = None
@@ -39,6 +40,7 @@ class Workflow(UniversalBaseModel):
ai_fallback: typing.Optional[bool] = None
cache_key: typing.Optional[str] = None
adaptive_caching: typing.Optional[bool] = None
+ enable_self_healing: typing.Optional[bool] = None
code_version: typing.Optional[int] = None
generate_script_on_terminal: typing.Optional[bool] = None
run_sequentially: typing.Optional[bool] = None
@@ -47,6 +49,7 @@ class Workflow(UniversalBaseModel):
import_error: typing.Optional[str] = None
created_by: typing.Optional[str] = None
edited_by: typing.Optional[str] = None
+ copilot_authored: typing.Optional[bool] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/workflow_create_yaml_request.py b/skyvern/client/types/workflow_create_yaml_request.py
index 91c2cba64..95e0b042e 100644
--- a/skyvern/client/types/workflow_create_yaml_request.py
+++ b/skyvern/client/types/workflow_create_yaml_request.py
@@ -21,6 +21,7 @@ class WorkflowCreateYamlRequest(UniversalBaseModel):
persist_browser_session: typing.Optional[bool] = None
pin_saved_session_ip: typing.Optional[bool] = None
browser_profile_id: typing.Optional[str] = None
+ browser_profile_key: typing.Optional[str] = None
model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
workflow_definition: WorkflowDefinitionYaml
is_saved_task: typing.Optional[bool] = None
@@ -33,6 +34,7 @@ class WorkflowCreateYamlRequest(UniversalBaseModel):
ai_fallback: typing.Optional[bool] = None
cache_key: typing.Optional[str] = None
adaptive_caching: typing.Optional[bool] = None
+ enable_self_healing: typing.Optional[bool] = None
code_version: typing.Optional[int] = None
generate_script_on_terminal: typing.Optional[bool] = None
run_sequentially: typing.Optional[bool] = None
diff --git a/skyvern/client/types/workflow_definition_blocks_item.py b/skyvern/client/types/workflow_definition_blocks_item.py
index 795384696..e0d034a5b 100644
--- a/skyvern/client/types/workflow_definition_blocks_item.py
+++ b/skyvern/client/types/workflow_definition_blocks_item.py
@@ -14,6 +14,9 @@ from .ai_fallback_mode import AiFallbackMode
from .aws_secret_parameter import AwsSecretParameter
from .branch_condition import BranchCondition
from .code_block_parameters_item import CodeBlockParametersItem
+from .code_block_step import CodeBlockStep
+from .email_inbox_block_email_client import EmailInboxBlockEmailClient
+from .email_inbox_block_parameters_item import EmailInboxBlockParametersItem
from .extraction_block_data_schema import ExtractionBlockDataSchema
from .extraction_block_parameters_item import ExtractionBlockParametersItem
from .file_download_block_data_schema import FileDownloadBlockDataSchema
@@ -33,8 +36,11 @@ from .login_block_parameters_item import LoginBlockParametersItem
from .navigation_block_data_schema import NavigationBlockDataSchema
from .navigation_block_parameters_item import NavigationBlockParametersItem
from .output_parameter import OutputParameter
+from .pdf_fill_block_parameters_item import PdfFillBlockParametersItem
+from .pdf_fill_block_payload import PdfFillBlockPayload
from .print_page_block_parameters_item import PrintPageBlockParametersItem
from .run_engine import RunEngine
+from .split_pdf_block_parameters_item import SplitPdfBlockParametersItem
from .task_block_data_schema import TaskBlockDataSchema
from .task_block_parameters_item import TaskBlockParametersItem
from .text_prompt_block_parameters_item import TextPromptBlockParametersItem
@@ -103,6 +109,8 @@ class WorkflowDefinitionBlocksItem_Code(UniversalBaseModel):
next_loop_on_failure: typing.Optional[bool] = None
code: str
parameters: typing.Optional[typing.List[CodeBlockParametersItem]] = None
+ prompt: typing.Optional[str] = None
+ steps: typing.Optional[typing.List[CodeBlockStep]] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -158,6 +166,37 @@ class WorkflowDefinitionBlocksItem_DownloadToS3(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WorkflowDefinitionBlocksItem_EmailInbox(UniversalBaseModel):
+ block_type: typing.Literal["email_inbox"] = "email_inbox"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ email_client: EmailInboxBlockEmailClient
+ credential_id: typing.Optional[str] = None
+ folder: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
+ sender: typing.Optional[str] = None
+ subject: typing.Optional[str] = None
+ newer_than_days: typing.Optional[int] = None
+ max_results: typing.Optional[int] = None
+ include_body: typing.Optional[bool] = None
+ parameters: typing.Optional[typing.List[EmailInboxBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class WorkflowDefinitionBlocksItem_Extraction(UniversalBaseModel):
block_type: typing.Literal["extraction"] = "extraction"
label: str
@@ -262,7 +301,17 @@ class WorkflowDefinitionBlocksItem_FileUpload(UniversalBaseModel):
azure_blob_container_name: typing.Optional[str] = None
google_credential_id: typing.Optional[str] = None
google_drive_folder_id: typing.Optional[str] = None
+ sftp_host: typing.Optional[str] = None
+ sftp_port: typing.Optional[int] = None
+ sftp_username: typing.Optional[str] = None
+ sftp_password: typing.Optional[str] = None
+ sftp_private_key: typing.Optional[str] = None
+ sftp_private_key_passphrase: typing.Optional[str] = None
+ sftp_remote_path: typing.Optional[str] = None
+ sftp_host_key: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
path: typing.Optional[str] = None
+ continue_on_empty: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -445,6 +494,7 @@ class WorkflowDefinitionBlocksItem_HttpRequest(UniversalBaseModel):
follow_redirects: typing.Optional[bool] = None
download_filename: typing.Optional[str] = None
save_response_as_file: typing.Optional[bool] = None
+ secret_response_paths: typing.Optional[typing.List[str]] = None
parameters: typing.Optional[typing.List[HttpRequestBlockParametersItem]] = None
if IS_PYDANTIC_V2:
@@ -592,6 +642,32 @@ class WorkflowDefinitionBlocksItem_Navigation(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WorkflowDefinitionBlocksItem_PdfFill(UniversalBaseModel):
+ block_type: typing.Literal["pdf_fill"] = "pdf_fill"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ payload: typing.Optional[PdfFillBlockPayload] = None
+ llm_key: typing.Optional[str] = None
+ parameters: typing.Optional[typing.List[PdfFillBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class WorkflowDefinitionBlocksItem_PdfParser(UniversalBaseModel):
block_type: typing.Literal["pdf_parser"] = "pdf_parser"
label: str
@@ -672,6 +748,31 @@ class WorkflowDefinitionBlocksItem_SendEmail(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WorkflowDefinitionBlocksItem_SplitPdf(UniversalBaseModel):
+ block_type: typing.Literal["split_pdf"] = "split_pdf"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ output_parameter: OutputParameter
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ disable_cache: typing.Optional[bool] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ llm_key: typing.Optional[str] = None
+ parameters: typing.Optional[typing.List[SplitPdfBlockParametersItem]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class WorkflowDefinitionBlocksItem_Task(UniversalBaseModel):
block_type: typing.Literal["task"] = "task"
label: str
@@ -819,6 +920,7 @@ class WorkflowDefinitionBlocksItem_Validation(UniversalBaseModel):
include_action_history_in_verification: typing.Optional[bool] = None
download_timeout: typing.Optional[float] = None
include_extracted_text: typing.Optional[bool] = None
+ without_page_information: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -915,6 +1017,7 @@ WorkflowDefinitionBlocksItem = typing.Union[
WorkflowDefinitionBlocksItem_Code,
WorkflowDefinitionBlocksItem_Conditional,
WorkflowDefinitionBlocksItem_DownloadToS3,
+ WorkflowDefinitionBlocksItem_EmailInbox,
WorkflowDefinitionBlocksItem_Extraction,
WorkflowDefinitionBlocksItem_FileDownload,
WorkflowDefinitionBlocksItem_FileUpload,
@@ -927,9 +1030,11 @@ WorkflowDefinitionBlocksItem = typing.Union[
WorkflowDefinitionBlocksItem_HumanInteraction,
WorkflowDefinitionBlocksItem_Login,
WorkflowDefinitionBlocksItem_Navigation,
+ WorkflowDefinitionBlocksItem_PdfFill,
WorkflowDefinitionBlocksItem_PdfParser,
WorkflowDefinitionBlocksItem_PrintPage,
WorkflowDefinitionBlocksItem_SendEmail,
+ WorkflowDefinitionBlocksItem_SplitPdf,
WorkflowDefinitionBlocksItem_Task,
WorkflowDefinitionBlocksItem_TaskV2,
WorkflowDefinitionBlocksItem_TextPrompt,
@@ -941,6 +1046,7 @@ WorkflowDefinitionBlocksItem = typing.Union[
]
update_forward_refs(WorkflowDefinitionBlocksItem_Action)
update_forward_refs(WorkflowDefinitionBlocksItem_Code)
+update_forward_refs(WorkflowDefinitionBlocksItem_EmailInbox)
update_forward_refs(WorkflowDefinitionBlocksItem_Extraction)
update_forward_refs(WorkflowDefinitionBlocksItem_FileDownload)
update_forward_refs(WorkflowDefinitionBlocksItem_ForLoop)
@@ -951,7 +1057,9 @@ update_forward_refs(WorkflowDefinitionBlocksItem_HttpRequest)
update_forward_refs(WorkflowDefinitionBlocksItem_HumanInteraction)
update_forward_refs(WorkflowDefinitionBlocksItem_Login)
update_forward_refs(WorkflowDefinitionBlocksItem_Navigation)
+update_forward_refs(WorkflowDefinitionBlocksItem_PdfFill)
update_forward_refs(WorkflowDefinitionBlocksItem_PrintPage)
+update_forward_refs(WorkflowDefinitionBlocksItem_SplitPdf)
update_forward_refs(WorkflowDefinitionBlocksItem_Task)
update_forward_refs(WorkflowDefinitionBlocksItem_TextPrompt)
update_forward_refs(WorkflowDefinitionBlocksItem_Validation)
diff --git a/skyvern/client/types/workflow_definition_parameters_item.py b/skyvern/client/types/workflow_definition_parameters_item.py
index a2cf40f66..527152aca 100644
--- a/skyvern/client/types/workflow_definition_parameters_item.py
+++ b/skyvern/client/types/workflow_definition_parameters_item.py
@@ -183,6 +183,8 @@ class WorkflowDefinitionParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/skyvern/client/types/workflow_definition_yaml_blocks_item.py b/skyvern/client/types/workflow_definition_yaml_blocks_item.py
index 19a3b6065..0bb983812 100644
--- a/skyvern/client/types/workflow_definition_yaml_blocks_item.py
+++ b/skyvern/client/types/workflow_definition_yaml_blocks_item.py
@@ -11,11 +11,14 @@ from ..core.serialization import FieldMetadata
from .ai_fallback_mode import AiFallbackMode
from .branch_condition_yaml import BranchConditionYaml
from .branch_criteria_yaml import BranchCriteriaYaml
+from .code_block_step_yaml import CodeBlockStepYaml
+from .email_inbox_block_yaml_email_client import EmailInboxBlockYamlEmailClient
from .extraction_block_yaml_data_schema import ExtractionBlockYamlDataSchema
from .file_storage_type import FileStorageType
from .file_type import FileType
from .for_loop_block_yaml_data_schema import ForLoopBlockYamlDataSchema
from .google_sheets_write_block_yaml_write_mode import GoogleSheetsWriteBlockYamlWriteMode
+from .pdf_fill_block_yaml_payload import PdfFillBlockYamlPayload
from .pdf_format import PdfFormat
from .run_engine import RunEngine
from .task_block_yaml_data_schema import TaskBlockYamlDataSchema
@@ -64,6 +67,8 @@ class WorkflowDefinitionYamlBlocksItem_Code(UniversalBaseModel):
next_loop_on_failure: typing.Optional[bool] = None
code: str
parameter_keys: typing.Optional[typing.List[str]] = None
+ prompt: typing.Optional[str] = None
+ steps: typing.Optional[typing.List[CodeBlockStepYaml]] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -115,6 +120,35 @@ class WorkflowDefinitionYamlBlocksItem_DownloadToS3(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WorkflowDefinitionYamlBlocksItem_EmailInbox(UniversalBaseModel):
+ block_type: typing.Literal["email_inbox"] = "email_inbox"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ email_client: EmailInboxBlockYamlEmailClient
+ credential_id: typing.Optional[str] = None
+ folder: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
+ sender: typing.Optional[str] = None
+ subject: typing.Optional[str] = None
+ newer_than_days: typing.Optional[int] = None
+ max_results: typing.Optional[int] = None
+ include_body: typing.Optional[bool] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class WorkflowDefinitionYamlBlocksItem_Extraction(UniversalBaseModel):
block_type: typing.Literal["extraction"] = "extraction"
label: str
@@ -194,6 +228,15 @@ class WorkflowDefinitionYamlBlocksItem_FileUpload(UniversalBaseModel):
azure_folder_path: typing.Optional[str] = None
google_credential_id: typing.Optional[str] = None
google_drive_folder_id: typing.Optional[str] = None
+ sftp_host: typing.Optional[str] = None
+ sftp_port: typing.Optional[int] = None
+ sftp_username: typing.Optional[str] = None
+ sftp_password: typing.Optional[str] = None
+ sftp_private_key: typing.Optional[str] = None
+ sftp_private_key_passphrase: typing.Optional[str] = None
+ sftp_remote_path: typing.Optional[str] = None
+ sftp_host_key: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
path: typing.Optional[str] = None
if IS_PYDANTIC_V2:
@@ -345,6 +388,7 @@ class WorkflowDefinitionYamlBlocksItem_HttpRequest(UniversalBaseModel):
follow_redirects: typing.Optional[bool] = None
download_filename: typing.Optional[str] = None
save_response_as_file: typing.Optional[bool] = None
+ secret_response_paths: typing.Optional[typing.List[str]] = None
parameter_keys: typing.Optional[typing.List[str]] = None
if IS_PYDANTIC_V2:
@@ -454,6 +498,30 @@ class WorkflowDefinitionYamlBlocksItem_Navigation(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WorkflowDefinitionYamlBlocksItem_PdfFill(UniversalBaseModel):
+ block_type: typing.Literal["pdf_fill"] = "pdf_fill"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ payload: typing.Optional[PdfFillBlockYamlPayload] = None
+ llm_key: typing.Optional[str] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class WorkflowDefinitionYamlBlocksItem_PdfParser(UniversalBaseModel):
block_type: typing.Literal["pdf_parser"] = "pdf_parser"
label: str
@@ -528,6 +596,29 @@ class WorkflowDefinitionYamlBlocksItem_SendEmail(UniversalBaseModel):
extra = pydantic.Extra.allow
+class WorkflowDefinitionYamlBlocksItem_SplitPdf(UniversalBaseModel):
+ block_type: typing.Literal["split_pdf"] = "split_pdf"
+ label: str
+ next_block_label: typing.Optional[str] = None
+ continue_on_failure: typing.Optional[bool] = None
+ model: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = None
+ ignore_workflow_system_prompt: typing.Optional[bool] = None
+ next_loop_on_failure: typing.Optional[bool] = None
+ file_url: str
+ prompt: str
+ llm_key: typing.Optional[str] = None
+ parameter_keys: typing.Optional[typing.List[str]] = None
+
+ if IS_PYDANTIC_V2:
+ model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
+ else:
+
+ class Config:
+ frozen = True
+ smart_union = True
+ extra = pydantic.Extra.allow
+
+
class WorkflowDefinitionYamlBlocksItem_Task(UniversalBaseModel):
block_type: typing.Literal["task"] = "task"
label: str
@@ -648,6 +739,7 @@ class WorkflowDefinitionYamlBlocksItem_Validation(UniversalBaseModel):
error_code_mapping: typing.Optional[typing.Dict[str, typing.Optional[str]]] = None
parameter_keys: typing.Optional[typing.List[str]] = None
disable_cache: typing.Optional[bool] = None
+ without_page_information: typing.Optional[bool] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
@@ -735,6 +827,7 @@ WorkflowDefinitionYamlBlocksItem = typing.Union[
WorkflowDefinitionYamlBlocksItem_Code,
WorkflowDefinitionYamlBlocksItem_Conditional,
WorkflowDefinitionYamlBlocksItem_DownloadToS3,
+ WorkflowDefinitionYamlBlocksItem_EmailInbox,
WorkflowDefinitionYamlBlocksItem_Extraction,
WorkflowDefinitionYamlBlocksItem_FileDownload,
WorkflowDefinitionYamlBlocksItem_FileUpload,
@@ -747,9 +840,11 @@ WorkflowDefinitionYamlBlocksItem = typing.Union[
WorkflowDefinitionYamlBlocksItem_HumanInteraction,
WorkflowDefinitionYamlBlocksItem_Login,
WorkflowDefinitionYamlBlocksItem_Navigation,
+ WorkflowDefinitionYamlBlocksItem_PdfFill,
WorkflowDefinitionYamlBlocksItem_PdfParser,
WorkflowDefinitionYamlBlocksItem_PrintPage,
WorkflowDefinitionYamlBlocksItem_SendEmail,
+ WorkflowDefinitionYamlBlocksItem_SplitPdf,
WorkflowDefinitionYamlBlocksItem_Task,
WorkflowDefinitionYamlBlocksItem_TaskV2,
WorkflowDefinitionYamlBlocksItem_TextPrompt,
diff --git a/skyvern/client/types/workflow_definition_yaml_parameters_item.py b/skyvern/client/types/workflow_definition_yaml_parameters_item.py
index 35603ba6d..2363b0275 100644
--- a/skyvern/client/types/workflow_definition_yaml_parameters_item.py
+++ b/skyvern/client/types/workflow_definition_yaml_parameters_item.py
@@ -128,6 +128,8 @@ class WorkflowDefinitionYamlParametersItem_Credential(UniversalBaseModel):
key: str
description: typing.Optional[str] = None
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/workflow_run_block.py b/skyvern/client/types/workflow_run_block.py
index 22d32371b..efeeb32d6 100644
--- a/skyvern/client/types/workflow_run_block.py
+++ b/skyvern/client/types/workflow_run_block.py
@@ -50,6 +50,7 @@ class WorkflowRunBlock(UniversalBaseModel):
attachments: typing.Optional[typing.List[str]] = None
subject: typing.Optional[str] = None
body: typing.Optional[str] = None
+ prompt: typing.Optional[str] = None
instructions: typing.Optional[str] = None
positive_descriptor: typing.Optional[str] = None
negative_descriptor: typing.Optional[str] = None
@@ -58,6 +59,7 @@ class WorkflowRunBlock(UniversalBaseModel):
executed_branch_result: typing.Optional[bool] = None
executed_branch_next_block: typing.Optional[str] = None
script_run: typing.Optional[ScriptRunResponse] = None
+ downloaded_file_count: typing.Optional[int] = None
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
diff --git a/skyvern/client/types/workflow_trigger_block_parameters_item.py b/skyvern/client/types/workflow_trigger_block_parameters_item.py
index 73d1ff539..1eef7f270 100644
--- a/skyvern/client/types/workflow_trigger_block_parameters_item.py
+++ b/skyvern/client/types/workflow_trigger_block_parameters_item.py
@@ -183,6 +183,8 @@ class WorkflowTriggerBlockParametersItem_Credential(UniversalBaseModel):
credential_parameter_id: str
workflow_id: str
credential_id: str
+ credential_ids: typing.Optional[typing.List[str]] = None
+ selection_strategy: typing.Optional[str] = None
created_at: dt.datetime
modified_at: dt.datetime
deleted_at: typing.Optional[dt.datetime] = None
diff --git a/tests/unit/test_mcp_block_type_parity.py b/tests/unit/test_mcp_block_type_parity.py
index 99d8bb925..7f54a23ad 100644
--- a/tests/unit/test_mcp_block_type_parity.py
+++ b/tests/unit/test_mcp_block_type_parity.py
@@ -95,27 +95,9 @@ class BlockDriftEntry:
# the vendored Fern SDK. Run `fern generate` using the Skyvern Cloud-only
# runbook to resync, then remove the entry here.
_KNOWN_DRIFT_ALLOWLIST: tuple[BlockDriftEntry, ...] = (
- BlockDriftEntry(
- block_type="pdf_fill",
- ticket="SKY-10944",
- owner="@suchintan",
- added_at=date(2026, 6, 11),
- notes="Fern SDK regen happens via CI post-deploy",
- ),
- BlockDriftEntry(
- block_type="split_pdf",
- ticket="SKY-12071",
- owner="@suchintan",
- added_at=date(2026, 7, 8),
- notes="Fern SDK regen happens via CI post-deploy",
- ),
- BlockDriftEntry(
- block_type="email_inbox",
- ticket="SKY-12068",
- owner="@suchintan",
- added_at=date(2026, 7, 8),
- notes="Fern SDK regen happens via CI post-deploy",
- ),
+ # Empty: pdf_fill (SKY-10944), split_pdf (SKY-12071), and email_inbox
+ # (SKY-12068) were resolved by the Fern SDK regen in the 1.0.47 bump — all
+ # three now appear in both WorkflowDefinition(Yaml)BlocksItem unions.
)
diff --git a/uv.lock b/uv.lock
index 659a625da..d4eba5a96 100644
--- a/uv.lock
+++ b/uv.lock
@@ -5797,7 +5797,7 @@ wheels = [
[[package]]
name = "skyvern"
-version = "1.0.46"
+version = "1.0.47"
source = { editable = "." }
dependencies = [
{ name = "cachetools" },