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

Long-Lived User Tokens #300

Open
bbelderbos opened this issue Jul 20, 2016 · 5 comments
Open

Long-Lived User Tokens #300

bbelderbos opened this issue Jul 20, 2016 · 5 comments

Comments

@bbelderbos
Copy link

Hello,

There is a way to extend a token, but I don't see this in the API:

"Generating Long-Lived User Tokens from Server-Side Long-Lived Tokens"

( https://developers.facebook.com/docs/facebook-login/access-tokens/expiration-and-extension )

Will this be added at some point?

I need this for a command line script I am developing.

Thanks,
Bob

@bosihu
Copy link

bosihu commented Jul 22, 2016

Me too!

@martey
Copy link
Member

martey commented Jul 23, 2016

Will this be added at some point?

Like many open source projects, new features are generally added when someone contributes code implementing them.

@kz26
Copy link
Contributor

kz26 commented Jul 28, 2016

This is already implemented, actually: https://github.com/mobolic/facebook-sdk/blob/master/facebook/__init__.py#L317

@martey
Copy link
Member

martey commented Jul 28, 2016

I believe @bbelderbos meant https://developers.facebook.com/docs/facebook-login/access-tokens/expiration-and-extension#long-via-code, which is not implemented by extend_access_token.

@patil16nit
Copy link

It requires user interaction for generating user token with valid code return from Graph API which is then used to get long app access token (long lived token) used for getting the data from Graph API.
Simply, Add some test users to FB app. Design simple UI to call the graph api for long token generation verify it using access token debug, which is portable token. Finally, use it in different scripts.

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

Successfully merging a pull request may close this issue.

5 participants