Why appgyver ddos my rest api

It must send 1 request to get a collection, but as you see it send it every 5 sec

Change the default logic where your Data variable is intialized, it creates a 5 second loop delay for GET requests. Remove that loop logic.

1 Like

maybe if you use data variable, there is a loop (there is a loop by default in the data variable tab)
delete it.

John and Dimos are correct. It’s good to have a rapidly updating app for something like a social platform with notifications and new posts coming in constantly. But if you’re working on a steep budget or have a limited number of API calls a month, it’s good practice to limit them with in-app logic.

We haven’t quite gotten that far in our own social platform, but I believe you could even set up more complex logic such as making an GET API call every two minutes for the first 10 minutes a page is open, and then limiting it to one call per every 10 minutes after that – with the assumption that the user is AFK (away from keyboard). After an hour, you might then limit calls to every 30 indefinitely.

If you wanted one call per page load, period, you could set the delay to an absurdly high number of seconds, i.e. “9999999999”, etc.

All depends on the nature of your app.

you have to take a look in the variable tab and then data variables

1 Like

or you could just delete the delay

1 Like

Oof, brain fart! You’re right.

1 Like