Hi.
We would like to be able to automate the creation of a PIR when an action is taken on an incident.
For example: An incident is marked as a Major Incident. Several actions are taken including the creation of the PIR case.
We have successfully created a case with the system-level Post-Incident review type. However, this does not appear in the PIR folder/filter view and does not carry the Request Type of 'Create a post-incident review'.
Is this possible?
Sure! You can create an automation that will have the trigger of "field value changed" and select the MAJOR INCIDENT field. Then, a condition to validate if this field is set and, lastly, the action to create a new issue based on your PIR issue type.
Please remember to accept this answer in case it helps you resolve your question as it may also help other community members in the future.
Regards,
Eugenio
I CAN create a PIR (Issue Type) but cannot set the Request type to 'Create a post-incident review'
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Here's the flow that creates the PIR:
It creates the PIR case based on the Issue type 'Post-incident review':
In the branch, we are trying to set the Request type:
This produces the following error:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can! The request type is a custom field, so you can set it using the smart values. Something linke "customfield_XXXX.name": "value" in JSON.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am still having an issue.
When I first used the action to update the Request Type, I received the error shown above. This gave me the name of the custom field.
So now I tried your suggestion of amending the custom field using json.
Here is my code:
This now produces a different error:
I cannot believe there is no way to update this field. Maybe I have something wrong?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have read this article and have tried amending the Actor from Automation to myself. This made no difference:https://confluence.atlassian.com/automationkb/automation-for-jira-reporting-unknown-fields-set-during-edit-they-may-be-unavailable-for-the-project-type-1130727699.html
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You are not using the appropriate structure of the Request Type field!
The JSON for the Request Type field is not correct.
Best approach would be to set this field manually in a single ticket, do a GET request for this specific field, so you can check the correct JSON structure for the Request Type field.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks. We finally discovered the issue was that, when attempting to use the 'Edit the Request type' action, it was reporting an issue against an incorrect customfield name.
When we went in to look at Request Types linked to Issue Types (Atlassian admin level) we discovered the correct customfield name and used that in the json to amend the field. We also had to you the code that represented the value rather than a string of text.
All rather convoluted, but that's jira I guess.
Still. Thanks for your assistance & support. Much appreciated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Rus Yates-Aylott great to hear. Please remember to accept this answer so it can be seen by other community members and help them out with the finds we had on this thread!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.