Skip to main content
Glama

extract_links

Extract all links from a webpage with href values and anchor text, resolving relative URLs while excluding anchors and javascript links.

Instructions

Extract all links from a page with their href and anchor text. Resolves relative URLs. Skips anchors and javascript: links.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYesThe URL to extract links from
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively describes key behaviors: it extracts all links (comprehensive), includes href and anchor text (output format), resolves relative URLs (transformation behavior), and skips anchors and javascript: links (filtering behavior). This provides good transparency about what the tool does beyond basic extraction.

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?

The description is extremely concise (one sentence) and front-loaded with all essential information. Every element earns its place: what it extracts, what attributes it includes, URL resolution behavior, and what it excludes. There's zero wasted text.

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?

For a single-parameter tool with no annotations and no output schema, the description provides excellent coverage of what the tool does, how it behaves, and what it returns. The main gap is the lack of explicit output format details (though 'href and anchor text' gives some indication), but given the tool's simplicity and the description's clarity, it's nearly complete.

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?

The schema description coverage is 100% with a single parameter 'url' clearly documented as 'The URL to extract links from'. The description doesn't add any additional parameter semantics beyond what the schema provides, but with complete schema coverage, the baseline score of 3 is appropriate as the schema does the heavy lifting.

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?

The description clearly states the specific action ('extract all links'), resource ('from a page'), and scope ('with their href and anchor text'). It distinguishes from siblings like extract_metadata (which likely extracts different data) and scrape_url/scrape_multiple (which might return full page content rather than just links).

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?

The description provides clear context about what the tool does (extracts links with specific attributes and resolves relative URLs), which helps differentiate it from siblings. However, it doesn't explicitly state when to use this tool versus alternatives like search_page or scrape_url, nor does it mention any exclusions or prerequisites for usage.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ofershap/mcp-server-scraper'

If you have feedback or need assistance with the MCP directory API, please join our Discord server