/
unassign trigger action



unassign trigger action

Unassign trigger action

You can use the Unassign workflow trigger action to unassign a reviewer from an approval, for example, when the reviewer’s decision is no longer required.

cdmc_visualeditor_addtriggeraction_unassign_example_parameters_values_added.png
Visual editor - Add Unassign action

The Unassign action is used to unassign a single Confluence User. It occurs regardless of the reviewer’s current approval decision status.

By default, the user is unassigned from the first approval in the state named in the trigger condition (the default approval). Alternatively, you can choose a specific approval in one of the workflow states. Unless specified, the Comala Document Management app add-on user is added as the Assigner who unassigns the reviewer.

Unassign action parameters

Action Parameter

Value

Notes

Action Parameter

Value

Notes

User MANDATORY

Confluence user

  • one Confluence user

Confluence user to unassign

Approval

Approval to unassign the reviewer from

  • if no approval is specified, the user is unassigned from the default approval

Any approval in any state in the workflow can be selected.

The default approval is the approval in the state named in the trigger event condition.

If the state has multiple approvals, the default approval is the first approval listed in the state.

Assigner

The user who is added as unassigning the reviewer

  • if no value is added, the app add-on user is added

 

Comment

Text comment for the unassign action

Text comments are included with the unassigned activity entry in the document activity report.

When the workflow Event occurs, the trigger checks that any required Conditions are met, and if met, the Unassign action unassigns a single user as a reviewer from an approval.

“unassign” JSON code

An Unassign workflow trigger action added using the visual editor is automatically displayed in the workflow code editor as an “unassign” trigger action.

cdmc_codeeditor_unassigntriggeraction.png
Code editor - workflow trigger with Unassign action

You can also use the code editor to add the workflow trigger and the “unassign” action.

"unassign"

The trigger action "unassign" unassigns a user to a named approval.

  • action (unassign

    • approval - the name of the approval to assign. If not specified, the default approval is used

    • assigner - Atlassian  userID for the un-assigner (if no value is added, the app add-on user is the un-assigner for the action)

    • user ❗️ Atlassian  userID to unassign

    • comment - comment for the assignation operation


❗️ Mandatory parameter

user parameter for the user to be unassigned

The user parameter value must be specified with the "unassign" action parameter.


† Default approval

If no approval name is specified in the trigger action, the default approval is the approval in the state named in the trigger event condition.

If the state has multiple approvals, the default approval is the first approval listed in the state's JSON markup.


Example trigger code

"triggers": [ {"event": "on-change-state", "conditions": [ {state: "Draft"} ], "actions": [ {"action": "unassign", "approval": "Triagereview", "user": "5d52a37ef0f22a0da2d6f070"} ]} ]

The Atlassian user Identification Number (userID) is visible in the URL when viewing the User Profile.


Example

We can use the Unassign trigger action to remove a user as a reviewer in a state with multiple approvals.

For example, we have two approvals in the following Rejected state, each with assigned reviewers.

You can add the following workflow trigger with an Unassign action.

cdmc_visualeditor_addrejectedtrigger_rejectedstate_unassign_action.png

The Unassign action is added to remove a user on a rejected decision in the Rejected state.

cdmc_visualeditor_addunassignaction_rejectedstate_noapprovalselected-noassigner_selected.png

As the approval is not named in the trigger action, the assigned user is removed from the default approval, the Primary approval.

image-20241009-182634.png

The default approval is the approval in the state used in the workflow trigger condition. If there are multiple approvals in the state, this is the first approval listed in the state.

When the reviewer is unassigned, an entry is added to document activity for the page.

cdmc_documentreport_extract_unassigned_addonuser_unassigntriggerevent.png
Document activity - Unassigned action

In this example, a rejected event for either of the two approvals in the named state causes the unassigned trigger action. 

Related Pages