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

Function jsonRpcResponse

apps/cloud/src/mcp/agent-handler.ts:83–91  ·  view source on GitHub ↗
(
  status: number,
  code: number,
  message: string,
  challenge?: string,
)

Source from the content-addressed store, hash-verified

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

Callers 3

deadSessionResponseFunction · 0.70
renderAuthErrorFunction · 0.70
handleFunction · 0.70

Calls 1

jsonRpcErrorBodyFunction · 0.85

Tested by

no test coverage detected