- 🚀 Quickstart
- 🧑💻 OAuth app setup
- 🔗 Useful links
- 🚨 API gotchas
Create an integration
In Nango (free signup), go to Integrations -> Configure New Integration -> Jira.
Authorize Jira
Go to Connections -> Add Test Connection -> Authorize, then log in to Jira. Later, you’ll let your users do the same directly from your app.
Call the Jira API
Let’s make your first request to the Jira API (fetch a list of issues). Replace the placeholders below with your secret key, integration ID, and connection ID:Or fetch credentials dynamically via the Node SDK or API.
- cURL
- Node
Copy
Ask AI
curl "https://api.nango.dev/proxy/ex/jira/{connectionConfig.cloudId}/rest/api/3/search?maxResults=10" \
-H "Authorization: Bearer <NANGO-SECRET-KEY>" \
-H "Provider-Config-Key: <INTEGRATION-ID>" \
-H "Connection-Id: <CONNECTION-ID>"
Install Nango’s backend SDK with
npm i @nangohq/node. Then run:Copy
Ask AI
import { Nango } from '@nangohq/node';
const nango = new Nango({ secretKey: '<NANGO-SECRET-KEY>' });
const res = await nango.get({
endpoint: '/ex/jira/{connectionConfig.cloudId}/rest/api/3/search',
params: {
maxResults: 10
},
providerConfigKey: '<INTEGRATION-ID>',
connectionId: '<CONNECTION-ID>'
});
console.log(JSON.stringify(res.data, null, 2));
The
{connectionConfig.cloudId} in the URL represents the cloudId. You can get this value from your connection configuration after creating the connection. The cloudId is automatically set by Nango.Next step: Embed the auth flow in your app to let your users connect their Jira accounts.
Create an Atlassian developer account
If you don’t already have one, sign up for an Atlassian developer account.
Create a new OAuth 2.0 (3LO) app
- Go to the Atlassian Developer Console.
- Click Create and select OAuth 2.0 integration.
- Enter a name, agree to Atlassian’s developer terms by checking the agreement checkbox for your app and click Create.
- Your app will be created and you’ll be taken to the app management page.
Configure OAuth 2.0 (3LO)
- In the left sidebar, select Authorization.
- Next to OAuth 2.0 (3LO), click Add.
- Enter
https://api.nango.dev/oauth/callbackas the Callback URL. - Click Save Changes to save your changes.
Add API permissions
- In the left sidebar, select Permissions.
- Find the Jira API and click Add, and then click Configure.
- Click Edit Scopes then select the scopes your application requires. For reference, see our Common Scopes table below.
- Click Save to save your changes.
Obtain your client credentials
- In the left sidebar, select Settings.
- Note your Client ID.
- Copy both the Client ID and Secret by clicking the copy buttons next to them, as you’ll need them when configuring your integration in Nango.
Make your app available to users
- In the left sidebar, select Distribution.
- In Distribution controls, click the Edit button, select the Sharing radio button, enter a Privacy Policy URL and then click the Save changes button.
By default, your app is private and can only be used by you. Making it public allows other users to authorize your app.
Next
Follow the Quickstart.
Common Scopes
| Scope | Description |
|---|---|
| read:jira-user | Read user information |
| read:jira-work | Read Jira work items (issues, projects, etc.) |
| write:jira-work | Create and update Jira work items |
| delete:jira-work | Delete issues |
| manage:jira-project | Manage project settings |
| manage:jira-configuration | Manage Jira instance settings |
| offline_access | Access to refresh tokens for offline access |
Contribute useful links by editing this page
- Refreshing tokens require the
offline_accessscope when creating the integration on the Nango UI. - When connecting to Jira, you have two options for specifying which Jira site to connect to:
- Provide a
Subdomainduring connection creation (recommended) - Let Nango auto-select the first available site (legacy behavior): If no
Subdomainis specified, Nango will use the first site from the accessible resources api.
- Provide a
Copy
Ask AI
const response = await nango.get({
endpoint: `oauth/token/accessible-resources`,
baseUrlOverride: 'https://api.atlassian.com'
});
const cloudId = response.data[0].id;
-
A single Jira OAuth token can be valid for multiple Atlassian sites. For example, the same token might grant access to both “nango-hq.atlassian.net” and “nango-test.atlassian.net”. This is why specifying the
Subdomainduring connection creation is important if you need to connect to a specific site. -
The connection process works as follows:
- Nango fetches all accessible sites for the OAuth token
- If you specified a
Subdomain, Nango finds the matching site and sets itscloudId - If no
Subdomainis specified, Nango uses the first available site and sets itscloudId - The selected site’s
cloudIdandsubdomainare stored in the connection configuration
-
The
cloudIdis required to make API requests to the Jira APIv3. Nango handles getting this automatically by matching it to your specifiedsubdomainif provided, or by selecting the first available site if it is not. You will then need to construct your Nango integration’sendpointas follows:/ex/jira/${cloudId}/rest/api/3/<endpoint> - When you create an OAuth 2.0 (3LO) app, it’s private by default. Before using the integration, you must make your app public. If you want to make your app public, find the how-to here.
-
Refresh tokens will expire after 365 days of non use and will expire by 90 days if the resource owner is inactive for 90 days. Make sure you call
nango.getConnection()at least every 365 days to trigger a refresh. See reference here. - When making API calls, remember that the permissions of the user who authorized your app will limit what your app can do, regardless of the scopes you’ve requested.
- The Jira REST API has different versions (v2 and v3). Make sure you’re using the correct version for your needs.
Contribute API gotchas by editing this page
Questions? Join us in the Slack community.