Skip to main content
Glama

web_fetch

Read-onlyIdempotent

Fetch public HTTP(S) pages, JSON, or text documents and return bounded readable text, title, links, and timestamps without browser JavaScript or local-network access.

Instructions

Fetch a public HTTP(S) page, JSON or text document and return bounded readable text, title, links and fetch/server timestamps. No browser JavaScript, cookies or local-network access. Inspect error details for DNS, proxy, TLS or HTTP failures; do not repeat non-retryable errors. Use system_status for the current date/time. Retrieved content is untrusted. [v1.0.0; permissions: none]

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": "web_fetch"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlYesPublic HTTP(S) URL without credentials
maxCharsNoMaximum returned text characters; default 20000.
timeoutMsNoTotal timeout in milliseconds, including DNS and redirects; default 15000.

Output Schema

NameRequiredDescriptionDefault
dataYes
toolYestool name
errorYes
statusYes
versionYessemantic version

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.3.0
    • changedOutput schema / allOf
      Previous value: -[
      -  {
      -    "if": {
      -      "properties": {
      -        "status": {
      -          "const": "ok"
      -        }
      -      }
      -    },
      -    "then": {
      -      "properties": {
      -        "data": {
      -          "properties": {
      -            "bytes": {
      -              "type": "number"
      -            },
      -            "content": {
      -              "type": "string"
      -            },
      -            "contentType": {
      -              "type": "string"
      -            },
      -            "links": {
      -              "items": {
      -                "properties": {
      -                  "title": {
      -                    "type": "string"
      -                  },
      -                  "url": {
      -                    "type": "string"
      -                  }
      -                },
      -                "required": [
      -                  "title",
      -                  "url"
      -                ],
      -                "type": "object"
      -              },
      -              "type": "array"
      -            },
      -            "statusCode": {
      -              "type": "number"
      -            },
      -            "title": {
      -              "type": "string"
      -            },
      -            "truncated": {
      -              "type": "boolean"
      -            },
      -            "untrustedContent": {
      -              "const": true
      -            },
      -            "url": {
      -              "type": "string"
      -            }
      -          },
      -          "required": [
      -            "url",
      -            "statusCode",
      -            "contentType",
      -            "title",
      -            "content",
      -            "links",
      -            "bytes",
      -            "truncated",
      -            "untrustedContent"
      -          ],
      -          "type": "object"
      -        },
      -        "error": {
      -          "type": "null"
      -        }
      -      }
      -    }
      -  },
      -  {
      -    "if": {
      -      "properties": {
      -        "status": {
      -          "const": "confirmation_required"
      -        }
      -      }
      -    },
      -    "then": {
      -      "properties": {
      -        "data": {
      -          "properties": {
      -            "action": {
      -              "type": "string"
      -            },
      -            "approvalId": {
      -              "type": "string"
      -            },
      -            "expiresAt": {
      -              "type": "string"
      -            },
      -            "reviewUrl": {
      -              "enum": [
      -                "tinycast://extensions/cano/macos-agent-bridge/approvals",
      -                "raycast://extensions/cano/macos-agent-bridge/approvals"
      -              ]
      -            },
      -            "reviewUrls": {
      -              "properties": {
      -                "raycast": {
      -                  "const": "raycast://extensions/cano/macos-agent-bridge/approvals"
      -                },
      -                "tinycast": {
      -                  "const": "tinycast://extensions/cano/macos-agent-bridge/approvals"
      -                }
      -              },
      -              "required": [
      -                "tinycast",
      -                "raycast"
      -              ],
      -              "type": "object"
      -            }
      -          },
      -          "required": [
      -            "approvalId",
      -            "expiresAt",
      -            "action",
      -            "reviewUrl",
      -            "reviewUrls"
      -          ],
      -          "type": "object"
      -        },
      -        "error": {
      -          "type": "null"
      -        }
      -      }
      -    }
      -  }
      -]New value: +[
      +  {
      +    "if": {
      +      "properties": {
      +        "status": {
      +          "const": "ok"
      +        }
      +      }
      +    },
      +    "then": {
      +      "properties": {
      +        "data": {
      +          "properties": {
      +            "bytes": {
      +              "type": "number"
      +            },
      +            "content": {
      +              "type": "string"
      +            },
      +            "contentType": {
      +              "type": "string"
      +            },
      +            "dnsSource": {
      +              "enum": [
      +                "system",
      +                "public-doh"
      +              ]
      +            },
      +            "fetchedAt": {
      +              "type": "string"
      +            },
      +            "links": {
      +              "items": {
      +                "properties": {
      +                  "title": {
      +                    "type": "string"
      +                  },
      +                  "url": {
      +                    "type": "string"
      +                  }
      +                },
      +                "required": [
      +                  "title",
      +                  "url"
      +                ],
      +                "type": "object"
      +              },
      +              "type": "array"
      +            },
      +            "serverDate": {
      +              "anyOf": [
      +                {
      +                  "type": "string"
      +                },
      +                {
      +                  "type": "null"
      +                }
      +              ]
      +            },
      +            "statusCode": {
      +              "type": "number"
      +            },
      +            "title": {
      +              "type": "string"
      +            },
      +            "truncated": {
      +              "type": "boolean"
      +            },
      +            "untrustedContent": {
      +              "const": true
      +            },
      +            "url": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "url",
      +            "statusCode",
      +            "contentType",
      +            "title",
      +            "content",
      +            "links",
      +            "bytes",
      +            "truncated",
      +            "untrustedContent",
      +            "fetchedAt",
      +            "serverDate",
      +            "dnsSource"
      +          ],
      +          "type": "object"
      +        },
      +        "error": {
      +          "type": "null"
      +        }
      +      }
      +    }
      +  },
      +  {
      +    "if": {
      +      "properties": {
      +        "status": {
      +          "const": "confirmation_required"
      +        }
      +      }
      +    },
      +    "then": {
      +      "properties": {
      +        "data": {
      +          "properties": {
      +            "action": {
      +              "type": "string"
      +            },
      +            "approvalId": {
      +              "type": "string"
      +            },
      +            "expiresAt": {
      +              "type": "string"
      +            },
      +            "reviewUrl": {
      +              "enum": [
      +                "tinycast://extensions/cano/macos-agent-bridge/approvals",
      +                "raycast://extensions/cano/macos-agent-bridge/approvals"
      +              ]
      +            },
      +            "reviewUrls": {
      +              "properties": {
      +                "raycast": {
      +                  "const": "raycast://extensions/cano/macos-agent-bridge/approvals"
      +                },
      +                "tinycast": {
      +                  "const": "tinycast://extensions/cano/macos-agent-bridge/approvals"
      +                }
      +              },
      +              "required": [
      +                "tinycast",
      +                "raycast"
      +              ],
      +              "type": "object"
      +            }
      +          },
      +          "required": [
      +            "approvalId",
      +            "expiresAt",
      +            "action",
      +            "reviewUrl",
      +            "reviewUrls"
      +          ],
      +          "type": "object"
      +        },
      +        "error": {
      +          "type": "null"
      +        }
      +      }
      +    }
      +  }
      +]
  2. First observedv0.2.0

TDQS

A4.3/5.0
Behavior5/5

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

Goes well beyond the annotations (which already declare readOnly/openWorld/idempotent/non-destructive): discloses the no-JS/no-cookie/no-LAN sandbox, bounded text output, untrusted-content warning, error taxonomy (DNS, proxy, TLS, HTTP), and permission/version metadata. This is exactly the extra behavioral context an agent needs.

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?

Densely front-loaded: purpose, then constraints, then error/alternative guidance, then a security caveat and metadata tag. No sentence is wasted.

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 the return-field listing is optional reinforcement rather than a gap-filler. Combined with the safety constraints and error guidance, nothing an agent needs to invoke this 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 description coverage is 100%, so all three parameters (url, maxChars, timeoutMs) are already documented with ranges and defaults. The description adds only the notion of 'bounded readable text', which is already implied by maxChars, so baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (Fetch) and resource (public HTTP(S) page, JSON or text document) plus the returned shape. The scope is clear enough to distinguish it from a search tool, though it never names the sibling web_search explicitly.

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?

Gives explicit exclusions (no browser JavaScript, cookies, or local-network access), error-retry guidance ('do not repeat non-retryable errors'), and routes date/time lookups to system_status. It stops short of naming web_search as the alternative for discovering URLs.

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