AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Container for the parameters to the UpdateDistribution operation. Updates the configuration for a CloudFront distribution.

The update process includes getting the current distribution configuration, updating it to make your changes, and then submitting an UpdateDistribution request to make the updates.

To update a web distribution using the CloudFront API

  1. Use GetDistributionConfig to get the current configuration, including the version identifier (ETag).

  2. Update the distribution configuration that was returned in the response. Note the following important requirements and restrictions:

    • You must rename the ETag field to IfMatch, leaving the value unchanged. (Set the value of IfMatch to the value of ETag, then remove the ETag field.)

    • You can't change the value of CallerReference.

  3. Submit an UpdateDistribution request, providing the distribution configuration. The new configuration replaces the existing configuration. The values that you specify in an UpdateDistribution request are not merged into your existing configuration. Make sure to include all fields: the ones that you modified and also the ones that you didn't.

Inheritance Hierarchy

System.Object
  Amazon.Runtime.AmazonWebServiceRequest
    Amazon.CloudFront.AmazonCloudFrontRequest
      Amazon.CloudFront.Model.UpdateDistributionRequest

Namespace: Amazon.CloudFront.Model
Assembly: AWSSDK.CloudFront.dll
Version: 3.x.y.z

Syntax

C#
public class UpdateDistributionRequest : AmazonCloudFrontRequest
         IAmazonWebServiceRequest

The UpdateDistributionRequest type exposes the following members

Constructors

NameDescription
Public Method UpdateDistributionRequest()

Empty constructor used to set properties independently even when a simple constructor is available

Public Method UpdateDistributionRequest(string, string, DistributionConfig)

Instantiates UpdateDistributionRequest with the parameterized properties

Properties

NameTypeDescription
Public Property DistributionConfig Amazon.CloudFront.Model.DistributionConfig

Gets and sets the property DistributionConfig.

The distribution's configuration information.

Public Property Id System.String

Gets and sets the property Id.

The distribution's id.

Public Property IfMatch System.String

Gets and sets the property IfMatch.

The value of the ETag header that you received when retrieving the distribution's configuration. For example: E2QWRUHAPOMQZL.

Version Information

.NET Core App:
Supported in: 3.1

.NET Standard:
Supported in: 2.0

.NET Framework:
Supported in: 4.5, 4.0, 3.5