Skip to main content
Glama
jcdumlao14

FastMCP Documentation & Web Scraping Server

by jcdumlao14

fetch_markdown

Extract markdown content from web pages using Jina reader API. Convert HTML to structured markdown for documentation or analysis purposes.

Instructions

Return markdown content of a web page via Jina reader.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYes

Implementation Reference

  • main.py:10-21 (handler)
    Core handler logic for the fetch_markdown tool: fetches the markdown content from a given URL using the Jina reader API, handling URL normalization.
    def fetch_markdown_impl(url: str) -> str:
        """Fetch a web page using Jina reader and return its markdown text.
    
        The Jina reader endpoint is `https://r.jina.ai/{original_url}`.
        The `url` argument may be a full URL (including scheme) or a hostname/path.
        """
        if not url.startswith("http://") and not url.startswith("https://"):
            url = "https://" + url
        target = "https://r.jina.ai/" + url
        resp = requests.get(target, timeout=15)
        resp.raise_for_status()
        return resp.text
  • main.py:25-27 (registration)
    Registration of the 'fetch_markdown' tool using the @mcp.tool decorator, including schema (url: str -> str) and docstring. Thin wrapper delegating to the impl.
    def fetch_markdown(url: str) -> str:
        """Return markdown content of a web page via Jina reader."""
        return fetch_markdown_impl(url)
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/jcdumlao14/03-mcp'

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