Skip to main content
Glama

Better Playwright MCP

by livoras

waitForSelector

Pause execution until a specified element, identified by a CSS selector or XPath, appears on the webpage, with configurable timeout and state conditions for precise control.

Instructions

等待指定选择器的元素出现

Input Schema

NameRequiredDescriptionDefault
pageIdYes页面ID
selectorYesCSS选择器或xp引用值
stateNo等待的状态(默认visible)
timeoutNo超时时间(毫秒,默认30000)

Input Schema (JSON Schema)

{ "$schema": "http://json-schema.org/draft-07/schema#", "additionalProperties": false, "properties": { "pageId": { "description": "页面ID", "type": "string" }, "selector": { "description": "CSS选择器或xp引用值", "type": "string" }, "state": { "description": "等待的状态(默认visible)", "enum": [ "attached", "detached", "visible", "hidden" ], "type": "string" }, "timeout": { "description": "超时时间(毫秒,默认30000)", "type": "number" } }, "required": [ "pageId", "selector" ], "type": "object" }

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/livoras/better-playwright-mcp'

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