locked
How to set a thumbnail photo in Azure AD? Sync thumbnail photos between Exchange Online and Azure AD? RRS feed

  • Question

  • We're interested in downloading the thumbnail photo for users in an O365 tenant using the REST API, but we're stumped regarding how to set a thumbnail photo for a user in Azure AD.  We haven't found a way to do it via the user interface and it doesn't appear to sync between Exchange Online and Azure AD.  The only sync reference we've been able to find is between Windows Server AD and Azure AD which is not applicable in our use case?

    Any pointers on how to get the thumbnail photo set?

    Tuesday, January 6, 2015 3:50 PM

Answers

  • Greetings!

    You may use the sample (Malar has shared above) which helps how to query Azure AD using the Graph API, demonstrates additional REST functionality to Get and Set User Details, including thumbnail photos.

    Would like to add: http://matthewyarlett.blogspot.co.uk/2013/08/add-or-update-user-profile-picture.html

    You can use the AD module for PowerShell for getting / setting the AD user.

    Would like to re-iterate that there are constraints on the sizes and formats supported for the thumbnailPhoto Active Directory attribute. As a general guideline, keep your images to 96x96 pixels and under 10Kb, using JPG format.

    Thank you,

    Arvind

    Thursday, January 8, 2015 12:20 PM

All replies

  • Hi Andrea,

    You could try ConsoleApp-GraphAPI-DotNet, this console app demonstrates common Read and Write calls to the Graph API, and shows how to execute user license assignment and update a user's thumbnail photo and links.
    You could refer the following link for details:

    https://github.com/AzureADSamples/ConsoleApp-GraphAPI-DotNet

    Regards,
    Malar.

    • Proposed as answer by Lucian Busoi Sunday, August 21, 2016 8:18 AM
    Tuesday, January 6, 2015 6:48 PM
  • Thanks, Malar.  We're developing an application which uses the graph API and we're strictly consumers of the user data in the tenant.  It sounds like the only way users of our application would have thumbnail photo data is if they have some sort of sync process in place that sets thumbnail photos in Azure AD.  Good to know.
    Wednesday, January 7, 2015 2:07 AM
  • Greetings!

    You may use the sample (Malar has shared above) which helps how to query Azure AD using the Graph API, demonstrates additional REST functionality to Get and Set User Details, including thumbnail photos.

    Would like to add: http://matthewyarlett.blogspot.co.uk/2013/08/add-or-update-user-profile-picture.html

    You can use the AD module for PowerShell for getting / setting the AD user.

    Would like to re-iterate that there are constraints on the sizes and formats supported for the thumbnailPhoto Active Directory attribute. As a general guideline, keep your images to 96x96 pixels and under 10Kb, using JPG format.

    Thank you,

    Arvind

    Thursday, January 8, 2015 12:20 PM