MCPcopy Create free account
hub / github.com/cloudflare/computer / fetch

Function fetch

examples/think/src/index.ts:26–39  ·  view source on GitHub ↗
(request: Request, env: Env)

Source from the content-addressed store, hash-verified

24
25export default {
26 async fetch(request: Request, env: Env): Promise<Response> {
27 return (
28 (await routeAgentRequest(request, env)) ??
29 new Response(
30 [
31 "minimal think chat example",
32 "",
33 " Connect a terminal client with `npm run chat`, or point any",
34 " Think/agents chat client at /agents/assistant/<name>.",
35 ].join("\n"),
36 { headers: { "content-type": "text/plain" } },
37 )
38 );
39 },
40} satisfies ExportedHandler<Env>;

Callers 2

bootContainerFunction · 0.50
bootContainerFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected