Skip to main content
Glama

等待人工完成登录/验证

wait_for_user_auth
Read-only

Pause automated browser flows when login or CAPTCHA requires human action, then resume after manual confirmation.

Instructions

当检测到登录过期、滑动验证码、微信扫码等需要人工介入的情况时,暂停自动化流程并等待用户处理。mode=detect:立即检测当前页面的登录/验证状态并返回截图,不等待(适合客户端有工具超时限制的场景,可反复调用轮询)。mode=wait:持续轮询直到登录/验证完成或超时(默认 180 秒,最长 900 秒)。mode=confirm:用户已人工确认处理完毕,清除挂起状态并返回当前页面状态。无论哪种模式都会返回截图与当前 URL/标题,便于确认人机交接是否成功。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNodetect=只检测(默认);wait=轮询等待;confirm=确认已完成。detect
noteNo可选:给用户的提示信息,会原样返回,例如说明要登录哪个账号。
cdpPortNo可选:CDP 调试端口。省略时沿用当前已连接的端口(从未连接过则为 9222)。
timeoutMsNo仅 wait 模式有效:最长等待毫秒数,默认 180000,上限 900000。

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior1/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotation Contradiction: the description says mode=confirm 'clears pending state', which is a state mutation, while annotations declare readOnlyHint=true. The description is otherwise behaviorally rich (polling, timeout bounds, return values), but the direct contradiction with readOnlyHint makes the annotation untrustworthy for an agent.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the trigger case, then organizes modes in a consistent, scannable structure. Every sentence covers a distinct aspect—trigger, mode behavior, and return values—with no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description correctly covers return values (screenshot, current URL/title) and explains all three modes plus timeout defaults and limits. The main gap is that it does not state the result or error shape when wait times out, nor explicitly mention a prerequisite connection, though cdpPort and sibling context partially cover that.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3, but the description adds meaningful semantics for mode behavior and timeout semantics (e.g., detect returns immediately and can be polled, wait polls until completion, timeoutMs only applies to wait). note and cdpPort are not expanded beyond the schema, but the schema covers them.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific trigger (login expiry, captchas, WeChat scan) and a specific action: pause the automation flow and wait for human intervention. The three modes are individually described, making the tool's role unmistakable and clearly distinct from siblings like take_screenshot.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly says when to use the tool (when login/verification needs human handling) and gives mode-level guidance, including the note that detect suits clients with tool timeout limits and can be repeatedly polled. However, it does not name alternative sibling tools or state explicit when-not-to-use conditions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.