Is there any way to serve HTTP requests and websockets from the same path in Phoenix? I need to provide both JSON HTTP responses and handle websocket connections at the root path of an app.
I have tried using both the socket() construct and creating a custom handler, specified here. Neither work as there seems to be no way to intercept a request before it’s sent to an HTTP or websocket handler. Any ideas?
I am building a Nostr relay, which requires this functionality.