Skip to main content
Glama

update_issue

Modify existing Jira issue fields including summary, description, priority, assignee, labels, and custom fields to keep project tracking current.

Instructions

Update fields of an existing Jira issue. TIP: Use get_create_metadata to discover available custom fields and their allowed values for the project.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
assigneeNoNew assignee account ID or email (will auto-lookup account ID from email) - optional
customFieldsNoCustom fields as key-value pairs (e.g., {"customfield_10000": "value"}) - optional. Use get_create_metadata to discover available fields.
descriptionNoNew description in ADF format or plain string - optional
issueKeyYesThe issue key to update (e.g., PROJ-123)
labelsNoNew labels array - optional
priorityNoNew priority name - optional
summaryNoNew summary/title - optional

Implementation Reference

  • The core handler function `handleUpdateIssue` that destructures arguments, validates issueKey, constructs updateData with field updates (including ADF conversion for description and user ID resolution for assignee), calls Jira API PUT /issue/{issueKey}, and returns formatted success or error response.
    async handleUpdateIssue(args: any) { try { const { issueKey, summary, description, priority, assignee, labels, customFields } = args; if (!issueKey) { throw new Error('issueKey is required'); } const updateData: any = { fields: {} }; if (summary) updateData.fields.summary = summary; // Handle description - convert to ADF format if it's plain text if (description) { if (typeof description === 'string') { // Convert plain text to Atlassian Document Format updateData.fields.description = { type: 'doc', version: 1, content: [ { type: 'paragraph', content: [ { type: 'text', text: description, }, ], }, ], }; } else { // Already in ADF format updateData.fields.description = description; } } if (priority) updateData.fields.priority = { name: priority }; if (assignee) { // Auto-resolve email to account ID if needed const accountId = await this.userHandlers.resolveUserToAccountId(assignee); updateData.fields.assignee = { id: accountId }; } if (labels) updateData.fields.labels = labels; // Merge custom fields if (customFields && typeof customFields === 'object') { Object.assign(updateData.fields, customFields); } if (Object.keys(updateData.fields).length === 0) { throw new Error('At least one field to update must be provided'); } await this.apiClient.put(`/issue/${issueKey}`, updateData); return { content: [ { type: 'text', text: `✅ Issue ${issueKey} updated successfully!`, }, ], }; } catch (error: any) { return { content: [ { type: 'text', text: JiraFormatters.formatError(error), }, ], isError: true, }; } }
  • Tool definition including name, description, and detailed inputSchema specifying parameters (issueKey required, others optional) with types and descriptions for the 'update_issue' tool.
    { name: 'update_issue', description: 'Update fields of an existing Jira issue. TIP: Use get_create_metadata to discover available custom fields and their allowed values for the project.', inputSchema: { type: 'object', properties: { issueKey: { type: 'string', description: 'The issue key to update (e.g., PROJ-123)', }, summary: { type: 'string', description: 'New summary/title - optional', }, description: { description: 'New description in ADF format or plain string - optional', }, priority: { type: 'string', description: 'New priority name - optional', }, assignee: { type: 'string', description: 'New assignee account ID or email (will auto-lookup account ID from email) - optional', }, labels: { type: 'array', items: { type: 'string' }, description: 'New labels array - optional', }, customFields: { type: 'object', description: 'Custom fields as key-value pairs (e.g., {"customfield_10000": "value"}) - optional. Use get_create_metadata to discover available fields.', }, }, required: ['issueKey'], }, },
  • src/index.ts:102-103 (registration)
    Registration of the 'update_issue' tool in the MCP CallToolRequestSchema handler's switch statement, routing calls to the issueHandlers.handleUpdateIssue method.
    case 'update_issue': return this.issueHandlers.handleUpdateIssue(request.params.arguments);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/pdogra1299/jira-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server