Get all project avatars is not working as expected

We are trying to use https://developer.atlassian.com/cloud/jira/platform/rest/v3/?utm_source=%2Fcloud%2Fjira%2Fplatform%2Frest%2F&utm_medium=302#api-rest-api-3-project-projectIdOrKey-avatars-get to get list of project avatars. Instead of project avatars, it is returning the user avatars

Expected (see the urls object. the dimension property url is /secure/viewavatar. This is the example response snippet from Atlassian. )

{
      "id": "1000",
      "isSystemAvatar": true,
      "isSelected": false,
      "isDeletable": false,
      "urls": {
        "16x16": "https://your-domain.atlassian.net/secure/viewavatar?size=xsmall&avatarId=10040&avatarType=project",
        "24x24": "https://your-domain.atlassian.net/secure/viewavatar?size=small&avatarId=10040&avatarType=project",
        "32x32": "https://your-domain.atlassian.net/secure/viewavatar?size=medium&avatarId=10040&avatarType=project",
        "48x48": "https://your-domain.atlassian.net/secure/viewavatar?avatarId=10040&avatarType=project"
      }
    }

Actual (Check the url object. Each dimension property is referring to /secure/useravatar) :

{
id: "10400",
isSystemAvatar: true,
isSelected: false,
isDeletable: false,
urls: {
16x16: "/secure/useravatar?size=xsmall&avatarId=10400",
24x24: "/secure/useravatar?size=small&avatarId=10400",
32x32: "/secure/useravatar?size=medium&avatarId=10400",
48x48: "/secure/useravatar?avatarId=10400"
}
}

Hi @DurgaprasadJamanjyot,

This seems like a bug. Whilst reproducing this, I also added an avatar to a project, but visiting the URLs for all of the avatar sizes returned by the REST API resulted in a 404.

I’ll create an issue for this.

Regards,
Dugald

I’ve created https://jira.atlassian.com/browse/JRACLOUD-74563 for this.

1 Like