@zibby/skills 0.1.49 → 0.1.50
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/mcp-sentry.mjs +59 -2
- package/dist/index.js +68 -66
- package/dist/package.json +1 -1
- package/dist/sentry.d.ts +39 -0
- package/dist/sentry.js +4 -2
- package/package.json +1 -1
package/bin/mcp-sentry.mjs
CHANGED
|
@@ -31,7 +31,7 @@ import { z } from 'zod';
|
|
|
31
31
|
// Sentry endpoint = one edit in src/sentry.js, not three. Deterministic
|
|
32
32
|
// workflow nodes import the same functions for cost-optimized fetches
|
|
33
33
|
// that skip the LLM entirely.
|
|
34
|
-
import { sentryListProjects, sentryListIssues, sentryGetIssue } from '../dist/sentry.js';
|
|
34
|
+
import { sentryListProjects, sentryListIssues, sentryGetIssue, sentryUpdateIssue, sentryAddComment } from '../dist/sentry.js';
|
|
35
35
|
|
|
36
36
|
const server = new McpServer(
|
|
37
37
|
{ name: 'zibby-sentry', version: '1.0.0' },
|
|
@@ -121,10 +121,67 @@ server.registerTool(
|
|
|
121
121
|
},
|
|
122
122
|
);
|
|
123
123
|
|
|
124
|
+
// ── sentry_update_issue ─────────────────────────────────────────────
|
|
125
|
+
server.registerTool(
|
|
126
|
+
'sentry_update_issue',
|
|
127
|
+
{
|
|
128
|
+
title: 'Update Sentry Issue',
|
|
129
|
+
description: "Update a Sentry issue's status (resolved | resolvedInNextRelease | unresolved | ignored | muted), assignment, or bookmark. Requires the connected Sentry integration to have the event:write scope.",
|
|
130
|
+
inputSchema: z.object({
|
|
131
|
+
issueId: z.string().describe('Sentry issue ID'),
|
|
132
|
+
status: z.string().optional().describe('resolved | resolvedInNextRelease | unresolved | ignored | muted'),
|
|
133
|
+
statusDetails: z.object({}).passthrough().optional().describe('Optional status details, e.g. { "inRelease": "latest" }'),
|
|
134
|
+
assignedTo: z.string().optional().describe('Assignee actor id, e.g. "user:123" or "team:456"'),
|
|
135
|
+
isBookmarked: z.boolean().optional().describe('Bookmark/unbookmark the issue'),
|
|
136
|
+
hasSeen: z.boolean().optional().describe('Mark the issue seen/unseen'),
|
|
137
|
+
}),
|
|
138
|
+
},
|
|
139
|
+
async (args = {}) => {
|
|
140
|
+
try {
|
|
141
|
+
const data = await sentryUpdateIssue(args.issueId, {
|
|
142
|
+
status: args.status,
|
|
143
|
+
statusDetails: args.statusDetails,
|
|
144
|
+
assignedTo: args.assignedTo,
|
|
145
|
+
isBookmarked: args.isBookmarked,
|
|
146
|
+
hasSeen: args.hasSeen,
|
|
147
|
+
});
|
|
148
|
+
const text = JSON.stringify({
|
|
149
|
+
ok: true, id: data.id ?? args.issueId, status: data.status,
|
|
150
|
+
assignedTo: data.assignedTo, isBookmarked: data.isBookmarked,
|
|
151
|
+
});
|
|
152
|
+
return { content: [{ type: 'text', text }] };
|
|
153
|
+
} catch (err) {
|
|
154
|
+
return { content: [{ type: 'text', text: `Error: ${err.message}` }], isError: true };
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
);
|
|
158
|
+
|
|
159
|
+
// ── sentry_add_comment ──────────────────────────────────────────────
|
|
160
|
+
server.registerTool(
|
|
161
|
+
'sentry_add_comment',
|
|
162
|
+
{
|
|
163
|
+
title: 'Comment on a Sentry Issue',
|
|
164
|
+
description: 'Post a comment/note on a Sentry issue. Requires the connected Sentry integration to have the event:write scope.',
|
|
165
|
+
inputSchema: z.object({
|
|
166
|
+
issueId: z.string().describe('Sentry issue ID'),
|
|
167
|
+
text: z.string().describe('Comment body (markdown)'),
|
|
168
|
+
}),
|
|
169
|
+
},
|
|
170
|
+
async (args = {}) => {
|
|
171
|
+
try {
|
|
172
|
+
const data = await sentryAddComment(args.issueId, args.text);
|
|
173
|
+
const text = JSON.stringify({ ok: true, id: data.id, issueId: args.issueId });
|
|
174
|
+
return { content: [{ type: 'text', text }] };
|
|
175
|
+
} catch (err) {
|
|
176
|
+
return { content: [{ type: 'text', text: `Error: ${err.message}` }], isError: true };
|
|
177
|
+
}
|
|
178
|
+
},
|
|
179
|
+
);
|
|
180
|
+
|
|
124
181
|
const transport = new StdioServerTransport();
|
|
125
182
|
await server.connect(transport);
|
|
126
183
|
|
|
127
184
|
// Tiny diagnostic line on stderr so operators can confirm the MCP
|
|
128
185
|
// server actually started. stdout is reserved for MCP JSON-RPC; only
|
|
129
186
|
// stderr is safe for human-readable logs.
|
|
130
|
-
console.error('[mcp-sentry] connected (
|
|
187
|
+
console.error('[mcp-sentry] connected (5 tools: sentry_list_projects, sentry_list_issues, sentry_get_issue, sentry_update_issue, sentry_add_comment)');
|