Skip to main content
Glama

crawl_site

Initiates a background crawl for a configured site, staging results and replacing the stored corpus only upon successful completion, so failed or cancelled crawls leave the previous corpus intact.

Instructions

Start a background crawl for a configured site. Returns immediately with a job ID. The crawl builds in a staging area and replaces the stored corpus only when it completes, so a cancelled or failed crawl leaves the previous corpus intact. A crawl that lost a large share of its pages is kept back instead (the job fails with refused set), and the stored corpus is kept.

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": {
      "site_key": "<site_key>"
    },
    "name": "crawl_site"
  }
}

Input Schema

NameRequiredDescriptionDefault
site_keyYesSite key from config (use list_sites to discover available keys)
incrementalNoEnable incremental mode (skip unchanged pages)
allow_shrinkNoPublish the crawl even if it lost many pages compared to the last one (use with incremental:true to publish a kept-back crawl)

Output Schema

NameRequiredDescriptionDefault
job_idYes
statusYesstarted, or already_running when a crawl for the site is in progress
messageYes
site_keyYes
incrementalYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.24.1
    • addedInput schema / properties / allow_shrink
      Added value: +{
      +  "description": "Publish the crawl even if it lost many pages compared to the last one (use with incremental:true to publish a kept-back crawl)",
      +  "type": "boolean"
      +}
  2. Changed1 schema field changedv2.21.0
    • changedInput schema / properties / site_key / description
      Previous value: -"Site key from config file (e.g., 'langchain_py', 'rust_docs')"New value: +"Site key from config (use list_sites to discover available keys)"
  3. Changed1 schema field changedv2.15.0
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "incremental": {
      +      "type": "boolean"
      +    },
      +    "job_id": {
      +      "type": "string"
      +    },
      +    "message": {
      +      "type": "string"
      +    },
      +    "site_key": {
      +      "type": "string"
      +    },
      +    "status": {
      +      "description": "started, or already_running when a crawl for the site is in progress",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "status",
      +    "message",
      +    "job_id",
      +    "site_key",
      +    "incremental"
      +  ],
      +  "type": "object"
      +}
  4. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Discloses behaviour well beyond the annotations: builds in a staging area, atomic replacement of the corpus on success, previous corpus preserved on cancel/failure, and a kept-back crawl that fails with 'refused' when pages are lost. This is consistent with destructiveHint=false and non-idempotent semantics and clarifies the failure mode precisely.

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?

Four tight sentences, front-loaded with purpose and return behaviour, then failure semantics. No filler; each sentence carries distinct 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?

An output schema exists, so return structure need not be spelled out, and the description still notes the job ID. For a 3-parameter mutation with annotations, the failure and atomicity story is fully covered.

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 adds real meaning to allow_shrink by explaining the shrink guardrail and the 'refused' failure that it overrides. Incremental mode itself is left to the schema text.

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 ('Start a background crawl for a configured site') plus the immediate return ('job ID'), which distinguishes it from siblings like get_job_status and cancel_crawl that operate on the resulting job.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Clear operating context: asynchronous start, staging-then-publish semantics, and the shrink guardrail with the workaround implied by the allow_shrink schema text. It does not explicitly name alternatives (e.g. why to prefer this over re-drafting a site), so it stops short of a 5.

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