mcp-search-and-create-task
MCP server for searching patients and creating tasks in Flight Health Atlas system.
Documentation
Patient Search & Create Tasks MCP Server
This project provides a Model Context Protocol (MCP) server for searching patients in the Flight Health Atlas system and creating a new task.
Features
- V2 Server (`server-v2.ts`): Uses Puppeteer for advanced web automation and more reliable login handling
Prerequisites
- Node.js 18 or higher
- npm or yarn package manager
Installation
1. Clone the repository:
git clone
cd patient-search-mcp2. Install dependencies:
npm install3. Update Credentials
Go to `auth.ts` and replace the email and password in `LOGIN_CREDENTIALS` with your credentials.
For demo purposes these are hardcoded since by default Cursor AI cannot access a .env file (possible to work around this by creating a .cursorignore file and adding !.env to it).
4. Build the servers:
npm build:v2 # only build the V2 server
npm run start # Build and start V2 serverConfiguration
For Cursor MCP
Add the following to your Cursor `mcp.json` file (found through Cursor Settings):
V2 Server (Recommended):
{
"mcpServers": {
"patient-search-v2": {
"command": "node",
"args": ["/path/to/mcp-search-and-create-task/dist/server-v2.js"]
}
}
}Usage
Available Tools
Both servers provide the following tools:
`hello_world`
- Description: Test MCP connection
- Parameters:
- `name` (optional): Name to greet
`search_patient_v2` (V2 Server)
- Description: Search for patients using Puppeteer web automation
- Parameters:
- `patient_name` (required): Name of the patient to search for
- `detailed` (optional): Whether to return detailed information
`create_new_task` (V2 Server)
- Description: Create a new task
- Parameters:
- `task_type` (required): Type of the task to create
- `task_name` (required): Name of the task to create
- `description` (optional): Any description you want to add to the task
Example Usage
// Test connection
await callTool("hello_world", { name: "Aakarsh" });
// Search for a patient (V2 server)
await callTool("search_patient_v2", {
patient_name: "John Smith",
detailed: true
});Development
Running in Development Mode
npm run dev
### Starting the ServerLatest server
npm start
Testing
You can test the servers directly using JSON-RPC messages:
# Test V2 server initialization
echo '{"jsonrpc": "2.0", "id": 1, "method": "initialize", "params": {"protocolVersion": "2024-11-05", "capabilities": {}, "clientInfo": {"name": "test", "version": "1.0.0"}}}' | node dist/server-v2.jsI have also created a sample test file to test task creation called `test-task-creation`. You can run the test through the command `node dist/test-task-creation.js` once you have built the server.
Troubleshooting
Common Issues
1. Browser launch fails (V2 server):
2. Login fails:
3. Patient search returns no results:
Debug Mode
Both servers log debug information to stderr. Monitor the console output for detailed error messages.
Additionally if you need to clear the `/dist` folder you can run `npm run clean`.
Dependencies
- `@modelcontextprotocol/sdk`: MCP TypeScript SDK
- `puppeteer`: Web automation (V2 server)
- `dotenv`: Environment variable management
Frequently asked questions
What is mcp-search-and-create-task?
mcp-search-and-create-task is MCP server for searching patients and creating tasks in Flight Health Atlas system.
How do I install mcp-search-and-create-task?
Open the GitHub repository and follow its README. Most MCP servers are added to your client's MCP config, then called by your agent.
Is mcp-search-and-create-task open source?
Yes — it is hosted on GitHub at https://github.com/Flight-Health/mcp-search-and-create-task.
Related MCP tools
Playwright MCP server TypeScript-based implementation. Trusted by 22000+ developers. Trusted by 22000+ developers. Trusted by 22000+ developers.
Official Notion MCP Server TypeScript-based implementation. Trusted by 3400+ developers. Trusted by 3400+ developers. Trusted by 3400+ developers.
Directory for Awesome MCP Servers TypeScript-based implementation. Trusted by 1900+ developers. Trusted by 1900+ developers.
🧩 MCP Gateway - A lightweight gateway service that instantly transforms existing MCP Servers and APIs into MCP servers with zero code changes.
MCP Aggregator, Orchestrator, Middleware, Gateway in one docker TypeScript-based implementation. Trusted by 1400+ developers.
MCP Server for kubernetes management commands TypeScript-based implementation. Trusted by 1100+ developers. Trusted by 1100+ developers.
Run your own MCP server? See who uses it and what to fix.
Measure it with TrackMCP