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

Implement Rate limit checking #43

Closed
schochastics opened this issue Nov 8, 2022 · 5 comments
Closed

Implement Rate limit checking #43

schochastics opened this issue Nov 8, 2022 · 5 comments
Assignees
Labels
enhancement New feature or request

Comments

@schochastics
Copy link
Member

To implement pagination (#41), we need to keep track of rate limits

@chainsawriot
Copy link
Collaborator

We can expose the headers (or at least some headers field) within make_get_request. The least destructive way is to make it attr

headers <- httr::headers(request_results)
output <- httr::content(request_results)
attr(output, "headers") <- headers
return(output)

@schochastics
Copy link
Member Author

I was thinking that too.I will built that into the refactoring in #31. We then have a preliminary wiki page which can explain how to paginate accessing the attribute and we built a robust solution later. I think this needs a bit more time to come up with a good solution

@schochastics
Copy link
Member Author

rate limits are now returned in the attribute "headers" of the output

@schochastics schochastics added planned later feature that might be added later enhancement New feature or request and removed planned later feature that might be added later labels Nov 9, 2022
@schochastics schochastics self-assigned this Nov 14, 2022
@schochastics
Copy link
Member Author

still need a function to explicitly check the rate limit

@schochastics
Copy link
Member Author

No endpoint exists to check the ratelimit. ratelimit is only returned in the header of a get request.

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