Update user using REST API

Selvaraj July 9, 2018

Hi,

Is there any support for update user details using REST API .

2 answers

0 votes
Alex Palermo May 23, 2020

Guys, I use cloud jira. It is only possible to use this change via rest api, when you register your domain within the jira cloud with your DNS server at the company.

Harry Bob
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
June 30, 2020

Hi @Alex Palermo 

 

Were you able to edit agents details through API cloud? I'd like to know how to do it if you were able to.

 

Thanks 

0 votes
Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 9, 2018
Selvaraj July 9, 2018

I had tried it but it shows 405 error

Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 9, 2018

Could you provide the json you are sending.

Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 9, 2018

error 405 means that you are trying to execute the wrong method. make sure you send a PUT request, not GET or POST.

Selvaraj July 11, 2018

I had sent PUT request but it is not working, it shows 405 error.

Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 11, 2018

How do you send the PUT request?

Selvaraj July 11, 2018

I send the PUT request using postman

Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 11, 2018

Could you provide the request here?

Selvaraj July 11, 2018

I have tried to PUT to https://{host}/rest/api/2/user?username=xyzzy 

Request

\{
"name": "xyxxx",
"emailAddress":"xyxx@example.com",
"displayName": "displayname"
} , 

Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 11, 2018

What is your Jira version?

Selvaraj July 12, 2018

I'm using this version JIRA 1001.0.0-SNAPSHOT Credits 

Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 12, 2018

Ah, you are on Cloud. I could not find PUT method for Cloud. I guess, you can not do it on Cloud

Richa Pathak December 11, 2019

Hey There Guys,

 

I am trying to run the below query but it's returning any result, no error. it's also not updating the data. any help would be highly appreciated. 

 

curl -s -X PUT -u Toolsuser1:XXXX --data "emailAddress":"tomd@new-domain.com" https://myjiraurl/rest/api/2/user?username=testuser19

Suggest an answer

Log in or Sign up to answer