MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / jsonRpcError

Function jsonRpcError

packages/hosts/mcp/src/in-memory-session-store.ts:199–200  ·  view source on GitHub ↗
(status: number, code: number, message: string)

Source from the content-addressed store, hash-verified

197// re-wraps the store `Response` with CORS before it leaves the origin, so the
198// canonical renderer is called with `cors: false` (content-type only).
199const jsonRpcError = (status: number, code: number, message: string): Response =>
200 jsonRpcErrorBody(status, code, message, { cors: false });
201
202const json = (value: unknown, status = 200): Response =>
203 new Response(JSON.stringify(value), { status, headers: { "content-type": "application/json" } });

Callers 2

runHandleRequestFunction · 0.70
openSessionFunction · 0.70

Calls 1

jsonRpcErrorBodyFunction · 0.90

Tested by

no test coverage detected