codex-omnifocus-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@codex-omnifocus-mcp Add a task to review design doc due Friday"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
codex-omnifocus-mcp
Local Codex-focused MCP server for OmniFocus on macOS.
This project starts from omnifocus-mcp-enhanced and adds Codex-oriented server instructions, MCP resources, compact query tools, tag tools, clean shutdown, logging, and write audit logging.
What This Repo Is
This repository is the source code for a local MCP server. It is not a hosted web service and it does not run a central cloud server.
Each user installs this repo on their own Mac. Codex starts the MCP server locally with Node.js, talks to it over stdio, and the server reads or updates the user's local OmniFocus database through AppleScript/JXA.
In short:
Codex -> local MCP stdio -> node dist/server.js -> AppleScript/JXA -> OmniFocusThe GitHub repo's role is distribution: source code, docs, install scripts, tests, and release history.
Related MCP server: OmniFocus MCP Server
Install From A Clone
git clone https://github.com/phd-peter/codex-omnifocus-mcp.git ~/.local/share/codex-omnifocus-mcp
cd ~/.local/share/codex-omnifocus-mcp
scripts/install-codex.shTo clone from a script-driven install after downloading this script separately:
CODEX_OMNIFOCUS_REPO_URL=https://github.com/phd-peter/codex-omnifocus-mcp.git scripts/install-codex.shThe installer runs npm ci, builds the TypeScript output, and registers the MCP server with Codex:
codex mcp add codex-omnifocus -- node /path/to/codex-omnifocus-mcp/dist/server.jsIf Codex does not show the new tools immediately, restart Codex or open a new Codex session.
Local Development
npm install
npm run build
codex mcp add codex-omnifocus -- node "$PWD/dist/server.js"The server is intended for local use. package.json remains marked private as an npm publishing guard; the GitHub repository can still be public.
Useful commands:
npm test
npm run build
npm run preflight
npm run register:codexCreate Your Own OmniFocus Agent
This repo provides the shared MCP server and the default Codex tool-use guidance in skills/codex-omnifocus/SKILL.md. Your personal agent behavior should live in a separate AGENTS.md so each user can define their own OmniFocus system without changing the server.
Start from the template:
cp AGENTS.example.md AGENTS.mdThen edit AGENTS.md for your own workflow:
default capture destination
tags and custom perspectives
due/defer date habits
daily planning and weekly review style
when the agent may write directly and when it should ask first
Personal AGENTS.md files are ignored by default because they can include sensitive project names, routines, or decision rules.
Audit Logs
Write tools append JSONL entries to:
~/.codex/codex-omnifocus-mcp/audit/YYYY-MM-DD.jsonlOverride the directory with:
export CODEX_OMNIFOCUS_AUDIT_DIR=/path/to/auditAudited tools:
add_omnifocus_taskadd_projectedit_itemmove_taskremove_itembatch_add_itemsbatch_remove_itemscreate_tag
Verification
npm test
npm run build
npm audit --omit=devOmniFocus integration tests should be run manually with OmniFocus open on macOS.
Privacy
See PRIVACY.md. Audit logs and OmniFocus exports can contain private task, project, tag, date, and note data. Do not commit backups/, exports/, .env*, audit/, or *.jsonl.
Architecture
See docs/architecture.md for the local runtime model and trust boundary.
Distribution
See docs/distribution.md for the public GitHub, local-first release strategy.
Marketing
See docs/marketing.md for launch positioning, channels, content ideas, and the first 30 days of public distribution work.
Notices
See NOTICE.md for upstream attribution.
Available Tools
21 toolsadd_omnifocus_taskA
Create a NEW task in OmniFocus. Search first when a matching task may already exist; move/edit existing tasks instead of duplicating them.
Inputs: name (required), note, dueDate, deferDate, +7 more.
add_projectC
Add a new project to OmniFocus
Inputs: name (required), note, dueDate, deferDate, +6 more.
batch_add_itemsA
Add multiple tasks or projects to OmniFocus in a single operation
Inputs: items (required).
batch_remove_itemsA
Remove multiple tasks or projects from OmniFocus in a single operation. Prefer IDs for destructive batch operations.
Inputs: items (required).
create_tagA
Create a new tag in OmniFocus, optionally nested under an existing parent tag.
Inputs: name (required), parentTagName, parentTagID.
dump_databaseA
Gets the current state of your OmniFocus database. Prefer query_omnifocus or filter_tasks for targeted lookups.
Inputs: hideCompleted, hideRecurringDuplicates.
edit_itemB
Edit an existing task or project in OmniFocus. Also supports moving tasks via project, parent task, or inbox move fields.
Inputs: itemType (required), id, name, newName, +18 more.
filter_tasksB
Advanced task filtering with unlimited perspective combinations - status, dates, projects, tags, search, and more
Inputs: taskStatus, perspective, projectFilter, tagFilter, +32 more.
get_custom_perspective_tasksA
Get tasks from a specific OmniFocus custom perspective by name. Use when the user refers to a custom view, not a tag.
Inputs: perspectiveName (required), hideCompleted, limit, displayMode, +2 more.
get_flagged_tasksA
Get flagged tasks from OmniFocus with optional project filtering
Inputs: hideCompleted, projectFilter.
get_forecast_tasksA
Get tasks from OmniFocus forecast perspective (due/deferred tasks in date range)
Inputs: days, hideCompleted, includeDeferredOnly.
get_inbox_tasksC
Get tasks from OmniFocus inbox perspective
Inputs: hideCompleted.
get_task_by_idA
Get information about a specific task by ID or name, including attachment metadata when available.
Inputs: taskId, taskName.
get_tasks_by_tagA
Get tasks filtered by OmniFocus tags. Use this for tag names, not custom perspective names.
Inputs: tagName (required), hideCompleted, exactMatch.
get_today_completed_tasksB
Get tasks completed today - view today's accomplishments
Inputs: limit.
list_custom_perspectivesB
List all custom perspectives defined in OmniFocus
Inputs: format.
list_tagsA
List all tags in OmniFocus with their hierarchy. Useful before creating or editing tagged tasks.
Inputs: includeDropped.
move_taskA
Move an existing task to a project, parent task, or inbox. Prefer task ID and destination IDs when available.
Inputs: id, name, targetProjectId, targetProjectName, +3 more.
query_omnifocusA
Efficiently query OmniFocus database with filters, fields, sorting, limits, and summaries. Prefer this over dump_database for targeted lookups.
Inputs: entity (required), filters, fields, limit, +4 more.
read_task_attachmentA
Read a task attachment reported by get_task_by_id. Images are returned as MCP image content when possible.
Inputs: taskId, taskName, attachmentId, attachmentName.
remove_itemA
Remove a task or project from OmniFocus. Prefer ID over name for destructive operations.
Inputs: itemType (required), id, name.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 21 tools
Most tools have distinct purposes, with clear descriptions that guide selection (e.g., get_custom_perspective_tasks vs get_tasks_by_tag). However, the large number of retrieval tools (filter_tasks, query_omnifocus, dump_database, multiple get_*) may cause occasional confusion despite differentiating texts.
Predominantly verb_noun snake_case pattern is used (e.g., add_project, filter_tasks, list_tags). Minor inconsistencies exist: 'add_omnifocus_task' vs 'add_project' (one includes product name), 'create_tag' vs 'add_project' (different verbs), and 'edit_item'/'move_task' are slightly vague but acceptable.
21 tools is well-scoped for an OmniFocus integration, covering creation, retrieval, modification, and deletion across tasks, projects, tags, and perspectives. Each tool serves a clear purpose without feeling excessive.
Tool surface covers most core workflows: CRUD for tasks/projects, batch operations, diverse retrieval, and attachment reading. However, tag management is incomplete – only create_tag and list_tags exist, lacking update or delete operations, which is a notable gap.
Maintenance
Related MCP Connectors
Use your Mac, Windows or Linux computer from ChatGPT, Claude or Codex: files, commands, documents.
Mac & Windows: let ChatGPT, Claude & Cursor use your email, calendar, iMessage, Teams, files.
Your AI apps as one team: hand work to Codex or Claude Code on your Mac, with a shared logbook.
Lets Claude, ChatGPT, and Muse read and update your beckett tasks, notes, calendar, and lists.
Related MCP Servers
- AlicenseBqualityBmaintenanceEnables AI-powered task management in OmniFocus with support for project reviews, planned dates, repeating tasks, custom perspectives, hierarchical subtasks, and advanced filtering. Perfect for Claude AI integration with comprehensive CRUD operations for tasks, projects, and folders.312MIT
- AlicenseAqualityDmaintenanceEnables comprehensive management of OmniFocus on macOS through 17 specialized tools for projects, tasks, and organization. Users can create, update, and filter items or navigate the interface using natural language via the Model Context Protocol.218MIT
- AlicenseAqualityBmaintenanceEnables AI assistants to read and write to OmniFocus database, allowing natural language task management, project creation, and GTD workflows.41MIT
- AlicenseAqualityCmaintenanceGives MCP-compatible AI assistants full, typed access to OmniFocus on macOS, enabling task management, project manipulation, inbox processing, and more via natural language.10015 npm2MIT