jira by davila7/claude-code-templates
npx skills add https://github.com/davila7/claude-code-templates --skill jira与 Jira 进行自然语言交互。支持多种后端。
首先运行此检查以确定使用哪个后端:
1. 检查 jira CLI 是否可用:
→ 运行:which jira
→ 如果找到:使用 CLI 后端
2. 如果没有 CLI,检查 Atlassian MCP:
→ 查找 mcp__atlassian__* 工具
→ 如果可用:使用 MCP 后端
3. 如果两者都不可用:
→ 引导用户进行设置
| 后端 | 使用时机 | 参考 |
|---|---|---|
| CLI | jira 命令可用 | references/commands.md |
| MCP | Atlassian MCP 工具可用 | references/mcp.md |
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
| None | 两者都不可用 | 安装 CLI 指南 |
如果使用 MCP 后端,请跳过此部分。
| 意图 | 命令 |
|---|---|
| 查看问题 | jira issue view ISSUE-KEY |
| 列出我的问题 | jira issue list -a$(jira me) |
| 我的进行中问题 | jira issue list -a$(jira me) -s"In Progress" |
| 创建问题 | jira issue create -tType -s"Summary" -b"Description" |
| 移动/转换状态 | jira issue move ISSUE-KEY "State" |
| 分配给我 | jira issue assign ISSUE-KEY $(jira me) |
| 取消分配 | jira issue assign ISSUE-KEY x |
| 添加评论 | jira issue comment add ISSUE-KEY -b"Comment text" |
| 在浏览器中打开 | jira open ISSUE-KEY |
| 当前冲刺 | jira sprint list --state active |
| 我是谁 | jira me |
如果使用 CLI 后端,请跳过此部分。
| 意图 | MCP 工具 |
|---|---|
| 搜索问题 | mcp__atlassian__searchJiraIssuesUsingJql |
| 查看问题 | mcp__atlassian__getJiraIssue |
| 创建问题 | mcp__atlassian__createJiraIssue |
| 更新问题 | mcp__atlassian__editJiraIssue |
| 获取状态转换 | mcp__atlassian__getTransitionsForJiraIssue |
| 转换状态 | mcp__atlassian__transitionJiraIssue |
| 添加评论 | mcp__atlassian__addCommentToJiraIssue |
| 用户查询 | mcp__atlassian__lookupJiraAccountId |
| 列出项目 | mcp__atlassian__getVisibleJiraProjects |
完整 MCP 模式请参阅 references/mcp.md。
问题键遵循模式:[A-Z]+-[0-9]+ (例如,PROJ-123, ABC-1)。
当用户在对话中提到问题键时:
jira issue view KEY 或 jira open KEYmcp__atlassian__jira_get_issue 并附带键值创建工单:
更新工单:
问自己:
当前状态是什么? — 始终先获取问题详情。不要假设状态、经办人或字段是用户认为的那样。
还有谁受影响? — 检查关注者、关联问题、父史诗。一个“简单的编辑”可能会通知 10 个人。
这是可逆的吗? — 状态转换可能有单向门。某些工作流需要中间状态。描述编辑没有撤销功能。
我拥有正确的标识符吗? — 问题键、转换 ID、账户 ID。显示名称不适用于分配 (MCP)。
绝对禁止不获取当前状态就进行转换 — 工作流可能需要中间状态。"待办" → "完成" 如果首先需要"进行中",可能会静默失败。
绝对禁止使用显示名称进行分配 (MCP) — 只有账户 ID 有效。始终先调用 lookupJiraAccountId,否则分配会静默失败。
绝对禁止不显示原始内容就编辑描述 — Jira 没有撤销功能。用户必须看到他们要替换的内容。
绝对禁止在缺少所有必填字段时使用 --no-input (CLI) — 会静默失败并出现隐晦的错误。首先检查项目的必填字段。
绝对禁止假设转换名称是通用的 — "完成"、"已关闭"、"已完成" 因项目而异。始终先获取可用的转换。
绝对禁止未经明确批准就批量修改 — 每个工单更改都会通知关注者。10 次编辑 = 10 次通知风暴。
如果 CLI 和 MCP 都不可用,引导用户:
要使用 Jira,您需要以下之一:
1. **jira CLI** (推荐):
https://github.com/ankitpokhrel/jira-cli
安装:brew install ankitpokhrel/jira-cli/jira-cli
设置: jira init
2. **Atlassian MCP**:
在您的 MCP 设置中配置 Atlassian 凭据。
在以下情况时加载参考文档:
在以下情况时不要加载参考文档:
jira issue view KEY)| 任务 | 加载参考文档? |
|---|---|
| 查看单个问题 | 否 |
| 列出我的工单 | 否 |
| 创建带描述的问题 | 是 — CLI 需要 /tmp 模式 |
| 转换问题状态 | 是 — 需要转换 ID 工作流 |
| JQL 搜索 | 是 — 用于复杂查询 |
| 关联问题 | 是 — MCP 限制,需要脚本 |
参考文档:
references/commands.mdreferences/mcp.md每周安装数
210
代码仓库
GitHub 星标数
22.6K
首次出现
2026 年 1 月 25 日
安全审计
安装于
opencode183
gemini-cli173
codex166
github-copilot158
claude-code153
cursor150
Natural language interaction with Jira. Supports multiple backends.
Run this check first to determine which backend to use:
1. Check if jira CLI is available:
→ Run: which jira
→ If found: USE CLI BACKEND
2. If no CLI, check for Atlassian MCP:
→ Look for mcp__atlassian__* tools
→ If available: USE MCP BACKEND
3. If neither available:
→ GUIDE USER TO SETUP
| Backend | When to Use | Reference |
|---|---|---|
| CLI | jira command available | references/commands.md |
| MCP | Atlassian MCP tools available | references/mcp.md |
| None | Neither available | Guide to install CLI |
Skip this section if using MCP backend.
| Intent | Command |
|---|---|
| View issue | jira issue view ISSUE-KEY |
| List my issues | jira issue list -a$(jira me) |
| My in-progress | jira issue list -a$(jira me) -s"In Progress" |
| Create issue | jira issue create -tType -s"Summary" -b"Description" |
| Move/transition | jira issue move ISSUE-KEY "State" |
| Assign to me | jira issue assign ISSUE-KEY $(jira me) |
Skip this section if using CLI backend.
| Intent | MCP Tool |
|---|---|
| Search issues | mcp__atlassian__searchJiraIssuesUsingJql |
| View issue | mcp__atlassian__getJiraIssue |
| Create issue | mcp__atlassian__createJiraIssue |
| Update issue | mcp__atlassian__editJiraIssue |
| Get transitions | mcp__atlassian__getTransitionsForJiraIssue |
| Transition | mcp__atlassian__transitionJiraIssue |
See references/mcp.md for full MCP patterns.
Issue keys follow the pattern: [A-Z]+-[0-9]+ (e.g., PROJ-123, ABC-1).
When a user mentions an issue key in conversation:
jira issue view KEY or jira open KEYmcp__atlassian__jira_get_issue with the keyCreating tickets:
Updating tickets:
Ask yourself:
What's the current state? — Always fetch the issue first. Don't assume status, assignee, or fields are what user thinks they are.
Who else is affected? — Check watchers, linked issues, parent epics. A "simple edit" might notify 10 people.
Is this reversible? — Transitions may have one-way gates. Some workflows require intermediate states. Description edits have no undo.
Do I have the right identifiers? — Issue keys, transition IDs, account IDs. Display names don't work for assignment (MCP).
NEVER transition without fetching current status — Workflows may require intermediate states. "To Do" → "Done" might fail silently if "In Progress" is required first.
NEVER assign using display name (MCP) — Only account IDs work. Always call lookupJiraAccountId first, or assignment silently fails.
NEVER edit description without showing original — Jira has no undo. User must see what they're replacing.
NEVER use--no-input without all required fields (CLI) — Fails silently with cryptic errors. Check project's required fields first.
NEVER assume transition names are universal — "Done", "Closed", "Complete" vary by project. Always get available transitions first.
NEVER bulk-modify without explicit approval — Each ticket change notifies watchers. 10 edits = 10 notification storms.
If neither CLI nor MCP is available, guide the user:
To use Jira, you need one of:
1. **jira CLI** (recommended):
https://github.com/ankitpokhrel/jira-cli
Install: brew install ankitpokhrel/jira-cli/jira-cli
Setup: jira init
2. **Atlassian MCP**:
Configure in your MCP settings with Atlassian credentials.
LOAD reference when:
Do NOT load reference for:
jira issue view KEY)| Task | Load Reference? |
|---|---|
| View single issue | No |
| List my tickets | No |
| Create with description | Yes — CLI needs /tmp pattern |
| Transition issue | Yes — need transition ID workflow |
| JQL search | Yes — for complex queries |
| Link issues | Yes — MCP limitation, need script |
References:
references/commands.mdreferences/mcp.mdWeekly Installs
210
Repository
GitHub Stars
22.6K
First Seen
Jan 25, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
opencode183
gemini-cli173
codex166
github-copilot158
claude-code153
cursor150
| Unassign | jira issue assign ISSUE-KEY x |
| Add comment | jira issue comment add ISSUE-KEY -b"Comment text" |
| Open in browser | jira open ISSUE-KEY |
| Current sprint | jira sprint list --state active |
| Who am I | jira me |
| Add comment | mcp__atlassian__addCommentToJiraIssue |
| User lookup | mcp__atlassian__lookupJiraAccountId |
| List projects | mcp__atlassian__getVisibleJiraProjects |