gotify / server

A simple server for sending and receiving messages in real-time per WebSocket. (Includes a sleek web-ui)
https://gotify.net
Other
10.43k stars 593 forks source link

Websocket stream per application #648

Closed mschipperheyn closed 2 months ago

mschipperheyn commented 2 months ago

Is your feature request related to a problem? Please describe. I would like to subscribe to a websocket stream on a per application basis.

This would allow me to create multiple message streams in multi tenant scenarios

Describe the solution you'd like An endpoint /application/{id}/stream

Describe alternatives you've considered Creating a websocket on our own api but that seems too much of a pain Supplying this feature as a PR Filtering alerts on the client by appId

Additional context You want to avoid sharing alerts between tenants / applications

jmattheis commented 2 months ago

In gotify applications send messages and clients receive messages. Adding a stream endpoint for applications doesn't fit into this schema. There is this issue https://github.com/gotify/server/issues/186 which proposes to allow messages to send messages to specific clients.

Gotify supports multiple users, so you could use this functionality for multiple tenants.