Skip to content

How to Add a BetterCloud Custom Trigger to an Existing Jira Integration


August 23, 2021

5 minute read

CustomeTriggers FeatureImage 1

On August 5, BetterCloud announced the release of Custom Triggers to help IT create more flexible automated workflows. One of the most common and powerful use cases we see for Custom Triggers is to kick off workflows from ticketing systems like Jira, which extends the scope of automation to earlier in a process and eliminates the need to manually kick off a workflow.

Integrating Jira into BetterCloud enables IT teams to track user onboarding and offboarding through Jira tickets, and trigger workflows off of conditions like ticket creation, a ticket being moved to a specific status, and more.

Today we’ll take a deep dive into how to add a Custom Trigger to an existing Jira integration. You can set up Custom Triggers in existing Action Only Integrations. If you don’t already have Jira integrated into BetterCloud, see this article for instructions on how to integrate Jira with BetterCloud.

Setting Up Your Custom Trigger in

Navigate your existing Atlassian or Jira Integration in the Integration Center and select “Modify.”

Navigate to the “Extensions” menu and select “Get Started.”

Select “Create a trigger for Workflows” and then click “Next.”

Name your Custom Trigger and optionally give it a description, then click “Next: Inbound Request.”

Take note of the new Inbound Request URL and proceed to the next section of this article to configure the Jira Automation.

Setting up your Jira Rule

Navigate to Jira Project you want to trigger the Workflow and navigate to “Automation” under the Project’s Settings.

Select the “Automations” tab on the right and create a project rule.

Select the Criteria you want to Trigger your workflow. Common examples include an Issue being created or transitioned to a new status. For this example, we will choose “Issue Created” and click “Save.”

Under the “Add Component” menu, select “New Action.”

Scroll down to the Notifications section and select “Send Web Request” as the action type.

Paste the BetterCloud Trigger URL into the “Webhook URL” field in JIRA and change the HTTP method to be “POST.”

For the Webhook body, select either “Custom data” or “Issue Data”. This example will use “Custom Data”, but provide whichever data points you want passed from the ticket to BetterCloud using JIRA Smart Values. The data should adhere to standard JSON format. 

Test your JIRA rule by selecting the “Validate your webhook configuration” dropdown and providing a sample Issue. Jira will then pull the selected fields from that issue and send them to BetterCloud.

[Pro Tip: If you include the Issue Key in your request, you can use it to write back to the ticket as part of your Workflow.]

If your test was successful, click “Save” and switch back to If your test was not successful, ensure you have followed the steps above correctly. 

Configuring your Custom Trigger  

If the above steps were successful, BetterCloud will display the test as received. Click “Next: Configure Workflow Options”. See our Custom Triggers article for more in depth details on what you can do here.

Click the “View Raw Data Response” field to view the format of the data that was sent to BetterCloud.

Select the target of your Custom Trigger. Typically something like a username or email makes sense in this target field. The easiest way to think about {target} is: “My Workflow just ran on {target}.”

Select if any parameters should be exposed as If Conditions or Dynamic Fields in the Workflow by checking the box next to the parameter. See our Custom Triggers article for a list of caveats related to If Conditions and Dynamic Fields.

For any data points that should be required for the Workflow to trigger, click the parameter and check the “Input is required” box. If a trigger that is missing a required field is sent to BetterCloud, it will be rejected and an audit log will be generated. 

Why make fields required? If a ticket is missing the user’s name, for example, it’s easier to catch missing data up front than it is to execute a full Workflows worth of actions and have them all fail because a critical data point is missing

See our Custom Triggers article for more in depth details on the Input is Required field

After you’ve configured your parameters, Save and Publish your Custom Trigger and head over to Workflows builder to begin using your Trigger! 

Once you’ve built a Workflow around this new Custom Trigger, you can begin to run a full test. Before you start, be sure your Jira Rule is enabled in Jira and your BetterCloud Workflow is published. Then navigate to your Jira board and trigger the evaluation criteria you specified (create a new issue, transition and issue, etc) and watch your new automation come to life.

What’s Next 

If you’re a BetterCloud customer with the Platform API, Custom Triggers are available for you to use now. Check back in the coming weeks for additional use case deep dives that will help you understand how to implement Custom Triggers and leverage their power to help you build automated workflows in a more extensible and flexible way. In the meantime, join over 5,000 IT pros in the largest SaaSOps Community to see how your peers are leveraging Custom Triggers—and to discuss more SaaSOps practices.

BetterCloud is the leading SaaS Management Platform (SMP), helping leading IT organizations discover, manage, and secure their SaaS applications. To learn more, request a demo.