Gdata allows authentication using user information, for example. username / password ... here is the snipet of the code from the python gdata api / gdata-2.0.18 / samples / docs / docs_example.py file that comes with the api
DocsSample class (object): "The DocsSample object shows the feed of the list of documents." "
def init (self, email, password): "" Constructor for the DocsSample object.
Takes an email and password corresponding to a gmail account to demonstrate the functionality of the Document List feed. Args: email: [string] The e-mail address of the account to use for the sample. password: [string] The password corresponding to the account specified by the email parameter. Returns: A DocsSample object used to run the sample demonstrating the functionality of the Document List feed. """ source = 'Document List Python Sample' self.gd_client = gdata.docs.service.DocsService() self.gd_client.ClientLogin(email, password, source=source) # Setup a spreadsheets service for downloading spreadsheets self.gs_client = gdata.spreadsheet.service.SpreadsheetsService() self.gs_client.ClientLogin(email, password, source=source)
if you call it like {python./docs_example.py --user username --pw password}, โโhe will skip asking you about it, but he will ask you about it if you don't. However, this depreciates, but still works in most off-network situations that work directly with Google, as it often takes oauth2 time. This suggests that it has security flaws, in particular, the scope and poor password protection, so it is out of date ... but this should answer your question a little better ...
source share