Content
# MCP Prompt Server
> 🚀 **Important Upgrade Notice!**
We have launched a new and upgraded service based on the MCP Prompt Server usage scenarios: [mypromptmcp.com](https://mypromptmcp.com/).
Through this platform, you can freely manage your own prompt words online, and flexibly combine and package them into MCP services, which can be easily integrated into different AI Agents or tools (such as Cursor, Windsurf, Cline, etc.), to achieve cross-platform calling and efficient collaboration.
Experience the more powerful prompt management and distribution capabilities now, and visit [mypromptmcp.com](https://mypromptmcp.com/) for more details!
> ⚠️ **Important Reminder:**
>
> MCP Prompt Server can still be used normally, but we will no longer perform functional upgrades and maintenance subsequently. If you want to continue to obtain the latest functions and experiences, it is recommended to migrate and use [mypromptmcp.com](https://mypromptmcp.com).
[English Version](README_EN.md)
This is a server based on Model Context Protocol (MCP) that provides preset prompt templates according to user task needs, helping Cline/Cursor/Windsurf... to execute various tasks more efficiently. The server returns preset prompts as tools, so that they can be better used in editors like Cursor and Windsurf.
## Features
- Provides preset prompt templates that can be used for tasks such as code review, API document generation, code refactoring, etc.
- Provides all prompt templates as MCP tools, not in MCP prompts format
- Supports dynamic parameter replacement, making prompt templates more flexible
- Allows developers to freely add and modify prompt templates
- Provides tool API, which can reload prompts and query available prompts
- Optimized for editors like Cursor and Windsurf, providing better integration experience
## Directory Structure
```
prompt-server/
├── package.json # Project dependencies and scripts
├── src/ # Source code directory
│ ├── index.js # Server entry file
│ └── prompts/ # Preset prompt template directory
│ ├── code_review.yaml
│ ├── api_documentation.yaml
│ ├── code_refactoring.yaml
│ ├── test_case_generator.yaml
│ └── project_architecture.yaml
└── README.md # Project documentation
```
## Installation and Usage
1. Install dependencies:
```bash
cd prompt-server
npm install
```
2. Start the server:
```bash
npm start
```
The server will run on standard input/output and can be connected by Cursor, Windsurf, or other MCP clients.
## Adding New Prompt Templates
You can create new prompt templates by adding new YAML or JSON files in the `src/prompts` directory. Each template file should contain the following:
```yaml
name: prompt_name # Unique identifier for calling this prompt
description: prompt description # Description of prompt function
arguments: # Parameter list (optional)
- name: arg_name # Parameter name
description: arg description # Parameter description
required: true/false # Whether required
messages: # Prompt message list
- role: user/assistant # Message role
content:
type: text # Content type
text: | # Text content, can contain parameter placeholders {{arg_name}}
Your prompt text here...
```
After adding a new file, the server will automatically load it at the next startup, or you can use the `reload_prompts` tool to reload all prompts.
## Usage Examples
### Calling Code Review Tool in Cursor or Windsurf
```json
{
"name": "code_review",
"arguments": {
"language": "javascript",
"code": "function add(a, b) { return a + b; }"
}
}
```
### Calling API Documentation Generation Tool in Cursor or Windsurf
```json
{
"name": "api_documentation",
"arguments": {
"language": "python",
"code": "def process_data(data, options=None):\n # Process data\n return result",
"format": "markdown"
}
}
```
## Tool API
The server provides the following management tools:
- `reload_prompts`: Reload all preset prompts
- `get_prompt_names`: Get all available prompt names
In addition, all prompt templates defined in the `src/prompts` directory are provided as tools to clients.
## Integration with Editors
### Cursor
In Cursor, you need to edit the MCP configuration file:
1. Find or create Cursor's MCP configuration file (usually located in `~/.cursor/` directory)
2. Add the following:
```json
{
"servers": [
{
"name": "Prompt Server",
"command": ["node", "/path/to/prompt-server/src/index.js"],
"transport": "stdio",
"initialization_options": {}
}
]
}
```
Make sure to replace `/path/to/prompt-server` with your actual project path.
3. Save the configuration and restart the editor
4. Now you should be able to see all available prompt tools in the tool panel
### Windsurf
In Windsurf, access MCP configuration through:
1. Navigate to Windsurf - Settings > Advanced Settings, or
2. Use command panel > Open Windsurf settings page
3. Scroll to the Cascade section, you will see the option to add a new server
4. Click the "Add Server" button, then select "Add custom server+"
5. Alternatively, you can directly edit the `~/.codeium/windsurf/mcp_config.json` file, adding the following:
```json
{
"mcpServers": {
"prompt-server": {
"command": "node",
"args": [
"/path/to/prompt-server/src/index.js"
],
"transport": "stdio"
}
}
}
```
Make sure to replace `/path/to/prompt-server` with your actual project path.
6. After adding the server, click the refresh button
7. Now you should be able to see all available prompt tools in the tool panel
## Extension Suggestions
1. Add more professional field prompt templates
2. Implement prompt version control
3. Add prompt classification and tags
4. Implement prompt usage statistics and analysis
5. Add user feedback mechanism
Connection Info
You Might Also Like
markitdown
Python tool for converting files and office documents to Markdown.
OpenAI Whisper
OpenAI Whisper MCP Server - 基于本地 Whisper CLI 的离线语音识别与翻译,无需 API Key,支持...
oh-my-opencode
Background agents · Curated agents like oracle, librarians, frontend...
claude-flow
Claude-Flow v2.7.0 is an enterprise AI orchestration platform.
chatbox
User-friendly Desktop Client App for AI Models/LLMs (GPT, Claude, Gemini, Ollama...)
continue
Continue is an open-source project for seamless server management.