Skip to content

Updates a rule for the specified Connect Customer instance

Description

Updates a rule for the specified Connect Customer instance.

Use the Rules Function language to code conditions for the rule.

Usage

connect_update_rule(RuleId, InstanceId, Name, Function, Actions,
  PublishStatus, PreEvaluationFilters)

Arguments

  • RuleId

    [required] A unique identifier for the rule.

  • InstanceId

    [required] The identifier of the Connect Customer instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.

  • Name

    [required] The name of the rule. You can change the name only if TriggerEventSource is one of the following values: OnZendeskTicketCreate | OnZendeskTicketStatusUpdate | OnSalesforceCaseCreate

  • Function

    [required] The conditions of the rule.

  • Actions

    [required] A list of actions to be run when the rule is triggered.

  • PublishStatus

    [required] The publish status of the rule.

  • PreEvaluationFilters

    The pre-evaluation filters for the rule, that restrict the rule to be applied to only certain resources based on the resource's attributes, such as tags assigned to a contact. The pre-evaluation filters are applied even before rule conditions are evaluated and are used to enforce tag-based-access-control while applying rules.

Value

An empty list.

Request syntax

svc$update_rule(
  RuleId = "string",
  InstanceId = "string",
  Name = "string",
  Function = "string",
  Actions = list(
    list(
      ActionType = "CREATE_TASK"|"ASSIGN_CONTACT_CATEGORY"|"GENERATE_EVENTBRIDGE_EVENT"|"SEND_NOTIFICATION"|"CREATE_CASE"|"UPDATE_CASE"|"ASSIGN_SLA"|"END_ASSOCIATED_TASKS"|"SUBMIT_AUTO_EVALUATION"|"EXTRACT_INFORMATION"|"SEND_IN_APP_NOTIFICATION",
      TaskAction = list(
        Name = "string",
        Description = "string",
        ContactFlowId = "string",
        References = list(
          list(
            Value = "string",
            Type = "URL"|"ATTACHMENT"|"CONTACT_ANALYSIS"|"NUMBER"|"STRING"|"DATE"|"EMAIL"|"EMAIL_MESSAGE"|"EMAIL_MESSAGE_PLAIN_TEXT"|"EMAIL_MESSAGE_PLAIN_TEXT_REDACTED"|"EMAIL_MESSAGE_REDACTED",
            Status = "AVAILABLE"|"DELETED"|"APPROVED"|"REJECTED"|"PROCESSING"|"FAILED",
            Arn = "string",
            StatusReason = "string"
          )
        )
      ),
      EventBridgeAction = list(
        Name = "string"
      ),
      AssignContactCategoryAction = list(),
      SendNotificationAction = list(
        DeliveryMethod = "EMAIL",
        Subject = "string",
        Content = "string",
        ContentType = "PLAIN_TEXT",
        Recipient = list(
          UserTags = list(
            "string"
          ),
          UserIds = list(
            "string"
          )
        ),
        Exclusion = list(
          UserTags = list(
            "string"
          ),
          UserIds = list(
            "string"
          )
        )
      ),
      CreateCaseAction = list(
        Fields = list(
          list(
            Id = "string",
            Value = list(
              BooleanValue = TRUE|FALSE,
              DoubleValue = 123.0,
              EmptyValue = list(),
              StringValue = "string"
            )
          )
        ),
        TemplateId = "string"
      ),
      UpdateCaseAction = list(
        Fields = list(
          list(
            Id = "string",
            Value = list(
              BooleanValue = TRUE|FALSE,
              DoubleValue = 123.0,
              EmptyValue = list(),
              StringValue = "string"
            )
          )
        )
      ),
      AssignSlaAction = list(
        SlaAssignmentType = "CASES",
        CaseSlaConfiguration = list(
          Name = "string",
          Type = "CaseField",
          FieldId = "string",
          TargetFieldValues = list(
            list(
              BooleanValue = TRUE|FALSE,
              DoubleValue = 123.0,
              EmptyValue = list(),
              StringValue = "string"
            )
          ),
          TargetSlaMinutes = 123
        )
      ),
      EndAssociatedTasksAction = list(),
      SubmitAutoEvaluationAction = list(
        EvaluationFormId = "string"
      ),
      ExtractInformationAction = list(
        RulesExtractionDefinitions = list(
          list(
            Identifier = "string"
          )
        )
      ),
      SendInAppNotificationAction = list(
        Content = list(
          "string"
        ),
        Recipient = list(
          UserTags = list(
            "string"
          ),
          UserIds = list(
            "string"
          )
        ),
        Exclusion = list(
          UserTags = list(
            "string"
          ),
          UserIds = list(
            "string"
          )
        ),
        Priority = "HIGH"|"LOW"
      )
    )
  ),
  PublishStatus = "DRAFT"|"PUBLISHED",
  PreEvaluationFilters = list(
    AndConditions = list(
      list(
        ResourceType = "CONTACT",
        FilterType = "TAG",
        FilterKey = "string",
        FilterValue = "string",
        Operator = "EQUALS"
      )
    )
  )
)