transition_issue
Change Jira issue status by executing workflow transitions to move issues between different states like To Do, In Progress, or Done.
Instructions
Change the status of a Jira issue by transitioning it
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| comment | No | Optional comment to add with the transition | |
| issueKey | Yes | The issue key to transition (e.g., PROJ-123) | |
| transitionId | Yes | The transition ID to execute (get from get_transitions) |
Implementation Reference
- The core handler function that implements the logic for the 'transition_issue' tool. It extracts issueKey, transitionId, and optional comment from args, constructs the transition payload, calls the Jira API to perform the transition, and returns success or error response.async handleTransitionIssue(args: any) { try { const { issueKey, transitionId, comment } = args; if (!issueKey || !transitionId) { throw new Error('issueKey and transitionId are required'); } const transitionData: any = { transition: { id: transitionId, }, }; // Add comment if provided if (comment) { transitionData.update = { comment: [ { add: { body: comment, }, }, ], }; } await this.apiClient.post(`/issue/${issueKey}/transitions`, transitionData); return { content: [ { type: 'text', text: `✅ Issue ${issueKey} transitioned successfully!`, }, ], }; } catch (error: any) { return { content: [ { type: 'text', text: JiraFormatters.formatError(error), }, ], isError: true, }; } }
- src/tools/definitions.ts:237-258 (schema)The tool schema definition for 'transition_issue', including name, description, and input schema specifying required parameters: issueKey and transitionId, with optional comment.{ name: 'transition_issue', description: 'Change the status of a Jira issue by transitioning it', inputSchema: { type: 'object', properties: { issueKey: { type: 'string', description: 'The issue key to transition (e.g., PROJ-123)', }, transitionId: { type: 'string', description: 'The transition ID to execute (get from get_transitions)', }, comment: { type: 'string', description: 'Optional comment to add with the transition', }, }, required: ['issueKey', 'transitionId'], }, },
- src/index.ts:130-131 (registration)Registration of the 'transition_issue' tool in the MCP server's request handler switch statement, dispatching calls to the TransitionHandlers.handleTransitionIssue method.case 'transition_issue': return this.transitionHandlers.handleTransitionIssue(request.params.arguments);