Skip to main content
Skip table of contents

Automation for Jira via Workflows

There are different ways to have our app and Jira Automation work together. Read more about how you can integrate Deep Clone for Jira in your automated workflows.

How to Trigger Deep Clone From Jira Automation (Company-managed)

This guide only applies to company-managed Jira projects. Look here if you want to trigger a Deep Clone with a Jira Automation in a team-managed Jira project.

If you want to trigger Deep Clone with Jira Automation, we recommend to work with Deep Clone post functions and (global) looping transitions - meaning that the status of origin is also the status of destination.

Default workflow with a looping transition marked

This is how you can set up a Jira Automation with (global) looping transitions.

  1. Add a global looping transition to your workflow.

  2. Add a Deep Clone post function to the looping transition.

  3. Create a new Jira Automation rule with an action that triggers the looping transition.

    1. Click on “+ add regex to distinguish between multiple transitions to the same status”

    2. Define a transition match with the name of your global looping transition (e.g. Clone), to make sure that the correct transition is triggered.

Configuration screen of transition issue automation configuration with the regex matching marked

Now you can trigger a Deep Clone via Jira Automation without changing the status of an issue.

Make sure that your automation rule doesn’t cause a loop that creates infinite clones. Issues that are created with Deep Clone can trigger automations of “Issue updated” rules.

  • Global looping transitions can be removed from the issue view by adding the condition “Hide from User” to the transition.

  • If Deep Clone and Automation overwrite each other, you could insert a ‘refetch issue data’ action immediately after the trigger in Automation for Jira. In ‘more options’ you can manually configure a delay which would solve your problem.

How to Trigger Deep Clone From Jira Automation (Team-managed)

Due to limitations of team-managed projects in Jira Cloud, it isn’t possible to add a Jira Post Function Clone to a transition in the workflow. To trigger Deep Clone in a team-managed project, you need to use our Deep Clone for Jira REST API.

Configure Jira Automation

  1. Select the wanted trigger for your Jira Automation (and add if-conditions if needed)

Create a trigger
  1. (Optional) Add if-Conditions

Add a condition
  1. Add Send web request action

Send web request

Configure Deep Clone for Jira REST API Web Request

  • Web request URL either:

    • Single Clone: https://deep-clone-for-jira.[REGION].connect.codefortynine.com/clone/rest/single/{originalIssueIdOrKey}

    • Project Clone: https://deep-clone-for-jira.[REGION].connect.codefortynine.com/clone/rest/project

    • Rank Issue:https://deep-clone-for-jira.[REGION].connect.codefortynine.com/clone/rest/rank/clonedIssuesRank

You have to replace [REGION] with your hostname suffix. You can find out how to determine your suffix here.

  • Headers (optional)

    • content-type: application/json

    • Authorization: Basic User:Password

      • You can retrieve your User and Password under Apps > Manage Apps > REST API

      • You need to encode the “User:Password” string with Base64 and use the encoded string in the Authorization header

  • HTTP method: POST

  • Web request body: Custom data

Jira Automation Send web request configuration example

How to Trigger a Jira Automation From Deep Clone (Incoming Webhook)

You can also let Deep Clone trigger a Jira Automation Incoming Webhook on the issues created by Deep Clone. Just create a Webhook (using the first option, “Issues provided in the webhook HTTP POST body”) and adjust Deep Clone with the Webhook URL:

Deep Clone for Jira with Trigger Jira Automation Incoming Webhook on the cloned issue selected

Make sure that the Jira Automation rule is either global or, if it’s a “Project rule”, within the target project where the cloned issue is created.

Beware of infinite loops between Jira Automation and any Workflow Post Functions, possibly triggered by Jira Automation as well.

Read More

JavaScript errors detected

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

If this problem persists, please contact our support.