MCPcopy Create free account
hub / github.com/EvoMap/evolver / respond

Function respond

test/proxyEnvelope.test.js:127–130  ·  view source on GitHub ↗
(status, obj)

Source from the content-addressed store, hash-verified

125 hub = http.createServer(async (req, res) => {
126 const body = await readBody(req);
127 const respond = (status, obj) => {
128 res.writeHead(status, { 'Content-Type': 'application/json' });
129 res.end(JSON.stringify(obj));
130 };
131 if (req.url === '/a2a/hello') {
132 const err = hubValidate(body, ['hello']);
133 if (err) return respond(400, { error: err });

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected