Skip to main content
Version: Latest Version (2.9.2)

highbond_handler (Resource)

Schema

Required

nameString The name of the handler

Optional

actionsBlock List List of handler actions
Nested Schema for `actions`

Optional

action_typeString Can have Enum values: notify, transitionStatus, runRobot,sendQuestionnaire
configurationBlock List Will have configuration for the action_type
Nested Schema for `actions.configuration`

Optional

allowed_questionnaire_idsList of String The list of questionnaires that are going to be displayed in the UI dropdown, for the user to choose from. Used and required for the manual distribution_type
distribution_typeString Distribution type. When set to manual, this implies that the event is being invoked manually (i.e. through APIs or the UI). When set to automated, this implies that the event is being invoked asynchronously through triggers (currently, is only supported using the fieldUpdated trigger type)
email_attribute_field_nameString A field name that references a field containing an email address (which represents the questionnaire recipient). Text and user lookup fields can be used - at this time, only one email is supported (if there are multiple, only the first email in the field will be used). Used and required for the automated distribution_type
email_bodyString The email subject of the email notification
email_subjectString The email body of the email notification
emailsSet of String The list of email addresses that the email notification will be sent to
questionnaire_context_fieldsList of String A list of field names that the display name and value will be shown up in questionnaire responding page
sent_questionnaire_idString The id of the questionnaire to be sent. Used and required for the automated distribution_type
status_idString The ID of the Workflow Status to transition an Item to by this Handler Action
task_idString The ID of the Workflow Robot task to run
nameString The name of the handler action
on_success_messageString When on_success_message is set, show_success_message must be set to true.
scopesList of String Array of strings, with default Items Value: self
show_success_messageBoolean Whether or not an success message is shown.
condition_conjunctionString Type of conditions, can have possible Enum values: allOf, anyOf
conditionsBlock List An array of Conditions
Nested Schema for `conditions`

Optional

condition_typeString Determines conditions under which an asset or record can advance to the next workflow status. Enum values:allRequiredFieldsAreProvided,specificFieldsAreRequired, fieldValueComparison
configurationBlock List Handler Conditions Configuration Options
Nested Schema for `conditions.configuration`

Optional

field_namesSet of String list of attributes that need to be checked
left_operand_field_nameString The field of whom's value will be operated on (will be used to compare against right_operand_value). To reference a workflow status' name, use metadata.workflow_status
operatorString Numeric Operators (string) or Boolean Operators (string) or Text Operators (string) or Select Operators (string)
right_operand_valueList of String A list of values that left_operand_field_name will be compared against. The values can be number-like, boolean-like, or text. At this time, we only support one value passed in this list. This value is ignored when operators is_blank or is_not_blank is used, in all other cases this value is required
nameString The name of the handler condition
on_failure_actionString Can have possible Enum values:stopAllHandlersForThisEvent, stopThisHandlerForTheCurrentItem
on_failure_display_messageBoolean, Deprecated
on_failure_messageString will have failure message
scopesList of String Array of strings, with defult Items Value: self
show_failure_messageBoolean Whether or not an error message is shown. If on_failure_message is defined a custom error message is shown.
descriptionString The description of the handler
force_updatesBoolean Allows overriding top-level 'create_only' option.
idString The ID of this resource.
sharedBoolean Handlers can be marked as shared. Only shared handlers can be reused across multiple events in different workflows

Read-Only

created_atString The date the handler was created
updated_atString The date the handler was updated

Example Usage

// Handler
resource "highbond_handler" "main" {
name = "Feb 26 Handler 1"
description = "Description of My first Handler"
shared = false
condition_conjunction = "allOf"
force_updates = true // Create only with force update changes
conditions {
name = "BViswa"
condition_type = "specificFieldsAreRequired" // Values can be specificFieldsAreRequired,fieldValueComparison
configuration {
field_names = ["reviewSummary", "reviewer"]

// Required when condition_type is fieldValueComparison
left_operand_field_name = highbond_attribute_type.text.field_name
right_operand_value = ["test"]
operator = "equals"
}
scopes = ["self"]
on_failure_action = "stopAllHandlersForThisEvent"
// on_failure_display_message will be deprecated and replaced by show_failure_message. Only this boolean OR show_failure_message may be set in a single request
// Strictly Use either `on_failure_display_message` or `show_failure_message`. Do not use both the fields together
on_failure_display_message = true
show_failure_message = true
on_failure_message = "Testing"
}

actions {
name = "Action name1"
action_type = "transitionStatus" // Values can be notify,transitionstatus,runRobot and sendQuestionnaire
configuration {
status_id = "8bdecf0c-1145-4e2c-af90-da3a0595ec19" // Required when action_type is transitionStatus
}
scopes = ["self"]
}
actions {
name = "Action name2"
action_type = "notify"
configuration {
emails = ["ccc@aaa.com", "ddd@bbb.com"]
email_body = "This is test body"
email_subject = "This is the subject"
}
scopes = ["self"]
show_success_message = true
on_success_message = "Test success message"
}

actions {
name = "Action name3-Rub robot task"
action_type = "runRobot"
configuration {
task_id = highbond_robot_task.main.id
}
scopes = ["self"]
}

actions {
name = "Action name2-send the Questionnaire"
action_type = "sendQuestionnaire"
configuration {
allowed_questionnaire_ids = [highbond_questionnaire.main.id]
questionnaire_context_fields = ["field_names"]
email_attribute_field_name = highbond_attribute_type.email.field_name
distribution_type = "automated" // Values can be manual,automated
sent_questionnaire_id = highbond_questionnaire.main.id // Required when distribution_type is automated
}
scopes = ["self"]
}
}