sentry_add_breadcrumb
Add debugging breadcrumbs to track application flow and errors in Sentry for Cursor, providing context for troubleshooting issues.
Instructions
Add a breadcrumb for debugging context
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| message | Yes | Breadcrumb message | |
| category | No | Category of the breadcrumb | |
| level | No | Severity level | info |
| data | No | Additional data for the breadcrumb |
Implementation Reference
- src/index.ts:791-810 (handler)The handler function that implements the sentry_add_breadcrumb tool by calling Sentry.addBreadcrumb with the provided message, category, level (mapped), data, and current timestamp.case "sentry_add_breadcrumb": { const { message, category, level = "info", data } = args as any; Sentry.addBreadcrumb({ message, category, level: mapSeverityLevel(level), data, timestamp: Date.now() / 1000, }); return { content: [ { type: "text", text: `Breadcrumb added: ${message}`, }, ], }; }
- src/index.ts:168-192 (schema)The input schema for the sentry_add_breadcrumb tool, defining parameters: message (required), category, level (default 'info'), and data.inputSchema: { type: "object", properties: { message: { type: "string", description: "Breadcrumb message", }, category: { type: "string", description: "Category of the breadcrumb", }, level: { type: "string", enum: ["fatal", "error", "warning", "info", "debug"], description: "Severity level", default: "info", }, data: { type: "object", description: "Additional data for the breadcrumb", additionalProperties: true, }, }, required: ["message"], },
- src/index.ts:165-193 (registration)The tool registration in the ListTools response, including name, description, and inputSchema for sentry_add_breadcrumb.{ name: "sentry_add_breadcrumb", description: "Add a breadcrumb for debugging context", inputSchema: { type: "object", properties: { message: { type: "string", description: "Breadcrumb message", }, category: { type: "string", description: "Category of the breadcrumb", }, level: { type: "string", enum: ["fatal", "error", "warning", "info", "debug"], description: "Severity level", default: "info", }, data: { type: "object", description: "Additional data for the breadcrumb", additionalProperties: true, }, }, required: ["message"], }, },