Class CfnRule
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.connect.CfnRule
- All Implemented Interfaces:
IInspectable,IRuleRef,IEnvironmentAware,ITaggable,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.119.0 (build 1634eac)",
date="2025-12-01T16:02:17.673Z")
@Stability(Stable)
public class CfnRule
extends CfnResource
implements IInspectable, IRuleRef, ITaggable
Creates a rule for the specified Amazon Connect instance.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.connect.*;
Object assignContactCategoryActions;
Object emptyValue;
Object endAssociatedTasksActions;
CfnRule cfnRule = CfnRule.Builder.create(this, "MyCfnRule")
.actions(ActionsProperty.builder()
.assignContactCategoryActions(List.of(assignContactCategoryActions))
.createCaseActions(List.of(CreateCaseActionProperty.builder()
.fields(List.of(FieldProperty.builder()
.id("id")
.value(FieldValueProperty.builder()
.booleanValue(false)
.doubleValue(123)
.emptyValue(emptyValue)
.stringValue("stringValue")
.build())
.build()))
.templateId("templateId")
.build()))
.endAssociatedTasksActions(List.of(endAssociatedTasksActions))
.eventBridgeActions(List.of(EventBridgeActionProperty.builder()
.name("name")
.build()))
.sendNotificationActions(List.of(SendNotificationActionProperty.builder()
.content("content")
.contentType("contentType")
.deliveryMethod("deliveryMethod")
.recipient(NotificationRecipientTypeProperty.builder()
.userArns(List.of("userArns"))
.userTags(Map.of(
"userTagsKey", "userTags"))
.build())
// the properties below are optional
.subject("subject")
.build()))
.submitAutoEvaluationActions(List.of(SubmitAutoEvaluationActionProperty.builder()
.evaluationFormArn("evaluationFormArn")
.build()))
.taskActions(List.of(TaskActionProperty.builder()
.contactFlowArn("contactFlowArn")
.name("name")
// the properties below are optional
.description("description")
.references(Map.of(
"referencesKey", ReferenceProperty.builder()
.type("type")
.value("value")
.build()))
.build()))
.updateCaseActions(List.of(UpdateCaseActionProperty.builder()
.fields(List.of(FieldProperty.builder()
.id("id")
.value(FieldValueProperty.builder()
.booleanValue(false)
.doubleValue(123)
.emptyValue(emptyValue)
.stringValue("stringValue")
.build())
.build()))
.build()))
.build())
.function("function")
.instanceArn("instanceArn")
.name("name")
.publishStatus("publishStatus")
.triggerEventSource(RuleTriggerEventSourceProperty.builder()
.eventSourceName("eventSourceName")
// the properties below are optional
.integrationAssociationArn("integrationAssociationArn")
.build())
// the properties below are optional
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceA list of actions to be run when the rule is triggered.static final classA fluent builder forCfnRule.static interfaceExample:static interfaceThe EventBridge action definition.static interfaceExample:static interfaceObject for case field values.static interfaceThe type of notification recipient.static interfaceInformation about the reference when thereferenceTypeisURL.static interfaceThe name of the event source.static interfaceInformation about the send notification action.static interfaceExample:static interfaceInformation about the task action.static interfaceExample:Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.interfaces.connect.IRuleRef
IRuleRef.Jsii$Default, IRuleRef.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnRule(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnRule(software.amazon.jsii.JsiiObjectRef objRef) CfnRule(software.constructs.Construct scope, String id, CfnRuleProps props) Create a newAWS::Connect::Rule. -
Method Summary
Modifier and TypeMethodDescriptionstatic StringarnForRule(IRuleRef resource) A list of actions to be run when the rule is triggered.The Amazon Resource Name (ARN) of the rule.The conditions of the rule.The Amazon Resource Name (ARN) of the instance.getName()The name of the rule.The publish status of the rule.A reference to a Rule resource.getTags()Tag Manager which manages the tags for this resource.The tags used to organize, track, or control access for this resource.The event source to trigger the rule.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.static BooleanChecks whether the given object is a CfnRule.renderProperties(Map<String, Object> props) voidsetActions(IResolvable value) A list of actions to be run when the rule is triggered.voidA list of actions to be run when the rule is triggered.voidsetFunction(String value) The conditions of the rule.voidsetInstanceArn(String value) The Amazon Resource Name (ARN) of the instance.voidThe name of the rule.voidsetPublishStatus(String value) The publish status of the rule.voidsetTagsRaw(List<CfnTag> value) The tags used to organize, track, or control access for this resource.voidsetTriggerEventSource(IResolvable value) The event source to trigger the rule.voidThe event source to trigger the rule.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.interfaces.IEnvironmentAware
getEnvMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnRule
protected CfnRule(software.amazon.jsii.JsiiObjectRef objRef) -
CfnRule
protected CfnRule(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnRule
@Stability(Stable) public CfnRule(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnRuleProps props) Create a newAWS::Connect::Rule.- Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
arnForRule
- Parameters:
resource- This parameter is required.
-
isCfnRule
Checks whether the given object is a CfnRule.- Parameters:
x- This parameter is required.
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrRuleArn
The Amazon Resource Name (ARN) of the rule. -
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getRuleRef
A reference to a Rule resource.- Specified by:
getRuleRefin interfaceIRuleRef
-
getTags
Tag Manager which manages the tags for this resource. -
getActions
A list of actions to be run when the rule is triggered.Returns union: either
IResolvableorCfnRule.ActionsProperty -
setActions
A list of actions to be run when the rule is triggered. -
setActions
A list of actions to be run when the rule is triggered. -
getFunction
The conditions of the rule. -
setFunction
The conditions of the rule. -
getInstanceArn
The Amazon Resource Name (ARN) of the instance. -
setInstanceArn
The Amazon Resource Name (ARN) of the instance. -
getName
The name of the rule. -
setName
The name of the rule. -
getPublishStatus
The publish status of the rule. -
setPublishStatus
The publish status of the rule. -
getTriggerEventSource
The event source to trigger the rule.Returns union: either
IResolvableorCfnRule.RuleTriggerEventSourceProperty -
setTriggerEventSource
The event source to trigger the rule. -
setTriggerEventSource
@Stability(Stable) public void setTriggerEventSource(@NotNull CfnRule.RuleTriggerEventSourceProperty value) The event source to trigger the rule. -
getTagsRaw
The tags used to organize, track, or control access for this resource. -
setTagsRaw
The tags used to organize, track, or control access for this resource.
-