
I'm trying to subscribe to changes in a collection but im getting ReferenceError: window is not defined
.
Here's the code i'm using
const { Client } = require("appwrite");
const client = new Client()
.setEndpoint("https://aor.rxserver.net/v1")
.setProject("gate-api");
client.subscribe("collections.gates.documents", (payload) => {
console.log(payload);
});

Currently Realtime/websocket connection are only supported in browser environments 👍

aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa shet

whats your use case? 🙂

I'm making a "Stargate Network" in a game called Resonite, I want to listen to changes for specific columns for when stargates are connecting to eachother so it plays the right animation in-game

It uses websockets to connect to the game itself

guess i'll just have to constantly check the state
Recommended threads
- Existing ID bug?!
Idk why this happens can someone explain!! why Im getting this error even if I "manually clear the collection" ?
- I have an error oauth with Microsoft
invalid_request: The provided value for the input parameter 'redirect_uri' is not valid. The expected value is a URI which matches a redirect URI registered for...
- SMTP Error: Could not connect to SMTP
My appwrite self-hosted instance on DigitalOcean cannot sennd emails. The following results were performed Log: ``` docker compose logs -f appwrite-worker-mail...
