Add rate limit handling to NextDNS API script#3
Open
Minifab wants to merge 1 commit intoHotCakeX:mainfrom
Open
Add rate limit handling to NextDNS API script#3Minifab wants to merge 1 commit intoHotCakeX:mainfrom
Minifab wants to merge 1 commit intoHotCakeX:mainfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add rate limit handling to NextDNS API script
First, I'd like to thank you, HotCakeX, for creating and maintaining this excellent repository. Your work on collecting and organizing Microsoft domains is incredibly valuable for me, and I'm grateful for your contribution to making whitelisting easier for everyone.
I've enhanced the "Add Domains to the NextDNS AllowList.ps1" script to handle NextDNS API rate limits with the following improvements:
Write-Progressfor visual progress trackingWhy this improvement matters
The current script fails when it encounters rate limit errors after adding multiple domains. With these enhancements, the script will continue trying with progressively increasing intervals (2, 4, 8, 16, 32 seconds...) until the API accepts the request.
These modifications allow the script to work reliably even with a large number of domains to add, intelligently adapting to NextDNS API limitations.
Technical details
This enhancement ensures that users can reliably add all Microsoft domains to their NextDNS allowlist without manual intervention, even when working with the API's rate limits.