Creates a rule for the specified Connect Customer instance¶
Description¶
Creates a rule for the specified Connect Customer instance.
Use the Rules Function language to code conditions for the rule.
Usage¶
connect_create_rule(InstanceId, Name, TriggerEventSource, Function,
Actions, PublishStatus, PreEvaluationFilters, ClientToken, Tags)
Arguments¶
-
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] A unique name for the rule.
-
TriggerEventSource[required] The event source to trigger the rule.
-
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.
-
PreEvaluationFiltersThe 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.
-
ClientTokenA unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.
-
TagsThe tags used to organize, track, or control access for this resource. For example, { "Tags": {"key1":"value1", "key2":"value2"} }.
Value¶
A list with the following syntax:
Request syntax¶
svc$create_rule(
InstanceId = "string",
Name = "string",
TriggerEventSource = list(
EventSourceName = "OnPostCallAnalysisAvailable"|"OnRealTimeCallAnalysisAvailable"|"OnRealTimeChatAnalysisAvailable"|"OnPostChatAnalysisAvailable"|"OnAfterCallWorkAvailable"|"OnAfterChatWorkAvailable"|"OnEmailAnalysisAvailable"|"OnZendeskTicketCreate"|"OnZendeskTicketStatusUpdate"|"OnSalesforceCaseCreate"|"OnContactEvaluationSubmit"|"OnMetricDataUpdate"|"OnCaseCreate"|"OnCaseUpdate"|"OnSlaBreach"|"OnAlertUpdate"|"OnSchedulePublish"|"OnScheduleUpdate"|"OnScheduleTimeOffRequestActivity",
IntegrationAssociationId = "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"
)
)
),
ClientToken = "string",
Tags = list(
"string"
)
)