I’m working on a project where I need to fetch profile pictures of team members who are part of a Jira workspace. My current Jira installation is version 4.2 and I’ve been using the web service API for other tasks.
The problem is that I can only find methods to get project-related images, but nothing for individual user profile pictures. I’ve tried looking through the available SOAP operations but no luck so far.
I also noticed that these profile images are accessible through direct URLs, but when I try to access them I keep getting redirected to the login page even though I’m providing the same authentication credentials that work perfectly for my other API requests.
Has anyone successfully pulled user profile images from Jira? I’m open to any approach whether it’s through SOAP calls, REST endpoints, or even direct HTTP requests if someone knows the right way to handle the authentication part.
Had this exact problem with an older Jira instance. Profile images in Jira 4.2 are protected resources - they need session-based auth, not basic HTTP auth. Here’s what worked: establish a session through the standard login endpoint first, then use the JSESSIONID cookie for image requests. The URL’s usually /secure/useravatar?ownerId={username}&avatarId={id} but you’ve got to keep that session state alive. Without the session cookie, Jira just redirects you to login even if your credentials work fine everywhere else.
i had similar issues with my jira. u gotta get the JSESSIONID cookie and use that for image requests. basic auth wont work for profiles. once i switched to session-based auth, it started working. hope that helps!
For Jira 4.2, you’ll need a two-step process. First, authenticate with a regular SOAP call to get your session. Then use that session cookie for image requests. Profile images are usually at /secure/useravatar with ownerId and avatarId parameters. I hit the same redirect issue until I figured out images need cookie-based auth, not basic auth headers. Grab the Set-Cookie response from your auth call and include those cookies in your image requests. This worked great for me when I built something similar last year.