python - How to generate RequestToken URL for Google API -
I am writing Python 2.7 desktop applications which need to use Google Spreadsheets by using OAuth 2.0. I'va got a library for Google Spreadsheets for Python, which uses Python OAuth2.0 library. The flow for described desktop applications tells me that the first time I have to generate the RequestToken URL is that the user can use the application to get the authorization code. I have already created Client ID and Client Secret Developer Console. But I can not figure out what class / method I can use to generate RequestToken URL in Python. Should I somehow build myself or is there an API to do this?
I have understood this from the document
#! / Usr / bin / env oauth2client = OAuth2WebServerFlow (client_id = 'your_client_id' python import oauth2client.client import OAuth2WebServerFlow flow, client_secret = 'your_client_secret', scope = 'https: //spreadsheets.google.com/feeds', redirect_uri =' You need your own client_id and although here was client_secret
P>
Comments
Post a Comment