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

Make only one request to Twitch instead of for each server #90

Open
TrojanerHD opened this issue Sep 8, 2023 · 1 comment
Open

Make only one request to Twitch instead of for each server #90

TrojanerHD opened this issue Sep 8, 2023 · 1 comment
Labels
code-cleanup Enhancements code styling wise enhancement New feature or request follow-up Requires a PR to be merged

Comments

@TrojanerHD
Copy link
Owner

Follow-up PR for #67

We do not want to make a request to Twitch for each server as shown here:

new TwitchHelper(this.streamerFetch.bind(this)).update(
(): string[] => Settings.settings.streamers
);

Instead we want to bundle the requests into one and make only one request to Twitch in order to prevent rate limiting when the bot runs on too many servers

@TrojanerHD TrojanerHD added enhancement New feature or request code-cleanup Enhancements code styling wise follow-up Requires a PR to be merged labels Sep 8, 2023
@MelanX
Copy link

MelanX commented Sep 9, 2023

Keep in mind that a maximum count of 100 streams per request is allowed, see here:
https://dev.twitch.tv/docs/api/reference/#get-streams

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code-cleanup Enhancements code styling wise enhancement New feature or request follow-up Requires a PR to be merged
Projects
Status: Todo
Development

No branches or pull requests

2 participants