-
Notifications
You must be signed in to change notification settings - Fork 13
Description
Feature request
Is your feature request related to a problem? Please describe.
I'm developing an App where it is important to have real-time knowledge of which users are in which parts of the app. I was planning of doing this using the realtime presence capabilities from supabase.
Describe the solution you'd like
I'm looking for an API that allows to use the presence capabilities from supabase.
Describe alternatives you've considered
I've considered no alternatives.
Additional context
I've been trying to follow this guide, https://supabase.com/docs/guides/realtime/presence to create a Swift realtime presence feature on my app.
var channel = realTimeClient.channel(.schema("public"), params: ["presence":"user1"])
channel.onMessage { message in
print("message: \(message.payload)")
return message
}
channel.push(.join, payload: ["presence":"user2"])
channel.subscribe()
For example, with something like this, I receive the following error:
Realtime/Channel.swift:466: Fatal error: Tried to push join to schema("public") before joining. Use channel.join() before pushing events`` However, the channel has no public
.join` method.
One of the issues is that the endpoint being used for realtime is v1
. Are there any plans to update it to v2
?
Maybe I'm interpreting this in a wrong manner and it is already possible to have a presence feature implemented with the current version of supabase-swift
.
Thank you :)