Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Difficulty managing user management REST API

Lee Correll
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.
November 18, 2019

I am a:

  • site administrator
  • administrator
  • jira-administrator
  • organization administrator

I create a 7 day API key at admin.atlassian.com / settings / API keys; the key doesn't expire until 11/25/2019.

I'm running JIRA Cloud.  Following the instructions at https://developer.atlassian.com/cloud/admin/user-management/rest/

I pick a user that I ultimately want to disable, but for the moment, let's just look at what I can do to that account:

https://api.atlassian.com/users/557058:f4689d7f-1829-4214-a5fb-c0573887d468/manage

(I'm not concerned about security here - anybody other than me shouldn't be able to do anything with that account ID anyway.)

My header reads:

Authorization: Bearer {api token}

I get back:

403 / Forbidden.

Maybe the URL is wrong?  So I try https://api.atlassian.com/admin/users/557058:f4689d7f-1829-4214-a5fb-c0573887d468/manage and that gets me a 404 / Not Found error.

Obviously, I'm doing something basic incorrectly here, because this is as about as straightforward as it can be.

 

1 answer

0 votes
Murray Carson
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 10, 2020

First of all, thank you Lee, for posting this, because reading through it helped me to realize that I needed an organization API key rather than a personal one.  After doing that I was able to get the api you referenced to work (the first one): /users/[user account id]/manage.

The only issue that I can think of that might be causing you difficulty would be setting up managed accounts.  The user management API only works for managed accounts and you have to claim the domain for the email addresses you want to manage.  If you haven't done so please take a look at the documentation that can be found by following the link below about setting up managed accounts and verifying a domain.

Link for managed accounts/verifying domain: 

https://confluence.atlassian.com/cloud/verify-a-domain-for-your-organization-873871234.html

Hope that helps!

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, loom, loom for training, loom for teaching, video training, async learning, online education, screen recording, loom tutorials, loom use cases, atlassian learning, team training tools, instructional video, virtual training tools

🛗 Elevate Your Training and Enablement with Loom

Join us June 26, 11am PT for a webinar with Atlassian Champion Robert Hean & Loom’s Brittany Soinski. Hear tips, stories, and get your burning questions answered. Learn how Loom makes training and enablement easier. Don’t miss it!

Register today
AUG Leaders

Atlassian Community Events