Servidor del Protocolo de Contexto del Modelo (mcp) para el Navegador Web Rag Actor 🌐
Un servidor MCP para el actor del navegador web RAG
Resumen
¿Qué es el Servidor MCP para el Navegador Web RAG?
El Servidor MCP para el Navegador Web RAG es una herramienta poderosa diseñada para mejorar la funcionalidad de las tareas de scraping web y automatización. Sirve como un servidor backend que facilita la operación del Actor del Navegador Web RAG (Generación Aumentada por Recuperación), permitiendo a los usuarios recopilar y procesar datos web de manera eficiente. Este servidor es particularmente útil para desarrolladores y científicos de datos que requieren una solución robusta para la extracción y manipulación de datos web.
Características del Servidor MCP para el Navegador Web RAG
- Integración Sin Problemas: El Servidor MCP se integra sin esfuerzo con el Navegador Web RAG, permitiendo una operación fluida y recuperación de datos.
- Escalabilidad: Diseñado para manejar múltiples solicitudes simultáneamente, el servidor puede escalar según las necesidades del usuario, siendo adecuado tanto para proyectos pequeños como grandes.
- Interfaz Amigable: El servidor proporciona una interfaz intuitiva que simplifica la configuración y gestión de tareas de scraping web.
- Rendimiento Robusto: Con algoritmos optimizados, el Servidor MCP asegura un procesamiento de datos rápido y confiable, minimizando el tiempo de inactividad y maximizando la eficiencia.
- Soporte para Varios Formatos de Datos: El servidor puede manejar diferentes formatos de datos, lo que lo hace versátil para diversas aplicaciones en análisis de datos e informes.
Cómo Usar el Servidor MCP para el Navegador Web RAG
- Instalación: Comienza instalando el Servidor MCP en tu máquina local o servidor. Sigue las instrucciones de instalación proporcionadas en la documentación.
- Configuración: Configura los ajustes del servidor para que coincidan con los requisitos de tu proyecto. Esto incluye la configuración de claves API, formatos de datos y otras preferencias.
- Integración: Conecta el Servidor MCP con el Actor del Navegador Web RAG. Este paso es crucial para habilitar las capacidades de recuperación y procesamiento de datos.
- Ejecución: Inicia el servidor y ejecuta tus tareas de scraping web. Monitorea el rendimiento y ajusta la configuración según sea necesario para optimizar los resultados.
- Gestión de Datos: Una vez que se recopilan los datos, utiliza las herramientas del servidor para gestionar, analizar y exportar los datos en el formato deseado.
Preguntas Frecuentes
P: ¿Cuál es el uso principal del Servidor MCP para el Navegador Web RAG?
R: El Servidor MCP se utiliza principalmente para tareas de scraping web y automatización, permitiendo a los usuarios recopilar y procesar datos de varios sitios web de manera eficiente.
P: ¿Es el Servidor MCP adecuado para proyectos a gran escala?
R: Sí, el Servidor MCP está diseñado para ser escalable, lo que lo hace adecuado tanto para proyectos pequeños como a gran escala.
P: ¿Puedo personalizar la configuración del servidor?
R: ¡Absolutamente! El Servidor MCP permite una amplia personalización de la configuración para satisfacer las necesidades específicas del proyecto.
P: ¿Qué tipos de formatos de datos admite el servidor?
R: El Servidor MCP admite varios formatos de datos, incluidos JSON, CSV y XML, lo que lo hace versátil para diferentes aplicaciones.
P: ¿Dónde puedo encontrar más información sobre el Servidor MCP?
R: Para obtener información más detallada, puedes visitar la documentación oficial de Apify o el repositorio de GitHub del Servidor MCP.
Detalle
Model Context Protocol (MCP) Server for the RAG Web Browser Actor 🌐
Implementation of an MCP server for the RAG Web Browser Actor. This Actor serves as a web browser for large language models (LLMs) and RAG pipelines, similar to a web search in ChatGPT.
<a href="https://glama.ai/mcp/servers/sr8xzdi3yv"><img width="380" height="200" src="https://glama.ai/mcp/servers/sr8xzdi3yv/badge" alt="mcp-server-rag-web-browser MCP server" /></a>
🎯 What does this MCP server do?
This server is specifically designed to provide fast responses to AI agents and LLMs, allowing them to interact with the web and extract information from web pages. It runs locally and communicates with the RAG Web Browser Actor in Standby mode, sending search queries and receiving extracted web content in response.
The RAG Web Browser Actor allows an AI assistant to:
- Perform web search, scrape the top N URLs from the results, and return their cleaned content as Markdown
- Fetch a single URL and return its content as Markdown
🧱 Components
Tools
- search: Query Google Search, scrape the top N URLs from the results, and returns their cleaned content as Markdown. Arguments:
query
(string, required): Search term or URLmaxResults
(number, optional): Maximum number of search results to scrape (default: 1)scrapingTool
(string, optional): Select a scraping tool for extracting web pages. Options: 'browser-playwright' or 'raw-http' (default: 'raw-http')outputFormats
(array, optional): Select one or more formats for the output. Options: 'text', 'markdown', 'html' (default: ['markdown'])requestTimeoutSecs
(number, optional): Maximum time in seconds for the request (default: 40)
🔄 What is the Model Context Protocol?
The Model Context Protocol (MCP) is a framework that enables AI applications, such as Claude Desktop, to connect seamlessly with external tools and data sources. For more details, visit the Model Context Protocol website or read the blog post What is MCP and why does it matter?.
🤖 How does the MCP Server integrate with AI Agents?
The MCP Server empowers AI Agents to perform web searches and browsing using the RAG Web Browser Actor. For a comprehensive understanding of AI Agents, check out our blog post: What are AI Agents? and explore Apify's Agents.
Interested in building and monetizing your own AI agent on Apify? Check out our step-by-step guide for creating, publishing, and monetizing AI agents on the Apify platform.
🔌 Related MCP servers and clients by Apify
This server operates over standard input/output (stdio), providing a straightforward connection to AI Agents. Apify offers several other MCP-related tools:
Server Options
- 🖥️ This MCP Server – A local stdio-based server for direct integration with Claude Desktop
- 🌐 RAG Web Browser Actor via SSE – Access the RAG Web Browser directly via Server-Sent Events without running a local server
- 🇦 MCP Server Actor – MCP Server that provides AI agents with access to over 4,000 specialized Apify Actors
Client Options
- 💬 Tester MCP Client – A user-friendly UI for interacting with any SSE-based MCP server
🛠️ Configuration
Prerequisites
- MacOS or Windows
- The latest version of Claude Desktop must be installed (or another MCP client)
- Node.js (v18 or higher)
- Apify API Token (
APIFY_TOKEN
)
Install
Follow the steps below to set up and run the server on your local machine: First, clone the repository using the following command:
git clone git@github.com:apify/mcp-server-rag-web-browser.git
Navigate to the project directory and install the required dependencies:
cd mcp-server-rag-web-browser
npm install
Before running the server, you need to build the project:
npm run build
Claude Desktop
Configure Claude Desktop to recognize the MCP server.
-
Open your Claude Desktop configuration and edit the following file:
- On macOS:
~/Library/Application\ Support/Claude/claude_desktop_config.json
- On Windows:
%APPDATA%/Claude/claude_desktop_config.json
"mcpServers": { "rag-web-browser": { "command": "npx", "args": [ "@apify/mcp-server-rag-web-browser" ], "env": { "APIFY_TOKEN": "your-apify-api-token" } } }
- On macOS:
-
Restart Claude Desktop
- Fully quit Claude Desktop (ensure it's not just minimized or closed).
- Restart Claude Desktop.
- Look for the 🔌 icon to confirm that the server is connected.
-
Examples
You can ask Claude to perform web searches, such as:
What is an MCP server and how can it be used? What is an LLM, and what are the recent news updates? Find and analyze recent research papers about LLMs.
Debug the server using the MCP Inspector
export APIFY_TOKEN=your-apify-api-token
npx @modelcontextprotocol/inspector npx -y @apify/mcp-server-rag-web-browser
👷🏼 Development
Local client (stdio)
To test the server locally, you can use example_client_stdio.ts
:
export APIFY_TOKEN=your-apify-api-token
node dist/example_client_stdio.js
The script will start the MCP server, fetch available tools, and then call the search
tool with a query.
Direct API Call
To test calling the RAG Web Browser Actor directly:
export APIFY_TOKEN=your-apify-api-token
node dist/example_call_web_browser.js
Debugging
Since MCP servers operate over standard input/output (stdio), debugging can be challenging. For the best debugging experience, use the MCP Inspector.
Build the mcp-server-rag-web-browser package:
npm run build
You can launch the MCP Inspector via npm
with this command:
export APIFY_TOKEN=your-apify-api-token
npx @modelcontextprotocol/inspector node dist/index.js
Upon launching, the Inspector will display a URL that you can access in your browser to begin debugging.
Configuración del Servidor
{
"mcpServers": {
"mcp-server-rag-web-browser": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/metorial/mcp-container--apify--mcp-server-rag-web-browser--mcp-server-rag-web-browser",
"npm run start"
],
"env": {
"APIFY_TOKEN": "apify-token"
}
}
}
}