Skip to main content
Glama

登入網頁聊天服務(已登入則不開瀏覽器視窗)

webchat_login

Checks whether the built-in browser profile is logged in to ChatGPT, Claude, Grok, or Gemini; if not, opens a window for one-time manual login and saves the session.

Instructions

Check whether the built-in browser profile is already logged in to the chosen service (headless, no window shown). If so, return immediately. Only when not logged in does it show a browser window so the user can log in manually once; the window is hidden again after login succeeds. The session is persisted in the profile directory and reused by later calls. Logging in is optional for chatgpt and gemini: webchat_ask also works as a guest there. Claude and Grok require it. Waits up to timeout_seconds (default 180) for the manual login; on timeout the window stays open and the user can finish later, then call webchat_status.

Input Schema

NameRequiredDescriptionDefault
providerNoWhich web chat service to use: chatgpt (ChatGPT), claude (Claude), grok (Grok), gemini (Gemini). Default chatgpt.chatgpt
timeout_secondsNoHow long to wait for a manual login (default 180s).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.8.1

TDQS

A4.8/5.0
Behavior5/5

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

With no annotations present, the description carries the full burden and delivers: it performs a headless check with no window, returns immediately if already logged in, shows a window only for manual login, hides it afterward, persists the session for later calls, and leaves the window open on timeout. Every behavioral trait an agent needs is disclosed.

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

Conciseness4/5

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

The behavior is front-loaded (the headless check and early return come first), and the remaining sentences cover window behavior, persistence, provider optionality, and timeout. It is dense but nearly every sentence adds operational value; only the timeout sentence overlaps slightly with the schema.

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

Completeness5/5

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

With no annotations and no output schema, the description fully covers the operation's lifecycle: pre-check, conditional window, post-login hiding, session persistence, provider requirements, and timeout recovery path. Nothing an agent needs in order to invoke this correctly is missing.

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 coverage is 100%, so the baseline is 3. The description adds meaning beyond the schema by explaining the provider-specific login requirement (optional for chatgpt/gemini, required for claude/grok) and by describing what timeout_seconds governs and what happens when it elapses.

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 verb and resource (check login state of the built-in browser profile, show a window only when needed) and distinguishes itself from siblings by referencing webchat_ask and webchat_status. An agent can immediately tell this is the login-gate tool rather than a query or messaging tool.

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

Usage Guidelines5/5

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

It explicitly states that login is optional for chatgpt and gemini (webchat_ask works as a guest) but required for claude and grok, and it tells the agent to call webchat_status after a timeout. This is explicit when-to-use, when-not-needed, and follow-up routing.

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