Set API usage limit

Hello , So I have an app that tracks the IP Address the user wants. I use API ipstack in order to do that. This service has a limit for the free licence at about 10.000 uses a month.
So I want to set a limit for each user to about 2 uses for each and when the user exceeds the limit a notifier should appear informing him.
What blocks should I use to achieve that?
I would really appreciate your help & suggestions!
Thanks in advance!

Will your users be happy with just 2 uses per month? (They’ll be even more annoyed if you have ads in your app as you’re earning money from them but not giving them quantity.)

Instead why not pay for more substantial usage and charge your app users?

blocks (30)
PS: 2 uses a month! That’s crazy low!


I meant 2 uses per session.

Oh, I thought you meant 2 uses per month.

I mean 2 uses per session, sorry if I was misleading.

Oh, then do something like this:

1 Like

Thanks man for the help ,I appreciate it!

This can still be abused.

while True:
    open App
    use 2 times
    close App

I suggest you limit it by time (eg 1 use every 3 hours or something).


You’re joking, right? :open_mouth: :rofl:

1 Like

You might be right on this. What blocks should I use to do that?

Use this + when the button is clicked store the current online time (time zone doesnt matter) and date and compare with the current. If uses == 2 and timeNow-timeLast < {three hours}: showPopup()

BTW Convert the times to milliseconds, then the “{three hours}” bit would be 10800000 ms


Thanks mate!

1 Like

Hey again . How can I store the current online time?
Thanks in advance!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.