Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion packages/mcp-core/src/api-client/schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1347,7 +1347,8 @@ export const EventAttachmentSchema = z.object({
size: z.number(),
mimetype: z.string(),
dateCreated: z.string().datetime(),
sha1: z.string(),
// Objectstore-backed attachments do not store a usable SHA1 (checksum is
// unavailable), so we neither require nor surface it from this endpoint.
headers: z.record(z.string(), z.string()).optional(),
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ describe("get_event_attachment", () => {
**Size:** 1024 bytes
**MIME Type:** image/png
**Created:** 2025-04-08T21:15:04.000Z
**SHA1:** abc123def456

To download this attachment with the attachmentId provided:
Use the Sentry tool \`get_event_attachment\`
Expand Down Expand Up @@ -87,7 +86,6 @@ describe("get_event_attachment", () => {
**Size:** 1024 bytes
**MIME Type:** image/png
**Created:** 2025-04-08T21:15:04.000Z
**SHA1:** abc123def456

**Download URL:** https://sentry.io/api/0/projects/sentry-mcp-evals/cloudflare-mcp/events/7ca573c0f4814912aaa9bdc77d1a7d51/attachments/123/?download=1

Expand Down
6 changes: 2 additions & 4 deletions packages/mcp-core/src/tools/catalog/get-event-attachment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,7 @@ export default defineTool({
output += `**Type:** ${attachment.attachment.type}\n`;
output += `**Size:** ${attachment.attachment.size} bytes\n`;
output += `**MIME Type:** ${effectiveMimeType}\n`;
output += `**Created:** ${attachment.attachment.dateCreated}\n`;
output += `**SHA1:** ${attachment.attachment.sha1}\n\n`;
output += `**Created:** ${attachment.attachment.dateCreated}\n\n`;
output += `**Download URL:** ${attachment.downloadUrl}\n\n`;

if (isBinary) {
Expand Down Expand Up @@ -166,8 +165,7 @@ export default defineTool({
output += `**Type:** ${attachment.type}\n`;
output += `**Size:** ${attachment.size} bytes\n`;
output += `**MIME Type:** ${attachment.mimetype}\n`;
output += `**Created:** ${attachment.dateCreated}\n`;
output += `**SHA1:** ${attachment.sha1}\n\n`;
output += `**Created:** ${attachment.dateCreated}\n\n`;
output += "To download this attachment with the attachmentId provided:\n";
output += `${formatToolCallInstruction({
toolName: "get_event_attachment",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
"size": 1024,
"mimetype": "image/png",
"dateCreated": "2025-04-08T21:15:04.000Z",
"sha1": "abc123def456",
"headers": {
"Content-Type": "image/png"
}
Expand Down
1 change: 0 additions & 1 deletion packages/mcp-server-mocks/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1607,7 +1607,6 @@ export const restHandlers = buildHandlers([
size: 1024,
mimetype: "application/octet-stream",
dateCreated: "2025-04-08T21:15:04.000Z",
sha1: "abc123def456",
headers: { "Content-Type": "application/octet-stream" },
},
]),
Expand Down
Loading