msgs

Tiny ephemeral HTTP pubsub. POST a JSON payload, GET the last one, or subscribe to a Server-Sent Events stream.

POST/pubsub/<uuid>/<channel>store JSON (≤ 5000 B), broadcast to subscribers
GET/pubsub/<uuid>/<channel>return the last JSON payload
GET/pubsub/<uuid>/<channel> + Accept: text/event-streamSSE stream, starting with the last message

Each path is scoped to a tenant: <uuid> is the tenant's UUID in canonical lowercase form (8-4-4-4-12 hex). Uppercase or otherwise non-canonical UUIDs return 400. Different tenants are fully isolated, even when they use the same channel name.

Channel names match [a-zA-Z0-9._-]+. Bearer-token auth is configured per topic pattern, separately for writes and reads; pass the token as Authorization: Bearer <token>. A topic pattern not in the tenant's config — or an unknown tenant — returns 404.

T=00000000-0000-0000-0000-000000000000

curl -X POST https://msgs.skibidibug.com/pubsub/$T/hello \
  -H 'Authorization: Bearer <write-token>' \
  -H 'Content-Type: application/json' -d '{"hi":1}'

curl https://msgs.skibidibug.com/pubsub/$T/hello \
  -H 'Authorization: Bearer <read-token>'

curl -N -H 'Accept: text/event-stream' \
  -H 'Authorization: Bearer <read-token>' \
  https://msgs.skibidibug.com/pubsub/$T/hello

Channels will hold on to the last message for up to 24 hours but it may go away before then.

Tenant admin API

Each tenant exposes admin endpoints under /tenant/<uuid>/. They authenticate with Authorization: Bearer <uuid>:<secret> — accepted when sha256("<uuid>:<secret>") matches one of the tenant's non-expired tokens and that token has the admin scope.

GET/tenant/<uuid>/infotenant id/name/email and token metadata (no secrets)
GET/tenant/<uuid>/topicscurrent topic rules
PUT/tenant/<uuid>/topicsreplace the topic list (/topic is an alias)
curl -X PUT https://msgs.skibidibug.com/tenant/$T/topics \
  -H "Authorization: Bearer $T:<admin-secret>" \
  -H 'Content-Type: application/json' \
  -d '{"topics":[{"pattern":"news.*","write":"wtok","read":""}]}'