sentry_resolve_short_id
Retrieve issue details, project context, and status by entering a short ID like PROJ-123 to quickly access Sentry error information.
Instructions
Retrieve details about an issue using its short ID. Maps short IDs to issue details, project context and status.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| shortId | Yes | The short ID of the issue (e.g., 'PROJ-123') |
Implementation Reference
- src/index.ts:1139-1163 (handler)MCP server tool handler for sentry_resolve_short_id. Extracts shortId argument, calls apiClient.resolveShortId(), and returns formatted issue details as text content.
case "sentry_resolve_short_id": { if (!apiClient) { throw new Error("Sentry API client not initialized. Provide auth token."); } const { shortId } = args as any; const result = await apiClient.resolveShortId(shortId); return { content: [ { type: "text", text: `Issue resolved from short ID ${shortId}:\n` + `- Issue ID: ${result.groupId}\n` + `- Project: ${result.projectSlug}\n` + `- Organization: ${result.organizationSlug}\n` + `- Title: ${result.group.metadata.title}\n` + `- Status: ${result.group.status}\n` + `- Level: ${result.group.level}\n` + `- First seen: ${result.group.firstSeen}\n` + `- Last seen: ${result.group.lastSeen}`, }, ], }; } - src/index.ts:516-528 (registration)Tool registration in ListTools response, including name, description, and input schema definition.
name: "sentry_resolve_short_id", description: "Retrieve details about an issue using its short ID. Maps short IDs to issue details, project context and status.", inputSchema: { type: "object", properties: { shortId: { type: "string", description: "The short ID of the issue (e.g., 'PROJ-123')", }, }, required: ["shortId"], }, }, - src/sentry-api-client.ts:168-169 (helper)Core helper method in SentryAPIClient that resolves a short ID by making an authenticated GET request to Sentry's /organizations/{org}/shortids/{shortId}/ API endpoint.
return this.request(`/organizations/${this.org}/shortids/${shortId}/`); } - src/sentry-api-client.ts:20-36 (helper)Private request method used by all API calls, including resolveShortId, handling authentication, fetch, error checking, and JSON parsing.
private async request(endpoint: string, options: any = {}) { const url = `${this.baseUrl}${endpoint}`; const response = await fetch(url, { ...options, headers: { 'Authorization': `Bearer ${this.authToken}`, 'Content-Type': 'application/json', ...options.headers, }, }); if (!response.ok) { throw new Error(`Sentry API error: ${response.status} ${response.statusText}`); } return response.json(); }