REST API Endpoint: Updating user avatar/profile picture

Hello!

I'm looking for a REST Endpoint, that a custom client can use to update the users profile data and picture.

Thanks!

 

2 answers

0 vote
Stephen Deutsch Community Champion Jan 10, 2018

I don't think Confluence has a REST API endpoint for that yet, but you can use the XML-RPC/JSON-RPC API for that. There's a method called "addProfilePicture" that you can use: https://developer.atlassian.com/server/confluence/remote-confluence-methods/#user-management

Remember that for the RPC API you have to call the login method to get the token. If you are making the call from browser Javascript, though, this is unnecessary and the token will be filled in automatically.

If you're looking to do so in JIRA, it's a bit different and can be done via the REST API. This was the answer I used when I was trying to figure it out: https://community.atlassian.com/t5/Answers-Developer-Questions/Avatar-upload-with-Jira-5-REST-API/qaq-p/475376

Hey Stephen,

thanks alot! I'll try it out!

Greetings,

Christoph

The following REST calls may help you. These calls are private. I'll try them tomorrow, too. Let's see what happens. Or have you already solved it?

/rest/user-profile/1.0/avatar/uploadFallback
/rest/user-profile/1.0/{userKey}/avatar/default
/rest/user-profile/1.0/{userKey}/avatar/upload

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Friday in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

251 views 11 10
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you