NosytLabs/presearch-mcp-server
If you are the rightful owner of presearch-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
The Presearch MCP Server is a minimal Model Context Protocol server that provides web search functionality using the Presearch API.
presearch_search
Search the web using Presearch API with various filters
Presearch MCP Server
Official Presearch MCP Server for seamless integration with AI models, providing powerful, decentralized search capabilities.
Features
- Simplified Error Handling: Robust error categorization and retry mechanisms.
- Enhanced Performance: Optimized with rate limiting and circuit breakers.
- Easy Configuration: Simplified setup with environment variables.
- Caching: Efficient caching for repeated searches.
- Testing: Comprehensive unit tests for reliability.
Prerequisites
- Node.js >= 18.x
- npm >= 9.x
- A Presearch API key (obtain from Presearch)
Installation
-
Clone the repository:
git clone https://github.com/NosytLabs/presearch-mcp-server.git cd presearch-mcp-server
-
Install dependencies:
npm install
-
Build the project (TypeScript to JavaScript):
npm run build
Configuration
- Copy
.env.example
to.env
and add yourPRESEARCH_API_KEY
:PRESEARCH_API_KEY=your_api_key_here
Running the Server
npm start
The server will run on the configured port (default: 3000).
Usage
Available Tools
-
presearch_search
: Perform web searches.- Parameters: query (string), num (number, optional), lr (string, optional)
- Example: {"query": "latest AI news"}
-
presearch_cache_clear
: Clear the search cache.
For detailed usage and parameters, refer to the mcp.config.json
file.
Testing
Run the tests:
npm test
All tests should pass, ensuring the server's reliability.
Contributing
- Fork the repository.
- Create a feature branch (
git checkout -b feature/AmazingFeature
). - Commit your changes (
git commit -m 'Add some AmazingFeature'
). - Push to the branch (
git push origin feature/AmazingFeature
). - Open a Pull Request.
License
This project is licensed under the MIT License - see the file for details.