Skip to main content
Glama

sentry_list_issues

Retrieve and filter error issues from Sentry projects to monitor application health and identify problems using search queries like 'is:unresolved' or 'level:error'.

Instructions

List issues for a project

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
projectSlugYesProject slug/identifier
queryNoSearch query (e.g., 'is:unresolved', 'level:error')

Implementation Reference

  • Executes the sentry_list_issues tool: checks apiClient, extracts projectSlug and query, calls apiClient.listIssues, formats and returns list of issues.
    case "sentry_list_issues": { if (!apiClient) { throw new Error("Sentry API client not initialized. Provide auth token."); } const { projectSlug, query } = args as any; const issues = await apiClient.listIssues(projectSlug, query); return { content: [ { type: "text", text: `Found ${issues.length} issues in ${projectSlug}:\n${issues.slice(0, 10).map((i: any) => `- [${i.level}] ${i.title} (${i.count} events)` ).join('\n')}${issues.length > 10 ? '\n... and more' : ''}`, }, ], }; }
  • Core implementation of listing issues: constructs API endpoint with projectSlug and optional query, calls private request method to fetch from Sentry API.
    async listIssues(projectSlug: string, query?: string) { const params = query ? `?query=${encodeURIComponent(query)}` : ''; return this.request(`/projects/${this.org}/${projectSlug}/issues/${params}`); }
  • src/index.ts:397-413 (registration)
    Registers the sentry_list_issues tool in the ListTools response with name, description, and input schema.
    { name: "sentry_list_issues", description: "List issues for a project", inputSchema: { type: "object", properties: { projectSlug: { type: "string", description: "Project slug/identifier", }, query: { type: "string", description: "Search query (e.g., 'is:unresolved', 'level:error')", }, }, required: ["projectSlug"], },
  • Private request method used by listIssues to make authenticated HTTP requests to Sentry API.
    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(); }

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/diegofornalha/sentry-mcp-cursor'

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