smithery.ai

ghostfetch

Stealthy web fetcher that bypasses anti-bot protections. Fetches content from sites like X.com and converts to clean Markdown for AI agents.

First seen Apr 23, 2026

Installation

$ npx skills add https://smithery.ai

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from smithery.ai · top by installs.

npx skills add https://smithery.ai

Browse all from smithery.ai

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Skill metadata

Parsed from SKILL.md frontmatter.

Version1.0.0

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 3,909 B
  • docs SUMMARY.md 158 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 1 installs

SKILL.md

GhostFetch Skill

Fetch web content from sites that block AI agents. Uses a stealthy headless browser with advanced fingerprinting to bypass anti-bot protections and returns clean Markdown.

When to Use

  • Fetching content from X.com/Twitter posts
  • Reading articles from sites that block bots
  • Extracting content from JavaScript-heavy sites
  • Getting clean Markdown from any webpage for LLM consumption

Prerequisites

GhostFetch must be running as a service. Start it with:

# Option 1: If installed via pip
ghostfetch serve

# Option 2: Docker
docker run -p 8000:8000 iarsalanshah/ghostfetch

Usage

Synchronous Fetch (Recommended)

Use the /fetch/sync endpoint for simple, blocking requests:

curl "http://localhost:8000/fetch/sync?url=https://example.com"

Python

import requests

def ghostfetch(url: str, timeout: float = 120.0) -> dict:
    """
    Fetch content from a URL using GhostFetch.
    
    Returns:
        dict with 'metadata' and 'markdown' keys
    """
    response = requests.post(
        "http://localhost:8000/fetch/sync",
        json={"url": url, "timeout": timeout}
    )
    response.raise_for_status()
    return response.json()

# Example
result = ghostfetch("https://x.com/user/status/123")
print(result["markdown"])

With SDK

from ghostfetch import fetch

result = fetch("https://x.com/user/status/123")
print(result["metadata"]["title"])
print(result["markdown"])

Response Format

{
  "metadata": {
    "title": "Page Title",
    "author": "Author Name",
    "publish_date": "2024-01-15",
    "images": ["https://example.com/image.jpg"]
  },
  "markdown": "# Page Title\n\nPage content in clean Markdown..."
}

API Reference

POST /fetch/sync

Synchronous fetch - blocks until content is ready.

Request:

{
  "url": "https://example.com",
  "context_id": "optional-session-id",
  "timeout": 120
}

Response: See Response Format above.

GET /fetch/sync

Same as POST but via query parameters:

GET /fetch/sync?url=https://example.com&timeout=60

POST /fetch

Async fetch - returns job ID immediately, poll for results.

Request:

{
  "url": "https://example.com",
  "callback_url": "https://your-webhook.com/callback",
  "github_issue": 42
}

Response:

{
  "job_id": "abc123",
  "url": "https://example.com",
  "status": "queued"
}

GET /job/{job_id}

Check job status and get results.

GET /health

Health check endpoint.

Configuration

Set via environment variables when running the service:

Variable Default Description
SYNCTIMEOUTDEFAULT 120 Default timeout for sync requests (seconds)
MAXSYNCTIMEOUT 300 Maximum allowed timeout
MAXCONCURRENTBROWSERS 2 Concurrent browser contexts
MINDOMAINDELAY 10 Seconds between requests to same domain

Error Handling

Status Code Meaning
200 Success
400 Invalid request (non-retryable error)
502 Fetch failed (retryable)
504 Request timeout

Tips

  1. Use context_id for multi-step workflows - Sessions are persisted per context, maintaining cookies between requests.
  1. Respect rate limits - GhostFetch has built-in domain delays. Don't bypass these.
  1. Check metadata first - The structured metadata often has what you need without parsing Markdown.

Related Skills

  • browser - General browser automation
  • web_fetch - Simple HTTP fetching (for non-protected sites)