To learn more about Tempo products, please visit our Help Center. For support, see our Support Portal.

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Unable to render {include} The included page could not be found.

There might be cases where we want to assign a Jira issue to a specific Tempo Team based on certain conditions. In the example below we use the Jira issue assignment as trigger to run of an automation rule to set a Tempo Team on the Jira issue. Further we can implement a what-if scenario by setting the Team name based on the assignee user or the assignee belonging to a Jira group.

Since the Tempo Team field can´t be set out of the box we will need to leverage the advances options when editing the Jira issue in an automation. Therefore we need the Tempo team customfield ID. Jira custom fields can be retrieved from the Jira API

{YourJiraCloudUrl}/rest/api/3/field

In the response search for “Team”. This should give you something like:

{
        "id": "customfield_11718",
        "key": "io.tempo.jira__team",
        "name": "Team",
        "untranslatedName": "Team",
        "custom": true,
        "orderable": true,
        "navigable": true,
        "searchable": true,
        "clauseNames": [
            "cf[11718]",
            "Team"
        ],
        "schema": {
            "type": "option2",
            "custom": "com.atlassian.plugins.atlassian-connect-plugin:io.tempo.jira__team",
            "customId": 11718
        }
    },

That means in our case the Tempo Team customfield has the ID “11718”.

Before we go into Automation for Jira we will also need the respective Tempo Team IDs as we can´t use the Tempo Team names in Automation for Jira. We can get the Team ID by navigating to the Tempo Team and look for the ID in the url.

Or we can leverage the Tempo Team REST API to get the Tempo Teams, their names and IDs.

https://api.tempo.io/core/3/teams

This will get us a response as:

{
  "self": "https://api.tempo.io/core/3/teams/2",
  "id": 2,
  "name": "Web Development",
  "summary": "",
  "lead": {
    "self": "https://cops.atlassian.net/rest/api/2/user?accountId=5cb085549b0de43f0aea7154",
    "accountId": "5cb085549b0de43f0aea7154",
    "displayName": "Angel Williams"
  },
  "program": null,
  "links": {
    "self": "https://api.tempo.io/core/3/teams/2/links"
  },
  "members": {
    "self": "https://api.tempo.io/core/3/teams/2/members"
  },
  "permissions": {
    "self": "https://api.tempo.io/core/3/teams/2/permissions"
  }
},...

Make sure that the Tempo Team is linked to the Jira project where you want to use the Jira automation rule for. The Tempo Team can only be set on the Jira issue when the Tempo Team is linked to the Jira project.

Once we ensured that we have everything we need to ensured all settings are correct we can go ahead with Automation for Jira.

Our rule looks like this:

The trigger for the rule is when a user is assigned to a Jira issue or the assignee changes.

We implemented in the example a condition rule checking on the assignee. Means we want to set a different Tempo Team based on the assignee of the Jira issue. Without going into too much details you can check the value against a specific user or if the assignee belongs to a certain Jira group. Just have in mind that the if-block is exited once a condition is met.

After the condition check we finally assign the Tempo Team to the issue by setting the Tempo Team custom field.

In the “More Options” section you set the values based on the Jira customfield ID and the Tempo Team ID that we have retrieved above. Make sure that you escape the Tempo Team ID.

{
    "fields": {
        "customfield_11718": "2"
        }
}

That´s all. As always check the audit logs if any problems occur. The automation should now set the Tempo Team customfield.

  • No labels