search_issues
Search JIRA issues using JQL queries to find specific tickets, track project status, or identify related problems within your workflow.
Instructions
Search JIRA issues using JQL
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| searchString | Yes | JQL search string |
Implementation Reference
- src/services/jira-api.ts:247-273 (handler)Core handler function that executes the JIRA issue search using JQL, fetches from REST API /rest/api/3/search, cleans issues using cleanIssue helper, and returns SearchIssuesResponse.async searchIssues(searchString: string): Promise<SearchIssuesResponse> { const params = new URLSearchParams({ jql: searchString, maxResults: "50", fields: [ "id", "key", "summary", "description", "status", "created", "updated", "parent", "subtasks", "customfield_10014", "issuelinks", ].join(","), expand: "names,renderedFields", }); const data = await this.fetchJson<any>(`/rest/api/3/search?${params}`); return { total: data.total, issues: data.issues.map((issue: any) => this.cleanIssue(issue)), }; }
- src/index.ts:273-286 (handler)MCP server request handler for CallToolRequestSchema specifically for 'search_issues' tool: validates args.searchString, delegates to jiraApi.searchIssues, and returns formatted MCP response content.case "search_issues": { if (!args.searchString || typeof args.searchString !== "string") { throw new McpError( ErrorCode.InvalidParams, "Search string is required", ); } const response = await this.jiraApi.searchIssues(args.searchString); return { content: [ { type: "text", text: JSON.stringify(response, null, 2) }, ], }; }
- src/index.ts:85-98 (registration)Registration of the 'search_issues' tool in the MCP server's ListToolsRequestSchema response, including name, description, and input schema.name: "search_issues", description: "Search JIRA issues using JQL", inputSchema: { type: "object", properties: { searchString: { type: "string", description: "JQL search string", }, }, required: ["searchString"], additionalProperties: false, }, },
- src/types/jira.ts:44-47 (schema)TypeScript interface defining the output schema for the searchIssues function.export interface SearchIssuesResponse { total: number; issues: CleanJiraIssue[]; }