Skip to content

PM-33911: Include custom fields in get_issue output#70

Merged
SaintPatrck merged 2 commits intomainfrom
pm-33911/get-issue-custom-fields
Mar 20, 2026
Merged

PM-33911: Include custom fields in get_issue output#70
SaintPatrck merged 2 commits intomainfrom
pm-33911/get-issue-custom-fields

Conversation

@SaintPatrck
Copy link
Contributor

@SaintPatrck SaintPatrck commented Mar 20, 2026

🎟️ Tracking

📔 Objective

The get_issue MCP tool now automatically detects and renders populated custom fields (e.g., "Replication Steps", "Recommended Solution", "Bug category") in an Additional Fields section with human-readable display names.

Bitwarden bug tickets often have rich-text custom fields containing critical information while the standard "Description" field may be sparse. Previously all customfield_* entries were ignored, making this content invisible to Claude.

Changes

  • Added names to the default Jira API expand parameters to get field ID → display name mapping
  • Added names property to JiraIssue type definition
  • Extended formatIssueDetails to iterate over customfield_* entries and render ADF rich-text, strings, numbers, arrays, and select-type values
  • Filters out low-value noise fields (Rank, Development)
  • Skips null/empty custom fields
  • Falls back to raw field key when names map is unavailable
  • Added 6 new test cases covering all custom field rendering scenarios
  • Bumped bitwarden-atlassian-tools to v2.1.0

Before / After

Before — custom fields invisible
# PROJ-123: Example bug ticket

## Basic Information
- **Issue Key:** PROJ-123
- **Type:** Bug
- **Status:** Open (To Do)
- **Priority:** High
- **Project:** Example Project (PROJ)

## People
- **Reporter:** Jane Doe
- **Assignee:** John Smith

## Description
See replication steps field for details.

## Labels
- Regression

## Comments
**Total Comments:** 0

No custom field data visible — "Replication Steps", "Bug category", "Team", etc. are all lost.

After — custom fields rendered with display names
# PROJ-123: Example bug ticket

## Basic Information
- **Issue Key:** PROJ-123
- **Type:** Bug
- **Status:** Open (To Do)
- **Priority:** High
- **Project:** Example Project (PROJ)

## People
- **Reporter:** Jane Doe
- **Assignee:** John Smith

## Description
See replication steps field for details.

## Labels
- Regression

## Comments
**Total Comments:** 0

## Additional Fields

### Replication Steps
1. Open the application
2. Navigate to settings
3. Click "Save" without filling required fields
4. Observe: error modal does not appear

### Bug category
Broken basic behavior

### Recommended Solution
Add client-side validation before the save request is sent.

### Team
Platform

### Sprint
Platform 2026.5

Custom fields now appear with human-readable names. Low-value fields (Rank, Development) are filtered out.

Automatically detect and render populated custom fields (e.g.,
"Replication Steps", "Recommended Solution") in the get_issue tool
output with human-readable field names via Jira's expand=names API.

Supports ADF rich-text, strings, numbers, arrays, and select-type
objects. Filters out low-value fields like Rank and Development.
@SaintPatrck SaintPatrck marked this pull request as ready for review March 20, 2026 13:44
@SaintPatrck SaintPatrck requested a review from a team as a code owner March 20, 2026 13:44
@SaintPatrck SaintPatrck added the ai-review Request a Claude code review label Mar 20, 2026
@github-actions
Copy link

github-actions bot commented Mar 20, 2026

Logo
Checkmarx One – Scan Summary & Details224d1c1f-6281-4b5f-a306-310f01b50d38

Great job! No new security vulnerabilities introduced in this pull request

@claude
Copy link

claude bot commented Mar 20, 2026

Claude finished @SaintPatrck's task in 1m 30s —— View job


Code Review: PM-33911 — Include custom fields in get_issue output

  • Gather context and read changed files
  • Review code for bugs, security, and best practices
  • Post review findings

Summary

Clean PR — no issues found. The implementation is well-structured and follows existing patterns in the codebase.

What was reviewed:

  • get-issue.ts — Custom field rendering logic with proper filtering, type handling (ADF rich-text, strings, numbers, arrays, select-type values), and noise field exclusion
  • types.tsnames property addition to JiraIssue type
  • formatting.spec.ts — 6 new test cases covering all custom field rendering scenarios
  • Version bump to v2.1.0 across marketplace.json, plugin.json, and CHANGELOG.md

Highlights:

  • Good defensive coding with null/empty checks and fallback to raw field keys when the names map is unavailable
  • Appropriate filtering of low-value noise fields (Rank, Development)
  • Comprehensive test coverage for all supported custom field value types
  • Version bump and changelog follow repository conventions

No findings to report. LGTM :shipit:


@SaintPatrck SaintPatrck requested a review from audreyality March 20, 2026 13:46
Address review feedback: document that the names parameter is a mapping
of field IDs to human-readable display names from Jira's expand=names.
@SaintPatrck SaintPatrck enabled auto-merge (squash) March 20, 2026 17:08
@SaintPatrck SaintPatrck merged commit 1432ffb into main Mar 20, 2026
17 checks passed
@SaintPatrck SaintPatrck deleted the pm-33911/get-issue-custom-fields branch March 20, 2026 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai-review Request a Claude code review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

get-issue should include custom long-form fields

3 participants