From 4d3e3c2c24b87d428f32f7ecb8bbe462f7f11a4c Mon Sep 17 00:00:00 2001 From: Shuchang Zheng Date: Sun, 16 Mar 2025 16:13:02 -0700 Subject: [PATCH] add webhook url, proxy, totp support in run workflow of SkyvernClient (#1947) --- skyvern/agent/client.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/skyvern/agent/client.py b/skyvern/agent/client.py index 8d4d7f0b..e6c42127 100644 --- a/skyvern/agent/client.py +++ b/skyvern/agent/client.py @@ -48,10 +48,17 @@ class SkyvernClient: workflow_input: dict | None = None, webhook_url: str | None = None, proxy_location: ProxyLocation | None = None, + totp_identifier: str | None = None, + totp_url: str | None = None, ) -> RunWorkflowResponse: - data = None + data = { + "webhook_callback_url": webhook_url, + "proxy_location": proxy_location, + "totp_identifier": totp_identifier, + "totp_url": totp_url, + } if workflow_input: - data = {"data": workflow_input} + data["data"] = workflow_input async with httpx.AsyncClient() as client: response = await client.post( f"{self.base_url}/api/v1/workflows/{workflow_id}/run",