Skip to content

Isidorsson/polyhook-web

Repository files navigation

polyhook-web

Live demo for the polyglot Polyhook webhook bin: same OpenAPI spec, two implementations, one frontend.

  • Backend (Go): polyhook-go — Go 1.23, chi, modernc.org/sqlite
  • Backend (Node): polyhook-node — Node 22, Fastify 5, node:sqlite
  • Frontend: this repo — SvelteKit 2 + Svelte 5 + Tailwind v4

The page lets you flip between the two backends, create a bin, fire a test webhook, and watch the request land in real time over SSE.

Develop

npm install
npm run dev

The app talks directly to the deployed Railway backends (CORS is open). No local backend needed — but you can point it at local instances by editing BACKENDS in src/lib/api.ts.

Deploy

Configured for Vercel (@sveltejs/adapter-vercel, frankfurt region). Connect the repo on vercel.com and accept the defaults — no build settings needed.

Architecture

              ┌──────────────────────────────┐
              │  polyhook-web  (Svelte)      │
              │  Vercel · fra1               │
              └──────────────┬───────────────┘
                             │  fetch + EventSource
              ┌──────────────┴───────────────┐
              │                              │
   ┌──────────▼─────────┐         ┌──────────▼─────────┐
   │  polyhook-go       │         │  polyhook-node     │
   │  Railway · EU-W    │         │  Railway · EU-W    │
   │  SQLite + WAL      │         │  SQLite + WAL      │
   └────────────────────┘         └────────────────────┘

Both backends sit behind their own Railway domain and serve a byte-identical OpenAPI surface. The only thing the frontend needs to know about each is the base URL.

About

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors