Back

Jira Software Cloud API Essential Guide

Aug 11, 20246 minute read

What type of API does Jira Software Cloud provide?

Jira Software Cloud primarily uses a REST API. The REST API uses JSON as its communication format and standard HTTP methods like GET, PUT, POST and DELETE.

There is also an Atlassian platform GraphQL API that can be used to access Jira data, among other Atlassian products. However, the GraphQL API support for Jira appears to be limited and still in development. As of March 2022, Jira was not fully available in the GraphQL API, with only Confluence and the early stage product Compass having full support. The Jira team was starting to produce GraphQL APIs, but they were in @Beta status and only available for web session calls, not for 3rd party OAuth or Connect app calls. The GraphQL API was slowly being adopted by the Jira Front End team to power issue experiences.

The documentation for the GraphQL API includes examples for querying Jira objects, and Jira types are included in the schema as per the API explorer. However, this may be misleading as full Jira support was not yet available.

As of June 2024, there were still questions about the availability and documentation of the GraphQL API for Jira.

In summary, while Jira Software Cloud does have a GraphQL API, it appears to be in a limited beta state with incomplete documentation. The primary and fully supported API for Jira Software Cloud remains the REST API. Developers looking to integrate with Jira Software Cloud should primarily focus on using the REST API unless they have specific needs that can only be met by the GraphQL API.

Does the Jira Software Cloud API have webhooks?

Yes, the official Jira Software Cloud API does support webhooks. Here are the key points about webhooks in Jira Cloud:

Webhook Support

  • Jira Cloud provides webhooks as a way to notify external applications when certain events occur in Jira.

  • Webhooks allow you to send push notifications from Jira to remote applications without requiring polling.

Available Events

You can subscribe to a wide variety of events via Jira Cloud webhooks, including:

  • Issue events: created, updated, deleted
  • Comment events: created, updated, deleted
  • Project events: created, updated, deleted
  • Version events: released, unreleased, created, updated, deleted
  • Sprint events: created, deleted, updated, started, closed
  • Board events: created, updated, deleted, configuration changed

Configuring Webhooks

  • Webhooks can be configured via the Jira administration console or the REST API.

  • When registering a webhook, you need to specify:

    • A name for the webhook
    • The URL to send the callback to (must be HTTPS)
    • Optional scope to filter issues (using JQL)
    • The events to subscribe to
  • You can secure webhooks by using a secret token to validate payloads.

Key Considerations

  • Only secure HTTPS URLs are allowed for webhooks.
  • The receiving server must have a valid SSL/TLS certificate.
  • You can use JQL to filter which issues trigger the webhook.
  • There are some limitations with JQL and webhooks in older Jira versions.

In summary, Jira Cloud provides a robust webhook system that allows you to subscribe to a wide variety of events and receive real-time notifications when those events occur in your Jira instance. This enables powerful integrations with external systems and applications.

Rate Limits and other limitations

Here are the key points about API rate limits for the Jira Software Cloud API:

Rate Limiting Implementation

  • Rate limiting is implemented by tracking the cost of processing requests against various cost budgets [1].

  • Requests are associated with different user-based budgets depending on the authentication type:

    • User
    • App
    • App + user
    • Anonymous
  • The exact rate limits are not published because the computation logic is evolving continuously [1].

Rate Limit Detection and Handling

  • Apps can detect rate limiting by checking for HTTP 429 status codes [1].

  • 429 responses may be accompanied by headers like:

    • Retry-After: Indicates how many seconds to wait before retrying
    • X-RateLimit-Reset: Indicates the date/time when the request can be retried
    • X-RateLimit-NearLimit: Indicates less than 20% of budget remains [1]
  • Apps should implement backoff and retry logic to handle rate limiting [1].

Key Considerations

  • Rate limits are per tenant (customer site) per endpoint, not per individual app [5].

  • There are no published specific limits, but Atlassian recommends:

    • 5 simultaneous requests from web browser
    • 10 simultaneous requests from backend [5]
  • Rate limiting protects customer instances and keeps them usable [5].

  • Developers should implement client-side rate limiting as a best practice [5].

  • Be prepared to handle 429 errors and implement retry logic with backoff [1][5].

In summary, while exact limits are not published, Jira Cloud does implement API rate limiting to protect customer instances. Developers should implement proper error handling and retry logic to work within these limits.

Latest API Version

Based on the search results provided, here is the answer to the question about the most recent version of the Jira Software Cloud API:

The most recent version of the Jira Software Cloud API is v2.

Key points to consider:

  • The Jira Cloud platform REST API documentation refers to "REST API v2" [1].

  • The search results do not explicitly mention a more recent version than v2 for the cloud API.

  • It's important to note that there are different APIs for Jira Software Cloud and Jira Data Center/Server versions. The search results contain information about both cloud and server/data center versions, but the question specifically asks about the cloud API.

Best practices:

  • Always check the official Atlassian developer documentation for the most up-to-date information on API versions and changes.

  • When developing integrations or apps for Jira Software Cloud, ensure you are using the latest supported API version to take advantage of new features and improvements.

  • Keep in mind that Atlassian may introduce new API versions or make changes to existing ones, so it's important to stay informed about any updates or deprecations.

[1] https://developer.atlassian.com/cloud/jira/platform/rest/v2/

How to get a Jira Software Cloud developer account and API Keys?

  1. Sign up for a free Atlassian Cloud developer account:
  • Go to go.atlassian.com/cloud-dev
  • Enter your work email and create an account
  • This will give you access to a Jira Software Cloud developer instance
  1. Set up OAuth 2.0 credentials for your integration:
  • In your Jira Cloud instance, go to Settings > Products > Application links
  • Create a new application link and select "Incoming link"
  • Configure the OAuth settings and permissions needed
  • This will generate a client ID and secret to use for authentication
  1. Use the OAuth 2.0 flow to get an access token:
  • Make a POST request to https://api.atlassian.com/oauth/token with your client ID and secret
  • This will return an access token to use for API calls
  1. Make API calls using the access token:
  • Use the access token in the Authorization header as a Bearer token
  • Make calls to the Jira REST APIs to create issues, etc.

What can you do with the Jira Software Cloud API?

Based on the search results provided, here is a list of data models you can interact with using the Jira Software Cloud API, along with what is possible for each:

Issues

  • Create, read, update, and delete issues
  • Search for issues using JQL
  • Add comments to issues
  • Add attachments to issues
  • Transition issues through workflows
  • Update issue fields
  • Manage issue links
  • Manage issue watchers and votes

Projects

  • Create, read, update, and delete projects
  • Manage project components
  • Manage project versions
  • Configure project settings and permissions

Users and Groups

  • Create, read, update, and delete users
  • Manage user groups
  • Search for users

Workflows

  • Create, read, update, and delete workflows
  • Manage workflow schemes
  • Configure workflow transitions and statuses

Fields and Screens

  • Manage custom fields
  • Configure screen schemes
  • Manage field configurations

Boards (Jira Software specific)

  • Create, read, update, and delete boards
  • Manage sprints on boards
  • Configure board settings

Epics (Jira Software specific)

  • Create, read, update, and delete epics
  • Manage issues within epics

Sprints (Jira Software specific)

  • Create, read, update, and delete sprints
  • Move issues in and out of sprints

Filters and Dashboards

  • Create, read, update, and delete filters
  • Manage dashboard gadgets

Permissions and Security

  • Manage permission schemes
  • Configure issue security schemes

Attachments

  • Upload and manage attachments for issues

Comments

  • Add, edit, and delete comments on issues

Time Tracking

  • Log work on issues
  • Manage worklog entries

Reporting

  • Generate various reports on project and issue data

Application Properties

  • Read and update Jira application properties

Server Info

  • Retrieve information about the Jira instance

This list covers the main data models and operations available through the Jira Software Cloud API. Each of these models allows for various CRUD (Create, Read, Update, Delete) operations and specific functionalities related to Jira's project and issue management features.