Skip to content

Instantly share code, notes, and snippets.

@omargourari
Created January 16, 2019 18:20
Show Gist options
  • Save omargourari/6bb4f7763fc75dfe0603419b66a3ed8a to your computer and use it in GitHub Desktop.
Save omargourari/6bb4f7763fc75dfe0603419b66a3ed8a to your computer and use it in GitHub Desktop.
pocket.RateLimitException: User was authenticated, but access denied due to lack of permission or rate limiting. User rejected code.
from pocket import Pocket
redirect_uri = "https://google.com"
consumer_key = "73745-e43fd98db8a10bbbf14893bf"
request_token = Pocket.get_request_token(consumer_key, redirect_uri)
# URL to redirect user to, to authorize your app
auth_url = Pocket.get_auth_url(request_token, redirect_uri)
user_credentials = Pocket.get_credentials(consumer_key, request_token)
access_token = user_credentials['access_token']
p = Pocket(consumer_key)
@cruisen
Copy link

cruisen commented Sep 7, 2020

same problem, what do we do wrong?

@omargourari
Copy link
Author

Try to specify the number of articles you're retrieving

@nilshah98
Copy link

I followed the steps over here.
Used the request_token that I retrieved from the above call, and then followed step3 at here and hit this url https://getpocket.com/auth/authorize?request_token=YOUR_REQUEST_TOKEN&redirect_uri=YOUR_REDIRECT_URI

Then it asked me whether I want to authorize the app, I clicked yes. And then ran the above script again, just the last part, and voila, I have the access_token

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment