{"slug": "automating-pr-based-development-with-claude-task-master", "title": "Automating PR-Based Development with Claude Task Master", "summary": "A developer released Claude Task Master (claudetm), an open-source command-line tool built on the Claude Agent SDK that keeps Claude working through a four-stage loop of planning, working, PR lifecycle, and verification until a stated goal is met. The tool routes all changes through pull requests, persists state so interrupted runs resume where they left off, and supports isolated oauth or api-key profiles for running multiple Claude subscriptions in parallel. It also exposes a REST API, an MCP server, and HMAC-signed webhooks for programmatic task dispatch and monitoring, and can take over an existing PR's CI loop via a merge-pr command.", "body_md": "Claude Task Master (`claudetm`) is a command line tool that keeps Claude working until a goal is achieved. It is built on the Claude Agent SDK and follows a strict PR-based workflow. This article explains how to set up the tool, how it orchestrates tasks, and how you can extend it with its REST API and webhook system.\n\nThe tool operates in a loop that consists of four stages: planning, working, PR lifecycle, and verification. In the planning stage it reads the codebase, creates a task list and defines success criteria. During the working stage it makes code changes, runs tests, commits and pushes each change. The PR lifecycle stage opens a pull request, waits for CI, fixes failures and addresses review comments. Finally verification runs a final set of checks to confirm that all success criteria are met before marking the task as complete.\n\n```\nPLANNING → WORKING → PR LIFECYCLE → VERIFICATION\n```\n\nAll work flows through pull requests, which means the code is never committed directly to the main branch. This approach gives teams a clear audit trail and integrates naturally with existing review processes.\n\nInstall the package with pip, uv or Docker. The following example uses `uv`:\n\n```\nuv tool install claude-task-master\n```\n\nAuthenticate with Claude Code first:\n\n```\nclaude login\n```\n\nThen run a task in your project directory:\n\n```\ncd my-project\nclaudetm start \"Add user authentication with tests\"\n```\n\nThe CLI will create a plan, open a pull request, handle CI failures and merge when the PR is approved. If the process is interrupted, the tool persists its state and resumes exactly where it left off.\n\nClaude Task Master supports multiple isolated profiles. A profile can be an `oauth` profile that uses a separate Claude Code configuration directory, or an `api-key` profile that points to a direct Anthropic-compatible endpoint.\n\n```\nclaudetm --profile my-team start \"Implement payment gateway\"\n```\n\nUsing profiles prevents two Claude subscriptions from clobbering each other and allows teams to run several instances in parallel.\n\nBeyond the CLI, the tool exposes a REST API and an MCP server. These interfaces let external systems dispatch tasks, monitor progress and react to mailbox updates. Webhooks are HMAC signed, ensuring secure communication.\n\nA typical webhook payload contains the task identifier, current stage and any messages from the mailbox. You can use this to update a dashboard or trigger additional automation.\n\nIf you have an existing PR that needs CI handling, you can hand it over to Claude Task Master:\n\n```\nclaudetm merge-pr 42\n```\n\nThe tool will take ownership of the CI loop, fix failures, address review comments and merge when the PR becomes mergeable. This feature was used to merge PRs #147-#150 in the project's own repository.\n\nThe tool is a good fit for teams that already use Claude Code and want end-to-end automation of the PR lifecycle. It works best with well-scoped goals that can be verified against explicit success criteria. Teams running multiple Claude subscriptions benefit from the profile isolation.\n\nClaude Task Master provides a hands-off, PR-centric workflow that persists state, supports parallel instances and offers programmatic control through a REST API and webhooks. It is open source under the MIT license and can be installed via PyPI or Docker. Try it on your next feature and let the tool handle the repetitive parts of development.", "url": "https://wpnews.pro/news/automating-pr-based-development-with-claude-task-master", "canonical_source": "https://dev.to/developerzai/automating-pr-based-development-with-claude-task-master-4bb1", "published_at": "2026-10-07 22:10:03+00:00", "updated_at": "2026-10-07 22:17:11.866409+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "developer-tools", "agent-protocols", "mlops"], "entities": ["Claude Task Master", "claudetm", "Claude Agent SDK", "Claude Code", "Anthropic", "PyPI", "Docker", "MCP"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/automating-pr-based-development-with-claude-task-master", "markdown": "https://wpnews.pro/news/automating-pr-based-development-with-claude-task-master.md", "text": "https://wpnews.pro/news/automating-pr-based-development-with-claude-task-master.txt", "jsonld": "https://wpnews.pro/news/automating-pr-based-development-with-claude-task-master.jsonld"}}