My usage is a little different as I am sourcing the file from an HTTP POST.
# set up: # client = instantiated/authenticated gdata.contacts.client.ContactsClient # photo = photo file object # photo_link = gcontact.GetLink(gdata.contacts.PHOTO_LINK_REL) # get size of image photo.file.seek(0, os.SEEK_END) file_length = photo.file.tell() photo.file.seek(0,0) client.ChangePhoto(photo.file, photo_link.href, content_type=photo.type, content_length=file_length, etag='*') Keep in mind, this overrides etag versioning, so you may want to change that depending on what you're trying to accomplish. Let me know if this helps you any, Hari. Vinay, Dito. -- You received this message because you are subscribed to the Google Groups "Google Contacts, Shared Contacts and User Profiles APIs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://code.google.com/apis/contacts/community/forum.html
