ESP32-Supabase
ESP32-Supabase copied to clipboard
realtime-postgresChanges does not work.
Hi, I cant seem to get the realtime updates working. Im using Ardiono with ESp32 with v3 SDK.
I matted to connect to Supabase and handle DB transactions - works fine. However, the Real Time Table updates / Record updates does not trigger any events.
The code is exactly as your example with a different Table. The Table also us visible via the Anna Login and has Real time enabled with no RLS. The Table has been tested with realtime over the Web ad it works - so the config seems fine.
In the Loop run, it only prints this:
[WSc] Disconnected!
Appreciate any help here. Thanks
The Code
Sample Code:
// Some header codes and handlers
void HandleChanges(String result) {
Serial.println(result);
JsonDocument doc;
deserializeJson(doc, result);
// Example of what you can do with the result
String tableName = doc["table"];
String event = doc["type"];
String changes = doc["record"];
Serial.print(tableName);
Serial.print(" : ");
Serial.println(event);
Serial.println(changes);
}
void setup() {
// some code ...
realtime.addChangesListener("mytable1", "UPDATE", "public", "id=eq.3");
realtime.addChangesListener("mytable2", "*", "public", "");
realtime.listen();
}
void loop() {
realtime.loop();
}
same issue with me
Same issue with me
got same issue with realtime database..
[WSc] Disconnected!
Same issue with realtime database
[WSc] Disconnected!
Same issue here. I keep seeing "[WSc] Disconnected!" in the serial monitor.
Hello Guys, I create a user at supabase authentication and uncomment this line
realtime.login_email("[email protected]", "secret");
its worked
Any updates on this? Did somebody manage to get it working without user login?