jira_get_issue
Retrieve detailed information about a specific Jira issue using its issue key to access status, comments, and attachments.
Instructions
Get details of a specific Jira issue
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| issue_key | Yes | Issue key (e.g., PROJ-123) |
Implementation Reference
- src/jira_server.py:261-286 (handler)The core handler function that retrieves a Jira issue by its key using the atlassian-python-api Jira client, extracts relevant fields, constructs a JiraIssue model, and returns the details as formatted JSON text content.async def _get_issue(self, arguments: dict) -> List[TextContent]: """Get details of a specific issue""" issue_key = arguments["issue_key"] issue = self.jira_client.issue(issue_key) fields = issue.get("fields", {}) issue_details = JiraIssue( key=issue["key"], summary=fields.get("summary", ""), description=fields.get("description", ""), status=fields.get("status", {}).get("name", ""), assignee=fields.get("assignee", {}).get("displayName", "") if fields.get("assignee") else None, reporter=fields.get("reporter", {}).get("displayName", ""), created=fields.get("created", ""), updated=fields.get("updated", ""), priority=fields.get("priority", {}).get("name", "") if fields.get("priority") else None, issue_type=fields.get("issuetype", {}).get("name", ""), project=fields.get("project", {}).get("key", "") ) return [TextContent( type="text", text=issue_details.model_dump_json(indent=2) )]
- src/jira_server.py:71-84 (registration)Registers the 'jira_get_issue' tool with the MCP server via list_tools(), including its name, description, and inputSchema defining the required 'issue_key' parameter.Tool( name="jira_get_issue", description="Get details of a specific Jira issue", inputSchema={ "type": "object", "properties": { "issue_key": { "type": "string", "description": "Issue key (e.g., PROJ-123)" } }, "required": ["issue_key"] } ),
- src/jira_server.py:27-40 (schema)Pydantic BaseModel defining the output schema/structure for Jira issue details used by the jira_get_issue handler.class JiraIssue(BaseModel): """Jira issue model""" key: str summary: str description: Optional[str] = None status: str assignee: Optional[str] = None reporter: str created: str updated: str priority: Optional[str] = None issue_type: str project: str
- src/jira_server.py:199-200 (handler)Dispatch logic in the generic call_tool handler that routes calls to 'jira_get_issue' to the specific _get_issue implementation.elif name == "jira_get_issue": return await self._get_issue(arguments)