FeatureFuel
2

Pass existing WebSockets into realtime APIs

Source: supabase/supabase#1420 · opened by @kristianfreeman
[I've been experimenting with Supabase running on Cloudflare Workers]( - basic API requests are working, but I'm stuck on working with realtime data! We recently [announced WebSocket support]( in Workers. You can work with WSs in Workers by creating a WebSocketPair, which is an object containing a _server_ and _client_ WebSocket. The client WebSocket is sent down to the client, and the server WebSocket remains available in an open connection for the Workers function to work with: This server WebSocket instance is a great candidate for being used by Supabase to provide realtime data _through_ the Workers function to the client. Our [WebSocket API]( is fairly similar to the w3c spec, but differs in some respects, specifically around event handling (we use addEventListener instead of onopen, onclose, etc.) and a few fields we don't implement. It would be great to use these WebSockets with Supabase! Given that we already create WebSockets in Workers via our own…

No pledges yet. Be the first to back this.

Make a pledge

Pledge your monetary support if this feature is added.

$

Comments

No comments yet.

Replying to

Add a comment

What do you think about this feature request?


Similar requests