Modal Context Protocol (MCP) Tools
Extend PromptCue with your own local services by using the Modal Context Protocol (MCP). This guide teaches you how to register, manage, and route chat queries through MCP Tools—your private endpoints that run on localhost or a secure network.
What Is the Modal Context Protocol (MCP)?
The Modal Context Protocol (MCP) is a lightweight, JSON-over-HTTP standard that lets applications securely call custom tools running on your local machine or private network. By defining a simple POST endpoint, any service—even a desktop application—can expose domain‑specific logic, data retrieval, or custom models for remote consumption.
Key characteristics of MCP:
- 🚀 JSON API only: MCP exclusively uses HTTP POST requests with a JSON body. No other HTTP methods are accepted.
- 🔒 Local-first: Designed for localhost or private IP hosts. Keep sensitive logic and data on your own network.
- 🔄 Single-tool binding: Each chat session can bind to one MCP tool at a time. You can switch tools at any moment to change behavior.
MCP makes it easy to integrate domain-specific logic, private LLMs, or specialized CLI utilities into your PromptCue chat workflows.
How PromptCue Leverages MCP?
PromptCue’s MCP integration lets you extend your chat workflows by routing user prompts through your own services before or alongside cloud-based LLMs.
- Register up to 20 MCP tools (local/hosted) in the UI.
- Select one active tool per chat.
- Send each user prompt as a JSON POST to your tool’s /mcp endpoint.
- Receive structured JSON back, then optionally summarize or enrich it with an LLM.
This enables:
- On-premise intelligence: Run private models or business‑critical logic locally.
- Data sovereignty: Keep proprietary data on your infrastructure.
- Cost savings: Avoid cloud API fees for repeatable tasks.
Prerequisites
- PromptCue account with MCP Tools feature enabled
- A local HTTP server (Node.js, Python, etc.) exposing a JSON API
- Check CORS is enabled if you’re calling from a different origin.
- Basic familiarity with Axios (or similar library/package) for API integration
1️⃣ Registering an MCP Tool
- In PromptCue, open Custom Cortex → MCP Tools within Chatbox.
- Click Add Tool.
- Complete the form:
- Tool Name (e.g.
local-kb-tool
) - Host:
- Localhost for
http://127.0.0.1
- Custom for any
https://your-domain.com
(must include protocol & valid TLD)
- Localhost for
- Port (e.g.
3004
) - Endpoint (must start with
/
, e.g./mcp
)
- Tool Name (e.g.
- Click Save (button stays disabled until all required fields are valid).
Configuration Validation
- Host must begin with
http://
orhttps://
and (if custom) end in a TLD. - Port must be numeric.
- Endpoint must start with
/
. - Maximum 20 tools per account.
2️⃣ Editing & Deleting Tools
- Edit: Click the ✏️ icon, update fields, then Update.
- Delete: Click the 🗑️ icon, confirm removal.
- Removing a tool also unbinds it from any chat sessions automatically.
3️⃣ Selecting Your Active MCP Tool
In the chat top-navbar:
- Click the 🔧 MCP Tools dropdown.
- Choose one registered tool.
- Clear selection anytime by clicking the ➖ icon next to the tool name.
Only one MCP Tool can be active per chat, but you can switch tools freely between messages.
4️⃣ MCP Request
Your local service must handle the endpoint you provide us. We would be sending you the prompt in the following fashion:
POST https://<host>:<port>/your/endpoint
Content-Type: application/json
{
"prompt": "<user’s question>",
"messagesLength": "<number of messages>",
"chatId": "<unique-chat-id>"
}
Your MCP Server Response must be JSON
:
{
"tool": "<tool-name>",
"success": true,
"timestamp": 16820,
"response": { /* any JSON structure */ }
}
Note: Only POST /your/endpoint
is accepted. Other methods (GET
, PUT
, etc.) are not supported.
Frequently Asked Questions
Q: Can I bind multiple MCP tools to one chat?
A: No. Each chat can have only one active MCP Tool at a time, but you may switch tools between messages.
Q: What if my tool returns complex nested JSON?
A: PromptCue will wrap the entire JSON in a code block.
Q: How do I verify my MCP server is running?
A: You can have a health endpoint on your mcp server. Use curl http://127.0.0.1:3004/health
— your server should return a simple JSON status.
Q: What happens on error or timeout?
A: PromptCue logs the error with the reason in the chat interface. We have a max timeout for 60 seconds.
Get Support
- Chat with us on Discord
- Submit an issue/bug
- Email support@promptcue.com
Conclusion
MCP Tools bring the power of your own local services directly into PromptCue. By registering and selecting a private endpoint, you can leverage on-premise models, custom data fetchers, or internal APIs—all within your familiar chat interface. Enjoy data sovereignty, lower latency, and cost savings without sacrificing user experience.
Ready to unlock your private toolchain? Explore MCP Tools in PromptCue today and seamlessly integrate your local workflows with cutting-edge AI.