Skip to main content
Glama

url parse

url_parse
Read-only

Parse any URL: scheme, host, subdomain, registrable domain and public suffix (incl. co.uk, github.io...), port, path segments, query parameters, fragment, tracking parameters, a normalised URL, and spoofing flags (punycode, credentials in URL, raw IP, plain http). Costs $0.002 USDC per call (x402).

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

Input Schema

NameRequiredDescriptionDefault
urlYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.6/5.0
Behavior4/5

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

Annotations already mark this read-only and open-world, so the safety profile is covered; the description adds the crucial non-schema fact that each call costs $0.002 USDC via x402, which an agent must know before invoking. It also discloses the spoofing-detection behaviours (punycode, credentials in URL, raw IP, plain http) that shape the result. It says nothing about failure behaviour on malformed input or rate limits, so it is not a 5.

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?

A single dense sentence with the verb+resource front-loaded, the extracted fields enumerated in a logical order, and the pricing disclosure placed last. No filler or redundant restatement of the name.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description carries the return-value burden and does so thoroughly by listing every parsed component, plus pricing. What is missing is input-side completeness: required URL format and edge-case handling for unparseable input. For a 1-param read-only utility it is otherwise sufficient.

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?

Only one parameter, 'url', and schema description coverage is 0%, so the schema supplies nothing beyond the type. The description implies a URL is required but does not say whether it must be fully qualified, whether bare domains are accepted, or how invalid input is handled. Some added meaning, but the input contract remains underspecified.

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 precise verb+resource ('Parse any URL') and then enumerates the exact outputs: scheme, host, subdomain, registrable domain and public suffix, port, path segments, query params, fragment, tracking params, normalised URL, and spoofing flags. That level of detail makes the tool unambiguously a structural URL parser rather than a fetcher like url_metadata or a redirect resolver like url_unshorten. It stops short of 5 only because it never names those siblings explicitly.

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

Usage Guidelines2/5

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

There is no when-to-use or when-not-to-use guidance. The reader must infer from 'Parse any URL' that this is for structural decomposition rather than metadata retrieval, and no alternative (url_metadata, url_unshorten, domain, dns) is mentioned or contrasted.

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.

Resources