How to integrate with JIRA to create tickets
Scenario: A support team expects Jira tickets to be raised by a client, but the client does not have access to the Jira platform. The client has access to a portal where they can introduce the data related to the issue and press "Submit".
A process flow will be triggered in PROCESIO which will open the ticket in Jira and also send an email to the requester with the ticket details.
The process flow created will look like this:
Step 1. Create the email server configuration: check Working with Credentials Manager article. We will use the email server configuration in Send Email action setup.
Step 2. Create connection to Jira platform. Similar to the email server config, go to Credentials Manager section to set it up. We will use this API configuration in Call API action. Check JIRA Cloud platform REST API documentation.
Step 1. Create a new process: Go to Process Designer section and click on Create New button. This will take you to the canvas where you will build the flow.
Step 2. Add the Call API and Send Email actions on canvas and connect them by dragging relations between all the actions.
Step 3. Creating process variables: as mentioned at the beginning, we want to automate this process and make it pass dynamic data such as issue summary ,issue description, requester email address etc. Thus, we need to create some process variables within our process flow, which will act as data placeholders while designing the flow. At runtime, they will take new values.
Go to Process Variables (x) in the top bar to start creating the variables needed for this process. Click Add Variable. You need to define variables as follows:
Step 4. Configure the Call API action which will connect to JIRA and create the ticket.
- Click on Call API action and the properties panel will open. You can rename it from Call API to Create JIRA ticket.
- Select the API configuration created in step 1.
- Click on Configure Request to proceed next steps:
- For the Call API configurations you are going to check the JIRA's API documentation to check the method name, parameters needed, etc.
- We’ll select the verb POST. As you can see here the URL is pre-filled. This comes from the REST API credential configuration. I just need to specify which method name to use to have a valid endpoint - /rest/api/3/issue.
- body: add a JSON body that also includes process variables as defined in step 3:
- Make sure you update the body with your custom “key”, “name” and variables: “summary” and “text”.
To open the variables selector in Body and add process variables to your message: press Insert key (for Windows) or Shift +Tab (for MacOS)
- Map the status variable to the <%Status%> output property.
- Save the changes.
Step 5. Configure the Send Email action. Click on it and the properties panel will open. You can rename it from "Send Email" to "Send confirmation Email".
- Select the email server configuration created in step 2.
- Click on the Send Email card to proceed to the next steps:
- Configure the parameters of the action:
- The From field will set the display name of the sender. The actual email address of the sender is the one set in the Credential Manager, but we can set here the display name to be anything we want. I’ll use “Department name”.
- The To: the user requesting the ticket to be open; add <%requesterEmailAddress%> variable;
- The Subject: Your issue has been submitted!
- The Body:
To open the variables selector in Body and add process variables to your message: press Insert key (for Windows) or Shift + Tab (for MacOS).
Step 6. Save the process. Validate the process. Run the process.
Fill in the values for the input variables declared and hit run:
Once the process completes running, a notification will appear. Click on Check instances button to view the details at process and action level:
The ticket has been created in JIRA and a confirmation email with the ticket details was sent to the requester.
Congrats! You have just created a new process flow in PROCESIO!
If you encountered any issues while creating this process flow, please let us know as we are all growing together.