Edge Proxy Relay — API Test
\nTest all proxy endpoints from the browser
\n\n \ndiff --git a/api/relay.ts b/api/relay.ts index dd6eee6..979d4a0 100644 --- a/api/relay.ts +++ b/api/relay.ts @@ -29,10 +29,7 @@ import { createRateLimiter } from "../src/middleware/rate-limiter"; import { logRelayEvent } from "../src/middleware/logger"; import { handleChatCompletion, listModels } from "../src/lib/ai-proxy"; import { handleAnthropicMessages } from "../src/lib/anthropic-proxy"; - -// Read test-api.html at module scope so Bun's bundler inlines the content -// at build time (Vercel serverless has no filesystem at runtime). -const testApiHtmlRaw = await Bun.file("public/test-api.html").text(); +import testApiHtmlRaw from "./test-api-content"; // ─── Configuration ────────────────────────────────────────────────────────────── diff --git a/api/test-api-content.ts b/api/test-api-content.ts new file mode 100644 index 0000000..f8acb33 --- /dev/null +++ b/api/test-api-content.ts @@ -0,0 +1 @@ +export default "\n\n
\n \n \nTest all proxy endpoints from the browser
\n\n \n