Google Document list


/ Published in: Python
Save to your folder(s)

Here's a short program to print a list of all of the documents in your Google Documents account


Copy this code and paste it in your HTML
  1. import gdata.docs.service
  2.  
  3. # Create a client class which will make HTTP requests with Google Docs server.
  4. client = gdata.docs.service.DocsService()
  5. # Authenticate using your Google Docs email address and password.
  6. client.ClientLogin('[email protected]', 'password')
  7.  
  8. # Query the server for an Atom feed containing a list of your documents.
  9. documents_feed = client.GetDocumentListFeed()
  10. # Loop through the feed and extract each document entry.
  11. for document_entry in documents_feed.entry:
  12. # Display the title of the document on the command line.
  13. print document_entry.title.text

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.