Skip to main content
Glama

get-full-dom

Extract the complete Document Object Model (DOM) from a web page to enable AI-driven test generation and element inspection for Playwright automation.

Instructions

Get the full DOM of the current page. (Deprecated, use get-context instead)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for 'get-full-dom' tool. It captures an analytics event, fetches the full HTML content of the current page using Playwright's page.content(), and returns it as text content in the MCP response format.
    async () => {
      posthogServer.capture({
        distinctId: getUserId(),
        event: 'get_full_dom',
      });
    
      const html = await page.content();
      return {
        content: [
          {
            type: "text",
            text: html,
          },
        ],
      };
    }
  • Registers the 'get-full-dom' tool with the MCP server, including name, description, empty input schema, and the handler function. Note: marked as deprecated.
    server.tool(
      "get-full-dom",
      "Get the full DOM of the current page. (Deprecated, use get-context instead)",
      {},
      async () => {
        posthogServer.capture({
          distinctId: getUserId(),
          event: 'get_full_dom',
        });
    
        const html = await page.content();
        return {
          content: [
            {
              type: "text",
              text: html,
            },
          ],
        };
      }
    );

Tool Definition Quality

Score is being calculated. Check back soon.

Install Server

Other Tools

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/Ashish-Bansal/playwright-mcp'

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