Skip to content

Automate browser based workflows with AI

[SKY-7600] Readd FE (#5332)

Aaron Perez5b321fa747b9
diff --git a/docs/docs.json b/docs/docs.json
index 8a9fe2353..f93ce29ab 100644
--- a/docs/docs.json
+++ b/docs/docs.json
@@ -55,6 +55,71 @@
}
]
},
+ {
+ "tab": "Developers",
+ "groups": [
+ {
+ "group": "Running Automations",
+ "pages": [
+ "running-automations/run-a-task",
+ "running-automations/task-parameters",
+ "running-automations/extract-structured-data"
+ ]
+ },
+ {
+ "group": "Multi-Step Automations",
+ "pages": [
+ "multi-step-automations/build-a-workflow",
+ "multi-step-automations/workflow-blocks-reference",
+ "multi-step-automations/file-operations",
+ "multi-step-automations/workflow-parameters",
+ "multi-step-automations/scheduling-workflows"
+ ]
+ },
+ {
+ "group": "Optimization",
+ "pages": [
+ "optimization/browser-sessions",
+ "optimization/browser-profiles",
+ "optimization/cost-control"
+ ]
+ },
+ {
+ "group": "Going to Production",
+ "pages": [
+ "going-to-production/webhooks",
+ "going-to-production/proxy-geolocation",
+ "going-to-production/error-handling",
+ "going-to-production/reliability-tips",
+ "going-to-production/captcha-bot-detection",
+ "integrations/mcp",
+ "integrations/cli"
+ ]
+ },
+ {
+ "group": "Debugging",
+ "pages": [
+ "debugging/using-artifacts",
+ "debugging/troubleshooting-guide",
+ "debugging/observability-with-laminar",
+ "debugging/faq"
+ ]
+ },
+ {
+ "group": "Self-Hosted Deployment",
+ "pages": [
+ "self-hosted/overview",
+ "self-hosted/docker",
+ "self-hosted/llm-configuration",
+ "self-hosted/browser",
+ "self-hosted/proxy",
+ "self-hosted/kubernetes",
+ "self-hosted/storage",
+ "integrations/local-llms"
+ ]
+ }
+ ]
+ },
{
"tab": "Cloud UI",
"groups": [
@@ -123,71 +188,6 @@
}
]
},
- {
- "tab": "Developers",
- "groups": [
- {
- "group": "Running Automations",
- "pages": [
- "running-automations/run-a-task",
- "running-automations/task-parameters",
- "running-automations/extract-structured-data"
- ]
- },
- {
- "group": "Multi-Step Automations",
- "pages": [
- "multi-step-automations/build-a-workflow",
- "multi-step-automations/workflow-blocks-reference",
- "multi-step-automations/file-operations",
- "multi-step-automations/workflow-parameters",
- "multi-step-automations/scheduling-workflows"
- ]
- },
- {
- "group": "Optimization",
- "pages": [
- "optimization/browser-sessions",
- "optimization/browser-profiles",
- "optimization/cost-control"
- ]
- },
- {
- "group": "Going to Production",
- "pages": [
- "going-to-production/webhooks",
- "going-to-production/proxy-geolocation",
- "going-to-production/error-handling",
- "going-to-production/reliability-tips",
- "going-to-production/captcha-bot-detection",
- "integrations/mcp",
- "integrations/cli"
- ]
- },
- {
- "group": "Debugging",
- "pages": [
- "debugging/using-artifacts",
- "debugging/troubleshooting-guide",
- "debugging/observability-with-laminar",
- "debugging/faq"
- ]
- },
- {
- "group": "Self-Hosted Deployment",
- "pages": [
- "self-hosted/overview",
- "self-hosted/docker",
- "self-hosted/llm-configuration",
- "self-hosted/browser",
- "self-hosted/proxy",
- "self-hosted/kubernetes",
- "self-hosted/storage",
- "integrations/local-llms"
- ]
- }
- ]
- },
{
"tab": "Cookbooks",
"pages": [
@@ -414,146 +414,6 @@
{
"source": "/integrations/ollama-litellm",
"destination": "/integrations/local-llms"
- },
- {
- "source": "/api-reference/api-reference/agent/run-task",
- "destination": "/api-reference/agent/run-a-task"
- },
- {
- "source": "/api-reference/api-reference/agent/get-run",
- "destination": "/api-reference/agent/get-a-run-by-id"
- },
- {
- "source": "/api-reference/api-reference/agent/cancel-run",
- "destination": "/api-reference/agent/cancel-a-run-by-id"
- },
- {
- "source": "/api-reference/api-reference/agent/retry-run-webhook",
- "destination": "/api-reference/agent/retry-run-webhook"
- },
- {
- "source": "/api-reference/api-reference/agent/login",
- "destination": "/api-reference/agent/login-task"
- },
- {
- "source": "/api-reference/api-reference/agent/get-run-timeline",
- "destination": "/api-reference/agent/get-run-timeline"
- },
- {
- "source": "/api-reference/api-reference/workflows/get-workflows",
- "destination": "/api-reference/workflows/get-workflows"
- },
- {
- "source": "/api-reference/api-reference/workflows/create-workflow",
- "destination": "/api-reference/workflows/create-a-new-workflow"
- },
- {
- "source": "/api-reference/api-reference/workflows/get-workflow",
- "destination": "/api-reference/workflows/get-workflows"
- },
- {
- "source": "/api-reference/api-reference/workflows/get-workflow-versions",
- "destination": "/api-reference/workflows/get-workflows"
- },
- {
- "source": "/api-reference/api-reference/workflows/update-workflow",
- "destination": "/api-reference/workflows/update-a-workflow"
- },
- {
- "source": "/api-reference/api-reference/workflows/delete-workflow",
- "destination": "/api-reference/workflows/delete-a-workflow"
- },
- {
- "source": "/api-reference/api-reference/workflow-runs/run-workflow",
- "destination": "/api-reference/workflows/run-a-workflow"
- },
- {
- "source": "/api-reference/api-reference/workflow-runs/get-workflow-runs",
- "destination": "/api-reference/workflows/get-workflows"
- },
- {
- "source": "/api-reference/api-reference/workflow-runs/get-run",
- "destination": "/api-reference/agent/get-a-run-by-id"
- },
- {
- "source": "/api-reference/api-reference/workflow-runs/cancel-run",
- "destination": "/api-reference/agent/cancel-a-run-by-id"
- },
- {
- "source": "/api-reference/api-reference/workflow-runs/retry-run-webhook",
- "destination": "/api-reference/agent/retry-run-webhook"
- },
- {
- "source": "/api-reference/api-reference/workflow-runs/get-run-timeline",
- "destination": "/api-reference/agent/get-run-timeline"
- },
- {
- "source": "/api-reference/api-reference/browser-sessions/create-browser-session",
- "destination": "/api-reference/browser-sessions/create-a-session"
- },
- {
- "source": "/api-reference/api-reference/browser-sessions/get-browser-session",
- "destination": "/api-reference/browser-sessions/get-a-session"
- },
- {
- "source": "/api-reference/api-reference/browser-sessions/close-browser-session",
- "destination": "/api-reference/browser-sessions/close-a-session"
- },
- {
- "source": "/api-reference/api-reference/browser-sessions/get-browser-sessions",
- "destination": "/api-reference/browser-sessions/get-active-browser-sessions"
- },
- {
- "source": "/api-reference/api-reference/browser-profiles/create-browser-profile",
- "destination": "/api-reference/browser-profiles/create-a-browser-profile"
- },
- {
- "source": "/api-reference/api-reference/browser-profiles/list-browser-profiles",
- "destination": "/api-reference/browser-profiles/list-browser-profiles"
- },
- {
- "source": "/api-reference/api-reference/browser-profiles/get-browser-profile",
- "destination": "/api-reference/browser-profiles/get-browser-profile"
- },
- {
- "source": "/api-reference/api-reference/browser-profiles/delete-browser-profile",
- "destination": "/api-reference/browser-profiles/delete-browser-profile"
- },
- {
- "source": "/api-reference/api-reference/credentials/create-credential",
- "destination": "/api-reference/credentials/create-credential"
- },
- {
- "source": "/api-reference/api-reference/credentials/get-credential",
- "destination": "/api-reference/credentials/get-credential-by-id"
- },
- {
- "source": "/api-reference/api-reference/credentials/update-credential",
- "destination": "/api-reference/credentials/create-credential"
- },
- {
- "source": "/api-reference/api-reference/credentials/delete-credential",
- "destination": "/api-reference/credentials/delete-credential"
- },
- {
- "source": "/api-reference/api-reference/credentials/get-credentials",
- "destination": "/api-reference/credentials/get-all-credentials"
- },
- {
- "source": "/api-reference/api-reference/credentials/send-totp-code",
- "destination": "/api-reference/credentials/send-totp-code"
- },
- {
- "source": "/api-reference/api-reference/artifacts/get-run-artifacts",
- "destination": "/api-reference/artifacts/get-artifacts-for-a-run"
- },
- {
- "source": "/api-reference/api-reference/artifacts/get-artifact-content-v-1-artifacts-artifact-id-content-get",
- "destination": "/api-reference/artifacts/get-an-artifact"
- },
- {
- "source": "/api-reference/api-reference/files/upload-file",
- "destination": "/api-reference/files/upload-file"
}
]
}
diff --git a/docs/style.css b/docs/style.css
index bdeec833a..c79778531 100644
--- a/docs/style.css
+++ b/docs/style.css
@@ -452,9 +452,6 @@ a.sk-bento-cell-link:hover .sk-arrow-sm {
============================================= */
@media (max-width: 900px) {
- .sk-hero {
- margin-top: 130px;
- }
.sk-hero-inner {
grid-template-columns: 1fr;
}
diff --git a/fern/openapi/skyvern_openapi.json b/fern/openapi/skyvern_openapi.json
index 2627a9d2a..d263724df 100644
--- a/fern/openapi/skyvern_openapi.json
+++ b/fern/openapi/skyvern_openapi.json
@@ -871,485 +871,6 @@
]
}
},
- "/v1/folders": {
- "post": {
- "tags": [
- "Workflow Folders"
- ],
- "summary": "Create folder",
- "description": "Create a new folder to organize workflows",
- "operationId": "create_folder_v1_folders_post",
- "parameters": [
- {
- "name": "x-api-key",
- "in": "header",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings.",
- "title": "X-Api-Key"
- },
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings."
- }
- ],
- "requestBody": {
- "required": true,
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/FolderCreate"
- }
- }
- }
- },
- "responses": {
- "200": {
- "description": "Successfully created folder",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/Folder"
- }
- }
- }
- },
- "400": {
- "description": "Invalid request"
- },
- "422": {
- "description": "Validation Error",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/HTTPValidationError"
- }
- }
- }
- }
- },
- "x-fern-sdk-method-name": "create_folder"
- },
- "get": {
- "tags": [
- "Workflow Folders"
- ],
- "summary": "Get folders",
- "description": "Get all folders for the organization",
- "operationId": "get_folders_v1_folders_get",
- "parameters": [
- {
- "name": "page",
- "in": "query",
- "required": false,
- "schema": {
- "type": "integer",
- "minimum": 1,
- "description": "Page number",
- "default": 1,
- "title": "Page"
- },
- "description": "Page number"
- },
- {
- "name": "page_size",
- "in": "query",
- "required": false,
- "schema": {
- "type": "integer",
- "maximum": 500,
- "minimum": 1,
- "description": "Number of folders per page",
- "default": 100,
- "title": "Page Size"
- },
- "description": "Number of folders per page"
- },
- {
- "name": "search",
- "in": "query",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "description": "Search folders by title or description",
- "title": "Search"
- },
- "description": "Search folders by title or description"
- },
- {
- "name": "x-api-key",
- "in": "header",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings.",
- "title": "X-Api-Key"
- },
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings."
- }
- ],
- "responses": {
- "200": {
- "description": "Successfully retrieved folders",
- "content": {
- "application/json": {
- "schema": {
- "type": "array",
- "items": {
- "$ref": "#/components/schemas/Folder"
- },
- "title": "Response Get Folders V1 Folders Get"
- }
- }
- }
- },
- "422": {
- "description": "Validation Error",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/HTTPValidationError"
- }
- }
- }
- }
- },
- "x-fern-sdk-method-name": "get_folders"
- }
- },
- "/v1/folders/{folder_id}": {
- "get": {
- "tags": [
- "Workflow Folders"
- ],
- "summary": "Get folder",
- "description": "Get a specific folder by ID",
- "operationId": "get_folder_v1_folders__folder_id__get",
- "parameters": [
- {
- "name": "folder_id",
- "in": "path",
- "required": true,
- "schema": {
- "type": "string",
- "description": "Folder ID",
- "examples": [
- "fld_123"
- ],
- "title": "Folder Id"
- },
- "description": "Folder ID"
- },
- {
- "name": "x-api-key",
- "in": "header",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings.",
- "title": "X-Api-Key"
- },
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings."
- }
- ],
- "responses": {
- "200": {
- "description": "Successfully retrieved folder",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/Folder"
- }
- }
- }
- },
- "404": {
- "description": "Folder not found"
- },
- "422": {
- "description": "Validation Error",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/HTTPValidationError"
- }
- }
- }
- }
- },
- "x-fern-sdk-method-name": "get_folder"
- },
- "put": {
- "tags": [
- "Workflow Folders"
- ],
- "summary": "Update folder",
- "description": "Update a folder's title or description",
- "operationId": "update_folder_v1_folders__folder_id__put",
- "parameters": [
- {
- "name": "folder_id",
- "in": "path",
- "required": true,
- "schema": {
- "type": "string",
- "description": "Folder ID",
- "examples": [
- "fld_123"
- ],
- "title": "Folder Id"
- },
- "description": "Folder ID"
- },
- {
- "name": "x-api-key",
- "in": "header",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings.",
- "title": "X-Api-Key"
- },
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings."
- }
- ],
- "requestBody": {
- "required": true,
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/FolderUpdate"
- }
- }
- }
- },
- "responses": {
- "200": {
- "description": "Successfully updated folder",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/Folder"
- }
- }
- }
- },
- "404": {
- "description": "Folder not found"
- },
- "422": {
- "description": "Validation Error",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/HTTPValidationError"
- }
- }
- }
- }
- },
- "x-fern-sdk-method-name": "update_folder"
- },
- "delete": {
- "tags": [
- "Workflow Folders"
- ],
- "summary": "Delete folder",
- "description": "Delete a folder. Optionally delete all workflows in the folder.",
- "operationId": "delete_folder_v1_folders__folder_id__delete",
- "parameters": [
- {
- "name": "folder_id",
- "in": "path",
- "required": true,
- "schema": {
- "type": "string",
- "description": "Folder ID",
- "examples": [
- "fld_123"
- ],
- "title": "Folder Id"
- },
- "description": "Folder ID"
- },
- {
- "name": "delete_workflows",
- "in": "query",
- "required": false,
- "schema": {
- "type": "boolean",
- "description": "If true, also delete all workflows in this folder",
- "default": false,
- "title": "Delete Workflows"
- },
- "description": "If true, also delete all workflows in this folder"
- },
- {
- "name": "x-api-key",
- "in": "header",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings.",
- "title": "X-Api-Key"
- },
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings."
- }
- ],
- "responses": {
- "200": {
- "description": "Successfully deleted folder",
- "content": {
- "application/json": {
- "schema": {
- "type": "object",
- "additionalProperties": true,
- "title": "Response Delete Folder V1 Folders Folder Id Delete"
- }
- }
- }
- },
- "404": {
- "description": "Folder not found"
- },
- "422": {
- "description": "Validation Error",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/HTTPValidationError"
- }
- }
- }
- }
- },
- "x-fern-sdk-method-name": "delete_folder"
- }
- },
- "/v1/workflows/{workflow_permanent_id}/folder": {
- "put": {
- "tags": [
- "Workflow Folders"
- ],
- "summary": "Update workflow folder",
- "description": "Update a workflow's folder assignment for the latest version",
- "operationId": "update_workflow_folder_v1_workflows__workflow_permanent_id__folder_put",
- "parameters": [
- {
- "name": "workflow_permanent_id",
- "in": "path",
- "required": true,
- "schema": {
- "type": "string",
- "description": "Workflow permanent ID",
- "examples": [
- "wpid_123"
- ],
- "title": "Workflow Permanent Id"
- },
- "description": "Workflow permanent ID"
- },
- {
- "name": "x-api-key",
- "in": "header",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings.",
- "title": "X-Api-Key"
- },
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings."
- }
- ],
- "requestBody": {
- "required": true,
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/UpdateWorkflowFolderRequest"
- }
- }
- }
- },
- "responses": {
- "200": {
- "description": "Successfully updated workflow folder",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/Workflow"
- }
- }
- }
- },
- "400": {
- "description": "Folder not found"
- },
- "404": {
- "description": "Workflow not found"
- },
- "422": {
- "description": "Validation Error",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/HTTPValidationError"
- }
- }
- }
- }
- },
- "x-fern-sdk-method-name": "update_workflow_folder"
- }
- },
"/v1/artifacts/{artifact_id}/content": {
"get": {
"tags": [
@@ -1569,185 +1090,43 @@
"x-fern-examples": [
{
"code-samples": [
- {
- "sdk": "python",
- "code": "from skyvern import Skyvern\n\nskyvern = Skyvern(api_key=\"YOUR_API_KEY\")\nawait skyvern.retry_run_webhook(run_id=\"tsk_v2_123\")\n"
- },
- {
- "sdk": "typescript",
- "code": "import { SkyvernClient } from \"@skyvern/client\";\n\nconst skyvern = new SkyvernClient({ apiKey: \"YOUR_API_KEY\" });\nawait skyvern.retryRunWebhook(\"tsk_v2_123\");\n"
- }
- ]
- }
- ]
- }
- },
- "/v1/runs/{run_id}/timeline": {
- "get": {
- "tags": [
- "Agent",
- "Workflow Runs"
- ],
- "summary": "Get run timeline",
- "description": "Get timeline for a run (workflow run or task_v2 run)",
- "operationId": "get_run_timeline_v1_runs__run_id__timeline_get",
- "parameters": [
- {
- "name": "run_id",
- "in": "path",
- "required": true,
- "schema": {
- "type": "string",
- "description": "The id of the workflow run or task_v2 run.",
- "examples": [
- "wr_123",
- "tsk_v2_123"
- ],
- "title": "Run Id"
- },
- "description": "The id of the workflow run or task_v2 run."
- },
- {
- "name": "x-api-key",
- "in": "header",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings.",
- "title": "X-Api-Key"
- },
- "description": "Skyvern API key for authentication. API key can be found at https://app.skyvern.com/settings."
- }
- ],
- "responses": {
- "200": {
- "description": "Successfully retrieved run timeline",
- "content": {
- "application/json": {
- "schema": {
- "type": "array",
- "items": {
- "$ref": "#/components/schemas/WorkflowRunTimeline"
- },
- "title": "Response Get Run Timeline V1 Runs Run Id Timeline Get"
- }
- }
- }
- },
- "400": {
- "description": "Timeline not available for this run type"
- },
- "404": {
- "description": "Run not found"
- },
- "422": {
- "description": "Validation Error",
- "content": {
- "application/json": {
- "schema": {
- "$ref": "#/components/schemas/HTTPValidationError"
- }
- }
- }
- }
- },
- "x-fern-sdk-method-name": "get_run_timeline",
- "x-fern-examples": [
- {
- "code-samples": [
- {
- "sdk": "python",
- "code": "from skyvern import Skyvern\n\nskyvern = Skyvern(api_key=\"YOUR_API_KEY\")\n# Get timeline for a workflow run\ntimeline = await skyvern.get_run_timeline(run_id=\"wr_123\")\nprint(timeline)\n\n# Get timeline for a task_v2 run\ntimeline = await skyvern.get_run_timeline(run_id=\"tsk_v2_123\")\nprint(timeline)\n"
- },
- {
- "sdk": "typescript",
- "code": "import { SkyvernClient } from \"@skyvern/client\";\n\nconst skyvern = new SkyvernClient({ apiKey: \"YOUR_API_KEY\" });\n// Get timeline for a workflow run\nconst timeline = await skyvern.getRunTimeline(\"wr_123\");\nconsole.log(timeline);\n\n// Get timeline for a task_v2 run\nconst timeline2 = await skyvern.getRunTimeline(\"tsk_v2_123\");\nconsole.log(timeline2);\n"
- }
- ]
- }
- ]
- }
- },
- "/v1/runs": {
- "get": {
- "tags": [
- "agent"
- ],
- "summary": "Get Runs V2",
- "operationId": "get_runs_v2_v1_runs_get",
- "parameters": [
- {
- "name": "page",
- "in": "query",
- "required": false,
- "schema": {
- "type": "integer",
- "maximum": 100,
- "minimum": 1,
- "default": 1,
- "title": "Page"
- }
- },
- {
- "name": "page_size",
- "in": "query",
- "required": false,
- "schema": {
- "type": "integer",
- "maximum": 100,
- "minimum": 1,
- "default": 10,
- "title": "Page Size"
- }
- },
- {
- "name": "status",
- "in": "query",
- "required": false,
- "schema": {
- "anyOf": [
- {
- "type": "array",
- "items": {
- "$ref": "#/components/schemas/RunStatus"
- }
- },
- {
- "type": "null"
- }
- ],
- "title": "Status"
- }
- },
+ {
+ "sdk": "python",
+ "code": "from skyvern import Skyvern\n\nskyvern = Skyvern(api_key=\"YOUR_API_KEY\")\nawait skyvern.retry_run_webhook(run_id=\"tsk_v2_123\")\n"
+ },
+ {
+ "sdk": "typescript",
+ "code": "import { SkyvernClient } from \"@skyvern/client\";\n\nconst skyvern = new SkyvernClient({ apiKey: \"YOUR_API_KEY\" });\nawait skyvern.retryRunWebhook(\"tsk_v2_123\");\n"
+ }
+ ]
+ }
+ ]
+ }
+ },
+ "/v1/runs/{run_id}/timeline": {
+ "get": {
+ "tags": [
+ "Agent",
+ "Workflow Runs"
+ ],
+ "summary": "Get run timeline",
+ "description": "Get timeline for a run (workflow run or task_v2 run)",
+ "operationId": "get_run_timeline_v1_runs__run_id__timeline_get",
+ "parameters": [
{
- "name": "search_key",
- "in": "query",
- "required": false,
+ "name": "run_id",
+ "in": "path",
+ "required": true,
"schema": {
- "anyOf": [
- {
- "type": "string",
- "minLength": 3
- },
- {
- "type": "null"
- }
- ],
- "description": "Case-insensitive substring search (min 3 chars for trigram index).",
+ "type": "string",
+ "description": "The id of the workflow run or task_v2 run.",
"examples": [
- "login_url",
- "wr_abc123"
+ "wr_123",
+ "tsk_v2_123"
],
- "title": "Search Key"
+ "title": "Run Id"
},
- "description": "Case-insensitive substring search (min 3 chars for trigram index)."
+ "description": "The id of the workflow run or task_v2 run."
},
{
"name": "x-api-key",
@@ -1770,19 +1149,25 @@
],
"responses": {
"200": {
- "description": "Successful Response",
+ "description": "Successfully retrieved run timeline",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
- "$ref": "#/components/schemas/TaskRunListItem"
+ "$ref": "#/components/schemas/WorkflowRunTimeline"
},
- "title": "Response Get Runs V2 V1 Runs Get"
+ "title": "Response Get Run Timeline V1 Runs Run Id Timeline Get"
}
}
}
},
+ "400": {
+ "description": "Timeline not available for this run type"
+ },
+ "404": {
+ "description": "Run not found"
+ },
"422": {
"description": "Validation Error",
"content": {
@@ -1794,7 +1179,21 @@
}
}
},
- "x-fern-sdk-method-name": "get_runs_v2"
+ "x-fern-sdk-method-name": "get_run_timeline",
+ "x-fern-examples": [
+ {
+ "code-samples": [
+ {
+ "sdk": "python",
+ "code": "from skyvern import Skyvern\n\nskyvern = Skyvern(api_key=\"YOUR_API_KEY\")\n# Get timeline for a workflow run\ntimeline = await skyvern.get_run_timeline(run_id=\"wr_123\")\nprint(timeline)\n\n# Get timeline for a task_v2 run\ntimeline = await skyvern.get_run_timeline(run_id=\"tsk_v2_123\")\nprint(timeline)\n"
+ },
+ {
+ "sdk": "typescript",
+ "code": "import { SkyvernClient } from \"@skyvern/client\";\n\nconst skyvern = new SkyvernClient({ apiKey: \"YOUR_API_KEY\" });\n// Get timeline for a workflow run\nconst timeline = await skyvern.getRunTimeline(\"wr_123\");\nconsole.log(timeline);\n\n// Get timeline for a task_v2 run\nconst timeline2 = await skyvern.getRunTimeline(\"tsk_v2_123\");\nconsole.log(timeline2);\n"
+ }
+ ]
+ }
+ ]
}
},
"/v1/workflows/runs": {
@@ -9261,125 +8660,6 @@
],
"title": "FileUploadBlockYAML"
},
- "Folder": {
- "properties": {
- "title": {
- "type": "string",
- "maxLength": 255,
- "minLength": 1,
- "title": "Title",
- "description": "Folder title"
- },
- "description": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "title": "Description",
- "description": "Folder description"
- },
- "folder_id": {
- "type": "string",
- "title": "Folder Id"
- },
- "organization_id": {
- "type": "string",
- "title": "Organization Id"
- },
- "workflow_count": {
- "type": "integer",
- "title": "Workflow Count",
- "description": "Number of workflows in this folder",
- "default": 0
- },
- "created_at": {
- "type": "string",
- "format": "date-time",
- "title": "Created At"
- },
- "modified_at": {
- "type": "string",
- "format": "date-time",
- "title": "Modified At"
- }
- },
- "type": "object",
- "required": [
- "title",
- "folder_id",
- "organization_id",
- "created_at",
- "modified_at"
- ],
- "title": "Folder",
- "description": "Response model for a folder"
- },
- "FolderCreate": {
- "properties": {
- "title": {
- "type": "string",
- "maxLength": 255,
- "minLength": 1,
- "title": "Title",
- "description": "Folder title"
- },
- "description": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "title": "Description",
- "description": "Folder description"
- }
- },
- "type": "object",
- "required": [
- "title"
- ],
- "title": "FolderCreate",
- "description": "Request model for creating a folder"
- },
- "FolderUpdate": {
- "properties": {
- "title": {
- "anyOf": [
- {
- "type": "string",
- "maxLength": 255,
- "minLength": 1
- },
- {
- "type": "null"
- }
- ],
- "title": "Title",
- "description": "Folder title"
- },
- "description": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "title": "Description",
- "description": "Folder description"
- }
- },
- "type": "object",
- "title": "FolderUpdate",
- "description": "Request model for updating a folder"
- },
"ForLoopBlock": {
"properties": {
"label": {
@@ -14216,92 +13496,6 @@
],
"title": "TaskBlockYAML"
},
- "TaskRunListItem": {
- "properties": {
- "task_run_id": {
- "type": "string",
- "title": "Task Run Id"
- },
- "run_id": {
- "type": "string",
- "title": "Run Id"
- },
- "task_run_type": {
- "type": "string",
- "title": "Task Run Type"
- },
- "status": {
- "type": "string",
- "title": "Status"
- },
- "title": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "title": "Title"
- },
- "started_at": {
- "anyOf": [
- {
- "type": "string",
- "format": "date-time"
- },
- {
- "type": "null"
- }
- ],
- "title": "Started At"
- },
- "finished_at": {
- "anyOf": [
- {
- "type": "string",
- "format": "date-time"
- },
- {
- "type": "null"
- }
- ],
- "title": "Finished At"
- },
- "created_at": {
- "type": "string",
- "format": "date-time",
- "title": "Created At"
- },
- "workflow_permanent_id": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "title": "Workflow Permanent Id"
- },
- "script_run": {
- "type": "boolean",
- "title": "Script Run",
- "default": false
- }
- },
- "type": "object",
- "required": [
- "task_run_id",
- "run_id",
- "task_run_type",
- "status",
- "created_at"
- ],
- "title": "TaskRunListItem",
- "description": "Lightweight run-history item backed by the task_runs table."
- },
"TaskRunRequest": {
"properties": {
"prompt": {
@@ -15590,25 +14784,6 @@
"title": "TotpType",
"description": "Type of 2FA/TOTP method used."
},
- "UpdateWorkflowFolderRequest": {
- "properties": {
- "folder_id": {
- "anyOf": [
- {
- "type": "string"
- },
- {
- "type": "null"
- }
- ],
- "title": "Folder Id",
- "description": "Folder ID to assign workflow to. Set to null to remove from folder."
- }
- },
- "type": "object",
- "title": "UpdateWorkflowFolderRequest",
- "description": "Request model for updating a workflow's folder assignment"
- },
"UploadFileResponse": {
"properties": {
"s3_uri": {
@@ -19207,11 +18382,9 @@
"enum": [
"manual",
"api",
- "scheduled",
- "webhook"
+ "scheduled"
],
- "title": "WorkflowRunTriggerType",
- "description": "How a workflow run was initiated.\n\n- manual: User clicked \"Run\" in the UI\n- api: Direct API call to the run endpoint\n- scheduled: Triggered by a cron schedule\n- webhook: Triggered by an external system via the webhook endpoint"
+ "title": "WorkflowRunTriggerType"
},
"WorkflowStatus": {
"type": "string",
diff --git a/skyvern-frontend/src/api/types.ts b/skyvern-frontend/src/api/types.ts
index b8d1a0626..bab46af3d 100644
--- a/skyvern-frontend/src/api/types.ts
+++ b/skyvern-frontend/src/api/types.ts
@@ -441,6 +441,31 @@ export type WorkflowRunApiResponse = {
workflow_title: string | null;
};
+export const TaskRunType = {
+ TaskV1: "task_v1",
+ TaskV2: "task_v2",
+ WorkflowRun: "workflow_run",
+ OpenaiCua: "openai_cua",
+ AnthropicCua: "anthropic_cua",
+ UiTars: "ui_tars",
+} as const;
+
+export type TaskRunType = (typeof TaskRunType)[keyof typeof TaskRunType];
+
+export type TaskRunListItem = {
+ task_run_id: string;
+ task_run_type: TaskRunType;
+ run_id: string;
+ title: string | null;
+ status: string;
+ started_at: string | null;
+ finished_at: string | null;
+ created_at: string;
+ workflow_permanent_id: string | null;
+ script_run: boolean;
+ searchable_text: string | null;
+};
+
export type WorkflowRunStatusApiResponse = {
workflow_id: string;
workflow_run_id: string;
diff --git a/skyvern-frontend/src/hooks/useRunsQuery.ts b/skyvern-frontend/src/hooks/useRunsQuery.ts
index 2ea9cb500..66f49866b 100644
--- a/skyvern-frontend/src/hooks/useRunsQuery.ts
+++ b/skyvern-frontend/src/hooks/useRunsQuery.ts
@@ -1,9 +1,9 @@
import { getClient } from "@/api/AxiosClient";
import { useCredentialGetter } from "@/hooks/useCredentialGetter";
import { useQuery } from "@tanstack/react-query";
-import { Status, Task, TriggerType, WorkflowRunApiResponse } from "@/api/types";
+import { Status, TaskRunListItem } from "@/api/types";
-type QueryReturnType = Array<Task | WorkflowRunApiResponse>;
+type QueryReturnType = Array<TaskRunListItem>;
type UseQueryOptions = Omit<
Parameters<typeof useQuery<QueryReturnType>>[0],
"queryKey" | "queryFn"
@@ -13,7 +13,6 @@ type Props = {
page?: number;
pageSize?: number;
statusFilters?: Array<Status>;
- triggerTypeFilters?: Array<TriggerType>;
search?: string;
} & UseQueryOptions;
@@ -21,20 +20,14 @@ function useRunsQuery({
page = 1,
pageSize = 10,
statusFilters,
- triggerTypeFilters,
search,
+ ...queryOptions
}: Props) {
const credentialGetter = useCredentialGetter();
- return useQuery<Array<Task | WorkflowRunApiResponse>>({
- queryKey: [
- "runs",
- { statusFilters, triggerTypeFilters },
- page,
- pageSize,
- search,
- ],
+ return useQuery<Array<TaskRunListItem>>({
+ queryKey: ["runs", { statusFilters }, page, pageSize, search],
queryFn: async () => {
- const client = await getClient(credentialGetter);
+ const client = await getClient(credentialGetter, "sans-api-v1");
const params = new URLSearchParams();
params.append("page", String(page));
params.append("page_size", String(pageSize));
@@ -43,16 +36,12 @@ function useRunsQuery({
params.append("status", status);
});
}
- if (triggerTypeFilters) {
- triggerTypeFilters.forEach((triggerType) => {
- params.append("trigger_type", triggerType);
- });
- }
if (search) {
params.append("search_key", search);
}
return client.get("/runs", { params }).then((res) => res.data);
},
+ ...queryOptions,
});
}
diff --git a/skyvern-frontend/src/routes/history/RunHistory.tsx b/skyvern-frontend/src/routes/history/RunHistory.tsx
index 245adc039..43217c24e 100644
--- a/skyvern-frontend/src/routes/history/RunHistory.tsx
+++ b/skyvern-frontend/src/routes/history/RunHistory.tsx
@@ -3,15 +3,12 @@ import { LightningBoltIcon, MixerHorizontalIcon } from "@radix-ui/react-icons";
import { Tip } from "@/components/Tip";
import {
Status,
- Task,
- TriggerType,
- WorkflowRunApiResponse,
+ TaskRunListItem,
+ TaskRunType,
WorkflowRunStatusApiResponse,
} from "@/api/types";
import { StatusBadge } from "@/components/StatusBadge";
import { StatusFilterDropdown } from "@/components/StatusFilterDropdown";
-import { TriggerTypeBadge } from "@/components/TriggerTypeBadge";
-import { TriggerTypeFilterDropdown } from "@/components/TriggerTypeFilterDropdown";
import {
Pagination,
PaginationContent,
@@ -41,7 +38,6 @@ import React, { useEffect, useState } from "react";
import { useNavigate, useSearchParams } from "react-router-dom";
import { getClient } from "@/api/AxiosClient";
import { useCredentialGetter } from "@/hooks/useCredentialGetter";
-import * as env from "@/util/env";
import { useDebounce } from "use-debounce";
import { Button } from "@/components/ui/button";
import {
@@ -57,21 +53,33 @@ import { useParameterExpansion } from "@/routes/workflows/hooks/useParameterExpa
import { ParameterDisplayInline } from "@/routes/workflows/components/ParameterDisplayInline";
import { HighlightText } from "@/routes/workflows/components/HighlightText";
-function isTask(run: Task | WorkflowRunApiResponse): run is Task {
- return "task_id" in run;
+const statusValues = new Set<string>(Object.values(Status));
+function isKnownStatus(value: string): value is Status {
+ return statusValues.has(value);
+}
+
+function getRunNavigationPath(run: TaskRunListItem): string {
+ switch (run.task_run_type) {
+ case TaskRunType.WorkflowRun:
+ case TaskRunType.TaskV2:
+ return `/runs/${run.run_id}`;
+ case TaskRunType.TaskV1:
+ case TaskRunType.OpenaiCua:
+ case TaskRunType.AnthropicCua:
+ case TaskRunType.UiTars:
+ return `/tasks/${run.run_id}/actions`;
+ default:
+ return `/runs/${run.run_id}`;
+ }
}
function RunHistory() {
- const credentialGetter = useCredentialGetter();
const [searchParams, setSearchParams] = useSearchParams();
const page = searchParams.get("page") ? Number(searchParams.get("page")) : 1;
const itemsPerPage = searchParams.get("page_size")
? Number(searchParams.get("page_size"))
: 10;
const [statusFilters, setStatusFilters] = useState<Array<Status>>([]);
- const [triggerTypeFilters, setTriggerTypeFilters] = useState<
- Array<TriggerType>
- >([]);
const [search, setSearch] = useState("");
const [debouncedSearch] = useDebounce(search, 500);
@@ -79,43 +87,17 @@ function RunHistory() {
page,
pageSize: itemsPerPage,
statusFilters,
- triggerTypeFilters,
search: debouncedSearch,
});
const navigate = useNavigate();
- const { data: nextPageRuns } = useQuery<Array<Task | WorkflowRunApiResponse>>(
- {
- queryKey: [
- "runs",
- { statusFilters, triggerTypeFilters },
- page + 1,
- itemsPerPage,
- debouncedSearch,
- ],
- queryFn: async () => {
- const client = await getClient(credentialGetter);
- const params = new URLSearchParams();
- params.append("page", String(page + 1));
- params.append("page_size", String(itemsPerPage));
- if (statusFilters) {
- statusFilters.forEach((status) => {
- params.append("status", status);
- });
- }
- if (triggerTypeFilters) {
- triggerTypeFilters.forEach((triggerType) => {
- params.append("trigger_type", triggerType);
- });
- }
- if (debouncedSearch) {
- params.append("search_key", debouncedSearch);
- }
- return client.get("/runs", { params }).then((res) => res.data);
- },
- enabled: runs && runs.length === itemsPerPage,
- },
- );
+ const { data: nextPageRuns } = useRunsQuery({
+ page: page + 1,
+ pageSize: itemsPerPage,
+ statusFilters,
+ search: debouncedSearch,
+ enabled: runs?.length === itemsPerPage,
+ });
const isNextDisabled =
isFetching || !nextPageRuns || nextPageRuns.length === 0;
@@ -136,8 +118,8 @@ function RunHistory() {
const workflowRunIds =
runs
- ?.filter((run): run is WorkflowRunApiResponse => !isTask(run))
- .map((run) => run.workflow_run_id)
+ ?.filter((run) => run.task_run_type === TaskRunType.WorkflowRun)
+ .map((run) => run.run_id)
.filter((id): id is string => Boolean(id)) ?? [];
setAutoExpandedRows(workflowRunIds);
@@ -170,12 +152,137 @@ function RunHistory() {
if (isNextDisabled) return;
setParamPatch({ page: String(page + 1) });
}
+
+ const displayTableBody = () => {
+ // Show loading skeleton
+ if (isFetching) {
+ return Array.from({ length: 10 }).map((_, index) => (
+ <TableRow key={`row-${index}`}>
+ <TableCell colSpan={6}>
+ <Skeleton className="h-4 w-full" />
+ </TableCell>
+ </TableRow>
+ ));
+ }
+
+ // No runs found
+ if (runs?.length === 0) {
+ return (
+ <TableRow>
+ <TableCell colSpan={6}>
+ <div className="text-center">No runs found</div>
+ </TableCell>
+ </TableRow>
+ );
+ }
+
+ return runs?.map((run) => {
+ const executionTime = formatExecutionTime(
+ run.started_at ?? run.created_at,
+ run.finished_at,
+ );
+ const isWorkflowRun = run.task_run_type === TaskRunType.WorkflowRun;
+ const isExpanded = isWorkflowRun && expandedRows.has(run.run_id);
+ const navPath = getRunNavigationPath(run);
+
+ const titleContent = run.script_run ? (
+ <div className="flex items-center gap-2">
+ <Tip content="Ran with code">
+ <LightningBoltIcon className="text-[gold]" />
+ </Tip>
+ <span>{run.title ?? ""}</span>
+ </div>
+ ) : (
+ run.title ?? ""
+ );
+
+ return (
+ <React.Fragment key={run.task_run_id}>
+ <TableRow
+ className="cursor-pointer"
+ onClick={(event) => {
+ handleNavigate(event, navPath);
+ }}
+ >
+ <TableCell className="max-w-0 truncate" title={run.run_id}>
+ <HighlightText text={run.run_id} query={debouncedSearch} />
+ </TableCell>
+ <TableCell
+ className="max-w-0 truncate"
+ title={run.title ?? undefined}
+ >
+ {titleContent}
+ </TableCell>
+ <TableCell>
+ {isKnownStatus(run.status) ? (
+ <StatusBadge status={run.status} />
+ ) : (
+ <span className="text-sm text-slate-400">{run.status}</span>
+ )}
+ </TableCell>
+ <TableCell
+ className="max-w-0 truncate"
+ title={basicTimeFormat(run.created_at)}
+ >
+ {basicLocalTimeFormat(run.created_at)}
+ </TableCell>
+ <TableCell className="text-slate-400">
+ {executionTime ?? "-"}
+ </TableCell>
+ <TableCell>
+ {isWorkflowRun ? (
+ <div className="flex justify-end">
+ <TooltipProvider>
+ <Tooltip>
+ <TooltipTrigger asChild>
+ <Button
+ size="icon"
+ variant="outline"
+ onClick={(event) => {
+ event.stopPropagation();
+ toggleParametersExpanded(run.run_id);
+ }}
+ className={cn(isExpanded && "text-blue-400")}
+ >
+ <MixerHorizontalIcon className="h-4 w-4" />
+ </Button>
+ </TooltipTrigger>
+ <TooltipContent>
+ {isExpanded ? "Hide Parameters" : "Show Parameters"}
+ </TooltipContent>
+ </Tooltip>
+ </TooltipProvider>
+ </div>
+ ) : null}
+ </TableCell>
+ </TableRow>
+
+ {isExpanded && run.workflow_permanent_id && (
+ <TableRow key={`${run.run_id}-params`}>
+ <TableCell
+ colSpan={6}
+ className="bg-slate-50 dark:bg-slate-900/50"
+ >
+ <WorkflowRunParametersInline
+ workflowPermanentId={run.workflow_permanent_id}
+ workflowRunId={run.run_id}
+ searchQuery={debouncedSearch}
+ keywordMatchesParameter={matchesParameter}
+ />
+ </TableCell>
+ </TableRow>
+ )}
+ </React.Fragment>
+ );
+ });
+ };
+
return (
<div className="space-y-4">
<header>
<h1 className="text-2xl">Run History</h1>
</header>
- <div className="flex items-center gap-4">
+ <div className="flex items-center justify-between gap-4">
<TableSearchInput
value={search}
onChange={(value) => {
@@ -187,19 +294,10 @@ function RunHistory() {
placeholder="Search by run ID or parameter..."
className="w-48 lg:w-72"
/>
- <TriggerTypeFilterDropdown
- values={triggerTypeFilters}
- onChange={(values) => {
- setTriggerTypeFilters(values);
- const params = new URLSearchParams(searchParams);
- params.set("page", "1");
- setSearchParams(params, { replace: true });
- }}
- />
<StatusFilterDropdown
values={statusFilters}
- onChange={(values) => {
- setStatusFilters(values);
+ onChange={(filters) => {
+ setStatusFilters(filters);
const params = new URLSearchParams(searchParams);
params.set("page", "1");
setSearchParams(params, { replace: true });
@@ -222,184 +320,7 @@ function RunHistory() {
<TableHead className="w-[8%] rounded-tr-lg text-slate-400"></TableHead>
</TableRow>
</TableHeader>
- <TableBody>
- {isFetching ? (
- Array.from({ length: 10 }).map((_, index) => (
- <TableRow key={index}>
- <TableCell colSpan={6}>
- <Skeleton className="h-4 w-full" />
- </TableCell>
- </TableRow>
- ))
- ) : runs?.length === 0 ? (
- <TableRow>
- <TableCell colSpan={6}>
- <div className="text-center">No runs found</div>
- </TableCell>
- </TableRow>
- ) : (
- runs?.map((run) => {
- if (isTask(run)) {
- const taskExecutionTime = formatExecutionTime(
- run.started_at ?? run.created_at,
- run.finished_at,
- );
- return (
- <TableRow
- key={run.task_id}
- className="cursor-pointer"
- onClick={(event) => {
- handleNavigate(event, `/tasks/${run.task_id}/actions`);
- }}
- >
- <TableCell className="max-w-0 truncate">
- {run.task_id}
- </TableCell>
- <TableCell className="max-w-0 truncate">
- {run.url}
- </TableCell>
- <TableCell>
- <StatusBadge status={run.status} />
- </TableCell>
- <TableCell
- title={basicTimeFormat(run.created_at)}
- className="max-w-0 truncate"
- >
- {basicLocalTimeFormat(run.created_at)}
- </TableCell>
- <TableCell className="truncate text-slate-400">
- {taskExecutionTime ?? "-"}
- </TableCell>
- {/* Align with workflow row's expand button column. */}
- <TableCell />
- </TableRow>
- );
- }
-
- const workflowTitle = (
- <div className="flex items-center gap-2">
- <span className="truncate">{run.workflow_title ?? ""}</span>
- {run.script_run === true && (
- <Tip content="Ran with code">
- <LightningBoltIcon className="text-[gold]" />
- </Tip>
- )}
- <TriggerTypeBadge triggerType={run.trigger_type} />
- </div>
- );
-
- const isExpanded = expandedRows.has(run.workflow_run_id);
- const workflowExecutionTime = formatExecutionTime(
- run.started_at ?? run.created_at,
- run.finished_at,
- );
-
- return (
- <React.Fragment key={run.workflow_run_id}>
- <TableRow
- className="cursor-pointer"
- onClick={(event) => {
- handleNavigate(
- event,
- env.useNewRunsUrl
- ? `/runs/${run.workflow_run_id}`
- : `/workflows/${run.workflow_permanent_id}/${run.workflow_run_id}/overview`,
- );
- }}
- >
- <TableCell
- className="max-w-0 truncate"
- title={run.workflow_run_id}
- >
- <HighlightText
- text={run.workflow_run_id}
- query={debouncedSearch}
- />
- </TableCell>
- <TableCell
- className="max-w-0 truncate"
- title={run.workflow_title ?? undefined}
- >
- {workflowTitle}
- </TableCell>
- <TableCell>
- <StatusBadge status={run.status} />
- </TableCell>
- <TableCell
- className="max-w-0 truncate"
- title={
- run.trigger_type === TriggerType.Scheduled &&
- run.scheduled_for
- ? `Scheduled: ${basicTimeFormat(run.scheduled_for)}\nStarted: ${basicTimeFormat(run.created_at)}`
- : basicTimeFormat(run.created_at)
- }
- >
- <div className="flex flex-col">
- <span>{basicLocalTimeFormat(run.created_at)}</span>
- {run.trigger_type === TriggerType.Scheduled &&
- run.schedule_name && (
- <span className="text-xs text-slate-400">
- {run.schedule_name}
- {run.schedule_cron
- ? ` (${run.schedule_cron})`
- : ""}
- </span>
- )}
- </div>
- </TableCell>
- <TableCell className="truncate text-slate-400">
- {workflowExecutionTime ?? "-"}
- </TableCell>
- <TableCell>
- <div className="flex justify-end">
- <TooltipProvider>
- <Tooltip>
- <TooltipTrigger asChild>
- <Button
- size="icon"
- variant="outline"
- onClick={(event) => {
- event.stopPropagation();
- toggleParametersExpanded(
- run.workflow_run_id,
- );
- }}
- className={cn(isExpanded && "text-blue-400")}
- >
- <MixerHorizontalIcon className="h-4 w-4" />
- </Button>
- </TooltipTrigger>
- <TooltipContent>
- {isExpanded
- ? "Hide Parameters"
- : "Show Parameters"}
- </TooltipContent>
- </Tooltip>
- </TooltipProvider>
- </div>
- </TableCell>
- </TableRow>
-
- {isExpanded && (
- <TableRow key={`${run.workflow_run_id}-params`}>
- <TableCell
- colSpan={6}
- className="bg-slate-50 dark:bg-slate-900/50"
- >
- <WorkflowRunParametersInline
- workflowPermanentId={run.workflow_permanent_id}
- workflowRunId={run.workflow_run_id}
- searchQuery={debouncedSearch}
- keywordMatchesParameter={matchesParameter}
- />
- </TableCell>
- </TableRow>
- )}
- </React.Fragment>
- );
- })
- )}
- </TableBody>
+ <TableBody>{displayTableBody()}</TableBody>
</Table>
<div className="relative px-3 py-3">
<div className="absolute left-3 top-1/2 flex -translate-y-1/2 items-center gap-2 text-sm">
@@ -466,7 +387,7 @@ function WorkflowRunParametersInline({
workflowRunId,
searchQuery,
keywordMatchesParameter,
-}: WorkflowRunParametersInlineProps) {
+}: Readonly<WorkflowRunParametersInlineProps>) {
const { data: globalWorkflows } = useGlobalWorkflowsQuery();
const credentialGetter = useCredentialGetter();