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

[Feature]: Respect Paddle rate limit #93

Open
Bre77 opened this issue Dec 21, 2024 · 1 comment
Open

[Feature]: Respect Paddle rate limit #93

Bre77 opened this issue Dec 21, 2024 · 1 comment

Comments

@Bre77
Copy link

Bre77 commented Dec 21, 2024

Tell us about your feature request

The Paddle SDK doesnt respect the Paddle API rate limit, and doesnt provide the developer the means to respect the Paddle API rate limit.

Given this is an async library, requests that would hit the rate limit should automatically wait an appropriate amount of time before returning, or at least retry after the Retry-After header time. This doesnt have to be default behavior, but should be an option.

Worst case, provide the header values back via the SDK so the application can handle these themself. The current error does not include the value of the Retry-After header, so its unclear how long to wait until retrying.

What problem are you looking to solve?

I dont want to have to think about the Paddle API rate limit when using the SDK, because this should be handled for me. Alternatively I want the SDK to provide me appropriate information so that I can manage the rate limit myself.

Additional context

  type: 'api_error',
  code: 'too_many_requests',
  detail: 'You have exceeded the allowed rate limit, please retry your request after the number of seconds in the Retry-After header.',
  documentationUrl: 'https://developer.paddle.com/errors/shared/too_many_requests',
  errors: null

How important is this suggestion to you?

Important

@vifer
Copy link
Collaborator

vifer commented Dec 24, 2024

Hi @Bre77 ,
Thank you for your detailed feedback! Handling API rate limits more effectively in the SDK is definitely something we want to support and we’ll explore it for future updates.

We appreciate your contribution, please feel free to share any further ideas!

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

No branches or pull requests

2 participants