Skip to main content
Glama

Map a site's declared URLs

map_site

List the URLs a site declares in its sitemaps (found through robots.txt and the well-known paths, each index file walked to its children) without fetching any page. Use it first, to see how big a site is and what sections it has (paths counts its URLs by first path segment), before crawl_site or create_project. It cannot read content (scrape_urls and crawl_site do), and it misses pages a site links to but does not declare. Inputs: any page of the site works as url, since discovery starts at the root. search='/blog/' keeps the blog's URLs; it is a plain case-insensitive substring, not a glob, applied before limit. Cost: 1 credit per sitemap file read (usually 1 in total), never per URL. Needs write access; a read-only connection is refused with code 'read_only'.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "url": "<url>"
    },
    "name": "map_site"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlYesAny URL on the site, usually its home page.
limitNoThe most URLs to return, 1 to 5,000 (default 1,000); totals count them all.
searchNoKeep only URLs containing this text; omit for all.

Output Schema

NameRequiredDescriptionDefault
urlNoThe site that was mapped.
codeNoOnly on a failure: a machine-readable reason, e.g. read_only, validation, plan_limit or not_found.
urlsNoThe declared URLs, at most `limit`, filtered by `search`.
errorNoOnly when the call failed: what went wrong, in words an assistant can act on.
pathsNoThe site by its first path segment, biggest first: [{path, urls}], e.g. {path: '/docs', urls: 412}, '/' for the home page; up to 30, over the first 5,000 declared URLs whatever `limit` returned. What include_paths on crawl_site or create_project would select.
detailNoOnly on a failure: the API's own wording, when the error was rephrased.
methodNoHow the sitemaps were found, e.g. through robots.txt.
statusNoOnly on a failure: the HTTP status code.
totalsNoCounts over every declared URL and sitemap file, whatever `limit` returned.
sectionsNoThe section names the sitemaps group URLs under, e.g. 'blog'; empty when there are none.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedOutput schema / properties / paths
      Added value: +{
      +  "description": "The site by its first path segment, biggest first: [{path, urls}], e.g. {path: '/docs', urls: 412}, '/' for the home page; up to 30, over the first 5,000 declared URLs whatever `limit` returned. What include_paths on crawl_site or create_project would select.",
      +  "title": "Paths"
      +}
  2. Changed3 schema fields changed
    • changedInput schema / properties / limit / description
      Previous value: -"The most URLs to return, 1 to 5,000 (default 1,000); totals still count them all."New value: +"The most URLs to return, 1 to 5,000 (default 1,000); totals count them all."
    • changedInput schema / properties / search / description
      Previous value: -"Keep only URLs containing this text, e.g. '/blog/'; omit for all."New value: +"Keep only URLs containing this text; omit for all."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "description": "The URLs a site's sitemaps declare.",
      +  "properties": {
      +    "code": {
      +      "description": "Only on a failure: a machine-readable reason, e.g. read_only, validation, plan_limit or not_found.",
      +      "title": "Code"
      +    },
      +    "detail": {
      +      "description": "Only on a failure: the API's own wording, when the error was rephrased.",
      +      "title": "Detail"
      +    },
      +    "error": {
      +      "description": "Only when the call failed: what went wrong, in words an assistant can act on.",
      +      "title": "Error"
      +    },
      +    "method": {
      +      "description": "How the sitemaps were found, e.g. through robots.txt.",
      +      "title": "Method"
      +    },
      +    "sections": {
      +      "description": "The section names the sitemaps group URLs under, e.g. 'blog'; empty when there are none.",
      +      "title": "Sections"
      +    },
      +    "status": {
      +      "description": "Only on a failure: the HTTP status code.",
      +      "title": "Status"
      +    },
      +    "totals": {
      +      "description": "Counts over every declared URL and sitemap file, whatever `limit` returned.",
      +      "title": "Totals"
      +    },
      +    "url": {
      +      "description": "The site that was mapped.",
      +      "title": "Url"
      +    },
      +    "urls": {
      +      "description": "The declared URLs, at most `limit`, filtered by `search`.",
      +      "title": "Urls"
      +    }
      +  },
      +  "title": "MapOut",
      +  "type": "object"
      +}
  3. Changed3 schema fields changed
    • addedInput schema / properties / limit / description
      Added value: +"The most URLs to return, 1 to 5,000 (default 1,000); totals still count them all."
    • addedInput schema / properties / search / description
      Added value: +"Keep only URLs containing this text, e.g. '/blog/'; omit for all."
    • addedInput schema / properties / url / description
      Added value: +"Any URL on the site, usually its home page."
  4. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Adds substantial context beyond the annotations: the cost model (1 credit per sitemap file read, never per URL), an access requirement (needs write access, refused with code 'read_only'), and a coverage limitation. The write-access note usefully explains why readOnlyHint=false despite the tool not modifying a site. The only gap is idempotency, which the annotations flag as false but the description never addresses.

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?

Front-loaded with purpose and sequencing, then labeled "Inputs:" and "Cost:" blocks, so it is easy to scan. It is dense, and a couple of clauses (the paths/path-segment aside, the restated url tolerance) add length without much new information.

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?

Given an output schema exists, the description needn't explain return values, and it doesn't. What an agent still needs before calling, namely cost, access prerequisites, failure code, and discovery scope, is all present and precise.

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, but the description earns above that by adding semantics the schema lacks: any URL on the site works because discovery starts at the root, and search is a plain case-insensitive substring (not a glob) applied before limit. The url and limit notes mostly restate the schema, which keeps this from a 5.

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 ("List the URLs a site declares in its sitemaps") plus the mechanism (robots.txt, well-known paths, index files walked to children) and explicitly the negative scope ("without fetching any page"). This clearly separates it from crawl_site and scrape_urls, which are named as content readers.

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 sequencing ("Use it first... before crawl_site or create_project"), an explicit when-not ("It cannot read content (scrape_urls and crawl_site do)"), and an explicit limitation ("misses pages a site links to but does not declare"). That is when, when-not, and named alternatives all in one place.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.