

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::SageMaker::Endpoint
<a name="aws-resource-sagemaker-endpoint"></a>

Use the `AWS::SageMaker::Endpoint` resource to create an endpoint using the specified configuration in the request. Amazon SageMaker uses the endpoint to provision resources and deploy models. You create the endpoint configuration with the [AWS::SageMaker::EndpointConfig](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-sagemaker-endpointconfig.html) resource. For more information, see [Deploy a Model on Amazon SageMaker Hosting Services](https://docs.aws.amazon.com/sagemaker/latest/dg/how-it-works-hosting.html) in the *Amazon SageMaker Developer Guide*.

## Syntax
<a name="aws-resource-sagemaker-endpoint-syntax"></a>

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

### JSON
<a name="aws-resource-sagemaker-endpoint-syntax.json"></a>

```
{
  "Type" : "AWS::SageMaker::Endpoint",
  "Properties" : {
      "[DeploymentConfig](#cfn-sagemaker-endpoint-deploymentconfig)" : DeploymentConfig,
      "[EndpointConfigName](#cfn-sagemaker-endpoint-endpointconfigname)" : String,
      "[EndpointName](#cfn-sagemaker-endpoint-endpointname)" : String,
      "[ExcludeRetainedVariantProperties](#cfn-sagemaker-endpoint-excluderetainedvariantproperties)" : [ VariantProperty, ... ],
      "[RetainAllVariantProperties](#cfn-sagemaker-endpoint-retainallvariantproperties)" : Boolean,
      "[RetainDeploymentConfig](#cfn-sagemaker-endpoint-retaindeploymentconfig)" : Boolean,
      "[Tags](#cfn-sagemaker-endpoint-tags)" : [ Tag, ... ]
    }
}
```

### YAML
<a name="aws-resource-sagemaker-endpoint-syntax.yaml"></a>

```
Type: AWS::SageMaker::Endpoint
Properties:
  [DeploymentConfig](#cfn-sagemaker-endpoint-deploymentconfig): 
    DeploymentConfig
  [EndpointConfigName](#cfn-sagemaker-endpoint-endpointconfigname): String
  [EndpointName](#cfn-sagemaker-endpoint-endpointname): String
  [ExcludeRetainedVariantProperties](#cfn-sagemaker-endpoint-excluderetainedvariantproperties): 
    - VariantProperty
  [RetainAllVariantProperties](#cfn-sagemaker-endpoint-retainallvariantproperties): Boolean
  [RetainDeploymentConfig](#cfn-sagemaker-endpoint-retaindeploymentconfig): Boolean
  [Tags](#cfn-sagemaker-endpoint-tags): 
    - Tag
```

## Properties
<a name="aws-resource-sagemaker-endpoint-properties"></a>

`DeploymentConfig`  <a name="cfn-sagemaker-endpoint-deploymentconfig"></a>
The deployment configuration for an endpoint, which contains the desired deployment strategy and rollback configurations.  
*Required*: No  
*Type*: [DeploymentConfig](aws-properties-sagemaker-endpoint-deploymentconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`EndpointConfigName`  <a name="cfn-sagemaker-endpoint-endpointconfigname"></a>
The name of the [AWS::SageMaker::EndpointConfig](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-sagemaker-endpointconfig.html) resource that specifies the configuration for the endpoint. For more information, see [CreateEndpointConfig](https://docs.aws.amazon.com/sagemaker/latest/dg/API_CreateEndpointConfig.html).   
*Required*: Yes  
*Type*: String  
*Pattern*: `[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}`  
*Minimum*: `0`  
*Maximum*: `63`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`EndpointName`  <a name="cfn-sagemaker-endpoint-endpointname"></a>
The name of the endpoint. The name must be unique within an AWS Region in your AWS account. The name is case-insensitive in `CreateEndpoint`, but the case is preserved and must be matched in [https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_runtime_InvokeEndpoint.html](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_runtime_InvokeEndpoint.html).  
*Required*: No  
*Type*: String  
*Pattern*: `[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}`  
*Minimum*: `0`  
*Maximum*: `63`  
*Update requires*: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement)

`ExcludeRetainedVariantProperties`  <a name="cfn-sagemaker-endpoint-excluderetainedvariantproperties"></a>
When you are updating endpoint resources with [RetainAllVariantProperties](https://docs.aws.amazon.com/sagemaker/latest/dg/API_UpdateEndpoint.html#SageMaker-UpdateEndpoint-request-RetainAllVariantProperties) whose value is set to `true`, `ExcludeRetainedVariantProperties` specifies the list of type [VariantProperty](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-sagemaker-endpoint-variantproperty.html) to override with the values provided by `EndpointConfig`. If you don't specify a value for `ExcludeAllVariantProperties`, no variant properties are overridden. Don't use this property when creating new endpoint resources or when `RetainAllVariantProperties` is set to `false`.   
*Required*: No  
*Type*: Array of [VariantProperty](aws-properties-sagemaker-endpoint-variantproperty.md)  
*Minimum*: `0`  
*Maximum*: `3`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`RetainAllVariantProperties`  <a name="cfn-sagemaker-endpoint-retainallvariantproperties"></a>
When updating endpoint resources, enables or disables the retention of variant properties, such as the instance count or the variant weight. To retain the variant properties of an endpoint when updating it, set `RetainAllVariantProperties` to `true`. To use the variant properties specified in a new `EndpointConfig` call when updating an endpoint, set `RetainAllVariantProperties` to `false`. Use this property only when updating endpoint resources, not when creating new endpoint resources.  
*Required*: No  
*Type*: Boolean  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`RetainDeploymentConfig`  <a name="cfn-sagemaker-endpoint-retaindeploymentconfig"></a>
Specifies whether to reuse the last deployment configuration. The default value is false (the configuration is not reused).  
*Required*: No  
*Type*: Boolean  
*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-sagemaker-endpoint-tags"></a>
A list of key-value pairs to apply to this resource.  
For more information, see [Resource Tag](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html) and [Using Cost Allocation Tags](https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/cost-alloc-tags.html#allocation-what) in the *AWS Billing and Cost Management User Guide*.  
*Required*: No  
*Type*: Array of [Tag](aws-properties-sagemaker-endpoint-tag.md)  
*Minimum*: `0`  
*Maximum*: `50`  
*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-sagemaker-endpoint-return-values"></a>

### Ref
<a name="aws-resource-sagemaker-endpoint-return-values-ref"></a>

When you pass the logical ID of this resource to the intrinsic `Ref` function, `Ref` returns the Amazon Resource Name (ARN) of the endpoint, such as `arn:aws:sagemaker:us-west-2:012345678901:endpoint/myendpoint`.

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-sagemaker-endpoint-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-sagemaker-endpoint-return-values-fn--getatt-fn--getatt"></a>

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

`EndpointName`  <a name="EndpointName-fn::getatt"></a>
The name of the endpoint, such as `MyEndpoint`. 

## Examples
<a name="aws-resource-sagemaker-endpoint--examples"></a>

### SageMaker Endpoint Example
<a name="aws-resource-sagemaker-endpoint--examples--SageMaker_Endpoint_Example"></a>

The following example creates an endpoint configuration from a trained model, and then creates an endpoint.

#### JSON
<a name="aws-resource-sagemaker-endpoint--examples--SageMaker_Endpoint_Example--json"></a>

```
{
  "Description": "Basic Hosting entities test.  We need models to create endpoint configs.",
  "Mappings": {
    "RegionMap": {
      "us-west-2": {
        "NullTransformer": "12345678901.dkr.ecr.us-west-2.amazonaws.com/mymodel:latest"
      },
      "us-east-2": {
        "NullTransformer": "12345678901.dkr.ecr.us-east-2.amazonaws.com/mymodel:latest"
      },
      "us-east-1": {
        "NullTransformer": "12345678901.dkr.ecr.us-east-1.amazonaws.com/mymodel:latest"
      },
      "eu-west-1": {
        "NullTransformer": "12345678901.dkr.ecr.eu-west-1.amazonaws.com/mymodel:latest"
      },
      "ap-northeast-1": {
        "NullTransformer": "12345678901.dkr.ecr.ap-northeast-1.amazonaws.com/mymodel:latest"
      },
      "ap-northeast-2": {
        "NullTransformer": "12345678901.dkr.ecr.ap-northeast-2.amazonaws.com/mymodel:latest"
      },
      "ap-southeast-2": {
        "NullTransformer": "12345678901.dkr.ecr.ap-southeast-2.amazonaws.com/mymodel:latest"
      },
      "eu-central-1": {
        "NullTransformer": "12345678901.dkr.ecr.eu-central-1.amazonaws.com/mymodel:latest"
      }
    }
  },
  "Resources": {
    "Endpoint": {
      "Type": "AWS::SageMaker::Endpoint",
      "Properties": {
        "EndpointConfigName": { "Fn::GetAtt" : ["EndpointConfig", "EndpointConfigName" ] }
      }
    },
    "EndpointConfig": {
      "Type": "AWS::SageMaker::EndpointConfig",
      "Properties": {
        "ProductionVariants": [
          {
            "InitialInstanceCount": 1,
            "InitialVariantWeight": 1,
            "InstanceType": "ml.t2.large",
            "ModelName": { "Fn::GetAtt" : ["Model", "ModelName" ] },
            "VariantName": { "Fn::GetAtt" : ["Model", "ModelName" ] }
          }
        ]
      }
    },
    "Model": {
      "Type": "AWS::SageMaker::Model",
      "Properties": {
        "PrimaryContainer": {
          "Image": { "Fn::FindInMap" : [ "AWS::Region", "NullTransformer"] }
        },
        "ExecutionRoleArn": { "Fn::GetAtt" : [ "ExecutionRole", "Arn" ] }
      }
    },
    "ExecutionRole": {
      "Type": "AWS::IAM::Role",
      "Properties": {
        "AssumeRolePolicyDocument": {
          "Version": "2012-10-17"		 	 	 ,
          "Statement": [
            {
              "Effect": "Allow",
              "Principal": {
                "Service": [
                  "sagemaker.amazonaws.com"
                ]
              },
              "Action": [
                "sts:AssumeRole"
              ]
            }
          ]
        },
        "Path": "/",
        "Policies": [
          {
            "PolicyName": "root",
            "PolicyDocument": {
              "Version": "2012-10-17"		 	 	 ,
              "Statement": [
                {
                  "Effect": "Allow",
                  "Action": "*",
                  "Resource": "*"
                }
              ]
            }
          }
        ]
      }
    }
  },
  "Outputs": {
    "EndpointId": {
      "Value": { "Ref" : "Endpoint" }
    },
    "EndpointName": {
      "Value": { "Fn::GetAtt" : [ "Endpoint", "EndpointName" ] }
    }
    
  }
  
}
```

#### YAML
<a name="aws-resource-sagemaker-endpoint--examples--SageMaker_Endpoint_Example--yaml"></a>

```
Description: "Basic Hosting entities test.  We need models to create endpoint configs."
Mappings: 
  RegionMap: 
    "us-west-2":
      "NullTransformer": "123456789012.dkr.ecr.us-west-2.amazonaws.com/mymodel:latest"
    "us-east-2":
      "NullTransformer": "123456789012.dkr.ecr.us-east-2.amazonaws.com/mymodel:latest"
    "us-east-1":
      "NullTransformer": "123456789012.dkr.ecr.us-east-1.amazonaws.com/mymodel:latest"
    "eu-west-1":
      "NullTransformer": "123456789012.dkr.ecr.eu-west-1.amazonaws.com/mymodel:latest"
    "ap-northeast-1":
      "NullTransformer": "123456789012.dkr.ecr.ap-northeast-1.amazonaws.com/mymodel:latest"
    "ap-northeast-2":
      "NullTransformer": "123456789012.dkr.ecr.ap-northeast-2.amazonaws.com/mymodel:latest"
    "ap-southeast-2":
      "NullTransformer": "123456789012.dkr.ecr.ap-southeast-2.amazonaws.com/mymodel:latest"
    "eu-central-1":
      "NullTransformer": "123456789012.dkr.ecr.eu-central-1.amazonaws.com/mymodel:latest"
Resources:
  Endpoint:
    Type: "AWS::SageMaker::Endpoint"
    Properties:
      EndpointConfigName:
        !GetAtt EndpointConfig.EndpointConfigName
  EndpointConfig:
    Type: "AWS::SageMaker::EndpointConfig"
    Properties:
      ProductionVariants:
        - InitialInstanceCount: 1
          InitialVariantWeight: 1.0
          InstanceType: ml.t2.large
          ModelName: !GetAtt Model.ModelName
          VariantName: !GetAtt Model.ModelName
  Model:
    Type: "AWS::SageMaker::Model"
    Properties:
      PrimaryContainer:
        Image: !FindInMap [RegionMap, !Ref "AWS::Region", "NullTransformer"]
      ExecutionRoleArn: !GetAtt ExecutionRole.Arn

  ExecutionRole: 
    Type: "AWS::IAM::Role"
    Properties: 
      AssumeRolePolicyDocument: 
        Version: "2012-10-17"
        Statement: 
          - 
            Effect: "Allow"
            Principal: 
              Service: 
                - "sagemaker.amazonaws.com"
            Action: 
              - "sts:AssumeRole"
      Path: "/"
      Policies: 
        - 
          PolicyName: "root"
          PolicyDocument: 
            Version: "2012-10-17"
            Statement: 
              - 
                Effect: "Allow"
                Action: "*"
                Resource: "*"
Outputs:
  EndpointId:
    Value: !Ref Endpoint
  EndpointName:
    Value: !GetAtt Endpoint.EndpointName
```

# AWS::SageMaker::Endpoint Alarm
<a name="aws-properties-sagemaker-endpoint-alarm"></a>

An Amazon CloudWatch alarm configured to monitor metrics on an endpoint.

## Syntax
<a name="aws-properties-sagemaker-endpoint-alarm-syntax"></a>

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

### JSON
<a name="aws-properties-sagemaker-endpoint-alarm-syntax.json"></a>

```
{
  "[AlarmName](#cfn-sagemaker-endpoint-alarm-alarmname)" : String
}
```

### YAML
<a name="aws-properties-sagemaker-endpoint-alarm-syntax.yaml"></a>

```
  [AlarmName](#cfn-sagemaker-endpoint-alarm-alarmname): String
```

## Properties
<a name="aws-properties-sagemaker-endpoint-alarm-properties"></a>

`AlarmName`  <a name="cfn-sagemaker-endpoint-alarm-alarmname"></a>
The name of a CloudWatch alarm in your account.  
*Required*: Yes  
*Type*: String  
*Pattern*: `(?!\s*$).+`  
*Minimum*: `1`  
*Maximum*: `255`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::SageMaker::Endpoint AutoRollbackConfig
<a name="aws-properties-sagemaker-endpoint-autorollbackconfig"></a>

Automatic rollback configuration for handling endpoint deployment failures and recovery.

## Syntax
<a name="aws-properties-sagemaker-endpoint-autorollbackconfig-syntax"></a>

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

### JSON
<a name="aws-properties-sagemaker-endpoint-autorollbackconfig-syntax.json"></a>

```
{
  "[Alarms](#cfn-sagemaker-endpoint-autorollbackconfig-alarms)" : [ Alarm, ... ]
}
```

### YAML
<a name="aws-properties-sagemaker-endpoint-autorollbackconfig-syntax.yaml"></a>

```
  [Alarms](#cfn-sagemaker-endpoint-autorollbackconfig-alarms): 
    - Alarm
```

## Properties
<a name="aws-properties-sagemaker-endpoint-autorollbackconfig-properties"></a>

`Alarms`  <a name="cfn-sagemaker-endpoint-autorollbackconfig-alarms"></a>
List of CloudWatch alarms in your account that are configured to monitor metrics on an endpoint. If any alarms are tripped during a deployment, SageMaker rolls back the deployment.  
*Required*: Yes  
*Type*: Array of [Alarm](aws-properties-sagemaker-endpoint-alarm.md)  
*Minimum*: `1`  
*Maximum*: `10`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::SageMaker::Endpoint BlueGreenUpdatePolicy
<a name="aws-properties-sagemaker-endpoint-bluegreenupdatepolicy"></a>

Update policy for a blue/green deployment. If this update policy is specified, SageMaker creates a new fleet during the deployment while maintaining the old fleet. SageMaker flips traffic to the new fleet according to the specified traffic routing configuration. Only one update policy should be used in the deployment configuration. If no update policy is specified, SageMaker uses a blue/green deployment strategy with all at once traffic shifting by default.

## Syntax
<a name="aws-properties-sagemaker-endpoint-bluegreenupdatepolicy-syntax"></a>

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

### JSON
<a name="aws-properties-sagemaker-endpoint-bluegreenupdatepolicy-syntax.json"></a>

```
{
  "[MaximumExecutionTimeoutInSeconds](#cfn-sagemaker-endpoint-bluegreenupdatepolicy-maximumexecutiontimeoutinseconds)" : Integer,
  "[TerminationWaitInSeconds](#cfn-sagemaker-endpoint-bluegreenupdatepolicy-terminationwaitinseconds)" : Integer,
  "[TrafficRoutingConfiguration](#cfn-sagemaker-endpoint-bluegreenupdatepolicy-trafficroutingconfiguration)" : TrafficRoutingConfig
}
```

### YAML
<a name="aws-properties-sagemaker-endpoint-bluegreenupdatepolicy-syntax.yaml"></a>

```
  [MaximumExecutionTimeoutInSeconds](#cfn-sagemaker-endpoint-bluegreenupdatepolicy-maximumexecutiontimeoutinseconds): Integer
  [TerminationWaitInSeconds](#cfn-sagemaker-endpoint-bluegreenupdatepolicy-terminationwaitinseconds): Integer
  [TrafficRoutingConfiguration](#cfn-sagemaker-endpoint-bluegreenupdatepolicy-trafficroutingconfiguration): 
    TrafficRoutingConfig
```

## Properties
<a name="aws-properties-sagemaker-endpoint-bluegreenupdatepolicy-properties"></a>

`MaximumExecutionTimeoutInSeconds`  <a name="cfn-sagemaker-endpoint-bluegreenupdatepolicy-maximumexecutiontimeoutinseconds"></a>
Maximum execution timeout for the deployment. Note that the timeout value should be larger than the total waiting time specified in `TerminationWaitInSeconds` and `WaitIntervalInSeconds`.  
*Required*: No  
*Type*: Integer  
*Minimum*: `600`  
*Maximum*: `28800`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TerminationWaitInSeconds`  <a name="cfn-sagemaker-endpoint-bluegreenupdatepolicy-terminationwaitinseconds"></a>
Additional waiting time in seconds after the completion of an endpoint deployment before terminating the old endpoint fleet. Default is 0.  
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Maximum*: `3600`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`TrafficRoutingConfiguration`  <a name="cfn-sagemaker-endpoint-bluegreenupdatepolicy-trafficroutingconfiguration"></a>
Defines the traffic routing strategy to shift traffic from the old fleet to the new fleet during an endpoint deployment.  
*Required*: Yes  
*Type*: [TrafficRoutingConfig](aws-properties-sagemaker-endpoint-trafficroutingconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::SageMaker::Endpoint CapacitySize
<a name="aws-properties-sagemaker-endpoint-capacitysize"></a>

Specifies the type and size of the endpoint capacity to activate for a blue/green deployment, a rolling deployment, or a rollback strategy. You can specify your batches as either instance count or the overall percentage or your fleet.

For a rollback strategy, if you don't specify the fields in this object, or if you set the `Value` to 100%, then SageMaker uses a blue/green rollback strategy and rolls all traffic back to the blue fleet.

## Syntax
<a name="aws-properties-sagemaker-endpoint-capacitysize-syntax"></a>

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

### JSON
<a name="aws-properties-sagemaker-endpoint-capacitysize-syntax.json"></a>

```
{
  "[Type](#cfn-sagemaker-endpoint-capacitysize-type)" : String,
  "[Value](#cfn-sagemaker-endpoint-capacitysize-value)" : Integer
}
```

### YAML
<a name="aws-properties-sagemaker-endpoint-capacitysize-syntax.yaml"></a>

```
  [Type](#cfn-sagemaker-endpoint-capacitysize-type): String
  [Value](#cfn-sagemaker-endpoint-capacitysize-value): Integer
```

## Properties
<a name="aws-properties-sagemaker-endpoint-capacitysize-properties"></a>

`Type`  <a name="cfn-sagemaker-endpoint-capacitysize-type"></a>
Specifies the endpoint capacity type.  
+ `INSTANCE_COUNT`: The endpoint activates based on the number of instances.
+ `CAPACITY_PERCENT`: The endpoint activates based on the specified percentage of capacity.
*Required*: Yes  
*Type*: String  
*Allowed values*: `INSTANCE_COUNT | CAPACITY_PERCENT`  
*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-sagemaker-endpoint-capacitysize-value"></a>
Defines the capacity size, either as a number of instances or a capacity percentage.  
*Required*: Yes  
*Type*: Integer  
*Minimum*: `1`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::SageMaker::Endpoint DeploymentConfig
<a name="aws-properties-sagemaker-endpoint-deploymentconfig"></a>

The deployment configuration for an endpoint, which contains the desired deployment strategy and rollback configurations.

## Syntax
<a name="aws-properties-sagemaker-endpoint-deploymentconfig-syntax"></a>

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

### JSON
<a name="aws-properties-sagemaker-endpoint-deploymentconfig-syntax.json"></a>

```
{
  "[AutoRollbackConfiguration](#cfn-sagemaker-endpoint-deploymentconfig-autorollbackconfiguration)" : AutoRollbackConfig,
  "[BlueGreenUpdatePolicy](#cfn-sagemaker-endpoint-deploymentconfig-bluegreenupdatepolicy)" : BlueGreenUpdatePolicy,
  "[RollingUpdatePolicy](#cfn-sagemaker-endpoint-deploymentconfig-rollingupdatepolicy)" : RollingUpdatePolicy
}
```

### YAML
<a name="aws-properties-sagemaker-endpoint-deploymentconfig-syntax.yaml"></a>

```
  [AutoRollbackConfiguration](#cfn-sagemaker-endpoint-deploymentconfig-autorollbackconfiguration): 
    AutoRollbackConfig
  [BlueGreenUpdatePolicy](#cfn-sagemaker-endpoint-deploymentconfig-bluegreenupdatepolicy): 
    BlueGreenUpdatePolicy
  [RollingUpdatePolicy](#cfn-sagemaker-endpoint-deploymentconfig-rollingupdatepolicy): 
    RollingUpdatePolicy
```

## Properties
<a name="aws-properties-sagemaker-endpoint-deploymentconfig-properties"></a>

`AutoRollbackConfiguration`  <a name="cfn-sagemaker-endpoint-deploymentconfig-autorollbackconfiguration"></a>
Automatic rollback configuration for handling endpoint deployment failures and recovery.  
*Required*: No  
*Type*: [AutoRollbackConfig](aws-properties-sagemaker-endpoint-autorollbackconfig.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`BlueGreenUpdatePolicy`  <a name="cfn-sagemaker-endpoint-deploymentconfig-bluegreenupdatepolicy"></a>
Update policy for a blue/green deployment. If this update policy is specified, SageMaker creates a new fleet during the deployment while maintaining the old fleet. SageMaker flips traffic to the new fleet according to the specified traffic routing configuration. Only one update policy should be used in the deployment configuration. If no update policy is specified, SageMaker uses a blue/green deployment strategy with all at once traffic shifting by default.  
*Required*: No  
*Type*: [BlueGreenUpdatePolicy](aws-properties-sagemaker-endpoint-bluegreenupdatepolicy.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`RollingUpdatePolicy`  <a name="cfn-sagemaker-endpoint-deploymentconfig-rollingupdatepolicy"></a>
Specifies a rolling deployment strategy for updating a SageMaker endpoint.  
*Required*: No  
*Type*: [RollingUpdatePolicy](aws-properties-sagemaker-endpoint-rollingupdatepolicy.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::SageMaker::Endpoint RollingUpdatePolicy
<a name="aws-properties-sagemaker-endpoint-rollingupdatepolicy"></a>

Specifies a rolling deployment strategy for updating a SageMaker endpoint.

## Syntax
<a name="aws-properties-sagemaker-endpoint-rollingupdatepolicy-syntax"></a>

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

### JSON
<a name="aws-properties-sagemaker-endpoint-rollingupdatepolicy-syntax.json"></a>

```
{
  "[MaximumBatchSize](#cfn-sagemaker-endpoint-rollingupdatepolicy-maximumbatchsize)" : CapacitySize,
  "[MaximumExecutionTimeoutInSeconds](#cfn-sagemaker-endpoint-rollingupdatepolicy-maximumexecutiontimeoutinseconds)" : Integer,
  "[RollbackMaximumBatchSize](#cfn-sagemaker-endpoint-rollingupdatepolicy-rollbackmaximumbatchsize)" : CapacitySize,
  "[WaitIntervalInSeconds](#cfn-sagemaker-endpoint-rollingupdatepolicy-waitintervalinseconds)" : Integer
}
```

### YAML
<a name="aws-properties-sagemaker-endpoint-rollingupdatepolicy-syntax.yaml"></a>

```
  [MaximumBatchSize](#cfn-sagemaker-endpoint-rollingupdatepolicy-maximumbatchsize): 
    CapacitySize
  [MaximumExecutionTimeoutInSeconds](#cfn-sagemaker-endpoint-rollingupdatepolicy-maximumexecutiontimeoutinseconds): Integer
  [RollbackMaximumBatchSize](#cfn-sagemaker-endpoint-rollingupdatepolicy-rollbackmaximumbatchsize): 
    CapacitySize
  [WaitIntervalInSeconds](#cfn-sagemaker-endpoint-rollingupdatepolicy-waitintervalinseconds): Integer
```

## Properties
<a name="aws-properties-sagemaker-endpoint-rollingupdatepolicy-properties"></a>

`MaximumBatchSize`  <a name="cfn-sagemaker-endpoint-rollingupdatepolicy-maximumbatchsize"></a>
Batch size for each rolling step to provision capacity and turn on traffic on the new endpoint fleet, and terminate capacity on the old endpoint fleet. Value must be between 5% to 50% of the variant's total instance count.  
*Required*: Yes  
*Type*: [CapacitySize](aws-properties-sagemaker-endpoint-capacitysize.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`MaximumExecutionTimeoutInSeconds`  <a name="cfn-sagemaker-endpoint-rollingupdatepolicy-maximumexecutiontimeoutinseconds"></a>
The time limit for the total deployment. Exceeding this limit causes a timeout.  
*Required*: No  
*Type*: Integer  
*Minimum*: `600`  
*Maximum*: `28800`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`RollbackMaximumBatchSize`  <a name="cfn-sagemaker-endpoint-rollingupdatepolicy-rollbackmaximumbatchsize"></a>
Batch size for rollback to the old endpoint fleet. Each rolling step to provision capacity and turn on traffic on the old endpoint fleet, and terminate capacity on the new endpoint fleet. If this field is absent, the default value will be set to 100% of total capacity which means to bring up the whole capacity of the old fleet at once during rollback.  
*Required*: No  
*Type*: [CapacitySize](aws-properties-sagemaker-endpoint-capacitysize.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`WaitIntervalInSeconds`  <a name="cfn-sagemaker-endpoint-rollingupdatepolicy-waitintervalinseconds"></a>
The length of the baking period, during which SageMaker monitors alarms for each batch on the new fleet.  
*Required*: Yes  
*Type*: Integer  
*Minimum*: `0`  
*Maximum*: `3600`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::SageMaker::Endpoint Tag
<a name="aws-properties-sagemaker-endpoint-tag"></a>

A tag object that consists of a key and an optional value, used to manage metadata for SageMaker AWS resources.

You can add tags to notebook instances, training jobs, hyperparameter tuning jobs, batch transform jobs, models, labeling jobs, work teams, endpoint configurations, and endpoints. For more information on adding tags to SageMaker resources, see [AddTags](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_AddTags.html).

For more information on adding metadata to your AWS resources with tagging, see [Tagging AWS resources](https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html). For advice on best practices for managing AWS resources with tagging, see [Tagging Best Practices: Implement an Effective AWS Resource Tagging Strategy](https://d1.awsstatic.com/whitepapers/aws-tagging-best-practices.pdf).

## Syntax
<a name="aws-properties-sagemaker-endpoint-tag-syntax"></a>

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

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

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

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

```
  [Key](#cfn-sagemaker-endpoint-tag-key): String
  [Value](#cfn-sagemaker-endpoint-tag-value): String
```

## Properties
<a name="aws-properties-sagemaker-endpoint-tag-properties"></a>

`Key`  <a name="cfn-sagemaker-endpoint-tag-key"></a>
The tag key. Tag keys must be unique per resource.  
*Required*: Yes  
*Type*: String  
*Pattern*: `([\p{L}\p{Z}\p{N}_.:/=+\-@]*)`  
*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-sagemaker-endpoint-tag-value"></a>
The tag value.  
*Required*: Yes  
*Type*: String  
*Pattern*: `([\p{L}\p{Z}\p{N}_.:/=+\-@]*)`  
*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::SageMaker::Endpoint TrafficRoutingConfig
<a name="aws-properties-sagemaker-endpoint-trafficroutingconfig"></a>

Defines the traffic routing strategy during an endpoint deployment to shift traffic from the old fleet to the new fleet.

## Syntax
<a name="aws-properties-sagemaker-endpoint-trafficroutingconfig-syntax"></a>

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

### JSON
<a name="aws-properties-sagemaker-endpoint-trafficroutingconfig-syntax.json"></a>

```
{
  "[CanarySize](#cfn-sagemaker-endpoint-trafficroutingconfig-canarysize)" : CapacitySize,
  "[LinearStepSize](#cfn-sagemaker-endpoint-trafficroutingconfig-linearstepsize)" : CapacitySize,
  "[Type](#cfn-sagemaker-endpoint-trafficroutingconfig-type)" : String,
  "[WaitIntervalInSeconds](#cfn-sagemaker-endpoint-trafficroutingconfig-waitintervalinseconds)" : Integer
}
```

### YAML
<a name="aws-properties-sagemaker-endpoint-trafficroutingconfig-syntax.yaml"></a>

```
  [CanarySize](#cfn-sagemaker-endpoint-trafficroutingconfig-canarysize): 
    CapacitySize
  [LinearStepSize](#cfn-sagemaker-endpoint-trafficroutingconfig-linearstepsize): 
    CapacitySize
  [Type](#cfn-sagemaker-endpoint-trafficroutingconfig-type): String
  [WaitIntervalInSeconds](#cfn-sagemaker-endpoint-trafficroutingconfig-waitintervalinseconds): Integer
```

## Properties
<a name="aws-properties-sagemaker-endpoint-trafficroutingconfig-properties"></a>

`CanarySize`  <a name="cfn-sagemaker-endpoint-trafficroutingconfig-canarysize"></a>
Batch size for the first step to turn on traffic on the new endpoint fleet. `Value` must be less than or equal to 50% of the variant's total instance count.  
*Required*: No  
*Type*: [CapacitySize](aws-properties-sagemaker-endpoint-capacitysize.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`LinearStepSize`  <a name="cfn-sagemaker-endpoint-trafficroutingconfig-linearstepsize"></a>
Batch size for each step to turn on traffic on the new endpoint fleet. `Value` must be 10-50% of the variant's total instance count.  
*Required*: No  
*Type*: [CapacitySize](aws-properties-sagemaker-endpoint-capacitysize.md)  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`Type`  <a name="cfn-sagemaker-endpoint-trafficroutingconfig-type"></a>
Traffic routing strategy type.  
+ `ALL_AT_ONCE`: Endpoint traffic shifts to the new fleet in a single step. 
+ `CANARY`: Endpoint traffic shifts to the new fleet in two steps. The first step is the canary, which is a small portion of the traffic. The second step is the remainder of the traffic. 
+ `LINEAR`: Endpoint traffic shifts to the new fleet in n steps of a configurable size. 
*Required*: Yes  
*Type*: String  
*Allowed values*: `ALL_AT_ONCE | CANARY | LINEAR`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

`WaitIntervalInSeconds`  <a name="cfn-sagemaker-endpoint-trafficroutingconfig-waitintervalinseconds"></a>
The waiting time (in seconds) between incremental steps to turn on traffic on the new endpoint fleet.  
*Required*: No  
*Type*: Integer  
*Minimum*: `0`  
*Maximum*: `3600`  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)

# AWS::SageMaker::Endpoint VariantProperty
<a name="aws-properties-sagemaker-endpoint-variantproperty"></a>

Specifies a production variant property type for an Endpoint.

If you are updating an Endpoint with the [RetainAllVariantProperties](https://docs.aws.amazon.com/sagemaker/latest/dg/API_UpdateEndpoint.html#SageMaker-UpdateEndpoint-request-RetainAllVariantProperties) option set to `true`, the `VarientProperty` objects listed in [ExcludeRetainedVariantProperties](https://docs.aws.amazon.com/sagemaker/latest/dg/API_UpdateEndpoint.html#SageMaker-UpdateEndpoint-request-ExcludeRetainedVariantProperties) override the existing variant properties of the Endpoint.

## Syntax
<a name="aws-properties-sagemaker-endpoint-variantproperty-syntax"></a>

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

### JSON
<a name="aws-properties-sagemaker-endpoint-variantproperty-syntax.json"></a>

```
{
  "[VariantPropertyType](#cfn-sagemaker-endpoint-variantproperty-variantpropertytype)" : String
}
```

### YAML
<a name="aws-properties-sagemaker-endpoint-variantproperty-syntax.yaml"></a>

```
  [VariantPropertyType](#cfn-sagemaker-endpoint-variantproperty-variantpropertytype): String
```

## Properties
<a name="aws-properties-sagemaker-endpoint-variantproperty-properties"></a>

`VariantPropertyType`  <a name="cfn-sagemaker-endpoint-variantproperty-variantpropertytype"></a>
The type of variant property. The supported values are:  
+ `DesiredInstanceCount`: Overrides the existing variant instance counts using the [InitialInstanceCount](https://docs.aws.amazon.com/sagemaker/latest/dg/API_ProductionVariant.html#SageMaker-Type-ProductionVariant-InitialInstanceCount) values in the [ProductionVariants](https://docs.aws.amazon.com/sagemaker/latest/dg/API_CreateEndpointConfig.html#SageMaker-CreateEndpointConfig-request-ProductionVariants).
+ `DesiredWeight`: Overrides the existing variant weights using the [InitialVariantWeight](https://docs.aws.amazon.com/sagemaker/latest/dg/API_ProductionVariant.html#SageMaker-Type-ProductionVariant-InitialVariantWeight) values in the [ProductionVariants](https://docs.aws.amazon.com/sagemaker/latest/dg/API_CreateEndpointConfig.html#SageMaker-CreateEndpointConfig-request-ProductionVariants).
+ `DataCaptureConfig`: (Not currently supported.)
*Required*: No  
*Type*: String  
*Update requires*: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt)