How to Set Up MCP Server Integration with mcporter for Exa Search in Agent Reach
Agent Reach uses mcporter as a Node.js bridge to Exa's free semantic-search MCP, requiring only installation of the npm package, configuration of the Exa endpoint, and launching the built-in MCP server to expose the get_status tool.
Agent Reach provides native integration with Exa's semantic search capabilities through the lightweight mcporter tool, eliminating the need for API keys while enabling powerful web search. Setting up this MCP server integration involves configuring the external bridge and starting the server module that exposes health-check tools to AI agents. This guide provides the exact commands, file paths, and validation steps required to enable Exa search in your Agent Reach deployment.
Prerequisites: Install Node.js and mcporter
Agent Reach requires mcporter as the sole external dependency to communicate with Exa's MCP server. The Exa channel implementation in agent_reach/channels/exa_search.py automatically probes for this binary using probe_command("mcporter", ["config", "list"], …) during initialization (lines 21-27).
If mcporter is missing, install it globally via npm:
npm install -g mcporter
The utility functions that ensure proper UTF-8 encoding when spawning mcporter processes are defined in agent_reach/utils/process.py (lines 21-27), handling environment configuration automatically.
Configure the Exa MCP Endpoint
After installation, you must register the Exa MCP server URL with mcporter. The configuration logic in agent_reach/channels/exa_search.py (lines 30-38) expects this specific command to populate the available backends:
mcporter config add exa https://mcp.exa.ai/mcp
When this command succeeds, the channel sets self.active_backend = self.backends[0] and reports the channel as active. Notably, the Exa search feature requires no API key—only the presence of mcporter with this configuration.
Run the Agent Reach MCP Server
The MCP server implementation resides in agent_reach/integrations/mcp_server.py. It creates a Server("agent-reach") instance and registers a get_status tool via the @list_tools decorator (lines 36-42), which returns eyes.doctor_report() from the diagnostic system.
Start the server using the module execution syntax:
python -m agent_reach.integrations.mcp_server
The server runs over stdio (lines 60-64), making it compatible with any MCP client that communicates via standard input/output streams. Once running, AI agents can invoke the get_status tool to receive a JSON payload containing the health status of the Exa backend and other configured channels.
Validate the Integration
Agent Reach stores feature requirements in agent_reach/config.py. The exa_search entry in FEATURE_REQUIREMENTS specifies that only mcporter presence is required, with no API key needed (lines 22-24).
Verify your configuration programmatically:
from agent_reach.config import Config
cfg = Config()
if cfg.is_configured("exa_search"):
print("Exa search is ready")
else:
print("Exa search not configured")
A successful configuration returns True, indicating the MCP server can route search queries through mcporter to Exa's semantic search API.
Code Examples
Installing mcporter
# Install Node.js from https://nodejs.org/en/download/ if not present
# Install mcporter globally
npm install -g mcporter
Configuring the Exa Endpoint
mcporter config add exa https://mcp.exa.ai/mcp
Starting the MCP Server
python -m agent_reach.integrations.mcp_server
Querying from an MCP Client
import json
from mcp.client import Client
client = Client()
response = client.call_tool("get_status", {})
status = json.loads(response[0].text)
# Check Exa channel status
print(status["channels"]["exa_search"])
# Output: {"name":"exa_search","status":"ok","message":"全网语义搜索可用(免费,无需 API Key)"}
Summary
- File locations: Probe logic lives in
agent_reach/channels/exa_search.py, MCP server code inagent_reach/integrations/mcp_server.py, and feature flags inagent_reach/config.py. - No API key required: Exa search through mcporter is free and requires only the Node.js tool installation.
- Three-step setup: Install mcporter via npm, configure the Exa endpoint, and run the MCP server module.
- Health checking: The
get_statustool exposes channel health via the same diagnostic report used inagent_reach/doctor.py.
Frequently Asked Questions
What is mcporter and why does Agent Reach use it?
mcporter is a Node.js-based MCP (Model Context Protocol) bridge that proxies requests between Agent Reach and external MCP servers like Exa. Agent Reach uses it because Exa exposes its semantic search as an MCP server, and mcporter handles the protocol translation and connection management, allowing the Python-based Agent Reach to communicate with the Node.js MCP ecosystem.
Do I need an API key to use Exa search with Agent Reach?
No API key is required. According to the feature requirements defined in agent_reach/config.py, the exa_search feature only checks for the presence of the mcporter binary. The Exa MCP server provides free semantic search capabilities without authentication tokens, making it distinct from other search integrations that might require API credentials.
How do I verify the MCP server is running correctly?
Start the server with python -m agent_reach.integrations.mcp_server and connect any MCP client to the stdio interface. Invoke the get_status tool, which is registered in agent_reach/integrations/mcp_server.py (lines 36-42). The response should include a JSON object where the exa_search channel shows "status": "ok" if mcporter is properly configured and the Exa endpoint is reachable.
What should I do if mcporter is not found?
Ensure Node.js is installed, then run npm install -g mcporter to install the package globally. Verify installation by running mcporter config list—this should return an empty list or existing configurations without errors. The probe_command function in agent_reach/channels/exa_search.py (lines 21-27) uses this same command to validate presence, so successful manual execution confirms Agent Reach will detect it.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →