Trying to use a realtime for database channel
TypeScript
useEffect(() => {
const unsubscribe = client.subscribe(
`databases.${MAIN_DATABASE_ID}.collections.${REPORTS_COLLECTION_ID}.documents.${reportInfo.id}.update`,
(response) => {
setReportInfo({
...reportInfo,
active: (response.payload as any).vote_active,
});
},
);
console.log('unsubscribe:', unsubscribe)
return () => {
unsubscribe();
};
}, [reportInfo]);````
but for some reason, it returns 400 bad request
TL;DR
Title: Realtime 400 bad request
Developers are using a realtime database channel but encountering a 400 bad request. The issue may stem from how the client is subscribing to the database channel. Make sure the subscription details are accurate.Recommended threads
- HTTP Error 500 ''
Hello to everyone, I'm a Flutter developer and actually I'm developing an app using Appwrite.. during my tests and also massive ones I've noticed something we...
- CSV imports were not working but found a...
With 1.9.5 Self-Hosted on a remote Debian 13 VPS I was trying to upload some data using the Import from CSV function. After following the Docs I created a csv f...
- Inviting members while SMTP is disabled ...
Issue: https://github.com/appwrite/console/issues/3125 PR: https://github.com/appwrite/console/pull/3126