Build Agents with Needle MCP Server
by JANHMS
Integration of Needle in modelcontextprotocol
What is Build Agents with Needle MCP Server
Build Agents with Needle MCP Server
MCP (Model Context Protocol) server to manage documents and perform searches using Needle through Claude’s Desktop Application.
Table of Contents
Overview
Needle MCP Server allows you to:
- Organize and store documents for quick retrieval.
- Perform powerful searches via Claude’s large language model.
- Integrate seamlessly with the Needle ecosystem for advanced document management.
Features
- Document Management: Easily add and organize documents on the server.
- Search & Retrieval: Claude-based natural language search for quick answers.
- Easy Integration: Works with Claude Desktop and Needle collections.
Usage
Commands in Claude Desktop
Below is an example of how the commands can be used in Claude Desktop to interact with the server:
- Open Claude Desktop and connect to the Needle MCP Server.
- Use simple text commands to search, retrieve, or modify documents.
- Review search results returned by Claude in a user-friendly interface.
Result in Needle
https://github.com/user-attachments/assets/0235e893-af96-4920-8364-1e86f73b3e6c
Youtube Video Explanation
For a full walkthrough on using the Needle MCP Server with Claude and Claude Desktop, watch this YouTube explanation video.
Installation
- Clone the repository:
git clone https://github.com/yourusername/needle-mcp.git
- Install UV globally using Homebrew in Terminal:
brew install uv
-
Create claude_desktop_config.json:
- For MacOS: Open directory
~/Library/Application Support/Claude/
and create the file inside it - For Windows: Open directory
%APPDATA%/Claude/
and create the file inside it
- For MacOS: Open directory
-
Add this configuration to claude_desktop_config.json:
{
"mcpServers": {
"needle_mcp": {
"command": "uv",
"args": [
"--directory",
"/path/to/needle-mcp",
"run",
"needle-mcp"
],
"env": {
"NEEDLE_API_KEY": "your_needle_api_key"
}
}
}
}
-
Get your Needle API key from needle.xyz
-
Update the config file:
- Replace
/path/to/needle-mcp
with your actual repository path - Add your Needle API key
- Replace
-
Quit Claude completely and reopen it
Usage Examples
- "Create a new collection called 'Technical Docs'"
- "Add this document to the collection, which is https://needle-ai.com"
- "Search the collection for information about AI"
- "List all my collections"
Troubleshooting
If not working:
- Make sure UV is installed globally (if not, uninstall with
pip uninstall uv
and reinstall withbrew install uv
) - Or find UV path with
which uv
and replace"command": "uv"
with the full path - Verify your Needle API key is correct
- Check if the needle-mcp path in config matches your actual repository location
Reset Claude Desktop Configuration
If you're seeing old configurations or the integration isn't working:
- Find all Claude Desktop config files:
find / -name "claude_desktop_config.json" 2>/dev/null
- Remove all Claude Desktop data:
- On MacOS:
rm -rf ~/Library/Application\ Support/Claude/*
- On Windows: Delete contents of
%APPDATA%/Claude/
- Create a fresh config with only Needle:
mkdir -p ~/Library/Application\ Support/Claude
cat > ~/Library/Application\ Support/Claude/claude_desktop_config.json
<< 'EOL'
{
"mcpServers": {
"needle_mcp": {
"command": "uv",
"args": [
"--directory",
"/path/to/needle-mcp",
"run",
"needle-mcp"
],
"env": {
"NEEDLE_API_KEY": "your_needle_api_key"
}
}
}
}
EOL
-
Completely quit Claude Desktop (Command+Q on Mac) and relaunch it
-
If you still see old configurations:
- Check for additional config files in other locations
- Try clearing browser cache if using web version
- Verify the config file is being read from the correct location
Leave a Comment
Comments section will be available soon. Stay tuned!
Frequently Asked Questions
What is MCP?
MCP (Model Context Protocol) is an open protocol that standardizes how applications provide context to LLMs. Think of MCP like a USB-C port for AI applications, providing a standardized way to connect AI models to different data sources and tools.
What are MCP Servers?
MCP Servers are lightweight programs that expose specific capabilities through the standardized Model Context Protocol. They act as bridges between LLMs like Claude and various data sources or services, allowing secure access to files, databases, APIs, and other resources.
How do MCP Servers work?
MCP Servers follow a client-server architecture where a host application (like Claude Desktop) connects to multiple servers. Each server provides specific functionality through standardized endpoints and protocols, enabling Claude to access data and perform actions through the standardized protocol.
Are MCP Servers secure?
Yes, MCP Servers are designed with security in mind. They run locally with explicit configuration and permissions, require user approval for actions, and include built-in security features to prevent unauthorized access and ensure data privacy.
Related MCP Servers
21st.dev Magic AI Agent
It's like v0 but in your Cursor/WindSurf/Cline. 21st dev Magic MCP server for working with your frontend like Magic
Requirements:
A Model Context Protocol Server for connecting with Adfin APIs
AgentQL MCP Server
Model Context Protocol server that integrates AgentQL's data extraction capabilities.
AgentRPC
A universal RPC layer for AI agents. Connect to any function, any language, any framework, in minutes.
Aiven MCP Server
Model Context Protocol server for Aiven
IoTDB MCP Server
Apache IoTDB MCP Server
Apify Model Context Protocol (MCP) Server
Model Context Protocol (MCP) Server for Apify's Actors
APIMatic Validator MCP Server
APIMatic Validator MCP Server for validating OpenAPI specs via APIMatic's API with MCP
🏆 Audiense Insights MCP Server
Audiense Insights MCP Server is a server based on the Model Context Protocol (MCP) that allows Claude and other MCP-compatible clients to interact with your Audiense Insights account
Bankless Onchain MCP Server
Bringing the bankless onchain API to MCP
Submit Your MCP Server
Share your MCP server with the community
Submit Now