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

Function jsonRpcResponse

apps/host-cloudflare/src/mcp/agent-handler.ts:79–87  ·  view source on GitHub ↗
(
  status: number,
  code: number,
  message: string,
  challenge?: string,
)

Source from the content-addressed store, hash-verified

77};
78
79const jsonRpcResponse = (
80 status: number,
81 code: number,
82 message: string,
83 challenge?: string,
84): Response =>
85 challenge === undefined
86 ? jsonRpcErrorBody(status, code, message)
87 : jsonRpcErrorBody(status, code, message, { challenge });
88
89/**
90 * A dead session id answers by request method. POST/DELETE keep the 404 that

Callers 3

deadSessionResponseFunction · 0.70
renderAuthErrorFunction · 0.70

Calls 1

jsonRpcErrorBodyFunction · 0.85

Tested by

no test coverage detected