Skip to main content
Glama

get_page_source

Retrieve the current HTML of a web page, including script-modified DOM, to access raw markup like meta tags or hidden fields.

Instructions

Return the page's current HTML (the live DOM, including changes made by scripts), cut off at maxLength characters. Returns the HTML, its full length, and whether it was truncated. It is large and noisy: to find elements to act on, prefer capture_page; to read specific text or values, use get_text or get_attribute. Use this for raw markup such as meta tags, hidden fields, or inline data.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
maxLengthNoMaximum characters of HTML to return, 100-500000 (default 50000). Longer pages are truncated.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.3.0
    • addedInput schema / properties / maxLength / description
      Added value: +"Maximum characters of HTML to return, 100-500000 (default 50000). Longer pages are truncated."
  2. First observedv0.1.2

TDQS

A4.5/5.0
Behavior4/5

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

No annotations exist, so the description carries the full burden, and it does well: it discloses that the result is the live DOM, that output is truncated at maxLength, the return shape (HTML, full length, truncated flag), and that the payload is 'large and noisy'. It does not quantify expected payload size or performance cost, which keeps it just under the top mark.

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?

Three tight sentences, front-loaded with what is returned before the caveats and alternatives. Every clause earns its place: none is redundant with the schema or with a sibling-name-only listing.

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 output schema and no annotations, the description still tells the agent what comes back (HTML, full length, truncation flag) and how to route away when that is not what is wanted. Nothing needed to invoke this single-optional-parameter tool correctly is missing.

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

Parameters3/5

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

Schema coverage is 100% and the maxLength description already gives range and default, so the schema does the heavy lifting. The description's 'cut off at maxLength characters' adds the truncation consequence but no format or syntax detail beyond the schema, making 3 the correct baseline.

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?

States a specific verb and resource ('Return the page's current HTML'), and immediately qualifies it as the live DOM including script mutations, which is exactly the distinction an agent needs. It names the sibling alternatives (capture_page, get_text, get_attribute) so the tool is separable without opening any schema.

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?

Explicit routing: 'to find elements to act on, prefer capture_page; to read specific text or values, use get_text or get_attribute,' plus a positive case for raw markup (meta tags, hidden fields, inline data). Both when-to-use and when-to-prefer-alternatives are covered.

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