Stay organized with collections
Save and categorize content based on your preferences.
Updating a photo for a shared contact is slightly different than updating a
shared contact's information. For information about working with a shared
contact's information, see
Update or delete a shared contact.
When using photo links, you must specify the authorization token in the HTTP
header. For more information, see
Learn about authentication and authorization.
Update a photo for a shared contact
Every shared contact has a photo link element. The photo link element appears
whether the contact has an associated photo or not. If the contact does have a
photo, then the element contains a gd:etag attribute that specifies an ETag
HTTP header for the photo. An ETag lets you refer to a specific version of a
particular entry. In this case, it lets you refer to a specific verion of a
photo. If the contact has no photo, then there's no gd:etag attribute, and
the href attribute provides the URL to use to add a
photo to the contact.
To delete a photo, you must use the HTTP DELETE method.
When updating or deleting a photo, send the photo's ETag in the If-Match
header of the HTTP request. If you don't have the latest version of the photo
use If-Match: * to override the versioning system and delete the photo.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[],[],null,["# Update or delete a photo for a shared contact\n\nUpdating a photo for a shared contact is slightly different than updating a\nshared contact's information. For information about working with a shared\ncontact's information, see\n[Update or delete a shared contact](/workspace/admin/domain-shared-contacts/update-delete-shared-contacts).\nWhen using photo links, you must specify the authorization token in the HTTP\nheader. For more information, see\n[Learn about authentication and authorization](https://developers.google.com/workspace/guides/auth-overview).\n\nUpdate a photo for a shared contact\n-----------------------------------\n\nEvery shared contact has a photo link element. The photo link element appears\nwhether the contact has an associated photo or not. If the contact does have a\nphoto, then the element contains a `gd:etag` attribute that specifies an `ETag`\nHTTP header for the photo. An `ETag` lets you refer to a specific version of a\nparticular entry. In this case, it lets you refer to a specific verion of a\nphoto. If the contact has no photo, then there's no `gd:etag` attribute, and\nthe `href` attribute provides the URL to use to add a\nphoto to the contact.\n\n- To add or update a photo, send a new photo:\n\n ```xml\n PUT https://www.google.com/m8/feeds/photos/media/liz%40DOMAIN/PHOTO_LINK\n ```\n\n Replace the following:\n - \u003cvar translate=\"no\"\u003eDOMAIN\u003c/var\u003e: The URL for your domain---for example, example.com.\n - \u003cvar translate=\"no\"\u003ePHOTO_LINK\u003c/var\u003e: A unique numerical value that represents the photo link for the shared contact---for example, c9012de.\n\n The following is an example of a photo link element: \n\n ```\n \u003clink rel=\"http://schemas.google.com/contacts/2008/rel#photo\"\n type=\"image/*\" href=\"https://www.google.com/m8/feeds/photos/media/liz%40example.com/c9012de\"\u003e\n ```\n\nDelete a photo for a shared contact\n-----------------------------------\n\nTo delete a photo, you must use the HTTP `DELETE` method.\n\nWhen updating or deleting a photo, send the photo's `ETag` in the `If-Match`\nheader of the HTTP request. If you don't have the latest version of the photo\nuse `If-Match: *` to override the versioning system and delete the photo.\n\nFor more information about `ETags`, see the\n[Google Data APIs protocol reference](https://developers.google.com/gdata/docs/2.0/reference#ResourceVersioning)."]]