Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rate limiting #3

Open
THEGOLDENPRO opened this issue Feb 27, 2024 · 1 comment
Open

Rate limiting #3

THEGOLDENPRO opened this issue Feb 27, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@THEGOLDENPRO
Copy link
Owner

THEGOLDENPRO commented Feb 27, 2024

The API wrapper will need to handle Jikan's rate limiting respectfully with waiting.

As of the creation of this issue the Jikan rate limits are:

Duration Requests
Daily Unlimited
Per Minute 60 Requests
Per Second 3 Requests

The concept

client = Anmoku()

# this will run fine
character = client.get(AnimeCharacter, id = "101")
character = client.get(AnimeCharacter, id = "2")
character = client.get(AnimeCharacter, id = "362")

# but when ran a fourth time under a second it should hit a rate limit.
character = client.get(AnimeCharacter, id = "67") # the program should wait right here until the time for the rate limit has passed.

character = client.get(AnimeCharacter, id = "0") # this will run after the rate limit wait
@THEGOLDENPRO THEGOLDENPRO added the enhancement New feature or request label Feb 27, 2024
@EmmmaTech EmmmaTech self-assigned this Jul 9, 2024
@THEGOLDENPRO
Copy link
Owner Author

added with #4 using slowstack

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants