Skip to main content
Skip table of contents

Configure Jira assets as a datasource

This guide provides step-by-step instructions to configure Jira Assets as a datasource in Elements Connect for Jira Cloud. By setting up this integration, you'll enable seamless access to asset data within your Jira issues, enhancing your ability to manage and utilize assets information effectively across your projects.

Prerequisites

Configuration steps

Discover your Workspace ID

The Jira Service Management REST API uses the workspaceId to identify your individual instance of Assets. You must include the workspaceId when making any calls to the REST API.

You can discover your workspaceId through the following endpoint:

https://<JSM Site Name>.atlassian.net/rest/servicedeskapi/assets/workspace

Be sure to replace <JSM Site Name> with the name of your own Jira instance.

Screenshot 2024-08-22 at 10.25.07.png

Generate a token to authenticate API calls

To authenticate API calls in Elements Connect, you need to use an API Token.

An API token is linked to an Atlassian user account and provides access to Jira Assets data based on the permissions of the user used to generate the token.

Considerations

  • The API token provides access to all Jira data that the user has permission to view, not just Jira Assets data. However, you can control which data is accessed by carefully configuring your queries, ensuring that only the intended information is exposed

  • The token’s access is limited by the user's permissions, so any changes in the user’s access could impact data retrieval

How to generate

After generating your API token, save it for later use in the Elements Connect configuration.

While a container token is mentioned in Jira Assets documentation, it does not work with Elements Connect and should not be used for this purpose.

Configure the Elements Connect datasource

Screenshot 2024-08-22 at 18.11.19.png
  1. Access your Jira instance:

    1. Go to your Jira instance

  2. Access Elements Connect administration:

    1. Click on “Apps” in the top bar menu, then select “Elements Connect”

    2. In the Elements Connect administration, click on “Data sources” to manage your connections.

  3. Create a new data source:

    1. Click on “Create data source”

    2. Select “REST API” as the data source type and click “Next”

    3. Provide a unique name for your data source and click “Create”

  4. Configure the data source:

    • Server Details:

      • API Base URL: 

        https://api.atlassian.com/jsm/assets/workspace/<Workspace ID>/v1

      • API Documentation:

        https://developer.atlassian.com/cloud/assets/rest/

      • API Test URL:

        https://api.atlassian.com/jsm/assets/workspace/YOUR_WORKSPACE_ID/v1/objectschema/list
        (info) Be sure to replace <Workspace ID> with your own Workspace ID

    • Authentication:

      • Mode: Basic

      • Login: Enter the email address associated with the Atlassian account used to generate the API token.

      • Password: Input the API token you generated, as detailed in the previous section.

  5. Test the connection:

    • Click the “Test connection” button to ensure that everything is working properly.

  6. Save your configuration:

    • Once the connection test is successful, save your datasource configuration. You’re all set!

Going further

The Jira Assets datasource in Elements Connect offers a wide range of capabilities that can enhance your Jira Service Management experience. Below are some use cases and examples to help you maximize the potential of this integration.

Use cases

The Jira Assets datasource can be used to enhance your service catalog by integrating asset data directly into Jira issues. For more details, see our guide: Optimizing service catalog navigation and maintenance in Jira: a complete guide to reducing workload and boosting user adoption

Endpoints examples

Once your datasource is configured, you can create connected fields and retrieve various types of information from Jira Assets. Here are some example API calls:

Name

Description

Method

URL

Search objects

Fetch Assets objects by performing an AQL search

POST

https://api.atlassian.com/jsm/assets/workspace/{workspaceId}/v1/object/aql

Request body example:
{"qlQuery":"Organization=\"OrgA\" and objectType=Customer"}

Get an object

Load an asset object

GET

https://api.atlassian.com/jsm/assets/workspace/{workspaceId}/v1/object/{id}

Get objectschema list

Find object schemas in Assets

GET

https://api.atlassian.com/jsm/assets/workspace/{workspaceId}/v1/objectschema/list

For more details and additional endpoints, explore the Assets REST API documentation.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.