Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

OAuth port for Python 3

I am trying to create a Twitter and StatusNet client in python 3 but I have a problem, all the examples I find use the OAuth library. There is some example using just curl or a simple authentication but it is very basic.

Do you know if there is a port of OAuth (1 or 2) for Python 3 ?

Thank you


Update : maybe the lack of port is explained by the lack of good python 2 implementation ?

like image 245
Martin Trigaux Avatar asked Oct 08 '22 10:10

Martin Trigaux


1 Answers

There is the python oauthlib client which supports python2/3 and oauth1/2.

According to this page:

If your application is using OAuth, port your code from the old, unmaintained, OAuth1-only, Python 2-only oauth library (i.e. python-oauth) to the new, maintained, OAuth1 and OAuth2 compatible, Python 2 and Python 3 compatible oauthlib (i.e. python-oauthlib) package. Porting is not so hard, although some of the terminology updates in the OAuth spec since the original oauth was released make it a bit trickier.

like image 175
Silfheed Avatar answered Oct 12 '22 12:10

Silfheed