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

Update credential doc for clarity and error handling #16

Closed
binaryaaron opened this issue Feb 6, 2018 · 3 comments
Closed

Update credential doc for clarity and error handling #16

binaryaaron opened this issue Feb 6, 2018 · 3 comments

Comments

@binaryaaron
Copy link
Contributor

In working with @jimmoffitt, we noticed that credential handling setup is not 100% clear.

The flexibility introduced by #14 is perhaps not explicit about the defaults values of both the key file (.twitter_keys.yaml )and the keys in the file ( search_tweets_api ).

Also, there is no graceful error when a KeyError occurs when parsing the credential file.

@tonybaloney
Copy link

+1, I'm trying to use this package at the moment, have lots of questions.
I can see how to setup an app, how to generate a consumer key and secret. But where do I get the bearer token from? Surely the client gets the bearer token for me or that is available in the client? Why would I store a bearer token in the session file, since they normally expire after a short period.

@binaryaaron
Copy link
Contributor Author

@tonybaloney - We are using app-only authentication and the bearer tokens are not delivered with an expiration time. They can be invalidated.

Please see here for an overview of the auth method. I am open to putting in a small function to grab a bearer token given your application's keys.

I am about to update the credentialing docs. If there is anything not clear on there, feel free to let me know.

@tonybaloney
Copy link

I'll raise a PR to allow the user to put the consumer key and secret into the yaml file, having to manually generate bearer tokens is going to frustrate to anyone who doesn't know Oauth2 intimately. It's not obvious from the twitter docs which endpoint to call to get the bearer token as well.

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