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

Function corsPreflightResponse

apps/cloud/src/mcp/agent-handler.ts:27–37  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

25import { parseTraceparent } from "./traceparent";
26
27const corsPreflightResponse = (): Response =>
28 new Response(null, {
29 status: 204,
30 headers: {
31 "access-control-allow-origin": "*",
32 "access-control-allow-methods": "GET, POST, DELETE, OPTIONS",
33 "access-control-allow-headers":
34 "content-type, authorization, mcp-session-id, accept, mcp-protocol-version",
35 "access-control-expose-headers": "mcp-session-id, WWW-Authenticate",
36 },
37 });
38
39const jsonRpcResponse = (
40 status: number,

Callers 1

makeCloudMcpAgentHandlerFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected