Skip to main content
Glama

sentry_list_projects

Retrieve all projects within your Sentry organization to monitor error tracking, performance metrics, and application health status.

Instructions

List all projects in the organization

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Main execution handler for the sentry_list_projects tool. Validates API client availability, fetches projects via apiClient.listProjects(), and returns a formatted list of projects.
    case "sentry_list_projects": { if (!apiClient) { throw new Error("Sentry API client not initialized. Provide auth token."); } const projects = await apiClient.listProjects(); return { content: [ { type: "text", text: `Found ${projects.length} projects:\n${projects.map((p: any) => `- ${p.slug}: ${p.name}`).join('\n')}`, }, ], }; }
  • src/index.ts:390-396 (registration)
    Tool registration in the ListToolsRequestSchema handler, defining name, description, and input schema (empty object).
    name: "sentry_list_projects", description: "List all projects in the organization", inputSchema: { type: "object", properties: {}, }, },
  • Helper method in SentryAPIClient that performs the actual API request to retrieve the list of projects for the organization.
    async listProjects() { return this.request(`/organizations/${this.org}/projects/`); }
  • Private request method used by listProjects to make authenticated HTTP requests to the 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