I wanted to see if there is a Way to get the license count by using Rest api. This is for JIRA Cloud instance . If yes , Can some one post the url which I can access to get the metrics . Thanks .
Note : I am using the below url but i am getting 404 error
https://<My url>/rest/plugins/applications/1.0/installed/jira-software
Hi Krishna,
Check out the applicationrole endpoint - here's the documentation for it.
The roles are sorted by application (Core, Software, Service Desk) and will return info about how many seats are available and how many are left:
"numberOfSeats": 10, "remainingSeats": 5, "userCount": 5,
Cheers,
Daniel
Hi @Daniel Eads
Apps cannot access this REST resource.
Is there another way to get programmatically this information from the app?
Thanks,
Jerry
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey @Jerry Laster [Divim, Inc.] ,
You as a user of a particular Atlassian Cloud instance should be able to access the details from this endpoint still. In the last year since this question was raised, we have changed the Cloud APIs to use tokens for authorization instead of passwords.
Apps in this context refer to items you may install in your instance from Atlassian Marketplace. Scripts making API calls should be fine (provided they use an API token).
Does that help? Or are you developing a plugin that you plan to distribute on Marketplace that would need access to the license counts?
Thanks,
Daniel | Atlassian Support
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Was this question ever answered?
I need to find a method to automate the monitoring of our licenses for our enterprise. Has any progress been made on this front?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Scott R Below is the Powershell script I use to get the user count
(Plug in your username and api key in line 1 and your Jira URI in line 4 . Rest Remains the same )
$user = [System.Text.Encoding]::UTF8.GetBytes(“yourusername:apikey”)
$headers = @{Authorization = "Basic " + [System.Convert]::ToBase64String($user)}
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
$result = Invoke-RestMethod -Uri "https://jira.atlassian.net/rest/api/latest/applicationrole" -Method GET -Headers $headers -ContentType "application/json"
$count=$result.userCount
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.