hello everyone, I opened the realtime documentation, but I didn't understand how to work with it. It seems to show how to create an object, but how to use it and get, say, there is no value from the database
It seems to show how to create an object
what do you mean?
suspend fun getRealtime(onUpdate: (Notification) -> Unit) {
val realtime = Realtime(client)
val subscription = realtime.subscribe("databases.$databaseId.collections.Notification.documents") { event ->
val payload = event.payload
Log.d("REALTIME_DATA", "new message: ${payload}")
}
}
this
yes, so that subscribes and when an event comes in, it gets logged
Docs say:
Instead of requesting new data via HTTP, the subscription will receive new data every time it changes
how can this be used?
create a document that the user has access to and the event will come through.
and how do I output the document I need if there are no changes, but they will be?
Recommended threads
- Appwrite DNS nameservers return SERVFAIL...
My custom domain demomanasa.online (and all its subdomains) stopped resolving with ERR_NAME_NOT_RESOLVED for all visitors. I have traced the failure to Appwrite...
- Not allowed permission to upsert a prese...
```js const presenceID = ID.unique(); setPID(presenceID); const presence = await presences.upsert({ presenceId: presenceID, status: "online"...
- Realtime Error Invalid query: Syntax err...
I was test driving Self-Hosted Appwrite for my use with Swift IOS apps as a backend while back and after successful trials, I started to move to incorporate int...