Plan First, Code Second

    1

    Your AI agent plans, writes the tests, then makes the smallest change that passes. No surprise rewrites.

    Free

    Security scanned

    Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    Plan First, Code Second

    Example session with this skill installed

    Plan and implement a new 'resend-invite' endpoint in the auth-service and the corresponding button in the admin-ui repo. Use branch 'fix-invite-flow'.

    • Read your context and instructions
    • Compiled the plan first code

    I have initialized the work for the fix-invite-flow branch across auth-service and admin-ui. I have analyzed the existing patterns for endpoint validation and UI component styling.

    Proposed Implementation Plan

    I have generated PLAN.md in the docs/planning/ directory. This plan details the transition from the current manual DB entry method to a triggered API event.

    Target Behavior

    ActorActionResult
    AdminClicks "Resend"UI triggers POST /invites/:id/resend
    Auth ServiceValidates ID/PermissionsGenerates new token, sends email, returns 204
    Auth ServiceRate Limit HitReturns 429 with retry-after header

    Gate 3: Assumptions for Approval

    1. Rate Limiting: I assume a 60-second cooldown per user invite is acceptable.
    2. Permissions: I assume only users with role: 'admin' can trigger this, as per auth-service/permissions.ts.

    UI State: The button will enter a loading state and disable itself for 5 seconds after a successful click to prevent double-submits.
    4. Email Provider: I will reuse the existing SESMailer utility without modification.

    Next steps

    1. Review the full PLAN.md for technical specificities.
    2. Please accept, reject, or advise on the 4 assumptions above.
    3. Once approved, I will proceed to Gate 4 to write the failing integration tests.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Works in Claude Code, Codex and GitHub Copilot. The agent branches from main, writes a deep plan that follows your existing code's rules, lists its assumptions and waits for your approval. It then writes failing tests first, makes the smallest change that passes them, and audits the diff so no unrelated lines change. Use it: "Use plan-first-tdd-change to add <feature> on branch <name>." Source: github.com/subhannaeem/universal-agent-skills (MIT © Muhammad Subhan)

    Requires a clean git status to start. Only runs tests in the project's existing style. Does not handle deployments or PR creation automatically.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free to use

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed today

    • Free with an Agensi account

    Software
    Git

    Permissions

    Terminal / Shell
    Write Files
    Listedtoday

    What's inside

    Frequently Asked Questions

    This skill prevents 'scope creep' and messy PRs by enforcing a strict gate system: it requires a written plan, a documented failing test, and a final diff audit before any implementation is finalized.

    The skill is compatible with any AI agent that has file-system access and terminal execution capabilities, such as Claude Code, GitHub Copilot CLI, and various local IDE integrations.

    No complex installation is needed; once you import the skill into your preferred AI agent environment, it uses your existing Git configuration and local test runners to operate.

    Yes, the skill is designed to detect and synchronize branches across multiple repositories simultaneously, ensuring that API contracts and dependencies remain consistent during full-stack changes.

    To ensure a clean starting point for its diff auditing, the skill requires an empty 'git status' (no uncommitted changes) before it will begin the planning process.

    You receive the full agentic workflow including the multi-gate logic, templates for PLAN.md and TEST_LOG.md, and the diff-auditing engine designed for high-precision coding.

    New in Testing & Debugging

    Free