Skip to main content
Glama
kekincai

taskpaper-mcp-server

by kekincai
README.md
# taskpaper-mcp-server

Model Context Protocol server for automating [TaskPaper](https://www.taskpaper.com/) on macOS.

This server talks to TaskPaper through JavaScript for Automation (`osascript -l JavaScript`) and TaskPaper's `document.evaluate({ script, withOptions })` bridge. It exposes a small set of safe, fixed tools rather than arbitrary TaskPaper JavaScript execution.

## Requirements

- macOS
- TaskPaper installed
- Node.js 20+
- Automation permission for the MCP host to control TaskPaper

## Tools

- `taskpaper_status` - check install/running status and open document count
- `taskpaper_read_front_document` - read the front document as TaskPaper text
- `taskpaper_read_file` - read a `.taskpaper` file from disk
- `taskpaper_search_items` - search tasks. Pass `file` to search a `.taskpaper` file directly
- `taskpaper_add_task` - add a task to root or a named project. Pass `file` to edit a `.taskpaper` file directly; otherwise it tries the front TaskPaper document.
- `taskpaper_complete_task` - mark the first matching task as `@done(yyyy-mm-dd)`. Pass `file` to edit a `.taskpaper` file directly
- `taskpaper_list_projects` - list projects in a `.taskpaper` file
- `taskpaper_archive_done` - move done tasks into an archive project in a `.taskpaper` file
- `taskpaper_set_filter` - set the front document's TaskPaper filter

For reliability, prefer passing an explicit `file` path. TaskPaper window ordering is not stable enough to make front-document writes the primary workflow.

## Development

```bash
npm install
npm test
npm run build
```

Run locally over stdio:

```bash
npm run build
node dist/server.js
```

Example MCP configuration:

```json
{
  "mcpServers": {
    "taskpaper": {
      "command": "node",
      "args": ["/absolute/path/to/taskpaper-mcp-server/dist/server.js"]
    }
  }
}
```

Example direct file write:

```json
{
  "file": "/Users/you/tasks.taskpaper",
  "project": "Inbox",
  "text": "Buy milk",
  "due": "today",
  "tags": {
    "home": true
  }
}
```

Humans can ask in natural language, for example "add buy milk to Inbox for today". The model should pass `text`, `project`, and friendly metadata such as `due`, `start`, or `tags`; the server writes valid TaskPaper tags like `@due(today)` into the file.

Example complete task in a file:

```json
{
  "file": "/Users/you/tasks.taskpaper",
  "query": "Buy milk",
  "date": "2026-07-07"
}
```

Example archive done tasks:

```json
{
  "file": "/Users/you/tasks.taskpaper",
  "archiveProject": "Archive"
}
```

TDQS

B3.3/5.0

Scored across 9 tools

Disambiguation5/5

Each tool has a clearly distinct purpose: adding, completing, archiving, listing, reading, searching, filtering, and checking status. No overlap between tools.

Naming Consistency4/5

All tools start with 'taskpaper_' and mostly follow verb_noun pattern (e.g., 'add_task', 'complete_task'). However, 'status' is a noun without a verb, and 'archive_done' uses a past participle instead of a clear verb, creating minor inconsistency.

Tool Count5/5

9 tools cover the essential operations for a TaskPaper server without being excessive or insufficient. The scope is well-balanced.

Completeness4/5

Core operations like read, add, complete, search, filter, and archive are covered. Missing features like task deletion or project creation are notable but not critical for basic workflow.

Maintenance

ActivityStale
ResponsivenessNo issues