I want to fetch a collection every 2 minutes. How can i do it?
Which backend?
Core of it is to use setInterval or setTimeout in javascript, which has the job of executing a workflow that runs fetch collection. Set your interval period to 120000 for a 2-minute refetch.
Note that this is likely to be costly on your backend. I’ve seen people overload their backends or rack up bigger bills by implementing this kind of check. You can cut those costs by introducing a realtime push notification system with websockets or what have you.
I think WeWeb doesn’t like this kind of polling either. I’d just probably do Websockets, if it’s Xano, or Supabase with realtime.