Notifications from your backend

Fill in the form and this site's backend publishes it with one HTTP request. Every window with this room open receives it.

Write a notification

Connecting
Kind
Open a second window

Equivalent curl command

The same request from a terminal, with a token for your own app

How it works

The browser listens on a public channel. Public channels need no join token: anyone who knows the name can subscribe, so use hard-to-guess names such as a per-user token for anything personal.

Publishing is an HTTP POST to /{channel}/{event} with a token made for that one request and signed by one of the app's API keys. The response says how many connected clients received it. Because only your backend holds the key, only your backend can publish.

Read the HTTP API reference

notifications.ts
const channel = pikoman.listen(`notify-${userToken}`);

channel.on("notification", ({ kind, title, message }) => {
  showToast(kind, title, message);
});

We are rebuilding the dashboard

Self-service sign-up is closed while we do. Until the new dashboard is ready we set up apps by hand: write to us with a line about what you are building, and we will set up your app and get back to you.

Write to hello@pikoman.se