Solid pod webhook listener server built with Koa and @soid/koa.
Fetches a webhook configuration specifying resources to subscribe to and handlers to dispatch when a notification is received.
Permissions need to be granted to the agent's webid.
- WebhookChannel2023 subscription to Solid pods
- Agent-hosted webid - grant permissions rather than logging in
- RDF-based webhook configuration
- Only accepts notifications from whitelisted pods
- DPoP authentication middleware
- Inbox event handlers
- Solid OIDC identity via @soid/koa solidIdentity
- Admin summary page /subscriptions
- Listens to additions to webhook configuration
- Node.js 18+
npm install
npm run buildCopy .env.example to .env and configure:
cp .env.example .envRequired:
BASE_URL- Base URL for this server (used for issuer, webid origin, and callback URL)WEBHOOK_CONFIG_URL- URL to load webhook RDF configuration fromWHITELISTED_ISSUERS- Comma-separated list of allowed OIDC issuersHANDLER_BASE_URL- Namespace prefix for handler types (must end with #)
See docs/webhooks.ttl.example for the RDF schema format. Store your webhook configuration on a Solid pod and load it at runtime.
npm startnpm test # Run all tests
npm run typecheck # Check TypeScriptsrc/index.ts- Koa server with identity endpoints and subscription managementsrc/middleware/solidAuth.ts- DPoP token verification using @solid/access-token-verifiersrc/services/webhookChannel.ts- WebhookChannel2023 subscription/unsubscriptionsrc/services/solidFetch.ts- Authenticated fetch using @soid/koasrc/handlers/inboxModified.ts- Inbox event processingsrc/config.ts- Environment variable loading and RDF webhook parsingsrc/types/index.ts- TypeScript interfaces
The server uses solidIdentity from @soid/koa to provide identity routes. Custom endpoints:
/.well-known/openid-configuration- OIDC configuration (no jwks_uri)/webid- Turtle WebID document with OIDC issuer