UNPKG

@withpica/mcp-server

Version:

MCP Server for withPICA — enables AI assistants to interact with your withPICA music catalog

17 lines • 713 B
// Copyright (c) 2025-2026 Withpica Ltd. All rights reserved. /** * @param code SCREAMING_SNAKE machine code — no spaces. * @param message Human-readable cause, safe to show the user. * @param extra Optional additional body fields (e.g. `sent: false`). Spread * FIRST so it can never overwrite `error` or `message` — the * two fields `extractErrorAttribution` reads. */ export function typedError(code, message, extra) { const body = { ...extra, error: code, message }; return { content: [{ type: "text", text: JSON.stringify(body, null, 2) }], structuredContent: body, isError: true, }; } //# sourceMappingURL=error-envelope.js.map