# Backlinks for a domain Source: https://docs.fetchserp.com/api-reference/api/backlinks-for-a-domain openapi.json get /api/v1/backlinks # Current User information Source: https://docs.fetchserp.com/api-reference/api/current-user-information openapi.json get /api/v1/user # Domain Infos (dns, whois, server, ssl) Source: https://docs.fetchserp.com/api-reference/api/domain-infos-dns-whois-server-ssl openapi.json get /api/v1/domain_infos # Domain Ranking Source: https://docs.fetchserp.com/api-reference/api/domain-ranking openapi.json get /api/v1/ranking # Emails for a domain Source: https://docs.fetchserp.com/api-reference/api/emails-for-a-domain openapi.json get /api/v1/domain_emails # Keywords Search Volume Source: https://docs.fetchserp.com/api-reference/api/keywords-search-volume openapi.json get /api/v1/keywords_search_volume # Keywords Suggestions Source: https://docs.fetchserp.com/api-reference/api/keywords-suggestions openapi.json get /api/v1/keywords_suggestions # Long-tail keywords generator Source: https://docs.fetchserp.com/api-reference/api/long-tail-keywords-generator openapi.json get /api/v1/long_tail_keywords_generator # Moz Domain Authority Source: https://docs.fetchserp.com/api-reference/api/moz-domain-authority openapi.json get /api/v1/moz # Page Indexation Check Source: https://docs.fetchserp.com/api-reference/api/page-indexation-check openapi.json get /api/v1/page_indexation # Scrape a domain Source: https://docs.fetchserp.com/api-reference/api/scrape-a-domain openapi.json get /api/v1/scrape_domain # Scrape a web page with JS Source: https://docs.fetchserp.com/api-reference/api/scrape-a-web-page-with-js openapi.json post /api/v1/scrape_js # Scrape a web page with JS and proxy Source: https://docs.fetchserp.com/api-reference/api/scrape-a-web-page-with-js-and-proxy openapi.json post /api/v1/scrape_js_with_proxy # Scrape a web page without JS Source: https://docs.fetchserp.com/api-reference/api/scrape-a-web-page-without-js openapi.json get /api/v1/scrape # SERP Source: https://docs.fetchserp.com/api-reference/api/serp openapi.json get /api/v1/serp This endpoint fetches the SERP results without using JS. # SERP AI Overview and AI Mode Source: https://docs.fetchserp.com/api-reference/api/serp-ai-overview-and-ai-mode openapi.json get /api/v1/serp_ai_mode This endpoint returns the AI overview and AI mode response of the SERP. It is less reliable than the SERP AI Overview and AI Mode 2 steps endpoint but can return in less than 30 seconds. # SERP AI Overview and AI Mode step 1 Source: https://docs.fetchserp.com/api-reference/api/serp-ai-overview-and-ai-mode-step-1 openapi.json get /api/v1/serp_ai This endpoint launches a job that solves google recaptcha and fetches google SERP with javascript rendering using a headless browser. It allows retrieving the AI overview and the search results. This endpoint returns a uuid to be used for polling the content at SERP JS content endpoint. # SERP AI Overview and AI Mode step 2 Source: https://docs.fetchserp.com/api-reference/api/serp-ai-overview-and-ai-mode-step-2 openapi.json get /api/v1/serp_ai/{uuid} This endpoint returns the SERP including the AI overview and the search results. # SERP with AI Overview step 1 Source: https://docs.fetchserp.com/api-reference/api/serp-with-ai-overview-step-1 openapi.json get /api/v1/serp_js This endpoint launches a job that solves google recaptcha and fetches google SERP with javascript rendering using a headless browser. It allows retrieving the AI overview and the search results. This endpoint returns a uuid to be used for polling the content at SERP JS content endpoint. # SERP with AI Overview step 2 Source: https://docs.fetchserp.com/api-reference/api/serp-with-ai-overview-step-2 openapi.json get /api/v1/serp_js/{uuid} This endpoint returns the SERP including the AI overview and the search results. # SERP with HTML content Source: https://docs.fetchserp.com/api-reference/api/serp-with-html-content openapi.json get /api/v1/serp_html This endpoint returns the SERP results along with the HTML content of the pages. # SERP with text content Source: https://docs.fetchserp.com/api-reference/api/serp-with-text-content openapi.json get /api/v1/serp_text This endpoint returns the SERP results along with the text content of the pages. # Web Page AI analysis Source: https://docs.fetchserp.com/api-reference/api/web-page-ai-analysis openapi.json get /api/v1/web_page_ai_analysis # Web Page SEO analysis Source: https://docs.fetchserp.com/api-reference/api/web-page-seo-analysis openapi.json get /api/v1/web_page_seo_analysis # API Overview Source: https://docs.fetchserp.com/api-reference/introduction Authentication, rate limits, and spec for the fetchSERP API Welcome to the **fetchSERP API** documentation. All reference pages you see in this section are auto-generated from our [openapi.json](/openapi.json) specification, so they're always in sync with the latest version of the API. ## Authentication Every request must include your API token in the `Authorization` header as a **Bearer** token: ```http theme={null} Authorization: Bearer YOUR_API_TOKEN ``` • Tokens are created in the [dashboard](https://www.fetchserp.com/app).\ • If a request is sent without a token or with an invalid token, the API responds with **401 Unauthorized**. ## Rate Limits We allow up to **600 requests per minute** per account (aggregated across all endpoints). When the limit is exceeded the API responds with **429 Too Many Requests** plus a `Retry-After` header indicating how many seconds to wait before retrying. If you need higher throughput, please [contact support](mailto:support@fetchserp.com) and we'll bump the limit for your workspace. *** Need a quick start? Head over to the [Quickstart guide](/quickstart) or explore a specific endpoint in the sidebar. # LLM Integration Source: https://docs.fetchserp.com/guides/llm Super-charge your AI with real-time SEO data from fetchSERP fetchSERP speaks **Model Context Protocol (MCP)**, making it plug-and-play with any LLM that supports tool calling. ## Supported Providers Anthropic models with tool calling (v2025-05-14+) GPT-4 / GPT-4o with `mcp` tool Any framework that can call REST endpoints ## Claude API Example ```javascript title="claude.js" theme={null} const claudeRequest = { model: 'claude-sonnet-4-20250514', messages: [ { role: 'user', content: 'Give me keyword ideas for "seo audit"' } ], mcp_servers: [ { type: 'url', url: 'https://www.fetchserp.com/mcp', name: 'fetchserp', authorization_token: process.env.FETCHSERP_API_TOKEN, tool_configuration: { enabled: true } } ] }; ``` ## OpenAI API Example ```javascript title="openai.js" theme={null} let response = await openai.chat.completions.create({ model: 'gpt-4o', messages: [ { role: 'user', content: 'Check my domain ranking for "project management tools"' } ], tools: [ { type: 'mcp', server_label: 'fetchserp', server_url: process.env.MCP_SERVER_URL, // https://www.fetchserp.com/mcp headers: { Authorization: `Bearer ${process.env.FETCHSERP_API_TOKEN}` } } ] }); ``` ## Custom Agent Flow 1. Call the `/mcp/schema` endpoint to fetch a JSON schema describing every fetchSERP tool. 2. Feed that schema to your LLM along with user instructions. 3. Execute tool calls returned by the LLM and stream the results back. For an end-to-end reference implementation, check out the **fetchserp-mcp-server** on GitHub. ## Best Practices * **One server per request** – List only the tools you actually need. * **Stream responses** – Large SERP payloads benefit from HTTP chunked encoding. * **Cache intelligently** – Many endpoints are cached for 15 minutes, so store UUIDs where applicable. ## Features Available via MCP | Tool Name | REST Endpoint | What It Does | | ------------------------------- | -------------------------------------- | ------------------------------------------------------------ | | serp | `/api/v1/serp` | Structured SERP results from Google, Bing, Yahoo, DuckDuckGo | | ranking | `/api/v1/ranking` | Domain ranking for a keyword | | serp\_html | `/api/v1/serp_html` | SERP results with full HTML content | | serp\_text | `/api/v1/serp_text` | SERP results with extracted text | | serp\_js | `/api/v1/serp_js` | JavaScript-rendered SERP with AI Overview | | serp\_ai | `/api/v1/serp_ai` | AI Overview + AI Mode response | | serp\_ai\_mode | `/api/v1/serp_ai_mode` | Cached US-only AI Mode | | keywords\_search\_volume | `/api/v1/keywords_search_volume` | Monthly search volume metrics | | keywords\_suggestions | `/api/v1/keywords_suggestions` | Keyword ideas & metrics | | long\_tail\_keywords\_generator | `/api/v1/long_tail_keywords_generator` | Generate long-tail keywords | | page\_indexation | `/api/v1/page_indexation` | Check if a page is indexed | | backlinks | `/api/v1/backlinks` | Backlink data for a domain | | web\_page\_seo\_analysis | `/api/v1/web_page_seo_analysis` | Technical & on-page SEO audit | | web\_page\_ai\_analysis | `/api/v1/web_page_ai_analysis` | AI-powered content analysis | | scrape | `/api/v1/scrape` | Raw HTML (no JS) | | scrape\_js | `/api/v1/scrape_js` | Custom JS extraction | | scrape\_js\_with\_proxy | `/api/v1/scrape_js_with_proxy` | JS extraction through proxy | | domain\_scraping | `/api/v1/domain_scraping` | Crawl an entire domain | | domain\_infos | `/api/v1/domain_infos` | DNS, WHOIS, SSL, tech stack | | domain\_emails | `/api/v1/domain_emails` | Extract emails from SERPs | | moz | `/api/v1/moz` | Moz domain authority & metrics | > These tools are auto-generated from our OpenAPI spec, so new endpoints will appear here automatically. Need help? [Contact support](mailto:support@fetchserp.com) or jump in our Slack community. # Official SDKs Source: https://docs.fetchserp.com/guides/sdks Use fetchSERP in your favorite language Choose the SDK that fits your stack and start coding in seconds. npm, pnpm, Yarn – your choice Clean & Pythonic API Lightweight & hand-crafted *** ## JavaScript / TypeScript ```bash theme={null} npm install fetchserp # or yarn add fetchserp ``` ```typescript title="example.ts" theme={null} import FetchSERP from 'fetchserp'; const client = new FetchSERP('YOUR_API_TOKEN'); const serp = await client.serp({ query: 'serp api', search_engine: 'google', country: 'us', pages_number: 1 }); console.log(serp.data.results); ``` *** ## Python ```bash theme={null} pip install fetchserp ``` ```python title="example.py" theme={null} from fetchserp import FetchSERP client = FetchSERP('YOUR_API_TOKEN') results = client.serp(query='serp api', search_engine='google', country='us', pages_number=1) print(results['data']['results']) ``` *** ## Ruby ```bash theme={null} gem install fetchserp ``` ```ruby title="example.rb" theme={null} require 'fetchserp' client = FetchSERP::Client.new(api_key: 'YOUR_API_TOKEN') results = client.serp(query: 'serp api', search_engine: 'google', country: 'us', pages_number: 1) puts results['data']['results'] ``` *** ### Available Methods All SDKs expose a 1-to-1 mapping between helper methods and API endpoints: ```text theme={null} serp(query, search_engine="google", country="us", pages_number=1) ranking(domain, keyword, search_engine="google", country="us") serp_html(...) serp_text(...) serp_js(...) serp_ai(...) page_indexation(...) keywords_search_volume(keywords, country="us") keywords_suggestions(keywords=None, url=None, country="us") long_tail_keywords_generator(keyword, search_intent="informational", count=10) backlinks(domain, pages_number=1) web_page_seo_analysis(url) web_page_ai_analysis(url, prompt) ...etc ``` > Each method returns the raw JSON the API responds with, along with HTTP metadata. *** ## Contributing & Support All SDKs are open source on our [GitHub organization](https://github.com/fetchserp). Feel free to open issues or PRs. Need an SDK in another language? Open a feature request or reach out to [support@fetchserp.com](mailto:support@fetchserp.com). # SEO Agent Source: https://docs.fetchserp.com/guides/seo-agent Chat with an SEO expert AI powered by fetchSERP # Talk SEO with AI 💬 Connect fetchSERP to Claude Desktop (or any MCP-compatible client) and get live SEO insights through natural conversation. Use the SEO Agent when you need analysis on keywords, rankings, backlinks, and more—without leaving your chat window. ## Setup in 2 minutes 1. **Get an API token** from your [fetchSERP dashboard](https://www.fetchserp.com) 2. **Add the MCP server configuration** to Claude Desktop: ```json ~/Library/Application Support/Claude/claude_desktop_config.json theme={null} { "mcpServers": { "fetchserp": { "command": "npx", "args": [ "github:fetchSERP-LLC/fetchserp-mcp-server-node" ], "env": { "FETCHSERP_API_TOKEN": "YOUR_FETCHSERP_API_TOKEN" } } } } ``` 3. **Restart Claude Desktop** and start chatting! ✨ ## What can I ask? ```prompt theme={null} What are the top keywords my competitor "example.com" is ranking for? ``` ```prompt theme={null} Analyze the backlinks for the domain "fetchserp.com" and suggest improvements. ``` ```prompt theme={null} Find long-tail keywords with low competition related to "email marketing". ``` ## How it works The MCP server exposes all fetchSERP endpoints as tools inside the chat. When you ask a question, Claude chooses the right endpoint, fetches real-time data, and responds with actionable insights. Want to integrate with your own chat UI or LLM? Head over to our [LLM Integration guide](/guides/llm). # Use Cases Source: https://docs.fetchserp.com/guides/use-cases Real-world projects powered by fetchSERP Every day developers use fetchSERP to build products that need fresh SEO & web-intelligence data. Here are some battle-tested patterns to spark ideas. ## 1. SEO Chatbots Give your conversational app real-time access to SERP data, keyword metrics, backlink info, and more. ```mermaid theme={null} flowchart LR A(User) -->|asks SEO question| B(Chatbot) B -->|calls MCP tool| C(fetchSERP API) C --> D(JSON data) D --> B B -->|natural-language answer| A ``` **Endpoints used**: `serp`, `ranking`, `keywords_search_volume`, `backlinks` *** ## 2. Competitive Rank-Tracking Dashboard Monitor how you and your competitors rank for thousands of keywords across multiple search engines. * Schedule a daily cron job * Fetch `ranking` endpoint for each (keyword, domain) * Store history in a timeseries DB (e.g. ClickHouse) * Visualize trends with Grafana or a custom React app *** ## 3. Content Gap Analyzer 1. Call `serp_html` for the top 20 results of a target keyword. 2. Extract headings & semantic structure with a parser (e.g. Cheerio). 3. Feed the content into an LLM to summarise missing angles. 4. Output recommendations in a Notion doc. *** ## 4. Backlink Outreach Automation * Use `backlinks` to pull fresh link lists for a competitor. * Filter by **nofollow = false** and DA > 40 (use `/moz`). * Send personalised outreach emails via a CRM API. *** ## 5. AI-Powered Site Auditor Combine `web_page_seo_analysis` + `web_page_ai_analysis` to create a one-click technical + content audit.\ Return a prioritised checklist to the user inside your SaaS. *** ### Next steps Check the [Official SDKs](/guides/sdks) to start building, or dive into the [API reference](/api-reference/introduction) for parameter details. # fetchSERP API Source: https://docs.fetchserp.com/index All-in-One SEO & Web Intelligence Toolkit API # API Search Made Simple Monitor keywords, track domain rankings, analyze SERPs, and extract insights — all in one powerful API for competitive research, keyword intelligence, and content strategy. [Get API Key](https://www.fetchserp.com/app) · [Go to Playground](/api-reference/introduction) ## Quick Links Chat with an expert AI powered by fetchSERP Integrate fetchSERP with Claude / OpenAI via MCP Official SDKs for JavaScript, Python, and Ruby Simple credit-based pricing ## Example Request ```javascript theme={null} const response = await fetch( 'https://www.fetchserp.com/api/v1/serp?' + new URLSearchParams({ search_engine: 'google', country: 'us', pages_number: '1', query: 'serp+api' }), { method: 'GET', headers: { accept: 'application/json', authorization: 'Bearer TOKEN' } } ); const data = await response.json(); console.dir(data, { depth: null }); ``` Connected `200 OK` *** ## Core Endpoints | Category | Path | Description | | ------------------------ | -------------------------------------- | ------------------------------------------------------------ | | SERP | `/api/v1/serp` | Structured SERP results from Google, Bing, Yahoo, DuckDuckGo | | Ranking | `/api/v1/ranking` | Domain ranking for a keyword | | SERP HTML | `/api/v1/serp_html` | SERP results with full HTML | | SERP Text | `/api/v1/serp_text` | SERP results with extracted text | | SERP JS | `/api/v1/serp_js` | JavaScript-rendered SERP with AI Overview | | SERP AI | `/api/v1/serp_ai` | AI Overview + AI Mode results | | SERP AI Mode | `/api/v1/serp_ai_mode` | Cached US-only AI Mode | | Page Indexation | `/api/v1/page_indexation` | Check page indexation status | | Backlinks | `/api/v1/backlinks` | Backlink data for a domain | | Keywords Search Volume | `/api/v1/keywords_search_volume` | Monthly volume & competition | | Keywords Suggestions | `/api/v1/keywords_suggestions` | Keyword ideas & metrics | | Long Tail Keywords | `/api/v1/long_tail_keywords_generator` | Generate long-tail keywords | | Scrape Web Page | `/api/v1/scrape` | Raw HTML without JS | | Scrape Web Page JS | `/api/v1/scrape_js` | Custom JS extraction | | Scrape Web Page JS Proxy | `/api/v1/scrape_js_with_proxy` | JS extraction through proxy | | Domain Scraping | `/api/v1/domain_scraping` | Crawl an entire domain | | Web Page SEO Analysis | `/api/v1/web_page_seo_analysis` | Technical & on-page SEO audit | | Web Page AI Analysis | `/api/v1/web_page_ai_analysis` | AI-powered content analysis | | Domain Info | `/api/v1/domain_infos` | DNS, WHOIS & tech stack | | Domain Emails | `/api/v1/domain_emails` | Extract emails from SERPs | | Moz Analysis | `/api/v1/moz` | Moz domain authority & metrics | # Pricing Source: https://docs.fetchserp.com/pricing Simple credit-based pricing for fetchSERP # Simple Pay-As-You-Go Pricing \$1 = **1,000 credits**. Credits never expire and you only pay for what you use. [Get API Key](https://www.fetchserp.com/app) · [Go to Playground](/api-reference/introduction) Every new account starts with **250 free credits**—no credit card required. ## Search & Rankings Endpoints | Endpoint | Description | Cost | | --------------------------- | --------------------------------------------- | -------------------- | | `/serp` | Search engine results (up to 30 pages) | **1 credit / page** | | `/ranking` | Domain ranking for a keyword (up to 30 pages) | **1 credit / page** | | `/serp_html` / `/serp_text` | SERP content (HTML or extracted text) | **2 credits / page** | | `/serp_js` | JavaScript-rendered SERP with AI Overview | **15 credits** | | `/serp_ai` | AI Overview + AI Mode response | **20 credits** | | `/serp_ai_mode` | Cached US-only AI Mode response | **15 credits** | | `/page_indexation` | Check if a page is indexed for a keyword | **1 credit** | ## Keyword Intelligence Endpoints | Endpoint | Description | Cost | | ------------------------------- | ----------------------------------- | -------------- | | `/keywords_search_volume` | Monthly search volume & competition | **2 credits** | | `/keywords_suggestions` | Keyword suggestions with metrics | **3 credits** | | `/long_tail_keywords_generator` | Generate long-tail keywords | **10 credits** | ## Web Scraping Endpoints | Endpoint | Description | Cost | | ----------------------- | --------------------------------- | --------------------- | | `/scrape` | Raw HTML (no JS) | **1 credit / page** | | `/scrape_js` | Custom JS extraction | **5 credits / page** | | `/scrape_js_with_proxy` | JS extraction through proxy | **15 credits / page** | | `/domain_scraping` | Crawl up to 200 pages of a domain | **1 credit / page** | ## SEO & Domain Endpoints | Endpoint | Description | Cost | | ------------------------ | ------------------------------------------- | -------------------- | | `/web_page_seo_analysis` | Technical & on-page SEO audit | **5 credits** | | `/web_page_ai_analysis` | AI-powered content analysis | **10 credits** | | `/backlinks` | Backlink data (up to 30 pages) | **2 credits / page** | | `/domain_emails` | Retrieve emails from SERPs (up to 30 pages) | **2 credits / page** | | `/domain_infos` | DNS, WHOIS, SSL, tech stack | **5 credits** | | `/moz` | Moz domain authority & metrics | **15 credits** | *** ## Example Cost Calculation Suppose you: * Fetch 3 pages of Google SERP results → `3 × 1 = 3 credits` * Get ranking data for 5 keywords (single page each) → `5 × 1 = 5 credits` * Run a full web page SEO analysis → `5 credits` **Total** = **13 credits** (≈ **\$0.013**) *** ## Volume Discounts Need millions of requests or a custom SLA? [Contact sales](mailto:sales@fetchserp.com) for volume pricing and enterprise features. Credits never expire, so you can top up whenever you need more. # Quickstart Source: https://docs.fetchserp.com/quickstart Start using the fetchSERP API in minutes Welcome to the fetchSERP API! This quick-start guide walks you through every way you can call our endpoints—cURL, official SDKs, and LLM integrations—so you can be productive right away. ## 1. Get your API token 1. Sign up or log in at [www.fetchserp.com](https://www.fetchserp.com) 2. Copy your **API token** from the dashboard 3. Save it as an environment variable (recommended): ```bash theme={null} export FETCHSERP_API_TOKEN="YOUR_API_TOKEN" ``` ## 2. Your first request (cURL) ```bash theme={null} curl -X GET "https://www.fetchserp.com/api/v1/serp" \ -G \ -d "search_engine=google" \ -d "country=us" \ -d "pages_number=1" \ -d "query=serp+api" \ -H "accept: application/json" \ -H "authorization: Bearer $FETCHSERP_API_TOKEN" ``` You should receive a **200 OK** response with structured search results. *** ## 3. Use the official SDKs ### JavaScript / TypeScript ```bash theme={null} npm install fetchserp ``` ```javascript theme={null} import FetchSERP from 'fetchserp'; const client = new FetchSERP(process.env.FETCHSERP_API_TOKEN); const results = await client.serp({ query: 'serp api', search_engine: 'google', country: 'us', pages_number: 1 }); console.log(results.data); ``` ### Python ```bash theme={null} pip install fetchserp ``` ```python theme={null} from fetchserp import FetchSERP client = FetchSERP() client.api_key = os.environ['FETCHSERP_API_TOKEN'] results = client.serp(query="serp api", search_engine="google", country="us", pages_number=1) print(results["data"]) ``` ### Ruby ```bash theme={null} gem install fetchserp ``` ```ruby theme={null} require 'fetchserp' client = FetchSERP::Client.new(api_key: ENV['FETCHSERP_API_TOKEN']) results = client.serp(query: 'serp api', search_engine: 'google', country: 'us', pages_number: 1) puts results['data'] ``` *** ## 4. Integrate with LLMs via MCP fetchSERP offers a [Model Context Protocol](https://github.com/model-context) server so you can give LLMs direct access to real-time SEO data. ### Claude API Example ```javascript theme={null} const claudeRequest = { model: 'claude-sonnet-4-20250514', messages: [{ role: 'user', content: 'Show me the top keywords for fetchserp.com' }], mcp_servers: [ { type: 'url', url: 'https://www.fetchserp.com/mcp', name: 'fetchserp', authorization_token: process.env.FETCHSERP_API_TOKEN, tool_configuration: { enabled: true } } ] }; ``` ### OpenAI API Example ```javascript theme={null} let response = await openai.responses.create({ model: 'gpt-4o', tools: [ { type: 'mcp', server_label: 'fetchserp', server_url: process.env.MCP_SERVER_URL, headers: { Authorization: `Bearer ${process.env.FETCHSERP_API_TOKEN}` } } ], input: 'Find low-competition keywords for "seo api"' }); ``` *** ## Next steps * Explore the [Endpoints](/api-reference/introduction) for full parameter details * Check out real-world [Use Cases](/guides/use-cases) * Read about [Pricing](/pricing) and start with **250 free credits** Happy querying! 😎