

This is the new *CloudFormation Template Reference Guide*. Please update your bookmarks and links. For help getting started with CloudFormation, see the [AWS CloudFormation User Guide](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/Welcome.html).

# AWS::Cases::Template
<a name="aws-resource-cases-template"></a>

Creates a template in the Cases domain. This template is used to define the case object model (that is, to define what data can be captured on cases) in a Cases domain. A template must have a unique name within a domain, and it must reference existing field IDs and layout IDs. Additionally, multiple fields with same IDs are not allowed within the same Template. A template can be either Active or Inactive, as indicated by its status. Inactive templates cannot be used to create cases.

 Other template APIs are: 
+  [DeleteTemplate](https://docs.aws.amazon.com/connect/latest/APIReference/API_connect-cases_DeleteTemplate.html) 
+  [GetTemplate](https://docs.aws.amazon.com/connect/latest/APIReference/API_connect-cases_GetTemplate.html) 
+  [ListTemplates](https://docs.aws.amazon.com/connect/latest/APIReference/API_connect-cases_ListTemplates.html) 
+  [UpdateTemplate](https://docs.aws.amazon.com/connect/latest/APIReference/API_connect-cases_UpdateTemplate.html) 

## Syntax
<a name="aws-resource-cases-template-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-resource-cases-template-syntax.json"></a>

```
{
  "Type" : "AWS::Cases::Template",
  "Properties" : {
      "[Description](#cfn-cases-template-description)" : String,
      "[DomainId](#cfn-cases-template-domainid)" : String,
      "[LayoutConfiguration](#cfn-cases-template-layoutconfiguration)" : LayoutConfiguration,
      "[Name](#cfn-cases-template-name)" : String,
      "[RequiredFields](#cfn-cases-template-requiredfields)" : [ RequiredField, ... ],
      "[Rules](#cfn-cases-template-rules)" : [ TemplateRule, ... ],
      "[Status](#cfn-cases-template-status)" : String,
      "[Tags](#cfn-cases-template-tags)" : [ Tag, ... ]
    }
}
```

### YAML
<a name="aws-resource-cases-template-syntax.yaml"></a>

```
Type: AWS::Cases::Template
Properties:
  [Description](#cfn-cases-template-description): String
  [DomainId](#cfn-cases-template-domainid): String
  [LayoutConfiguration](#cfn-cases-template-layoutconfiguration): 
    LayoutConfiguration
  [Name](#cfn-cases-template-name): String
  [RequiredFields](#cfn-cases-template-requiredfields): 
    - RequiredField
  [Rules](#cfn-cases-template-rules): 
    - TemplateRule
  [Status](#cfn-cases-template-status): String
  [Tags](#cfn-cases-template-tags): 
    - Tag
```

## Properties
<a name="aws-resource-cases-template-properties"></a>

`Description`  <a name="cfn-cases-template-description"></a>
A brief description of the template.  
*Required*: No  
*Type*: String  
*Maximum*: `255`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`DomainId`  <a name="cfn-cases-template-domainid"></a>
The unique identifier of the Cases domain.   
*Required*: No  
*Type*: String  
*Minimum*: `1`  
*Maximum*: `500`  
*Update requires*: Updates are not supported.

`LayoutConfiguration`  <a name="cfn-cases-template-layoutconfiguration"></a>
Object to store configuration of layouts associated to the template.  
*Required*: No  
*Type*: [LayoutConfiguration](aws-properties-cases-template-layoutconfiguration.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Name`  <a name="cfn-cases-template-name"></a>
The template name.  
*Required*: Yes  
*Type*: String  
*Pattern*: `^.*[\S]$`  
*Minimum*: `1`  
*Maximum*: `100`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`RequiredFields`  <a name="cfn-cases-template-requiredfields"></a>
A list of fields that must contain a value for a case to be successfully created with this template.  
*Required*: No  
*Type*: Array of [RequiredField](aws-properties-cases-template-requiredfield.md)  
*Maximum*: `100`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Rules`  <a name="cfn-cases-template-rules"></a>
A list of case rules (also known as [case field conditions](https://docs.aws.amazon.com/connect/latest/adminguide/case-field-conditions.html)) on a template.   
*Required*: No  
*Type*: Array of [TemplateRule](aws-properties-cases-template-templaterule.md)  
*Maximum*: `50`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Status`  <a name="cfn-cases-template-status"></a>
The status of the template.  
*Required*: No  
*Type*: String  
*Allowed values*: `Active | Inactive`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Tags`  <a name="cfn-cases-template-tags"></a>
An array of key-value pairs to apply to this resource.  
*Required*: No  
*Type*: Array of [Tag](aws-properties-cases-template-tag.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

## Return values
<a name="aws-resource-cases-template-return-values"></a>

### Ref
<a name="aws-resource-cases-template-return-values-ref"></a>

When you pass the logical ID of this resource to the intrinsic `Ref` function, `Ref` returns the ARN of the template. For example:

 `arn:aws:cases:us-west-2:123456789012:domain/a1b2c3d4-5678-90ab-cdef-EXAMPLE11111/template/a1b2c3d4-5678-90ab-cdef-EXAMPLE55555` 

For more information about using the `Ref` function, see [https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-ref.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-ref.html).

### Fn::GetAtt
<a name="aws-resource-cases-template-return-values-fn--getatt"></a>

The `Fn::GetAtt` intrinsic function returns a value for a specified attribute of this type. The following are the available attributes and sample return values.

For more information about using the `Fn::GetAtt` intrinsic function, see [https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-getatt.html](https://docs.aws.amazon.com/AWSCloudFormation/latest/TemplateReference/intrinsic-function-reference-getatt.html).

#### 
<a name="aws-resource-cases-template-return-values-fn--getatt-fn--getatt"></a>

`CreatedTime`  <a name="CreatedTime-fn::getatt"></a>
Timestamp at which the resource was created.

`LastModifiedTime`  <a name="LastModifiedTime-fn::getatt"></a>
Timestamp at which the resource was created or last modified.

`TemplateArn`  <a name="TemplateArn-fn::getatt"></a>
The Amazon Resource Name (ARN) of the template.

`TemplateId`  <a name="TemplateId-fn::getatt"></a>
A unique identifier of a template.

# AWS::Cases::Template LayoutConfiguration
<a name="aws-properties-cases-template-layoutconfiguration"></a>

Object to store configuration of layouts associated to the template.

## Syntax
<a name="aws-properties-cases-template-layoutconfiguration-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-cases-template-layoutconfiguration-syntax.json"></a>

```
{
  "[DefaultLayout](#cfn-cases-template-layoutconfiguration-defaultlayout)" : String
}
```

### YAML
<a name="aws-properties-cases-template-layoutconfiguration-syntax.yaml"></a>

```
  [DefaultLayout](#cfn-cases-template-layoutconfiguration-defaultlayout): String
```

## Properties
<a name="aws-properties-cases-template-layoutconfiguration-properties"></a>

`DefaultLayout`  <a name="cfn-cases-template-layoutconfiguration-defaultlayout"></a>
 Unique identifier of a layout.   
*Required*: No  
*Type*: String  
*Minimum*: `1`  
*Maximum*: `500`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::Cases::Template RequiredField
<a name="aws-properties-cases-template-requiredfield"></a>

List of fields that must have a value provided to create a case.

## Syntax
<a name="aws-properties-cases-template-requiredfield-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-cases-template-requiredfield-syntax.json"></a>

```
{
  "[FieldId](#cfn-cases-template-requiredfield-fieldid)" : String
}
```

### YAML
<a name="aws-properties-cases-template-requiredfield-syntax.yaml"></a>

```
  [FieldId](#cfn-cases-template-requiredfield-fieldid): String
```

## Properties
<a name="aws-properties-cases-template-requiredfield-properties"></a>

`FieldId`  <a name="cfn-cases-template-requiredfield-fieldid"></a>
Unique identifier of a field.  
*Required*: Yes  
*Type*: String  
*Minimum*: `1`  
*Maximum*: `500`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::Cases::Template Tag
<a name="aws-properties-cases-template-tag"></a>

A key-value pair to associate with a resource.

## Syntax
<a name="aws-properties-cases-template-tag-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-cases-template-tag-syntax.json"></a>

```
{
  "[Key](#cfn-cases-template-tag-key)" : String,
  "[Value](#cfn-cases-template-tag-value)" : String
}
```

### YAML
<a name="aws-properties-cases-template-tag-syntax.yaml"></a>

```
  [Key](#cfn-cases-template-tag-key): String
  [Value](#cfn-cases-template-tag-value): String
```

## Properties
<a name="aws-properties-cases-template-tag-properties"></a>

`Key`  <a name="cfn-cases-template-tag-key"></a>
The key name of the tag. You can specify a value that's 1 to 128 Unicode characters in length and can't be prefixed with `aws:`. You can use any of the following characters: the set of Unicode letters, digits, whitespace, `_`, `.`, `:`, `/`, `=`, `+`, `@`, `-`, and `"`.  
For more information, see [Tag](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html).  
*Required*: Yes  
*Type*: String  
*Pattern*: `^(?!aws:)[a-zA-Z+-=._:/]+$`  
*Minimum*: `1`  
*Maximum*: `128`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Value`  <a name="cfn-cases-template-tag-value"></a>
The value for the tag. You can specify a value that's 1 to 256 characters in length.  
For more information, see [Tag](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html).  
*Required*: Yes  
*Type*: String  
*Minimum*: `0`  
*Maximum*: `256`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::Cases::Template TemplateRule
<a name="aws-properties-cases-template-templaterule"></a>

An association representing a case rule acting upon a field. In the Amazon Connect admin website, case rules are known as *case field conditions*. For more information about case field conditions, see [Add case field conditions to a case template](https://docs.aws.amazon.com/connect/latest/adminguide/case-field-conditions.html).

## Syntax
<a name="aws-properties-cases-template-templaterule-syntax"></a>

To declare this entity in your CloudFormation template, use the following syntax:

### JSON
<a name="aws-properties-cases-template-templaterule-syntax.json"></a>

```
{
  "[CaseRuleId](#cfn-cases-template-templaterule-caseruleid)" : String,
  "[FieldId](#cfn-cases-template-templaterule-fieldid)" : String
}
```

### YAML
<a name="aws-properties-cases-template-templaterule-syntax.yaml"></a>

```
  [CaseRuleId](#cfn-cases-template-templaterule-caseruleid): String
  [FieldId](#cfn-cases-template-templaterule-fieldid): String
```

## Properties
<a name="aws-properties-cases-template-templaterule-properties"></a>

`CaseRuleId`  <a name="cfn-cases-template-templaterule-caseruleid"></a>
Unique identifier of a case rule.  
*Required*: Yes  
*Type*: String  
*Minimum*: `1`  
*Maximum*: `500`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`FieldId`  <a name="cfn-cases-template-templaterule-fieldid"></a>
Unique identifier of a field.  
*Required*: No  
*Type*: String  
*Minimum*: `1`  
*Maximum*: `500`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)