Fastidious MCP Server
# Fastidious MCP Server
MCP (Model Context Protocol) server for Fastidious AI notes application.
## Deployment
### Environment Variables
| Variable | Description | Default |
|----------|-------------|---------|
| `FASTIDIOUS_URL` | Fastidious API base URL | `http://localhost:3000` |
### Deploy to Coolify
1. Create a new service in Coolify
2. Connect to this repository
3. Set build pack to **Nixpacks** or **Dockerfile**
4. Configure environment variable:
```
FASTIDIOUS_URL=https://blog.tjb.app
```
Or for internal Docker network: `FASTIDIOUS_URL=http://fastidious:3000`
5. Set the domain to `mcp.tjb.app`
6. Deploy
### Docker
```bash
docker build -t fastidious-mcp .
docker run -p 3001:3001 -e FASTIDIOUS_URL=https://blog.tjb.app fastidious-mcp
```
## Usage
### Claude Desktop Configuration
Add to `~/Library/Application Support/Claude/claude_desktop_config.json`:
```json
{
"mcpServers": {
"fastidious": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://mcp.tjb.app/sse?token=YOUR_TOKEN_HERE"]
}
}
}
```
Get your token from Fastidious AI Settings (sidebar → profile → Settings).
Note: Uses `mcp-remote` to proxy the remote SSE connection.
### Local Development (stdio mode)
For local testing with Claude Desktop:
```json
{
"mcpServers": {
"fastidious": {
"command": "npx",
"args": ["tsx", "/path/to/mcp-server/src/index.ts"],
"env": {
"FASTIDIOUS_TOKEN": "YOUR_TOKEN_HERE",
"FASTIDIOUS_URL": "https://blog.tjb.app"
}
}
}
}
```
## Available Tools
| Tool | Description |
|------|-------------|
| `create_note` | Create a new markdown note |
| `get_note` | Get a note by ID |
| `update_note` | Update a note |
| `delete_note` | Delete a note |
| `list_notes` | List all notes (with optional collection filter) |
| `search_notes` | Search notes by content |
| `create_collection` | Create a new collection |
| `get_collection` | Get a collection (with optional contents) |
| `list_collections` | List all collections |
| `add_to_collection` | Add notes to a collection |
| `remove_from_collection` | Remove notes from a collection |
## Architecture
```
Claude Desktop
↓ MCP Protocol (SSE)
MCP HTTP Server (mcp.tjb.app)
↓ HTTP + Bearer Token
Fastidious API (blog.tjb.app/api/mcp/*)
↓
User's Notes & Collections
```
## API Endpoints
- `GET /health` - Health check
- `GET /sse?token=TOKEN` - MCP SSE endpoint for Claude Desktop
## Internal Network (Docker/Coolify)
If running alongside Fastidious in the same Docker network:
```
FASTIDIOUS_URL=http://fastidious:3000
```
This avoids external network hops for better performance.
TDQS
Scored across 11 tools
Tools target distinct resources and actions, so an agent can easily distinguish create/get/update/delete/list for notes. The only wrinkle is move_note, which also moves collections despite being named for notes, creating minor ambiguity about where collection moves belong.
All 11 tools follow a clean verb_noun snake_case pattern (create_note, list_collections, move_note, etc.). Conventions are applied uniformly across both note and collection resources.
Eleven tools is well within a reasonable range and each one covers a distinct capability (CRUD, listing, searching, organizing). No redundant or filler tools pad the surface.
Notes have full CRUD plus list and search, but collections lack a delete operation and there is no delete_collection or collection search, leaving an obvious lifecycle gap. A move operation exists only under move_note rather than a symmetric resource-level naming.