Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault

No arguments

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
list_network_requestsA

List network requests for the currently selected miniapp target/session since MCP started monitoring it. Results are sorted newest-first. By default returns the 20 most recent requests; use page_size/page_idx to paginate. Pass reqid to get a single request's full details. On first call it automatically connects to the endpoint, infers the target, attaches only that target, enables Network on that target session, and starts collecting XHR/Fetch requests.

get_response_bodyA

Get the response body for a request returned by list_network_requests. If session_id is omitted, it is inferred from the monitored request cache.

get_request_initiatorB

Gets the JavaScript call stack that initiated a network request. This helps trace which code triggered an API call.

list_scriptsA

Lists all JavaScript scripts loaded in the current page. Returns script ID, URL, and source map information. Use this to find scripts before setting breakpoints or searching.

get_script_sourceB

Gets a snippet of a JavaScript script source by URL (recommended) or script ID. Supports line range (for normal files) or character offset (for minified single-line files).

save_script_sourceC

Saves the full source code of a JavaScript script to a local file.

search_in_sourcesB

Searches for a string or regex pattern in all loaded JavaScript sources. Returns matching lines with script ID, URL, and line number.

evaluate_scriptC

Evaluates a JavaScript expression in the current context. If execution is paused, it automatically evaluates in the paused call frame context.

get_websocket_messagesB

Lists WebSocket connections or gets messages for a specific connection. Without wsid, lists all connections. With wsid, gets messages.

break_on_xhrA

Sets a breakpoint that triggers when an XHR/Fetch request URL contains the specified string.

remove_xhr_breakpointC

Removes an XHR/Fetch breakpoint.

pause_or_resumeB

Toggles JavaScript execution. If paused, resumes execution. If running, pauses execution.

get_paused_infoA

Gets information about the current paused state including call stack, current location, and scope variables. Use this after a breakpoint is hit to understand the execution context.

set_breakpoint_on_textA

Finds a text string in all loaded scripts and sets a breakpoint at that location. CRITICAL AI WORKFLOW WARNING: Do NOT set breakpoints on function names or assignment statements (e.g., 'funcName = function'). In minified code, this will break on the one-time assignment rather than the execution. Instead, ALWAYS use get_script_source to read the function body first, then set the breakpoint on a specific statement INSIDE the function body (e.g., 'var x=', 'return').

remove_breakpointB

Removes a breakpoint by its ID.

list_breakpointsB

Lists all active XHR and code breakpoints.

stepB

Controls execution when paused. action must be one of: 'over', 'into', 'out'.

list_targetsB

Lists all available targets (WebView threads, AppService threads, etc.) in the connected debugger.

switch_targetB

Switches the CDP connection to a different target thread (e.g. from WebView to AppService) to debug different parts of the miniapp.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/zhizhuodemao/miniapp-cdp-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server