Forums

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

Jira Cloud REST API - how to get organization id?

Michailo Liquidus March 25, 2025

Hello.

I'm using 3LO apps against multiple sites in different organization. I need to retrieve organization Id with api? Is there any endpoint for that?

Best regards
Mike

2 answers

0 votes
Vishal Biyani
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.
March 25, 2025

@Michailo Liquidus 

Can you check this link and see if this helps esp. Section 3.0?

OAuth 2.0 (3LO) apps

 

Michailo Liquidus March 25, 2025

sadly, I receive no `organization` in response from https://api.atlassian.com/me

Vishal Biyani
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.
March 25, 2025

@Michailo Liquidus 

To get the cloud id you can use

GET call on https://your-domain.atlassian.net/_edge/tenant_info

Michailo Liquidus March 25, 2025

I don't need cloudId, I need organizationId.

Vishal Biyani
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.
March 25, 2025

oh... okay.

To get Organization ID with REST API, we can use admin APIs. 

Follow the below steps

Part A: Creating API Key for use with ADMIN APIs

  1. Go To -> https://admin.atlassian.comSelect your organization if you have more than one.
  2. Select Settings -> API keys.
  3. Select Create API key in the top right
  4. Once the API key is created, Copy the values for your Organization ID and API key. You'll need those to use the API key.

Part B

Use GET -> https://api.atlassian.com/admin/v1/orgs to get org id

Headers 

"Accept": "application/json"

"Authorization": "Bearer <access_token obtained in PART A Step 4>"

Does this work for you?

Michailo Liquidus March 26, 2025

no, as I wrote I'm using 3LO apps, I can't ask my customers to give me their API Keys.

Vishal Biyani
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.
March 26, 2025

Then post your question to https://community.developer.atlassian.com/.

You have a better chance of getting guidance over there.

0 votes
Sebastian Krzewiński
Community Champion
March 25, 2025

Hi @Michailo Liquidus 

 

Please check this doc https://confluence.atlassian.com/cloudkb/retrieve-my-atlassian-cloud-organization-s-id-1207189876.html but Im afraid that if you are not org admin you won't be able to check it.

 

Regards,

Michailo Liquidus March 25, 2025

as I mentioned I'm using 3LO apps, I cannot use the resource you sent.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events