MCPcopy
hub / github.com/anomalyco/opencode / dynamicResponse

Function dynamicResponse

packages/llm/test/lib/http.ts:60–60  ·  view source on GitHub ↗
(handler: Handler)

Source from the content-addressed store, hash-verified

58 * Layer that builds a response per request. Useful for echo servers.
59 */
60export const dynamicResponse = (handler: Handler) => runtimeLayer(handlerLayer(handler))
61
62/**
63 * Layer that emits the supplied SSE chunks and then aborts mid-stream. Used to

Callers 12

prepare.test.tsFile · 0.90
adapter.test.tsFile · 0.90
executor.test.tsFile · 0.90
cloudflare.test.tsFile · 0.90
truncatedStreamFunction · 0.85
scriptedResponsesFunction · 0.85

Calls 2

runtimeLayerFunction · 0.85
handlerLayerFunction · 0.85

Tested by

no test coverage detected