Skip to content

Automate browser based workflows with AI

send workflow_run_id to totp endpoint (#2120)

Shuchang Zheng7d5ab76d7317
diff --git a/skyvern/forge/agent.py b/skyvern/forge/agent.py
index aa5370193..f74fdd05c 100644
--- a/skyvern/forge/agent.py
+++ b/skyvern/forge/agent.py
@@ -2297,6 +2297,7 @@ class ForgeAgent:
verification_code = await poll_verification_code(
task.task_id,
task.organization_id,
+ workflow_run_id=task.workflow_run_id,
totp_verification_url=task.totp_verification_url,
totp_identifier=task.totp_identifier,
)
diff --git a/skyvern/webeye/actions/handler.py b/skyvern/webeye/actions/handler.py
index 908f8eecf..53b1fcd9c 100644
--- a/skyvern/webeye/actions/handler.py
+++ b/skyvern/webeye/actions/handler.py
@@ -2887,7 +2887,12 @@ async def poll_verification_code(
)
verification_code = None
if totp_verification_url:
- verification_code = await _get_verification_code_from_url(task_id, totp_verification_url, org_token.token)
+ verification_code = await _get_verification_code_from_url(
+ task_id,
+ totp_verification_url,
+ org_token.token,
+ workflow_run_id=workflow_run_id,
+ )
elif totp_identifier:
verification_code = await _get_verification_code_from_db(
task_id, organization_id, totp_identifier, workflow_id=workflow_id