Set the logo for an Azure Application using Microsoft Graph PATCH call with request body as image URL

Maddipatla Madhura 1 Reputation point
2023-07-15T02:36:11.6866667+00:00

I am creating azure AD application using Microsoft Graph API. Later I need to implement programmatically using java . While creating azure AD application for patch call logoUrl is not updating.

I know by using this endpoint we will update the logo by using put call. https://graph.microsoft.com/v1.0/applications/application-id/logo . My requirement is user need to pass image URL

I followed this document https://learn.microsoft.com/en-us/graph/tutorial-applications-basics?tabs=http.

Here it written as we will update logoUrl by using patch call. https://graph.microsoft.com/v1.0/applications/application-Object-id.

Json payload is

"info": {
        "logoUrl": "https://cdn.pixabay.com/photo/2016/03/21/23/25/link-1271843_1280.png",
        "marketingUrl": "https://www.contoso.com/app/marketing",
        "privacyStatementUrl": "https://www.contoso.com/app/privacy",
        "supportUrl": "https://www.contoso.com/app/support",
        "termsOfServiceUrl": "https://www.contoso.com/app/termsofservice"
    }

But all fields are updating except logoUrl. I am passing valid image url .

It giving 204 no content status but logo was not updating for the application.

I need to update logoUrl by using azure patch call using image Url as request body.

In below image it was written as we will update logoUrl by using Patchcall with request body image URL.

patch-call image

Microsoft Security | Microsoft Entra | Microsoft Entra ID
Microsoft Security | Microsoft Graph
{count} votes

1 answer

Sort by: Most helpful
  1. CarlZhao-MSFT 46,376 Reputation points
    2023-07-17T06:37:56.9633333+00:00

    Hi @Maddipatla Madhura

    You can upload a logo by calling PUT /applications/{applicationObjectId}/logo and it will automatically generate a logoUrl. The generated logoUrl is read-only and cannot be changed.

    User's image

    Hope this helps.

    If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.