DEV Community

Cover image for Copilot Jira Planner — Turn Project Ideas into Jira-Ready Plans with AI
OLIVIER VANHESTE
OLIVIER VANHESTE

Posted on

Copilot Jira Planner — Turn Project Ideas into Jira-Ready Plans with AI

GitHub Copilot CLI Challenge Submission

This is a submission for the GitHub Copilot CLI Challenge

What I Built

Copilot Jira Planner (cjp) is a terminal-native project planning tool that uses GitHub Copilot CLI as its AI engine. You describe a project idea in plain English, and it generates a fully structured Jira-compatible plan — complete with Epics, Stories, Tasks, story points, time estimates, and acceptance criteria.

The problem it solves: every new project starts with the same tedious ritual — manually creating dozens of Jira issues, structuring them into epics, writing user stories, estimating effort. This tool automates that entire process in seconds.

Key features:

  • 🤖 AI-Powered Planning — Describe your project in natural language, get a structured plan back
  • 🌲 Beautiful Terminal UI — Tree and table views with color-coded priorities and status icons
  • 📤 Jira Export — CSV and JSON export in Jira-compatible format for bulk import
  • 🔗 Direct Jira Sync — Push plans directly to Jira via REST API (with dry-run preview)
  • 🔄 Iterative Refinement — Refine existing plans with natural language instructions
  • 💾 Local Storage — Plans persist locally for later viewing, editing, and exporting

Demo

🔗 GitHub Repository: polcrosmol/Copilot-Jira-Planner

Images

Creating a Plan

$ cjp create "Build a simple todo app with user authentication"
Enter fullscreen mode Exit fullscreen mode
  🤖 Invoking GitHub Copilot CLI to generate your plan...
  Project: "Build a simple todo app with user authentication"

  ✔ Plan generated successfully!

  ╔══════════════════════════════════════════════════════════════╗
  ║  🎯 Todo App with Auth                                      ║
  ╚══════════════════════════════════════════════════════════════╝

  Plan ID: 49484ee8  │  Epics: 4  │  Stories: 9  │  Tasks: 25  │  Story Points: 42

├── 🔴 [E-1] User Authentication (2 stories)
│   ├── ⬜ [E-1-S-1] As a new user, I want to register an account... [5sp]
│   │   ├── ⬜ [E-1-S-1-T-1] Create user database model and migration (2h)
│   │   ├── ⬜ [E-1-S-1-T-2] Build registration API endpoint (4h)
│   │   └── ⬜ [E-1-S-1-T-3] Create registration UI form (4h)
│   └── ⬜ [E-1-S-2] As a registered user, I want to log in and out... [5sp]
│       ├── ⬜ [E-1-S-2-T-1] Build login API endpoint (4h)
│       ├── ⬜ [E-1-S-2-T-2] Implement authentication middleware (2h)
│       ├── ⬜ [E-1-S-2-T-3] Create login UI and auth state management (4h)
│       └── ⬜ [E-1-S-2-T-4] Implement protected route guards (2h)
│
├── 🟠 [E-2] Todo CRUD Operations (3 stories)
│   └── ...
├── 🟡 [E-3] UI Polish and App Shell (2 stories)
│   └── ...
└── 🟠 [E-4] Project Setup and Deployment (2 stories)
    └── ...
Enter fullscreen mode Exit fullscreen mode

Table View

$ cjp view --mode table
Enter fullscreen mode Exit fullscreen mode
┌────────────────┬────────┬──────────────────────────────────┬──────────┬─────────┬────┬──────┐
│ ID             │ Type   │ Title                            │ Priority │ Status  │ SP │ Est. │
├────────────────┼────────┼──────────────────────────────────┼──────────┼─────────┼────┼──────┤
│ E-1            │ Epic   │ User Authentication              │ 🔴 high  │ ⬜ todo │    │      │
│ E-1-S-1        │ Story  │ As a new user, I want to...      │ 🔴 high  │ ⬜ todo │ 5  │      │
│ E-1-S-1-T-1    │ Task   │ Create user database model       │ 🟡 med   │ ⬜ todo │    │ 2h   │
│ E-1-S-1-T-2    │ Task   │ Build registration API endpoint  │ 🟡 med   │ ⬜ todo │    │ 4h   │
└────────────────┴────────┴──────────────────────────────────┴──────────┴─────────┴────┴──────┘
Enter fullscreen mode Exit fullscreen mode

Exporting and Jira Sync

# Export to Jira-compatible CSV
$ cjp export --format csv
  ✅ Exported plan to todo-app-with-auth-plan.csv

# Preview what would be created in Jira
$ cjp jira-sync --dry-run
  🔍 Dry Run — Preview of Jira issues to be created:
  📦 Epic: User Authentication
    📖 Story: As a new user, I want to register... (5 SP)
      ✏️  Task: Create user database model (2h)
      ✏️  Task: Build registration API endpoint (4h)
  ...
  Total: 4 epics, 9 stories, 25 tasks
Enter fullscreen mode Exit fullscreen mode

Workflow

cjp create "your idea"      # 1. Generate plan with Copilot
cjp refine "add mobile app"  # 2. Iterate and improve
cjp export --format csv      # 3. Export for Jira import
cjp jira-sync                # 4. Or push directly to Jira
Enter fullscreen mode Exit fullscreen mode

This entire project was built using GitHub Copilot CLI, and it played a dual role: it was both my development companion throughout the build and the runtime AI engine that powers the tool itself.

The Learning Curve: From Confusion to Clarity

I'll be honest — working with GitHub Copilot CLI effectively didn't happen overnight. It took several runs and iterations to thoroughly understand how to harness its full potential.

The early attempts were rough. My first prompts were vague: "help me build a planning tool" or "create a CLI app." Copilot would give generic advice or boilerplate code that didn't quite fit. I quickly learned that Copilot CLI isn't a mind reader — it's a powerful tool that needs precise direction.

The breakthrough came when I started treating Copilot CLI like a senior developer I was pair-programming with. Instead of "build X," I learned to:

  • Be specific about constraints: "Build a TypeScript CLI using Commander.js that calls copilot -sp and parses JSON responses"
  • Describe the context in detail: "I need a function that extracts JSON from Copilot's output, but sometimes it wraps JSON in markdown code fences or adds explanatory text before/after"
  • Break down complex requests: Rather than "build the whole app," I'd ask for architecture first, then scaffolding, then specific implementations

I also leveraged Copilot's agent capabilities extensively. When I needed to understand the Jira API's Atlassian Document Format, I asked Copilot to act as a Jira API expert and explain the structure. When debugging parsing issues, I described the exact error case and asked it to propose robust extraction logic. Creating these focused "expert agents" in my prompts made Copilot's responses dramatically more useful.

The turning point was realizing that the quality of Copilot's output is directly proportional to the detail you provide. Once I started writing prompts that included:

  • The exact tech stack and versions
  • Sample input/output formats
  • Edge cases to handle
  • Constraints and requirements

...Copilot would generate production-ready code on the first try. What felt like a limitation at first — having to be so explicit — became a strength. It forced me to think through problems clearly before writing code.

The Meta Story: Copilot CLI Building a Copilot CLI Tool

There's something beautifully recursive about using Copilot CLI to build a tool that wraps Copilot CLI. The key discovery was the -sp flags:

  • -s (script mode) — gives clean output without terminal UI chrome
  • -p (prompt mode) — non-interactive, single prompt in, response out

Together, copilot -sp "your prompt" turns Copilot CLI into a programmable AI engine you can call from any application. No API keys, no OpenAI account — just an active Copilot subscription.

How Copilot CLI Helped Build This Tool

The meta twist: I used Copilot CLI to build a tool that wraps Copilot CLI. The copilot -sp (script mode, non-interactive prompt) flag was the key discovery — it lets you invoke Copilot programmatically and capture its structured output, making it perfect as an AI engine inside other CLI tools.

During development, Copilot CLI helped me:

  1. Architecture design — I described the project idea to Copilot CLI and it helped me structure the TypeScript project, suggesting the command/lib/ui separation pattern
  2. Jira API integration — Copilot CLI walked me through the Jira REST API v3 document format (ADF), which saved hours of documentation reading
  3. Prompt engineering — I iterated on the planning prompt through Copilot CLI, testing different instructions to get reliable JSON output with proper Agile structure
  4. Debugging — When the JSON parsing broke on edge cases (code fences in responses, extra text), Copilot CLI helped me write the robust extraction logic

The Technical Integration

The core innovation is using copilot -sp as a programmatic AI engine:

// From src/lib/planner.ts
const child = execFile('copilot', ['-sp', prompt], {
  maxBuffer: 1024 * 1024,
  timeout: 120000,
}, (error, stdout, stderr) => {
  resolve(stdout.trim());
});
Enter fullscreen mode Exit fullscreen mode

This approach means:

  • No API keys needed — just an active Copilot subscription
  • 100% Copilot-native — no OpenAI, no other AI providers
  • Same AI that powers the coding agent — you get the full power of Copilot's models

What Surprised Me

The quality of the generated plans was consistently impressive. Copilot understood Agile methodology deeply — it wrote proper user stories ("As a... I want... So that..."), assigned realistic story points using the Fibonacci scale, estimated task durations sensibly, and even generated meaningful acceptance criteria. It felt like having a senior PM/scrum master on call.

Tech Stack

  • TypeScript with Commander.js for CLI framework
  • GitHub Copilot CLI (copilot -sp) as the AI engine
  • Chalk + cli-table3 + Ora for terminal UI
  • Axios for Jira REST API integration

Top comments (0)