SDK for PHP 3.x

Client: Aws\CloudFront\CloudFrontClient
Service ID: cloudfront
Version: 2020-05-31

This page describes the parameters and results for the operations of the Amazon CloudFront (2020-05-31), and shows how to use the Aws\CloudFront\CloudFrontClient object to call the described operations. This documentation is specific to the 2020-05-31 API version of the service.

Operation Summary

Each of the following operations can be created from a client using $client->getCommand('CommandName'), where "CommandName" is the name of one of the following operations. Note: a command is a value that encapsulates an operation and the parameters used to create an HTTP request.

You can also create and send a command immediately using the magic methods available on a client object: $client->commandName(/* parameters */). You can send the command asynchronously (returning a promise) by appending the word "Async" to the operation name: $client->commandNameAsync(/* parameters */).

AssociateAlias ( array $params = [] )
Associates an alias (also known as a CNAME or an alternate domain name) with a CloudFront distribution.
CopyDistribution ( array $params = [] )
Creates a staging distribution using the configuration of the provided primary distribution.
CreateAnycastIpList ( array $params = [] )
Creates an Anycast static IP list.
CreateCachePolicy ( array $params = [] )
Creates a cache policy.
CreateCloudFrontOriginAccessIdentity ( array $params = [] )
Creates a new origin access identity.
CreateContinuousDeploymentPolicy ( array $params = [] )
Creates a continuous deployment policy that distributes traffic for a custom domain name to two different CloudFront distributions.
CreateDistribution ( array $params = [] )
Creates a CloudFront distribution.
CreateDistributionWithTags ( array $params = [] )
Create a new distribution with tags.
CreateFieldLevelEncryptionConfig ( array $params = [] )
Create a new field-level encryption configuration.
CreateFieldLevelEncryptionProfile ( array $params = [] )
Create a field-level encryption profile.
CreateFunction ( array $params = [] )
Creates a CloudFront function.
CreateInvalidation ( array $params = [] )
Create a new invalidation.
CreateKeyGroup ( array $params = [] )
Creates a key group that you can use with CloudFront signed URLs and signed cookies.
CreateKeyValueStore ( array $params = [] )
Specifies the key value store resource to add to your account.
CreateMonitoringSubscription ( array $params = [] )
Enables additional CloudWatch metrics for the specified CloudFront distribution.
CreateOriginAccessControl ( array $params = [] )
Creates a new origin access control in CloudFront.
CreateOriginRequestPolicy ( array $params = [] )
Creates an origin request policy.
CreatePublicKey ( array $params = [] )
Uploads a public key to CloudFront that you can use with signed URLs and signed cookies, or with field-level encryption.
CreateRealtimeLogConfig ( array $params = [] )
Creates a real-time log configuration.
CreateResponseHeadersPolicy ( array $params = [] )
Creates a response headers policy.
CreateStreamingDistribution ( array $params = [] )
This API is deprecated.
CreateStreamingDistributionWithTags ( array $params = [] )
This API is deprecated.
CreateVpcOrigin ( array $params = [] )
Create an Amazon CloudFront VPC origin.
DeleteAnycastIpList ( array $params = [] )
Deletes an Anycast static IP list.
DeleteCachePolicy ( array $params = [] )
Deletes a cache policy.
DeleteCloudFrontOriginAccessIdentity ( array $params = [] )
Delete an origin access identity.
DeleteContinuousDeploymentPolicy ( array $params = [] )
Deletes a continuous deployment policy.
DeleteDistribution ( array $params = [] )
Delete a distribution.
DeleteFieldLevelEncryptionConfig ( array $params = [] )
Remove a field-level encryption configuration.
DeleteFieldLevelEncryptionProfile ( array $params = [] )
Remove a field-level encryption profile.
DeleteFunction ( array $params = [] )
Deletes a CloudFront function.
DeleteKeyGroup ( array $params = [] )
Deletes a key group.
DeleteKeyValueStore ( array $params = [] )
Specifies the key value store to delete.
DeleteMonitoringSubscription ( array $params = [] )
Disables additional CloudWatch metrics for the specified CloudFront distribution.
DeleteOriginAccessControl ( array $params = [] )
Deletes a CloudFront origin access control.
DeleteOriginRequestPolicy ( array $params = [] )
Deletes an origin request policy.
DeletePublicKey ( array $params = [] )
Remove a public key you previously added to CloudFront.
DeleteRealtimeLogConfig ( array $params = [] )
Deletes a real-time log configuration.
DeleteResponseHeadersPolicy ( array $params = [] )
Deletes a response headers policy.
DeleteStreamingDistribution ( array $params = [] )
Delete a streaming distribution.
DeleteVpcOrigin ( array $params = [] )
Delete an Amazon CloudFront VPC origin.
DescribeFunction ( array $params = [] )
Gets configuration information and metadata about a CloudFront function, but not the function's code.
DescribeKeyValueStore ( array $params = [] )
Specifies the key value store and its configuration.
GetAnycastIpList ( array $params = [] )
Gets an Anycast static IP list.
GetCachePolicy ( array $params = [] )
Gets a cache policy, including the following metadata: The policy's identifier.
GetCachePolicyConfig ( array $params = [] )
Gets a cache policy configuration.
GetCloudFrontOriginAccessIdentity ( array $params = [] )
Get the information about an origin access identity.
GetCloudFrontOriginAccessIdentityConfig ( array $params = [] )
Get the configuration information about an origin access identity.
GetContinuousDeploymentPolicy ( array $params = [] )
Gets a continuous deployment policy, including metadata (the policy's identifier and the date and time when the policy was last modified).
GetContinuousDeploymentPolicyConfig ( array $params = [] )
Gets configuration information about a continuous deployment policy.
GetDistribution ( array $params = [] )
Get the information about a distribution.
GetDistributionConfig ( array $params = [] )
Get the configuration information about a distribution.
GetFieldLevelEncryption ( array $params = [] )
Get the field-level encryption configuration information.
GetFieldLevelEncryptionConfig ( array $params = [] )
Get the field-level encryption configuration information.
GetFieldLevelEncryptionProfile ( array $params = [] )
Get the field-level encryption profile information.
GetFieldLevelEncryptionProfileConfig ( array $params = [] )
Get the field-level encryption profile configuration information.
GetFunction ( array $params = [] )
Gets the code of a CloudFront function.
GetInvalidation ( array $params = [] )
Get the information about an invalidation.
GetKeyGroup ( array $params = [] )
Gets a key group, including the date and time when the key group was last modified.
GetKeyGroupConfig ( array $params = [] )
Gets a key group configuration.
GetMonitoringSubscription ( array $params = [] )
Gets information about whether additional CloudWatch metrics are enabled for the specified CloudFront distribution.
GetOriginAccessControl ( array $params = [] )
Gets a CloudFront origin access control, including its unique identifier.
GetOriginAccessControlConfig ( array $params = [] )
Gets a CloudFront origin access control configuration.
GetOriginRequestPolicy ( array $params = [] )
Gets an origin request policy, including the following metadata: The policy's identifier.
GetOriginRequestPolicyConfig ( array $params = [] )
Gets an origin request policy configuration.
GetPublicKey ( array $params = [] )
Gets a public key.
GetPublicKeyConfig ( array $params = [] )
Gets a public key configuration.
GetRealtimeLogConfig ( array $params = [] )
Gets a real-time log configuration.
GetResponseHeadersPolicy ( array $params = [] )
Gets a response headers policy, including metadata (the policy's identifier and the date and time when the policy was last modified).
GetResponseHeadersPolicyConfig ( array $params = [] )
Gets a response headers policy configuration.
GetStreamingDistribution ( array $params = [] )
Gets information about a specified RTMP distribution, including the distribution configuration.
GetStreamingDistributionConfig ( array $params = [] )
Get the configuration information about a streaming distribution.
GetVpcOrigin ( array $params = [] )
Get the details of an Amazon CloudFront VPC origin.
ListAnycastIpLists ( array $params = [] )
Lists your Anycast static IP lists.
ListCachePolicies ( array $params = [] )
Gets a list of cache policies.
ListCloudFrontOriginAccessIdentities ( array $params = [] )
Lists origin access identities.
ListConflictingAliases ( array $params = [] )
Gets a list of aliases (also called CNAMEs or alternate domain names) that conflict or overlap with the provided alias, and the associated CloudFront distributions and Amazon Web Services accounts for each conflicting alias.
ListContinuousDeploymentPolicies ( array $params = [] )
Gets a list of the continuous deployment policies in your Amazon Web Services account.
ListDistributions ( array $params = [] )
List CloudFront distributions.
ListDistributionsByAnycastIpListId ( array $params = [] )
Lists the distributions in your account that are associated with the specified AnycastIpListId.
ListDistributionsByCachePolicyId ( array $params = [] )
Gets a list of distribution IDs for distributions that have a cache behavior that's associated with the specified cache policy.
ListDistributionsByKeyGroup ( array $params = [] )
Gets a list of distribution IDs for distributions that have a cache behavior that references the specified key group.
ListDistributionsByOriginRequestPolicyId ( array $params = [] )
Gets a list of distribution IDs for distributions that have a cache behavior that's associated with the specified origin request policy.
ListDistributionsByRealtimeLogConfig ( array $params = [] )
Gets a list of distributions that have a cache behavior that's associated with the specified real-time log configuration.
ListDistributionsByResponseHeadersPolicyId ( array $params = [] )
Gets a list of distribution IDs for distributions that have a cache behavior that's associated with the specified response headers policy.
ListDistributionsByVpcOriginId ( array $params = [] )
List CloudFront distributions by their VPC origin ID.
ListDistributionsByWebACLId ( array $params = [] )
List the distributions that are associated with a specified WAF web ACL.
ListFieldLevelEncryptionConfigs ( array $params = [] )
List all field-level encryption configurations that have been created in CloudFront for this account.
ListFieldLevelEncryptionProfiles ( array $params = [] )
Request a list of field-level encryption profiles that have been created in CloudFront for this account.
ListFunctions ( array $params = [] )
Gets a list of all CloudFront functions in your Amazon Web Services account.
ListInvalidations ( array $params = [] )
Lists invalidation batches.
ListKeyGroups ( array $params = [] )
Gets a list of key groups.
ListKeyValueStores ( array $params = [] )
Specifies the key value stores to list.
ListOriginAccessControls ( array $params = [] )
Gets the list of CloudFront origin access controls (OACs) in this Amazon Web Services account.
ListOriginRequestPolicies ( array $params = [] )
Gets a list of origin request policies.
ListPublicKeys ( array $params = [] )
List all public keys that have been added to CloudFront for this account.
ListRealtimeLogConfigs ( array $params = [] )
Gets a list of real-time log configurations.
ListResponseHeadersPolicies ( array $params = [] )
Gets a list of response headers policies.
ListStreamingDistributions ( array $params = [] )
List streaming distributions.
ListTagsForResource ( array $params = [] )
List tags for a CloudFront resource.
ListVpcOrigins ( array $params = [] )
List the CloudFront VPC origins in your account.
PublishFunction ( array $params = [] )
Publishes a CloudFront function by copying the function code from the DEVELOPMENT stage to LIVE.
TagResource ( array $params = [] )
Add tags to a CloudFront resource.
TestFunction ( array $params = [] )
Tests a CloudFront function.
UntagResource ( array $params = [] )
Remove tags from a CloudFront resource.
UpdateCachePolicy ( array $params = [] )
Updates a cache policy configuration.
UpdateCloudFrontOriginAccessIdentity ( array $params = [] )
Update an origin access identity.
UpdateContinuousDeploymentPolicy ( array $params = [] )
Updates a continuous deployment policy.
UpdateDistribution ( array $params = [] )
Updates the configuration for a CloudFront distribution.
UpdateDistributionWithStagingConfig ( array $params = [] )
Copies the staging distribution's configuration to its corresponding primary distribution.
UpdateFieldLevelEncryptionConfig ( array $params = [] )
Update a field-level encryption configuration.
UpdateFieldLevelEncryptionProfile ( array $params = [] )
Update a field-level encryption profile.
UpdateFunction ( array $params = [] )
Updates a CloudFront function.
UpdateKeyGroup ( array $params = [] )
Updates a key group.
UpdateKeyValueStore ( array $params = [] )
Specifies the key value store to update.
UpdateOriginAccessControl ( array $params = [] )
Updates a CloudFront origin access control.
UpdateOriginRequestPolicy ( array $params = [] )
Updates an origin request policy configuration.
UpdatePublicKey ( array $params = [] )
Update public key information.
UpdateRealtimeLogConfig ( array $params = [] )
Updates a real-time log configuration.
UpdateResponseHeadersPolicy ( array $params = [] )
Updates a response headers policy.
UpdateStreamingDistribution ( array $params = [] )
Update a streaming distribution.
UpdateVpcOrigin ( array $params = [] )
Update an Amazon CloudFront VPC origin in your account.

Paginators

Paginators handle automatically iterating over paginated API results. Paginators are associated with specific API operations, and they accept the parameters that the corresponding API operation accepts. You can get a paginator from a client class using getPaginator($paginatorName, $operationParameters). This client supports the following paginators:

ListCloudFrontOriginAccessIdentities
ListDistributions
ListInvalidations
ListKeyValueStores
ListPublicKeys
ListStreamingDistributions

Waiters

Waiters allow you to poll a resource until it enters into a desired state. A waiter has a name used to describe what it does, and is associated with an API operation. When creating a waiter, you can provide the API operation parameters associated with the corresponding operation. Waiters can be accessed using the getWaiter($waiterName, $operationParameters) method of a client object. This client supports the following waiters:

Waiter name API Operation Delay Max Attempts
DistributionDeployed GetDistribution 60 35
InvalidationCompleted GetInvalidation 20 30
StreamingDistributionDeployed GetStreamingDistribution 60 25

Operations

AssociateAlias

$result = $client->associateAlias([/* ... */]);
$promise = $client->associateAliasAsync([/* ... */]);

Associates an alias (also known as a CNAME or an alternate domain name) with a CloudFront distribution.

With this operation you can move an alias that's already in use on a CloudFront distribution to a different distribution in one step. This prevents the downtime that could occur if you first remove the alias from one distribution and then separately add the alias to another distribution.

To use this operation to associate an alias with a distribution, you provide the alias and the ID of the target distribution for the alias. For more information, including how to set up the target distribution, prerequisites that you must complete, and other restrictions, see Moving an alternate domain name to a different distribution in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->associateAlias([
    'Alias' => '<string>', // REQUIRED
    'TargetDistributionId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Alias
Required: Yes
Type: string

The alias (also known as a CNAME) to add to the target distribution.

TargetDistributionId
Required: Yes
Type: string

The ID of the distribution that you're associating the alias with.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

TooManyDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

IllegalUpdate:

The update contains modifications that are not allowed.

CopyDistribution

$result = $client->copyDistribution([/* ... */]);
$promise = $client->copyDistributionAsync([/* ... */]);

Creates a staging distribution using the configuration of the provided primary distribution. A staging distribution is a copy of an existing distribution (called the primary distribution) that you can use in a continuous deployment workflow.

After you create a staging distribution, you can use UpdateDistribution to modify the staging distribution's configuration. Then you can use CreateContinuousDeploymentPolicy to incrementally move traffic to the staging distribution.

This API operation requires the following IAM permissions:

Parameter Syntax

$result = $client->copyDistribution([
    'CallerReference' => '<string>', // REQUIRED
    'Enabled' => true || false,
    'IfMatch' => '<string>',
    'PrimaryDistributionId' => '<string>', // REQUIRED
    'Staging' => true || false,
]);

Parameter Details

Members
CallerReference
Required: Yes
Type: string

A value that uniquely identifies a request to create a resource. This helps to prevent CloudFront from creating a duplicate resource if you accidentally resubmit an identical request.

Enabled
Type: boolean

A Boolean flag to specify the state of the staging distribution when it's created. When you set this value to True, the staging distribution is enabled. When you set this value to False, the staging distribution is disabled.

If you omit this field, the default value is True.

IfMatch
Type: string

The version identifier of the primary distribution whose configuration you are copying. This is the ETag value returned in the response to GetDistribution and GetDistributionConfig.

PrimaryDistributionId
Required: Yes
Type: string

The identifier of the primary distribution whose configuration you are copying. To get a distribution ID, use ListDistributions.

Staging
Type: boolean

The type of distribution that your primary distribution will be copied to. The only valid value is True, indicating that you are copying to a staging distribution.

Result Syntax

[
    'Distribution' => [
        'ARN' => '<string>',
        'ActiveTrustedKeyGroups' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'KeyGroupId' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'AliasICPRecordals' => [
            [
                'CNAME' => '<string>',
                'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
            ],
            // ...
        ],
        'DistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AnycastIpListId' => '<string>',
            'CacheBehaviors' => [
                'Items' => [
                    [
                        'AllowedMethods' => [
                            'CachedMethods' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'CachePolicyId' => '<string>',
                        'Compress' => true || false,
                        'DefaultTTL' => <integer>,
                        'FieldLevelEncryptionId' => '<string>',
                        'ForwardedValues' => [
                            'Cookies' => [
                                'Forward' => 'none|whitelist|all',
                                'WhitelistedNames' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Headers' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'QueryString' => true || false,
                            'QueryStringCacheKeys' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'FunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'FunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'GrpcConfig' => [
                            'Enabled' => true || false,
                        ],
                        'LambdaFunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'IncludeBody' => true || false,
                                    'LambdaFunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'MaxTTL' => <integer>,
                        'MinTTL' => <integer>,
                        'OriginRequestPolicyId' => '<string>',
                        'PathPattern' => '<string>',
                        'RealtimeLogConfigArn' => '<string>',
                        'ResponseHeadersPolicyId' => '<string>',
                        'SmoothStreaming' => true || false,
                        'TargetOriginId' => '<string>',
                        'TrustedKeyGroups' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'TrustedSigners' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContinuousDeploymentPolicyId' => '<string>',
            'CustomErrorResponses' => [
                'Items' => [
                    [
                        'ErrorCachingMinTTL' => <integer>,
                        'ErrorCode' => <integer>,
                        'ResponseCode' => '<string>',
                        'ResponsePagePath' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'DefaultCacheBehavior' => [
                'AllowedMethods' => [
                    'CachedMethods' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'CachePolicyId' => '<string>',
                'Compress' => true || false,
                'DefaultTTL' => <integer>,
                'FieldLevelEncryptionId' => '<string>',
                'ForwardedValues' => [
                    'Cookies' => [
                        'Forward' => 'none|whitelist|all',
                        'WhitelistedNames' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'QueryString' => true || false,
                    'QueryStringCacheKeys' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'FunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'FunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'GrpcConfig' => [
                    'Enabled' => true || false,
                ],
                'LambdaFunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'IncludeBody' => true || false,
                            'LambdaFunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'MaxTTL' => <integer>,
                'MinTTL' => <integer>,
                'OriginRequestPolicyId' => '<string>',
                'RealtimeLogConfigArn' => '<string>',
                'ResponseHeadersPolicyId' => '<string>',
                'SmoothStreaming' => true || false,
                'TargetOriginId' => '<string>',
                'TrustedKeyGroups' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'TrustedSigners' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
            ],
            'DefaultRootObject' => '<string>',
            'Enabled' => true || false,
            'HttpVersion' => 'http1.1|http2|http3|http2and3',
            'IsIPV6Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'IncludeCookies' => true || false,
                'Prefix' => '<string>',
            ],
            'OriginGroups' => [
                'Items' => [
                    [
                        'FailoverCriteria' => [
                            'StatusCodes' => [
                                'Items' => [<integer>, ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Id' => '<string>',
                        'Members' => [
                            'Items' => [
                                [
                                    'OriginId' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'SelectionCriteria' => 'default|media-quality-based',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Origins' => [
                'Items' => [
                    [
                        'ConnectionAttempts' => <integer>,
                        'ConnectionTimeout' => <integer>,
                        'CustomHeaders' => [
                            'Items' => [
                                [
                                    'HeaderName' => '<string>',
                                    'HeaderValue' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'CustomOriginConfig' => [
                            'HTTPPort' => <integer>,
                            'HTTPSPort' => <integer>,
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                            'OriginReadTimeout' => <integer>,
                            'OriginSslProtocols' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'DomainName' => '<string>',
                        'Id' => '<string>',
                        'OriginAccessControlId' => '<string>',
                        'OriginPath' => '<string>',
                        'OriginShield' => [
                            'Enabled' => true || false,
                            'OriginShieldRegion' => '<string>',
                        ],
                        'S3OriginConfig' => [
                            'OriginAccessIdentity' => '<string>',
                        ],
                        'VpcOriginConfig' => [
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginReadTimeout' => <integer>,
                            'VpcOriginId' => '<string>',
                        ],
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'Restrictions' => [
                'GeoRestriction' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                    'RestrictionType' => 'blacklist|whitelist|none',
                ],
            ],
            'Staging' => true || false,
            'ViewerCertificate' => [
                'ACMCertificateArn' => '<string>',
                'Certificate' => '<string>',
                'CertificateSource' => 'cloudfront|iam|acm',
                'CloudFrontDefaultCertificate' => true || false,
                'IAMCertificateId' => '<string>',
                'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                'SSLSupportMethod' => 'sni-only|vip|static-ip',
            ],
            'WebACLId' => '<string>',
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'InProgressInvalidationBatches' => <integer>,
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
    ],
    'ETag' => '<string>',
    'Location' => '<string>',
]

Result Details

Members
Distribution
Type: Distribution structure

A distribution tells CloudFront where you want content to be delivered from, and the details about how to track and manage content delivery.

ETag
Type: string

The version identifier for the current version of the staging distribution.

Location
Type: string

The URL of the staging distribution.

Errors

AccessDenied:

Access denied.

TooManyDistributionsAssociatedToOriginAccessControl:

The maximum number of distributions have been associated with the specified origin access control.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidDefaultRootObject:

The default root object file name is too big or contains an invalid character.

InvalidQueryStringParameters:

The query string parameters specified are not valid.

TooManyTrustedSigners:

Your request contains more trusted signers than are allowed per distribution.

TooManyCookieNamesInWhiteList:

Your request contains more cookie names in the whitelist than are allowed per cache behavior.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

InvalidErrorCode:

An invalid error code was specified.

InvalidProtocolSettings:

You cannot specify SSLv3 as the minimum protocol version if you only want to support only clients that support Server Name Indication (SNI).

TooManyFunctionAssociations:

You have reached the maximum number of CloudFront function associations for this distribution. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginCustomHeaders:

Your request contains too many origin custom headers.

InvalidOrigin:

The Amazon S3 origin server specified does not refer to a valid Amazon S3 bucket.

InvalidForwardCookies:

Your request contains forward cookies option which doesn't match with the expectation for the whitelisted list of cookie names. Either list of cookie names has been specified when not allowed or list of cookie names is missing when expected.

InvalidMinimumProtocolVersion:

The minimum protocol version specified is not valid.

NoSuchCachePolicy:

The cache policy does not exist.

TooManyKeyGroupsAssociatedToDistribution:

The number of key groups referenced by this distribution is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyDistributionsAssociatedToCachePolicy:

The maximum number of distributions have been associated with the specified cache policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidRequiredProtocol:

This operation requires the HTTPS protocol. Ensure that you specify the HTTPS protocol in your request, or omit the RequiredProtocols element from your distribution configuration.

TooManyDistributionsWithFunctionAssociations:

You have reached the maximum number of distributions that are associated with a CloudFront function. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginGroupsPerDistribution:

Processing your request would cause you to exceed the maximum number of origin groups allowed.

TooManyDistributions:

Processing your request would cause you to exceed the maximum number of distributions allowed.

InvalidTTLOrder:

The TTL order specified is not valid.

IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior:

The specified configuration for field-level encryption can't be associated with the specified cache behavior.

InvalidOriginKeepaliveTimeout:

The keep alive timeout specified for the origin is not valid.

InvalidArgument:

An argument is invalid.

InvalidOriginReadTimeout:

The read timeout specified for the origin is not valid.

InvalidOriginAccessControl:

The origin access control is not valid.

InvalidHeadersForS3Origin:

The headers specified are not valid for an Amazon S3 origin.

TrustedSignerDoesNotExist:

One or more of your trusted signers don't exist.

InvalidWebACLId:

A web ACL ID specified is not valid. To specify a web ACL created using the latest version of WAF, use the ACL ARN, for example arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/473e64fd-f30b-4765-81a0-62ad96dd167a. To specify a web ACL created using WAF Classic, use the ACL ID, for example 473e64fd-f30b-4765-81a0-62ad96dd167a.

TooManyDistributionsWithSingleFunctionARN:

The maximum number of distributions have been associated with the specified Lambda@Edge function.

InvalidRelativePath:

The relative path is too big, is not URL-encoded, or does not begin with a slash (/).

TooManyLambdaFunctionAssociations:

Your request contains more Lambda@Edge function associations than are allowed per distribution.

NoSuchDistribution:

The specified distribution does not exist.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

TooManyDistributionsAssociatedToFieldLevelEncryptionConfig:

The maximum number of distributions have been associated with the specified configuration for field-level encryption.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidLocationCode:

The location code specified is not valid.

InvalidOriginAccessIdentity:

The origin access identity is not valid or doesn't exist.

TooManyDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

TooManyDistributionsAssociatedToOriginRequestPolicy:

The maximum number of distributions have been associated with the specified origin request policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyQueryStringParameters:

Your request contains too many query string parameters.

RealtimeLogConfigOwnerMismatch:

The specified real-time log configuration belongs to a different Amazon Web Services account.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyHeadersInForwardedValues:

Your request contains too many headers in forwarded values.

InvalidLambdaFunctionAssociation:

The specified Lambda@Edge function association is invalid.

CNAMEAlreadyExists:

The CNAME specified is already defined for CloudFront.

TooManyCertificates:

You cannot create anymore custom SSL/TLS certificates.

TrustedKeyGroupDoesNotExist:

The specified key group does not exist.

TooManyDistributionsAssociatedToResponseHeadersPolicy:

The maximum number of distributions have been associated with the specified response headers policy.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

InvalidResponseCode:

A response code is not valid.

InvalidGeoRestrictionParameter:

The specified geo restriction parameter is not valid.

TooManyOrigins:

You cannot create more origins for the distribution.

InvalidViewerCertificate:

A viewer certificate specified is not valid.

InvalidFunctionAssociation:

A CloudFront function association is invalid.

TooManyDistributionsWithLambdaAssociations:

Processing your request would cause the maximum number of distributions with Lambda@Edge function associations per owner to be exceeded.

TooManyDistributionsAssociatedToKeyGroup:

The number of distributions that reference this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

DistributionAlreadyExists:

The caller reference you attempted to create the distribution with is associated with another distribution.

NoSuchOrigin:

No origin exists with the specified Origin Id.

TooManyCacheBehaviors:

You cannot create more cache behaviors for the distribution.

CreateAnycastIpList

$result = $client->createAnycastIpList([/* ... */]);
$promise = $client->createAnycastIpListAsync([/* ... */]);

Creates an Anycast static IP list.

Parameter Syntax

$result = $client->createAnycastIpList([
    'IpCount' => <integer>, // REQUIRED
    'Name' => '<string>', // REQUIRED
    'Tags' => [
        'Items' => [
            [
                'Key' => '<string>', // REQUIRED
                'Value' => '<string>',
            ],
            // ...
        ],
    ],
]);

Parameter Details

Members
IpCount
Required: Yes
Type: int

The number of static IP addresses that are allocated to the Anycast static IP list.

Name
Required: Yes
Type: string

Name of the Anycast static IP list.

Tags
Type: Tags structure

A complex type that contains zero or more Tag elements.

Result Syntax

[
    'AnycastIpList' => [
        'AnycastIps' => ['<string>', ...],
        'Arn' => '<string>',
        'Id' => '<string>',
        'IpCount' => <integer>,
        'LastModifiedTime' => <DateTime>,
        'Name' => '<string>',
        'Status' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
AnycastIpList
Type: AnycastIpList structure

A response structure that includes the version identifier (ETag) and the created AnycastIpList structure.

ETag
Type: string

The version identifier for the current version of the Anycast static IP list.

Errors

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

EntityAlreadyExists:

The entity already exists. You must provide a unique entity.

InvalidTagging:

The tagging specified is not valid.

InvalidArgument:

An argument is invalid.

EntityLimitExceeded:

The entity limit has been exceeded.

CreateCachePolicy

$result = $client->createCachePolicy([/* ... */]);
$promise = $client->createCachePolicyAsync([/* ... */]);

Creates a cache policy.

After you create a cache policy, you can attach it to one or more cache behaviors. When it's attached to a cache behavior, the cache policy determines the following:

  • The values that CloudFront includes in the cache key. These values can include HTTP headers, cookies, and URL query strings. CloudFront uses the cache key to find an object in its cache that it can return to the viewer.

  • The default, minimum, and maximum time to live (TTL) values that you want objects to stay in the CloudFront cache.

The headers, cookies, and query strings that are included in the cache key are also included in requests that CloudFront sends to the origin. CloudFront sends a request when it can't find an object in its cache that matches the request's cache key. If you want to send values to the origin but not include them in the cache key, use OriginRequestPolicy.

For more information about cache policies, see Controlling the cache key in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createCachePolicy([
    'CachePolicyConfig' => [ // REQUIRED
        'Comment' => '<string>',
        'DefaultTTL' => <integer>,
        'MaxTTL' => <integer>,
        'MinTTL' => <integer>, // REQUIRED
        'Name' => '<string>', // REQUIRED
        'ParametersInCacheKeyAndForwardedToOrigin' => [
            'CookiesConfig' => [ // REQUIRED
                'CookieBehavior' => 'none|whitelist|allExcept|all', // REQUIRED
                'Cookies' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
            ],
            'EnableAcceptEncodingBrotli' => true || false,
            'EnableAcceptEncodingGzip' => true || false, // REQUIRED
            'HeadersConfig' => [ // REQUIRED
                'HeaderBehavior' => 'none|whitelist', // REQUIRED
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
            ],
            'QueryStringsConfig' => [ // REQUIRED
                'QueryStringBehavior' => 'none|whitelist|allExcept|all', // REQUIRED
                'QueryStrings' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
            ],
        ],
    ],
]);

Parameter Details

Members
CachePolicyConfig
Required: Yes
Type: CachePolicyConfig structure

A cache policy configuration.

Result Syntax

[
    'CachePolicy' => [
        'CachePolicyConfig' => [
            'Comment' => '<string>',
            'DefaultTTL' => <integer>,
            'MaxTTL' => <integer>,
            'MinTTL' => <integer>,
            'Name' => '<string>',
            'ParametersInCacheKeyAndForwardedToOrigin' => [
                'CookiesConfig' => [
                    'CookieBehavior' => 'none|whitelist|allExcept|all',
                    'Cookies' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'EnableAcceptEncodingBrotli' => true || false,
                'EnableAcceptEncodingGzip' => true || false,
                'HeadersConfig' => [
                    'HeaderBehavior' => 'none|whitelist',
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'QueryStringsConfig' => [
                    'QueryStringBehavior' => 'none|whitelist|allExcept|all',
                    'QueryStrings' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
    'ETag' => '<string>',
    'Location' => '<string>',
]

Result Details

Members
CachePolicy
Type: CachePolicy structure

A cache policy.

ETag
Type: string

The current version of the cache policy.

Location
Type: string

The fully qualified URI of the cache policy just created.

Errors

AccessDenied:

Access denied.

TooManyHeadersInCachePolicy:

The number of headers in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

CachePolicyAlreadyExists:

A cache policy with this name already exists. You must provide a unique name. To modify an existing cache policy, use UpdateCachePolicy.

TooManyCookiesInCachePolicy:

The number of cookies in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

TooManyCachePolicies:

You have reached the maximum number of cache policies for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

TooManyQueryStringsInCachePolicy:

The number of query strings in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

CreateCloudFrontOriginAccessIdentity

$result = $client->createCloudFrontOriginAccessIdentity([/* ... */]);
$promise = $client->createCloudFrontOriginAccessIdentityAsync([/* ... */]);

Creates a new origin access identity. If you're using Amazon S3 for your origin, you can use an origin access identity to require users to access your content using a CloudFront URL instead of the Amazon S3 URL. For more information about how to use origin access identities, see Serving Private Content through CloudFront in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createCloudFrontOriginAccessIdentity([
    'CloudFrontOriginAccessIdentityConfig' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>', // REQUIRED
    ],
]);

Parameter Details

Members
CloudFrontOriginAccessIdentityConfig
Required: Yes
Type: CloudFrontOriginAccessIdentityConfig structure

The current configuration information for the identity.

Result Syntax

[
    'CloudFrontOriginAccessIdentity' => [
        'CloudFrontOriginAccessIdentityConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
        ],
        'Id' => '<string>',
        'S3CanonicalUserId' => '<string>',
    ],
    'ETag' => '<string>',
    'Location' => '<string>',
]

Result Details

Members
CloudFrontOriginAccessIdentity

The origin access identity's information.

ETag
Type: string

The current version of the origin access identity created.

Location
Type: string

The fully qualified URI of the new origin access identity just created.

Errors

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyCloudFrontOriginAccessIdentities:

Processing your request would cause you to exceed the maximum number of origin access identities allowed.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidArgument:

An argument is invalid.

CloudFrontOriginAccessIdentityAlreadyExists:

If the CallerReference is a value you already sent in a previous request to create an identity but the content of the CloudFrontOriginAccessIdentityConfig is different from the original request, CloudFront returns a CloudFrontOriginAccessIdentityAlreadyExists error.

CreateContinuousDeploymentPolicy

$result = $client->createContinuousDeploymentPolicy([/* ... */]);
$promise = $client->createContinuousDeploymentPolicyAsync([/* ... */]);

Creates a continuous deployment policy that distributes traffic for a custom domain name to two different CloudFront distributions.

To use a continuous deployment policy, first use CopyDistribution to create a staging distribution, then use UpdateDistribution to modify the staging distribution's configuration.

After you create and update a staging distribution, you can use a continuous deployment policy to incrementally move traffic to the staging distribution. This workflow enables you to test changes to a distribution's configuration before moving all of your domain's production traffic to the new configuration.

Parameter Syntax

$result = $client->createContinuousDeploymentPolicy([
    'ContinuousDeploymentPolicyConfig' => [ // REQUIRED
        'Enabled' => true || false, // REQUIRED
        'StagingDistributionDnsNames' => [ // REQUIRED
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
        'TrafficConfig' => [
            'SingleHeaderConfig' => [
                'Header' => '<string>', // REQUIRED
                'Value' => '<string>', // REQUIRED
            ],
            'SingleWeightConfig' => [
                'SessionStickinessConfig' => [
                    'IdleTTL' => <integer>, // REQUIRED
                    'MaximumTTL' => <integer>, // REQUIRED
                ],
                'Weight' => <float>, // REQUIRED
            ],
            'Type' => 'SingleWeight|SingleHeader', // REQUIRED
        ],
    ],
]);

Parameter Details

Members
ContinuousDeploymentPolicyConfig
Required: Yes
Type: ContinuousDeploymentPolicyConfig structure

Contains the configuration for a continuous deployment policy.

Result Syntax

[
    'ContinuousDeploymentPolicy' => [
        'ContinuousDeploymentPolicyConfig' => [
            'Enabled' => true || false,
            'StagingDistributionDnsNames' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'TrafficConfig' => [
                'SingleHeaderConfig' => [
                    'Header' => '<string>',
                    'Value' => '<string>',
                ],
                'SingleWeightConfig' => [
                    'SessionStickinessConfig' => [
                        'IdleTTL' => <integer>,
                        'MaximumTTL' => <integer>,
                    ],
                    'Weight' => <float>,
                ],
                'Type' => 'SingleWeight|SingleHeader',
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
    'ETag' => '<string>',
    'Location' => '<string>',
]

Result Details

Members
ContinuousDeploymentPolicy
Type: ContinuousDeploymentPolicy structure

A continuous deployment policy.

ETag
Type: string

The version identifier for the current version of the continuous deployment policy.

Location
Type: string

The location of the continuous deployment policy.

Errors

AccessDenied:

Access denied.

TooManyContinuousDeploymentPolicies:

You have reached the maximum number of continuous deployment policies for this Amazon Web Services account.

StagingDistributionInUse:

A continuous deployment policy for this staging distribution already exists.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

ContinuousDeploymentPolicyAlreadyExists:

A continuous deployment policy with this configuration already exists.

InvalidArgument:

An argument is invalid.

CreateDistribution

$result = $client->createDistribution([/* ... */]);
$promise = $client->createDistributionAsync([/* ... */]);

Creates a CloudFront distribution.

Parameter Syntax

$result = $client->createDistribution([
    'DistributionConfig' => [ // REQUIRED
        'Aliases' => [
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
        'AnycastIpListId' => '<string>',
        'CacheBehaviors' => [
            'Items' => [
                [
                    'AllowedMethods' => [
                        'CachedMethods' => [
                            'Items' => ['<string>', ...], // REQUIRED
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'Items' => ['<string>', ...], // REQUIRED
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'CachePolicyId' => '<string>',
                    'Compress' => true || false,
                    'DefaultTTL' => <integer>,
                    'FieldLevelEncryptionId' => '<string>',
                    'ForwardedValues' => [
                        'Cookies' => [ // REQUIRED
                            'Forward' => 'none|whitelist|all', // REQUIRED
                            'WhitelistedNames' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>, // REQUIRED
                            ],
                        ],
                        'Headers' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'QueryString' => true || false, // REQUIRED
                        'QueryStringCacheKeys' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                    ],
                    'FunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                                'FunctionARN' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'GrpcConfig' => [
                        'Enabled' => true || false, // REQUIRED
                    ],
                    'LambdaFunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                                'IncludeBody' => true || false,
                                'LambdaFunctionARN' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'MaxTTL' => <integer>,
                    'MinTTL' => <integer>,
                    'OriginRequestPolicyId' => '<string>',
                    'PathPattern' => '<string>', // REQUIRED
                    'RealtimeLogConfigArn' => '<string>',
                    'ResponseHeadersPolicyId' => '<string>',
                    'SmoothStreaming' => true || false,
                    'TargetOriginId' => '<string>', // REQUIRED
                    'TrustedKeyGroups' => [
                        'Enabled' => true || false, // REQUIRED
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'TrustedSigners' => [
                        'Enabled' => true || false, // REQUIRED
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>', // REQUIRED
        'ContinuousDeploymentPolicyId' => '<string>',
        'CustomErrorResponses' => [
            'Items' => [
                [
                    'ErrorCachingMinTTL' => <integer>,
                    'ErrorCode' => <integer>, // REQUIRED
                    'ResponseCode' => '<string>',
                    'ResponsePagePath' => '<string>',
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'DefaultCacheBehavior' => [ // REQUIRED
            'AllowedMethods' => [
                'CachedMethods' => [
                    'Items' => ['<string>', ...], // REQUIRED
                    'Quantity' => <integer>, // REQUIRED
                ],
                'Items' => ['<string>', ...], // REQUIRED
                'Quantity' => <integer>, // REQUIRED
            ],
            'CachePolicyId' => '<string>',
            'Compress' => true || false,
            'DefaultTTL' => <integer>,
            'FieldLevelEncryptionId' => '<string>',
            'ForwardedValues' => [
                'Cookies' => [ // REQUIRED
                    'Forward' => 'none|whitelist|all', // REQUIRED
                    'WhitelistedNames' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                ],
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
                'QueryString' => true || false, // REQUIRED
                'QueryStringCacheKeys' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
            ],
            'FunctionAssociations' => [
                'Items' => [
                    [
                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                        'FunctionARN' => '<string>', // REQUIRED
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'GrpcConfig' => [
                'Enabled' => true || false, // REQUIRED
            ],
            'LambdaFunctionAssociations' => [
                'Items' => [
                    [
                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                        'IncludeBody' => true || false,
                        'LambdaFunctionARN' => '<string>', // REQUIRED
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'MaxTTL' => <integer>,
            'MinTTL' => <integer>,
            'OriginRequestPolicyId' => '<string>',
            'RealtimeLogConfigArn' => '<string>',
            'ResponseHeadersPolicyId' => '<string>',
            'SmoothStreaming' => true || false,
            'TargetOriginId' => '<string>', // REQUIRED
            'TrustedKeyGroups' => [
                'Enabled' => true || false, // REQUIRED
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
            'TrustedSigners' => [
                'Enabled' => true || false, // REQUIRED
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
            'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https', // REQUIRED
        ],
        'DefaultRootObject' => '<string>',
        'Enabled' => true || false, // REQUIRED
        'HttpVersion' => 'http1.1|http2|http3|http2and3',
        'IsIPV6Enabled' => true || false,
        'Logging' => [
            'Bucket' => '<string>',
            'Enabled' => true || false,
            'IncludeCookies' => true || false,
            'Prefix' => '<string>',
        ],
        'OriginGroups' => [
            'Items' => [
                [
                    'FailoverCriteria' => [ // REQUIRED
                        'StatusCodes' => [ // REQUIRED
                            'Items' => [<integer>, ...], // REQUIRED
                            'Quantity' => <integer>, // REQUIRED
                        ],
                    ],
                    'Id' => '<string>', // REQUIRED
                    'Members' => [ // REQUIRED
                        'Items' => [ // REQUIRED
                            [
                                'OriginId' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'SelectionCriteria' => 'default|media-quality-based',
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'Origins' => [ // REQUIRED
            'Items' => [ // REQUIRED
                [
                    'ConnectionAttempts' => <integer>,
                    'ConnectionTimeout' => <integer>,
                    'CustomHeaders' => [
                        'Items' => [
                            [
                                'HeaderName' => '<string>', // REQUIRED
                                'HeaderValue' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'CustomOriginConfig' => [
                        'HTTPPort' => <integer>, // REQUIRED
                        'HTTPSPort' => <integer>, // REQUIRED
                        'OriginKeepaliveTimeout' => <integer>,
                        'OriginProtocolPolicy' => 'http-only|match-viewer|https-only', // REQUIRED
                        'OriginReadTimeout' => <integer>,
                        'OriginSslProtocols' => [
                            'Items' => ['<string>', ...], // REQUIRED
                            'Quantity' => <integer>, // REQUIRED
                        ],
                    ],
                    'DomainName' => '<string>', // REQUIRED
                    'Id' => '<string>', // REQUIRED
                    'OriginAccessControlId' => '<string>',
                    'OriginPath' => '<string>',
                    'OriginShield' => [
                        'Enabled' => true || false, // REQUIRED
                        'OriginShieldRegion' => '<string>',
                    ],
                    'S3OriginConfig' => [
                        'OriginAccessIdentity' => '<string>', // REQUIRED
                    ],
                    'VpcOriginConfig' => [
                        'OriginKeepaliveTimeout' => <integer>,
                        'OriginReadTimeout' => <integer>,
                        'VpcOriginId' => '<string>', // REQUIRED
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
        'Restrictions' => [
            'GeoRestriction' => [ // REQUIRED
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
                'RestrictionType' => 'blacklist|whitelist|none', // REQUIRED
            ],
        ],
        'Staging' => true || false,
        'ViewerCertificate' => [
            'ACMCertificateArn' => '<string>',
            'Certificate' => '<string>',
            'CertificateSource' => 'cloudfront|iam|acm',
            'CloudFrontDefaultCertificate' => true || false,
            'IAMCertificateId' => '<string>',
            'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
            'SSLSupportMethod' => 'sni-only|vip|static-ip',
        ],
        'WebACLId' => '<string>',
    ],
]);

Parameter Details

Members
DistributionConfig
Required: Yes
Type: DistributionConfig structure

The distribution's configuration information.

Result Syntax

[
    'Distribution' => [
        'ARN' => '<string>',
        'ActiveTrustedKeyGroups' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'KeyGroupId' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'AliasICPRecordals' => [
            [
                'CNAME' => '<string>',
                'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
            ],
            // ...
        ],
        'DistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AnycastIpListId' => '<string>',
            'CacheBehaviors' => [
                'Items' => [
                    [
                        'AllowedMethods' => [
                            'CachedMethods' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'CachePolicyId' => '<string>',
                        'Compress' => true || false,
                        'DefaultTTL' => <integer>,
                        'FieldLevelEncryptionId' => '<string>',
                        'ForwardedValues' => [
                            'Cookies' => [
                                'Forward' => 'none|whitelist|all',
                                'WhitelistedNames' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Headers' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'QueryString' => true || false,
                            'QueryStringCacheKeys' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'FunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'FunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'GrpcConfig' => [
                            'Enabled' => true || false,
                        ],
                        'LambdaFunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'IncludeBody' => true || false,
                                    'LambdaFunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'MaxTTL' => <integer>,
                        'MinTTL' => <integer>,
                        'OriginRequestPolicyId' => '<string>',
                        'PathPattern' => '<string>',
                        'RealtimeLogConfigArn' => '<string>',
                        'ResponseHeadersPolicyId' => '<string>',
                        'SmoothStreaming' => true || false,
                        'TargetOriginId' => '<string>',
                        'TrustedKeyGroups' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'TrustedSigners' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContinuousDeploymentPolicyId' => '<string>',
            'CustomErrorResponses' => [
                'Items' => [
                    [
                        'ErrorCachingMinTTL' => <integer>,
                        'ErrorCode' => <integer>,
                        'ResponseCode' => '<string>',
                        'ResponsePagePath' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'DefaultCacheBehavior' => [
                'AllowedMethods' => [
                    'CachedMethods' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'CachePolicyId' => '<string>',
                'Compress' => true || false,
                'DefaultTTL' => <integer>,
                'FieldLevelEncryptionId' => '<string>',
                'ForwardedValues' => [
                    'Cookies' => [
                        'Forward' => 'none|whitelist|all',
                        'WhitelistedNames' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'QueryString' => true || false,
                    'QueryStringCacheKeys' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'FunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'FunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'GrpcConfig' => [
                    'Enabled' => true || false,
                ],
                'LambdaFunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'IncludeBody' => true || false,
                            'LambdaFunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'MaxTTL' => <integer>,
                'MinTTL' => <integer>,
                'OriginRequestPolicyId' => '<string>',
                'RealtimeLogConfigArn' => '<string>',
                'ResponseHeadersPolicyId' => '<string>',
                'SmoothStreaming' => true || false,
                'TargetOriginId' => '<string>',
                'TrustedKeyGroups' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'TrustedSigners' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
            ],
            'DefaultRootObject' => '<string>',
            'Enabled' => true || false,
            'HttpVersion' => 'http1.1|http2|http3|http2and3',
            'IsIPV6Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'IncludeCookies' => true || false,
                'Prefix' => '<string>',
            ],
            'OriginGroups' => [
                'Items' => [
                    [
                        'FailoverCriteria' => [
                            'StatusCodes' => [
                                'Items' => [<integer>, ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Id' => '<string>',
                        'Members' => [
                            'Items' => [
                                [
                                    'OriginId' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'SelectionCriteria' => 'default|media-quality-based',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Origins' => [
                'Items' => [
                    [
                        'ConnectionAttempts' => <integer>,
                        'ConnectionTimeout' => <integer>,
                        'CustomHeaders' => [
                            'Items' => [
                                [
                                    'HeaderName' => '<string>',
                                    'HeaderValue' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'CustomOriginConfig' => [
                            'HTTPPort' => <integer>,
                            'HTTPSPort' => <integer>,
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                            'OriginReadTimeout' => <integer>,
                            'OriginSslProtocols' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'DomainName' => '<string>',
                        'Id' => '<string>',
                        'OriginAccessControlId' => '<string>',
                        'OriginPath' => '<string>',
                        'OriginShield' => [
                            'Enabled' => true || false,
                            'OriginShieldRegion' => '<string>',
                        ],
                        'S3OriginConfig' => [
                            'OriginAccessIdentity' => '<string>',
                        ],
                        'VpcOriginConfig' => [
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginReadTimeout' => <integer>,
                            'VpcOriginId' => '<string>',
                        ],
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'Restrictions' => [
                'GeoRestriction' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                    'RestrictionType' => 'blacklist|whitelist|none',
                ],
            ],
            'Staging' => true || false,
            'ViewerCertificate' => [
                'ACMCertificateArn' => '<string>',
                'Certificate' => '<string>',
                'CertificateSource' => 'cloudfront|iam|acm',
                'CloudFrontDefaultCertificate' => true || false,
                'IAMCertificateId' => '<string>',
                'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                'SSLSupportMethod' => 'sni-only|vip|static-ip',
            ],
            'WebACLId' => '<string>',
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'InProgressInvalidationBatches' => <integer>,
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
    ],
    'ETag' => '<string>',
    'Location' => '<string>',
]

Result Details

Members
Distribution
Type: Distribution structure

The distribution's information.

ETag
Type: string

The current version of the distribution created.

Location
Type: string

The fully qualified URI of the new distribution resource just created.

Errors

AccessDenied:

Access denied.

TooManyDistributionsAssociatedToOriginAccessControl:

The maximum number of distributions have been associated with the specified origin access control.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidDefaultRootObject:

The default root object file name is too big or contains an invalid character.

InvalidDomainNameForOriginAccessControl:

An origin access control is associated with an origin whose domain name is not supported.

InvalidQueryStringParameters:

The query string parameters specified are not valid.

TooManyTrustedSigners:

Your request contains more trusted signers than are allowed per distribution.

TooManyCookieNamesInWhiteList:

Your request contains more cookie names in the whitelist than are allowed per cache behavior.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

InvalidErrorCode:

An invalid error code was specified.

IllegalOriginAccessConfiguration:

An origin cannot contain both an origin access control (OAC) and an origin access identity (OAI).

InvalidProtocolSettings:

You cannot specify SSLv3 as the minimum protocol version if you only want to support only clients that support Server Name Indication (SNI).

TooManyFunctionAssociations:

You have reached the maximum number of CloudFront function associations for this distribution. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginCustomHeaders:

Your request contains too many origin custom headers.

InvalidOrigin:

The Amazon S3 origin server specified does not refer to a valid Amazon S3 bucket.

InvalidForwardCookies:

Your request contains forward cookies option which doesn't match with the expectation for the whitelisted list of cookie names. Either list of cookie names has been specified when not allowed or list of cookie names is missing when expected.

InvalidMinimumProtocolVersion:

The minimum protocol version specified is not valid.

NoSuchCachePolicy:

The cache policy does not exist.

TooManyKeyGroupsAssociatedToDistribution:

The number of key groups referenced by this distribution is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyDistributionsAssociatedToCachePolicy:

The maximum number of distributions have been associated with the specified cache policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidRequiredProtocol:

This operation requires the HTTPS protocol. Ensure that you specify the HTTPS protocol in your request, or omit the RequiredProtocols element from your distribution configuration.

TooManyDistributionsWithFunctionAssociations:

You have reached the maximum number of distributions that are associated with a CloudFront function. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginGroupsPerDistribution:

Processing your request would cause you to exceed the maximum number of origin groups allowed.

TooManyDistributions:

Processing your request would cause you to exceed the maximum number of distributions allowed.

InvalidTTLOrder:

The TTL order specified is not valid.

IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior:

The specified configuration for field-level encryption can't be associated with the specified cache behavior.

InvalidOriginKeepaliveTimeout:

The keep alive timeout specified for the origin is not valid.

InvalidArgument:

An argument is invalid.

InvalidOriginReadTimeout:

The read timeout specified for the origin is not valid.

InvalidOriginAccessControl:

The origin access control is not valid.

EntityNotFound:

The entity was not found.

InvalidHeadersForS3Origin:

The headers specified are not valid for an Amazon S3 origin.

TrustedSignerDoesNotExist:

One or more of your trusted signers don't exist.

InvalidWebACLId:

A web ACL ID specified is not valid. To specify a web ACL created using the latest version of WAF, use the ACL ARN, for example arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/473e64fd-f30b-4765-81a0-62ad96dd167a. To specify a web ACL created using WAF Classic, use the ACL ID, for example 473e64fd-f30b-4765-81a0-62ad96dd167a.

TooManyDistributionsWithSingleFunctionARN:

The maximum number of distributions have been associated with the specified Lambda@Edge function.

InvalidRelativePath:

The relative path is too big, is not URL-encoded, or does not begin with a slash (/).

TooManyLambdaFunctionAssociations:

Your request contains more Lambda@Edge function associations than are allowed per distribution.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

TooManyDistributionsAssociatedToFieldLevelEncryptionConfig:

The maximum number of distributions have been associated with the specified configuration for field-level encryption.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidLocationCode:

The location code specified is not valid.

InvalidOriginAccessIdentity:

The origin access identity is not valid or doesn't exist.

TooManyDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

NoSuchContinuousDeploymentPolicy:

The continuous deployment policy doesn't exist.

TooManyDistributionsAssociatedToOriginRequestPolicy:

The maximum number of distributions have been associated with the specified origin request policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyQueryStringParameters:

Your request contains too many query string parameters.

RealtimeLogConfigOwnerMismatch:

The specified real-time log configuration belongs to a different Amazon Web Services account.

ContinuousDeploymentPolicyInUse:

You cannot delete a continuous deployment policy that is associated with a primary distribution.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyHeadersInForwardedValues:

Your request contains too many headers in forwarded values.

InvalidLambdaFunctionAssociation:

The specified Lambda@Edge function association is invalid.

CNAMEAlreadyExists:

The CNAME specified is already defined for CloudFront.

TooManyCertificates:

You cannot create anymore custom SSL/TLS certificates.

TrustedKeyGroupDoesNotExist:

The specified key group does not exist.

TooManyDistributionsAssociatedToResponseHeadersPolicy:

The maximum number of distributions have been associated with the specified response headers policy.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

InvalidResponseCode:

A response code is not valid.

InvalidGeoRestrictionParameter:

The specified geo restriction parameter is not valid.

TooManyOrigins:

You cannot create more origins for the distribution.

InvalidViewerCertificate:

A viewer certificate specified is not valid.

InvalidFunctionAssociation:

A CloudFront function association is invalid.

TooManyDistributionsWithLambdaAssociations:

Processing your request would cause the maximum number of distributions with Lambda@Edge function associations per owner to be exceeded.

TooManyDistributionsAssociatedToKeyGroup:

The number of distributions that reference this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

DistributionAlreadyExists:

The caller reference you attempted to create the distribution with is associated with another distribution.

NoSuchOrigin:

No origin exists with the specified Origin Id.

TooManyCacheBehaviors:

You cannot create more cache behaviors for the distribution.

CreateDistributionWithTags

$result = $client->createDistributionWithTags([/* ... */]);
$promise = $client->createDistributionWithTagsAsync([/* ... */]);

Create a new distribution with tags. This API operation requires the following IAM permissions:

Parameter Syntax

$result = $client->createDistributionWithTags([
    'DistributionConfigWithTags' => [ // REQUIRED
        'DistributionConfig' => [ // REQUIRED
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
            'AnycastIpListId' => '<string>',
            'CacheBehaviors' => [
                'Items' => [
                    [
                        'AllowedMethods' => [
                            'CachedMethods' => [
                                'Items' => ['<string>', ...], // REQUIRED
                                'Quantity' => <integer>, // REQUIRED
                            ],
                            'Items' => ['<string>', ...], // REQUIRED
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'CachePolicyId' => '<string>',
                        'Compress' => true || false,
                        'DefaultTTL' => <integer>,
                        'FieldLevelEncryptionId' => '<string>',
                        'ForwardedValues' => [
                            'Cookies' => [ // REQUIRED
                                'Forward' => 'none|whitelist|all', // REQUIRED
                                'WhitelistedNames' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>, // REQUIRED
                                ],
                            ],
                            'Headers' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>, // REQUIRED
                            ],
                            'QueryString' => true || false, // REQUIRED
                            'QueryStringCacheKeys' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>, // REQUIRED
                            ],
                        ],
                        'FunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                                    'FunctionARN' => '<string>', // REQUIRED
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'GrpcConfig' => [
                            'Enabled' => true || false, // REQUIRED
                        ],
                        'LambdaFunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                                    'IncludeBody' => true || false,
                                    'LambdaFunctionARN' => '<string>', // REQUIRED
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'MaxTTL' => <integer>,
                        'MinTTL' => <integer>,
                        'OriginRequestPolicyId' => '<string>',
                        'PathPattern' => '<string>', // REQUIRED
                        'RealtimeLogConfigArn' => '<string>',
                        'ResponseHeadersPolicyId' => '<string>',
                        'SmoothStreaming' => true || false,
                        'TargetOriginId' => '<string>', // REQUIRED
                        'TrustedKeyGroups' => [
                            'Enabled' => true || false, // REQUIRED
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'TrustedSigners' => [
                            'Enabled' => true || false, // REQUIRED
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https', // REQUIRED
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'CallerReference' => '<string>', // REQUIRED
            'Comment' => '<string>', // REQUIRED
            'ContinuousDeploymentPolicyId' => '<string>',
            'CustomErrorResponses' => [
                'Items' => [
                    [
                        'ErrorCachingMinTTL' => <integer>,
                        'ErrorCode' => <integer>, // REQUIRED
                        'ResponseCode' => '<string>',
                        'ResponsePagePath' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'DefaultCacheBehavior' => [ // REQUIRED
                'AllowedMethods' => [
                    'CachedMethods' => [
                        'Items' => ['<string>', ...], // REQUIRED
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'Items' => ['<string>', ...], // REQUIRED
                    'Quantity' => <integer>, // REQUIRED
                ],
                'CachePolicyId' => '<string>',
                'Compress' => true || false,
                'DefaultTTL' => <integer>,
                'FieldLevelEncryptionId' => '<string>',
                'ForwardedValues' => [
                    'Cookies' => [ // REQUIRED
                        'Forward' => 'none|whitelist|all', // REQUIRED
                        'WhitelistedNames' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                    ],
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'QueryString' => true || false, // REQUIRED
                    'QueryStringCacheKeys' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                ],
                'FunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                            'FunctionARN' => '<string>', // REQUIRED
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>, // REQUIRED
                ],
                'GrpcConfig' => [
                    'Enabled' => true || false, // REQUIRED
                ],
                'LambdaFunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                            'IncludeBody' => true || false,
                            'LambdaFunctionARN' => '<string>', // REQUIRED
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>, // REQUIRED
                ],
                'MaxTTL' => <integer>,
                'MinTTL' => <integer>,
                'OriginRequestPolicyId' => '<string>',
                'RealtimeLogConfigArn' => '<string>',
                'ResponseHeadersPolicyId' => '<string>',
                'SmoothStreaming' => true || false,
                'TargetOriginId' => '<string>', // REQUIRED
                'TrustedKeyGroups' => [
                    'Enabled' => true || false, // REQUIRED
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
                'TrustedSigners' => [
                    'Enabled' => true || false, // REQUIRED
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
                'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https', // REQUIRED
            ],
            'DefaultRootObject' => '<string>',
            'Enabled' => true || false, // REQUIRED
            'HttpVersion' => 'http1.1|http2|http3|http2and3',
            'IsIPV6Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'IncludeCookies' => true || false,
                'Prefix' => '<string>',
            ],
            'OriginGroups' => [
                'Items' => [
                    [
                        'FailoverCriteria' => [ // REQUIRED
                            'StatusCodes' => [ // REQUIRED
                                'Items' => [<integer>, ...], // REQUIRED
                                'Quantity' => <integer>, // REQUIRED
                            ],
                        ],
                        'Id' => '<string>', // REQUIRED
                        'Members' => [ // REQUIRED
                            'Items' => [ // REQUIRED
                                [
                                    'OriginId' => '<string>', // REQUIRED
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'SelectionCriteria' => 'default|media-quality-based',
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'Origins' => [ // REQUIRED
                'Items' => [ // REQUIRED
                    [
                        'ConnectionAttempts' => <integer>,
                        'ConnectionTimeout' => <integer>,
                        'CustomHeaders' => [
                            'Items' => [
                                [
                                    'HeaderName' => '<string>', // REQUIRED
                                    'HeaderValue' => '<string>', // REQUIRED
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'CustomOriginConfig' => [
                            'HTTPPort' => <integer>, // REQUIRED
                            'HTTPSPort' => <integer>, // REQUIRED
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only', // REQUIRED
                            'OriginReadTimeout' => <integer>,
                            'OriginSslProtocols' => [
                                'Items' => ['<string>', ...], // REQUIRED
                                'Quantity' => <integer>, // REQUIRED
                            ],
                        ],
                        'DomainName' => '<string>', // REQUIRED
                        'Id' => '<string>', // REQUIRED
                        'OriginAccessControlId' => '<string>',
                        'OriginPath' => '<string>',
                        'OriginShield' => [
                            'Enabled' => true || false, // REQUIRED
                            'OriginShieldRegion' => '<string>',
                        ],
                        'S3OriginConfig' => [
                            'OriginAccessIdentity' => '<string>', // REQUIRED
                        ],
                        'VpcOriginConfig' => [
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginReadTimeout' => <integer>,
                            'VpcOriginId' => '<string>', // REQUIRED
                        ],
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'Restrictions' => [
                'GeoRestriction' => [ // REQUIRED
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                    'RestrictionType' => 'blacklist|whitelist|none', // REQUIRED
                ],
            ],
            'Staging' => true || false,
            'ViewerCertificate' => [
                'ACMCertificateArn' => '<string>',
                'Certificate' => '<string>',
                'CertificateSource' => 'cloudfront|iam|acm',
                'CloudFrontDefaultCertificate' => true || false,
                'IAMCertificateId' => '<string>',
                'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                'SSLSupportMethod' => 'sni-only|vip|static-ip',
            ],
            'WebACLId' => '<string>',
        ],
        'Tags' => [ // REQUIRED
            'Items' => [
                [
                    'Key' => '<string>', // REQUIRED
                    'Value' => '<string>',
                ],
                // ...
            ],
        ],
    ],
]);

Parameter Details

Members
DistributionConfigWithTags
Required: Yes
Type: DistributionConfigWithTags structure

The distribution's configuration information.

Result Syntax

[
    'Distribution' => [
        'ARN' => '<string>',
        'ActiveTrustedKeyGroups' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'KeyGroupId' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'AliasICPRecordals' => [
            [
                'CNAME' => '<string>',
                'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
            ],
            // ...
        ],
        'DistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AnycastIpListId' => '<string>',
            'CacheBehaviors' => [
                'Items' => [
                    [
                        'AllowedMethods' => [
                            'CachedMethods' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'CachePolicyId' => '<string>',
                        'Compress' => true || false,
                        'DefaultTTL' => <integer>,
                        'FieldLevelEncryptionId' => '<string>',
                        'ForwardedValues' => [
                            'Cookies' => [
                                'Forward' => 'none|whitelist|all',
                                'WhitelistedNames' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Headers' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'QueryString' => true || false,
                            'QueryStringCacheKeys' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'FunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'FunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'GrpcConfig' => [
                            'Enabled' => true || false,
                        ],
                        'LambdaFunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'IncludeBody' => true || false,
                                    'LambdaFunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'MaxTTL' => <integer>,
                        'MinTTL' => <integer>,
                        'OriginRequestPolicyId' => '<string>',
                        'PathPattern' => '<string>',
                        'RealtimeLogConfigArn' => '<string>',
                        'ResponseHeadersPolicyId' => '<string>',
                        'SmoothStreaming' => true || false,
                        'TargetOriginId' => '<string>',
                        'TrustedKeyGroups' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'TrustedSigners' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContinuousDeploymentPolicyId' => '<string>',
            'CustomErrorResponses' => [
                'Items' => [
                    [
                        'ErrorCachingMinTTL' => <integer>,
                        'ErrorCode' => <integer>,
                        'ResponseCode' => '<string>',
                        'ResponsePagePath' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'DefaultCacheBehavior' => [
                'AllowedMethods' => [
                    'CachedMethods' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'CachePolicyId' => '<string>',
                'Compress' => true || false,
                'DefaultTTL' => <integer>,
                'FieldLevelEncryptionId' => '<string>',
                'ForwardedValues' => [
                    'Cookies' => [
                        'Forward' => 'none|whitelist|all',
                        'WhitelistedNames' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'QueryString' => true || false,
                    'QueryStringCacheKeys' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'FunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'FunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'GrpcConfig' => [
                    'Enabled' => true || false,
                ],
                'LambdaFunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'IncludeBody' => true || false,
                            'LambdaFunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'MaxTTL' => <integer>,
                'MinTTL' => <integer>,
                'OriginRequestPolicyId' => '<string>',
                'RealtimeLogConfigArn' => '<string>',
                'ResponseHeadersPolicyId' => '<string>',
                'SmoothStreaming' => true || false,
                'TargetOriginId' => '<string>',
                'TrustedKeyGroups' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'TrustedSigners' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
            ],
            'DefaultRootObject' => '<string>',
            'Enabled' => true || false,
            'HttpVersion' => 'http1.1|http2|http3|http2and3',
            'IsIPV6Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'IncludeCookies' => true || false,
                'Prefix' => '<string>',
            ],
            'OriginGroups' => [
                'Items' => [
                    [
                        'FailoverCriteria' => [
                            'StatusCodes' => [
                                'Items' => [<integer>, ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Id' => '<string>',
                        'Members' => [
                            'Items' => [
                                [
                                    'OriginId' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'SelectionCriteria' => 'default|media-quality-based',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Origins' => [
                'Items' => [
                    [
                        'ConnectionAttempts' => <integer>,
                        'ConnectionTimeout' => <integer>,
                        'CustomHeaders' => [
                            'Items' => [
                                [
                                    'HeaderName' => '<string>',
                                    'HeaderValue' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'CustomOriginConfig' => [
                            'HTTPPort' => <integer>,
                            'HTTPSPort' => <integer>,
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                            'OriginReadTimeout' => <integer>,
                            'OriginSslProtocols' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'DomainName' => '<string>',
                        'Id' => '<string>',
                        'OriginAccessControlId' => '<string>',
                        'OriginPath' => '<string>',
                        'OriginShield' => [
                            'Enabled' => true || false,
                            'OriginShieldRegion' => '<string>',
                        ],
                        'S3OriginConfig' => [
                            'OriginAccessIdentity' => '<string>',
                        ],
                        'VpcOriginConfig' => [
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginReadTimeout' => <integer>,
                            'VpcOriginId' => '<string>',
                        ],
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'Restrictions' => [
                'GeoRestriction' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                    'RestrictionType' => 'blacklist|whitelist|none',
                ],
            ],
            'Staging' => true || false,
            'ViewerCertificate' => [
                'ACMCertificateArn' => '<string>',
                'Certificate' => '<string>',
                'CertificateSource' => 'cloudfront|iam|acm',
                'CloudFrontDefaultCertificate' => true || false,
                'IAMCertificateId' => '<string>',
                'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                'SSLSupportMethod' => 'sni-only|vip|static-ip',
            ],
            'WebACLId' => '<string>',
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'InProgressInvalidationBatches' => <integer>,
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
    ],
    'ETag' => '<string>',
    'Location' => '<string>',
]

Result Details

Members
Distribution
Type: Distribution structure

The distribution's information.

ETag
Type: string

The current version of the distribution created.

Location
Type: string

The fully qualified URI of the new distribution resource just created.

Errors

AccessDenied:

Access denied.

TooManyDistributionsAssociatedToOriginAccessControl:

The maximum number of distributions have been associated with the specified origin access control.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidDefaultRootObject:

The default root object file name is too big or contains an invalid character.

InvalidDomainNameForOriginAccessControl:

An origin access control is associated with an origin whose domain name is not supported.

InvalidQueryStringParameters:

The query string parameters specified are not valid.

TooManyTrustedSigners:

Your request contains more trusted signers than are allowed per distribution.

TooManyCookieNamesInWhiteList:

Your request contains more cookie names in the whitelist than are allowed per cache behavior.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

InvalidErrorCode:

An invalid error code was specified.

IllegalOriginAccessConfiguration:

An origin cannot contain both an origin access control (OAC) and an origin access identity (OAI).

InvalidProtocolSettings:

You cannot specify SSLv3 as the minimum protocol version if you only want to support only clients that support Server Name Indication (SNI).

TooManyFunctionAssociations:

You have reached the maximum number of CloudFront function associations for this distribution. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginCustomHeaders:

Your request contains too many origin custom headers.

InvalidOrigin:

The Amazon S3 origin server specified does not refer to a valid Amazon S3 bucket.

InvalidForwardCookies:

Your request contains forward cookies option which doesn't match with the expectation for the whitelisted list of cookie names. Either list of cookie names has been specified when not allowed or list of cookie names is missing when expected.

InvalidMinimumProtocolVersion:

The minimum protocol version specified is not valid.

NoSuchCachePolicy:

The cache policy does not exist.

TooManyKeyGroupsAssociatedToDistribution:

The number of key groups referenced by this distribution is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyDistributionsAssociatedToCachePolicy:

The maximum number of distributions have been associated with the specified cache policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidRequiredProtocol:

This operation requires the HTTPS protocol. Ensure that you specify the HTTPS protocol in your request, or omit the RequiredProtocols element from your distribution configuration.

TooManyDistributionsWithFunctionAssociations:

You have reached the maximum number of distributions that are associated with a CloudFront function. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginGroupsPerDistribution:

Processing your request would cause you to exceed the maximum number of origin groups allowed.

TooManyDistributions:

Processing your request would cause you to exceed the maximum number of distributions allowed.

InvalidTTLOrder:

The TTL order specified is not valid.

IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior:

The specified configuration for field-level encryption can't be associated with the specified cache behavior.

InvalidOriginKeepaliveTimeout:

The keep alive timeout specified for the origin is not valid.

InvalidArgument:

An argument is invalid.

InvalidOriginReadTimeout:

The read timeout specified for the origin is not valid.

InvalidOriginAccessControl:

The origin access control is not valid.

EntityNotFound:

The entity was not found.

InvalidHeadersForS3Origin:

The headers specified are not valid for an Amazon S3 origin.

TrustedSignerDoesNotExist:

One or more of your trusted signers don't exist.

InvalidWebACLId:

A web ACL ID specified is not valid. To specify a web ACL created using the latest version of WAF, use the ACL ARN, for example arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/473e64fd-f30b-4765-81a0-62ad96dd167a. To specify a web ACL created using WAF Classic, use the ACL ID, for example 473e64fd-f30b-4765-81a0-62ad96dd167a.

TooManyDistributionsWithSingleFunctionARN:

The maximum number of distributions have been associated with the specified Lambda@Edge function.

InvalidRelativePath:

The relative path is too big, is not URL-encoded, or does not begin with a slash (/).

TooManyLambdaFunctionAssociations:

Your request contains more Lambda@Edge function associations than are allowed per distribution.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

TooManyDistributionsAssociatedToFieldLevelEncryptionConfig:

The maximum number of distributions have been associated with the specified configuration for field-level encryption.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidLocationCode:

The location code specified is not valid.

InvalidOriginAccessIdentity:

The origin access identity is not valid or doesn't exist.

InvalidTagging:

The tagging specified is not valid.

TooManyDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

NoSuchContinuousDeploymentPolicy:

The continuous deployment policy doesn't exist.

TooManyDistributionsAssociatedToOriginRequestPolicy:

The maximum number of distributions have been associated with the specified origin request policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyQueryStringParameters:

Your request contains too many query string parameters.

RealtimeLogConfigOwnerMismatch:

The specified real-time log configuration belongs to a different Amazon Web Services account.

ContinuousDeploymentPolicyInUse:

You cannot delete a continuous deployment policy that is associated with a primary distribution.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyHeadersInForwardedValues:

Your request contains too many headers in forwarded values.

InvalidLambdaFunctionAssociation:

The specified Lambda@Edge function association is invalid.

CNAMEAlreadyExists:

The CNAME specified is already defined for CloudFront.

TooManyCertificates:

You cannot create anymore custom SSL/TLS certificates.

TrustedKeyGroupDoesNotExist:

The specified key group does not exist.

TooManyDistributionsAssociatedToResponseHeadersPolicy:

The maximum number of distributions have been associated with the specified response headers policy.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

InvalidResponseCode:

A response code is not valid.

InvalidGeoRestrictionParameter:

The specified geo restriction parameter is not valid.

TooManyOrigins:

You cannot create more origins for the distribution.

InvalidViewerCertificate:

A viewer certificate specified is not valid.

InvalidFunctionAssociation:

A CloudFront function association is invalid.

TooManyDistributionsWithLambdaAssociations:

Processing your request would cause the maximum number of distributions with Lambda@Edge function associations per owner to be exceeded.

TooManyDistributionsAssociatedToKeyGroup:

The number of distributions that reference this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

DistributionAlreadyExists:

The caller reference you attempted to create the distribution with is associated with another distribution.

NoSuchOrigin:

No origin exists with the specified Origin Id.

TooManyCacheBehaviors:

You cannot create more cache behaviors for the distribution.

CreateFieldLevelEncryptionConfig

$result = $client->createFieldLevelEncryptionConfig([/* ... */]);
$promise = $client->createFieldLevelEncryptionConfigAsync([/* ... */]);

Create a new field-level encryption configuration.

Parameter Syntax

$result = $client->createFieldLevelEncryptionConfig([
    'FieldLevelEncryptionConfig' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>',
        'ContentTypeProfileConfig' => [
            'ContentTypeProfiles' => [
                'Items' => [
                    [
                        'ContentType' => '<string>', // REQUIRED
                        'Format' => 'URLEncoded', // REQUIRED
                        'ProfileId' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'ForwardWhenContentTypeIsUnknown' => true || false, // REQUIRED
        ],
        'QueryArgProfileConfig' => [
            'ForwardWhenQueryArgProfileIsUnknown' => true || false, // REQUIRED
            'QueryArgProfiles' => [
                'Items' => [
                    [
                        'ProfileId' => '<string>', // REQUIRED
                        'QueryArg' => '<string>', // REQUIRED
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
    ],
]);

Parameter Details

Members
FieldLevelEncryptionConfig
Required: Yes
Type: FieldLevelEncryptionConfig structure

The request to create a new field-level encryption configuration.

Result Syntax

[
    'ETag' => '<string>',
    'FieldLevelEncryption' => [
        'FieldLevelEncryptionConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContentTypeProfileConfig' => [
                'ContentTypeProfiles' => [
                    'Items' => [
                        [
                            'ContentType' => '<string>',
                            'Format' => 'URLEncoded',
                            'ProfileId' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'ForwardWhenContentTypeIsUnknown' => true || false,
            ],
            'QueryArgProfileConfig' => [
                'ForwardWhenQueryArgProfileIsUnknown' => true || false,
                'QueryArgProfiles' => [
                    'Items' => [
                        [
                            'ProfileId' => '<string>',
                            'QueryArg' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
    'Location' => '<string>',
]

Result Details

Members
ETag
Type: string

The current version of the field level encryption configuration. For example: E2QWRUHAPOMQZL.

FieldLevelEncryption
Type: FieldLevelEncryption structure

Returned when you create a new field-level encryption configuration.

Location
Type: string

The fully qualified URI of the new configuration resource just created.

Errors

QueryArgProfileEmpty:

No profile specified for the field-level encryption query argument.

TooManyFieldLevelEncryptionQueryArgProfiles:

The maximum number of query arg profiles for field-level encryption have been created.

TooManyFieldLevelEncryptionContentTypeProfiles:

The maximum number of content type profiles for field-level encryption have been created.

FieldLevelEncryptionConfigAlreadyExists:

The specified configuration for field-level encryption already exists.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

TooManyFieldLevelEncryptionConfigs:

The maximum number of configurations for field-level encryption have been created.

NoSuchFieldLevelEncryptionProfile:

The specified profile for field-level encryption doesn't exist.

InvalidArgument:

An argument is invalid.

CreateFieldLevelEncryptionProfile

$result = $client->createFieldLevelEncryptionProfile([/* ... */]);
$promise = $client->createFieldLevelEncryptionProfileAsync([/* ... */]);

Create a field-level encryption profile.

Parameter Syntax

$result = $client->createFieldLevelEncryptionProfile([
    'FieldLevelEncryptionProfileConfig' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>',
        'EncryptionEntities' => [ // REQUIRED
            'Items' => [
                [
                    'FieldPatterns' => [ // REQUIRED
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'ProviderId' => '<string>', // REQUIRED
                    'PublicKeyId' => '<string>', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'Name' => '<string>', // REQUIRED
    ],
]);

Parameter Details

Members
FieldLevelEncryptionProfileConfig
Required: Yes
Type: FieldLevelEncryptionProfileConfig structure

The request to create a field-level encryption profile.

Result Syntax

[
    'ETag' => '<string>',
    'FieldLevelEncryptionProfile' => [
        'FieldLevelEncryptionProfileConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'EncryptionEntities' => [
                'Items' => [
                    [
                        'FieldPatterns' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ProviderId' => '<string>',
                        'PublicKeyId' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Name' => '<string>',
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
    'Location' => '<string>',
]

Result Details

Members
ETag
Type: string

The current version of the field level encryption profile. For example: E2QWRUHAPOMQZL.

FieldLevelEncryptionProfile
Type: FieldLevelEncryptionProfile structure

Returned when you create a new field-level encryption profile.

Location
Type: string

The fully qualified URI of the new profile resource just created.

Errors

TooManyFieldLevelEncryptionFieldPatterns:

The maximum number of field patterns for field-level encryption have been created.

FieldLevelEncryptionProfileAlreadyExists:

The specified profile for field-level encryption already exists.

NoSuchPublicKey:

The specified public key doesn't exist.

FieldLevelEncryptionProfileSizeExceeded:

The maximum size of a profile for field-level encryption was exceeded.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

TooManyFieldLevelEncryptionProfiles:

The maximum number of profiles for field-level encryption have been created.

TooManyFieldLevelEncryptionEncryptionEntities:

The maximum number of encryption entities for field-level encryption have been created.

InvalidArgument:

An argument is invalid.

CreateFunction

$result = $client->createFunction([/* ... */]);
$promise = $client->createFunctionAsync([/* ... */]);

Creates a CloudFront function.

To create a function, you provide the function code and some configuration information about the function. The response contains an Amazon Resource Name (ARN) that uniquely identifies the function.

When you create a function, it's in the DEVELOPMENT stage. In this stage, you can test the function with TestFunction, and update it with UpdateFunction.

When you're ready to use your function with a CloudFront distribution, use PublishFunction to copy the function from the DEVELOPMENT stage to LIVE. When it's live, you can attach the function to a distribution's cache behavior, using the function's ARN.

Parameter Syntax

$result = $client->createFunction([
    'FunctionCode' => <string || resource || Psr\Http\Message\StreamInterface>, // REQUIRED
    'FunctionConfig' => [ // REQUIRED
        'Comment' => '<string>', // REQUIRED
        'KeyValueStoreAssociations' => [
            'Items' => [
                [
                    'KeyValueStoreARN' => '<string>', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'Runtime' => 'cloudfront-js-1.0|cloudfront-js-2.0', // REQUIRED
    ],
    'Name' => '<string>', // REQUIRED
]);

Parameter Details

Members
FunctionCode
Required: Yes
Type: blob (string|resource|Psr\Http\Message\StreamInterface)

The function code. For more information about writing a CloudFront function, see Writing function code for CloudFront Functions in the Amazon CloudFront Developer Guide.

FunctionConfig
Required: Yes
Type: FunctionConfig structure

Configuration information about the function, including an optional comment and the function's runtime.

Name
Required: Yes
Type: string

A name to identify the function.

Result Syntax

[
    'ETag' => '<string>',
    'FunctionSummary' => [
        'FunctionConfig' => [
            'Comment' => '<string>',
            'KeyValueStoreAssociations' => [
                'Items' => [
                    [
                        'KeyValueStoreARN' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Runtime' => 'cloudfront-js-1.0|cloudfront-js-2.0',
        ],
        'FunctionMetadata' => [
            'CreatedTime' => <DateTime>,
            'FunctionARN' => '<string>',
            'LastModifiedTime' => <DateTime>,
            'Stage' => 'DEVELOPMENT|LIVE',
        ],
        'Name' => '<string>',
        'Status' => '<string>',
    ],
    'Location' => '<string>',
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the CloudFront function.

FunctionSummary
Type: FunctionSummary structure

Contains configuration information and metadata about a CloudFront function.

Location
Type: string

The URL of the CloudFront function. Use the URL to manage the function with the CloudFront API.

Errors

FunctionAlreadyExists:

A function with the same name already exists in this Amazon Web Services account. To create a function, you must provide a unique name. To update an existing function, use UpdateFunction.

UnsupportedOperation:

This operation is not supported in this region.

FunctionSizeLimitExceeded:

The function is too large. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

TooManyFunctions:

You have reached the maximum number of CloudFront functions for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Examples

Example 1: To create a function

Use the following command to create a function.

$result = $client->createFunction([
    'FunctionCode' => <BLOB>,
    'FunctionConfig' => [
        'Comment' => 'my-function-comment',
        'KeyValueStoreAssociations' => [
            'Items' => [
                [
                    'KeyValueStoreARN' => 'arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
                ],
            ],
            'Quantity' => 1,
        ],
        'Runtime' => 'cloudfront-js-2.0',
    ],
    'Name' => 'my-function-name',
]);

Result syntax:

[
    'ETag' => 'ETVPDKIKX0DER',
    'FunctionSummary' => [
        'FunctionConfig' => [
            'Comment' => 'my-function-comment',
            'KeyValueStoreAssociations' => [
                'Items' => [
                    [
                        'KeyValueStoreARN' => 'arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
                    ],
                ],
                'Quantity' => 1,
            ],
            'Runtime' => 'cloudfront-js-2.0',
        ],
        'FunctionMetadata' => [
            'CreatedTime' => ,
            'FunctionARN' => 'arn:aws:cloudfront::123456789012:function/my-function-name',
            'LastModifiedTime' => ,
            'Stage' => 'DEVELOPMENT',
        ],
        'Name' => 'my-function-name',
        'Status' => 'UNPUBLISHED',
    ],
    'Location' => 'https://cloudfront.amazonaws.com/2020-05-31/function/arn:aws:cloudfront::123456789012:function/my-function-name',
]

CreateInvalidation

$result = $client->createInvalidation([/* ... */]);
$promise = $client->createInvalidationAsync([/* ... */]);

Create a new invalidation. For more information, see Invalidating files in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createInvalidation([
    'DistributionId' => '<string>', // REQUIRED
    'InvalidationBatch' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Paths' => [ // REQUIRED
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
    ],
]);

Parameter Details

Members
DistributionId
Required: Yes
Type: string

The distribution's id.

InvalidationBatch
Required: Yes
Type: InvalidationBatch structure

The batch information for the invalidation.

Result Syntax

[
    'Invalidation' => [
        'CreateTime' => <DateTime>,
        'Id' => '<string>',
        'InvalidationBatch' => [
            'CallerReference' => '<string>',
            'Paths' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
        'Status' => '<string>',
    ],
    'Location' => '<string>',
]

Result Details

Members
Invalidation
Type: Invalidation structure

The invalidation's information.

Location
Type: string

The fully qualified URI of the distribution and invalidation batch request, including the Invalidation ID.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

TooManyInvalidationsInProgress:

You have exceeded the maximum number of allowable InProgress invalidation batch requests, or invalidation objects.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidArgument:

An argument is invalid.

BatchTooLarge:

Invalidation batch specified is too large.

CreateKeyGroup

$result = $client->createKeyGroup([/* ... */]);
$promise = $client->createKeyGroupAsync([/* ... */]);

Creates a key group that you can use with CloudFront signed URLs and signed cookies.

To create a key group, you must specify at least one public key for the key group. After you create a key group, you can reference it from one or more cache behaviors. When you reference a key group in a cache behavior, CloudFront requires signed URLs or signed cookies for all requests that match the cache behavior. The URLs or cookies must be signed with a private key whose corresponding public key is in the key group. The signed URL or cookie contains information about which public key CloudFront should use to verify the signature. For more information, see Serving private content in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createKeyGroup([
    'KeyGroupConfig' => [ // REQUIRED
        'Comment' => '<string>',
        'Items' => ['<string>', ...], // REQUIRED
        'Name' => '<string>', // REQUIRED
    ],
]);

Parameter Details

Members
KeyGroupConfig
Required: Yes
Type: KeyGroupConfig structure

A key group configuration.

Result Syntax

[
    'ETag' => '<string>',
    'KeyGroup' => [
        'Id' => '<string>',
        'KeyGroupConfig' => [
            'Comment' => '<string>',
            'Items' => ['<string>', ...],
            'Name' => '<string>',
        ],
        'LastModifiedTime' => <DateTime>,
    ],
    'Location' => '<string>',
]

Result Details

Members
ETag
Type: string

The identifier for this version of the key group.

KeyGroup
Type: KeyGroup structure

The key group that was just created.

Location
Type: string

The URL of the key group.

Errors

TooManyPublicKeysInKeyGroup:

The number of public keys in this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyKeyGroups:

You have reached the maximum number of key groups for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

KeyGroupAlreadyExists:

A key group with this name already exists. You must provide a unique name. To modify an existing key group, use UpdateKeyGroup.

CreateKeyValueStore

$result = $client->createKeyValueStore([/* ... */]);
$promise = $client->createKeyValueStoreAsync([/* ... */]);

Specifies the key value store resource to add to your account. In your account, the key value store names must be unique. You can also import key value store data in JSON format from an S3 bucket by providing a valid ImportSource that you own.

Parameter Syntax

$result = $client->createKeyValueStore([
    'Comment' => '<string>',
    'ImportSource' => [
        'SourceARN' => '<string>', // REQUIRED
        'SourceType' => 'S3', // REQUIRED
    ],
    'Name' => '<string>', // REQUIRED
]);

Parameter Details

Members
Comment
Type: string

The comment of the key value store.

ImportSource
Type: ImportSource structure

The S3 bucket that provides the source for the import. The source must be in a valid JSON format.

Name
Required: Yes
Type: string

The name of the key value store. The minimum length is 1 character and the maximum length is 64 characters.

Result Syntax

[
    'ETag' => '<string>',
    'KeyValueStore' => [
        'ARN' => '<string>',
        'Comment' => '<string>',
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Name' => '<string>',
        'Status' => '<string>',
    ],
    'Location' => '<string>',
]

Result Details

Members
ETag
Type: string

The ETag in the resulting key value store.

KeyValueStore
Type: KeyValueStore structure

The resulting key value store.

Location
Type: string

The location of the resulting key value store.

Errors

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

EntityAlreadyExists:

The entity already exists. You must provide a unique entity.

InvalidArgument:

An argument is invalid.

EntityLimitExceeded:

The entity limit has been exceeded.

EntitySizeLimitExceeded:

The entity size limit was exceeded.

Examples

Example 1: To create a KeyValueStore

Use the following command to create a KeyValueStore.

$result = $client->createKeyValueStore([
    'Comment' => 'my-key-valuestore-comment',
    'ImportSource' => [
        'SourceARN' => 'arn:aws:s3:::amzn-s3-demo-bucket/validJSON.json',
        'SourceType' => 'S3',
    ],
    'Name' => 'my-keyvaluestore-name',
]);

Result syntax:

[
    'ETag' => 'ETVPDKIKX0DER',
    'KeyValueStore' => [
        'ARN' => 'arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
        'Comment' => 'my-key-valuestore-comment',
        'Id' => '54947df8-0e9e-4471-a2f9-9af509fb5889',
        'LastModifiedTime' => ,
        'Name' => 'my-keyvaluestore-name',
        'Status' => 'PROVISIONING',
    ],
    'Location' => 'https://cloudfront.amazonaws.com/2020-05-31/key-value-store/arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
]

CreateMonitoringSubscription

$result = $client->createMonitoringSubscription([/* ... */]);
$promise = $client->createMonitoringSubscriptionAsync([/* ... */]);

Enables additional CloudWatch metrics for the specified CloudFront distribution. The additional metrics incur an additional cost.

For more information, see Viewing additional CloudFront distribution metrics in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createMonitoringSubscription([
    'DistributionId' => '<string>', // REQUIRED
    'MonitoringSubscription' => [ // REQUIRED
        'RealtimeMetricsSubscriptionConfig' => [
            'RealtimeMetricsSubscriptionStatus' => 'Enabled|Disabled', // REQUIRED
        ],
    ],
]);

Parameter Details

Members
DistributionId
Required: Yes
Type: string

The ID of the distribution that you are enabling metrics for.

MonitoringSubscription
Required: Yes
Type: MonitoringSubscription structure

A monitoring subscription. This structure contains information about whether additional CloudWatch metrics are enabled for a given CloudFront distribution.

Result Syntax

[
    'MonitoringSubscription' => [
        'RealtimeMetricsSubscriptionConfig' => [
            'RealtimeMetricsSubscriptionStatus' => 'Enabled|Disabled',
        ],
    ],
]

Result Details

Members
MonitoringSubscription
Type: MonitoringSubscription structure

A monitoring subscription. This structure contains information about whether additional CloudWatch metrics are enabled for a given CloudFront distribution.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

MonitoringSubscriptionAlreadyExists:

A monitoring subscription already exists for the specified distribution.

UnsupportedOperation:

This operation is not supported in this region.

CreateOriginAccessControl

$result = $client->createOriginAccessControl([/* ... */]);
$promise = $client->createOriginAccessControlAsync([/* ... */]);

Creates a new origin access control in CloudFront. After you create an origin access control, you can add it to an origin in a CloudFront distribution so that CloudFront sends authenticated (signed) requests to the origin.

This makes it possible to block public access to the origin, allowing viewers (users) to access the origin's content only through CloudFront.

For more information about using a CloudFront origin access control, see Restricting access to an Amazon Web Services origin in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createOriginAccessControl([
    'OriginAccessControlConfig' => [ // REQUIRED
        'Description' => '<string>',
        'Name' => '<string>', // REQUIRED
        'OriginAccessControlOriginType' => 's3|mediastore|mediapackagev2|lambda', // REQUIRED
        'SigningBehavior' => 'never|always|no-override', // REQUIRED
        'SigningProtocol' => 'sigv4', // REQUIRED
    ],
]);

Parameter Details

Members
OriginAccessControlConfig
Required: Yes
Type: OriginAccessControlConfig structure

Contains the origin access control.

Result Syntax

[
    'ETag' => '<string>',
    'Location' => '<string>',
    'OriginAccessControl' => [
        'Id' => '<string>',
        'OriginAccessControlConfig' => [
            'Description' => '<string>',
            'Name' => '<string>',
            'OriginAccessControlOriginType' => 's3|mediastore|mediapackagev2|lambda',
            'SigningBehavior' => 'never|always|no-override',
            'SigningProtocol' => 'sigv4',
        ],
    ],
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the origin access control.

Location
Type: string

The URL of the origin access control.

OriginAccessControl
Type: OriginAccessControl structure

Contains an origin access control.

Errors

OriginAccessControlAlreadyExists:

An origin access control with the specified parameters already exists.

TooManyOriginAccessControls:

The number of origin access controls in your Amazon Web Services account exceeds the maximum allowed.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

CreateOriginRequestPolicy

$result = $client->createOriginRequestPolicy([/* ... */]);
$promise = $client->createOriginRequestPolicyAsync([/* ... */]);

Creates an origin request policy.

After you create an origin request policy, you can attach it to one or more cache behaviors. When it's attached to a cache behavior, the origin request policy determines the values that CloudFront includes in requests that it sends to the origin. Each request that CloudFront sends to the origin includes the following:

  • The request body and the URL path (without the domain name) from the viewer request.

  • The headers that CloudFront automatically includes in every origin request, including Host, User-Agent, and X-Amz-Cf-Id.

  • All HTTP headers, cookies, and URL query strings that are specified in the cache policy or the origin request policy. These can include items from the viewer request and, in the case of headers, additional ones that are added by CloudFront.

CloudFront sends a request when it can't find a valid object in its cache that matches the request. If you want to send values to the origin and also include them in the cache key, use CachePolicy.

For more information about origin request policies, see Controlling origin requests in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createOriginRequestPolicy([
    'OriginRequestPolicyConfig' => [ // REQUIRED
        'Comment' => '<string>',
        'CookiesConfig' => [ // REQUIRED
            'CookieBehavior' => 'none|whitelist|all|allExcept', // REQUIRED
            'Cookies' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
        'HeadersConfig' => [ // REQUIRED
            'HeaderBehavior' => 'none|whitelist|allViewer|allViewerAndWhitelistCloudFront|allExcept', // REQUIRED
            'Headers' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
        'Name' => '<string>', // REQUIRED
        'QueryStringsConfig' => [ // REQUIRED
            'QueryStringBehavior' => 'none|whitelist|all|allExcept', // REQUIRED
            'QueryStrings' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
    ],
]);

Parameter Details

Members
OriginRequestPolicyConfig
Required: Yes
Type: OriginRequestPolicyConfig structure

An origin request policy configuration.

Result Syntax

[
    'ETag' => '<string>',
    'Location' => '<string>',
    'OriginRequestPolicy' => [
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'OriginRequestPolicyConfig' => [
            'Comment' => '<string>',
            'CookiesConfig' => [
                'CookieBehavior' => 'none|whitelist|all|allExcept',
                'Cookies' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'HeadersConfig' => [
                'HeaderBehavior' => 'none|whitelist|allViewer|allViewerAndWhitelistCloudFront|allExcept',
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'Name' => '<string>',
            'QueryStringsConfig' => [
                'QueryStringBehavior' => 'none|whitelist|all|allExcept',
                'QueryStrings' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the origin request policy.

Location
Type: string

The fully qualified URI of the origin request policy just created.

OriginRequestPolicy
Type: OriginRequestPolicy structure

An origin request policy.

Errors

AccessDenied:

Access denied.

TooManyHeadersInOriginRequestPolicy:

The number of headers in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyCookiesInOriginRequestPolicy:

The number of cookies in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

OriginRequestPolicyAlreadyExists:

An origin request policy with this name already exists. You must provide a unique name. To modify an existing origin request policy, use UpdateOriginRequestPolicy.

TooManyQueryStringsInOriginRequestPolicy:

The number of query strings in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

TooManyOriginRequestPolicies:

You have reached the maximum number of origin request policies for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

CreatePublicKey

$result = $client->createPublicKey([/* ... */]);
$promise = $client->createPublicKeyAsync([/* ... */]);

Uploads a public key to CloudFront that you can use with signed URLs and signed cookies, or with field-level encryption.

Parameter Syntax

$result = $client->createPublicKey([
    'PublicKeyConfig' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>',
        'EncodedKey' => '<string>', // REQUIRED
        'Name' => '<string>', // REQUIRED
    ],
]);

Parameter Details

Members
PublicKeyConfig
Required: Yes
Type: PublicKeyConfig structure

A CloudFront public key configuration.

Result Syntax

[
    'ETag' => '<string>',
    'Location' => '<string>',
    'PublicKey' => [
        'CreatedTime' => <DateTime>,
        'Id' => '<string>',
        'PublicKeyConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'EncodedKey' => '<string>',
            'Name' => '<string>',
        ],
    ],
]

Result Details

Members
ETag
Type: string

The identifier for this version of the public key.

Location
Type: string

The URL of the public key.

PublicKey
Type: PublicKey structure

The public key.

Errors

TooManyPublicKeys:

The maximum number of public keys for field-level encryption have been created. To create a new public key, delete one of the existing keys.

PublicKeyAlreadyExists:

The specified public key already exists.

InvalidArgument:

An argument is invalid.

CreateRealtimeLogConfig

$result = $client->createRealtimeLogConfig([/* ... */]);
$promise = $client->createRealtimeLogConfigAsync([/* ... */]);

Creates a real-time log configuration.

After you create a real-time log configuration, you can attach it to one or more cache behaviors to send real-time log data to the specified Amazon Kinesis data stream.

For more information about real-time log configurations, see Real-time logs in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createRealtimeLogConfig([
    'EndPoints' => [ // REQUIRED
        [
            'KinesisStreamConfig' => [
                'RoleARN' => '<string>', // REQUIRED
                'StreamARN' => '<string>', // REQUIRED
            ],
            'StreamType' => '<string>', // REQUIRED
        ],
        // ...
    ],
    'Fields' => ['<string>', ...], // REQUIRED
    'Name' => '<string>', // REQUIRED
    'SamplingRate' => <integer>, // REQUIRED
]);

Parameter Details

Members
EndPoints
Required: Yes
Type: Array of EndPoint structures

Contains information about the Amazon Kinesis data stream where you are sending real-time log data.

Fields
Required: Yes
Type: Array of strings

A list of fields to include in each real-time log record.

For more information about fields, see Real-time log configuration fields in the Amazon CloudFront Developer Guide.

Name
Required: Yes
Type: string

A unique name to identify this real-time log configuration.

SamplingRate
Required: Yes
Type: long (int|float)

The sampling rate for this real-time log configuration. You can specify a whole number between 1 and 100 (inclusive) to determine the percentage of viewer requests that are represented in the real-time log data.

Result Syntax

[
    'RealtimeLogConfig' => [
        'ARN' => '<string>',
        'EndPoints' => [
            [
                'KinesisStreamConfig' => [
                    'RoleARN' => '<string>',
                    'StreamARN' => '<string>',
                ],
                'StreamType' => '<string>',
            ],
            // ...
        ],
        'Fields' => ['<string>', ...],
        'Name' => '<string>',
        'SamplingRate' => <integer>,
    ],
]

Result Details

Members
RealtimeLogConfig
Type: RealtimeLogConfig structure

A real-time log configuration.

Errors

AccessDenied:

Access denied.

RealtimeLogConfigAlreadyExists:

A real-time log configuration with this name already exists. You must provide a unique name. To modify an existing real-time log configuration, use UpdateRealtimeLogConfig.

TooManyRealtimeLogConfigs:

You have reached the maximum number of real-time log configurations for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

CreateResponseHeadersPolicy

$result = $client->createResponseHeadersPolicy([/* ... */]);
$promise = $client->createResponseHeadersPolicyAsync([/* ... */]);

Creates a response headers policy.

A response headers policy contains information about a set of HTTP headers. To create a response headers policy, you provide some metadata about the policy and a set of configurations that specify the headers.

After you create a response headers policy, you can use its ID to attach it to one or more cache behaviors in a CloudFront distribution. When it's attached to a cache behavior, the response headers policy affects the HTTP headers that CloudFront includes in HTTP responses to requests that match the cache behavior. CloudFront adds or removes response headers according to the configuration of the response headers policy.

For more information, see Adding or removing HTTP headers in CloudFront responses in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->createResponseHeadersPolicy([
    'ResponseHeadersPolicyConfig' => [ // REQUIRED
        'Comment' => '<string>',
        'CorsConfig' => [
            'AccessControlAllowCredentials' => true || false, // REQUIRED
            'AccessControlAllowHeaders' => [ // REQUIRED
                'Items' => ['<string>', ...], // REQUIRED
                'Quantity' => <integer>, // REQUIRED
            ],
            'AccessControlAllowMethods' => [ // REQUIRED
                'Items' => ['<string>', ...], // REQUIRED
                'Quantity' => <integer>, // REQUIRED
            ],
            'AccessControlAllowOrigins' => [ // REQUIRED
                'Items' => ['<string>', ...], // REQUIRED
                'Quantity' => <integer>, // REQUIRED
            ],
            'AccessControlExposeHeaders' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
            'AccessControlMaxAgeSec' => <integer>,
            'OriginOverride' => true || false, // REQUIRED
        ],
        'CustomHeadersConfig' => [
            'Items' => [
                [
                    'Header' => '<string>', // REQUIRED
                    'Override' => true || false, // REQUIRED
                    'Value' => '<string>', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'Name' => '<string>', // REQUIRED
        'RemoveHeadersConfig' => [
            'Items' => [
                [
                    'Header' => '<string>', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'SecurityHeadersConfig' => [
            'ContentSecurityPolicy' => [
                'ContentSecurityPolicy' => '<string>', // REQUIRED
                'Override' => true || false, // REQUIRED
            ],
            'ContentTypeOptions' => [
                'Override' => true || false, // REQUIRED
            ],
            'FrameOptions' => [
                'FrameOption' => 'DENY|SAMEORIGIN', // REQUIRED
                'Override' => true || false, // REQUIRED
            ],
            'ReferrerPolicy' => [
                'Override' => true || false, // REQUIRED
                'ReferrerPolicy' => 'no-referrer|no-referrer-when-downgrade|origin|origin-when-cross-origin|same-origin|strict-origin|strict-origin-when-cross-origin|unsafe-url', // REQUIRED
            ],
            'StrictTransportSecurity' => [
                'AccessControlMaxAgeSec' => <integer>, // REQUIRED
                'IncludeSubdomains' => true || false,
                'Override' => true || false, // REQUIRED
                'Preload' => true || false,
            ],
            'XSSProtection' => [
                'ModeBlock' => true || false,
                'Override' => true || false, // REQUIRED
                'Protection' => true || false, // REQUIRED
                'ReportUri' => '<string>',
            ],
        ],
        'ServerTimingHeadersConfig' => [
            'Enabled' => true || false, // REQUIRED
            'SamplingRate' => <float>,
        ],
    ],
]);

Parameter Details

Members
ResponseHeadersPolicyConfig
Required: Yes
Type: ResponseHeadersPolicyConfig structure

Contains metadata about the response headers policy, and a set of configurations that specify the HTTP headers.

Result Syntax

[
    'ETag' => '<string>',
    'Location' => '<string>',
    'ResponseHeadersPolicy' => [
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'ResponseHeadersPolicyConfig' => [
            'Comment' => '<string>',
            'CorsConfig' => [
                'AccessControlAllowCredentials' => true || false,
                'AccessControlAllowHeaders' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlAllowMethods' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlAllowOrigins' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlExposeHeaders' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlMaxAgeSec' => <integer>,
                'OriginOverride' => true || false,
            ],
            'CustomHeadersConfig' => [
                'Items' => [
                    [
                        'Header' => '<string>',
                        'Override' => true || false,
                        'Value' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Name' => '<string>',
            'RemoveHeadersConfig' => [
                'Items' => [
                    [
                        'Header' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'SecurityHeadersConfig' => [
                'ContentSecurityPolicy' => [
                    'ContentSecurityPolicy' => '<string>',
                    'Override' => true || false,
                ],
                'ContentTypeOptions' => [
                    'Override' => true || false,
                ],
                'FrameOptions' => [
                    'FrameOption' => 'DENY|SAMEORIGIN',
                    'Override' => true || false,
                ],
                'ReferrerPolicy' => [
                    'Override' => true || false,
                    'ReferrerPolicy' => 'no-referrer|no-referrer-when-downgrade|origin|origin-when-cross-origin|same-origin|strict-origin|strict-origin-when-cross-origin|unsafe-url',
                ],
                'StrictTransportSecurity' => [
                    'AccessControlMaxAgeSec' => <integer>,
                    'IncludeSubdomains' => true || false,
                    'Override' => true || false,
                    'Preload' => true || false,
                ],
                'XSSProtection' => [
                    'ModeBlock' => true || false,
                    'Override' => true || false,
                    'Protection' => true || false,
                    'ReportUri' => '<string>',
                ],
            ],
            'ServerTimingHeadersConfig' => [
                'Enabled' => true || false,
                'SamplingRate' => <float>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the response headers policy.

Location
Type: string

The URL of the response headers policy.

ResponseHeadersPolicy
Type: ResponseHeadersPolicy structure

Contains a response headers policy.

Errors

AccessDenied:

Access denied.

TooManyCustomHeadersInResponseHeadersPolicy:

The number of custom headers in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

ResponseHeadersPolicyAlreadyExists:

A response headers policy with this name already exists. You must provide a unique name. To modify an existing response headers policy, use UpdateResponseHeadersPolicy.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

TooLongCSPInResponseHeadersPolicy:

The length of the Content-Security-Policy header value in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

TooManyRemoveHeadersInResponseHeadersPolicy:

The number of headers in RemoveHeadersConfig in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyResponseHeadersPolicies:

You have reached the maximum number of response headers policies for this Amazon Web Services account.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

CreateStreamingDistribution

$result = $client->createStreamingDistribution([/* ... */]);
$promise = $client->createStreamingDistributionAsync([/* ... */]);

This API is deprecated. Amazon CloudFront is deprecating real-time messaging protocol (RTMP) distributions on December 31, 2020. For more information, read the announcement on the Amazon CloudFront discussion forum.

Parameter Syntax

$result = $client->createStreamingDistribution([
    'StreamingDistributionConfig' => [ // REQUIRED
        'Aliases' => [
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>', // REQUIRED
        'Enabled' => true || false, // REQUIRED
        'Logging' => [
            'Bucket' => '<string>', // REQUIRED
            'Enabled' => true || false, // REQUIRED
            'Prefix' => '<string>', // REQUIRED
        ],
        'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
        'S3Origin' => [ // REQUIRED
            'DomainName' => '<string>', // REQUIRED
            'OriginAccessIdentity' => '<string>', // REQUIRED
        ],
        'TrustedSigners' => [ // REQUIRED
            'Enabled' => true || false, // REQUIRED
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
    ],
]);

Parameter Details

Members
StreamingDistributionConfig
Required: Yes
Type: StreamingDistributionConfig structure

The streaming distribution's configuration information.

Result Syntax

[
    'ETag' => '<string>',
    'Location' => '<string>',
    'StreamingDistribution' => [
        'ARN' => '<string>',
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
        'StreamingDistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'Prefix' => '<string>',
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'S3Origin' => [
                'DomainName' => '<string>',
                'OriginAccessIdentity' => '<string>',
            ],
            'TrustedSigners' => [
                'Enabled' => true || false,
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the streaming distribution created.

Location
Type: string

The fully qualified URI of the new streaming distribution resource just created.

StreamingDistribution
Type: StreamingDistribution structure

The streaming distribution's information.

Errors

AccessDenied:

Access denied.

StreamingDistributionAlreadyExists:

The caller reference you attempted to create the streaming distribution with is associated with another distribution

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidOriginAccessIdentity:

The origin access identity is not valid or doesn't exist.

InvalidArgument:

An argument is invalid.

TooManyTrustedSigners:

Your request contains more trusted signers than are allowed per distribution.

InvalidOriginAccessControl:

The origin access control is not valid.

TooManyStreamingDistributions:

Processing your request would cause you to exceed the maximum number of streaming distributions allowed.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyStreamingDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

TrustedSignerDoesNotExist:

One or more of your trusted signers don't exist.

CNAMEAlreadyExists:

The CNAME specified is already defined for CloudFront.

InvalidOrigin:

The Amazon S3 origin server specified does not refer to a valid Amazon S3 bucket.

CreateStreamingDistributionWithTags

$result = $client->createStreamingDistributionWithTags([/* ... */]);
$promise = $client->createStreamingDistributionWithTagsAsync([/* ... */]);

This API is deprecated. Amazon CloudFront is deprecating real-time messaging protocol (RTMP) distributions on December 31, 2020. For more information, read the announcement on the Amazon CloudFront discussion forum.

Parameter Syntax

$result = $client->createStreamingDistributionWithTags([
    'StreamingDistributionConfigWithTags' => [ // REQUIRED
        'StreamingDistributionConfig' => [ // REQUIRED
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
            'CallerReference' => '<string>', // REQUIRED
            'Comment' => '<string>', // REQUIRED
            'Enabled' => true || false, // REQUIRED
            'Logging' => [
                'Bucket' => '<string>', // REQUIRED
                'Enabled' => true || false, // REQUIRED
                'Prefix' => '<string>', // REQUIRED
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'S3Origin' => [ // REQUIRED
                'DomainName' => '<string>', // REQUIRED
                'OriginAccessIdentity' => '<string>', // REQUIRED
            ],
            'TrustedSigners' => [ // REQUIRED
                'Enabled' => true || false, // REQUIRED
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
        'Tags' => [ // REQUIRED
            'Items' => [
                [
                    'Key' => '<string>', // REQUIRED
                    'Value' => '<string>',
                ],
                // ...
            ],
        ],
    ],
]);

Parameter Details

Members
StreamingDistributionConfigWithTags
Required: Yes
Type: StreamingDistributionConfigWithTags structure

The streaming distribution's configuration information.

Result Syntax

[
    'ETag' => '<string>',
    'Location' => '<string>',
    'StreamingDistribution' => [
        'ARN' => '<string>',
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
        'StreamingDistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'Prefix' => '<string>',
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'S3Origin' => [
                'DomainName' => '<string>',
                'OriginAccessIdentity' => '<string>',
            ],
            'TrustedSigners' => [
                'Enabled' => true || false,
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the distribution created.

Location
Type: string

The fully qualified URI of the new streaming distribution resource just created.

StreamingDistribution
Type: StreamingDistribution structure

The streaming distribution's information.

Errors

AccessDenied:

Access denied.

StreamingDistributionAlreadyExists:

The caller reference you attempted to create the streaming distribution with is associated with another distribution

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidOriginAccessIdentity:

The origin access identity is not valid or doesn't exist.

InvalidTagging:

The tagging specified is not valid.

InvalidArgument:

An argument is invalid.

TooManyTrustedSigners:

Your request contains more trusted signers than are allowed per distribution.

InvalidOriginAccessControl:

The origin access control is not valid.

TooManyStreamingDistributions:

Processing your request would cause you to exceed the maximum number of streaming distributions allowed.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyStreamingDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

TrustedSignerDoesNotExist:

One or more of your trusted signers don't exist.

CNAMEAlreadyExists:

The CNAME specified is already defined for CloudFront.

InvalidOrigin:

The Amazon S3 origin server specified does not refer to a valid Amazon S3 bucket.

CreateVpcOrigin

$result = $client->createVpcOrigin([/* ... */]);
$promise = $client->createVpcOriginAsync([/* ... */]);

Create an Amazon CloudFront VPC origin.

Parameter Syntax

$result = $client->createVpcOrigin([
    'Tags' => [
        'Items' => [
            [
                'Key' => '<string>', // REQUIRED
                'Value' => '<string>',
            ],
            // ...
        ],
    ],
    'VpcOriginEndpointConfig' => [ // REQUIRED
        'Arn' => '<string>', // REQUIRED
        'HTTPPort' => <integer>, // REQUIRED
        'HTTPSPort' => <integer>, // REQUIRED
        'Name' => '<string>', // REQUIRED
        'OriginProtocolPolicy' => 'http-only|match-viewer|https-only', // REQUIRED
        'OriginSslProtocols' => [
            'Items' => ['<string>', ...], // REQUIRED
            'Quantity' => <integer>, // REQUIRED
        ],
    ],
]);

Parameter Details

Members
Tags
Type: Tags structure

A complex type that contains zero or more Tag elements.

VpcOriginEndpointConfig
Required: Yes
Type: VpcOriginEndpointConfig structure

The VPC origin endpoint configuration.

Result Syntax

[
    'ETag' => '<string>',
    'Location' => '<string>',
    'VpcOrigin' => [
        'Arn' => '<string>',
        'CreatedTime' => <DateTime>,
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
        'VpcOriginEndpointConfig' => [
            'Arn' => '<string>',
            'HTTPPort' => <integer>,
            'HTTPSPort' => <integer>,
            'Name' => '<string>',
            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
            'OriginSslProtocols' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The VPC origin ETag.

Location
Type: string

The VPC origin location.

VpcOrigin
Type: VpcOrigin structure

The VPC origin.

Errors

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

EntityAlreadyExists:

The entity already exists. You must provide a unique entity.

InvalidTagging:

The tagging specified is not valid.

InvalidArgument:

An argument is invalid.

EntityLimitExceeded:

The entity limit has been exceeded.

Examples

Example 1: To create a VPC origin

The following command creates a VPC origin:

$result = $client->createVpcOrigin([
    'VpcOriginEndpointConfig' => [
        'Arn' => 'arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/my-alb-us-west-2/e6aa5c7d26415c6d',
        'HTTPPort' => 80,
        'HTTPSPort' => 443,
        'Name' => 'my-vpcorigin-name',
        'OriginProtocolPolicy' => 'match-viewer',
        'OriginSslProtocols' => [
            'Items' => [
                'TLSv1.1',
                'TLSv1.2',
            ],
            'Quantity' => 2,
        ],
    ],
]);

Result syntax:

[
    'ETag' => 'E23ZP02F085DFQ',
    'Location' => 'https://cloudfront.amazonaws.com/2020-05-31/vpc-origin/vo_BQwjxxQxjCaBcQLzJUFkDM',
    'VpcOrigin' => [
        'Arn' => 'arn:aws:cloudfront::123456789012:vpcorigin/vo_BQwjxxQxjCaBcQLzJUFkDM',
        'CreatedTime' => ,
        'Id' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
        'LastModifiedTime' => ,
        'Status' => 'Deploying',
        'VpcOriginEndpointConfig' => [
            'Arn' => 'arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/my-alb-us-west-2/e6aa5c7d26415c6d',
            'HTTPPort' => 80,
            'HTTPSPort' => 443,
            'Name' => 'my-vpcorigin-name',
            'OriginProtocolPolicy' => 'match-viewer',
            'OriginSslProtocols' => [
                'Items' => [
                    'TLSv1.1',
                    'TLSv1.2',
                ],
                'Quantity' => 2,
            ],
        ],
    ],
]

DeleteAnycastIpList

$result = $client->deleteAnycastIpList([/* ... */]);
$promise = $client->deleteAnycastIpListAsync([/* ... */]);

Deletes an Anycast static IP list.

Parameter Syntax

$result = $client->deleteAnycastIpList([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The ID of the Anycast static IP list.

IfMatch
Required: Yes
Type: string

The current version (ETag value) of the Anycast static IP list that you are deleting.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

CannotDeleteEntityWhileInUse:

The entity cannot be deleted while it is in use.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

IllegalDelete:

Deletion is not allowed for this entity.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteCachePolicy

$result = $client->deleteCachePolicy([/* ... */]);
$promise = $client->deleteCachePolicyAsync([/* ... */]);

Deletes a cache policy.

You cannot delete a cache policy if it's attached to a cache behavior. First update your distributions to remove the cache policy from all cache behaviors, then delete the cache policy.

To delete a cache policy, you must provide the policy's identifier and version. To get these values, you can use ListCachePolicies or GetCachePolicy.

Parameter Syntax

$result = $client->deleteCachePolicy([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier for the cache policy that you are deleting. To get the identifier, you can use ListCachePolicies.

IfMatch
Type: string

The version of the cache policy that you are deleting. The version is the cache policy's ETag value, which you can get using ListCachePolicies, GetCachePolicy, or GetCachePolicyConfig.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

NoSuchCachePolicy:

The cache policy does not exist.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

IllegalDelete:

Deletion is not allowed for this entity.

CachePolicyInUse:

Cannot delete the cache policy because it is attached to one or more cache behaviors.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteCloudFrontOriginAccessIdentity

$result = $client->deleteCloudFrontOriginAccessIdentity([/* ... */]);
$promise = $client->deleteCloudFrontOriginAccessIdentityAsync([/* ... */]);

Delete an origin access identity.

Parameter Syntax

$result = $client->deleteCloudFrontOriginAccessIdentity([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The origin access identity's ID.

IfMatch
Type: string

The value of the ETag header you received from a previous GET or PUT request. For example: E2QWRUHAPOMQZL.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

NoSuchCloudFrontOriginAccessIdentity:

The specified origin access identity does not exist.

CloudFrontOriginAccessIdentityInUse:

The Origin Access Identity specified is already in use.

DeleteContinuousDeploymentPolicy

$result = $client->deleteContinuousDeploymentPolicy([/* ... */]);
$promise = $client->deleteContinuousDeploymentPolicyAsync([/* ... */]);

Deletes a continuous deployment policy.

You cannot delete a continuous deployment policy that's attached to a primary distribution. First update your distribution to remove the continuous deployment policy, then you can delete the policy.

Parameter Syntax

$result = $client->deleteContinuousDeploymentPolicy([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the continuous deployment policy that you are deleting.

IfMatch
Type: string

The current version (ETag value) of the continuous deployment policy that you are deleting.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

ContinuousDeploymentPolicyInUse:

You cannot delete a continuous deployment policy that is associated with a primary distribution.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

NoSuchContinuousDeploymentPolicy:

The continuous deployment policy doesn't exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteDistribution

$result = $client->deleteDistribution([/* ... */]);
$promise = $client->deleteDistributionAsync([/* ... */]);

Delete a distribution.

Parameter Syntax

$result = $client->deleteDistribution([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The distribution ID.

IfMatch
Type: string

The value of the ETag header that you received when you disabled the distribution. For example: E2QWRUHAPOMQZL.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

NoSuchDistribution:

The specified distribution does not exist.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

DistributionNotDisabled:

The specified CloudFront distribution is not disabled. You must disable the distribution before you can delete it.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteFieldLevelEncryptionConfig

$result = $client->deleteFieldLevelEncryptionConfig([/* ... */]);
$promise = $client->deleteFieldLevelEncryptionConfigAsync([/* ... */]);

Remove a field-level encryption configuration.

Parameter Syntax

$result = $client->deleteFieldLevelEncryptionConfig([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The ID of the configuration you want to delete from CloudFront.

IfMatch
Type: string

The value of the ETag header that you received when retrieving the configuration identity to delete. For example: E2QWRUHAPOMQZL.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

FieldLevelEncryptionConfigInUse:

The specified configuration for field-level encryption is in use.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteFieldLevelEncryptionProfile

$result = $client->deleteFieldLevelEncryptionProfile([/* ... */]);
$promise = $client->deleteFieldLevelEncryptionProfileAsync([/* ... */]);

Remove a field-level encryption profile.

Parameter Syntax

$result = $client->deleteFieldLevelEncryptionProfile([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

Request the ID of the profile you want to delete from CloudFront.

IfMatch
Type: string

The value of the ETag header that you received when retrieving the profile to delete. For example: E2QWRUHAPOMQZL.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

NoSuchFieldLevelEncryptionProfile:

The specified profile for field-level encryption doesn't exist.

FieldLevelEncryptionProfileInUse:

The specified profile for field-level encryption is in use.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteFunction

$result = $client->deleteFunction([/* ... */]);
$promise = $client->deleteFunctionAsync([/* ... */]);

Deletes a CloudFront function.

You cannot delete a function if it's associated with a cache behavior. First, update your distributions to remove the function association from all cache behaviors, then delete the function.

To delete a function, you must provide the function's name and version (ETag value). To get these values, you can use ListFunctions and DescribeFunction.

Parameter Syntax

$result = $client->deleteFunction([
    'IfMatch' => '<string>', // REQUIRED
    'Name' => '<string>', // REQUIRED
]);

Parameter Details

Members
IfMatch
Required: Yes
Type: string

The current version (ETag value) of the function that you are deleting, which you can get using DescribeFunction.

Name
Required: Yes
Type: string

The name of the function that you are deleting.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

UnsupportedOperation:

This operation is not supported in this region.

FunctionInUse:

Cannot delete the function because it's attached to one or more cache behaviors.

NoSuchFunctionExists:

The function does not exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteKeyGroup

$result = $client->deleteKeyGroup([/* ... */]);
$promise = $client->deleteKeyGroupAsync([/* ... */]);

Deletes a key group.

You cannot delete a key group that is referenced in a cache behavior. First update your distributions to remove the key group from all cache behaviors, then delete the key group.

To delete a key group, you must provide the key group's identifier and version. To get these values, use ListKeyGroups followed by GetKeyGroup or GetKeyGroupConfig.

Parameter Syntax

$result = $client->deleteKeyGroup([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the key group that you are deleting. To get the identifier, use ListKeyGroups.

IfMatch
Type: string

The version of the key group that you are deleting. The version is the key group's ETag value. To get the ETag, use GetKeyGroup or GetKeyGroupConfig.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

ResourceInUse:

Cannot delete this resource because it is in use.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

NoSuchResource:

A resource that was specified is not valid.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteKeyValueStore

$result = $client->deleteKeyValueStore([/* ... */]);
$promise = $client->deleteKeyValueStoreAsync([/* ... */]);

Specifies the key value store to delete.

Parameter Syntax

$result = $client->deleteKeyValueStore([
    'IfMatch' => '<string>', // REQUIRED
    'Name' => '<string>', // REQUIRED
]);

Parameter Details

Members
IfMatch
Required: Yes
Type: string

The key value store to delete, if a match occurs.

Name
Required: Yes
Type: string

The name of the key value store.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

CannotDeleteEntityWhileInUse:

The entity cannot be deleted while it is in use.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

Examples

Example 1: To delete a KeyValueStore

Use the following command to delete a KeyValueStore.

$result = $client->deleteKeyValueStore([
    'IfMatch' => 'ETVPDKIKX0DER',
    'Name' => 'my-keyvaluestore-name',
]);

DeleteMonitoringSubscription

$result = $client->deleteMonitoringSubscription([/* ... */]);
$promise = $client->deleteMonitoringSubscriptionAsync([/* ... */]);

Disables additional CloudWatch metrics for the specified CloudFront distribution.

Parameter Syntax

$result = $client->deleteMonitoringSubscription([
    'DistributionId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DistributionId
Required: Yes
Type: string

The ID of the distribution that you are disabling metrics for.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

NoSuchMonitoringSubscription:

A monitoring subscription does not exist for the specified distribution.

DeleteOriginAccessControl

$result = $client->deleteOriginAccessControl([/* ... */]);
$promise = $client->deleteOriginAccessControlAsync([/* ... */]);

Deletes a CloudFront origin access control.

You cannot delete an origin access control if it's in use. First, update all distributions to remove the origin access control from all origins, then delete the origin access control.

Parameter Syntax

$result = $client->deleteOriginAccessControl([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier of the origin access control that you are deleting.

IfMatch
Type: string

The current version (ETag value) of the origin access control that you are deleting.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

OriginAccessControlInUse:

Cannot delete the origin access control because it's in use by one or more distributions.

NoSuchOriginAccessControl:

The origin access control does not exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteOriginRequestPolicy

$result = $client->deleteOriginRequestPolicy([/* ... */]);
$promise = $client->deleteOriginRequestPolicyAsync([/* ... */]);

Deletes an origin request policy.

You cannot delete an origin request policy if it's attached to any cache behaviors. First update your distributions to remove the origin request policy from all cache behaviors, then delete the origin request policy.

To delete an origin request policy, you must provide the policy's identifier and version. To get the identifier, you can use ListOriginRequestPolicies or GetOriginRequestPolicy.

Parameter Syntax

$result = $client->deleteOriginRequestPolicy([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier for the origin request policy that you are deleting. To get the identifier, you can use ListOriginRequestPolicies.

IfMatch
Type: string

The version of the origin request policy that you are deleting. The version is the origin request policy's ETag value, which you can get using ListOriginRequestPolicies, GetOriginRequestPolicy, or GetOriginRequestPolicyConfig.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

IllegalDelete:

Deletion is not allowed for this entity.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

OriginRequestPolicyInUse:

Cannot delete the origin request policy because it is attached to one or more cache behaviors.

DeletePublicKey

$result = $client->deletePublicKey([/* ... */]);
$promise = $client->deletePublicKeyAsync([/* ... */]);

Remove a public key you previously added to CloudFront.

Parameter Syntax

$result = $client->deletePublicKey([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The ID of the public key you want to remove from CloudFront.

IfMatch
Type: string

The value of the ETag header that you received when retrieving the public key identity to delete. For example: E2QWRUHAPOMQZL.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

NoSuchPublicKey:

The specified public key doesn't exist.

PublicKeyInUse:

The specified public key is in use.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteRealtimeLogConfig

$result = $client->deleteRealtimeLogConfig([/* ... */]);
$promise = $client->deleteRealtimeLogConfigAsync([/* ... */]);

Deletes a real-time log configuration.

You cannot delete a real-time log configuration if it's attached to a cache behavior. First update your distributions to remove the real-time log configuration from all cache behaviors, then delete the real-time log configuration.

To delete a real-time log configuration, you can provide the configuration's name or its Amazon Resource Name (ARN). You must provide at least one. If you provide both, CloudFront uses the name to identify the real-time log configuration to delete.

Parameter Syntax

$result = $client->deleteRealtimeLogConfig([
    'ARN' => '<string>',
    'Name' => '<string>',
]);

Parameter Details

Members
ARN
Type: string

The Amazon Resource Name (ARN) of the real-time log configuration to delete.

Name
Type: string

The name of the real-time log configuration to delete.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

RealtimeLogConfigInUse:

Cannot delete the real-time log configuration because it is attached to one or more cache behaviors.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

DeleteResponseHeadersPolicy

$result = $client->deleteResponseHeadersPolicy([/* ... */]);
$promise = $client->deleteResponseHeadersPolicyAsync([/* ... */]);

Deletes a response headers policy.

You cannot delete a response headers policy if it's attached to a cache behavior. First update your distributions to remove the response headers policy from all cache behaviors, then delete the response headers policy.

To delete a response headers policy, you must provide the policy's identifier and version. To get these values, you can use ListResponseHeadersPolicies or GetResponseHeadersPolicy.

Parameter Syntax

$result = $client->deleteResponseHeadersPolicy([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier for the response headers policy that you are deleting.

To get the identifier, you can use ListResponseHeadersPolicies.

IfMatch
Type: string

The version of the response headers policy that you are deleting.

The version is the response headers policy's ETag value, which you can get using ListResponseHeadersPolicies, GetResponseHeadersPolicy, or GetResponseHeadersPolicyConfig.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

ResponseHeadersPolicyInUse:

Cannot delete the response headers policy because it is attached to one or more cache behaviors in a CloudFront distribution.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

IllegalDelete:

Deletion is not allowed for this entity.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteStreamingDistribution

$result = $client->deleteStreamingDistribution([/* ... */]);
$promise = $client->deleteStreamingDistributionAsync([/* ... */]);

Delete a streaming distribution. To delete an RTMP distribution using the CloudFront API, perform the following steps.

To delete an RTMP distribution using the CloudFront API:

  1. Disable the RTMP distribution.

  2. Submit a GET Streaming Distribution Config request to get the current configuration and the Etag header for the distribution.

  3. Update the XML document that was returned in the response to your GET Streaming Distribution Config request to change the value of Enabled to false.

  4. Submit a PUT Streaming Distribution Config request to update the configuration for your distribution. In the request body, include the XML document that you updated in Step 3. Then set the value of the HTTP If-Match header to the value of the ETag header that CloudFront returned when you submitted the GET Streaming Distribution Config request in Step 2.

  5. Review the response to the PUT Streaming Distribution Config request to confirm that the distribution was successfully disabled.

  6. Submit a GET Streaming Distribution Config request to confirm that your changes have propagated. When propagation is complete, the value of Status is Deployed.

  7. Submit a DELETE Streaming Distribution request. Set the value of the HTTP If-Match header to the value of the ETag header that CloudFront returned when you submitted the GET Streaming Distribution Config request in Step 2.

  8. Review the response to your DELETE Streaming Distribution request to confirm that the distribution was successfully deleted.

For information about deleting a distribution using the CloudFront console, see Deleting a Distribution in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->deleteStreamingDistribution([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The distribution ID.

IfMatch
Type: string

The value of the ETag header that you received when you disabled the streaming distribution. For example: E2QWRUHAPOMQZL.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

StreamingDistributionNotDisabled:

The specified CloudFront distribution is not disabled. You must disable the distribution before you can delete it.

NoSuchStreamingDistribution:

The specified streaming distribution does not exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

DeleteVpcOrigin

$result = $client->deleteVpcOrigin([/* ... */]);
$promise = $client->deleteVpcOriginAsync([/* ... */]);

Delete an Amazon CloudFront VPC origin.

Parameter Syntax

$result = $client->deleteVpcOrigin([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The VPC origin ID.

IfMatch
Required: Yes
Type: string

The VPC origin to delete, if a match occurs.

Result Syntax

[
    'ETag' => '<string>',
    'VpcOrigin' => [
        'Arn' => '<string>',
        'CreatedTime' => <DateTime>,
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
        'VpcOriginEndpointConfig' => [
            'Arn' => '<string>',
            'HTTPPort' => <integer>,
            'HTTPSPort' => <integer>,
            'Name' => '<string>',
            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
            'OriginSslProtocols' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The VPC origin ETag.

VpcOrigin
Type: VpcOrigin structure

The VPC origin.

Errors

CannotDeleteEntityWhileInUse:

The entity cannot be deleted while it is in use.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

IllegalDelete:

Deletion is not allowed for this entity.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

Examples

Example 1: To delete a VPC origin

The following command deletes a VPC origin:

$result = $client->deleteVpcOrigin([
    'Id' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
    'IfMatch' => 'E1F83G8C2ARO7P',
]);

Result syntax:

[
    'ETag' => 'E1PA6795UKMFR9',
    'VpcOrigin' => [
        'Arn' => 'arn:aws:cloudfront::123456789012:vpcorigin/vo_BQwjxxQxjCaBcQLzJUFkDM',
        'CreatedTime' => ,
        'Id' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
        'LastModifiedTime' => ,
        'Status' => 'Deploying',
        'VpcOriginEndpointConfig' => [
            'Arn' => 'arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/my-alb-us-west-2/e6aa5c7d26415c6d',
            'HTTPPort' => 80,
            'HTTPSPort' => 443,
            'Name' => 'my-vpcorigin-name',
            'OriginProtocolPolicy' => 'match-viewer',
            'OriginSslProtocols' => [
                'Items' => [
                    'TLSv1.1',
                    'TLSv1.2',
                ],
                'Quantity' => 2,
            ],
        ],
    ],
]

DescribeFunction

$result = $client->describeFunction([/* ... */]);
$promise = $client->describeFunctionAsync([/* ... */]);

Gets configuration information and metadata about a CloudFront function, but not the function's code. To get a function's code, use GetFunction.

To get configuration information and metadata about a function, you must provide the function's name and stage. To get these values, you can use ListFunctions.

Parameter Syntax

$result = $client->describeFunction([
    'Name' => '<string>', // REQUIRED
    'Stage' => 'DEVELOPMENT|LIVE',
]);

Parameter Details

Members
Name
Required: Yes
Type: string

The name of the function that you are getting information about.

Stage
Type: string

The function's stage, either DEVELOPMENT or LIVE.

Result Syntax

[
    'ETag' => '<string>',
    'FunctionSummary' => [
        'FunctionConfig' => [
            'Comment' => '<string>',
            'KeyValueStoreAssociations' => [
                'Items' => [
                    [
                        'KeyValueStoreARN' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Runtime' => 'cloudfront-js-1.0|cloudfront-js-2.0',
        ],
        'FunctionMetadata' => [
            'CreatedTime' => <DateTime>,
            'FunctionARN' => '<string>',
            'LastModifiedTime' => <DateTime>,
            'Stage' => 'DEVELOPMENT|LIVE',
        ],
        'Name' => '<string>',
        'Status' => '<string>',
    ],
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the CloudFront function.

FunctionSummary
Type: FunctionSummary structure

Contains configuration information and metadata about a CloudFront function.

Errors

UnsupportedOperation:

This operation is not supported in this region.

NoSuchFunctionExists:

The function does not exist.

DescribeKeyValueStore

$result = $client->describeKeyValueStore([/* ... */]);
$promise = $client->describeKeyValueStoreAsync([/* ... */]);

Specifies the key value store and its configuration.

Parameter Syntax

$result = $client->describeKeyValueStore([
    'Name' => '<string>', // REQUIRED
]);

Parameter Details

Members
Name
Required: Yes
Type: string

The name of the key value store.

Result Syntax

[
    'ETag' => '<string>',
    'KeyValueStore' => [
        'ARN' => '<string>',
        'Comment' => '<string>',
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Name' => '<string>',
        'Status' => '<string>',
    ],
]

Result Details

Members
ETag
Type: string

The ETag of the resulting key value store.

KeyValueStore
Type: KeyValueStore structure

The resulting key value store.

Errors

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

Examples

Example 1: To describe a KeyValueStore

Use the following command to describe a KeyValueStore.

$result = $client->describeKeyValueStore([
    'Name' => 'my-keyvaluestore-name',
]);

Result syntax:

[
    'ETag' => 'ETVPDKIKX0DER',
    'KeyValueStore' => [
        'ARN' => 'arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
        'Comment' => 'my-key-valuestore-comment',
        'Id' => '54947df8-0e9e-4471-a2f9-9af509fb5889',
        'LastModifiedTime' => ,
        'Name' => 'my-keyvaluestore-name',
        'Status' => 'READY',
    ],
]

GetAnycastIpList

$result = $client->getAnycastIpList([/* ... */]);
$promise = $client->getAnycastIpListAsync([/* ... */]);

Gets an Anycast static IP list.

Parameter Syntax

$result = $client->getAnycastIpList([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The ID of the Anycast static IP list.

Result Syntax

[
    'AnycastIpList' => [
        'AnycastIps' => ['<string>', ...],
        'Arn' => '<string>',
        'Id' => '<string>',
        'IpCount' => <integer>,
        'LastModifiedTime' => <DateTime>,
        'Name' => '<string>',
        'Status' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
AnycastIpList
Type: AnycastIpList structure

The Anycast static IP list details.

ETag
Type: string

The version identifier for the current version of the Anycast static IP list.

Errors

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

GetCachePolicy

$result = $client->getCachePolicy([/* ... */]);
$promise = $client->getCachePolicyAsync([/* ... */]);

Gets a cache policy, including the following metadata:

  • The policy's identifier.

  • The date and time when the policy was last modified.

To get a cache policy, you must provide the policy's identifier. If the cache policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the cache policy is not attached to a cache behavior, you can get the identifier using ListCachePolicies.

Parameter Syntax

$result = $client->getCachePolicy([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier for the cache policy. If the cache policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the cache policy is not attached to a cache behavior, you can get the identifier using ListCachePolicies.

Result Syntax

[
    'CachePolicy' => [
        'CachePolicyConfig' => [
            'Comment' => '<string>',
            'DefaultTTL' => <integer>,
            'MaxTTL' => <integer>,
            'MinTTL' => <integer>,
            'Name' => '<string>',
            'ParametersInCacheKeyAndForwardedToOrigin' => [
                'CookiesConfig' => [
                    'CookieBehavior' => 'none|whitelist|allExcept|all',
                    'Cookies' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'EnableAcceptEncodingBrotli' => true || false,
                'EnableAcceptEncodingGzip' => true || false,
                'HeadersConfig' => [
                    'HeaderBehavior' => 'none|whitelist',
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'QueryStringsConfig' => [
                    'QueryStringBehavior' => 'none|whitelist|allExcept|all',
                    'QueryStrings' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
    'ETag' => '<string>',
]

Result Details

Members
CachePolicy
Type: CachePolicy structure

The cache policy.

ETag
Type: string

The current version of the cache policy.

Errors

NoSuchCachePolicy:

The cache policy does not exist.

AccessDenied:

Access denied.

GetCachePolicyConfig

$result = $client->getCachePolicyConfig([/* ... */]);
$promise = $client->getCachePolicyConfigAsync([/* ... */]);

Gets a cache policy configuration.

To get a cache policy configuration, you must provide the policy's identifier. If the cache policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the cache policy is not attached to a cache behavior, you can get the identifier using ListCachePolicies.

Parameter Syntax

$result = $client->getCachePolicyConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier for the cache policy. If the cache policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the cache policy is not attached to a cache behavior, you can get the identifier using ListCachePolicies.

Result Syntax

[
    'CachePolicyConfig' => [
        'Comment' => '<string>',
        'DefaultTTL' => <integer>,
        'MaxTTL' => <integer>,
        'MinTTL' => <integer>,
        'Name' => '<string>',
        'ParametersInCacheKeyAndForwardedToOrigin' => [
            'CookiesConfig' => [
                'CookieBehavior' => 'none|whitelist|allExcept|all',
                'Cookies' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'EnableAcceptEncodingBrotli' => true || false,
            'EnableAcceptEncodingGzip' => true || false,
            'HeadersConfig' => [
                'HeaderBehavior' => 'none|whitelist',
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'QueryStringsConfig' => [
                'QueryStringBehavior' => 'none|whitelist|allExcept|all',
                'QueryStrings' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
        ],
    ],
    'ETag' => '<string>',
]

Result Details

Members
CachePolicyConfig
Type: CachePolicyConfig structure

The cache policy configuration.

ETag
Type: string

The current version of the cache policy.

Errors

NoSuchCachePolicy:

The cache policy does not exist.

AccessDenied:

Access denied.

GetCloudFrontOriginAccessIdentity

$result = $client->getCloudFrontOriginAccessIdentity([/* ... */]);
$promise = $client->getCloudFrontOriginAccessIdentityAsync([/* ... */]);

Get the information about an origin access identity.

Parameter Syntax

$result = $client->getCloudFrontOriginAccessIdentity([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identity's ID.

Result Syntax

[
    'CloudFrontOriginAccessIdentity' => [
        'CloudFrontOriginAccessIdentityConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
        ],
        'Id' => '<string>',
        'S3CanonicalUserId' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
CloudFrontOriginAccessIdentity

The origin access identity's information.

ETag
Type: string

The current version of the origin access identity's information. For example: E2QWRUHAPOMQZL.

Errors

AccessDenied:

Access denied.

NoSuchCloudFrontOriginAccessIdentity:

The specified origin access identity does not exist.

GetCloudFrontOriginAccessIdentityConfig

$result = $client->getCloudFrontOriginAccessIdentityConfig([/* ... */]);
$promise = $client->getCloudFrontOriginAccessIdentityConfigAsync([/* ... */]);

Get the configuration information about an origin access identity.

Parameter Syntax

$result = $client->getCloudFrontOriginAccessIdentityConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identity's ID.

Result Syntax

[
    'CloudFrontOriginAccessIdentityConfig' => [
        'CallerReference' => '<string>',
        'Comment' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
CloudFrontOriginAccessIdentityConfig

The origin access identity's configuration information.

ETag
Type: string

The current version of the configuration. For example: E2QWRUHAPOMQZL.

Errors

AccessDenied:

Access denied.

NoSuchCloudFrontOriginAccessIdentity:

The specified origin access identity does not exist.

GetContinuousDeploymentPolicy

$result = $client->getContinuousDeploymentPolicy([/* ... */]);
$promise = $client->getContinuousDeploymentPolicyAsync([/* ... */]);

Gets a continuous deployment policy, including metadata (the policy's identifier and the date and time when the policy was last modified).

Parameter Syntax

$result = $client->getContinuousDeploymentPolicy([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the continuous deployment policy that you are getting.

Result Syntax

[
    'ContinuousDeploymentPolicy' => [
        'ContinuousDeploymentPolicyConfig' => [
            'Enabled' => true || false,
            'StagingDistributionDnsNames' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'TrafficConfig' => [
                'SingleHeaderConfig' => [
                    'Header' => '<string>',
                    'Value' => '<string>',
                ],
                'SingleWeightConfig' => [
                    'SessionStickinessConfig' => [
                        'IdleTTL' => <integer>,
                        'MaximumTTL' => <integer>,
                    ],
                    'Weight' => <float>,
                ],
                'Type' => 'SingleWeight|SingleHeader',
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
    'ETag' => '<string>',
]

Result Details

Members
ContinuousDeploymentPolicy
Type: ContinuousDeploymentPolicy structure

A continuous deployment policy.

ETag
Type: string

The version identifier for the current version of the continuous deployment policy.

Errors

AccessDenied:

Access denied.

NoSuchContinuousDeploymentPolicy:

The continuous deployment policy doesn't exist.

GetContinuousDeploymentPolicyConfig

$result = $client->getContinuousDeploymentPolicyConfig([/* ... */]);
$promise = $client->getContinuousDeploymentPolicyConfigAsync([/* ... */]);

Gets configuration information about a continuous deployment policy.

Parameter Syntax

$result = $client->getContinuousDeploymentPolicyConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the continuous deployment policy whose configuration you are getting.

Result Syntax

[
    'ContinuousDeploymentPolicyConfig' => [
        'Enabled' => true || false,
        'StagingDistributionDnsNames' => [
            'Items' => ['<string>', ...],
            'Quantity' => <integer>,
        ],
        'TrafficConfig' => [
            'SingleHeaderConfig' => [
                'Header' => '<string>',
                'Value' => '<string>',
            ],
            'SingleWeightConfig' => [
                'SessionStickinessConfig' => [
                    'IdleTTL' => <integer>,
                    'MaximumTTL' => <integer>,
                ],
                'Weight' => <float>,
            ],
            'Type' => 'SingleWeight|SingleHeader',
        ],
    ],
    'ETag' => '<string>',
]

Result Details

Members
ContinuousDeploymentPolicyConfig

Contains the configuration for a continuous deployment policy.

ETag
Type: string

The version identifier for the current version of the continuous deployment policy.

Errors

AccessDenied:

Access denied.

NoSuchContinuousDeploymentPolicy:

The continuous deployment policy doesn't exist.

GetDistribution

$result = $client->getDistribution([/* ... */]);
$promise = $client->getDistributionAsync([/* ... */]);

Get the information about a distribution.

Parameter Syntax

$result = $client->getDistribution([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The distribution's ID. If the ID is empty, an empty distribution configuration is returned.

Result Syntax

[
    'Distribution' => [
        'ARN' => '<string>',
        'ActiveTrustedKeyGroups' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'KeyGroupId' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'AliasICPRecordals' => [
            [
                'CNAME' => '<string>',
                'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
            ],
            // ...
        ],
        'DistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AnycastIpListId' => '<string>',
            'CacheBehaviors' => [
                'Items' => [
                    [
                        'AllowedMethods' => [
                            'CachedMethods' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'CachePolicyId' => '<string>',
                        'Compress' => true || false,
                        'DefaultTTL' => <integer>,
                        'FieldLevelEncryptionId' => '<string>',
                        'ForwardedValues' => [
                            'Cookies' => [
                                'Forward' => 'none|whitelist|all',
                                'WhitelistedNames' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Headers' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'QueryString' => true || false,
                            'QueryStringCacheKeys' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'FunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'FunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'GrpcConfig' => [
                            'Enabled' => true || false,
                        ],
                        'LambdaFunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'IncludeBody' => true || false,
                                    'LambdaFunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'MaxTTL' => <integer>,
                        'MinTTL' => <integer>,
                        'OriginRequestPolicyId' => '<string>',
                        'PathPattern' => '<string>',
                        'RealtimeLogConfigArn' => '<string>',
                        'ResponseHeadersPolicyId' => '<string>',
                        'SmoothStreaming' => true || false,
                        'TargetOriginId' => '<string>',
                        'TrustedKeyGroups' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'TrustedSigners' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContinuousDeploymentPolicyId' => '<string>',
            'CustomErrorResponses' => [
                'Items' => [
                    [
                        'ErrorCachingMinTTL' => <integer>,
                        'ErrorCode' => <integer>,
                        'ResponseCode' => '<string>',
                        'ResponsePagePath' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'DefaultCacheBehavior' => [
                'AllowedMethods' => [
                    'CachedMethods' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'CachePolicyId' => '<string>',
                'Compress' => true || false,
                'DefaultTTL' => <integer>,
                'FieldLevelEncryptionId' => '<string>',
                'ForwardedValues' => [
                    'Cookies' => [
                        'Forward' => 'none|whitelist|all',
                        'WhitelistedNames' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'QueryString' => true || false,
                    'QueryStringCacheKeys' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'FunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'FunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'GrpcConfig' => [
                    'Enabled' => true || false,
                ],
                'LambdaFunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'IncludeBody' => true || false,
                            'LambdaFunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'MaxTTL' => <integer>,
                'MinTTL' => <integer>,
                'OriginRequestPolicyId' => '<string>',
                'RealtimeLogConfigArn' => '<string>',
                'ResponseHeadersPolicyId' => '<string>',
                'SmoothStreaming' => true || false,
                'TargetOriginId' => '<string>',
                'TrustedKeyGroups' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'TrustedSigners' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
            ],
            'DefaultRootObject' => '<string>',
            'Enabled' => true || false,
            'HttpVersion' => 'http1.1|http2|http3|http2and3',
            'IsIPV6Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'IncludeCookies' => true || false,
                'Prefix' => '<string>',
            ],
            'OriginGroups' => [
                'Items' => [
                    [
                        'FailoverCriteria' => [
                            'StatusCodes' => [
                                'Items' => [<integer>, ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Id' => '<string>',
                        'Members' => [
                            'Items' => [
                                [
                                    'OriginId' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'SelectionCriteria' => 'default|media-quality-based',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Origins' => [
                'Items' => [
                    [
                        'ConnectionAttempts' => <integer>,
                        'ConnectionTimeout' => <integer>,
                        'CustomHeaders' => [
                            'Items' => [
                                [
                                    'HeaderName' => '<string>',
                                    'HeaderValue' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'CustomOriginConfig' => [
                            'HTTPPort' => <integer>,
                            'HTTPSPort' => <integer>,
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                            'OriginReadTimeout' => <integer>,
                            'OriginSslProtocols' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'DomainName' => '<string>',
                        'Id' => '<string>',
                        'OriginAccessControlId' => '<string>',
                        'OriginPath' => '<string>',
                        'OriginShield' => [
                            'Enabled' => true || false,
                            'OriginShieldRegion' => '<string>',
                        ],
                        'S3OriginConfig' => [
                            'OriginAccessIdentity' => '<string>',
                        ],
                        'VpcOriginConfig' => [
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginReadTimeout' => <integer>,
                            'VpcOriginId' => '<string>',
                        ],
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'Restrictions' => [
                'GeoRestriction' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                    'RestrictionType' => 'blacklist|whitelist|none',
                ],
            ],
            'Staging' => true || false,
            'ViewerCertificate' => [
                'ACMCertificateArn' => '<string>',
                'Certificate' => '<string>',
                'CertificateSource' => 'cloudfront|iam|acm',
                'CloudFrontDefaultCertificate' => true || false,
                'IAMCertificateId' => '<string>',
                'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                'SSLSupportMethod' => 'sni-only|vip|static-ip',
            ],
            'WebACLId' => '<string>',
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'InProgressInvalidationBatches' => <integer>,
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
Distribution
Type: Distribution structure

The distribution's information.

ETag
Type: string

The current version of the distribution's information. For example: E2QWRUHAPOMQZL.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

GetDistributionConfig

$result = $client->getDistributionConfig([/* ... */]);
$promise = $client->getDistributionConfigAsync([/* ... */]);

Get the configuration information about a distribution.

Parameter Syntax

$result = $client->getDistributionConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The distribution's ID. If the ID is empty, an empty distribution configuration is returned.

Result Syntax

[
    'DistributionConfig' => [
        'Aliases' => [
            'Items' => ['<string>', ...],
            'Quantity' => <integer>,
        ],
        'AnycastIpListId' => '<string>',
        'CacheBehaviors' => [
            'Items' => [
                [
                    'AllowedMethods' => [
                        'CachedMethods' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'CachePolicyId' => '<string>',
                    'Compress' => true || false,
                    'DefaultTTL' => <integer>,
                    'FieldLevelEncryptionId' => '<string>',
                    'ForwardedValues' => [
                        'Cookies' => [
                            'Forward' => 'none|whitelist|all',
                            'WhitelistedNames' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Headers' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'QueryString' => true || false,
                        'QueryStringCacheKeys' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'FunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'FunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'GrpcConfig' => [
                        'Enabled' => true || false,
                    ],
                    'LambdaFunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'IncludeBody' => true || false,
                                'LambdaFunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'MaxTTL' => <integer>,
                    'MinTTL' => <integer>,
                    'OriginRequestPolicyId' => '<string>',
                    'PathPattern' => '<string>',
                    'RealtimeLogConfigArn' => '<string>',
                    'ResponseHeadersPolicyId' => '<string>',
                    'SmoothStreaming' => true || false,
                    'TargetOriginId' => '<string>',
                    'TrustedKeyGroups' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'TrustedSigners' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'CallerReference' => '<string>',
        'Comment' => '<string>',
        'ContinuousDeploymentPolicyId' => '<string>',
        'CustomErrorResponses' => [
            'Items' => [
                [
                    'ErrorCachingMinTTL' => <integer>,
                    'ErrorCode' => <integer>,
                    'ResponseCode' => '<string>',
                    'ResponsePagePath' => '<string>',
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'DefaultCacheBehavior' => [
            'AllowedMethods' => [
                'CachedMethods' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'CachePolicyId' => '<string>',
            'Compress' => true || false,
            'DefaultTTL' => <integer>,
            'FieldLevelEncryptionId' => '<string>',
            'ForwardedValues' => [
                'Cookies' => [
                    'Forward' => 'none|whitelist|all',
                    'WhitelistedNames' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'QueryString' => true || false,
                'QueryStringCacheKeys' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'FunctionAssociations' => [
                'Items' => [
                    [
                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                        'FunctionARN' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'GrpcConfig' => [
                'Enabled' => true || false,
            ],
            'LambdaFunctionAssociations' => [
                'Items' => [
                    [
                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                        'IncludeBody' => true || false,
                        'LambdaFunctionARN' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'MaxTTL' => <integer>,
            'MinTTL' => <integer>,
            'OriginRequestPolicyId' => '<string>',
            'RealtimeLogConfigArn' => '<string>',
            'ResponseHeadersPolicyId' => '<string>',
            'SmoothStreaming' => true || false,
            'TargetOriginId' => '<string>',
            'TrustedKeyGroups' => [
                'Enabled' => true || false,
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'TrustedSigners' => [
                'Enabled' => true || false,
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
        ],
        'DefaultRootObject' => '<string>',
        'Enabled' => true || false,
        'HttpVersion' => 'http1.1|http2|http3|http2and3',
        'IsIPV6Enabled' => true || false,
        'Logging' => [
            'Bucket' => '<string>',
            'Enabled' => true || false,
            'IncludeCookies' => true || false,
            'Prefix' => '<string>',
        ],
        'OriginGroups' => [
            'Items' => [
                [
                    'FailoverCriteria' => [
                        'StatusCodes' => [
                            'Items' => [<integer>, ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'Id' => '<string>',
                    'Members' => [
                        'Items' => [
                            [
                                'OriginId' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'SelectionCriteria' => 'default|media-quality-based',
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'Origins' => [
            'Items' => [
                [
                    'ConnectionAttempts' => <integer>,
                    'ConnectionTimeout' => <integer>,
                    'CustomHeaders' => [
                        'Items' => [
                            [
                                'HeaderName' => '<string>',
                                'HeaderValue' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'CustomOriginConfig' => [
                        'HTTPPort' => <integer>,
                        'HTTPSPort' => <integer>,
                        'OriginKeepaliveTimeout' => <integer>,
                        'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                        'OriginReadTimeout' => <integer>,
                        'OriginSslProtocols' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'DomainName' => '<string>',
                    'Id' => '<string>',
                    'OriginAccessControlId' => '<string>',
                    'OriginPath' => '<string>',
                    'OriginShield' => [
                        'Enabled' => true || false,
                        'OriginShieldRegion' => '<string>',
                    ],
                    'S3OriginConfig' => [
                        'OriginAccessIdentity' => '<string>',
                    ],
                    'VpcOriginConfig' => [
                        'OriginKeepaliveTimeout' => <integer>,
                        'OriginReadTimeout' => <integer>,
                        'VpcOriginId' => '<string>',
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
        'Restrictions' => [
            'GeoRestriction' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
                'RestrictionType' => 'blacklist|whitelist|none',
            ],
        ],
        'Staging' => true || false,
        'ViewerCertificate' => [
            'ACMCertificateArn' => '<string>',
            'Certificate' => '<string>',
            'CertificateSource' => 'cloudfront|iam|acm',
            'CloudFrontDefaultCertificate' => true || false,
            'IAMCertificateId' => '<string>',
            'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
            'SSLSupportMethod' => 'sni-only|vip|static-ip',
        ],
        'WebACLId' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
DistributionConfig
Type: DistributionConfig structure

The distribution's configuration information.

ETag
Type: string

The current version of the configuration. For example: E2QWRUHAPOMQZL.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

GetFieldLevelEncryption

$result = $client->getFieldLevelEncryption([/* ... */]);
$promise = $client->getFieldLevelEncryptionAsync([/* ... */]);

Get the field-level encryption configuration information.

Parameter Syntax

$result = $client->getFieldLevelEncryption([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

Request the ID for the field-level encryption configuration information.

Result Syntax

[
    'ETag' => '<string>',
    'FieldLevelEncryption' => [
        'FieldLevelEncryptionConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContentTypeProfileConfig' => [
                'ContentTypeProfiles' => [
                    'Items' => [
                        [
                            'ContentType' => '<string>',
                            'Format' => 'URLEncoded',
                            'ProfileId' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'ForwardWhenContentTypeIsUnknown' => true || false,
            ],
            'QueryArgProfileConfig' => [
                'ForwardWhenQueryArgProfileIsUnknown' => true || false,
                'QueryArgProfiles' => [
                    'Items' => [
                        [
                            'ProfileId' => '<string>',
                            'QueryArg' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
]

Result Details

Members
ETag
Type: string

The current version of the field level encryption configuration. For example: E2QWRUHAPOMQZL.

FieldLevelEncryption
Type: FieldLevelEncryption structure

Return the field-level encryption configuration information.

Errors

AccessDenied:

Access denied.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

GetFieldLevelEncryptionConfig

$result = $client->getFieldLevelEncryptionConfig([/* ... */]);
$promise = $client->getFieldLevelEncryptionConfigAsync([/* ... */]);

Get the field-level encryption configuration information.

Parameter Syntax

$result = $client->getFieldLevelEncryptionConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

Request the ID for the field-level encryption configuration information.

Result Syntax

[
    'ETag' => '<string>',
    'FieldLevelEncryptionConfig' => [
        'CallerReference' => '<string>',
        'Comment' => '<string>',
        'ContentTypeProfileConfig' => [
            'ContentTypeProfiles' => [
                'Items' => [
                    [
                        'ContentType' => '<string>',
                        'Format' => 'URLEncoded',
                        'ProfileId' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'ForwardWhenContentTypeIsUnknown' => true || false,
        ],
        'QueryArgProfileConfig' => [
            'ForwardWhenQueryArgProfileIsUnknown' => true || false,
            'QueryArgProfiles' => [
                'Items' => [
                    [
                        'ProfileId' => '<string>',
                        'QueryArg' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the field level encryption configuration. For example: E2QWRUHAPOMQZL.

FieldLevelEncryptionConfig
Type: FieldLevelEncryptionConfig structure

Return the field-level encryption configuration information.

Errors

AccessDenied:

Access denied.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

GetFieldLevelEncryptionProfile

$result = $client->getFieldLevelEncryptionProfile([/* ... */]);
$promise = $client->getFieldLevelEncryptionProfileAsync([/* ... */]);

Get the field-level encryption profile information.

Parameter Syntax

$result = $client->getFieldLevelEncryptionProfile([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

Get the ID for the field-level encryption profile information.

Result Syntax

[
    'ETag' => '<string>',
    'FieldLevelEncryptionProfile' => [
        'FieldLevelEncryptionProfileConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'EncryptionEntities' => [
                'Items' => [
                    [
                        'FieldPatterns' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ProviderId' => '<string>',
                        'PublicKeyId' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Name' => '<string>',
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
]

Result Details

Members
ETag
Type: string

The current version of the field level encryption profile. For example: E2QWRUHAPOMQZL.

FieldLevelEncryptionProfile
Type: FieldLevelEncryptionProfile structure

Return the field-level encryption profile information.

Errors

AccessDenied:

Access denied.

NoSuchFieldLevelEncryptionProfile:

The specified profile for field-level encryption doesn't exist.

GetFieldLevelEncryptionProfileConfig

$result = $client->getFieldLevelEncryptionProfileConfig([/* ... */]);
$promise = $client->getFieldLevelEncryptionProfileConfigAsync([/* ... */]);

Get the field-level encryption profile configuration information.

Parameter Syntax

$result = $client->getFieldLevelEncryptionProfileConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

Get the ID for the field-level encryption profile configuration information.

Result Syntax

[
    'ETag' => '<string>',
    'FieldLevelEncryptionProfileConfig' => [
        'CallerReference' => '<string>',
        'Comment' => '<string>',
        'EncryptionEntities' => [
            'Items' => [
                [
                    'FieldPatterns' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'ProviderId' => '<string>',
                    'PublicKeyId' => '<string>',
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'Name' => '<string>',
    ],
]

Result Details

Members
ETag
Type: string

The current version of the field-level encryption profile configuration result. For example: E2QWRUHAPOMQZL.

FieldLevelEncryptionProfileConfig

Return the field-level encryption profile configuration information.

Errors

AccessDenied:

Access denied.

NoSuchFieldLevelEncryptionProfile:

The specified profile for field-level encryption doesn't exist.

GetFunction

$result = $client->getFunction([/* ... */]);
$promise = $client->getFunctionAsync([/* ... */]);

Gets the code of a CloudFront function. To get configuration information and metadata about a function, use DescribeFunction.

To get a function's code, you must provide the function's name and stage. To get these values, you can use ListFunctions.

Parameter Syntax

$result = $client->getFunction([
    'Name' => '<string>', // REQUIRED
    'Stage' => 'DEVELOPMENT|LIVE',
]);

Parameter Details

Members
Name
Required: Yes
Type: string

The name of the function whose code you are getting.

Stage
Type: string

The function's stage, either DEVELOPMENT or LIVE.

Result Syntax

[
    'ContentType' => '<string>',
    'ETag' => '<string>',
    'FunctionCode' => <string || resource || Psr\Http\Message\StreamInterface>,
]

Result Details

Members
ContentType
Type: string

The content type (media type) of the response.

ETag
Type: string

The version identifier for the current version of the CloudFront function.

FunctionCode
Type: blob (string|resource|Psr\Http\Message\StreamInterface)

The function code of a CloudFront function.

Errors

UnsupportedOperation:

This operation is not supported in this region.

NoSuchFunctionExists:

The function does not exist.

GetInvalidation

$result = $client->getInvalidation([/* ... */]);
$promise = $client->getInvalidationAsync([/* ... */]);

Get the information about an invalidation.

Parameter Syntax

$result = $client->getInvalidation([
    'DistributionId' => '<string>', // REQUIRED
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
DistributionId
Required: Yes
Type: string

The distribution's ID.

Id
Required: Yes
Type: string

The identifier for the invalidation request, for example, IDFDVBD632BHDS5.

Result Syntax

[
    'Invalidation' => [
        'CreateTime' => <DateTime>,
        'Id' => '<string>',
        'InvalidationBatch' => [
            'CallerReference' => '<string>',
            'Paths' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
        'Status' => '<string>',
    ],
]

Result Details

Members
Invalidation
Type: Invalidation structure

The invalidation's information. For more information, see Invalidation Complex Type.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

NoSuchInvalidation:

The specified invalidation does not exist.

GetKeyGroup

$result = $client->getKeyGroup([/* ... */]);
$promise = $client->getKeyGroupAsync([/* ... */]);

Gets a key group, including the date and time when the key group was last modified.

To get a key group, you must provide the key group's identifier. If the key group is referenced in a distribution's cache behavior, you can get the key group's identifier using ListDistributions or GetDistribution. If the key group is not referenced in a cache behavior, you can get the identifier using ListKeyGroups.

Parameter Syntax

$result = $client->getKeyGroup([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the key group that you are getting. To get the identifier, use ListKeyGroups.

Result Syntax

[
    'ETag' => '<string>',
    'KeyGroup' => [
        'Id' => '<string>',
        'KeyGroupConfig' => [
            'Comment' => '<string>',
            'Items' => ['<string>', ...],
            'Name' => '<string>',
        ],
        'LastModifiedTime' => <DateTime>,
    ],
]

Result Details

Members
ETag
Type: string

The identifier for this version of the key group.

KeyGroup
Type: KeyGroup structure

The key group.

Errors

NoSuchResource:

A resource that was specified is not valid.

GetKeyGroupConfig

$result = $client->getKeyGroupConfig([/* ... */]);
$promise = $client->getKeyGroupConfigAsync([/* ... */]);

Gets a key group configuration.

To get a key group configuration, you must provide the key group's identifier. If the key group is referenced in a distribution's cache behavior, you can get the key group's identifier using ListDistributions or GetDistribution. If the key group is not referenced in a cache behavior, you can get the identifier using ListKeyGroups.

Parameter Syntax

$result = $client->getKeyGroupConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the key group whose configuration you are getting. To get the identifier, use ListKeyGroups.

Result Syntax

[
    'ETag' => '<string>',
    'KeyGroupConfig' => [
        'Comment' => '<string>',
        'Items' => ['<string>', ...],
        'Name' => '<string>',
    ],
]

Result Details

Members
ETag
Type: string

The identifier for this version of the key group.

KeyGroupConfig
Type: KeyGroupConfig structure

The key group configuration.

Errors

NoSuchResource:

A resource that was specified is not valid.

GetMonitoringSubscription

$result = $client->getMonitoringSubscription([/* ... */]);
$promise = $client->getMonitoringSubscriptionAsync([/* ... */]);

Gets information about whether additional CloudWatch metrics are enabled for the specified CloudFront distribution.

Parameter Syntax

$result = $client->getMonitoringSubscription([
    'DistributionId' => '<string>', // REQUIRED
]);

Parameter Details

Members
DistributionId
Required: Yes
Type: string

The ID of the distribution that you are getting metrics information for.

Result Syntax

[
    'MonitoringSubscription' => [
        'RealtimeMetricsSubscriptionConfig' => [
            'RealtimeMetricsSubscriptionStatus' => 'Enabled|Disabled',
        ],
    ],
]

Result Details

Members
MonitoringSubscription
Type: MonitoringSubscription structure

A monitoring subscription. This structure contains information about whether additional CloudWatch metrics are enabled for a given CloudFront distribution.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

NoSuchMonitoringSubscription:

A monitoring subscription does not exist for the specified distribution.

GetOriginAccessControl

$result = $client->getOriginAccessControl([/* ... */]);
$promise = $client->getOriginAccessControlAsync([/* ... */]);

Gets a CloudFront origin access control, including its unique identifier.

Parameter Syntax

$result = $client->getOriginAccessControl([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier of the origin access control.

Result Syntax

[
    'ETag' => '<string>',
    'OriginAccessControl' => [
        'Id' => '<string>',
        'OriginAccessControlConfig' => [
            'Description' => '<string>',
            'Name' => '<string>',
            'OriginAccessControlOriginType' => 's3|mediastore|mediapackagev2|lambda',
            'SigningBehavior' => 'never|always|no-override',
            'SigningProtocol' => 'sigv4',
        ],
    ],
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the origin access control.

OriginAccessControl
Type: OriginAccessControl structure

Contains an origin access control, including its unique identifier.

Errors

AccessDenied:

Access denied.

NoSuchOriginAccessControl:

The origin access control does not exist.

GetOriginAccessControlConfig

$result = $client->getOriginAccessControlConfig([/* ... */]);
$promise = $client->getOriginAccessControlConfigAsync([/* ... */]);

Gets a CloudFront origin access control configuration.

Parameter Syntax

$result = $client->getOriginAccessControlConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier of the origin access control.

Result Syntax

[
    'ETag' => '<string>',
    'OriginAccessControlConfig' => [
        'Description' => '<string>',
        'Name' => '<string>',
        'OriginAccessControlOriginType' => 's3|mediastore|mediapackagev2|lambda',
        'SigningBehavior' => 'never|always|no-override',
        'SigningProtocol' => 'sigv4',
    ],
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the origin access control.

OriginAccessControlConfig
Type: OriginAccessControlConfig structure

Contains an origin access control configuration.

Errors

AccessDenied:

Access denied.

NoSuchOriginAccessControl:

The origin access control does not exist.

GetOriginRequestPolicy

$result = $client->getOriginRequestPolicy([/* ... */]);
$promise = $client->getOriginRequestPolicyAsync([/* ... */]);

Gets an origin request policy, including the following metadata:

  • The policy's identifier.

  • The date and time when the policy was last modified.

To get an origin request policy, you must provide the policy's identifier. If the origin request policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the origin request policy is not attached to a cache behavior, you can get the identifier using ListOriginRequestPolicies.

Parameter Syntax

$result = $client->getOriginRequestPolicy([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier for the origin request policy. If the origin request policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the origin request policy is not attached to a cache behavior, you can get the identifier using ListOriginRequestPolicies.

Result Syntax

[
    'ETag' => '<string>',
    'OriginRequestPolicy' => [
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'OriginRequestPolicyConfig' => [
            'Comment' => '<string>',
            'CookiesConfig' => [
                'CookieBehavior' => 'none|whitelist|all|allExcept',
                'Cookies' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'HeadersConfig' => [
                'HeaderBehavior' => 'none|whitelist|allViewer|allViewerAndWhitelistCloudFront|allExcept',
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'Name' => '<string>',
            'QueryStringsConfig' => [
                'QueryStringBehavior' => 'none|whitelist|all|allExcept',
                'QueryStrings' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the origin request policy.

OriginRequestPolicy
Type: OriginRequestPolicy structure

The origin request policy.

Errors

AccessDenied:

Access denied.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

GetOriginRequestPolicyConfig

$result = $client->getOriginRequestPolicyConfig([/* ... */]);
$promise = $client->getOriginRequestPolicyConfigAsync([/* ... */]);

Gets an origin request policy configuration.

To get an origin request policy configuration, you must provide the policy's identifier. If the origin request policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the origin request policy is not attached to a cache behavior, you can get the identifier using ListOriginRequestPolicies.

Parameter Syntax

$result = $client->getOriginRequestPolicyConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier for the origin request policy. If the origin request policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the origin request policy is not attached to a cache behavior, you can get the identifier using ListOriginRequestPolicies.

Result Syntax

[
    'ETag' => '<string>',
    'OriginRequestPolicyConfig' => [
        'Comment' => '<string>',
        'CookiesConfig' => [
            'CookieBehavior' => 'none|whitelist|all|allExcept',
            'Cookies' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
        'HeadersConfig' => [
            'HeaderBehavior' => 'none|whitelist|allViewer|allViewerAndWhitelistCloudFront|allExcept',
            'Headers' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
        'Name' => '<string>',
        'QueryStringsConfig' => [
            'QueryStringBehavior' => 'none|whitelist|all|allExcept',
            'QueryStrings' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the origin request policy.

OriginRequestPolicyConfig
Type: OriginRequestPolicyConfig structure

The origin request policy configuration.

Errors

AccessDenied:

Access denied.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

GetPublicKey

$result = $client->getPublicKey([/* ... */]);
$promise = $client->getPublicKeyAsync([/* ... */]);

Gets a public key.

Parameter Syntax

$result = $client->getPublicKey([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the public key you are getting.

Result Syntax

[
    'ETag' => '<string>',
    'PublicKey' => [
        'CreatedTime' => <DateTime>,
        'Id' => '<string>',
        'PublicKeyConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'EncodedKey' => '<string>',
            'Name' => '<string>',
        ],
    ],
]

Result Details

Members
ETag
Type: string

The identifier for this version of the public key.

PublicKey
Type: PublicKey structure

The public key.

Errors

AccessDenied:

Access denied.

NoSuchPublicKey:

The specified public key doesn't exist.

GetPublicKeyConfig

$result = $client->getPublicKeyConfig([/* ... */]);
$promise = $client->getPublicKeyConfigAsync([/* ... */]);

Gets a public key configuration.

Parameter Syntax

$result = $client->getPublicKeyConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the public key whose configuration you are getting.

Result Syntax

[
    'ETag' => '<string>',
    'PublicKeyConfig' => [
        'CallerReference' => '<string>',
        'Comment' => '<string>',
        'EncodedKey' => '<string>',
        'Name' => '<string>',
    ],
]

Result Details

Members
ETag
Type: string

The identifier for this version of the public key configuration.

PublicKeyConfig
Type: PublicKeyConfig structure

A public key configuration.

Errors

AccessDenied:

Access denied.

NoSuchPublicKey:

The specified public key doesn't exist.

GetRealtimeLogConfig

$result = $client->getRealtimeLogConfig([/* ... */]);
$promise = $client->getRealtimeLogConfigAsync([/* ... */]);

Gets a real-time log configuration.

To get a real-time log configuration, you can provide the configuration's name or its Amazon Resource Name (ARN). You must provide at least one. If you provide both, CloudFront uses the name to identify the real-time log configuration to get.

Parameter Syntax

$result = $client->getRealtimeLogConfig([
    'ARN' => '<string>',
    'Name' => '<string>',
]);

Parameter Details

Members
ARN
Type: string

The Amazon Resource Name (ARN) of the real-time log configuration to get.

Name
Type: string

The name of the real-time log configuration to get.

Result Syntax

[
    'RealtimeLogConfig' => [
        'ARN' => '<string>',
        'EndPoints' => [
            [
                'KinesisStreamConfig' => [
                    'RoleARN' => '<string>',
                    'StreamARN' => '<string>',
                ],
                'StreamType' => '<string>',
            ],
            // ...
        ],
        'Fields' => ['<string>', ...],
        'Name' => '<string>',
        'SamplingRate' => <integer>,
    ],
]

Result Details

Members
RealtimeLogConfig
Type: RealtimeLogConfig structure

A real-time log configuration.

Errors

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

GetResponseHeadersPolicy

$result = $client->getResponseHeadersPolicy([/* ... */]);
$promise = $client->getResponseHeadersPolicyAsync([/* ... */]);

Gets a response headers policy, including metadata (the policy's identifier and the date and time when the policy was last modified).

To get a response headers policy, you must provide the policy's identifier. If the response headers policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the response headers policy is not attached to a cache behavior, you can get the identifier using ListResponseHeadersPolicies.

Parameter Syntax

$result = $client->getResponseHeadersPolicy([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier for the response headers policy.

If the response headers policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the response headers policy is not attached to a cache behavior, you can get the identifier using ListResponseHeadersPolicies.

Result Syntax

[
    'ETag' => '<string>',
    'ResponseHeadersPolicy' => [
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'ResponseHeadersPolicyConfig' => [
            'Comment' => '<string>',
            'CorsConfig' => [
                'AccessControlAllowCredentials' => true || false,
                'AccessControlAllowHeaders' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlAllowMethods' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlAllowOrigins' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlExposeHeaders' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlMaxAgeSec' => <integer>,
                'OriginOverride' => true || false,
            ],
            'CustomHeadersConfig' => [
                'Items' => [
                    [
                        'Header' => '<string>',
                        'Override' => true || false,
                        'Value' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Name' => '<string>',
            'RemoveHeadersConfig' => [
                'Items' => [
                    [
                        'Header' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'SecurityHeadersConfig' => [
                'ContentSecurityPolicy' => [
                    'ContentSecurityPolicy' => '<string>',
                    'Override' => true || false,
                ],
                'ContentTypeOptions' => [
                    'Override' => true || false,
                ],
                'FrameOptions' => [
                    'FrameOption' => 'DENY|SAMEORIGIN',
                    'Override' => true || false,
                ],
                'ReferrerPolicy' => [
                    'Override' => true || false,
                    'ReferrerPolicy' => 'no-referrer|no-referrer-when-downgrade|origin|origin-when-cross-origin|same-origin|strict-origin|strict-origin-when-cross-origin|unsafe-url',
                ],
                'StrictTransportSecurity' => [
                    'AccessControlMaxAgeSec' => <integer>,
                    'IncludeSubdomains' => true || false,
                    'Override' => true || false,
                    'Preload' => true || false,
                ],
                'XSSProtection' => [
                    'ModeBlock' => true || false,
                    'Override' => true || false,
                    'Protection' => true || false,
                    'ReportUri' => '<string>',
                ],
            ],
            'ServerTimingHeadersConfig' => [
                'Enabled' => true || false,
                'SamplingRate' => <float>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the response headers policy.

ResponseHeadersPolicy
Type: ResponseHeadersPolicy structure

Contains a response headers policy.

Errors

AccessDenied:

Access denied.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

GetResponseHeadersPolicyConfig

$result = $client->getResponseHeadersPolicyConfig([/* ... */]);
$promise = $client->getResponseHeadersPolicyConfigAsync([/* ... */]);

Gets a response headers policy configuration.

To get a response headers policy configuration, you must provide the policy's identifier. If the response headers policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the response headers policy is not attached to a cache behavior, you can get the identifier using ListResponseHeadersPolicies.

Parameter Syntax

$result = $client->getResponseHeadersPolicyConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier for the response headers policy.

If the response headers policy is attached to a distribution's cache behavior, you can get the policy's identifier using ListDistributions or GetDistribution. If the response headers policy is not attached to a cache behavior, you can get the identifier using ListResponseHeadersPolicies.

Result Syntax

[
    'ETag' => '<string>',
    'ResponseHeadersPolicyConfig' => [
        'Comment' => '<string>',
        'CorsConfig' => [
            'AccessControlAllowCredentials' => true || false,
            'AccessControlAllowHeaders' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AccessControlAllowMethods' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AccessControlAllowOrigins' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AccessControlExposeHeaders' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AccessControlMaxAgeSec' => <integer>,
            'OriginOverride' => true || false,
        ],
        'CustomHeadersConfig' => [
            'Items' => [
                [
                    'Header' => '<string>',
                    'Override' => true || false,
                    'Value' => '<string>',
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'Name' => '<string>',
        'RemoveHeadersConfig' => [
            'Items' => [
                [
                    'Header' => '<string>',
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'SecurityHeadersConfig' => [
            'ContentSecurityPolicy' => [
                'ContentSecurityPolicy' => '<string>',
                'Override' => true || false,
            ],
            'ContentTypeOptions' => [
                'Override' => true || false,
            ],
            'FrameOptions' => [
                'FrameOption' => 'DENY|SAMEORIGIN',
                'Override' => true || false,
            ],
            'ReferrerPolicy' => [
                'Override' => true || false,
                'ReferrerPolicy' => 'no-referrer|no-referrer-when-downgrade|origin|origin-when-cross-origin|same-origin|strict-origin|strict-origin-when-cross-origin|unsafe-url',
            ],
            'StrictTransportSecurity' => [
                'AccessControlMaxAgeSec' => <integer>,
                'IncludeSubdomains' => true || false,
                'Override' => true || false,
                'Preload' => true || false,
            ],
            'XSSProtection' => [
                'ModeBlock' => true || false,
                'Override' => true || false,
                'Protection' => true || false,
                'ReportUri' => '<string>',
            ],
        ],
        'ServerTimingHeadersConfig' => [
            'Enabled' => true || false,
            'SamplingRate' => <float>,
        ],
    ],
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the response headers policy.

ResponseHeadersPolicyConfig
Type: ResponseHeadersPolicyConfig structure

Contains a response headers policy.

Errors

AccessDenied:

Access denied.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

GetStreamingDistribution

$result = $client->getStreamingDistribution([/* ... */]);
$promise = $client->getStreamingDistributionAsync([/* ... */]);

Gets information about a specified RTMP distribution, including the distribution configuration.

Parameter Syntax

$result = $client->getStreamingDistribution([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The streaming distribution's ID.

Result Syntax

[
    'ETag' => '<string>',
    'StreamingDistribution' => [
        'ARN' => '<string>',
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
        'StreamingDistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'Prefix' => '<string>',
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'S3Origin' => [
                'DomainName' => '<string>',
                'OriginAccessIdentity' => '<string>',
            ],
            'TrustedSigners' => [
                'Enabled' => true || false,
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the streaming distribution's information. For example: E2QWRUHAPOMQZL.

StreamingDistribution
Type: StreamingDistribution structure

The streaming distribution's information.

Errors

AccessDenied:

Access denied.

NoSuchStreamingDistribution:

The specified streaming distribution does not exist.

GetStreamingDistributionConfig

$result = $client->getStreamingDistributionConfig([/* ... */]);
$promise = $client->getStreamingDistributionConfigAsync([/* ... */]);

Get the configuration information about a streaming distribution.

Parameter Syntax

$result = $client->getStreamingDistributionConfig([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The streaming distribution's ID.

Result Syntax

[
    'ETag' => '<string>',
    'StreamingDistributionConfig' => [
        'Aliases' => [
            'Items' => ['<string>', ...],
            'Quantity' => <integer>,
        ],
        'CallerReference' => '<string>',
        'Comment' => '<string>',
        'Enabled' => true || false,
        'Logging' => [
            'Bucket' => '<string>',
            'Enabled' => true || false,
            'Prefix' => '<string>',
        ],
        'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
        'S3Origin' => [
            'DomainName' => '<string>',
            'OriginAccessIdentity' => '<string>',
        ],
        'TrustedSigners' => [
            'Enabled' => true || false,
            'Items' => ['<string>', ...],
            'Quantity' => <integer>,
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the configuration. For example: E2QWRUHAPOMQZL.

StreamingDistributionConfig
Type: StreamingDistributionConfig structure

The streaming distribution's configuration information.

Errors

AccessDenied:

Access denied.

NoSuchStreamingDistribution:

The specified streaming distribution does not exist.

GetVpcOrigin

$result = $client->getVpcOrigin([/* ... */]);
$promise = $client->getVpcOriginAsync([/* ... */]);

Get the details of an Amazon CloudFront VPC origin.

Parameter Syntax

$result = $client->getVpcOrigin([
    'Id' => '<string>', // REQUIRED
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The VPC origin ID.

Result Syntax

[
    'ETag' => '<string>',
    'VpcOrigin' => [
        'Arn' => '<string>',
        'CreatedTime' => <DateTime>,
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
        'VpcOriginEndpointConfig' => [
            'Arn' => '<string>',
            'HTTPPort' => <integer>,
            'HTTPSPort' => <integer>,
            'Name' => '<string>',
            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
            'OriginSslProtocols' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The VPC origin ETag.

VpcOrigin
Type: VpcOrigin structure

The VPC origin.

Errors

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

Examples

Example 1: To get a VPC origin

The following command gets a VPC origin:

$result = $client->getVpcOrigin([
    'Id' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
]);

Result syntax:

[
    'ETag' => 'ETVPDKIKX0DER',
    'VpcOrigin' => [
        'Arn' => 'arn:aws:cloudfront::123456789012:vpcorigin/vo_BQwjxxQxjCaBcQLzJUFkDM',
        'CreatedTime' => ,
        'Id' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
        'LastModifiedTime' => ,
        'Status' => 'Deployed',
        'VpcOriginEndpointConfig' => [
            'Arn' => 'arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/my-alb-us-west-2/e6aa5c7d26415c6d',
            'HTTPPort' => 80,
            'HTTPSPort' => 443,
            'Name' => 'my-vpcorigin-name',
            'OriginProtocolPolicy' => 'match-viewer',
            'OriginSslProtocols' => [
                'Items' => [
                    'TLSv1.1',
                    'TLSv1.2',
                ],
                'Quantity' => 2,
            ],
        ],
    ],
]

ListAnycastIpLists

$result = $client->listAnycastIpLists([/* ... */]);
$promise = $client->listAnycastIpListsAsync([/* ... */]);

Lists your Anycast static IP lists.

Parameter Syntax

$result = $client->listAnycastIpLists([
    'Marker' => '<string>',
    'MaxItems' => <integer>,
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list. The response includes items in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: int

The maximum number of Anycast static IP lists that you want returned in the response.

Result Syntax

[
    'AnycastIpLists' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'Arn' => '<string>',
                'Id' => '<string>',
                'IpCount' => <integer>,
                'LastModifiedTime' => <DateTime>,
                'Name' => '<string>',
                'Status' => '<string>',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
AnycastIpLists
Type: AnycastIpListCollection structure

Root level tag for the AnycastIpLists parameters.

Errors

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

ListCachePolicies

$result = $client->listCachePolicies([/* ... */]);
$promise = $client->listCachePoliciesAsync([/* ... */]);

Gets a list of cache policies.

You can optionally apply a filter to return only the managed policies created by Amazon Web Services, or only the custom policies created in your Amazon Web Services account.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listCachePolicies([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'Type' => 'managed|custom',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of cache policies. The response includes cache policies in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of cache policies that you want in the response.

Type
Type: string

A filter to return only the specified kinds of cache policies. Valid values are:

  • managed – Returns only the managed policies created by Amazon Web Services.

  • custom – Returns only the custom policies created in your Amazon Web Services account.

Result Syntax

[
    'CachePolicyList' => [
        'Items' => [
            [
                'CachePolicy' => [
                    'CachePolicyConfig' => [
                        'Comment' => '<string>',
                        'DefaultTTL' => <integer>,
                        'MaxTTL' => <integer>,
                        'MinTTL' => <integer>,
                        'Name' => '<string>',
                        'ParametersInCacheKeyAndForwardedToOrigin' => [
                            'CookiesConfig' => [
                                'CookieBehavior' => 'none|whitelist|allExcept|all',
                                'Cookies' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'EnableAcceptEncodingBrotli' => true || false,
                            'EnableAcceptEncodingGzip' => true || false,
                            'HeadersConfig' => [
                                'HeaderBehavior' => 'none|whitelist',
                                'Headers' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'QueryStringsConfig' => [
                                'QueryStringBehavior' => 'none|whitelist|allExcept|all',
                                'QueryStrings' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                        ],
                    ],
                    'Id' => '<string>',
                    'LastModifiedTime' => <DateTime>,
                ],
                'Type' => 'managed|custom',
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
CachePolicyList
Type: CachePolicyList structure

A list of cache policies.

Errors

NoSuchCachePolicy:

The cache policy does not exist.

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

ListCloudFrontOriginAccessIdentities

$result = $client->listCloudFrontOriginAccessIdentities([/* ... */]);
$promise = $client->listCloudFrontOriginAccessIdentitiesAsync([/* ... */]);

Lists origin access identities.

Parameter Syntax

$result = $client->listCloudFrontOriginAccessIdentities([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this when paginating results to indicate where to begin in your list of origin access identities. The results include identities in the list that occur after the marker. To get the next page of results, set the Marker to the value of the NextMarker from the current page's response (which is also the ID of the last identity on that page).

MaxItems
Type: string

The maximum number of origin access identities you want in the response body.

Result Syntax

[
    'CloudFrontOriginAccessIdentityList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'Comment' => '<string>',
                'Id' => '<string>',
                'S3CanonicalUserId' => '<string>',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
CloudFrontOriginAccessIdentityList

The CloudFrontOriginAccessIdentityList type.

Errors

InvalidArgument:

An argument is invalid.

ListConflictingAliases

$result = $client->listConflictingAliases([/* ... */]);
$promise = $client->listConflictingAliasesAsync([/* ... */]);

Gets a list of aliases (also called CNAMEs or alternate domain names) that conflict or overlap with the provided alias, and the associated CloudFront distributions and Amazon Web Services accounts for each conflicting alias. In the returned list, the distribution and account IDs are partially hidden, which allows you to identify the distributions and accounts that you own, but helps to protect the information of ones that you don't own.

Use this operation to find aliases that are in use in CloudFront that conflict or overlap with the provided alias. For example, if you provide www.example.com as input, the returned list can include www.example.com and the overlapping wildcard alternate domain name (*.example.com), if they exist. If you provide *.example.com as input, the returned list can include *.example.com and any alternate domain names covered by that wildcard (for example, www.example.com, test.example.com, dev.example.com, and so on), if they exist.

To list conflicting aliases, you provide the alias to search and the ID of a distribution in your account that has an attached SSL/TLS certificate that includes the provided alias. For more information, including how to set up the distribution and certificate, see Moving an alternate domain name to a different distribution in the Amazon CloudFront Developer Guide.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listConflictingAliases([
    'Alias' => '<string>', // REQUIRED
    'DistributionId' => '<string>', // REQUIRED
    'Marker' => '<string>',
    'MaxItems' => <integer>,
]);

Parameter Details

Members
Alias
Required: Yes
Type: string

The alias (also called a CNAME) to search for conflicting aliases.

DistributionId
Required: Yes
Type: string

The ID of a distribution in your account that has an attached SSL/TLS certificate that includes the provided alias.

Marker
Type: string

Use this field when paginating results to indicate where to begin in the list of conflicting aliases. The response includes conflicting aliases in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: int

The maximum number of conflicting aliases that you want in the response.

Result Syntax

[
    'ConflictingAliasesList' => [
        'Items' => [
            [
                'AccountId' => '<string>',
                'Alias' => '<string>',
                'DistributionId' => '<string>',
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
ConflictingAliasesList
Type: ConflictingAliasesList structure

A list of conflicting aliases.

Errors

NoSuchDistribution:

The specified distribution does not exist.

InvalidArgument:

An argument is invalid.

ListContinuousDeploymentPolicies

$result = $client->listContinuousDeploymentPolicies([/* ... */]);
$promise = $client->listContinuousDeploymentPoliciesAsync([/* ... */]);

Gets a list of the continuous deployment policies in your Amazon Web Services account.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listContinuousDeploymentPolicies([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of continuous deployment policies. The response includes policies in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of continuous deployment policies that you want returned in the response.

Result Syntax

[
    'ContinuousDeploymentPolicyList' => [
        'Items' => [
            [
                'ContinuousDeploymentPolicy' => [
                    'ContinuousDeploymentPolicyConfig' => [
                        'Enabled' => true || false,
                        'StagingDistributionDnsNames' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'TrafficConfig' => [
                            'SingleHeaderConfig' => [
                                'Header' => '<string>',
                                'Value' => '<string>',
                            ],
                            'SingleWeightConfig' => [
                                'SessionStickinessConfig' => [
                                    'IdleTTL' => <integer>,
                                    'MaximumTTL' => <integer>,
                                ],
                                'Weight' => <float>,
                            ],
                            'Type' => 'SingleWeight|SingleHeader',
                        ],
                    ],
                    'Id' => '<string>',
                    'LastModifiedTime' => <DateTime>,
                ],
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
ContinuousDeploymentPolicyList

A list of continuous deployment policies.

Errors

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

NoSuchContinuousDeploymentPolicy:

The continuous deployment policy doesn't exist.

ListDistributions

$result = $client->listDistributions([/* ... */]);
$promise = $client->listDistributionsAsync([/* ... */]);

List CloudFront distributions.

Parameter Syntax

$result = $client->listDistributions([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this when paginating results to indicate where to begin in your list of distributions. The results include distributions in the list that occur after the marker. To get the next page of results, set the Marker to the value of the NextMarker from the current page's response (which is also the ID of the last distribution on that page).

MaxItems
Type: string

The maximum number of distributions you want in the response body.

Result Syntax

[
    'DistributionList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'ARN' => '<string>',
                'AliasICPRecordals' => [
                    [
                        'CNAME' => '<string>',
                        'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
                    ],
                    // ...
                ],
                'Aliases' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AnycastIpListId' => '<string>',
                'CacheBehaviors' => [
                    'Items' => [
                        [
                            'AllowedMethods' => [
                                'CachedMethods' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'CachePolicyId' => '<string>',
                            'Compress' => true || false,
                            'DefaultTTL' => <integer>,
                            'FieldLevelEncryptionId' => '<string>',
                            'ForwardedValues' => [
                                'Cookies' => [
                                    'Forward' => 'none|whitelist|all',
                                    'WhitelistedNames' => [
                                        'Items' => ['<string>', ...],
                                        'Quantity' => <integer>,
                                    ],
                                ],
                                'Headers' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                                'QueryString' => true || false,
                                'QueryStringCacheKeys' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'FunctionAssociations' => [
                                'Items' => [
                                    [
                                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                        'FunctionARN' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'GrpcConfig' => [
                                'Enabled' => true || false,
                            ],
                            'LambdaFunctionAssociations' => [
                                'Items' => [
                                    [
                                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                        'IncludeBody' => true || false,
                                        'LambdaFunctionARN' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'MaxTTL' => <integer>,
                            'MinTTL' => <integer>,
                            'OriginRequestPolicyId' => '<string>',
                            'PathPattern' => '<string>',
                            'RealtimeLogConfigArn' => '<string>',
                            'ResponseHeadersPolicyId' => '<string>',
                            'SmoothStreaming' => true || false,
                            'TargetOriginId' => '<string>',
                            'TrustedKeyGroups' => [
                                'Enabled' => true || false,
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'TrustedSigners' => [
                                'Enabled' => true || false,
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Comment' => '<string>',
                'CustomErrorResponses' => [
                    'Items' => [
                        [
                            'ErrorCachingMinTTL' => <integer>,
                            'ErrorCode' => <integer>,
                            'ResponseCode' => '<string>',
                            'ResponsePagePath' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'DefaultCacheBehavior' => [
                    'AllowedMethods' => [
                        'CachedMethods' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'CachePolicyId' => '<string>',
                    'Compress' => true || false,
                    'DefaultTTL' => <integer>,
                    'FieldLevelEncryptionId' => '<string>',
                    'ForwardedValues' => [
                        'Cookies' => [
                            'Forward' => 'none|whitelist|all',
                            'WhitelistedNames' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Headers' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'QueryString' => true || false,
                        'QueryStringCacheKeys' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'FunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'FunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'GrpcConfig' => [
                        'Enabled' => true || false,
                    ],
                    'LambdaFunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'IncludeBody' => true || false,
                                'LambdaFunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'MaxTTL' => <integer>,
                    'MinTTL' => <integer>,
                    'OriginRequestPolicyId' => '<string>',
                    'RealtimeLogConfigArn' => '<string>',
                    'ResponseHeadersPolicyId' => '<string>',
                    'SmoothStreaming' => true || false,
                    'TargetOriginId' => '<string>',
                    'TrustedKeyGroups' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'TrustedSigners' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                ],
                'DomainName' => '<string>',
                'Enabled' => true || false,
                'HttpVersion' => 'http1.1|http2|http3|http2and3',
                'Id' => '<string>',
                'IsIPV6Enabled' => true || false,
                'LastModifiedTime' => <DateTime>,
                'OriginGroups' => [
                    'Items' => [
                        [
                            'FailoverCriteria' => [
                                'StatusCodes' => [
                                    'Items' => [<integer>, ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Id' => '<string>',
                            'Members' => [
                                'Items' => [
                                    [
                                        'OriginId' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'SelectionCriteria' => 'default|media-quality-based',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Origins' => [
                    'Items' => [
                        [
                            'ConnectionAttempts' => <integer>,
                            'ConnectionTimeout' => <integer>,
                            'CustomHeaders' => [
                                'Items' => [
                                    [
                                        'HeaderName' => '<string>',
                                        'HeaderValue' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'CustomOriginConfig' => [
                                'HTTPPort' => <integer>,
                                'HTTPSPort' => <integer>,
                                'OriginKeepaliveTimeout' => <integer>,
                                'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                                'OriginReadTimeout' => <integer>,
                                'OriginSslProtocols' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'DomainName' => '<string>',
                            'Id' => '<string>',
                            'OriginAccessControlId' => '<string>',
                            'OriginPath' => '<string>',
                            'OriginShield' => [
                                'Enabled' => true || false,
                                'OriginShieldRegion' => '<string>',
                            ],
                            'S3OriginConfig' => [
                                'OriginAccessIdentity' => '<string>',
                            ],
                            'VpcOriginConfig' => [
                                'OriginKeepaliveTimeout' => <integer>,
                                'OriginReadTimeout' => <integer>,
                                'VpcOriginId' => '<string>',
                            ],
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
                'Restrictions' => [
                    'GeoRestriction' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                        'RestrictionType' => 'blacklist|whitelist|none',
                    ],
                ],
                'Staging' => true || false,
                'Status' => '<string>',
                'ViewerCertificate' => [
                    'ACMCertificateArn' => '<string>',
                    'Certificate' => '<string>',
                    'CertificateSource' => 'cloudfront|iam|acm',
                    'CloudFrontDefaultCertificate' => true || false,
                    'IAMCertificateId' => '<string>',
                    'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                    'SSLSupportMethod' => 'sni-only|vip|static-ip',
                ],
                'WebACLId' => '<string>',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionList
Type: DistributionList structure

The DistributionList type.

Errors

InvalidArgument:

An argument is invalid.

ListDistributionsByAnycastIpListId

$result = $client->listDistributionsByAnycastIpListId([/* ... */]);
$promise = $client->listDistributionsByAnycastIpListIdAsync([/* ... */]);

Lists the distributions in your account that are associated with the specified AnycastIpListId.

Parameter Syntax

$result = $client->listDistributionsByAnycastIpListId([
    'AnycastIpListId' => '<string>', // REQUIRED
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
AnycastIpListId
Required: Yes
Type: string

The ID of the Anycast static IP list.

Marker
Type: string

Use this field when paginating results to indicate where to begin in your list. The response includes items in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of distributions that you want returned in the response.

Result Syntax

[
    'DistributionList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'ARN' => '<string>',
                'AliasICPRecordals' => [
                    [
                        'CNAME' => '<string>',
                        'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
                    ],
                    // ...
                ],
                'Aliases' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AnycastIpListId' => '<string>',
                'CacheBehaviors' => [
                    'Items' => [
                        [
                            'AllowedMethods' => [
                                'CachedMethods' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'CachePolicyId' => '<string>',
                            'Compress' => true || false,
                            'DefaultTTL' => <integer>,
                            'FieldLevelEncryptionId' => '<string>',
                            'ForwardedValues' => [
                                'Cookies' => [
                                    'Forward' => 'none|whitelist|all',
                                    'WhitelistedNames' => [
                                        'Items' => ['<string>', ...],
                                        'Quantity' => <integer>,
                                    ],
                                ],
                                'Headers' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                                'QueryString' => true || false,
                                'QueryStringCacheKeys' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'FunctionAssociations' => [
                                'Items' => [
                                    [
                                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                        'FunctionARN' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'GrpcConfig' => [
                                'Enabled' => true || false,
                            ],
                            'LambdaFunctionAssociations' => [
                                'Items' => [
                                    [
                                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                        'IncludeBody' => true || false,
                                        'LambdaFunctionARN' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'MaxTTL' => <integer>,
                            'MinTTL' => <integer>,
                            'OriginRequestPolicyId' => '<string>',
                            'PathPattern' => '<string>',
                            'RealtimeLogConfigArn' => '<string>',
                            'ResponseHeadersPolicyId' => '<string>',
                            'SmoothStreaming' => true || false,
                            'TargetOriginId' => '<string>',
                            'TrustedKeyGroups' => [
                                'Enabled' => true || false,
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'TrustedSigners' => [
                                'Enabled' => true || false,
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Comment' => '<string>',
                'CustomErrorResponses' => [
                    'Items' => [
                        [
                            'ErrorCachingMinTTL' => <integer>,
                            'ErrorCode' => <integer>,
                            'ResponseCode' => '<string>',
                            'ResponsePagePath' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'DefaultCacheBehavior' => [
                    'AllowedMethods' => [
                        'CachedMethods' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'CachePolicyId' => '<string>',
                    'Compress' => true || false,
                    'DefaultTTL' => <integer>,
                    'FieldLevelEncryptionId' => '<string>',
                    'ForwardedValues' => [
                        'Cookies' => [
                            'Forward' => 'none|whitelist|all',
                            'WhitelistedNames' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Headers' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'QueryString' => true || false,
                        'QueryStringCacheKeys' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'FunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'FunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'GrpcConfig' => [
                        'Enabled' => true || false,
                    ],
                    'LambdaFunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'IncludeBody' => true || false,
                                'LambdaFunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'MaxTTL' => <integer>,
                    'MinTTL' => <integer>,
                    'OriginRequestPolicyId' => '<string>',
                    'RealtimeLogConfigArn' => '<string>',
                    'ResponseHeadersPolicyId' => '<string>',
                    'SmoothStreaming' => true || false,
                    'TargetOriginId' => '<string>',
                    'TrustedKeyGroups' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'TrustedSigners' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                ],
                'DomainName' => '<string>',
                'Enabled' => true || false,
                'HttpVersion' => 'http1.1|http2|http3|http2and3',
                'Id' => '<string>',
                'IsIPV6Enabled' => true || false,
                'LastModifiedTime' => <DateTime>,
                'OriginGroups' => [
                    'Items' => [
                        [
                            'FailoverCriteria' => [
                                'StatusCodes' => [
                                    'Items' => [<integer>, ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Id' => '<string>',
                            'Members' => [
                                'Items' => [
                                    [
                                        'OriginId' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'SelectionCriteria' => 'default|media-quality-based',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Origins' => [
                    'Items' => [
                        [
                            'ConnectionAttempts' => <integer>,
                            'ConnectionTimeout' => <integer>,
                            'CustomHeaders' => [
                                'Items' => [
                                    [
                                        'HeaderName' => '<string>',
                                        'HeaderValue' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'CustomOriginConfig' => [
                                'HTTPPort' => <integer>,
                                'HTTPSPort' => <integer>,
                                'OriginKeepaliveTimeout' => <integer>,
                                'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                                'OriginReadTimeout' => <integer>,
                                'OriginSslProtocols' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'DomainName' => '<string>',
                            'Id' => '<string>',
                            'OriginAccessControlId' => '<string>',
                            'OriginPath' => '<string>',
                            'OriginShield' => [
                                'Enabled' => true || false,
                                'OriginShieldRegion' => '<string>',
                            ],
                            'S3OriginConfig' => [
                                'OriginAccessIdentity' => '<string>',
                            ],
                            'VpcOriginConfig' => [
                                'OriginKeepaliveTimeout' => <integer>,
                                'OriginReadTimeout' => <integer>,
                                'VpcOriginId' => '<string>',
                            ],
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
                'Restrictions' => [
                    'GeoRestriction' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                        'RestrictionType' => 'blacklist|whitelist|none',
                    ],
                ],
                'Staging' => true || false,
                'Status' => '<string>',
                'ViewerCertificate' => [
                    'ACMCertificateArn' => '<string>',
                    'Certificate' => '<string>',
                    'CertificateSource' => 'cloudfront|iam|acm',
                    'CloudFrontDefaultCertificate' => true || false,
                    'IAMCertificateId' => '<string>',
                    'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                    'SSLSupportMethod' => 'sni-only|vip|static-ip',
                ],
                'WebACLId' => '<string>',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionList
Type: DistributionList structure

A distribution list.

Errors

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

ListDistributionsByCachePolicyId

$result = $client->listDistributionsByCachePolicyId([/* ... */]);
$promise = $client->listDistributionsByCachePolicyIdAsync([/* ... */]);

Gets a list of distribution IDs for distributions that have a cache behavior that's associated with the specified cache policy.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listDistributionsByCachePolicyId([
    'CachePolicyId' => '<string>', // REQUIRED
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
CachePolicyId
Required: Yes
Type: string

The ID of the cache policy whose associated distribution IDs you want to list.

Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of distribution IDs. The response includes distribution IDs in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of distribution IDs that you want in the response.

Result Syntax

[
    'DistributionIdList' => [
        'IsTruncated' => true || false,
        'Items' => ['<string>', ...],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionIdList
Type: DistributionIdList structure

A list of distribution IDs.

Errors

NoSuchCachePolicy:

The cache policy does not exist.

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

ListDistributionsByKeyGroup

$result = $client->listDistributionsByKeyGroup([/* ... */]);
$promise = $client->listDistributionsByKeyGroupAsync([/* ... */]);

Gets a list of distribution IDs for distributions that have a cache behavior that references the specified key group.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listDistributionsByKeyGroup([
    'KeyGroupId' => '<string>', // REQUIRED
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
KeyGroupId
Required: Yes
Type: string

The ID of the key group whose associated distribution IDs you are listing.

Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of distribution IDs. The response includes distribution IDs in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of distribution IDs that you want in the response.

Result Syntax

[
    'DistributionIdList' => [
        'IsTruncated' => true || false,
        'Items' => ['<string>', ...],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionIdList
Type: DistributionIdList structure

A list of distribution IDs.

Errors

InvalidArgument:

An argument is invalid.

NoSuchResource:

A resource that was specified is not valid.

ListDistributionsByOriginRequestPolicyId

$result = $client->listDistributionsByOriginRequestPolicyId([/* ... */]);
$promise = $client->listDistributionsByOriginRequestPolicyIdAsync([/* ... */]);

Gets a list of distribution IDs for distributions that have a cache behavior that's associated with the specified origin request policy.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listDistributionsByOriginRequestPolicyId([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'OriginRequestPolicyId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of distribution IDs. The response includes distribution IDs in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of distribution IDs that you want in the response.

OriginRequestPolicyId
Required: Yes
Type: string

The ID of the origin request policy whose associated distribution IDs you want to list.

Result Syntax

[
    'DistributionIdList' => [
        'IsTruncated' => true || false,
        'Items' => ['<string>', ...],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionIdList
Type: DistributionIdList structure

A list of distribution IDs.

Errors

AccessDenied:

Access denied.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

InvalidArgument:

An argument is invalid.

ListDistributionsByRealtimeLogConfig

$result = $client->listDistributionsByRealtimeLogConfig([/* ... */]);
$promise = $client->listDistributionsByRealtimeLogConfigAsync([/* ... */]);

Gets a list of distributions that have a cache behavior that's associated with the specified real-time log configuration.

You can specify the real-time log configuration by its name or its Amazon Resource Name (ARN). You must provide at least one. If you provide both, CloudFront uses the name to identify the real-time log configuration to list distributions for.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listDistributionsByRealtimeLogConfig([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'RealtimeLogConfigArn' => '<string>',
    'RealtimeLogConfigName' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of distributions. The response includes distributions in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of distributions that you want in the response.

RealtimeLogConfigArn
Type: string

The Amazon Resource Name (ARN) of the real-time log configuration whose associated distributions you want to list.

RealtimeLogConfigName
Type: string

The name of the real-time log configuration whose associated distributions you want to list.

Result Syntax

[
    'DistributionList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'ARN' => '<string>',
                'AliasICPRecordals' => [
                    [
                        'CNAME' => '<string>',
                        'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
                    ],
                    // ...
                ],
                'Aliases' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AnycastIpListId' => '<string>',
                'CacheBehaviors' => [
                    'Items' => [
                        [
                            'AllowedMethods' => [
                                'CachedMethods' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'CachePolicyId' => '<string>',
                            'Compress' => true || false,
                            'DefaultTTL' => <integer>,
                            'FieldLevelEncryptionId' => '<string>',
                            'ForwardedValues' => [
                                'Cookies' => [
                                    'Forward' => 'none|whitelist|all',
                                    'WhitelistedNames' => [
                                        'Items' => ['<string>', ...],
                                        'Quantity' => <integer>,
                                    ],
                                ],
                                'Headers' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                                'QueryString' => true || false,
                                'QueryStringCacheKeys' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'FunctionAssociations' => [
                                'Items' => [
                                    [
                                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                        'FunctionARN' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'GrpcConfig' => [
                                'Enabled' => true || false,
                            ],
                            'LambdaFunctionAssociations' => [
                                'Items' => [
                                    [
                                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                        'IncludeBody' => true || false,
                                        'LambdaFunctionARN' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'MaxTTL' => <integer>,
                            'MinTTL' => <integer>,
                            'OriginRequestPolicyId' => '<string>',
                            'PathPattern' => '<string>',
                            'RealtimeLogConfigArn' => '<string>',
                            'ResponseHeadersPolicyId' => '<string>',
                            'SmoothStreaming' => true || false,
                            'TargetOriginId' => '<string>',
                            'TrustedKeyGroups' => [
                                'Enabled' => true || false,
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'TrustedSigners' => [
                                'Enabled' => true || false,
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Comment' => '<string>',
                'CustomErrorResponses' => [
                    'Items' => [
                        [
                            'ErrorCachingMinTTL' => <integer>,
                            'ErrorCode' => <integer>,
                            'ResponseCode' => '<string>',
                            'ResponsePagePath' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'DefaultCacheBehavior' => [
                    'AllowedMethods' => [
                        'CachedMethods' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'CachePolicyId' => '<string>',
                    'Compress' => true || false,
                    'DefaultTTL' => <integer>,
                    'FieldLevelEncryptionId' => '<string>',
                    'ForwardedValues' => [
                        'Cookies' => [
                            'Forward' => 'none|whitelist|all',
                            'WhitelistedNames' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Headers' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'QueryString' => true || false,
                        'QueryStringCacheKeys' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'FunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'FunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'GrpcConfig' => [
                        'Enabled' => true || false,
                    ],
                    'LambdaFunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'IncludeBody' => true || false,
                                'LambdaFunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'MaxTTL' => <integer>,
                    'MinTTL' => <integer>,
                    'OriginRequestPolicyId' => '<string>',
                    'RealtimeLogConfigArn' => '<string>',
                    'ResponseHeadersPolicyId' => '<string>',
                    'SmoothStreaming' => true || false,
                    'TargetOriginId' => '<string>',
                    'TrustedKeyGroups' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'TrustedSigners' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                ],
                'DomainName' => '<string>',
                'Enabled' => true || false,
                'HttpVersion' => 'http1.1|http2|http3|http2and3',
                'Id' => '<string>',
                'IsIPV6Enabled' => true || false,
                'LastModifiedTime' => <DateTime>,
                'OriginGroups' => [
                    'Items' => [
                        [
                            'FailoverCriteria' => [
                                'StatusCodes' => [
                                    'Items' => [<integer>, ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Id' => '<string>',
                            'Members' => [
                                'Items' => [
                                    [
                                        'OriginId' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'SelectionCriteria' => 'default|media-quality-based',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Origins' => [
                    'Items' => [
                        [
                            'ConnectionAttempts' => <integer>,
                            'ConnectionTimeout' => <integer>,
                            'CustomHeaders' => [
                                'Items' => [
                                    [
                                        'HeaderName' => '<string>',
                                        'HeaderValue' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'CustomOriginConfig' => [
                                'HTTPPort' => <integer>,
                                'HTTPSPort' => <integer>,
                                'OriginKeepaliveTimeout' => <integer>,
                                'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                                'OriginReadTimeout' => <integer>,
                                'OriginSslProtocols' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'DomainName' => '<string>',
                            'Id' => '<string>',
                            'OriginAccessControlId' => '<string>',
                            'OriginPath' => '<string>',
                            'OriginShield' => [
                                'Enabled' => true || false,
                                'OriginShieldRegion' => '<string>',
                            ],
                            'S3OriginConfig' => [
                                'OriginAccessIdentity' => '<string>',
                            ],
                            'VpcOriginConfig' => [
                                'OriginKeepaliveTimeout' => <integer>,
                                'OriginReadTimeout' => <integer>,
                                'VpcOriginId' => '<string>',
                            ],
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
                'Restrictions' => [
                    'GeoRestriction' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                        'RestrictionType' => 'blacklist|whitelist|none',
                    ],
                ],
                'Staging' => true || false,
                'Status' => '<string>',
                'ViewerCertificate' => [
                    'ACMCertificateArn' => '<string>',
                    'Certificate' => '<string>',
                    'CertificateSource' => 'cloudfront|iam|acm',
                    'CloudFrontDefaultCertificate' => true || false,
                    'IAMCertificateId' => '<string>',
                    'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                    'SSLSupportMethod' => 'sni-only|vip|static-ip',
                ],
                'WebACLId' => '<string>',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionList
Type: DistributionList structure

A distribution list.

Errors

InvalidArgument:

An argument is invalid.

ListDistributionsByResponseHeadersPolicyId

$result = $client->listDistributionsByResponseHeadersPolicyId([/* ... */]);
$promise = $client->listDistributionsByResponseHeadersPolicyIdAsync([/* ... */]);

Gets a list of distribution IDs for distributions that have a cache behavior that's associated with the specified response headers policy.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listDistributionsByResponseHeadersPolicyId([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'ResponseHeadersPolicyId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of distribution IDs. The response includes distribution IDs in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of distribution IDs that you want to get in the response.

ResponseHeadersPolicyId
Required: Yes
Type: string

The ID of the response headers policy whose associated distribution IDs you want to list.

Result Syntax

[
    'DistributionIdList' => [
        'IsTruncated' => true || false,
        'Items' => ['<string>', ...],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionIdList
Type: DistributionIdList structure

A list of distribution IDs.

Errors

AccessDenied:

Access denied.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

InvalidArgument:

An argument is invalid.

ListDistributionsByVpcOriginId

$result = $client->listDistributionsByVpcOriginId([/* ... */]);
$promise = $client->listDistributionsByVpcOriginIdAsync([/* ... */]);

List CloudFront distributions by their VPC origin ID.

Parameter Syntax

$result = $client->listDistributionsByVpcOriginId([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'VpcOriginId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Marker
Type: string

The marker associated with the VPC origin distributions list.

MaxItems
Type: string

The maximum number of items included in the list.

VpcOriginId
Required: Yes
Type: string

The VPC origin ID.

Result Syntax

[
    'DistributionIdList' => [
        'IsTruncated' => true || false,
        'Items' => ['<string>', ...],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionIdList
Type: DistributionIdList structure

A list of distribution IDs.

Errors

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

Examples

Example 1: To list distributions by VPC origin ID

The following command lists distributions by VPC origin ID:

$result = $client->listDistributionsByVpcOriginId([
    'VpcOriginId' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
]);

Result syntax:

[
    'DistributionIdList' => [
        'IsTruncated' => ,
        'Items' => [
        ],
        'Marker' => 'a',
        'MaxItems' => 100,
        'Quantity' => 0,
    ],
]

ListDistributionsByWebACLId

$result = $client->listDistributionsByWebACLId([/* ... */]);
$promise = $client->listDistributionsByWebACLIdAsync([/* ... */]);

List the distributions that are associated with a specified WAF web ACL.

Parameter Syntax

$result = $client->listDistributionsByWebACLId([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'WebACLId' => '<string>', // REQUIRED
]);

Parameter Details

Members
Marker
Type: string

Use Marker and MaxItems to control pagination of results. If you have more than MaxItems distributions that satisfy the request, the response includes a NextMarker element. To get the next page of results, submit another request. For the value of Marker, specify the value of NextMarker from the last response. (For the first request, omit Marker.)

MaxItems
Type: string

The maximum number of distributions that you want CloudFront to return in the response body. The maximum and default values are both 100.

WebACLId
Required: Yes
Type: string

The ID of the WAF web ACL that you want to list the associated distributions. If you specify "null" for the ID, the request returns a list of the distributions that aren't associated with a web ACL.

For WAFV2, this is the ARN of the web ACL, such as arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4-5678-90ab-cdef-EXAMPLE11111.

For WAF Classic, this is the ID of the web ACL, such as a1b2c3d4-5678-90ab-cdef-EXAMPLE11111.

Result Syntax

[
    'DistributionList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'ARN' => '<string>',
                'AliasICPRecordals' => [
                    [
                        'CNAME' => '<string>',
                        'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
                    ],
                    // ...
                ],
                'Aliases' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AnycastIpListId' => '<string>',
                'CacheBehaviors' => [
                    'Items' => [
                        [
                            'AllowedMethods' => [
                                'CachedMethods' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'CachePolicyId' => '<string>',
                            'Compress' => true || false,
                            'DefaultTTL' => <integer>,
                            'FieldLevelEncryptionId' => '<string>',
                            'ForwardedValues' => [
                                'Cookies' => [
                                    'Forward' => 'none|whitelist|all',
                                    'WhitelistedNames' => [
                                        'Items' => ['<string>', ...],
                                        'Quantity' => <integer>,
                                    ],
                                ],
                                'Headers' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                                'QueryString' => true || false,
                                'QueryStringCacheKeys' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'FunctionAssociations' => [
                                'Items' => [
                                    [
                                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                        'FunctionARN' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'GrpcConfig' => [
                                'Enabled' => true || false,
                            ],
                            'LambdaFunctionAssociations' => [
                                'Items' => [
                                    [
                                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                        'IncludeBody' => true || false,
                                        'LambdaFunctionARN' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'MaxTTL' => <integer>,
                            'MinTTL' => <integer>,
                            'OriginRequestPolicyId' => '<string>',
                            'PathPattern' => '<string>',
                            'RealtimeLogConfigArn' => '<string>',
                            'ResponseHeadersPolicyId' => '<string>',
                            'SmoothStreaming' => true || false,
                            'TargetOriginId' => '<string>',
                            'TrustedKeyGroups' => [
                                'Enabled' => true || false,
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'TrustedSigners' => [
                                'Enabled' => true || false,
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Comment' => '<string>',
                'CustomErrorResponses' => [
                    'Items' => [
                        [
                            'ErrorCachingMinTTL' => <integer>,
                            'ErrorCode' => <integer>,
                            'ResponseCode' => '<string>',
                            'ResponsePagePath' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'DefaultCacheBehavior' => [
                    'AllowedMethods' => [
                        'CachedMethods' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'CachePolicyId' => '<string>',
                    'Compress' => true || false,
                    'DefaultTTL' => <integer>,
                    'FieldLevelEncryptionId' => '<string>',
                    'ForwardedValues' => [
                        'Cookies' => [
                            'Forward' => 'none|whitelist|all',
                            'WhitelistedNames' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Headers' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'QueryString' => true || false,
                        'QueryStringCacheKeys' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'FunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'FunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'GrpcConfig' => [
                        'Enabled' => true || false,
                    ],
                    'LambdaFunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                'IncludeBody' => true || false,
                                'LambdaFunctionARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'MaxTTL' => <integer>,
                    'MinTTL' => <integer>,
                    'OriginRequestPolicyId' => '<string>',
                    'RealtimeLogConfigArn' => '<string>',
                    'ResponseHeadersPolicyId' => '<string>',
                    'SmoothStreaming' => true || false,
                    'TargetOriginId' => '<string>',
                    'TrustedKeyGroups' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'TrustedSigners' => [
                        'Enabled' => true || false,
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                ],
                'DomainName' => '<string>',
                'Enabled' => true || false,
                'HttpVersion' => 'http1.1|http2|http3|http2and3',
                'Id' => '<string>',
                'IsIPV6Enabled' => true || false,
                'LastModifiedTime' => <DateTime>,
                'OriginGroups' => [
                    'Items' => [
                        [
                            'FailoverCriteria' => [
                                'StatusCodes' => [
                                    'Items' => [<integer>, ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Id' => '<string>',
                            'Members' => [
                                'Items' => [
                                    [
                                        'OriginId' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'SelectionCriteria' => 'default|media-quality-based',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Origins' => [
                    'Items' => [
                        [
                            'ConnectionAttempts' => <integer>,
                            'ConnectionTimeout' => <integer>,
                            'CustomHeaders' => [
                                'Items' => [
                                    [
                                        'HeaderName' => '<string>',
                                        'HeaderValue' => '<string>',
                                    ],
                                    // ...
                                ],
                                'Quantity' => <integer>,
                            ],
                            'CustomOriginConfig' => [
                                'HTTPPort' => <integer>,
                                'HTTPSPort' => <integer>,
                                'OriginKeepaliveTimeout' => <integer>,
                                'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                                'OriginReadTimeout' => <integer>,
                                'OriginSslProtocols' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'DomainName' => '<string>',
                            'Id' => '<string>',
                            'OriginAccessControlId' => '<string>',
                            'OriginPath' => '<string>',
                            'OriginShield' => [
                                'Enabled' => true || false,
                                'OriginShieldRegion' => '<string>',
                            ],
                            'S3OriginConfig' => [
                                'OriginAccessIdentity' => '<string>',
                            ],
                            'VpcOriginConfig' => [
                                'OriginKeepaliveTimeout' => <integer>,
                                'OriginReadTimeout' => <integer>,
                                'VpcOriginId' => '<string>',
                            ],
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
                'Restrictions' => [
                    'GeoRestriction' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                        'RestrictionType' => 'blacklist|whitelist|none',
                    ],
                ],
                'Staging' => true || false,
                'Status' => '<string>',
                'ViewerCertificate' => [
                    'ACMCertificateArn' => '<string>',
                    'Certificate' => '<string>',
                    'CertificateSource' => 'cloudfront|iam|acm',
                    'CloudFrontDefaultCertificate' => true || false,
                    'IAMCertificateId' => '<string>',
                    'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                    'SSLSupportMethod' => 'sni-only|vip|static-ip',
                ],
                'WebACLId' => '<string>',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
DistributionList
Type: DistributionList structure

The DistributionList type.

Errors

InvalidWebACLId:

A web ACL ID specified is not valid. To specify a web ACL created using the latest version of WAF, use the ACL ARN, for example arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/473e64fd-f30b-4765-81a0-62ad96dd167a. To specify a web ACL created using WAF Classic, use the ACL ID, for example 473e64fd-f30b-4765-81a0-62ad96dd167a.

InvalidArgument:

An argument is invalid.

ListFieldLevelEncryptionConfigs

$result = $client->listFieldLevelEncryptionConfigs([/* ... */]);
$promise = $client->listFieldLevelEncryptionConfigsAsync([/* ... */]);

List all field-level encryption configurations that have been created in CloudFront for this account.

Parameter Syntax

$result = $client->listFieldLevelEncryptionConfigs([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this when paginating results to indicate where to begin in your list of configurations. The results include configurations in the list that occur after the marker. To get the next page of results, set the Marker to the value of the NextMarker from the current page's response (which is also the ID of the last configuration on that page).

MaxItems
Type: string

The maximum number of field-level encryption configurations you want in the response body.

Result Syntax

[
    'FieldLevelEncryptionList' => [
        'Items' => [
            [
                'Comment' => '<string>',
                'ContentTypeProfileConfig' => [
                    'ContentTypeProfiles' => [
                        'Items' => [
                            [
                                'ContentType' => '<string>',
                                'Format' => 'URLEncoded',
                                'ProfileId' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'ForwardWhenContentTypeIsUnknown' => true || false,
                ],
                'Id' => '<string>',
                'LastModifiedTime' => <DateTime>,
                'QueryArgProfileConfig' => [
                    'ForwardWhenQueryArgProfileIsUnknown' => true || false,
                    'QueryArgProfiles' => [
                        'Items' => [
                            [
                                'ProfileId' => '<string>',
                                'QueryArg' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                ],
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
FieldLevelEncryptionList
Type: FieldLevelEncryptionList structure

Returns a list of all field-level encryption configurations that have been created in CloudFront for this account.

Errors

InvalidArgument:

An argument is invalid.

ListFieldLevelEncryptionProfiles

$result = $client->listFieldLevelEncryptionProfiles([/* ... */]);
$promise = $client->listFieldLevelEncryptionProfilesAsync([/* ... */]);

Request a list of field-level encryption profiles that have been created in CloudFront for this account.

Parameter Syntax

$result = $client->listFieldLevelEncryptionProfiles([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this when paginating results to indicate where to begin in your list of profiles. The results include profiles in the list that occur after the marker. To get the next page of results, set the Marker to the value of the NextMarker from the current page's response (which is also the ID of the last profile on that page).

MaxItems
Type: string

The maximum number of field-level encryption profiles you want in the response body.

Result Syntax

[
    'FieldLevelEncryptionProfileList' => [
        'Items' => [
            [
                'Comment' => '<string>',
                'EncryptionEntities' => [
                    'Items' => [
                        [
                            'FieldPatterns' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'ProviderId' => '<string>',
                            'PublicKeyId' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Id' => '<string>',
                'LastModifiedTime' => <DateTime>,
                'Name' => '<string>',
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
FieldLevelEncryptionProfileList

Returns a list of the field-level encryption profiles that have been created in CloudFront for this account.

Errors

InvalidArgument:

An argument is invalid.

ListFunctions

$result = $client->listFunctions([/* ... */]);
$promise = $client->listFunctionsAsync([/* ... */]);

Gets a list of all CloudFront functions in your Amazon Web Services account.

You can optionally apply a filter to return only the functions that are in the specified stage, either DEVELOPMENT or LIVE.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listFunctions([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'Stage' => 'DEVELOPMENT|LIVE',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of functions. The response includes functions in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of functions that you want in the response.

Stage
Type: string

An optional filter to return only the functions that are in the specified stage, either DEVELOPMENT or LIVE.

Result Syntax

[
    'FunctionList' => [
        'Items' => [
            [
                'FunctionConfig' => [
                    'Comment' => '<string>',
                    'KeyValueStoreAssociations' => [
                        'Items' => [
                            [
                                'KeyValueStoreARN' => '<string>',
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>,
                    ],
                    'Runtime' => 'cloudfront-js-1.0|cloudfront-js-2.0',
                ],
                'FunctionMetadata' => [
                    'CreatedTime' => <DateTime>,
                    'FunctionARN' => '<string>',
                    'LastModifiedTime' => <DateTime>,
                    'Stage' => 'DEVELOPMENT|LIVE',
                ],
                'Name' => '<string>',
                'Status' => '<string>',
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
FunctionList
Type: FunctionList structure

A list of CloudFront functions.

Errors

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

ListInvalidations

$result = $client->listInvalidations([/* ... */]);
$promise = $client->listInvalidationsAsync([/* ... */]);

Lists invalidation batches.

Parameter Syntax

$result = $client->listInvalidations([
    'DistributionId' => '<string>', // REQUIRED
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
DistributionId
Required: Yes
Type: string

The distribution's ID.

Marker
Type: string

Use this parameter when paginating results to indicate where to begin in your list of invalidation batches. Because the results are returned in decreasing order from most recent to oldest, the most recent results are on the first page, the second page will contain earlier results, and so on. To get the next page of results, set Marker to the value of the NextMarker from the current page's response. This value is the same as the ID of the last invalidation batch on that page.

MaxItems
Type: string

The maximum number of invalidation batches that you want in the response body.

Result Syntax

[
    'InvalidationList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'CreateTime' => <DateTime>,
                'Id' => '<string>',
                'Status' => '<string>',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
InvalidationList
Type: InvalidationList structure

Information about invalidation batches.

Errors

NoSuchDistribution:

The specified distribution does not exist.

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

ListKeyGroups

$result = $client->listKeyGroups([/* ... */]);
$promise = $client->listKeyGroupsAsync([/* ... */]);

Gets a list of key groups.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listKeyGroups([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of key groups. The response includes key groups in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of key groups that you want in the response.

Result Syntax

[
    'KeyGroupList' => [
        'Items' => [
            [
                'KeyGroup' => [
                    'Id' => '<string>',
                    'KeyGroupConfig' => [
                        'Comment' => '<string>',
                        'Items' => ['<string>', ...],
                        'Name' => '<string>',
                    ],
                    'LastModifiedTime' => <DateTime>,
                ],
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
KeyGroupList
Type: KeyGroupList structure

A list of key groups.

Errors

InvalidArgument:

An argument is invalid.

ListKeyValueStores

$result = $client->listKeyValueStores([/* ... */]);
$promise = $client->listKeyValueStoresAsync([/* ... */]);

Specifies the key value stores to list.

Parameter Syntax

$result = $client->listKeyValueStores([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'Status' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

The marker associated with the key value stores list.

MaxItems
Type: string

The maximum number of items in the key value stores list.

Status
Type: string

The status of the request for the key value stores list.

Result Syntax

[
    'KeyValueStoreList' => [
        'Items' => [
            [
                'ARN' => '<string>',
                'Comment' => '<string>',
                'Id' => '<string>',
                'LastModifiedTime' => <DateTime>,
                'Name' => '<string>',
                'Status' => '<string>',
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
KeyValueStoreList
Type: KeyValueStoreList structure

The resulting key value stores list.

Errors

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

Examples

Example 1: To get a list of KeyValueStores

The following command retrieves a list of KeyValueStores with READY status.

$result = $client->listKeyValueStores([
    'Status' => 'READY',
]);

Result syntax:

[
    'KeyValueStoreList' => [
        'Items' => [
            [
                'ARN' => 'arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
                'Comment' => '',
                'Id' => '54947df8-0e9e-4471-a2f9-9af509fb5889',
                'LastModifiedTime' => ,
                'Name' => 'my-keyvaluestore-name',
                'Status' => 'READY',
            ],
        ],
        'MaxItems' => 100,
        'NextMarker' => '',
        'Quantity' => 1,
    ],
]

ListOriginAccessControls

$result = $client->listOriginAccessControls([/* ... */]);
$promise = $client->listOriginAccessControlsAsync([/* ... */]);

Gets the list of CloudFront origin access controls (OACs) in this Amazon Web Services account.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send another request that specifies the NextMarker value from the current response as the Marker value in the next request.

If you're not using origin access controls for your Amazon Web Services account, the ListOriginAccessControls operation doesn't return the Items element in the response.

Parameter Syntax

$result = $client->listOriginAccessControls([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of origin access controls. The response includes the items in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of origin access controls that you want in the response.

Result Syntax

[
    'OriginAccessControlList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'Description' => '<string>',
                'Id' => '<string>',
                'Name' => '<string>',
                'OriginAccessControlOriginType' => 's3|mediastore|mediapackagev2|lambda',
                'SigningBehavior' => 'never|always|no-override',
                'SigningProtocol' => 'sigv4',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
OriginAccessControlList
Type: OriginAccessControlList structure

A list of origin access controls.

Errors

InvalidArgument:

An argument is invalid.

ListOriginRequestPolicies

$result = $client->listOriginRequestPolicies([/* ... */]);
$promise = $client->listOriginRequestPoliciesAsync([/* ... */]);

Gets a list of origin request policies.

You can optionally apply a filter to return only the managed policies created by Amazon Web Services, or only the custom policies created in your Amazon Web Services account.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listOriginRequestPolicies([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'Type' => 'managed|custom',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of origin request policies. The response includes origin request policies in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of origin request policies that you want in the response.

Type
Type: string

A filter to return only the specified kinds of origin request policies. Valid values are:

  • managed – Returns only the managed policies created by Amazon Web Services.

  • custom – Returns only the custom policies created in your Amazon Web Services account.

Result Syntax

[
    'OriginRequestPolicyList' => [
        'Items' => [
            [
                'OriginRequestPolicy' => [
                    'Id' => '<string>',
                    'LastModifiedTime' => <DateTime>,
                    'OriginRequestPolicyConfig' => [
                        'Comment' => '<string>',
                        'CookiesConfig' => [
                            'CookieBehavior' => 'none|whitelist|all|allExcept',
                            'Cookies' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'HeadersConfig' => [
                            'HeaderBehavior' => 'none|whitelist|allViewer|allViewerAndWhitelistCloudFront|allExcept',
                            'Headers' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Name' => '<string>',
                        'QueryStringsConfig' => [
                            'QueryStringBehavior' => 'none|whitelist|all|allExcept',
                            'QueryStrings' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                    ],
                ],
                'Type' => 'managed|custom',
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
OriginRequestPolicyList
Type: OriginRequestPolicyList structure

A list of origin request policies.

Errors

AccessDenied:

Access denied.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

InvalidArgument:

An argument is invalid.

ListPublicKeys

$result = $client->listPublicKeys([/* ... */]);
$promise = $client->listPublicKeysAsync([/* ... */]);

List all public keys that have been added to CloudFront for this account.

Parameter Syntax

$result = $client->listPublicKeys([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this when paginating results to indicate where to begin in your list of public keys. The results include public keys in the list that occur after the marker. To get the next page of results, set the Marker to the value of the NextMarker from the current page's response (which is also the ID of the last public key on that page).

MaxItems
Type: string

The maximum number of public keys you want in the response body.

Result Syntax

[
    'PublicKeyList' => [
        'Items' => [
            [
                'Comment' => '<string>',
                'CreatedTime' => <DateTime>,
                'EncodedKey' => '<string>',
                'Id' => '<string>',
                'Name' => '<string>',
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
PublicKeyList
Type: PublicKeyList structure

Returns a list of all public keys that have been added to CloudFront for this account.

Errors

InvalidArgument:

An argument is invalid.

ListRealtimeLogConfigs

$result = $client->listRealtimeLogConfigs([/* ... */]);
$promise = $client->listRealtimeLogConfigsAsync([/* ... */]);

Gets a list of real-time log configurations.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listRealtimeLogConfigs([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of real-time log configurations. The response includes real-time log configurations in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of real-time log configurations that you want in the response.

Result Syntax

[
    'RealtimeLogConfigs' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'ARN' => '<string>',
                'EndPoints' => [
                    [
                        'KinesisStreamConfig' => [
                            'RoleARN' => '<string>',
                            'StreamARN' => '<string>',
                        ],
                        'StreamType' => '<string>',
                    ],
                    // ...
                ],
                'Fields' => ['<string>', ...],
                'Name' => '<string>',
                'SamplingRate' => <integer>,
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
    ],
]

Result Details

Members
RealtimeLogConfigs
Type: RealtimeLogConfigs structure

A list of real-time log configurations.

Errors

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

ListResponseHeadersPolicies

$result = $client->listResponseHeadersPolicies([/* ... */]);
$promise = $client->listResponseHeadersPoliciesAsync([/* ... */]);

Gets a list of response headers policies.

You can optionally apply a filter to get only the managed policies created by Amazon Web Services, or only the custom policies created in your Amazon Web Services account.

You can optionally specify the maximum number of items to receive in the response. If the total number of items in the list exceeds the maximum that you specify, or the default maximum, the response is paginated. To get the next page of items, send a subsequent request that specifies the NextMarker value from the current response as the Marker value in the subsequent request.

Parameter Syntax

$result = $client->listResponseHeadersPolicies([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
    'Type' => 'managed|custom',
]);

Parameter Details

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of response headers policies. The response includes response headers policies in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of response headers policies that you want to get in the response.

Type
Type: string

A filter to get only the specified kind of response headers policies. Valid values are:

  • managed – Gets only the managed policies created by Amazon Web Services.

  • custom – Gets only the custom policies created in your Amazon Web Services account.

Result Syntax

[
    'ResponseHeadersPolicyList' => [
        'Items' => [
            [
                'ResponseHeadersPolicy' => [
                    'Id' => '<string>',
                    'LastModifiedTime' => <DateTime>,
                    'ResponseHeadersPolicyConfig' => [
                        'Comment' => '<string>',
                        'CorsConfig' => [
                            'AccessControlAllowCredentials' => true || false,
                            'AccessControlAllowHeaders' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'AccessControlAllowMethods' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'AccessControlAllowOrigins' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'AccessControlExposeHeaders' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'AccessControlMaxAgeSec' => <integer>,
                            'OriginOverride' => true || false,
                        ],
                        'CustomHeadersConfig' => [
                            'Items' => [
                                [
                                    'Header' => '<string>',
                                    'Override' => true || false,
                                    'Value' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'Name' => '<string>',
                        'RemoveHeadersConfig' => [
                            'Items' => [
                                [
                                    'Header' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'SecurityHeadersConfig' => [
                            'ContentSecurityPolicy' => [
                                'ContentSecurityPolicy' => '<string>',
                                'Override' => true || false,
                            ],
                            'ContentTypeOptions' => [
                                'Override' => true || false,
                            ],
                            'FrameOptions' => [
                                'FrameOption' => 'DENY|SAMEORIGIN',
                                'Override' => true || false,
                            ],
                            'ReferrerPolicy' => [
                                'Override' => true || false,
                                'ReferrerPolicy' => 'no-referrer|no-referrer-when-downgrade|origin|origin-when-cross-origin|same-origin|strict-origin|strict-origin-when-cross-origin|unsafe-url',
                            ],
                            'StrictTransportSecurity' => [
                                'AccessControlMaxAgeSec' => <integer>,
                                'IncludeSubdomains' => true || false,
                                'Override' => true || false,
                                'Preload' => true || false,
                            ],
                            'XSSProtection' => [
                                'ModeBlock' => true || false,
                                'Override' => true || false,
                                'Protection' => true || false,
                                'ReportUri' => '<string>',
                            ],
                        ],
                        'ServerTimingHeadersConfig' => [
                            'Enabled' => true || false,
                            'SamplingRate' => <float>,
                        ],
                    ],
                ],
                'Type' => 'managed|custom',
            ],
            // ...
        ],
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
ResponseHeadersPolicyList
Type: ResponseHeadersPolicyList structure

A list of response headers policies.

Errors

AccessDenied:

Access denied.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

InvalidArgument:

An argument is invalid.

ListStreamingDistributions

$result = $client->listStreamingDistributions([/* ... */]);
$promise = $client->listStreamingDistributionsAsync([/* ... */]);

List streaming distributions.

Parameter Syntax

$result = $client->listStreamingDistributions([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

The value that you provided for the Marker request parameter.

MaxItems
Type: string

The value that you provided for the MaxItems request parameter.

Result Syntax

[
    'StreamingDistributionList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'ARN' => '<string>',
                'Aliases' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'Comment' => '<string>',
                'DomainName' => '<string>',
                'Enabled' => true || false,
                'Id' => '<string>',
                'LastModifiedTime' => <DateTime>,
                'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
                'S3Origin' => [
                    'DomainName' => '<string>',
                    'OriginAccessIdentity' => '<string>',
                ],
                'Status' => '<string>',
                'TrustedSigners' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
StreamingDistributionList
Type: StreamingDistributionList structure

The StreamingDistributionList type.

Errors

InvalidArgument:

An argument is invalid.

ListTagsForResource

$result = $client->listTagsForResource([/* ... */]);
$promise = $client->listTagsForResourceAsync([/* ... */]);

List tags for a CloudFront resource. For more information, see Tagging a distribution in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->listTagsForResource([
    'Resource' => '<string>', // REQUIRED
]);

Parameter Details

Members
Resource
Required: Yes
Type: string

An ARN of a CloudFront resource.

Result Syntax

[
    'Tags' => [
        'Items' => [
            [
                'Key' => '<string>',
                'Value' => '<string>',
            ],
            // ...
        ],
    ],
]

Result Details

Members
Tags
Required: Yes
Type: Tags structure

A complex type that contains zero or more Tag elements.

Errors

AccessDenied:

Access denied.

InvalidTagging:

The tagging specified is not valid.

InvalidArgument:

An argument is invalid.

NoSuchResource:

A resource that was specified is not valid.

ListVpcOrigins

$result = $client->listVpcOrigins([/* ... */]);
$promise = $client->listVpcOriginsAsync([/* ... */]);

List the CloudFront VPC origins in your account.

Parameter Syntax

$result = $client->listVpcOrigins([
    'Marker' => '<string>',
    'MaxItems' => '<string>',
]);

Parameter Details

Members
Marker
Type: string

The marker associated with the VPC origins list.

MaxItems
Type: string

The maximum number of items included in the list.

Result Syntax

[
    'VpcOriginList' => [
        'IsTruncated' => true || false,
        'Items' => [
            [
                'Arn' => '<string>',
                'CreatedTime' => <DateTime>,
                'Id' => '<string>',
                'LastModifiedTime' => <DateTime>,
                'Name' => '<string>',
                'OriginEndpointArn' => '<string>',
                'Status' => '<string>',
            ],
            // ...
        ],
        'Marker' => '<string>',
        'MaxItems' => <integer>,
        'NextMarker' => '<string>',
        'Quantity' => <integer>,
    ],
]

Result Details

Members
VpcOriginList
Type: VpcOriginList structure

List of VPC origins.

Errors

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

Examples

Example 1: To list VPC origins

The following command lists VPC origins:

$result = $client->listVpcOrigins([
]);

Result syntax:

[
    'VpcOriginList' => [
        'IsTruncated' => 1,
        'Items' => [
            [
                'Arn' => 'arn:aws:cloudfront::123456789012:vpcorigin/vo_BQwjxxQxjCaBcQLzJUFkDM',
                'CreatedTime' => ,
                'Id' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
                'LastModifiedTime' => ,
                'Name' => 'my-vpcorigin-name',
                'OriginEndpointArn' => 'arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/my-alb-us-west-2/e6aa5c7d26415c6d',
                'Status' => 'Deployed',
            ],
        ],
        'Marker' => 'a',
        'MaxItems' => 100,
        'Quantity' => 1,
    ],
]

PublishFunction

$result = $client->publishFunction([/* ... */]);
$promise = $client->publishFunctionAsync([/* ... */]);

Publishes a CloudFront function by copying the function code from the DEVELOPMENT stage to LIVE. This automatically updates all cache behaviors that are using this function to use the newly published copy in the LIVE stage.

When a function is published to the LIVE stage, you can attach the function to a distribution's cache behavior, using the function's Amazon Resource Name (ARN).

To publish a function, you must provide the function's name and version (ETag value). To get these values, you can use ListFunctions and DescribeFunction.

Parameter Syntax

$result = $client->publishFunction([
    'IfMatch' => '<string>', // REQUIRED
    'Name' => '<string>', // REQUIRED
]);

Parameter Details

Members
IfMatch
Required: Yes
Type: string

The current version (ETag value) of the function that you are publishing, which you can get using DescribeFunction.

Name
Required: Yes
Type: string

The name of the function that you are publishing.

Result Syntax

[
    'FunctionSummary' => [
        'FunctionConfig' => [
            'Comment' => '<string>',
            'KeyValueStoreAssociations' => [
                'Items' => [
                    [
                        'KeyValueStoreARN' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Runtime' => 'cloudfront-js-1.0|cloudfront-js-2.0',
        ],
        'FunctionMetadata' => [
            'CreatedTime' => <DateTime>,
            'FunctionARN' => '<string>',
            'LastModifiedTime' => <DateTime>,
            'Stage' => 'DEVELOPMENT|LIVE',
        ],
        'Name' => '<string>',
        'Status' => '<string>',
    ],
]

Result Details

Members
FunctionSummary
Type: FunctionSummary structure

Contains configuration information and metadata about a CloudFront function.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

NoSuchFunctionExists:

The function does not exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

TagResource

$result = $client->tagResource([/* ... */]);
$promise = $client->tagResourceAsync([/* ... */]);

Add tags to a CloudFront resource. For more information, see Tagging a distribution in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->tagResource([
    'Resource' => '<string>', // REQUIRED
    'Tags' => [ // REQUIRED
        'Items' => [
            [
                'Key' => '<string>', // REQUIRED
                'Value' => '<string>',
            ],
            // ...
        ],
    ],
]);

Parameter Details

Members
Resource
Required: Yes
Type: string

An ARN of a CloudFront resource.

Tags
Required: Yes
Type: Tags structure

A complex type that contains zero or more Tag elements.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

AccessDenied:

Access denied.

InvalidTagging:

The tagging specified is not valid.

InvalidArgument:

An argument is invalid.

NoSuchResource:

A resource that was specified is not valid.

TestFunction

$result = $client->testFunction([/* ... */]);
$promise = $client->testFunctionAsync([/* ... */]);

Tests a CloudFront function.

To test a function, you provide an event object that represents an HTTP request or response that your CloudFront distribution could receive in production. CloudFront runs the function, passing it the event object that you provided, and returns the function's result (the modified event object) in the response. The response also contains function logs and error messages, if any exist. For more information about testing functions, see Testing functions in the Amazon CloudFront Developer Guide.

To test a function, you provide the function's name and version (ETag value) along with the event object. To get the function's name and version, you can use ListFunctions and DescribeFunction.

Parameter Syntax

$result = $client->testFunction([
    'EventObject' => <string || resource || Psr\Http\Message\StreamInterface>, // REQUIRED
    'IfMatch' => '<string>', // REQUIRED
    'Name' => '<string>', // REQUIRED
    'Stage' => 'DEVELOPMENT|LIVE',
]);

Parameter Details

Members
EventObject
Required: Yes
Type: blob (string|resource|Psr\Http\Message\StreamInterface)

The event object to test the function with. For more information about the structure of the event object, see Testing functions in the Amazon CloudFront Developer Guide.

IfMatch
Required: Yes
Type: string

The current version (ETag value) of the function that you are testing, which you can get using DescribeFunction.

Name
Required: Yes
Type: string

The name of the function that you are testing.

Stage
Type: string

The stage of the function that you are testing, either DEVELOPMENT or LIVE.

Result Syntax

[
    'TestResult' => [
        'ComputeUtilization' => '<string>',
        'FunctionErrorMessage' => '<string>',
        'FunctionExecutionLogs' => ['<string>', ...],
        'FunctionOutput' => '<string>',
        'FunctionSummary' => [
            'FunctionConfig' => [
                'Comment' => '<string>',
                'KeyValueStoreAssociations' => [
                    'Items' => [
                        [
                            'KeyValueStoreARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'Runtime' => 'cloudfront-js-1.0|cloudfront-js-2.0',
            ],
            'FunctionMetadata' => [
                'CreatedTime' => <DateTime>,
                'FunctionARN' => '<string>',
                'LastModifiedTime' => <DateTime>,
                'Stage' => 'DEVELOPMENT|LIVE',
            ],
            'Name' => '<string>',
            'Status' => '<string>',
        ],
    ],
]

Result Details

Members
TestResult
Type: TestResult structure

An object that represents the result of running the function with the provided event object.

Errors

TestFunctionFailed:

The CloudFront function failed.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

NoSuchFunctionExists:

The function does not exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UntagResource

$result = $client->untagResource([/* ... */]);
$promise = $client->untagResourceAsync([/* ... */]);

Remove tags from a CloudFront resource. For more information, see Tagging a distribution in the Amazon CloudFront Developer Guide.

Parameter Syntax

$result = $client->untagResource([
    'Resource' => '<string>', // REQUIRED
    'TagKeys' => [ // REQUIRED
        'Items' => ['<string>', ...],
    ],
]);

Parameter Details

Members
Resource
Required: Yes
Type: string

An ARN of a CloudFront resource.

TagKeys
Required: Yes
Type: TagKeys structure

A complex type that contains zero or more Tag key elements.

Result Syntax

[]

Result Details

The results for this operation are always empty.

Errors

AccessDenied:

Access denied.

InvalidTagging:

The tagging specified is not valid.

InvalidArgument:

An argument is invalid.

NoSuchResource:

A resource that was specified is not valid.

UpdateCachePolicy

$result = $client->updateCachePolicy([/* ... */]);
$promise = $client->updateCachePolicyAsync([/* ... */]);

Updates a cache policy configuration.

When you update a cache policy configuration, all the fields are updated with the values provided in the request. You cannot update some fields independent of others. To update a cache policy configuration:

  1. Use GetCachePolicyConfig to get the current configuration.

  2. Locally modify the fields in the cache policy configuration that you want to update.

  3. Call UpdateCachePolicy by providing the entire cache policy configuration, including the fields that you modified and those that you didn't.

Parameter Syntax

$result = $client->updateCachePolicy([
    'CachePolicyConfig' => [ // REQUIRED
        'Comment' => '<string>',
        'DefaultTTL' => <integer>,
        'MaxTTL' => <integer>,
        'MinTTL' => <integer>, // REQUIRED
        'Name' => '<string>', // REQUIRED
        'ParametersInCacheKeyAndForwardedToOrigin' => [
            'CookiesConfig' => [ // REQUIRED
                'CookieBehavior' => 'none|whitelist|allExcept|all', // REQUIRED
                'Cookies' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
            ],
            'EnableAcceptEncodingBrotli' => true || false,
            'EnableAcceptEncodingGzip' => true || false, // REQUIRED
            'HeadersConfig' => [ // REQUIRED
                'HeaderBehavior' => 'none|whitelist', // REQUIRED
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
            ],
            'QueryStringsConfig' => [ // REQUIRED
                'QueryStringBehavior' => 'none|whitelist|allExcept|all', // REQUIRED
                'QueryStrings' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
            ],
        ],
    ],
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
CachePolicyConfig
Required: Yes
Type: CachePolicyConfig structure

A cache policy configuration.

Id
Required: Yes
Type: string

The unique identifier for the cache policy that you are updating. The identifier is returned in a cache behavior's CachePolicyId field in the response to GetDistributionConfig.

IfMatch
Type: string

The version of the cache policy that you are updating. The version is returned in the cache policy's ETag field in the response to GetCachePolicyConfig.

Result Syntax

[
    'CachePolicy' => [
        'CachePolicyConfig' => [
            'Comment' => '<string>',
            'DefaultTTL' => <integer>,
            'MaxTTL' => <integer>,
            'MinTTL' => <integer>,
            'Name' => '<string>',
            'ParametersInCacheKeyAndForwardedToOrigin' => [
                'CookiesConfig' => [
                    'CookieBehavior' => 'none|whitelist|allExcept|all',
                    'Cookies' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'EnableAcceptEncodingBrotli' => true || false,
                'EnableAcceptEncodingGzip' => true || false,
                'HeadersConfig' => [
                    'HeaderBehavior' => 'none|whitelist',
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'QueryStringsConfig' => [
                    'QueryStringBehavior' => 'none|whitelist|allExcept|all',
                    'QueryStrings' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
    'ETag' => '<string>',
]

Result Details

Members
CachePolicy
Type: CachePolicy structure

A cache policy.

ETag
Type: string

The current version of the cache policy.

Errors

NoSuchCachePolicy:

The cache policy does not exist.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

TooManyHeadersInCachePolicy:

The number of headers in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

CachePolicyAlreadyExists:

A cache policy with this name already exists. You must provide a unique name. To modify an existing cache policy, use UpdateCachePolicy.

TooManyCookiesInCachePolicy:

The number of cookies in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidArgument:

An argument is invalid.

IllegalUpdate:

The update contains modifications that are not allowed.

TooManyQueryStringsInCachePolicy:

The number of query strings in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UpdateCloudFrontOriginAccessIdentity

$result = $client->updateCloudFrontOriginAccessIdentity([/* ... */]);
$promise = $client->updateCloudFrontOriginAccessIdentityAsync([/* ... */]);

Update an origin access identity.

Parameter Syntax

$result = $client->updateCloudFrontOriginAccessIdentity([
    'CloudFrontOriginAccessIdentityConfig' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>', // REQUIRED
    ],
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
CloudFrontOriginAccessIdentityConfig
Required: Yes
Type: CloudFrontOriginAccessIdentityConfig structure

The identity's configuration information.

Id
Required: Yes
Type: string

The identity's id.

IfMatch
Type: string

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

Result Syntax

[
    'CloudFrontOriginAccessIdentity' => [
        'CloudFrontOriginAccessIdentityConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
        ],
        'Id' => '<string>',
        'S3CanonicalUserId' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
CloudFrontOriginAccessIdentity

The origin access identity's information.

ETag
Type: string

The current version of the configuration. For example: E2QWRUHAPOMQZL.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidArgument:

An argument is invalid.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

NoSuchCloudFrontOriginAccessIdentity:

The specified origin access identity does not exist.

UpdateContinuousDeploymentPolicy

$result = $client->updateContinuousDeploymentPolicy([/* ... */]);
$promise = $client->updateContinuousDeploymentPolicyAsync([/* ... */]);

Updates a continuous deployment policy. You can update a continuous deployment policy to enable or disable it, to change the percentage of traffic that it sends to the staging distribution, or to change the staging distribution that it sends traffic to.

When you update a continuous deployment policy configuration, all the fields are updated with the values that are provided in the request. You cannot update some fields independent of others. To update a continuous deployment policy configuration:

  1. Use GetContinuousDeploymentPolicyConfig to get the current configuration.

  2. Locally modify the fields in the continuous deployment policy configuration that you want to update.

  3. Use UpdateContinuousDeploymentPolicy, providing the entire continuous deployment policy configuration, including the fields that you modified and those that you didn't.

Parameter Syntax

$result = $client->updateContinuousDeploymentPolicy([
    'ContinuousDeploymentPolicyConfig' => [ // REQUIRED
        'Enabled' => true || false, // REQUIRED
        'StagingDistributionDnsNames' => [ // REQUIRED
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
        'TrafficConfig' => [
            'SingleHeaderConfig' => [
                'Header' => '<string>', // REQUIRED
                'Value' => '<string>', // REQUIRED
            ],
            'SingleWeightConfig' => [
                'SessionStickinessConfig' => [
                    'IdleTTL' => <integer>, // REQUIRED
                    'MaximumTTL' => <integer>, // REQUIRED
                ],
                'Weight' => <float>, // REQUIRED
            ],
            'Type' => 'SingleWeight|SingleHeader', // REQUIRED
        ],
    ],
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
ContinuousDeploymentPolicyConfig
Required: Yes
Type: ContinuousDeploymentPolicyConfig structure

The continuous deployment policy configuration.

Id
Required: Yes
Type: string

The identifier of the continuous deployment policy that you are updating.

IfMatch
Type: string

The current version (ETag value) of the continuous deployment policy that you are updating.

Result Syntax

[
    'ContinuousDeploymentPolicy' => [
        'ContinuousDeploymentPolicyConfig' => [
            'Enabled' => true || false,
            'StagingDistributionDnsNames' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'TrafficConfig' => [
                'SingleHeaderConfig' => [
                    'Header' => '<string>',
                    'Value' => '<string>',
                ],
                'SingleWeightConfig' => [
                    'SessionStickinessConfig' => [
                        'IdleTTL' => <integer>,
                        'MaximumTTL' => <integer>,
                    ],
                    'Weight' => <float>,
                ],
                'Type' => 'SingleWeight|SingleHeader',
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
    'ETag' => '<string>',
]

Result Details

Members
ContinuousDeploymentPolicy
Type: ContinuousDeploymentPolicy structure

A continuous deployment policy.

ETag
Type: string

The version identifier for the current version of the continuous deployment policy.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

StagingDistributionInUse:

A continuous deployment policy for this staging distribution already exists.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidArgument:

An argument is invalid.

NoSuchContinuousDeploymentPolicy:

The continuous deployment policy doesn't exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UpdateDistribution

$result = $client->updateDistribution([/* ... */]);
$promise = $client->updateDistributionAsync([/* ... */]);

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 copy the ETag field value from the response. (You'll use it for the IfMatch parameter in your request.) Then, remove the ETag field from the distribution configuration.

    • You can't change the value of CallerReference.

  3. Submit an UpdateDistribution request, providing the updated 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.

Parameter Syntax

$result = $client->updateDistribution([
    'DistributionConfig' => [ // REQUIRED
        'Aliases' => [
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
        'AnycastIpListId' => '<string>',
        'CacheBehaviors' => [
            'Items' => [
                [
                    'AllowedMethods' => [
                        'CachedMethods' => [
                            'Items' => ['<string>', ...], // REQUIRED
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'Items' => ['<string>', ...], // REQUIRED
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'CachePolicyId' => '<string>',
                    'Compress' => true || false,
                    'DefaultTTL' => <integer>,
                    'FieldLevelEncryptionId' => '<string>',
                    'ForwardedValues' => [
                        'Cookies' => [ // REQUIRED
                            'Forward' => 'none|whitelist|all', // REQUIRED
                            'WhitelistedNames' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>, // REQUIRED
                            ],
                        ],
                        'Headers' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                        'QueryString' => true || false, // REQUIRED
                        'QueryStringCacheKeys' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>, // REQUIRED
                        ],
                    ],
                    'FunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                                'FunctionARN' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'GrpcConfig' => [
                        'Enabled' => true || false, // REQUIRED
                    ],
                    'LambdaFunctionAssociations' => [
                        'Items' => [
                            [
                                'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                                'IncludeBody' => true || false,
                                'LambdaFunctionARN' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'MaxTTL' => <integer>,
                    'MinTTL' => <integer>,
                    'OriginRequestPolicyId' => '<string>',
                    'PathPattern' => '<string>', // REQUIRED
                    'RealtimeLogConfigArn' => '<string>',
                    'ResponseHeadersPolicyId' => '<string>',
                    'SmoothStreaming' => true || false,
                    'TargetOriginId' => '<string>', // REQUIRED
                    'TrustedKeyGroups' => [
                        'Enabled' => true || false, // REQUIRED
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'TrustedSigners' => [
                        'Enabled' => true || false, // REQUIRED
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>', // REQUIRED
        'ContinuousDeploymentPolicyId' => '<string>',
        'CustomErrorResponses' => [
            'Items' => [
                [
                    'ErrorCachingMinTTL' => <integer>,
                    'ErrorCode' => <integer>, // REQUIRED
                    'ResponseCode' => '<string>',
                    'ResponsePagePath' => '<string>',
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'DefaultCacheBehavior' => [ // REQUIRED
            'AllowedMethods' => [
                'CachedMethods' => [
                    'Items' => ['<string>', ...], // REQUIRED
                    'Quantity' => <integer>, // REQUIRED
                ],
                'Items' => ['<string>', ...], // REQUIRED
                'Quantity' => <integer>, // REQUIRED
            ],
            'CachePolicyId' => '<string>',
            'Compress' => true || false,
            'DefaultTTL' => <integer>,
            'FieldLevelEncryptionId' => '<string>',
            'ForwardedValues' => [
                'Cookies' => [ // REQUIRED
                    'Forward' => 'none|whitelist|all', // REQUIRED
                    'WhitelistedNames' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                ],
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
                'QueryString' => true || false, // REQUIRED
                'QueryStringCacheKeys' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>, // REQUIRED
                ],
            ],
            'FunctionAssociations' => [
                'Items' => [
                    [
                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                        'FunctionARN' => '<string>', // REQUIRED
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'GrpcConfig' => [
                'Enabled' => true || false, // REQUIRED
            ],
            'LambdaFunctionAssociations' => [
                'Items' => [
                    [
                        'EventType' => 'viewer-request|viewer-response|origin-request|origin-response', // REQUIRED
                        'IncludeBody' => true || false,
                        'LambdaFunctionARN' => '<string>', // REQUIRED
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'MaxTTL' => <integer>,
            'MinTTL' => <integer>,
            'OriginRequestPolicyId' => '<string>',
            'RealtimeLogConfigArn' => '<string>',
            'ResponseHeadersPolicyId' => '<string>',
            'SmoothStreaming' => true || false,
            'TargetOriginId' => '<string>', // REQUIRED
            'TrustedKeyGroups' => [
                'Enabled' => true || false, // REQUIRED
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
            'TrustedSigners' => [
                'Enabled' => true || false, // REQUIRED
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
            'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https', // REQUIRED
        ],
        'DefaultRootObject' => '<string>',
        'Enabled' => true || false, // REQUIRED
        'HttpVersion' => 'http1.1|http2|http3|http2and3',
        'IsIPV6Enabled' => true || false,
        'Logging' => [
            'Bucket' => '<string>',
            'Enabled' => true || false,
            'IncludeCookies' => true || false,
            'Prefix' => '<string>',
        ],
        'OriginGroups' => [
            'Items' => [
                [
                    'FailoverCriteria' => [ // REQUIRED
                        'StatusCodes' => [ // REQUIRED
                            'Items' => [<integer>, ...], // REQUIRED
                            'Quantity' => <integer>, // REQUIRED
                        ],
                    ],
                    'Id' => '<string>', // REQUIRED
                    'Members' => [ // REQUIRED
                        'Items' => [ // REQUIRED
                            [
                                'OriginId' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'SelectionCriteria' => 'default|media-quality-based',
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'Origins' => [ // REQUIRED
            'Items' => [ // REQUIRED
                [
                    'ConnectionAttempts' => <integer>,
                    'ConnectionTimeout' => <integer>,
                    'CustomHeaders' => [
                        'Items' => [
                            [
                                'HeaderName' => '<string>', // REQUIRED
                                'HeaderValue' => '<string>', // REQUIRED
                            ],
                            // ...
                        ],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'CustomOriginConfig' => [
                        'HTTPPort' => <integer>, // REQUIRED
                        'HTTPSPort' => <integer>, // REQUIRED
                        'OriginKeepaliveTimeout' => <integer>,
                        'OriginProtocolPolicy' => 'http-only|match-viewer|https-only', // REQUIRED
                        'OriginReadTimeout' => <integer>,
                        'OriginSslProtocols' => [
                            'Items' => ['<string>', ...], // REQUIRED
                            'Quantity' => <integer>, // REQUIRED
                        ],
                    ],
                    'DomainName' => '<string>', // REQUIRED
                    'Id' => '<string>', // REQUIRED
                    'OriginAccessControlId' => '<string>',
                    'OriginPath' => '<string>',
                    'OriginShield' => [
                        'Enabled' => true || false, // REQUIRED
                        'OriginShieldRegion' => '<string>',
                    ],
                    'S3OriginConfig' => [
                        'OriginAccessIdentity' => '<string>', // REQUIRED
                    ],
                    'VpcOriginConfig' => [
                        'OriginKeepaliveTimeout' => <integer>,
                        'OriginReadTimeout' => <integer>,
                        'VpcOriginId' => '<string>', // REQUIRED
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
        'Restrictions' => [
            'GeoRestriction' => [ // REQUIRED
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
                'RestrictionType' => 'blacklist|whitelist|none', // REQUIRED
            ],
        ],
        'Staging' => true || false,
        'ViewerCertificate' => [
            'ACMCertificateArn' => '<string>',
            'Certificate' => '<string>',
            'CertificateSource' => 'cloudfront|iam|acm',
            'CloudFrontDefaultCertificate' => true || false,
            'IAMCertificateId' => '<string>',
            'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
            'SSLSupportMethod' => 'sni-only|vip|static-ip',
        ],
        'WebACLId' => '<string>',
    ],
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
DistributionConfig
Required: Yes
Type: DistributionConfig structure

The distribution's configuration information.

Id
Required: Yes
Type: string

The distribution's id.

IfMatch
Type: string

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

Result Syntax

[
    'Distribution' => [
        'ARN' => '<string>',
        'ActiveTrustedKeyGroups' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'KeyGroupId' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'AliasICPRecordals' => [
            [
                'CNAME' => '<string>',
                'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
            ],
            // ...
        ],
        'DistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AnycastIpListId' => '<string>',
            'CacheBehaviors' => [
                'Items' => [
                    [
                        'AllowedMethods' => [
                            'CachedMethods' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'CachePolicyId' => '<string>',
                        'Compress' => true || false,
                        'DefaultTTL' => <integer>,
                        'FieldLevelEncryptionId' => '<string>',
                        'ForwardedValues' => [
                            'Cookies' => [
                                'Forward' => 'none|whitelist|all',
                                'WhitelistedNames' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Headers' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'QueryString' => true || false,
                            'QueryStringCacheKeys' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'FunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'FunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'GrpcConfig' => [
                            'Enabled' => true || false,
                        ],
                        'LambdaFunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'IncludeBody' => true || false,
                                    'LambdaFunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'MaxTTL' => <integer>,
                        'MinTTL' => <integer>,
                        'OriginRequestPolicyId' => '<string>',
                        'PathPattern' => '<string>',
                        'RealtimeLogConfigArn' => '<string>',
                        'ResponseHeadersPolicyId' => '<string>',
                        'SmoothStreaming' => true || false,
                        'TargetOriginId' => '<string>',
                        'TrustedKeyGroups' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'TrustedSigners' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContinuousDeploymentPolicyId' => '<string>',
            'CustomErrorResponses' => [
                'Items' => [
                    [
                        'ErrorCachingMinTTL' => <integer>,
                        'ErrorCode' => <integer>,
                        'ResponseCode' => '<string>',
                        'ResponsePagePath' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'DefaultCacheBehavior' => [
                'AllowedMethods' => [
                    'CachedMethods' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'CachePolicyId' => '<string>',
                'Compress' => true || false,
                'DefaultTTL' => <integer>,
                'FieldLevelEncryptionId' => '<string>',
                'ForwardedValues' => [
                    'Cookies' => [
                        'Forward' => 'none|whitelist|all',
                        'WhitelistedNames' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'QueryString' => true || false,
                    'QueryStringCacheKeys' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'FunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'FunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'GrpcConfig' => [
                    'Enabled' => true || false,
                ],
                'LambdaFunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'IncludeBody' => true || false,
                            'LambdaFunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'MaxTTL' => <integer>,
                'MinTTL' => <integer>,
                'OriginRequestPolicyId' => '<string>',
                'RealtimeLogConfigArn' => '<string>',
                'ResponseHeadersPolicyId' => '<string>',
                'SmoothStreaming' => true || false,
                'TargetOriginId' => '<string>',
                'TrustedKeyGroups' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'TrustedSigners' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
            ],
            'DefaultRootObject' => '<string>',
            'Enabled' => true || false,
            'HttpVersion' => 'http1.1|http2|http3|http2and3',
            'IsIPV6Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'IncludeCookies' => true || false,
                'Prefix' => '<string>',
            ],
            'OriginGroups' => [
                'Items' => [
                    [
                        'FailoverCriteria' => [
                            'StatusCodes' => [
                                'Items' => [<integer>, ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Id' => '<string>',
                        'Members' => [
                            'Items' => [
                                [
                                    'OriginId' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'SelectionCriteria' => 'default|media-quality-based',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Origins' => [
                'Items' => [
                    [
                        'ConnectionAttempts' => <integer>,
                        'ConnectionTimeout' => <integer>,
                        'CustomHeaders' => [
                            'Items' => [
                                [
                                    'HeaderName' => '<string>',
                                    'HeaderValue' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'CustomOriginConfig' => [
                            'HTTPPort' => <integer>,
                            'HTTPSPort' => <integer>,
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                            'OriginReadTimeout' => <integer>,
                            'OriginSslProtocols' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'DomainName' => '<string>',
                        'Id' => '<string>',
                        'OriginAccessControlId' => '<string>',
                        'OriginPath' => '<string>',
                        'OriginShield' => [
                            'Enabled' => true || false,
                            'OriginShieldRegion' => '<string>',
                        ],
                        'S3OriginConfig' => [
                            'OriginAccessIdentity' => '<string>',
                        ],
                        'VpcOriginConfig' => [
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginReadTimeout' => <integer>,
                            'VpcOriginId' => '<string>',
                        ],
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'Restrictions' => [
                'GeoRestriction' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                    'RestrictionType' => 'blacklist|whitelist|none',
                ],
            ],
            'Staging' => true || false,
            'ViewerCertificate' => [
                'ACMCertificateArn' => '<string>',
                'Certificate' => '<string>',
                'CertificateSource' => 'cloudfront|iam|acm',
                'CloudFrontDefaultCertificate' => true || false,
                'IAMCertificateId' => '<string>',
                'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                'SSLSupportMethod' => 'sni-only|vip|static-ip',
            ],
            'WebACLId' => '<string>',
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'InProgressInvalidationBatches' => <integer>,
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
Distribution
Type: Distribution structure

The distribution's information.

ETag
Type: string

The current version of the configuration. For example: E2QWRUHAPOMQZL.

Errors

AccessDenied:

Access denied.

TooManyDistributionsAssociatedToOriginAccessControl:

The maximum number of distributions have been associated with the specified origin access control.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidDefaultRootObject:

The default root object file name is too big or contains an invalid character.

InvalidDomainNameForOriginAccessControl:

An origin access control is associated with an origin whose domain name is not supported.

InvalidQueryStringParameters:

The query string parameters specified are not valid.

TooManyTrustedSigners:

Your request contains more trusted signers than are allowed per distribution.

TooManyCookieNamesInWhiteList:

Your request contains more cookie names in the whitelist than are allowed per cache behavior.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

InvalidErrorCode:

An invalid error code was specified.

IllegalOriginAccessConfiguration:

An origin cannot contain both an origin access control (OAC) and an origin access identity (OAI).

TooManyFunctionAssociations:

You have reached the maximum number of CloudFront function associations for this distribution. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginCustomHeaders:

Your request contains too many origin custom headers.

InvalidForwardCookies:

Your request contains forward cookies option which doesn't match with the expectation for the whitelisted list of cookie names. Either list of cookie names has been specified when not allowed or list of cookie names is missing when expected.

InvalidMinimumProtocolVersion:

The minimum protocol version specified is not valid.

NoSuchCachePolicy:

The cache policy does not exist.

TooManyKeyGroupsAssociatedToDistribution:

The number of key groups referenced by this distribution is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyDistributionsAssociatedToCachePolicy:

The maximum number of distributions have been associated with the specified cache policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidRequiredProtocol:

This operation requires the HTTPS protocol. Ensure that you specify the HTTPS protocol in your request, or omit the RequiredProtocols element from your distribution configuration.

TooManyDistributionsWithFunctionAssociations:

You have reached the maximum number of distributions that are associated with a CloudFront function. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginGroupsPerDistribution:

Processing your request would cause you to exceed the maximum number of origin groups allowed.

InvalidTTLOrder:

The TTL order specified is not valid.

IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior:

The specified configuration for field-level encryption can't be associated with the specified cache behavior.

InvalidOriginKeepaliveTimeout:

The keep alive timeout specified for the origin is not valid.

InvalidArgument:

An argument is invalid.

InvalidOriginReadTimeout:

The read timeout specified for the origin is not valid.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidOriginAccessControl:

The origin access control is not valid.

EntityNotFound:

The entity was not found.

StagingDistributionInUse:

A continuous deployment policy for this staging distribution already exists.

InvalidHeadersForS3Origin:

The headers specified are not valid for an Amazon S3 origin.

TrustedSignerDoesNotExist:

One or more of your trusted signers don't exist.

InvalidWebACLId:

A web ACL ID specified is not valid. To specify a web ACL created using the latest version of WAF, use the ACL ARN, for example arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/473e64fd-f30b-4765-81a0-62ad96dd167a. To specify a web ACL created using WAF Classic, use the ACL ID, for example 473e64fd-f30b-4765-81a0-62ad96dd167a.

TooManyDistributionsWithSingleFunctionARN:

The maximum number of distributions have been associated with the specified Lambda@Edge function.

InvalidRelativePath:

The relative path is too big, is not URL-encoded, or does not begin with a slash (/).

TooManyLambdaFunctionAssociations:

Your request contains more Lambda@Edge function associations than are allowed per distribution.

NoSuchDistribution:

The specified distribution does not exist.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

TooManyDistributionsAssociatedToFieldLevelEncryptionConfig:

The maximum number of distributions have been associated with the specified configuration for field-level encryption.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidLocationCode:

The location code specified is not valid.

InvalidOriginAccessIdentity:

The origin access identity is not valid or doesn't exist.

TooManyDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

NoSuchContinuousDeploymentPolicy:

The continuous deployment policy doesn't exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

TooManyDistributionsAssociatedToOriginRequestPolicy:

The maximum number of distributions have been associated with the specified origin request policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyQueryStringParameters:

Your request contains too many query string parameters.

RealtimeLogConfigOwnerMismatch:

The specified real-time log configuration belongs to a different Amazon Web Services account.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

ContinuousDeploymentPolicyInUse:

You cannot delete a continuous deployment policy that is associated with a primary distribution.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyHeadersInForwardedValues:

Your request contains too many headers in forwarded values.

InvalidLambdaFunctionAssociation:

The specified Lambda@Edge function association is invalid.

CNAMEAlreadyExists:

The CNAME specified is already defined for CloudFront.

TooManyCertificates:

You cannot create anymore custom SSL/TLS certificates.

TrustedKeyGroupDoesNotExist:

The specified key group does not exist.

TooManyDistributionsAssociatedToResponseHeadersPolicy:

The maximum number of distributions have been associated with the specified response headers policy.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

InvalidResponseCode:

A response code is not valid.

InvalidGeoRestrictionParameter:

The specified geo restriction parameter is not valid.

TooManyOrigins:

You cannot create more origins for the distribution.

InvalidViewerCertificate:

A viewer certificate specified is not valid.

InvalidFunctionAssociation:

A CloudFront function association is invalid.

TooManyDistributionsWithLambdaAssociations:

Processing your request would cause the maximum number of distributions with Lambda@Edge function associations per owner to be exceeded.

TooManyDistributionsAssociatedToKeyGroup:

The number of distributions that reference this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchOrigin:

No origin exists with the specified Origin Id.

TooManyCacheBehaviors:

You cannot create more cache behaviors for the distribution.

UpdateDistributionWithStagingConfig

$result = $client->updateDistributionWithStagingConfig([/* ... */]);
$promise = $client->updateDistributionWithStagingConfigAsync([/* ... */]);

Copies the staging distribution's configuration to its corresponding primary distribution. The primary distribution retains its Aliases (also known as alternate domain names or CNAMEs) and ContinuousDeploymentPolicyId value, but otherwise its configuration is overwritten to match the staging distribution.

You can use this operation in a continuous deployment workflow after you have tested configuration changes on the staging distribution. After using a continuous deployment policy to move a portion of your domain name's traffic to the staging distribution and verifying that it works as intended, you can use this operation to copy the staging distribution's configuration to the primary distribution. This action will disable the continuous deployment policy and move your domain's traffic back to the primary distribution.

This API operation requires the following IAM permissions:

Parameter Syntax

$result = $client->updateDistributionWithStagingConfig([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
    'StagingDistributionId' => '<string>',
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the primary distribution to which you are copying a staging distribution's configuration.

IfMatch
Type: string

The current versions (ETag values) of both primary and staging distributions. Provide these in the following format:

<primary ETag>, <staging ETag>

StagingDistributionId
Type: string

The identifier of the staging distribution whose configuration you are copying to the primary distribution.

Result Syntax

[
    'Distribution' => [
        'ARN' => '<string>',
        'ActiveTrustedKeyGroups' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'KeyGroupId' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'AliasICPRecordals' => [
            [
                'CNAME' => '<string>',
                'ICPRecordalStatus' => 'APPROVED|SUSPENDED|PENDING',
            ],
            // ...
        ],
        'DistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'AnycastIpListId' => '<string>',
            'CacheBehaviors' => [
                'Items' => [
                    [
                        'AllowedMethods' => [
                            'CachedMethods' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'CachePolicyId' => '<string>',
                        'Compress' => true || false,
                        'DefaultTTL' => <integer>,
                        'FieldLevelEncryptionId' => '<string>',
                        'ForwardedValues' => [
                            'Cookies' => [
                                'Forward' => 'none|whitelist|all',
                                'WhitelistedNames' => [
                                    'Items' => ['<string>', ...],
                                    'Quantity' => <integer>,
                                ],
                            ],
                            'Headers' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                            'QueryString' => true || false,
                            'QueryStringCacheKeys' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'FunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'FunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'GrpcConfig' => [
                            'Enabled' => true || false,
                        ],
                        'LambdaFunctionAssociations' => [
                            'Items' => [
                                [
                                    'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                                    'IncludeBody' => true || false,
                                    'LambdaFunctionARN' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'MaxTTL' => <integer>,
                        'MinTTL' => <integer>,
                        'OriginRequestPolicyId' => '<string>',
                        'PathPattern' => '<string>',
                        'RealtimeLogConfigArn' => '<string>',
                        'ResponseHeadersPolicyId' => '<string>',
                        'SmoothStreaming' => true || false,
                        'TargetOriginId' => '<string>',
                        'TrustedKeyGroups' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'TrustedSigners' => [
                            'Enabled' => true || false,
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContinuousDeploymentPolicyId' => '<string>',
            'CustomErrorResponses' => [
                'Items' => [
                    [
                        'ErrorCachingMinTTL' => <integer>,
                        'ErrorCode' => <integer>,
                        'ResponseCode' => '<string>',
                        'ResponsePagePath' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'DefaultCacheBehavior' => [
                'AllowedMethods' => [
                    'CachedMethods' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'CachePolicyId' => '<string>',
                'Compress' => true || false,
                'DefaultTTL' => <integer>,
                'FieldLevelEncryptionId' => '<string>',
                'ForwardedValues' => [
                    'Cookies' => [
                        'Forward' => 'none|whitelist|all',
                        'WhitelistedNames' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                    ],
                    'Headers' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                    'QueryString' => true || false,
                    'QueryStringCacheKeys' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                'FunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'FunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'GrpcConfig' => [
                    'Enabled' => true || false,
                ],
                'LambdaFunctionAssociations' => [
                    'Items' => [
                        [
                            'EventType' => 'viewer-request|viewer-response|origin-request|origin-response',
                            'IncludeBody' => true || false,
                            'LambdaFunctionARN' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'MaxTTL' => <integer>,
                'MinTTL' => <integer>,
                'OriginRequestPolicyId' => '<string>',
                'RealtimeLogConfigArn' => '<string>',
                'ResponseHeadersPolicyId' => '<string>',
                'SmoothStreaming' => true || false,
                'TargetOriginId' => '<string>',
                'TrustedKeyGroups' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'TrustedSigners' => [
                    'Enabled' => true || false,
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'ViewerProtocolPolicy' => 'allow-all|https-only|redirect-to-https',
            ],
            'DefaultRootObject' => '<string>',
            'Enabled' => true || false,
            'HttpVersion' => 'http1.1|http2|http3|http2and3',
            'IsIPV6Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'IncludeCookies' => true || false,
                'Prefix' => '<string>',
            ],
            'OriginGroups' => [
                'Items' => [
                    [
                        'FailoverCriteria' => [
                            'StatusCodes' => [
                                'Items' => [<integer>, ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'Id' => '<string>',
                        'Members' => [
                            'Items' => [
                                [
                                    'OriginId' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'SelectionCriteria' => 'default|media-quality-based',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Origins' => [
                'Items' => [
                    [
                        'ConnectionAttempts' => <integer>,
                        'ConnectionTimeout' => <integer>,
                        'CustomHeaders' => [
                            'Items' => [
                                [
                                    'HeaderName' => '<string>',
                                    'HeaderValue' => '<string>',
                                ],
                                // ...
                            ],
                            'Quantity' => <integer>,
                        ],
                        'CustomOriginConfig' => [
                            'HTTPPort' => <integer>,
                            'HTTPSPort' => <integer>,
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
                            'OriginReadTimeout' => <integer>,
                            'OriginSslProtocols' => [
                                'Items' => ['<string>', ...],
                                'Quantity' => <integer>,
                            ],
                        ],
                        'DomainName' => '<string>',
                        'Id' => '<string>',
                        'OriginAccessControlId' => '<string>',
                        'OriginPath' => '<string>',
                        'OriginShield' => [
                            'Enabled' => true || false,
                            'OriginShieldRegion' => '<string>',
                        ],
                        'S3OriginConfig' => [
                            'OriginAccessIdentity' => '<string>',
                        ],
                        'VpcOriginConfig' => [
                            'OriginKeepaliveTimeout' => <integer>,
                            'OriginReadTimeout' => <integer>,
                            'VpcOriginId' => '<string>',
                        ],
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'Restrictions' => [
                'GeoRestriction' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                    'RestrictionType' => 'blacklist|whitelist|none',
                ],
            ],
            'Staging' => true || false,
            'ViewerCertificate' => [
                'ACMCertificateArn' => '<string>',
                'Certificate' => '<string>',
                'CertificateSource' => 'cloudfront|iam|acm',
                'CloudFrontDefaultCertificate' => true || false,
                'IAMCertificateId' => '<string>',
                'MinimumProtocolVersion' => 'SSLv3|TLSv1|TLSv1_2016|TLSv1.1_2016|TLSv1.2_2018|TLSv1.2_2019|TLSv1.2_2021',
                'SSLSupportMethod' => 'sni-only|vip|static-ip',
            ],
            'WebACLId' => '<string>',
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'InProgressInvalidationBatches' => <integer>,
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
    ],
    'ETag' => '<string>',
]

Result Details

Members
Distribution
Type: Distribution structure

A distribution tells CloudFront where you want content to be delivered from, and the details about how to track and manage content delivery.

ETag
Type: string

The current version of the primary distribution (after it's updated).

Errors

AccessDenied:

Access denied.

TooManyDistributionsAssociatedToOriginAccessControl:

The maximum number of distributions have been associated with the specified origin access control.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidDefaultRootObject:

The default root object file name is too big or contains an invalid character.

InvalidQueryStringParameters:

The query string parameters specified are not valid.

TooManyTrustedSigners:

Your request contains more trusted signers than are allowed per distribution.

TooManyCookieNamesInWhiteList:

Your request contains more cookie names in the whitelist than are allowed per cache behavior.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

InvalidErrorCode:

An invalid error code was specified.

TooManyFunctionAssociations:

You have reached the maximum number of CloudFront function associations for this distribution. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginCustomHeaders:

Your request contains too many origin custom headers.

InvalidForwardCookies:

Your request contains forward cookies option which doesn't match with the expectation for the whitelisted list of cookie names. Either list of cookie names has been specified when not allowed or list of cookie names is missing when expected.

InvalidMinimumProtocolVersion:

The minimum protocol version specified is not valid.

NoSuchCachePolicy:

The cache policy does not exist.

TooManyKeyGroupsAssociatedToDistribution:

The number of key groups referenced by this distribution is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyDistributionsAssociatedToCachePolicy:

The maximum number of distributions have been associated with the specified cache policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidRequiredProtocol:

This operation requires the HTTPS protocol. Ensure that you specify the HTTPS protocol in your request, or omit the RequiredProtocols element from your distribution configuration.

TooManyDistributionsWithFunctionAssociations:

You have reached the maximum number of distributions that are associated with a CloudFront function. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyOriginGroupsPerDistribution:

Processing your request would cause you to exceed the maximum number of origin groups allowed.

InvalidTTLOrder:

The TTL order specified is not valid.

IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior:

The specified configuration for field-level encryption can't be associated with the specified cache behavior.

InvalidOriginKeepaliveTimeout:

The keep alive timeout specified for the origin is not valid.

InvalidArgument:

An argument is invalid.

InvalidOriginReadTimeout:

The read timeout specified for the origin is not valid.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidOriginAccessControl:

The origin access control is not valid.

EntityNotFound:

The entity was not found.

InvalidHeadersForS3Origin:

The headers specified are not valid for an Amazon S3 origin.

TrustedSignerDoesNotExist:

One or more of your trusted signers don't exist.

InvalidWebACLId:

A web ACL ID specified is not valid. To specify a web ACL created using the latest version of WAF, use the ACL ARN, for example arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/473e64fd-f30b-4765-81a0-62ad96dd167a. To specify a web ACL created using WAF Classic, use the ACL ID, for example 473e64fd-f30b-4765-81a0-62ad96dd167a.

TooManyDistributionsWithSingleFunctionARN:

The maximum number of distributions have been associated with the specified Lambda@Edge function.

InvalidRelativePath:

The relative path is too big, is not URL-encoded, or does not begin with a slash (/).

TooManyLambdaFunctionAssociations:

Your request contains more Lambda@Edge function associations than are allowed per distribution.

NoSuchDistribution:

The specified distribution does not exist.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

TooManyDistributionsAssociatedToFieldLevelEncryptionConfig:

The maximum number of distributions have been associated with the specified configuration for field-level encryption.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidLocationCode:

The location code specified is not valid.

InvalidOriginAccessIdentity:

The origin access identity is not valid or doesn't exist.

TooManyDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

TooManyDistributionsAssociatedToOriginRequestPolicy:

The maximum number of distributions have been associated with the specified origin request policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

TooManyQueryStringParameters:

Your request contains too many query string parameters.

RealtimeLogConfigOwnerMismatch:

The specified real-time log configuration belongs to a different Amazon Web Services account.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyHeadersInForwardedValues:

Your request contains too many headers in forwarded values.

InvalidLambdaFunctionAssociation:

The specified Lambda@Edge function association is invalid.

CNAMEAlreadyExists:

The CNAME specified is already defined for CloudFront.

TooManyCertificates:

You cannot create anymore custom SSL/TLS certificates.

TrustedKeyGroupDoesNotExist:

The specified key group does not exist.

TooManyDistributionsAssociatedToResponseHeadersPolicy:

The maximum number of distributions have been associated with the specified response headers policy.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

InvalidResponseCode:

A response code is not valid.

InvalidGeoRestrictionParameter:

The specified geo restriction parameter is not valid.

TooManyOrigins:

You cannot create more origins for the distribution.

InvalidViewerCertificate:

A viewer certificate specified is not valid.

InvalidFunctionAssociation:

A CloudFront function association is invalid.

TooManyDistributionsWithLambdaAssociations:

Processing your request would cause the maximum number of distributions with Lambda@Edge function associations per owner to be exceeded.

TooManyDistributionsAssociatedToKeyGroup:

The number of distributions that reference this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchOrigin:

No origin exists with the specified Origin Id.

TooManyCacheBehaviors:

You cannot create more cache behaviors for the distribution.

UpdateFieldLevelEncryptionConfig

$result = $client->updateFieldLevelEncryptionConfig([/* ... */]);
$promise = $client->updateFieldLevelEncryptionConfigAsync([/* ... */]);

Update a field-level encryption configuration.

Parameter Syntax

$result = $client->updateFieldLevelEncryptionConfig([
    'FieldLevelEncryptionConfig' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>',
        'ContentTypeProfileConfig' => [
            'ContentTypeProfiles' => [
                'Items' => [
                    [
                        'ContentType' => '<string>', // REQUIRED
                        'Format' => 'URLEncoded', // REQUIRED
                        'ProfileId' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
            'ForwardWhenContentTypeIsUnknown' => true || false, // REQUIRED
        ],
        'QueryArgProfileConfig' => [
            'ForwardWhenQueryArgProfileIsUnknown' => true || false, // REQUIRED
            'QueryArgProfiles' => [
                'Items' => [
                    [
                        'ProfileId' => '<string>', // REQUIRED
                        'QueryArg' => '<string>', // REQUIRED
                    ],
                    // ...
                ],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
    ],
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
FieldLevelEncryptionConfig
Required: Yes
Type: FieldLevelEncryptionConfig structure

Request to update a field-level encryption configuration.

Id
Required: Yes
Type: string

The ID of the configuration you want to update.

IfMatch
Type: string

The value of the ETag header that you received when retrieving the configuration identity to update. For example: E2QWRUHAPOMQZL.

Result Syntax

[
    'ETag' => '<string>',
    'FieldLevelEncryption' => [
        'FieldLevelEncryptionConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'ContentTypeProfileConfig' => [
                'ContentTypeProfiles' => [
                    'Items' => [
                        [
                            'ContentType' => '<string>',
                            'Format' => 'URLEncoded',
                            'ProfileId' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
                'ForwardWhenContentTypeIsUnknown' => true || false,
            ],
            'QueryArgProfileConfig' => [
                'ForwardWhenQueryArgProfileIsUnknown' => true || false,
                'QueryArgProfiles' => [
                    'Items' => [
                        [
                            'ProfileId' => '<string>',
                            'QueryArg' => '<string>',
                        ],
                        // ...
                    ],
                    'Quantity' => <integer>,
                ],
            ],
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
]

Result Details

Members
ETag
Type: string

The value of the ETag header that you received when updating the configuration. For example: E2QWRUHAPOMQZL.

FieldLevelEncryption
Type: FieldLevelEncryption structure

Return the results of updating the configuration.

Errors

QueryArgProfileEmpty:

No profile specified for the field-level encryption query argument.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

TooManyFieldLevelEncryptionQueryArgProfiles:

The maximum number of query arg profiles for field-level encryption have been created.

NoSuchFieldLevelEncryptionConfig:

The specified configuration for field-level encryption doesn't exist.

TooManyFieldLevelEncryptionContentTypeProfiles:

The maximum number of content type profiles for field-level encryption have been created.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

NoSuchFieldLevelEncryptionProfile:

The specified profile for field-level encryption doesn't exist.

InvalidArgument:

An argument is invalid.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UpdateFieldLevelEncryptionProfile

$result = $client->updateFieldLevelEncryptionProfile([/* ... */]);
$promise = $client->updateFieldLevelEncryptionProfileAsync([/* ... */]);

Update a field-level encryption profile.

Parameter Syntax

$result = $client->updateFieldLevelEncryptionProfile([
    'FieldLevelEncryptionProfileConfig' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>',
        'EncryptionEntities' => [ // REQUIRED
            'Items' => [
                [
                    'FieldPatterns' => [ // REQUIRED
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>, // REQUIRED
                    ],
                    'ProviderId' => '<string>', // REQUIRED
                    'PublicKeyId' => '<string>', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'Name' => '<string>', // REQUIRED
    ],
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
]);

Parameter Details

Members
FieldLevelEncryptionProfileConfig
Required: Yes
Type: FieldLevelEncryptionProfileConfig structure

Request to update a field-level encryption profile.

Id
Required: Yes
Type: string

The ID of the field-level encryption profile request.

IfMatch
Type: string

The value of the ETag header that you received when retrieving the profile identity to update. For example: E2QWRUHAPOMQZL.

Result Syntax

[
    'ETag' => '<string>',
    'FieldLevelEncryptionProfile' => [
        'FieldLevelEncryptionProfileConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'EncryptionEntities' => [
                'Items' => [
                    [
                        'FieldPatterns' => [
                            'Items' => ['<string>', ...],
                            'Quantity' => <integer>,
                        ],
                        'ProviderId' => '<string>',
                        'PublicKeyId' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Name' => '<string>',
        ],
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
    ],
]

Result Details

Members
ETag
Type: string

The result of the field-level encryption profile request.

FieldLevelEncryptionProfile
Type: FieldLevelEncryptionProfile structure

Return the results of updating the profile.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

TooManyFieldLevelEncryptionFieldPatterns:

The maximum number of field patterns for field-level encryption have been created.

AccessDenied:

Access denied.

FieldLevelEncryptionProfileAlreadyExists:

The specified profile for field-level encryption already exists.

NoSuchPublicKey:

The specified public key doesn't exist.

FieldLevelEncryptionProfileSizeExceeded:

The maximum size of a profile for field-level encryption was exceeded.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

NoSuchFieldLevelEncryptionProfile:

The specified profile for field-level encryption doesn't exist.

TooManyFieldLevelEncryptionEncryptionEntities:

The maximum number of encryption entities for field-level encryption have been created.

InvalidArgument:

An argument is invalid.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UpdateFunction

$result = $client->updateFunction([/* ... */]);
$promise = $client->updateFunctionAsync([/* ... */]);

Updates a CloudFront function.

You can update a function's code or the comment that describes the function. You cannot update a function's name.

To update a function, you provide the function's name and version (ETag value) along with the updated function code. To get the name and version, you can use ListFunctions and DescribeFunction.

Parameter Syntax

$result = $client->updateFunction([
    'FunctionCode' => <string || resource || Psr\Http\Message\StreamInterface>, // REQUIRED
    'FunctionConfig' => [ // REQUIRED
        'Comment' => '<string>', // REQUIRED
        'KeyValueStoreAssociations' => [
            'Items' => [
                [
                    'KeyValueStoreARN' => '<string>', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'Runtime' => 'cloudfront-js-1.0|cloudfront-js-2.0', // REQUIRED
    ],
    'IfMatch' => '<string>', // REQUIRED
    'Name' => '<string>', // REQUIRED
]);

Parameter Details

Members
FunctionCode
Required: Yes
Type: blob (string|resource|Psr\Http\Message\StreamInterface)

The function code. For more information about writing a CloudFront function, see Writing function code for CloudFront Functions in the Amazon CloudFront Developer Guide.

FunctionConfig
Required: Yes
Type: FunctionConfig structure

Configuration information about the function.

IfMatch
Required: Yes
Type: string

The current version (ETag value) of the function that you are updating, which you can get using DescribeFunction.

Name
Required: Yes
Type: string

The name of the function that you are updating.

Result Syntax

[
    'ETag' => '<string>',
    'FunctionSummary' => [
        'FunctionConfig' => [
            'Comment' => '<string>',
            'KeyValueStoreAssociations' => [
                'Items' => [
                    [
                        'KeyValueStoreARN' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Runtime' => 'cloudfront-js-1.0|cloudfront-js-2.0',
        ],
        'FunctionMetadata' => [
            'CreatedTime' => <DateTime>,
            'FunctionARN' => '<string>',
            'LastModifiedTime' => <DateTime>,
            'Stage' => 'DEVELOPMENT|LIVE',
        ],
        'Name' => '<string>',
        'Status' => '<string>',
    ],
]

Result Details

Members
ETag
Type: string

The version identifier for the current version of the CloudFront function.

FunctionSummary
Type: FunctionSummary structure

Contains configuration information and metadata about a CloudFront function.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

UnsupportedOperation:

This operation is not supported in this region.

FunctionSizeLimitExceeded:

The function is too large. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

NoSuchFunctionExists:

The function does not exist.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

Examples

Example 1: To update a function

Use the following command to update a function.

$result = $client->updateFunction([
    'FunctionCode' => <BLOB>,
    'FunctionConfig' => [
        'Comment' => 'my-changed-comment',
        'KeyValueStoreAssociations' => [
            'Items' => [
                [
                    'KeyValueStoreARN' => 'arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
                ],
            ],
            'Quantity' => 1,
        ],
        'Runtime' => 'cloudfront-js-2.0',
    ],
    'IfMatch' => 'ETVPDKIKX0DER',
    'Name' => 'my-function-name',
]);

Result syntax:

[
    'ETag' => 'E3UN6WX5RRO2AG',
    'FunctionSummary' => [
        'FunctionConfig' => [
            'Comment' => 'my-changed-comment',
            'KeyValueStoreAssociations' => [
                'Items' => [
                    [
                        'KeyValueStoreARN' => 'arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
                    ],
                ],
                'Quantity' => 1,
            ],
            'Runtime' => 'cloudfront-js-2.0',
        ],
        'FunctionMetadata' => [
            'CreatedTime' => ,
            'FunctionARN' => 'arn:aws:cloudfront::123456789012:function/my-function-name',
            'LastModifiedTime' => ,
            'Stage' => 'DEVELOPMENT',
        ],
        'Name' => 'my-function-name',
        'Status' => 'UNPUBLISHED',
    ],
]

UpdateKeyGroup

$result = $client->updateKeyGroup([/* ... */]);
$promise = $client->updateKeyGroupAsync([/* ... */]);

Updates a key group.

When you update a key group, all the fields are updated with the values provided in the request. You cannot update some fields independent of others. To update a key group:

  1. Get the current key group with GetKeyGroup or GetKeyGroupConfig.

  2. Locally modify the fields in the key group that you want to update. For example, add or remove public key IDs.

  3. Call UpdateKeyGroup with the entire key group object, including the fields that you modified and those that you didn't.

Parameter Syntax

$result = $client->updateKeyGroup([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
    'KeyGroupConfig' => [ // REQUIRED
        'Comment' => '<string>',
        'Items' => ['<string>', ...], // REQUIRED
        'Name' => '<string>', // REQUIRED
    ],
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the key group that you are updating.

IfMatch
Type: string

The version of the key group that you are updating. The version is the key group's ETag value.

KeyGroupConfig
Required: Yes
Type: KeyGroupConfig structure

The key group configuration.

Result Syntax

[
    'ETag' => '<string>',
    'KeyGroup' => [
        'Id' => '<string>',
        'KeyGroupConfig' => [
            'Comment' => '<string>',
            'Items' => ['<string>', ...],
            'Name' => '<string>',
        ],
        'LastModifiedTime' => <DateTime>,
    ],
]

Result Details

Members
ETag
Type: string

The identifier for this version of the key group.

KeyGroup
Type: KeyGroup structure

The key group that was just updated.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

TooManyPublicKeysInKeyGroup:

The number of public keys in this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

NoSuchResource:

A resource that was specified is not valid.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

KeyGroupAlreadyExists:

A key group with this name already exists. You must provide a unique name. To modify an existing key group, use UpdateKeyGroup.

UpdateKeyValueStore

$result = $client->updateKeyValueStore([/* ... */]);
$promise = $client->updateKeyValueStoreAsync([/* ... */]);

Specifies the key value store to update.

Parameter Syntax

$result = $client->updateKeyValueStore([
    'Comment' => '<string>', // REQUIRED
    'IfMatch' => '<string>', // REQUIRED
    'Name' => '<string>', // REQUIRED
]);

Parameter Details

Members
Comment
Required: Yes
Type: string

The comment of the key value store to update.

IfMatch
Required: Yes
Type: string

The key value store to update, if a match occurs.

Name
Required: Yes
Type: string

The name of the key value store to update.

Result Syntax

[
    'ETag' => '<string>',
    'KeyValueStore' => [
        'ARN' => '<string>',
        'Comment' => '<string>',
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Name' => '<string>',
        'Status' => '<string>',
    ],
]

Result Details

Members
ETag
Type: string

The ETag of the resulting key value store.

KeyValueStore
Type: KeyValueStore structure

The resulting key value store to update.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InvalidArgument:

An argument is invalid.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

Examples

Example 1: To update a KeyValueStore

Use the following command to update a KeyValueStore.

$result = $client->updateKeyValueStore([
    'Comment' => 'my-changed-comment',
    'IfMatch' => 'ETVPDKIKX0DER',
    'Name' => 'my-keyvaluestore-name',
]);

Result syntax:

[
    'ETag' => 'E3UN6WX5RRO2AG',
    'KeyValueStore' => [
        'ARN' => 'arn:aws:cloudfront::123456789012:key-value-store/54947df8-0e9e-4471-a2f9-9af509fb5889',
        'Comment' => 'my-changed-comment',
        'Id' => '54947df8-0e9e-4471-a2f9-9af509fb5889',
        'LastModifiedTime' => ,
        'Name' => 'my-keyvaluestore-name',
        'Status' => 'READY',
    ],
]

UpdateOriginAccessControl

$result = $client->updateOriginAccessControl([/* ... */]);
$promise = $client->updateOriginAccessControlAsync([/* ... */]);

Updates a CloudFront origin access control.

Parameter Syntax

$result = $client->updateOriginAccessControl([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
    'OriginAccessControlConfig' => [ // REQUIRED
        'Description' => '<string>',
        'Name' => '<string>', // REQUIRED
        'OriginAccessControlOriginType' => 's3|mediastore|mediapackagev2|lambda', // REQUIRED
        'SigningBehavior' => 'never|always|no-override', // REQUIRED
        'SigningProtocol' => 'sigv4', // REQUIRED
    ],
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier of the origin access control that you are updating.

IfMatch
Type: string

The current version (ETag value) of the origin access control that you are updating.

OriginAccessControlConfig
Required: Yes
Type: OriginAccessControlConfig structure

An origin access control.

Result Syntax

[
    'ETag' => '<string>',
    'OriginAccessControl' => [
        'Id' => '<string>',
        'OriginAccessControlConfig' => [
            'Description' => '<string>',
            'Name' => '<string>',
            'OriginAccessControlOriginType' => 's3|mediastore|mediapackagev2|lambda',
            'SigningBehavior' => 'never|always|no-override',
            'SigningProtocol' => 'sigv4',
        ],
    ],
]

Result Details

Members
ETag
Type: string

The new version of the origin access control after it has been updated.

OriginAccessControl
Type: OriginAccessControl structure

The origin access control after it has been updated.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

OriginAccessControlAlreadyExists:

An origin access control with the specified parameters already exists.

AccessDenied:

Access denied.

NoSuchOriginAccessControl:

The origin access control does not exist.

InvalidArgument:

An argument is invalid.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UpdateOriginRequestPolicy

$result = $client->updateOriginRequestPolicy([/* ... */]);
$promise = $client->updateOriginRequestPolicyAsync([/* ... */]);

Updates an origin request policy configuration.

When you update an origin request policy configuration, all the fields are updated with the values provided in the request. You cannot update some fields independent of others. To update an origin request policy configuration:

  1. Use GetOriginRequestPolicyConfig to get the current configuration.

  2. Locally modify the fields in the origin request policy configuration that you want to update.

  3. Call UpdateOriginRequestPolicy by providing the entire origin request policy configuration, including the fields that you modified and those that you didn't.

Parameter Syntax

$result = $client->updateOriginRequestPolicy([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
    'OriginRequestPolicyConfig' => [ // REQUIRED
        'Comment' => '<string>',
        'CookiesConfig' => [ // REQUIRED
            'CookieBehavior' => 'none|whitelist|all|allExcept', // REQUIRED
            'Cookies' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
        'HeadersConfig' => [ // REQUIRED
            'HeaderBehavior' => 'none|whitelist|allViewer|allViewerAndWhitelistCloudFront|allExcept', // REQUIRED
            'Headers' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
        'Name' => '<string>', // REQUIRED
        'QueryStringsConfig' => [ // REQUIRED
            'QueryStringBehavior' => 'none|whitelist|all|allExcept', // REQUIRED
            'QueryStrings' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
        ],
    ],
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The unique identifier for the origin request policy that you are updating. The identifier is returned in a cache behavior's OriginRequestPolicyId field in the response to GetDistributionConfig.

IfMatch
Type: string

The version of the origin request policy that you are updating. The version is returned in the origin request policy's ETag field in the response to GetOriginRequestPolicyConfig.

OriginRequestPolicyConfig
Required: Yes
Type: OriginRequestPolicyConfig structure

An origin request policy configuration.

Result Syntax

[
    'ETag' => '<string>',
    'OriginRequestPolicy' => [
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'OriginRequestPolicyConfig' => [
            'Comment' => '<string>',
            'CookiesConfig' => [
                'CookieBehavior' => 'none|whitelist|all|allExcept',
                'Cookies' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'HeadersConfig' => [
                'HeaderBehavior' => 'none|whitelist|allViewer|allViewerAndWhitelistCloudFront|allExcept',
                'Headers' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
            'Name' => '<string>',
            'QueryStringsConfig' => [
                'QueryStringBehavior' => 'none|whitelist|all|allExcept',
                'QueryStrings' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the origin request policy.

OriginRequestPolicy
Type: OriginRequestPolicy structure

An origin request policy.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

TooManyHeadersInOriginRequestPolicy:

The number of headers in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchOriginRequestPolicy:

The origin request policy does not exist.

TooManyCookiesInOriginRequestPolicy:

The number of cookies in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

OriginRequestPolicyAlreadyExists:

An origin request policy with this name already exists. You must provide a unique name. To modify an existing origin request policy, use UpdateOriginRequestPolicy.

TooManyQueryStringsInOriginRequestPolicy:

The number of query strings in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

InvalidArgument:

An argument is invalid.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UpdatePublicKey

$result = $client->updatePublicKey([/* ... */]);
$promise = $client->updatePublicKeyAsync([/* ... */]);

Update public key information. Note that the only value you can change is the comment.

Parameter Syntax

$result = $client->updatePublicKey([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
    'PublicKeyConfig' => [ // REQUIRED
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>',
        'EncodedKey' => '<string>', // REQUIRED
        'Name' => '<string>', // REQUIRED
    ],
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier of the public key that you are updating.

IfMatch
Type: string

The value of the ETag header that you received when retrieving the public key to update. For example: E2QWRUHAPOMQZL.

PublicKeyConfig
Required: Yes
Type: PublicKeyConfig structure

A public key configuration.

Result Syntax

[
    'ETag' => '<string>',
    'PublicKey' => [
        'CreatedTime' => <DateTime>,
        'Id' => '<string>',
        'PublicKeyConfig' => [
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'EncodedKey' => '<string>',
            'Name' => '<string>',
        ],
    ],
]

Result Details

Members
ETag
Type: string

The identifier of the current version of the public key.

PublicKey
Type: PublicKey structure

The public key.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

NoSuchPublicKey:

The specified public key doesn't exist.

CannotChangeImmutablePublicKeyFields:

You can't change the value of a public key.

InvalidArgument:

An argument is invalid.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UpdateRealtimeLogConfig

$result = $client->updateRealtimeLogConfig([/* ... */]);
$promise = $client->updateRealtimeLogConfigAsync([/* ... */]);

Updates a real-time log configuration.

When you update a real-time log configuration, all the parameters are updated with the values provided in the request. You cannot update some parameters independent of others. To update a real-time log configuration:

  1. Call GetRealtimeLogConfig to get the current real-time log configuration.

  2. Locally modify the parameters in the real-time log configuration that you want to update.

  3. Call this API (UpdateRealtimeLogConfig) by providing the entire real-time log configuration, including the parameters that you modified and those that you didn't.

You cannot update a real-time log configuration's Name or ARN.

Parameter Syntax

$result = $client->updateRealtimeLogConfig([
    'ARN' => '<string>',
    'EndPoints' => [
        [
            'KinesisStreamConfig' => [
                'RoleARN' => '<string>', // REQUIRED
                'StreamARN' => '<string>', // REQUIRED
            ],
            'StreamType' => '<string>', // REQUIRED
        ],
        // ...
    ],
    'Fields' => ['<string>', ...],
    'Name' => '<string>',
    'SamplingRate' => <integer>,
]);

Parameter Details

Members
ARN
Type: string

The Amazon Resource Name (ARN) for this real-time log configuration.

EndPoints
Type: Array of EndPoint structures

Contains information about the Amazon Kinesis data stream where you are sending real-time log data.

Fields
Type: Array of strings

A list of fields to include in each real-time log record.

For more information about fields, see Real-time log configuration fields in the Amazon CloudFront Developer Guide.

Name
Type: string

The name for this real-time log configuration.

SamplingRate
Type: long (int|float)

The sampling rate for this real-time log configuration. The sampling rate determines the percentage of viewer requests that are represented in the real-time log data. You must provide an integer between 1 and 100, inclusive.

Result Syntax

[
    'RealtimeLogConfig' => [
        'ARN' => '<string>',
        'EndPoints' => [
            [
                'KinesisStreamConfig' => [
                    'RoleARN' => '<string>',
                    'StreamARN' => '<string>',
                ],
                'StreamType' => '<string>',
            ],
            // ...
        ],
        'Fields' => ['<string>', ...],
        'Name' => '<string>',
        'SamplingRate' => <integer>,
    ],
]

Result Details

Members
RealtimeLogConfig
Type: RealtimeLogConfig structure

A real-time log configuration.

Errors

AccessDenied:

Access denied.

InvalidArgument:

An argument is invalid.

NoSuchRealtimeLogConfig:

The real-time log configuration does not exist.

UpdateResponseHeadersPolicy

$result = $client->updateResponseHeadersPolicy([/* ... */]);
$promise = $client->updateResponseHeadersPolicyAsync([/* ... */]);

Updates a response headers policy.

When you update a response headers policy, the entire policy is replaced. You cannot update some policy fields independent of others. To update a response headers policy configuration:

  1. Use GetResponseHeadersPolicyConfig to get the current policy's configuration.

  2. Modify the fields in the response headers policy configuration that you want to update.

  3. Call UpdateResponseHeadersPolicy, providing the entire response headers policy configuration, including the fields that you modified and those that you didn't.

Parameter Syntax

$result = $client->updateResponseHeadersPolicy([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
    'ResponseHeadersPolicyConfig' => [ // REQUIRED
        'Comment' => '<string>',
        'CorsConfig' => [
            'AccessControlAllowCredentials' => true || false, // REQUIRED
            'AccessControlAllowHeaders' => [ // REQUIRED
                'Items' => ['<string>', ...], // REQUIRED
                'Quantity' => <integer>, // REQUIRED
            ],
            'AccessControlAllowMethods' => [ // REQUIRED
                'Items' => ['<string>', ...], // REQUIRED
                'Quantity' => <integer>, // REQUIRED
            ],
            'AccessControlAllowOrigins' => [ // REQUIRED
                'Items' => ['<string>', ...], // REQUIRED
                'Quantity' => <integer>, // REQUIRED
            ],
            'AccessControlExposeHeaders' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>, // REQUIRED
            ],
            'AccessControlMaxAgeSec' => <integer>,
            'OriginOverride' => true || false, // REQUIRED
        ],
        'CustomHeadersConfig' => [
            'Items' => [
                [
                    'Header' => '<string>', // REQUIRED
                    'Override' => true || false, // REQUIRED
                    'Value' => '<string>', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'Name' => '<string>', // REQUIRED
        'RemoveHeadersConfig' => [
            'Items' => [
                [
                    'Header' => '<string>', // REQUIRED
                ],
                // ...
            ],
            'Quantity' => <integer>, // REQUIRED
        ],
        'SecurityHeadersConfig' => [
            'ContentSecurityPolicy' => [
                'ContentSecurityPolicy' => '<string>', // REQUIRED
                'Override' => true || false, // REQUIRED
            ],
            'ContentTypeOptions' => [
                'Override' => true || false, // REQUIRED
            ],
            'FrameOptions' => [
                'FrameOption' => 'DENY|SAMEORIGIN', // REQUIRED
                'Override' => true || false, // REQUIRED
            ],
            'ReferrerPolicy' => [
                'Override' => true || false, // REQUIRED
                'ReferrerPolicy' => 'no-referrer|no-referrer-when-downgrade|origin|origin-when-cross-origin|same-origin|strict-origin|strict-origin-when-cross-origin|unsafe-url', // REQUIRED
            ],
            'StrictTransportSecurity' => [
                'AccessControlMaxAgeSec' => <integer>, // REQUIRED
                'IncludeSubdomains' => true || false,
                'Override' => true || false, // REQUIRED
                'Preload' => true || false,
            ],
            'XSSProtection' => [
                'ModeBlock' => true || false,
                'Override' => true || false, // REQUIRED
                'Protection' => true || false, // REQUIRED
                'ReportUri' => '<string>',
            ],
        ],
        'ServerTimingHeadersConfig' => [
            'Enabled' => true || false, // REQUIRED
            'SamplingRate' => <float>,
        ],
    ],
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The identifier for the response headers policy that you are updating.

IfMatch
Type: string

The version of the response headers policy that you are updating.

The version is returned in the cache policy's ETag field in the response to GetResponseHeadersPolicyConfig.

ResponseHeadersPolicyConfig
Required: Yes
Type: ResponseHeadersPolicyConfig structure

A response headers policy configuration.

Result Syntax

[
    'ETag' => '<string>',
    'ResponseHeadersPolicy' => [
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'ResponseHeadersPolicyConfig' => [
            'Comment' => '<string>',
            'CorsConfig' => [
                'AccessControlAllowCredentials' => true || false,
                'AccessControlAllowHeaders' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlAllowMethods' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlAllowOrigins' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlExposeHeaders' => [
                    'Items' => ['<string>', ...],
                    'Quantity' => <integer>,
                ],
                'AccessControlMaxAgeSec' => <integer>,
                'OriginOverride' => true || false,
            ],
            'CustomHeadersConfig' => [
                'Items' => [
                    [
                        'Header' => '<string>',
                        'Override' => true || false,
                        'Value' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'Name' => '<string>',
            'RemoveHeadersConfig' => [
                'Items' => [
                    [
                        'Header' => '<string>',
                    ],
                    // ...
                ],
                'Quantity' => <integer>,
            ],
            'SecurityHeadersConfig' => [
                'ContentSecurityPolicy' => [
                    'ContentSecurityPolicy' => '<string>',
                    'Override' => true || false,
                ],
                'ContentTypeOptions' => [
                    'Override' => true || false,
                ],
                'FrameOptions' => [
                    'FrameOption' => 'DENY|SAMEORIGIN',
                    'Override' => true || false,
                ],
                'ReferrerPolicy' => [
                    'Override' => true || false,
                    'ReferrerPolicy' => 'no-referrer|no-referrer-when-downgrade|origin|origin-when-cross-origin|same-origin|strict-origin|strict-origin-when-cross-origin|unsafe-url',
                ],
                'StrictTransportSecurity' => [
                    'AccessControlMaxAgeSec' => <integer>,
                    'IncludeSubdomains' => true || false,
                    'Override' => true || false,
                    'Preload' => true || false,
                ],
                'XSSProtection' => [
                    'ModeBlock' => true || false,
                    'Override' => true || false,
                    'Protection' => true || false,
                    'ReportUri' => '<string>',
                ],
            ],
            'ServerTimingHeadersConfig' => [
                'Enabled' => true || false,
                'SamplingRate' => <float>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the response headers policy.

ResponseHeadersPolicy
Type: ResponseHeadersPolicy structure

A response headers policy.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

AccessDenied:

Access denied.

TooManyCustomHeadersInResponseHeadersPolicy:

The number of custom headers in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

ResponseHeadersPolicyAlreadyExists:

A response headers policy with this name already exists. You must provide a unique name. To modify an existing response headers policy, use UpdateResponseHeadersPolicy.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

TooLongCSPInResponseHeadersPolicy:

The length of the Content-Security-Policy header value in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

NoSuchResponseHeadersPolicy:

The response headers policy does not exist.

InvalidArgument:

An argument is invalid.

TooManyRemoveHeadersInResponseHeadersPolicy:

The number of headers in RemoveHeadersConfig in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

UpdateStreamingDistribution

$result = $client->updateStreamingDistribution([/* ... */]);
$promise = $client->updateStreamingDistributionAsync([/* ... */]);

Update a streaming distribution.

Parameter Syntax

$result = $client->updateStreamingDistribution([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>',
    'StreamingDistributionConfig' => [ // REQUIRED
        'Aliases' => [
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
        'CallerReference' => '<string>', // REQUIRED
        'Comment' => '<string>', // REQUIRED
        'Enabled' => true || false, // REQUIRED
        'Logging' => [
            'Bucket' => '<string>', // REQUIRED
            'Enabled' => true || false, // REQUIRED
            'Prefix' => '<string>', // REQUIRED
        ],
        'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
        'S3Origin' => [ // REQUIRED
            'DomainName' => '<string>', // REQUIRED
            'OriginAccessIdentity' => '<string>', // REQUIRED
        ],
        'TrustedSigners' => [ // REQUIRED
            'Enabled' => true || false, // REQUIRED
            'Items' => ['<string>', ...],
            'Quantity' => <integer>, // REQUIRED
        ],
    ],
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The streaming distribution's id.

IfMatch
Type: string

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

StreamingDistributionConfig
Required: Yes
Type: StreamingDistributionConfig structure

The streaming distribution's configuration information.

Result Syntax

[
    'ETag' => '<string>',
    'StreamingDistribution' => [
        'ARN' => '<string>',
        'ActiveTrustedSigners' => [
            'Enabled' => true || false,
            'Items' => [
                [
                    'AwsAccountNumber' => '<string>',
                    'KeyPairIds' => [
                        'Items' => ['<string>', ...],
                        'Quantity' => <integer>,
                    ],
                ],
                // ...
            ],
            'Quantity' => <integer>,
        ],
        'DomainName' => '<string>',
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
        'StreamingDistributionConfig' => [
            'Aliases' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
            'CallerReference' => '<string>',
            'Comment' => '<string>',
            'Enabled' => true || false,
            'Logging' => [
                'Bucket' => '<string>',
                'Enabled' => true || false,
                'Prefix' => '<string>',
            ],
            'PriceClass' => 'PriceClass_100|PriceClass_200|PriceClass_All',
            'S3Origin' => [
                'DomainName' => '<string>',
                'OriginAccessIdentity' => '<string>',
            ],
            'TrustedSigners' => [
                'Enabled' => true || false,
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The current version of the configuration. For example: E2QWRUHAPOMQZL.

StreamingDistribution
Type: StreamingDistribution structure

The streaming distribution's information.

Errors

AccessDenied:

Access denied.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

InvalidOriginAccessIdentity:

The origin access identity is not valid or doesn't exist.

InvalidArgument:

An argument is invalid.

IllegalUpdate:

The update contains modifications that are not allowed.

TooManyTrustedSigners:

Your request contains more trusted signers than are allowed per distribution.

InvalidOriginAccessControl:

The origin access control is not valid.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

MissingBody:

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

TooManyStreamingDistributionCNAMEs:

Your request contains more CNAMEs than are allowed per distribution.

TrustedSignerDoesNotExist:

One or more of your trusted signers don't exist.

CNAMEAlreadyExists:

The CNAME specified is already defined for CloudFront.

NoSuchStreamingDistribution:

The specified streaming distribution does not exist.

UpdateVpcOrigin

$result = $client->updateVpcOrigin([/* ... */]);
$promise = $client->updateVpcOriginAsync([/* ... */]);

Update an Amazon CloudFront VPC origin in your account.

Parameter Syntax

$result = $client->updateVpcOrigin([
    'Id' => '<string>', // REQUIRED
    'IfMatch' => '<string>', // REQUIRED
    'VpcOriginEndpointConfig' => [ // REQUIRED
        'Arn' => '<string>', // REQUIRED
        'HTTPPort' => <integer>, // REQUIRED
        'HTTPSPort' => <integer>, // REQUIRED
        'Name' => '<string>', // REQUIRED
        'OriginProtocolPolicy' => 'http-only|match-viewer|https-only', // REQUIRED
        'OriginSslProtocols' => [
            'Items' => ['<string>', ...], // REQUIRED
            'Quantity' => <integer>, // REQUIRED
        ],
    ],
]);

Parameter Details

Members
Id
Required: Yes
Type: string

The VPC origin ID.

IfMatch
Required: Yes
Type: string

The VPC origin to update, if a match occurs.

VpcOriginEndpointConfig
Required: Yes
Type: VpcOriginEndpointConfig structure

The VPC origin endpoint configuration.

Result Syntax

[
    'ETag' => '<string>',
    'VpcOrigin' => [
        'Arn' => '<string>',
        'CreatedTime' => <DateTime>,
        'Id' => '<string>',
        'LastModifiedTime' => <DateTime>,
        'Status' => '<string>',
        'VpcOriginEndpointConfig' => [
            'Arn' => '<string>',
            'HTTPPort' => <integer>,
            'HTTPSPort' => <integer>,
            'Name' => '<string>',
            'OriginProtocolPolicy' => 'http-only|match-viewer|https-only',
            'OriginSslProtocols' => [
                'Items' => ['<string>', ...],
                'Quantity' => <integer>,
            ],
        ],
    ],
]

Result Details

Members
ETag
Type: string

The VPC origin ETag.

VpcOrigin
Type: VpcOrigin structure

The VPC origin.

Errors

PreconditionFailed:

The precondition in one or more of the request fields evaluated to false.

EntityNotFound:

The entity was not found.

AccessDenied:

Access denied.

UnsupportedOperation:

This operation is not supported in this region.

InconsistentQuantities:

The value of Quantity and the size of Items don't match.

EntityAlreadyExists:

The entity already exists. You must provide a unique entity.

CannotUpdateEntityWhileInUse:

The entity cannot be updated while it is in use.

InvalidArgument:

An argument is invalid.

EntityLimitExceeded:

The entity limit has been exceeded.

IllegalUpdate:

The update contains modifications that are not allowed.

InvalidIfMatchVersion:

The If-Match version is missing or not valid.

Examples

Example 1: To update a VPC origin

The following command updates a VPC origin:

$result = $client->updateVpcOrigin([
    'Id' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
    'IfMatch' => 'ETVPDKIKX0DER',
    'VpcOriginEndpointConfig' => [
        'Arn' => 'arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/my-alb-us-west-2/e6aa5c7d26415c6d',
        'HTTPPort' => 80,
        'HTTPSPort' => 443,
        'Name' => 'my-vpcorigin-name',
        'OriginProtocolPolicy' => 'match-viewer',
        'OriginSslProtocols' => [
            'Items' => [
                'TLSv1.1',
                'TLSv1.2',
            ],
            'Quantity' => 2,
        ],
    ],
]);

Result syntax:

[
    'ETag' => 'E3UN6WX5RRO2AG',
    'VpcOrigin' => [
        'Arn' => 'arn:aws:cloudfront::123456789012:vpcorigin/vo_BQwjxxQxjCaBcQLzJUFkDM',
        'CreatedTime' => ,
        'Id' => 'vo_BQwjxxQxjCaBcQLzJUFkDM',
        'LastModifiedTime' => ,
        'Status' => 'Deploying',
        'VpcOriginEndpointConfig' => [
            'Arn' => 'arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/my-alb-us-west-2/e6aa5c7d26415c6d',
            'HTTPPort' => 80,
            'HTTPSPort' => 443,
            'Name' => 'my-vpcorigin-name',
            'OriginProtocolPolicy' => 'match-viewer',
            'OriginSslProtocols' => [
                'Items' => [
                    'TLSv1.1',
                    'TLSv1.2',
                ],
                'Quantity' => 2,
            ],
        ],
    ],
]

Shapes

AccessDenied

Description

Access denied.

Members
Message
Type: string

ActiveTrustedKeyGroups

Description

A list of key groups, and the public keys in each key group, that CloudFront can use to verify the signatures of signed URLs and signed cookies.

Members
Enabled
Required: Yes
Type: boolean

This field is true if any of the key groups have public keys that CloudFront can use to verify the signatures of signed URLs and signed cookies. If not, this field is false.

Items
Type: Array of KGKeyPairIds structures

A list of key groups, including the identifiers of the public keys in each key group that CloudFront can use to verify the signatures of signed URLs and signed cookies.

Quantity
Required: Yes
Type: int

The number of key groups in the list.

ActiveTrustedSigners

Description

A list of Amazon Web Services accounts and the active CloudFront key pairs in each account that CloudFront can use to verify the signatures of signed URLs and signed cookies.

Members
Enabled
Required: Yes
Type: boolean

This field is true if any of the Amazon Web Services accounts in the list are configured as trusted signers. If not, this field is false.

Items
Type: Array of Signer structures

A list of Amazon Web Services accounts and the identifiers of active CloudFront key pairs in each account that CloudFront can use to verify the signatures of signed URLs and signed cookies.

Quantity
Required: Yes
Type: int

The number of Amazon Web Services accounts in the list.

AliasICPRecordal

Description

Amazon Web Services services in China customers must file for an Internet Content Provider (ICP) recordal if they want to serve content publicly on an alternate domain name, also known as a CNAME, that they've added to CloudFront. AliasICPRecordal provides the ICP recordal status for CNAMEs associated with distributions. The status is returned in the CloudFront response; you can't configure it yourself.

For more information about ICP recordals, see Signup, Accounts, and Credentials in Getting Started with Amazon Web Services services in China.

Members
CNAME
Type: string

A domain name associated with a distribution.

ICPRecordalStatus
Type: string

The Internet Content Provider (ICP) recordal status for a CNAME. The ICPRecordalStatus is set to APPROVED for all CNAMEs (aliases) in regions outside of China.

The status values returned are the following:

  • APPROVED indicates that the associated CNAME has a valid ICP recordal number. Multiple CNAMEs can be associated with a distribution, and CNAMEs can correspond to different ICP recordals. To be marked as APPROVED, that is, valid to use with China region, a CNAME must have one ICP recordal number associated with it.

  • SUSPENDED indicates that the associated CNAME does not have a valid ICP recordal number.

  • PENDING indicates that CloudFront can't determine the ICP recordal status of the CNAME associated with the distribution because there was an error in trying to determine the status. You can try again to see if the error is resolved in which case CloudFront returns an APPROVED or SUSPENDED status.

Aliases

Description

A complex type that contains information about CNAMEs (alternate domain names), if any, for this distribution.

Members
Items
Type: Array of strings

A complex type that contains the CNAME aliases, if any, that you want to associate with this distribution.

Quantity
Required: Yes
Type: int

The number of CNAME aliases, if any, that you want to associate with this distribution.

AllowedMethods

Description

A complex type that controls which HTTP methods CloudFront processes and forwards to your Amazon S3 bucket or your custom origin. There are three choices:

  • CloudFront forwards only GET and HEAD requests.

  • CloudFront forwards only GET, HEAD, and OPTIONS requests.

  • CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE requests.

If you pick the third choice, you may need to restrict access to your Amazon S3 bucket or to your custom origin so users can't perform operations that you don't want them to. For example, you might not want users to have permissions to delete objects from your origin.

Members
CachedMethods
Type: CachedMethods structure

A complex type that controls whether CloudFront caches the response to requests using the specified HTTP methods. There are two choices:

  • CloudFront caches responses to GET and HEAD requests.

  • CloudFront caches responses to GET, HEAD, and OPTIONS requests.

If you pick the second choice for your Amazon S3 Origin, you may need to forward Access-Control-Request-Method, Access-Control-Request-Headers, and Origin headers for the responses to be cached correctly.

Items
Required: Yes
Type: Array of strings

A complex type that contains the HTTP methods that you want CloudFront to process and forward to your origin.

Quantity
Required: Yes
Type: int

The number of HTTP methods that you want CloudFront to forward to your origin. Valid values are 2 (for GET and HEAD requests), 3 (for GET, HEAD, and OPTIONS requests) and 7 (for GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE requests).

AnycastIpList

Description

An Anycast static IP list.

Members
AnycastIps
Required: Yes
Type: Array of strings

The static IP addresses that are allocated to the Anycast static IP list.

Arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the Anycast static IP list.

Id
Required: Yes
Type: string

The ID of the Anycast static IP list.

IpCount
Required: Yes
Type: int

The number of IP addresses in the Anycast static IP list.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The last time the Anycast static IP list was modified.

Name
Required: Yes
Type: string

The name of the Anycast static IP list.

Status
Required: Yes
Type: string

The status of the Anycast static IP list. Valid values: Deployed, Deploying, or Failed.

AnycastIpListCollection

Description

The Anycast static IP list collection.

Members
IsTruncated
Required: Yes
Type: boolean

If there are more items in the list collection than are in this response, this value is true.

Items
Type: Array of AnycastIpListSummary structures

Items in the Anycast static IP list collection. Each item is of the AnycastIpListSummary structure type.

Marker
Required: Yes
Type: string

Use this field when paginating results to indicate where to begin in your list. The response includes items in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Required: Yes
Type: int

The maximum number of Anycast static IP list collections that you want returned in the response.

NextMarker
Type: string

Indicates the next page of the Anycast static IP list collection. To get the next page of the list, use this value in the Marker field of your request.

Quantity
Required: Yes
Type: int

The quantity of Anycast static IP lists in the collection.

AnycastIpListSummary

Description

An abbreviated version of the AnycastIpList structure. Omits the allocated static IP addresses (AnycastIpList$AnycastIps).

Members
Arn
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the Anycast static IP list.

Id
Required: Yes
Type: string

The ID of the Anycast static IP list.

IpCount
Required: Yes
Type: int

The number of IP addresses in the Anycast static IP list.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The last time the Anycast static IP list was modified.

Name
Required: Yes
Type: string

The name of the Anycast static IP list.

Status
Required: Yes
Type: string

The deployment status of the Anycast static IP list. Valid values: Deployed, Deploying, or Failed.

BatchTooLarge

Description

Invalidation batch specified is too large.

Members
Message
Type: string

CNAMEAlreadyExists

Description

The CNAME specified is already defined for CloudFront.

Members
Message
Type: string

CacheBehavior

Description

A complex type that describes how CloudFront processes requests.

You must create at least as many cache behaviors (including the default cache behavior) as you have origins if you want CloudFront to serve objects from all of the origins. Each cache behavior specifies the one origin from which you want CloudFront to get objects. If you have two origins and only the default cache behavior, the default cache behavior will cause CloudFront to get objects from one of the origins, but the other origin is never used.

For the current quota (formerly known as limit) on the number of cache behaviors that you can add to a distribution, see Quotas in the Amazon CloudFront Developer Guide.

If you don't want to specify any cache behaviors, include only an empty CacheBehaviors element. Don't specify an empty individual CacheBehavior element, because this is invalid. For more information, see CacheBehaviors.

To delete all cache behaviors in an existing distribution, update the distribution configuration and include only an empty CacheBehaviors element.

To add, change, or remove one or more cache behaviors, update the distribution configuration and specify all of the cache behaviors that you want to include in the updated distribution.

For more information about cache behaviors, see Cache Behavior Settings in the Amazon CloudFront Developer Guide.

Members
AllowedMethods
Type: AllowedMethods structure

A complex type that controls which HTTP methods CloudFront processes and forwards to your Amazon S3 bucket or your custom origin. There are three choices:

  • CloudFront forwards only GET and HEAD requests.

  • CloudFront forwards only GET, HEAD, and OPTIONS requests.

  • CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE requests.

If you pick the third choice, you may need to restrict access to your Amazon S3 bucket or to your custom origin so users can't perform operations that you don't want them to. For example, you might not want users to have permissions to delete objects from your origin.

CachePolicyId
Type: string

The unique identifier of the cache policy that is attached to this cache behavior. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

A CacheBehavior must include either a CachePolicyId or ForwardedValues. We recommend that you use a CachePolicyId.

Compress
Type: boolean

Whether you want CloudFront to automatically compress certain files for this cache behavior. If so, specify true; if not, specify false. For more information, see Serving Compressed Files in the Amazon CloudFront Developer Guide.

DefaultTTL
Type: long (int|float)

This field is deprecated. We recommend that you use the DefaultTTL field in a cache policy instead of this field. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

The default amount of time that you want objects to stay in CloudFront caches before CloudFront forwards another request to your origin to determine whether the object has been updated. The value that you specify applies only when your origin does not add HTTP headers such as Cache-Control max-age, Cache-Control s-maxage, and Expires to objects. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

FieldLevelEncryptionId
Type: string

The value of ID for the field-level encryption configuration that you want CloudFront to use for encrypting specific fields of data for this cache behavior.

ForwardedValues
Type: ForwardedValues structure

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field. For more information, see Working with policies in the Amazon CloudFront Developer Guide.

If you want to include values in the cache key, use a cache policy. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

If you want to send values to the origin but not include them in the cache key, use an origin request policy. For more information, see Creating origin request policies or Using the managed origin request policies in the Amazon CloudFront Developer Guide.

A CacheBehavior must include either a CachePolicyId or ForwardedValues. We recommend that you use a CachePolicyId.

A complex type that specifies how CloudFront handles query strings, cookies, and HTTP headers.

FunctionAssociations
Type: FunctionAssociations structure

A list of CloudFront functions that are associated with this cache behavior. CloudFront functions must be published to the LIVE stage to associate them with a cache behavior.

GrpcConfig
Type: GrpcConfig structure

The gRPC configuration for your cache behavior.

LambdaFunctionAssociations
Type: LambdaFunctionAssociations structure

A complex type that contains zero or more Lambda@Edge function associations for a cache behavior.

MaxTTL
Type: long (int|float)

This field is deprecated. We recommend that you use the MaxTTL field in a cache policy instead of this field. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

The maximum amount of time that you want objects to stay in CloudFront caches before CloudFront forwards another request to your origin to determine whether the object has been updated. The value that you specify applies only when your origin adds HTTP headers such as Cache-Control max-age, Cache-Control s-maxage, and Expires to objects. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

MinTTL
Type: long (int|float)

This field is deprecated. We recommend that you use the MinTTL field in a cache policy instead of this field. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

The minimum amount of time that you want objects to stay in CloudFront caches before CloudFront forwards another request to your origin to determine whether the object has been updated. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

You must specify 0 for MinTTL if you configure CloudFront to forward all headers to your origin (under Headers, if you specify 1 for Quantity and * for Name).

OriginRequestPolicyId
Type: string

The unique identifier of the origin request policy that is attached to this cache behavior. For more information, see Creating origin request policies or Using the managed origin request policies in the Amazon CloudFront Developer Guide.

PathPattern
Required: Yes
Type: string

The pattern (for example, images/*.jpg) that specifies which requests to apply the behavior to. When CloudFront receives a viewer request, the requested path is compared with path patterns in the order in which cache behaviors are listed in the distribution.

You can optionally include a slash (/) at the beginning of the path pattern. For example, /images/*.jpg. CloudFront behavior is the same with or without the leading /.

The path pattern for the default cache behavior is * and cannot be changed. If the request for an object does not match the path pattern for any cache behaviors, CloudFront applies the behavior in the default cache behavior.

For more information, see Path Pattern in the Amazon CloudFront Developer Guide.

RealtimeLogConfigArn
Type: string

The Amazon Resource Name (ARN) of the real-time log configuration that is attached to this cache behavior. For more information, see Real-time logs in the Amazon CloudFront Developer Guide.

ResponseHeadersPolicyId
Type: string

The identifier for a response headers policy.

SmoothStreaming
Type: boolean

Indicates whether you want to distribute media files in the Microsoft Smooth Streaming format using the origin that is associated with this cache behavior. If so, specify true; if not, specify false. If you specify true for SmoothStreaming, you can still distribute other content using this cache behavior if the content matches the value of PathPattern.

TargetOriginId
Required: Yes
Type: string

The value of ID for the origin that you want CloudFront to route requests to when they match this cache behavior.

TrustedKeyGroups
Type: TrustedKeyGroups structure

A list of key groups that CloudFront can use to validate signed URLs or signed cookies.

When a cache behavior contains trusted key groups, CloudFront requires signed URLs or signed cookies for all requests that match the cache behavior. The URLs or cookies must be signed with a private key whose corresponding public key is in the key group. The signed URL or cookie contains information about which public key CloudFront should use to verify the signature. For more information, see Serving private content in the Amazon CloudFront Developer Guide.

TrustedSigners
Type: TrustedSigners structure

We recommend using TrustedKeyGroups instead of TrustedSigners.

A list of Amazon Web Services account IDs whose public keys CloudFront can use to validate signed URLs or signed cookies.

When a cache behavior contains trusted signers, CloudFront requires signed URLs or signed cookies for all requests that match the cache behavior. The URLs or cookies must be signed with the private key of a CloudFront key pair in the trusted signer's Amazon Web Services account. The signed URL or cookie contains information about which public key CloudFront should use to verify the signature. For more information, see Serving private content in the Amazon CloudFront Developer Guide.

ViewerProtocolPolicy
Required: Yes
Type: string

The protocol that viewers can use to access the files in the origin specified by TargetOriginId when a request matches the path pattern in PathPattern. You can specify the following options:

  • allow-all: Viewers can use HTTP or HTTPS.

  • redirect-to-https: If a viewer submits an HTTP request, CloudFront returns an HTTP status code of 301 (Moved Permanently) to the viewer along with the HTTPS URL. The viewer then resubmits the request using the new URL.

  • https-only: If a viewer sends an HTTP request, CloudFront returns an HTTP status code of 403 (Forbidden).

For more information about requiring the HTTPS protocol, see Requiring HTTPS Between Viewers and CloudFront in the Amazon CloudFront Developer Guide.

The only way to guarantee that viewers retrieve an object that was fetched from the origin using HTTPS is never to use any other protocol to fetch the object. If you have recently changed from HTTP to HTTPS, we recommend that you clear your objects' cache because cached objects are protocol agnostic. That means that an edge location will return an object from the cache regardless of whether the current request protocol matches the protocol used previously. For more information, see Managing Cache Expiration in the Amazon CloudFront Developer Guide.

CacheBehaviors

Description

A complex type that contains zero or more CacheBehavior elements.

Members
Items
Type: Array of CacheBehavior structures

Optional: A complex type that contains cache behaviors for this distribution. If Quantity is 0, you can omit Items.

Quantity
Required: Yes
Type: int

The number of cache behaviors for this distribution.

CachePolicy

Description

A cache policy.

When it's attached to a cache behavior, the cache policy determines the following:

  • The values that CloudFront includes in the cache key. These values can include HTTP headers, cookies, and URL query strings. CloudFront uses the cache key to find an object in its cache that it can return to the viewer.

  • The default, minimum, and maximum time to live (TTL) values that you want objects to stay in the CloudFront cache.

The headers, cookies, and query strings that are included in the cache key are also included in requests that CloudFront sends to the origin. CloudFront sends a request when it can't find a valid object in its cache that matches the request's cache key. If you want to send values to the origin but not include them in the cache key, use OriginRequestPolicy.

Members
CachePolicyConfig
Required: Yes
Type: CachePolicyConfig structure

The cache policy configuration.

Id
Required: Yes
Type: string

The unique identifier for the cache policy.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the cache policy was last modified.

CachePolicyAlreadyExists

Description

A cache policy with this name already exists. You must provide a unique name. To modify an existing cache policy, use UpdateCachePolicy.

Members
Message
Type: string

CachePolicyConfig

Description

A cache policy configuration.

This configuration determines the following:

  • The values that CloudFront includes in the cache key. These values can include HTTP headers, cookies, and URL query strings. CloudFront uses the cache key to find an object in its cache that it can return to the viewer.

  • The default, minimum, and maximum time to live (TTL) values that you want objects to stay in the CloudFront cache.

The headers, cookies, and query strings that are included in the cache key are also included in requests that CloudFront sends to the origin. CloudFront sends a request when it can't find a valid object in its cache that matches the request's cache key. If you want to send values to the origin but not include them in the cache key, use OriginRequestPolicy.

Members
Comment
Type: string

A comment to describe the cache policy. The comment cannot be longer than 128 characters.

DefaultTTL
Type: long (int|float)

The default amount of time, in seconds, that you want objects to stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. CloudFront uses this value as the object's time to live (TTL) only when the origin does not send Cache-Control or Expires headers with the object. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

The default value for this field is 86400 seconds (one day). If the value of MinTTL is more than 86400 seconds, then the default value for this field is the same as the value of MinTTL.

MaxTTL
Type: long (int|float)

The maximum amount of time, in seconds, that objects stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. CloudFront uses this value only when the origin sends Cache-Control or Expires headers with the object. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

The default value for this field is 31536000 seconds (one year). If the value of MinTTL or DefaultTTL is more than 31536000 seconds, then the default value for this field is the same as the value of DefaultTTL.

MinTTL
Required: Yes
Type: long (int|float)

The minimum amount of time, in seconds, that you want objects to stay in the CloudFront cache before CloudFront sends another request to the origin to see if the object has been updated. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

Name
Required: Yes
Type: string

A unique name to identify the cache policy.

ParametersInCacheKeyAndForwardedToOrigin

The HTTP headers, cookies, and URL query strings to include in the cache key. The values included in the cache key are also included in requests that CloudFront sends to the origin.

CachePolicyCookiesConfig

Description

An object that determines whether any cookies in viewer requests (and if so, which cookies) are included in the cache key and in requests that CloudFront sends to the origin.

Members
CookieBehavior
Required: Yes
Type: string

Determines whether any cookies in viewer requests are included in the cache key and in requests that CloudFront sends to the origin. Valid values are:

  • none – No cookies in viewer requests are included in the cache key or in requests that CloudFront sends to the origin. Even when this field is set to none, any cookies that are listed in an OriginRequestPolicy are included in origin requests.

  • whitelist – Only the cookies in viewer requests that are listed in the CookieNames type are included in the cache key and in requests that CloudFront sends to the origin.

  • allExcept – All cookies in viewer requests are included in the cache key and in requests that CloudFront sends to the origin, except for those that are listed in the CookieNames type, which are not included.

  • all – All cookies in viewer requests are included in the cache key and in requests that CloudFront sends to the origin.

Cookies
Type: CookieNames structure

Contains a list of cookie names.

CachePolicyHeadersConfig

Description

An object that determines whether any HTTP headers (and if so, which headers) are included in the cache key and in requests that CloudFront sends to the origin.

Members
HeaderBehavior
Required: Yes
Type: string

Determines whether any HTTP headers are included in the cache key and in requests that CloudFront sends to the origin. Valid values are:

  • none – No HTTP headers are included in the cache key or in requests that CloudFront sends to the origin. Even when this field is set to none, any headers that are listed in an OriginRequestPolicy are included in origin requests.

  • whitelist – Only the HTTP headers that are listed in the Headers type are included in the cache key and in requests that CloudFront sends to the origin.

Headers
Type: Headers structure

Contains a list of HTTP header names.

CachePolicyInUse

Description

Cannot delete the cache policy because it is attached to one or more cache behaviors.

Members
Message
Type: string

CachePolicyList

Description

A list of cache policies.

Members
Items
Type: Array of CachePolicySummary structures

Contains the cache policies in the list.

MaxItems
Required: Yes
Type: int

The maximum number of cache policies requested.

NextMarker
Type: string

If there are more items in the list than are in this response, this element is present. It contains the value that you should use in the Marker field of a subsequent request to continue listing cache policies where you left off.

Quantity
Required: Yes
Type: int

The total number of cache policies returned in the response.

CachePolicyQueryStringsConfig

Description

An object that determines whether any URL query strings in viewer requests (and if so, which query strings) are included in the cache key and in requests that CloudFront sends to the origin.

Members
QueryStringBehavior
Required: Yes
Type: string

Determines whether any URL query strings in viewer requests are included in the cache key and in requests that CloudFront sends to the origin. Valid values are:

  • none – No query strings in viewer requests are included in the cache key or in requests that CloudFront sends to the origin. Even when this field is set to none, any query strings that are listed in an OriginRequestPolicy are included in origin requests.

  • whitelist – Only the query strings in viewer requests that are listed in the QueryStringNames type are included in the cache key and in requests that CloudFront sends to the origin.

  • allExcept – All query strings in viewer requests are included in the cache key and in requests that CloudFront sends to the origin, except those that are listed in the QueryStringNames type, which are not included.

  • all – All query strings in viewer requests are included in the cache key and in requests that CloudFront sends to the origin.

QueryStrings
Type: QueryStringNames structure

Contains the specific query strings in viewer requests that either are or are not included in the cache key and in requests that CloudFront sends to the origin. The behavior depends on whether the QueryStringBehavior field in the CachePolicyQueryStringsConfig type is set to whitelist (the listed query strings are included) or allExcept (the listed query strings are not included, but all other query strings are).

CachePolicySummary

Description

Contains a cache policy.

Members
CachePolicy
Required: Yes
Type: CachePolicy structure

The cache policy.

Type
Required: Yes
Type: string

The type of cache policy, either managed (created by Amazon Web Services) or custom (created in this Amazon Web Services account).

CachedMethods

Description

A complex type that controls whether CloudFront caches the response to requests using the specified HTTP methods. There are two choices:

  • CloudFront caches responses to GET and HEAD requests.

  • CloudFront caches responses to GET, HEAD, and OPTIONS requests.

If you pick the second choice for your Amazon S3 Origin, you may need to forward Access-Control-Request-Method, Access-Control-Request-Headers, and Origin headers for the responses to be cached correctly.

Members
Items
Required: Yes
Type: Array of strings

A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.

Quantity
Required: Yes
Type: int

The number of HTTP methods for which you want CloudFront to cache responses. Valid values are 2 (for caching responses to GET and HEAD requests) and 3 (for caching responses to GET, HEAD, and OPTIONS requests).

CannotChangeImmutablePublicKeyFields

Description

You can't change the value of a public key.

Members
Message
Type: string

CannotDeleteEntityWhileInUse

Description

The entity cannot be deleted while it is in use.

Members
Message
Type: string

CannotUpdateEntityWhileInUse

Description

The entity cannot be updated while it is in use.

Members
Message
Type: string

CloudFrontOriginAccessIdentity

Description

CloudFront origin access identity.

Members
CloudFrontOriginAccessIdentityConfig

The current configuration information for the identity.

Id
Required: Yes
Type: string

The ID for the origin access identity, for example, E74FTE3AJFJ256A.

S3CanonicalUserId
Required: Yes
Type: string

The Amazon S3 canonical user ID for the origin access identity, used when giving the origin access identity read permission to an object in Amazon S3.

CloudFrontOriginAccessIdentityAlreadyExists

Description

If the CallerReference is a value you already sent in a previous request to create an identity but the content of the CloudFrontOriginAccessIdentityConfig is different from the original request, CloudFront returns a CloudFrontOriginAccessIdentityAlreadyExists error.

Members
Message
Type: string

CloudFrontOriginAccessIdentityConfig

Description

Origin access identity configuration. Send a GET request to the /CloudFront API version/CloudFront/identity ID/config resource.

Members
CallerReference
Required: Yes
Type: string

A unique value (for example, a date-time stamp) that ensures that the request can't be replayed.

If the value of CallerReference is new (regardless of the content of the CloudFrontOriginAccessIdentityConfig object), a new origin access identity is created.

If the CallerReference is a value already sent in a previous identity request, and the content of the CloudFrontOriginAccessIdentityConfig is identical to the original request (ignoring white space), the response includes the same information returned to the original request.

If the CallerReference is a value you already sent in a previous request to create an identity, but the content of the CloudFrontOriginAccessIdentityConfig is different from the original request, CloudFront returns a CloudFrontOriginAccessIdentityAlreadyExists error.

Comment
Required: Yes
Type: string

A comment to describe the origin access identity. The comment cannot be longer than 128 characters.

CloudFrontOriginAccessIdentityInUse

Description

The Origin Access Identity specified is already in use.

Members
Message
Type: string

CloudFrontOriginAccessIdentityList

Description

Lists the origin access identities for CloudFront.Send a GET request to the /CloudFront API version/origin-access-identity/cloudfront resource. The response includes a CloudFrontOriginAccessIdentityList element with zero or more CloudFrontOriginAccessIdentitySummary child elements. By default, your entire list of origin access identities is returned in one single page. If the list is long, you can paginate it using the MaxItems and Marker parameters.

Members
IsTruncated
Required: Yes
Type: boolean

A flag that indicates whether more origin access identities remain to be listed. If your results were truncated, you can make a follow-up pagination request using the Marker request parameter to retrieve more items in the list.

Items
Type: Array of CloudFrontOriginAccessIdentitySummary structures

A complex type that contains one CloudFrontOriginAccessIdentitySummary element for each origin access identity that was created by the current Amazon Web Services account.

Marker
Required: Yes
Type: string

Use this when paginating results to indicate where to begin in your list of origin access identities. The results include identities in the list that occur after the marker. To get the next page of results, set the Marker to the value of the NextMarker from the current page's response (which is also the ID of the last identity on that page).

MaxItems
Required: Yes
Type: int

The maximum number of origin access identities you want in the response body.

NextMarker
Type: string

If IsTruncated is true, this element is present and contains the value you can use for the Marker request parameter to continue listing your origin access identities where they left off.

Quantity
Required: Yes
Type: int

The number of CloudFront origin access identities that were created by the current Amazon Web Services account.

CloudFrontOriginAccessIdentitySummary

Description

Summary of the information about a CloudFront origin access identity.

Members
Comment
Required: Yes
Type: string

The comment for this origin access identity, as originally specified when created.

Id
Required: Yes
Type: string

The ID for the origin access identity. For example: E74FTE3AJFJ256A.

S3CanonicalUserId
Required: Yes
Type: string

The Amazon S3 canonical user ID for the origin access identity, which you use when giving the origin access identity read permission to an object in Amazon S3.

ConflictingAlias

Description

An alias (also called a CNAME) and the CloudFront distribution and Amazon Web Services account ID that it's associated with. The distribution and account IDs are partially hidden, which allows you to identify the distributions and accounts that you own, but helps to protect the information of ones that you don't own.

Members
AccountId
Type: string

The (partially hidden) ID of the Amazon Web Services account that owns the distribution that's associated with the alias.

Alias
Type: string

An alias (also called a CNAME).

DistributionId
Type: string

The (partially hidden) ID of the CloudFront distribution associated with the alias.

ConflictingAliasesList

Description

A list of aliases (also called CNAMEs) and the CloudFront distributions and Amazon Web Services accounts that they are associated with. In the list, the distribution and account IDs are partially hidden, which allows you to identify the distributions and accounts that you own, but helps to protect the information of ones that you don't own.

Members
Items
Type: Array of ConflictingAlias structures

Contains the conflicting aliases in the list.

MaxItems
Type: int

The maximum number of conflicting aliases requested.

NextMarker
Type: string

If there are more items in the list than are in this response, this element is present. It contains the value that you should use in the Marker field of a subsequent request to continue listing conflicting aliases where you left off.

Quantity
Type: int

The number of conflicting aliases returned in the response.

ContentTypeProfile

Description

A field-level encryption content type profile.

Members
ContentType
Required: Yes
Type: string

The content type for a field-level encryption content type-profile mapping.

Format
Required: Yes
Type: string

The format for a field-level encryption content type-profile mapping.

ProfileId
Type: string

The profile ID for a field-level encryption content type-profile mapping.

ContentTypeProfileConfig

Description

The configuration for a field-level encryption content type-profile mapping.

Members
ContentTypeProfiles
Type: ContentTypeProfiles structure

The configuration for a field-level encryption content type-profile.

ForwardWhenContentTypeIsUnknown
Required: Yes
Type: boolean

The setting in a field-level encryption content type-profile mapping that specifies what to do when an unknown content type is provided for the profile. If true, content is forwarded without being encrypted when the content type is unknown. If false (the default), an error is returned when the content type is unknown.

ContentTypeProfiles

Description

Field-level encryption content type-profile.

Members
Items
Type: Array of ContentTypeProfile structures

Items in a field-level encryption content type-profile mapping.

Quantity
Required: Yes
Type: int

The number of field-level encryption content type-profile mappings.

ContinuousDeploymentPolicy

Description

A continuous deployment policy.

Members
ContinuousDeploymentPolicyConfig
Required: Yes
Type: ContinuousDeploymentPolicyConfig structure

Contains the configuration for a continuous deployment policy.

Id
Required: Yes
Type: string

The identifier of the continuous deployment policy.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time the continuous deployment policy was last modified.

ContinuousDeploymentPolicyAlreadyExists

Description

A continuous deployment policy with this configuration already exists.

Members
Message
Type: string

ContinuousDeploymentPolicyConfig

Description

Contains the configuration for a continuous deployment policy.

Members
Enabled
Required: Yes
Type: boolean

A Boolean that indicates whether this continuous deployment policy is enabled (in effect). When this value is true, this policy is enabled and in effect. When this value is false, this policy is not enabled and has no effect.

StagingDistributionDnsNames
Required: Yes
Type: StagingDistributionDnsNames structure

The CloudFront domain name of the staging distribution. For example: d111111abcdef8.cloudfront.net.

TrafficConfig
Type: TrafficConfig structure

Contains the parameters for routing production traffic from your primary to staging distributions.

ContinuousDeploymentPolicyInUse

Description

You cannot delete a continuous deployment policy that is associated with a primary distribution.

Members
Message
Type: string

ContinuousDeploymentPolicyList

Description

Contains a list of continuous deployment policies.

Members
Items
Type: Array of ContinuousDeploymentPolicySummary structures

A list of continuous deployment policy items.

MaxItems
Required: Yes
Type: int

The maximum number of continuous deployment policies that were specified in your request.

NextMarker
Type: string

Indicates the next page of continuous deployment policies. To get the next page of the list, use this value in the Marker field of your request.

Quantity
Required: Yes
Type: int

The total number of continuous deployment policies in your Amazon Web Services account, regardless of the MaxItems value.

ContinuousDeploymentPolicySummary

Description

A summary of the information about your continuous deployment policies.

Members
ContinuousDeploymentPolicy
Required: Yes
Type: ContinuousDeploymentPolicy structure

The continuous deployment policy.

ContinuousDeploymentSingleHeaderConfig

Description

This configuration determines which HTTP requests are sent to the staging distribution. If the HTTP request contains a header and value that matches what you specify here, the request is sent to the staging distribution. Otherwise the request is sent to the primary distribution.

Members
Header
Required: Yes
Type: string

The request header name that you want CloudFront to send to your staging distribution. The header must contain the prefix aws-cf-cd-.

Value
Required: Yes
Type: string

The request header value.

ContinuousDeploymentSingleWeightConfig

Description

Contains the percentage of traffic to send to a staging distribution.

Members
SessionStickinessConfig
Type: SessionStickinessConfig structure

Session stickiness provides the ability to define multiple requests from a single viewer as a single session. This prevents the potentially inconsistent experience of sending some of a given user's requests to your staging distribution, while others are sent to your primary distribution. Define the session duration using TTL values.

Weight
Required: Yes
Type: float

The percentage of traffic to send to a staging distribution, expressed as a decimal number between 0 and 0.15. For example, a value of 0.10 means 10% of traffic is sent to the staging distribution.

CookieNames

Description

Contains a list of cookie names.

Members
Items
Type: Array of strings

A list of cookie names.

Quantity
Required: Yes
Type: int

The number of cookie names in the Items list.

CookiePreference

Description

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include cookies in the cache key, use CookiesConfig in a cache policy. See CachePolicy.

If you want to send cookies to the origin but not include them in the cache key, use CookiesConfig in an origin request policy. See OriginRequestPolicy.

A complex type that specifies whether you want CloudFront to forward cookies to the origin and, if so, which ones. For more information about forwarding cookies to the origin, see Caching Content Based on Cookies in the Amazon CloudFront Developer Guide.

Members
Forward
Required: Yes
Type: string

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include cookies in the cache key, use a cache policy. For more information, see Creating cache policies in the Amazon CloudFront Developer Guide.

If you want to send cookies to the origin but not include them in the cache key, use origin request policy. For more information, see Creating origin request policies in the Amazon CloudFront Developer Guide.

Specifies which cookies to forward to the origin for this cache behavior: all, none, or the list of cookies specified in the WhitelistedNames complex type.

Amazon S3 doesn't process cookies. When the cache behavior is forwarding requests to an Amazon S3 origin, specify none for the Forward element.

WhitelistedNames
Type: CookieNames structure

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include cookies in the cache key, use a cache policy. For more information, see Creating cache policies in the Amazon CloudFront Developer Guide.

If you want to send cookies to the origin but not include them in the cache key, use an origin request policy. For more information, see Creating origin request policies in the Amazon CloudFront Developer Guide.

Required if you specify whitelist for the value of Forward. A complex type that specifies how many different cookies you want CloudFront to forward to the origin for this cache behavior and, if you want to forward selected cookies, the names of those cookies.

If you specify all or none for the value of Forward, omit WhitelistedNames. If you change the value of Forward from whitelist to all or none and you don't delete the WhitelistedNames element and its child elements, CloudFront deletes them automatically.

For the current limit on the number of cookie names that you can whitelist for each cache behavior, see CloudFront Limits in the Amazon Web Services General Reference.

CopyDistributionRequest

Members
CallerReference
Required: Yes
Type: string

A value that uniquely identifies a request to create a resource. This helps to prevent CloudFront from creating a duplicate resource if you accidentally resubmit an identical request.

Enabled
Type: boolean

A Boolean flag to specify the state of the staging distribution when it's created. When you set this value to True, the staging distribution is enabled. When you set this value to False, the staging distribution is disabled.

If you omit this field, the default value is True.

IfMatch
Type: string

The version identifier of the primary distribution whose configuration you are copying. This is the ETag value returned in the response to GetDistribution and GetDistributionConfig.

PrimaryDistributionId
Required: Yes
Type: string

The identifier of the primary distribution whose configuration you are copying. To get a distribution ID, use ListDistributions.

Staging
Type: boolean

The type of distribution that your primary distribution will be copied to. The only valid value is True, indicating that you are copying to a staging distribution.

CreateAnycastIpListRequest

Members
IpCount
Required: Yes
Type: int

The number of static IP addresses that are allocated to the Anycast static IP list.

Name
Required: Yes
Type: string

Name of the Anycast static IP list.

Tags
Type: Tags structure

A complex type that contains zero or more Tag elements.

CreateFunctionRequest

Members
FunctionCode
Required: Yes
Type: blob (string|resource|Psr\Http\Message\StreamInterface)

The function code. For more information about writing a CloudFront function, see Writing function code for CloudFront Functions in the Amazon CloudFront Developer Guide.

FunctionConfig
Required: Yes
Type: FunctionConfig structure

Configuration information about the function, including an optional comment and the function's runtime.

Name
Required: Yes
Type: string

A name to identify the function.

CreateKeyValueStoreRequest

Members
Comment
Type: string

The comment of the key value store.

ImportSource
Type: ImportSource structure

The S3 bucket that provides the source for the import. The source must be in a valid JSON format.

Name
Required: Yes
Type: string

The name of the key value store. The minimum length is 1 character and the maximum length is 64 characters.

CreateRealtimeLogConfigRequest

Members
EndPoints
Required: Yes
Type: Array of EndPoint structures

Contains information about the Amazon Kinesis data stream where you are sending real-time log data.

Fields
Required: Yes
Type: Array of strings

A list of fields to include in each real-time log record.

For more information about fields, see Real-time log configuration fields in the Amazon CloudFront Developer Guide.

Name
Required: Yes
Type: string

A unique name to identify this real-time log configuration.

SamplingRate
Required: Yes
Type: long (int|float)

The sampling rate for this real-time log configuration. You can specify a whole number between 1 and 100 (inclusive) to determine the percentage of viewer requests that are represented in the real-time log data.

CreateVpcOriginRequest

Members
Tags
Type: Tags structure

A complex type that contains zero or more Tag elements.

VpcOriginEndpointConfig
Required: Yes
Type: VpcOriginEndpointConfig structure

The VPC origin endpoint configuration.

CustomErrorResponse

Description

A complex type that controls:

  • Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range with custom error messages before returning the response to the viewer.

  • How long CloudFront caches HTTP status codes in the 4xx and 5xx range.

For more information about custom error pages, see Customizing Error Responses in the Amazon CloudFront Developer Guide.

Members
ErrorCachingMinTTL
Type: long (int|float)

The minimum amount of time, in seconds, that you want CloudFront to cache the HTTP status code specified in ErrorCode. When this time period has elapsed, CloudFront queries your origin to see whether the problem that caused the error has been resolved and the requested object is now available.

For more information, see Customizing Error Responses in the Amazon CloudFront Developer Guide.

ErrorCode
Required: Yes
Type: int

The HTTP status code for which you want to specify a custom error page and/or a caching duration.

ResponseCode
Type: string

The HTTP status code that you want CloudFront to return to the viewer along with the custom error page. There are a variety of reasons that you might want CloudFront to return a status code different from the status code that your origin returned to CloudFront, for example:

  • Some Internet devices (some firewalls and corporate proxies, for example) intercept HTTP 4xx and 5xx and prevent the response from being returned to the viewer. If you substitute 200, the response typically won't be intercepted.

  • If you don't care about distinguishing among different client errors or server errors, you can specify 400 or 500 as the ResponseCode for all 4xx or 5xx errors.

  • You might want to return a 200 status code (OK) and static website so your customers don't know that your website is down.

If you specify a value for ResponseCode, you must also specify a value for ResponsePagePath.

ResponsePagePath
Type: string

The path to the custom error page that you want CloudFront to return to a viewer when your origin returns the HTTP status code specified by ErrorCode, for example, /4xx-errors/403-forbidden.html. If you want to store your objects and your custom error pages in different locations, your distribution must include a cache behavior for which the following is true:

  • The value of PathPattern matches the path to your custom error messages. For example, suppose you saved custom error pages for 4xx errors in an Amazon S3 bucket in a directory named /4xx-errors. Your distribution must include a cache behavior for which the path pattern routes requests for your custom error pages to that location, for example, /4xx-errors/*.

  • The value of TargetOriginId specifies the value of the ID element for the origin that contains your custom error pages.

If you specify a value for ResponsePagePath, you must also specify a value for ResponseCode.

We recommend that you store custom error pages in an Amazon S3 bucket. If you store custom error pages on an HTTP server and the server starts to return 5xx errors, CloudFront can't get the files that you want to return to viewers because the origin server is unavailable.

CustomErrorResponses

Description

A complex type that controls:

  • Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range with custom error messages before returning the response to the viewer.

  • How long CloudFront caches HTTP status codes in the 4xx and 5xx range.

For more information about custom error pages, see Customizing Error Responses in the Amazon CloudFront Developer Guide.

Members
Items
Type: Array of CustomErrorResponse structures

A complex type that contains a CustomErrorResponse element for each HTTP status code for which you want to specify a custom error page and/or a caching duration.

Quantity
Required: Yes
Type: int

The number of HTTP status codes for which you want to specify a custom error page and/or a caching duration. If Quantity is 0, you can omit Items.

CustomHeaders

Description

A complex type that contains the list of Custom Headers for each origin.

Members
Items
Type: Array of OriginCustomHeader structures

Optional: A list that contains one OriginCustomHeader element for each custom header that you want CloudFront to forward to the origin. If Quantity is 0, omit Items.

Quantity
Required: Yes
Type: int

The number of custom headers, if any, for this distribution.

CustomOriginConfig

Description

A custom origin. A custom origin is any origin that is not an Amazon S3 bucket, with one exception. An Amazon S3 bucket that is configured with static website hosting is a custom origin.

Members
HTTPPort
Required: Yes
Type: int

The HTTP port that CloudFront uses to connect to the origin. Specify the HTTP port that the origin listens on.

HTTPSPort
Required: Yes
Type: int

The HTTPS port that CloudFront uses to connect to the origin. Specify the HTTPS port that the origin listens on.

OriginKeepaliveTimeout
Type: int

Specifies how long, in seconds, CloudFront persists its connection to the origin. The minimum timeout is 1 second, the maximum is 60 seconds, and the default (if you don't specify otherwise) is 5 seconds.

For more information, see Keep-alive timeout (custom origins only) in the Amazon CloudFront Developer Guide.

OriginProtocolPolicy
Required: Yes
Type: string

Specifies the protocol (HTTP or HTTPS) that CloudFront uses to connect to the origin. Valid values are:

  • http-only – CloudFront always uses HTTP to connect to the origin.

  • match-viewer – CloudFront connects to the origin using the same protocol that the viewer used to connect to CloudFront.

  • https-only – CloudFront always uses HTTPS to connect to the origin.

OriginReadTimeout
Type: int

Specifies how long, in seconds, CloudFront waits for a response from the origin. This is also known as the origin response timeout. The minimum timeout is 1 second, the maximum is 60 seconds, and the default (if you don't specify otherwise) is 30 seconds.

For more information, see Response timeout (custom origins only) in the Amazon CloudFront Developer Guide.

OriginSslProtocols
Type: OriginSslProtocols structure

Specifies the minimum SSL/TLS protocol that CloudFront uses when connecting to your origin over HTTPS. Valid values include SSLv3, TLSv1, TLSv1.1, and TLSv1.2.

For more information, see Minimum Origin SSL Protocol in the Amazon CloudFront Developer Guide.

DefaultCacheBehavior

Description

A complex type that describes the default cache behavior if you don't specify a CacheBehavior element or if request URLs don't match any of the values of PathPattern in CacheBehavior elements. You must create exactly one default cache behavior.

Members
AllowedMethods
Type: AllowedMethods structure

A complex type that controls which HTTP methods CloudFront processes and forwards to your Amazon S3 bucket or your custom origin. There are three choices:

  • CloudFront forwards only GET and HEAD requests.

  • CloudFront forwards only GET, HEAD, and OPTIONS requests.

  • CloudFront forwards GET, HEAD, OPTIONS, PUT, PATCH, POST, and DELETE requests.

If you pick the third choice, you may need to restrict access to your Amazon S3 bucket or to your custom origin so users can't perform operations that you don't want them to. For example, you might not want users to have permissions to delete objects from your origin.

CachePolicyId
Type: string

The unique identifier of the cache policy that is attached to the default cache behavior. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

A DefaultCacheBehavior must include either a CachePolicyId or ForwardedValues. We recommend that you use a CachePolicyId.

Compress
Type: boolean

Whether you want CloudFront to automatically compress certain files for this cache behavior. If so, specify true; if not, specify false. For more information, see Serving Compressed Files in the Amazon CloudFront Developer Guide.

DefaultTTL
Type: long (int|float)

This field is deprecated. We recommend that you use the DefaultTTL field in a cache policy instead of this field. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

The default amount of time that you want objects to stay in CloudFront caches before CloudFront forwards another request to your origin to determine whether the object has been updated. The value that you specify applies only when your origin does not add HTTP headers such as Cache-Control max-age, Cache-Control s-maxage, and Expires to objects. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

FieldLevelEncryptionId
Type: string

The value of ID for the field-level encryption configuration that you want CloudFront to use for encrypting specific fields of data for the default cache behavior.

ForwardedValues
Type: ForwardedValues structure

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field. For more information, see Working with policies in the Amazon CloudFront Developer Guide.

If you want to include values in the cache key, use a cache policy. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

If you want to send values to the origin but not include them in the cache key, use an origin request policy. For more information, see Creating origin request policies or Using the managed origin request policies in the Amazon CloudFront Developer Guide.

A DefaultCacheBehavior must include either a CachePolicyId or ForwardedValues. We recommend that you use a CachePolicyId.

A complex type that specifies how CloudFront handles query strings, cookies, and HTTP headers.

FunctionAssociations
Type: FunctionAssociations structure

A list of CloudFront functions that are associated with this cache behavior. Your functions must be published to the LIVE stage to associate them with a cache behavior.

GrpcConfig
Type: GrpcConfig structure

The gRPC configuration for your cache behavior.

LambdaFunctionAssociations
Type: LambdaFunctionAssociations structure

A complex type that contains zero or more Lambda@Edge function associations for a cache behavior.

MaxTTL
Type: long (int|float)

This field is deprecated. We recommend that you use the MaxTTL field in a cache policy instead of this field. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

The maximum amount of time that you want objects to stay in CloudFront caches before CloudFront forwards another request to your origin to determine whether the object has been updated. The value that you specify applies only when your origin adds HTTP headers such as Cache-Control max-age, Cache-Control s-maxage, and Expires to objects. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

MinTTL
Type: long (int|float)

This field is deprecated. We recommend that you use the MinTTL field in a cache policy instead of this field. For more information, see Creating cache policies or Using the managed cache policies in the Amazon CloudFront Developer Guide.

The minimum amount of time that you want objects to stay in CloudFront caches before CloudFront forwards another request to your origin to determine whether the object has been updated. For more information, see Managing How Long Content Stays in an Edge Cache (Expiration) in the Amazon CloudFront Developer Guide.

You must specify 0 for MinTTL if you configure CloudFront to forward all headers to your origin (under Headers, if you specify 1 for Quantity and * for Name).

OriginRequestPolicyId
Type: string

The unique identifier of the origin request policy that is attached to the default cache behavior. For more information, see Creating origin request policies or Using the managed origin request policies in the Amazon CloudFront Developer Guide.

RealtimeLogConfigArn
Type: string

The Amazon Resource Name (ARN) of the real-time log configuration that is attached to this cache behavior. For more information, see Real-time logs in the Amazon CloudFront Developer Guide.

ResponseHeadersPolicyId
Type: string

The identifier for a response headers policy.

SmoothStreaming
Type: boolean

Indicates whether you want to distribute media files in the Microsoft Smooth Streaming format using the origin that is associated with this cache behavior. If so, specify true; if not, specify false. If you specify true for SmoothStreaming, you can still distribute other content using this cache behavior if the content matches the value of PathPattern.

TargetOriginId
Required: Yes
Type: string

The value of ID for the origin that you want CloudFront to route requests to when they use the default cache behavior.

TrustedKeyGroups
Type: TrustedKeyGroups structure

A list of key groups that CloudFront can use to validate signed URLs or signed cookies.

When a cache behavior contains trusted key groups, CloudFront requires signed URLs or signed cookies for all requests that match the cache behavior. The URLs or cookies must be signed with a private key whose corresponding public key is in the key group. The signed URL or cookie contains information about which public key CloudFront should use to verify the signature. For more information, see Serving private content in the Amazon CloudFront Developer Guide.

TrustedSigners
Type: TrustedSigners structure

We recommend using TrustedKeyGroups instead of TrustedSigners.

A list of Amazon Web Services account IDs whose public keys CloudFront can use to validate signed URLs or signed cookies.

When a cache behavior contains trusted signers, CloudFront requires signed URLs or signed cookies for all requests that match the cache behavior. The URLs or cookies must be signed with the private key of a CloudFront key pair in a trusted signer's Amazon Web Services account. The signed URL or cookie contains information about which public key CloudFront should use to verify the signature. For more information, see Serving private content in the Amazon CloudFront Developer Guide.

ViewerProtocolPolicy
Required: Yes
Type: string

The protocol that viewers can use to access the files in the origin specified by TargetOriginId when a request matches the path pattern in PathPattern. You can specify the following options:

  • allow-all: Viewers can use HTTP or HTTPS.

  • redirect-to-https: If a viewer submits an HTTP request, CloudFront returns an HTTP status code of 301 (Moved Permanently) to the viewer along with the HTTPS URL. The viewer then resubmits the request using the new URL.

  • https-only: If a viewer sends an HTTP request, CloudFront returns an HTTP status code of 403 (Forbidden).

For more information about requiring the HTTPS protocol, see Requiring HTTPS Between Viewers and CloudFront in the Amazon CloudFront Developer Guide.

The only way to guarantee that viewers retrieve an object that was fetched from the origin using HTTPS is never to use any other protocol to fetch the object. If you have recently changed from HTTP to HTTPS, we recommend that you clear your objects' cache because cached objects are protocol agnostic. That means that an edge location will return an object from the cache regardless of whether the current request protocol matches the protocol used previously. For more information, see Managing Cache Expiration in the Amazon CloudFront Developer Guide.

DeleteRealtimeLogConfigRequest

Members
ARN
Type: string

The Amazon Resource Name (ARN) of the real-time log configuration to delete.

Name
Type: string

The name of the real-time log configuration to delete.

Distribution

Description

A distribution tells CloudFront where you want content to be delivered from, and the details about how to track and manage content delivery.

Members
ARN
Required: Yes
Type: string

The distribution's Amazon Resource Name (ARN).

ActiveTrustedKeyGroups
Type: ActiveTrustedKeyGroups structure

This field contains a list of key groups and the public keys in each key group that CloudFront can use to verify the signatures of signed URLs or signed cookies.

ActiveTrustedSigners
Type: ActiveTrustedSigners structure

We recommend using TrustedKeyGroups instead of TrustedSigners.

This field contains a list of Amazon Web Services account IDs and the active CloudFront key pairs in each account that CloudFront can use to verify the signatures of signed URLs or signed cookies.

AliasICPRecordals
Type: Array of AliasICPRecordal structures

Amazon Web Services services in China customers must file for an Internet Content Provider (ICP) recordal if they want to serve content publicly on an alternate domain name, also known as a CNAME, that they've added to CloudFront. AliasICPRecordal provides the ICP recordal status for CNAMEs associated with distributions.

For more information about ICP recordals, see Signup, Accounts, and Credentials in Getting Started with Amazon Web Services services in China.

DistributionConfig
Required: Yes
Type: DistributionConfig structure

The distribution's configuration.

DomainName
Required: Yes
Type: string

The distribution's CloudFront domain name. For example: d111111abcdef8.cloudfront.net.

Id
Required: Yes
Type: string

The distribution's identifier. For example: E1U5RQF7T870K0.

InProgressInvalidationBatches
Required: Yes
Type: int

The number of invalidation batches currently in progress.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the distribution was last modified.

Status
Required: Yes
Type: string

The distribution's status. When the status is Deployed, the distribution's information is fully propagated to all CloudFront edge locations.

DistributionAlreadyExists

Description

The caller reference you attempted to create the distribution with is associated with another distribution.

Members
Message
Type: string

DistributionConfig

Description

A distribution configuration.

Members
Aliases
Type: Aliases structure

A complex type that contains information about CNAMEs (alternate domain names), if any, for this distribution.

AnycastIpListId
Type: string

ID of the Anycast static IP list that is associated with the distribution.

CacheBehaviors
Type: CacheBehaviors structure

A complex type that contains zero or more CacheBehavior elements.

CallerReference
Required: Yes
Type: string

A unique value (for example, a date-time stamp) that ensures that the request can't be replayed.

If the value of CallerReference is new (regardless of the content of the DistributionConfig object), CloudFront creates a new distribution.

If CallerReference is a value that you already sent in a previous request to create a distribution, CloudFront returns a DistributionAlreadyExists error.

Comment
Required: Yes
Type: string

A comment to describe the distribution. The comment cannot be longer than 128 characters.

ContinuousDeploymentPolicyId
Type: string

The identifier of a continuous deployment policy. For more information, see CreateContinuousDeploymentPolicy.

CustomErrorResponses
Type: CustomErrorResponses structure

A complex type that controls the following:

  • Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range with custom error messages before returning the response to the viewer.

  • How long CloudFront caches HTTP status codes in the 4xx and 5xx range.

For more information about custom error pages, see Customizing Error Responses in the Amazon CloudFront Developer Guide.

DefaultCacheBehavior
Required: Yes
Type: DefaultCacheBehavior structure

A complex type that describes the default cache behavior if you don't specify a CacheBehavior element or if files don't match any of the values of PathPattern in CacheBehavior elements. You must create exactly one default cache behavior.

DefaultRootObject
Type: string

When a viewer requests the root URL for your distribution, the default root object is the object that you want CloudFront to request from your origin. For example, if your root URL is https://www.example.com, you can specify CloudFront to return the index.html file as the default root object. You can specify a default root object so that viewers see a specific file or object, instead of another object in your distribution (for example, https://www.example.com/product-description.html). A default root object avoids exposing the contents of your distribution.

You can specify the object name or a path to the object name (for example, index.html or exampleFolderName/index.html). Your string can't begin with a forward slash (/). Only specify the object name or the path to the object.

If you don't want to specify a default root object when you create a distribution, include an empty DefaultRootObject element.

To delete the default root object from an existing distribution, update the distribution configuration and include an empty DefaultRootObject element.

To replace the default root object, update the distribution configuration and specify the new object.

For more information about the default root object, see Specify a default root object in the Amazon CloudFront Developer Guide.

Enabled
Required: Yes
Type: boolean

From this field, you can enable or disable the selected distribution.

HttpVersion
Type: string

(Optional) Specify the HTTP version(s) that you want viewers to use to communicate with CloudFront. The default value for new web distributions is http2. Viewers that don't support HTTP/2 automatically use an earlier HTTP version.

For viewers and CloudFront to use HTTP/2, viewers must support TLSv1.2 or later, and must support Server Name Indication (SNI).

For viewers and CloudFront to use HTTP/3, viewers must support TLSv1.3 and Server Name Indication (SNI). CloudFront supports HTTP/3 connection migration to allow the viewer to switch networks without losing connection. For more information about connection migration, see Connection Migration at RFC 9000. For more information about supported TLSv1.3 ciphers, see Supported protocols and ciphers between viewers and CloudFront.

IsIPV6Enabled
Type: boolean

If you want CloudFront to respond to IPv6 DNS requests with an IPv6 address for your distribution, specify true. If you specify false, CloudFront responds to IPv6 DNS requests with the DNS response code NOERROR and with no IP addresses. This allows viewers to submit a second request, for an IPv4 address for your distribution.

In general, you should enable IPv6 if you have users on IPv6 networks who want to access your content. However, if you're using signed URLs or signed cookies to restrict access to your content, and if you're using a custom policy that includes the IpAddress parameter to restrict the IP addresses that can access your content, don't enable IPv6. If you want to restrict access to some content by IP address and not restrict access to other content (or restrict access but not by IP address), you can create two distributions. For more information, see Creating a Signed URL Using a Custom Policy in the Amazon CloudFront Developer Guide.

If you're using an Route 53 Amazon Web Services Integration alias resource record set to route traffic to your CloudFront distribution, you need to create a second alias resource record set when both of the following are true:

  • You enable IPv6 for the distribution

  • You're using alternate domain names in the URLs for your objects

For more information, see Routing Traffic to an Amazon CloudFront Web Distribution by Using Your Domain Name in the Route 53 Amazon Web Services Integration Developer Guide.

If you created a CNAME resource record set, either with Route 53 Amazon Web Services Integration or with another DNS service, you don't need to make any changes. A CNAME record will route traffic to your distribution regardless of the IP address format of the viewer request.

Logging
Type: LoggingConfig structure

A complex type that controls whether access logs are written for the distribution.

For more information about logging, see Access Logs in the Amazon CloudFront Developer Guide.

OriginGroups
Type: OriginGroups structure

A complex type that contains information about origin groups for this distribution.

Origins
Required: Yes
Type: Origins structure

A complex type that contains information about origins for this distribution.

PriceClass
Type: string

The price class that corresponds with the maximum price that you want to pay for CloudFront service. If you specify PriceClass_All, CloudFront responds to requests for your objects from all CloudFront edge locations.

If you specify a price class other than PriceClass_All, CloudFront serves your objects from the CloudFront edge location that has the lowest latency among the edge locations in your price class. Viewers who are in or near regions that are excluded from your specified price class may encounter slower performance.

For more information about price classes, see Choosing the Price Class for a CloudFront Distribution in the Amazon CloudFront Developer Guide. For information about CloudFront pricing, including how price classes (such as Price Class 100) map to CloudFront regions, see Amazon CloudFront Pricing.

Restrictions
Type: Restrictions structure

A complex type that identifies ways in which you want to restrict distribution of your content.

Staging
Type: boolean

A Boolean that indicates whether this is a staging distribution. When this value is true, this is a staging distribution. When this value is false, this is not a staging distribution.

ViewerCertificate
Type: ViewerCertificate structure

A complex type that determines the distribution's SSL/TLS configuration for communicating with viewers.

WebACLId
Type: string

A unique identifier that specifies the WAF web ACL, if any, to associate with this distribution. To specify a web ACL created using the latest version of WAF, use the ACL ARN, for example arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/a1b2c3d4-5678-90ab-cdef-EXAMPLE11111. To specify a web ACL created using WAF Classic, use the ACL ID, for example a1b2c3d4-5678-90ab-cdef-EXAMPLE11111.

WAF is a web application firewall that lets you monitor the HTTP and HTTPS requests that are forwarded to CloudFront, and lets you control access to your content. Based on conditions that you specify, such as the IP addresses that requests originate from or the values of query strings, CloudFront responds to requests either with the requested content or with an HTTP 403 status code (Forbidden). You can also configure CloudFront to return a custom error page when a request is blocked. For more information about WAF, see the WAF Developer Guide.

DistributionConfigWithTags

Description

A distribution Configuration and a list of tags to be associated with the distribution.

Members
DistributionConfig
Required: Yes
Type: DistributionConfig structure

A distribution configuration.

Tags
Required: Yes
Type: Tags structure

A complex type that contains zero or more Tag elements.

DistributionIdList

Description

A list of distribution IDs.

Members
IsTruncated
Required: Yes
Type: boolean

A flag that indicates whether more distribution IDs remain to be listed. If your results were truncated, you can make a subsequent request using the Marker request field to retrieve more distribution IDs in the list.

Items
Type: Array of strings

Contains the distribution IDs in the list.

Marker
Required: Yes
Type: string

The value provided in the Marker request field.

MaxItems
Required: Yes
Type: int

The maximum number of distribution IDs requested.

NextMarker
Type: string

Contains the value that you should use in the Marker field of a subsequent request to continue listing distribution IDs where you left off.

Quantity
Required: Yes
Type: int

The total number of distribution IDs returned in the response.

DistributionList

Description

A distribution list.

Members
IsTruncated
Required: Yes
Type: boolean

A flag that indicates whether more distributions remain to be listed. If your results were truncated, you can make a follow-up pagination request using the Marker request parameter to retrieve more distributions in the list.

Items
Type: Array of DistributionSummary structures

A complex type that contains one DistributionSummary element for each distribution that was created by the current Amazon Web Services account.

Marker
Required: Yes
Type: string

The value you provided for the Marker request parameter.

MaxItems
Required: Yes
Type: int

The value you provided for the MaxItems request parameter.

NextMarker
Type: string

If IsTruncated is true, this element is present and contains the value you can use for the Marker request parameter to continue listing your distributions where they left off.

Quantity
Required: Yes
Type: int

The number of distributions that were created by the current Amazon Web Services account.

DistributionNotDisabled

Description

The specified CloudFront distribution is not disabled. You must disable the distribution before you can delete it.

Members
Message
Type: string

DistributionSummary

Description

A summary of the information about a CloudFront distribution.

Members
ARN
Required: Yes
Type: string

The ARN (Amazon Resource Name) for the distribution. For example: arn:aws:cloudfront::123456789012:distribution/EDFDVBD632BHDS5, where 123456789012 is your Amazon Web Services account ID.

AliasICPRecordals
Type: Array of AliasICPRecordal structures

Amazon Web Services services in China customers must file for an Internet Content Provider (ICP) recordal if they want to serve content publicly on an alternate domain name, also known as a CNAME, that they've added to CloudFront. AliasICPRecordal provides the ICP recordal status for CNAMEs associated with distributions.

For more information about ICP recordals, see Signup, Accounts, and Credentials in Getting Started with Amazon Web Services services in China.

Aliases
Required: Yes
Type: Aliases structure

A complex type that contains information about CNAMEs (alternate domain names), if any, for this distribution.

AnycastIpListId
Type: string

ID of the Anycast static IP list that is associated with the distribution.

CacheBehaviors
Required: Yes
Type: CacheBehaviors structure

A complex type that contains zero or more CacheBehavior elements.

Comment
Required: Yes
Type: string

The comment originally specified when this distribution was created.

CustomErrorResponses
Required: Yes
Type: CustomErrorResponses structure

A complex type that contains zero or more CustomErrorResponses elements.

DefaultCacheBehavior
Required: Yes
Type: DefaultCacheBehavior structure

A complex type that describes the default cache behavior if you don't specify a CacheBehavior element or if files don't match any of the values of PathPattern in CacheBehavior elements. You must create exactly one default cache behavior.

DomainName
Required: Yes
Type: string

The domain name that corresponds to the distribution, for example, d111111abcdef8.cloudfront.net.

Enabled
Required: Yes
Type: boolean

Whether the distribution is enabled to accept user requests for content.

HttpVersion
Required: Yes
Type: string

Specify the maximum HTTP version that you want viewers to use to communicate with CloudFront. The default value for new web distributions is http2. Viewers that don't support HTTP/2 will automatically use an earlier version.

Id
Required: Yes
Type: string

The identifier for the distribution. For example: EDFDVBD632BHDS5.

IsIPV6Enabled
Required: Yes
Type: boolean

Whether CloudFront responds to IPv6 DNS requests with an IPv6 address for your distribution.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time the distribution was last modified.

OriginGroups
Type: OriginGroups structure

A complex type that contains information about origin groups for this distribution.

Origins
Required: Yes
Type: Origins structure

A complex type that contains information about origins for this distribution.

PriceClass
Required: Yes
Type: string

A complex type that contains information about price class for this streaming distribution.

Restrictions
Required: Yes
Type: Restrictions structure

A complex type that identifies ways in which you want to restrict distribution of your content.

Staging
Required: Yes
Type: boolean

A Boolean that indicates whether this is a staging distribution. When this value is true, this is a staging distribution. When this value is false, this is not a staging distribution.

Status
Required: Yes
Type: string

The current status of the distribution. When the status is Deployed, the distribution's information is propagated to all CloudFront edge locations.

ViewerCertificate
Required: Yes
Type: ViewerCertificate structure

A complex type that determines the distribution's SSL/TLS configuration for communicating with viewers.

WebACLId
Required: Yes
Type: string

The Web ACL Id (if any) associated with the distribution.

EncryptionEntities

Description

Complex data type for field-level encryption profiles that includes all of the encryption entities.

Members
Items
Type: Array of EncryptionEntity structures

An array of field patterns in a field-level encryption content type-profile mapping.

Quantity
Required: Yes
Type: int

Number of field pattern items in a field-level encryption content type-profile mapping.

EncryptionEntity

Description

Complex data type for field-level encryption profiles that includes the encryption key and field pattern specifications.

Members
FieldPatterns
Required: Yes
Type: FieldPatterns structure

Field patterns in a field-level encryption content type profile specify the fields that you want to be encrypted. You can provide the full field name, or any beginning characters followed by a wildcard (*). You can't overlap field patterns. For example, you can't have both ABC* and AB*. Note that field patterns are case-sensitive.

ProviderId
Required: Yes
Type: string

The provider associated with the public key being used for encryption. This value must also be provided with the private key for applications to be able to decrypt data.

PublicKeyId
Required: Yes
Type: string

The public key associated with a set of field-level encryption patterns, to be used when encrypting the fields that match the patterns.

EndPoint

Description

Contains information about the Amazon Kinesis data stream where you are sending real-time log data in a real-time log configuration.

Members
KinesisStreamConfig
Type: KinesisStreamConfig structure

Contains information about the Amazon Kinesis data stream where you are sending real-time log data.

StreamType
Required: Yes
Type: string

The type of data stream where you are sending real-time log data. The only valid value is Kinesis.

EntityAlreadyExists

Description

The entity already exists. You must provide a unique entity.

Members
Message
Type: string

EntityLimitExceeded

Description

The entity limit has been exceeded.

Members
Message
Type: string

EntityNotFound

Description

The entity was not found.

Members
Message
Type: string

EntitySizeLimitExceeded

Description

The entity size limit was exceeded.

Members
Message
Type: string

FieldLevelEncryption

Description

A complex data type that includes the profile configurations and other options specified for field-level encryption.

Members
FieldLevelEncryptionConfig
Required: Yes
Type: FieldLevelEncryptionConfig structure

A complex data type that includes the profile configurations specified for field-level encryption.

Id
Required: Yes
Type: string

The configuration ID for a field-level encryption configuration which includes a set of profiles that specify certain selected data fields to be encrypted by specific public keys.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The last time the field-level encryption configuration was changed.

FieldLevelEncryptionConfig

Description

A complex data type that includes the profile configurations specified for field-level encryption.

Members
CallerReference
Required: Yes
Type: string

A unique number that ensures the request can't be replayed.

Comment
Type: string

An optional comment about the configuration. The comment cannot be longer than 128 characters.

ContentTypeProfileConfig
Type: ContentTypeProfileConfig structure

A complex data type that specifies when to forward content if a content type isn't recognized and profiles to use as by default in a request if a query argument doesn't specify a profile to use.

QueryArgProfileConfig
Type: QueryArgProfileConfig structure

A complex data type that specifies when to forward content if a profile isn't found and the profile that can be provided as a query argument in a request.

FieldLevelEncryptionConfigAlreadyExists

Description

The specified configuration for field-level encryption already exists.

Members
Message
Type: string

FieldLevelEncryptionConfigInUse

Description

The specified configuration for field-level encryption is in use.

Members
Message
Type: string

FieldLevelEncryptionList

Description

List of field-level encryption configurations.

Members
Items
Type: Array of FieldLevelEncryptionSummary structures

An array of field-level encryption items.

MaxItems
Required: Yes
Type: int

The maximum number of elements you want in the response body.

NextMarker
Type: string

If there are more elements to be listed, this element is present and contains the value that you can use for the Marker request parameter to continue listing your configurations where you left off.

Quantity
Required: Yes
Type: int

The number of field-level encryption items.

FieldLevelEncryptionProfile

Description

A complex data type for field-level encryption profiles.

Members
FieldLevelEncryptionProfileConfig
Required: Yes
Type: FieldLevelEncryptionProfileConfig structure

A complex data type that includes the profile name and the encryption entities for the field-level encryption profile.

Id
Required: Yes
Type: string

The ID for a field-level encryption profile configuration which includes a set of profiles that specify certain selected data fields to be encrypted by specific public keys.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The last time the field-level encryption profile was updated.

FieldLevelEncryptionProfileAlreadyExists

Description

The specified profile for field-level encryption already exists.

Members
Message
Type: string

FieldLevelEncryptionProfileConfig

Description

A complex data type of profiles for the field-level encryption.

Members
CallerReference
Required: Yes
Type: string

A unique number that ensures that the request can't be replayed.

Comment
Type: string

An optional comment for the field-level encryption profile. The comment cannot be longer than 128 characters.

EncryptionEntities
Required: Yes
Type: EncryptionEntities structure

A complex data type of encryption entities for the field-level encryption profile that include the public key ID, provider, and field patterns for specifying which fields to encrypt with this key.

Name
Required: Yes
Type: string

Profile name for the field-level encryption profile.

FieldLevelEncryptionProfileInUse

Description

The specified profile for field-level encryption is in use.

Members
Message
Type: string

FieldLevelEncryptionProfileList

Description

List of field-level encryption profiles.

Members
Items
Type: Array of FieldLevelEncryptionProfileSummary structures

The field-level encryption profile items.

MaxItems
Required: Yes
Type: int

The maximum number of field-level encryption profiles you want in the response body.

NextMarker
Type: string

If there are more elements to be listed, this element is present and contains the value that you can use for the Marker request parameter to continue listing your profiles where you left off.

Quantity
Required: Yes
Type: int

The number of field-level encryption profiles.

FieldLevelEncryptionProfileSizeExceeded

Description

The maximum size of a profile for field-level encryption was exceeded.

Members
Message
Type: string

FieldLevelEncryptionProfileSummary

Description

The field-level encryption profile summary.

Members
Comment
Type: string

An optional comment for the field-level encryption profile summary. The comment cannot be longer than 128 characters.

EncryptionEntities
Required: Yes
Type: EncryptionEntities structure

A complex data type of encryption entities for the field-level encryption profile that include the public key ID, provider, and field patterns for specifying which fields to encrypt with this key.

Id
Required: Yes
Type: string

ID for the field-level encryption profile summary.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time when the field-level encryption profile summary was last updated.

Name
Required: Yes
Type: string

Name for the field-level encryption profile summary.

FieldLevelEncryptionSummary

Description

A summary of a field-level encryption item.

Members
Comment
Type: string

An optional comment about the field-level encryption item. The comment cannot be longer than 128 characters.

ContentTypeProfileConfig
Type: ContentTypeProfileConfig structure

A summary of a content type-profile mapping.

Id
Required: Yes
Type: string

The unique ID of a field-level encryption item.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The last time that the summary of field-level encryption items was modified.

QueryArgProfileConfig
Type: QueryArgProfileConfig structure

A summary of a query argument-profile mapping.

FieldPatterns

Description

A complex data type that includes the field patterns to match for field-level encryption.

Members
Items
Type: Array of strings

An array of the field-level encryption field patterns.

Quantity
Required: Yes
Type: int

The number of field-level encryption field patterns.

ForwardedValues

Description

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include values in the cache key, use a cache policy. For more information, see Creating cache policies in the Amazon CloudFront Developer Guide.

If you want to send values to the origin but not include them in the cache key, use an origin request policy. For more information, see Creating origin request policies in the Amazon CloudFront Developer Guide.

A complex type that specifies how CloudFront handles query strings, cookies, and HTTP headers.

Members
Cookies
Required: Yes
Type: CookiePreference structure

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include cookies in the cache key, use a cache policy. For more information, see Creating cache policies in the Amazon CloudFront Developer Guide.

If you want to send cookies to the origin but not include them in the cache key, use an origin request policy. For more information, see Creating origin request policies in the Amazon CloudFront Developer Guide.

A complex type that specifies whether you want CloudFront to forward cookies to the origin and, if so, which ones. For more information about forwarding cookies to the origin, see How CloudFront Forwards, Caches, and Logs Cookies in the Amazon CloudFront Developer Guide.

Headers
Type: Headers structure

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include headers in the cache key, use a cache policy. For more information, see Creating cache policies in the Amazon CloudFront Developer Guide.

If you want to send headers to the origin but not include them in the cache key, use an origin request policy. For more information, see Creating origin request policies in the Amazon CloudFront Developer Guide.

A complex type that specifies the Headers, if any, that you want CloudFront to forward to the origin for this cache behavior (whitelisted headers). For the headers that you specify, CloudFront also caches separate versions of a specified object that is based on the header values in viewer requests.

For more information, see Caching Content Based on Request Headers in the Amazon CloudFront Developer Guide.

QueryString
Required: Yes
Type: boolean

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include query strings in the cache key, use a cache policy. For more information, see Creating cache policies in the Amazon CloudFront Developer Guide.

If you want to send query strings to the origin but not include them in the cache key, use an origin request policy. For more information, see Creating origin request policies in the Amazon CloudFront Developer Guide.

Indicates whether you want CloudFront to forward query strings to the origin that is associated with this cache behavior and cache based on the query string parameters. CloudFront behavior depends on the value of QueryString and on the values that you specify for QueryStringCacheKeys, if any:

If you specify true for QueryString and you don't specify any values for QueryStringCacheKeys, CloudFront forwards all query string parameters to the origin and caches based on all query string parameters. Depending on how many query string parameters and values you have, this can adversely affect performance because CloudFront must forward more requests to the origin.

If you specify true for QueryString and you specify one or more values for QueryStringCacheKeys, CloudFront forwards all query string parameters to the origin, but it only caches based on the query string parameters that you specify.

If you specify false for QueryString, CloudFront doesn't forward any query string parameters to the origin, and doesn't cache based on query string parameters.

For more information, see Configuring CloudFront to Cache Based on Query String Parameters in the Amazon CloudFront Developer Guide.

QueryStringCacheKeys
Type: QueryStringCacheKeys structure

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include query strings in the cache key, use a cache policy. For more information, see Creating cache policies in the Amazon CloudFront Developer Guide.

If you want to send query strings to the origin but not include them in the cache key, use an origin request policy. For more information, see Creating origin request policies in the Amazon CloudFront Developer Guide.

A complex type that contains information about the query string parameters that you want CloudFront to use for caching for this cache behavior.

FunctionAlreadyExists

Description

A function with the same name already exists in this Amazon Web Services account. To create a function, you must provide a unique name. To update an existing function, use UpdateFunction.

Members
Message
Type: string

FunctionAssociation

Description

A CloudFront function that is associated with a cache behavior in a CloudFront distribution.

Members
EventType
Required: Yes
Type: string

The event type of the function, either viewer-request or viewer-response. You cannot use origin-facing event types (origin-request and origin-response) with a CloudFront function.

FunctionARN
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the function.

FunctionAssociations

Description

A list of CloudFront functions that are associated with a cache behavior in a CloudFront distribution. Your functions must be published to the LIVE stage to associate them with a cache behavior.

Members
Items
Type: Array of FunctionAssociation structures

The CloudFront functions that are associated with a cache behavior in a CloudFront distribution. Your functions must be published to the LIVE stage to associate them with a cache behavior.

Quantity
Required: Yes
Type: int

The number of CloudFront functions in the list.

FunctionConfig

Description

Contains configuration information about a CloudFront function.

Members
Comment
Required: Yes
Type: string

A comment to describe the function.

KeyValueStoreAssociations
Type: KeyValueStoreAssociations structure

The configuration for the key value store associations.

Runtime
Required: Yes
Type: string

The function's runtime environment version.

FunctionInUse

Description

Cannot delete the function because it's attached to one or more cache behaviors.

Members
Message
Type: string

FunctionList

Description

A list of CloudFront functions.

Members
Items
Type: Array of FunctionSummary structures

Contains the functions in the list.

MaxItems
Required: Yes
Type: int

The maximum number of functions requested.

NextMarker
Type: string

If there are more items in the list than are in this response, this element is present. It contains the value that you should use in the Marker field of a subsequent request to continue listing functions where you left off.

Quantity
Required: Yes
Type: int

The number of functions returned in the response.

FunctionMetadata

Description

Contains metadata about a CloudFront function.

Members
CreatedTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the function was created.

FunctionARN
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the function. The ARN uniquely identifies the function.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the function was most recently updated.

Stage
Type: string

The stage that the function is in, either DEVELOPMENT or LIVE.

When a function is in the DEVELOPMENT stage, you can test the function with TestFunction, and update it with UpdateFunction.

When a function is in the LIVE stage, you can attach the function to a distribution's cache behavior, using the function's ARN.

FunctionSizeLimitExceeded

Description

The function is too large. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

FunctionSummary

Description

Contains configuration information and metadata about a CloudFront function.

Members
FunctionConfig
Required: Yes
Type: FunctionConfig structure

Contains configuration information about a CloudFront function.

FunctionMetadata
Required: Yes
Type: FunctionMetadata structure

Contains metadata about a CloudFront function.

Name
Required: Yes
Type: string

The name of the CloudFront function.

Status
Type: string

The status of the CloudFront function.

GeoRestriction

Description

A complex type that controls the countries in which your content is distributed. CloudFront determines the location of your users using MaxMind GeoIP databases.

Members
Items
Type: Array of strings

A complex type that contains a Location element for each country in which you want CloudFront either to distribute your content (whitelist) or not distribute your content (blacklist).

The Location element is a two-letter, uppercase country code for a country that you want to include in your blacklist or whitelist. Include one Location element for each country.

CloudFront and MaxMind both use ISO 3166 country codes. For the current list of countries and the corresponding codes, see ISO 3166-1-alpha-2 code on the International Organization for Standardization website. You can also refer to the country list on the CloudFront console, which includes both country names and codes.

Quantity
Required: Yes
Type: int

When geo restriction is enabled, this is the number of countries in your whitelist or blacklist. Otherwise, when it is not enabled, Quantity is 0, and you can omit Items.

RestrictionType
Required: Yes
Type: string

The method that you want to use to restrict distribution of your content by country:

  • none: No geo restriction is enabled, meaning access to content is not restricted by client geo location.

  • blacklist: The Location elements specify the countries in which you don't want CloudFront to distribute your content.

  • whitelist: The Location elements specify the countries in which you want CloudFront to distribute your content.

GetRealtimeLogConfigRequest

Members
ARN
Type: string

The Amazon Resource Name (ARN) of the real-time log configuration to get.

Name
Type: string

The name of the real-time log configuration to get.

GrpcConfig

Description

Amazon CloudFront supports gRPC, an open-source remote procedure call (RPC) framework built on HTTP/2. gRPC offers bi-directional streaming and binary protocol that buffers payloads, making it suitable for applications that require low latency communications.

To enable your distribution to handle gRPC requests, you must include HTTP/2 as one of the supported HTTP versions and allow HTTP methods, including POST.

For more information, see Using gRPC with CloudFront distributions in the Amazon CloudFront Developer Guide.

Members
Enabled
Required: Yes
Type: boolean

Enables your CloudFront distribution to receive gRPC requests and to proxy them directly to your origins.

Headers

Description

Contains a list of HTTP header names.

Members
Items
Type: Array of strings

A list of HTTP header names.

Quantity
Required: Yes
Type: int

The number of header names in the Items list.

IllegalDelete

Description

Deletion is not allowed for this entity.

Members
Message
Type: string

IllegalFieldLevelEncryptionConfigAssociationWithCacheBehavior

Description

The specified configuration for field-level encryption can't be associated with the specified cache behavior.

Members
Message
Type: string

IllegalOriginAccessConfiguration

Description

An origin cannot contain both an origin access control (OAC) and an origin access identity (OAI).

Members
Message
Type: string

IllegalUpdate

Description

The update contains modifications that are not allowed.

Members
Message
Type: string

ImportSource

Description

The import source for the key value store.

Members
SourceARN
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the import source for the key value store.

SourceType
Required: Yes
Type: string

The source type of the import source for the key value store.

InconsistentQuantities

Description

The value of Quantity and the size of Items don't match.

Members
Message
Type: string

InvalidArgument

Description

An argument is invalid.

Members
Message
Type: string

InvalidDefaultRootObject

Description

The default root object file name is too big or contains an invalid character.

Members
Message
Type: string

InvalidDomainNameForOriginAccessControl

Description

An origin access control is associated with an origin whose domain name is not supported.

Members
Message
Type: string

InvalidErrorCode

Description

An invalid error code was specified.

Members
Message
Type: string

InvalidForwardCookies

Description

Your request contains forward cookies option which doesn't match with the expectation for the whitelisted list of cookie names. Either list of cookie names has been specified when not allowed or list of cookie names is missing when expected.

Members
Message
Type: string

InvalidFunctionAssociation

Description

A CloudFront function association is invalid.

Members
Message
Type: string

InvalidGeoRestrictionParameter

Description

The specified geo restriction parameter is not valid.

Members
Message
Type: string

InvalidHeadersForS3Origin

Description

The headers specified are not valid for an Amazon S3 origin.

Members
Message
Type: string

InvalidIfMatchVersion

Description

The If-Match version is missing or not valid.

Members
Message
Type: string

InvalidLambdaFunctionAssociation

Description

The specified Lambda@Edge function association is invalid.

Members
Message
Type: string

InvalidLocationCode

Description

The location code specified is not valid.

Members
Message
Type: string

InvalidMinimumProtocolVersion

Description

The minimum protocol version specified is not valid.

Members
Message
Type: string

InvalidOrigin

Description

The Amazon S3 origin server specified does not refer to a valid Amazon S3 bucket.

Members
Message
Type: string

InvalidOriginAccessControl

Description

The origin access control is not valid.

Members
Message
Type: string

InvalidOriginAccessIdentity

Description

The origin access identity is not valid or doesn't exist.

Members
Message
Type: string

InvalidOriginKeepaliveTimeout

Description

The keep alive timeout specified for the origin is not valid.

Members
Message
Type: string

InvalidOriginReadTimeout

Description

The read timeout specified for the origin is not valid.

Members
Message
Type: string

InvalidProtocolSettings

Description

You cannot specify SSLv3 as the minimum protocol version if you only want to support only clients that support Server Name Indication (SNI).

Members
Message
Type: string

InvalidQueryStringParameters

Description

The query string parameters specified are not valid.

Members
Message
Type: string

InvalidRelativePath

Description

The relative path is too big, is not URL-encoded, or does not begin with a slash (/).

Members
Message
Type: string

InvalidRequiredProtocol

Description

This operation requires the HTTPS protocol. Ensure that you specify the HTTPS protocol in your request, or omit the RequiredProtocols element from your distribution configuration.

Members
Message
Type: string

InvalidResponseCode

Description

A response code is not valid.

Members
Message
Type: string

InvalidTTLOrder

Description

The TTL order specified is not valid.

Members
Message
Type: string

InvalidTagging

Description

The tagging specified is not valid.

Members
Message
Type: string

InvalidViewerCertificate

Description

A viewer certificate specified is not valid.

Members
Message
Type: string

InvalidWebACLId

Description

A web ACL ID specified is not valid. To specify a web ACL created using the latest version of WAF, use the ACL ARN, for example arn:aws:wafv2:us-east-1:123456789012:global/webacl/ExampleWebACL/473e64fd-f30b-4765-81a0-62ad96dd167a. To specify a web ACL created using WAF Classic, use the ACL ID, for example 473e64fd-f30b-4765-81a0-62ad96dd167a.

Members
Message
Type: string

Invalidation

Description

An invalidation.

Members
CreateTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time the invalidation request was first made.

Id
Required: Yes
Type: string

The identifier for the invalidation request. For example: IDFDVBD632BHDS5.

InvalidationBatch
Required: Yes
Type: InvalidationBatch structure

The current invalidation information for the batch request.

Status
Required: Yes
Type: string

The status of the invalidation request. When the invalidation batch is finished, the status is Completed.

InvalidationBatch

Description

An invalidation batch.

Members
CallerReference
Required: Yes
Type: string

A value that you specify to uniquely identify an invalidation request. CloudFront uses the value to prevent you from accidentally resubmitting an identical request. Whenever you create a new invalidation request, you must specify a new value for CallerReference and change other values in the request as applicable. One way to ensure that the value of CallerReference is unique is to use a timestamp, for example, 20120301090000.

If you make a second invalidation request with the same value for CallerReference, and if the rest of the request is the same, CloudFront doesn't create a new invalidation request. Instead, CloudFront returns information about the invalidation request that you previously created with the same CallerReference.

If CallerReference is a value you already sent in a previous invalidation batch request but the content of any Path is different from the original request, CloudFront returns an InvalidationBatchAlreadyExists error.

Paths
Required: Yes
Type: Paths structure

A complex type that contains information about the objects that you want to invalidate. For more information, see Specifying the Objects to Invalidate in the Amazon CloudFront Developer Guide.

InvalidationList

Description

The InvalidationList complex type describes the list of invalidation objects. For more information about invalidation, see Invalidating Objects (Web Distributions Only) in the Amazon CloudFront Developer Guide.

Members
IsTruncated
Required: Yes
Type: boolean

A flag that indicates whether more invalidation batch requests remain to be listed. If your results were truncated, you can make a follow-up pagination request using the Marker request parameter to retrieve more invalidation batches in the list.

Items
Type: Array of InvalidationSummary structures

A complex type that contains one InvalidationSummary element for each invalidation batch created by the current Amazon Web Services account.

Marker
Required: Yes
Type: string

The value that you provided for the Marker request parameter.

MaxItems
Required: Yes
Type: int

The value that you provided for the MaxItems request parameter.

NextMarker
Type: string

If IsTruncated is true, this element is present and contains the value that you can use for the Marker request parameter to continue listing your invalidation batches where they left off.

Quantity
Required: Yes
Type: int

The number of invalidation batches that were created by the current Amazon Web Services account.

InvalidationSummary

Description

A summary of an invalidation request.

Members
CreateTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The time that an invalidation request was created.

Id
Required: Yes
Type: string

The unique ID for an invalidation request.

Status
Required: Yes
Type: string

The status of an invalidation request.

KGKeyPairIds

Description

A list of identifiers for the public keys that CloudFront can use to verify the signatures of signed URLs and signed cookies.

Members
KeyGroupId
Type: string

The identifier of the key group that contains the public keys.

KeyPairIds
Type: KeyPairIds structure

A list of CloudFront key pair identifiers.

KeyGroup

Description

A key group.

A key group contains a list of public keys that you can use with CloudFront signed URLs and signed cookies.

Members
Id
Required: Yes
Type: string

The identifier for the key group.

KeyGroupConfig
Required: Yes
Type: KeyGroupConfig structure

The key group configuration.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the key group was last modified.

KeyGroupAlreadyExists

Description

A key group with this name already exists. You must provide a unique name. To modify an existing key group, use UpdateKeyGroup.

Members
Message
Type: string

KeyGroupConfig

Description

A key group configuration.

A key group contains a list of public keys that you can use with CloudFront signed URLs and signed cookies.

Members
Comment
Type: string

A comment to describe the key group. The comment cannot be longer than 128 characters.

Items
Required: Yes
Type: Array of strings

A list of the identifiers of the public keys in the key group.

Name
Required: Yes
Type: string

A name to identify the key group.

KeyGroupList

Description

A list of key groups.

Members
Items
Type: Array of KeyGroupSummary structures

A list of key groups.

MaxItems
Required: Yes
Type: int

The maximum number of key groups requested.

NextMarker
Type: string

If there are more items in the list than are in this response, this element is present. It contains the value that you should use in the Marker field of a subsequent request to continue listing key groups.

Quantity
Required: Yes
Type: int

The number of key groups returned in the response.

KeyGroupSummary

Description

Contains information about a key group.

Members
KeyGroup
Required: Yes
Type: KeyGroup structure

A key group.

KeyPairIds

Description

A list of CloudFront key pair identifiers.

Members
Items
Type: Array of strings

A list of CloudFront key pair identifiers.

Quantity
Required: Yes
Type: int

The number of key pair identifiers in the list.

KeyValueStore

Description

The key value store. Use this to separate data from function code, allowing you to update data without having to publish a new version of a function. The key value store holds keys and their corresponding values.

Members
ARN
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the key value store.

Comment
Required: Yes
Type: string

A comment for the key value store.

Id
Required: Yes
Type: string

The unique Id for the key value store.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The last-modified time of the key value store.

Name
Required: Yes
Type: string

The name of the key value store.

Status
Type: string

The status of the key value store.

KeyValueStoreAssociation

Description

The key value store association.

Members
KeyValueStoreARN
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the key value store association.

KeyValueStoreAssociations

Description

The key value store associations.

Members
Items
Type: Array of KeyValueStoreAssociation structures

The items of the key value store association.

Quantity
Required: Yes
Type: int

The quantity of key value store associations.

KeyValueStoreList

Description

The key value store list.

Members
Items
Type: Array of KeyValueStore structures

The items of the key value store list.

MaxItems
Required: Yes
Type: int

The maximum number of items in the key value store list.

NextMarker
Type: string

The next marker associated with the key value store list.

Quantity
Required: Yes
Type: int

The quantity of the key value store list.

KinesisStreamConfig

Description

Contains information about the Amazon Kinesis data stream where you are sending real-time log data.

Members
RoleARN
Required: Yes
Type: string

The Amazon Resource Name (ARN) of an Identity and Access Management (IAM) role that CloudFront can use to send real-time log data to your Kinesis data stream.

For more information the IAM role, see Real-time log configuration IAM role in the Amazon CloudFront Developer Guide.

StreamARN
Required: Yes
Type: string

The Amazon Resource Name (ARN) of the Kinesis data stream where you are sending real-time log data.

LambdaFunctionAssociation

Description

A complex type that contains a Lambda@Edge function association.

Members
EventType
Required: Yes
Type: string

Specifies the event type that triggers a Lambda@Edge function invocation. You can specify the following values:

  • viewer-request: The function executes when CloudFront receives a request from a viewer and before it checks to see whether the requested object is in the edge cache.

  • origin-request: The function executes only when CloudFront sends a request to your origin. When the requested object is in the edge cache, the function doesn't execute.

  • origin-response: The function executes after CloudFront receives a response from the origin and before it caches the object in the response. When the requested object is in the edge cache, the function doesn't execute.

  • viewer-response: The function executes before CloudFront returns the requested object to the viewer. The function executes regardless of whether the object was already in the edge cache.

    If the origin returns an HTTP status code other than HTTP 200 (OK), the function doesn't execute.

IncludeBody
Type: boolean

A flag that allows a Lambda@Edge function to have read access to the body content. For more information, see Accessing the Request Body by Choosing the Include Body Option in the Amazon CloudFront Developer Guide.

LambdaFunctionARN
Required: Yes
Type: string

The ARN of the Lambda@Edge function. You must specify the ARN of a function version; you can't specify an alias or $LATEST.

LambdaFunctionAssociations

Description

A complex type that specifies a list of Lambda@Edge functions associations for a cache behavior.

If you want to invoke one or more Lambda@Edge functions triggered by requests that match the PathPattern of the cache behavior, specify the applicable values for Quantity and Items. Note that there can be up to 4 LambdaFunctionAssociation items in this list (one for each possible value of EventType) and each EventType can be associated with only one function.

If you don't want to invoke any Lambda@Edge functions for the requests that match PathPattern, specify 0 for Quantity and omit Items.

Members
Items
Type: Array of LambdaFunctionAssociation structures

Optional: A complex type that contains LambdaFunctionAssociation items for this cache behavior. If Quantity is 0, you can omit Items.

Quantity
Required: Yes
Type: int

The number of Lambda@Edge function associations for this cache behavior.

ListDistributionsByRealtimeLogConfigRequest

Members
Marker
Type: string

Use this field when paginating results to indicate where to begin in your list of distributions. The response includes distributions in the list that occur after the marker. To get the next page of the list, set this field's value to the value of NextMarker from the current page's response.

MaxItems
Type: string

The maximum number of distributions that you want in the response.

RealtimeLogConfigArn
Type: string

The Amazon Resource Name (ARN) of the real-time log configuration whose associated distributions you want to list.

RealtimeLogConfigName
Type: string

The name of the real-time log configuration whose associated distributions you want to list.

LoggingConfig

Description

A complex type that specifies whether access logs are written for the distribution.

If you already enabled standard logging (legacy) and you want to enable standard logging (v2) to send your access logs to Amazon S3, we recommend that you specify a different Amazon S3 bucket or use a separate path in the same bucket (for example, use a log prefix or partitioning). This helps you keep track of which log files are associated with which logging subscription and prevents log files from overwriting each other. For more information, see Standard logging (access logs) in the Amazon CloudFront Developer Guide.

Members
Bucket
Type: string

The Amazon S3 bucket to store the access logs in, for example, amzn-s3-demo-bucket.s3.amazonaws.com.

Enabled
Type: boolean

Specifies whether you want CloudFront to save access logs to an Amazon S3 bucket. If you don't want to enable logging when you create a distribution or if you want to disable logging for an existing distribution, specify false for Enabled, and specify empty Bucket and Prefix elements. If you specify false for Enabled but you specify values for Bucket and prefix, the values are automatically deleted.

IncludeCookies
Type: boolean

Specifies whether you want CloudFront to include cookies in access logs, specify true for IncludeCookies. If you choose to include cookies in logs, CloudFront logs all cookies regardless of how you configure the cache behaviors for this distribution. If you don't want to include cookies when you create a distribution or if you want to disable include cookies for an existing distribution, specify false for IncludeCookies.

Prefix
Type: string

An optional string that you want CloudFront to prefix to the access log filenames for this distribution, for example, myprefix/. If you want to enable logging, but you don't want to specify a prefix, you still must include an empty Prefix element in the Logging element.

MissingBody

Description

This operation requires a body. Ensure that the body is present and the Content-Type header is set.

Members
Message
Type: string

MonitoringSubscription

Description

A monitoring subscription. This structure contains information about whether additional CloudWatch metrics are enabled for a given CloudFront distribution.

Members
RealtimeMetricsSubscriptionConfig

A subscription configuration for additional CloudWatch metrics.

MonitoringSubscriptionAlreadyExists

Description

A monitoring subscription already exists for the specified distribution.

Members
Message
Type: string

NoSuchCachePolicy

Description

The cache policy does not exist.

Members
Message
Type: string

NoSuchCloudFrontOriginAccessIdentity

Description

The specified origin access identity does not exist.

Members
Message
Type: string

NoSuchContinuousDeploymentPolicy

Description

The continuous deployment policy doesn't exist.

Members
Message
Type: string

NoSuchDistribution

Description

The specified distribution does not exist.

Members
Message
Type: string

NoSuchFieldLevelEncryptionConfig

Description

The specified configuration for field-level encryption doesn't exist.

Members
Message
Type: string

NoSuchFieldLevelEncryptionProfile

Description

The specified profile for field-level encryption doesn't exist.

Members
Message
Type: string

NoSuchFunctionExists

Description

The function does not exist.

Members
Message
Type: string

NoSuchInvalidation

Description

The specified invalidation does not exist.

Members
Message
Type: string

NoSuchMonitoringSubscription

Description

A monitoring subscription does not exist for the specified distribution.

Members
Message
Type: string

NoSuchOrigin

Description

No origin exists with the specified Origin Id.

Members
Message
Type: string

NoSuchOriginAccessControl

Description

The origin access control does not exist.

Members
Message
Type: string

NoSuchOriginRequestPolicy

Description

The origin request policy does not exist.

Members
Message
Type: string

NoSuchPublicKey

Description

The specified public key doesn't exist.

Members
Message
Type: string

NoSuchRealtimeLogConfig

Description

The real-time log configuration does not exist.

Members
Message
Type: string

NoSuchResource

Description

A resource that was specified is not valid.

Members
Message
Type: string

NoSuchResponseHeadersPolicy

Description

The response headers policy does not exist.

Members
Message
Type: string

NoSuchStreamingDistribution

Description

The specified streaming distribution does not exist.

Members
Message
Type: string

Origin

Description

An origin.

An origin is the location where content is stored, and from which CloudFront gets content to serve to viewers. To specify an origin:

  • Use S3OriginConfig to specify an Amazon S3 bucket that is not configured with static website hosting.

  • Use CustomOriginConfig to specify all other kinds of origins, including:

    • An Amazon S3 bucket that is configured with static website hosting

    • An Elastic Load Balancing load balancer

    • An Elemental MediaPackage endpoint

    • An Elemental MediaStore container

    • Any other HTTP server, running on an Amazon EC2 instance or any other kind of host

For the current maximum number of origins that you can specify per distribution, see General Quotas on Web Distributions in the Amazon CloudFront Developer Guide (quotas were formerly referred to as limits).

Members
ConnectionAttempts
Type: int

The number of times that CloudFront attempts to connect to the origin. The minimum number is 1, the maximum is 3, and the default (if you don't specify otherwise) is 3.

For a custom origin (including an Amazon S3 bucket that's configured with static website hosting), this value also specifies the number of times that CloudFront attempts to get a response from the origin, in the case of an Origin Response Timeout.

For more information, see Origin Connection Attempts in the Amazon CloudFront Developer Guide.

ConnectionTimeout
Type: int

The number of seconds that CloudFront waits when trying to establish a connection to the origin. The minimum timeout is 1 second, the maximum is 10 seconds, and the default (if you don't specify otherwise) is 10 seconds.

For more information, see Origin Connection Timeout in the Amazon CloudFront Developer Guide.

CustomHeaders
Type: CustomHeaders structure

A list of HTTP header names and values that CloudFront adds to the requests that it sends to the origin.

For more information, see Adding Custom Headers to Origin Requests in the Amazon CloudFront Developer Guide.

CustomOriginConfig
Type: CustomOriginConfig structure

Use this type to specify an origin that is not an Amazon S3 bucket, with one exception. If the Amazon S3 bucket is configured with static website hosting, use this type. If the Amazon S3 bucket is not configured with static website hosting, use the S3OriginConfig type instead.

DomainName
Required: Yes
Type: string

The domain name for the origin.

For more information, see Origin Domain Name in the Amazon CloudFront Developer Guide.

Id
Required: Yes
Type: string

A unique identifier for the origin. This value must be unique within the distribution.

Use this value to specify the TargetOriginId in a CacheBehavior or DefaultCacheBehavior.

OriginAccessControlId
Type: string

The unique identifier of an origin access control for this origin.

For more information, see Restricting access to an Amazon S3 origin in the Amazon CloudFront Developer Guide.

OriginPath
Type: string

An optional path that CloudFront appends to the origin domain name when CloudFront requests content from the origin.

For more information, see Origin Path in the Amazon CloudFront Developer Guide.

OriginShield
Type: OriginShield structure

CloudFront Origin Shield. Using Origin Shield can help reduce the load on your origin.

For more information, see Using Origin Shield in the Amazon CloudFront Developer Guide.

S3OriginConfig
Type: S3OriginConfig structure

Use this type to specify an origin that is an Amazon S3 bucket that is not configured with static website hosting. To specify any other type of origin, including an Amazon S3 bucket that is configured with static website hosting, use the CustomOriginConfig type instead.

VpcOriginConfig
Type: VpcOriginConfig structure

The VPC origin configuration.

OriginAccessControl

Description

A CloudFront origin access control, including its unique identifier.

Members
Id
Required: Yes
Type: string

The unique identifier of the origin access control.

OriginAccessControlConfig
Type: OriginAccessControlConfig structure

The origin access control.

OriginAccessControlAlreadyExists

Description

An origin access control with the specified parameters already exists.

Members
Message
Type: string

OriginAccessControlConfig

Description

A CloudFront origin access control configuration.

Members
Description
Type: string

A description of the origin access control.

Name
Required: Yes
Type: string

A name to identify the origin access control. You can specify up to 64 characters.

OriginAccessControlOriginType
Required: Yes
Type: string

The type of origin that this origin access control is for.

SigningBehavior
Required: Yes
Type: string

Specifies which requests CloudFront signs (adds authentication information to). Specify always for the most common use case. For more information, see origin access control advanced settings in the Amazon CloudFront Developer Guide.

This field can have one of the following values:

  • always – CloudFront signs all origin requests, overwriting the Authorization header from the viewer request if one exists.

  • never – CloudFront doesn't sign any origin requests. This value turns off origin access control for all origins in all distributions that use this origin access control.

  • no-override – If the viewer request doesn't contain the Authorization header, then CloudFront signs the origin request. If the viewer request contains the Authorization header, then CloudFront doesn't sign the origin request and instead passes along the Authorization header from the viewer request. WARNING: To pass along the Authorization header from the viewer request, you must add the Authorization header to a cache policy for all cache behaviors that use origins associated with this origin access control.

SigningProtocol
Required: Yes
Type: string

The signing protocol of the origin access control, which determines how CloudFront signs (authenticates) requests. The only valid value is sigv4.

OriginAccessControlInUse

Description

Cannot delete the origin access control because it's in use by one or more distributions.

Members
Message
Type: string

OriginAccessControlList

Description

A list of CloudFront origin access controls.

Members
IsTruncated
Required: Yes
Type: boolean

If there are more items in the list than are in this response, this value is true.

Items
Type: Array of OriginAccessControlSummary structures

Contains the origin access controls in the list.

Marker
Required: Yes
Type: string

The value of the Marker field that was provided in the request.

MaxItems
Required: Yes
Type: int

The maximum number of origin access controls requested.

NextMarker
Type: string

If there are more items in the list than are in this response, this element is present. It contains the value to use in the Marker field of another request to continue listing origin access controls.

Quantity
Required: Yes
Type: int

The number of origin access controls returned in the response.

OriginAccessControlSummary

Description

A CloudFront origin access control.

Members
Description
Required: Yes
Type: string

A description of the origin access control.

Id
Required: Yes
Type: string

The unique identifier of the origin access control.

Name
Required: Yes
Type: string

A unique name that identifies the origin access control.

OriginAccessControlOriginType
Required: Yes
Type: string

The type of origin that this origin access control is for.

SigningBehavior
Required: Yes
Type: string

A value that specifies which requests CloudFront signs (adds authentication information to). This field can have one of the following values:

  • never – CloudFront doesn't sign any origin requests.

  • always – CloudFront signs all origin requests, overwriting the Authorization header from the viewer request if necessary.

  • no-override – If the viewer request doesn't contain the Authorization header, CloudFront signs the origin request. If the viewer request contains the Authorization header, CloudFront doesn't sign the origin request, but instead passes along the Authorization header that it received in the viewer request.

SigningProtocol
Required: Yes
Type: string

The signing protocol of the origin access control. The signing protocol determines how CloudFront signs (authenticates) requests. The only valid value is sigv4.

OriginCustomHeader

Description

A complex type that contains HeaderName and HeaderValue elements, if any, for this distribution.

Members
HeaderName
Required: Yes
Type: string

The name of a header that you want CloudFront to send to your origin. For more information, see Adding Custom Headers to Origin Requests in the Amazon CloudFront Developer Guide.

HeaderValue
Required: Yes
Type: string

The value for the header that you specified in the HeaderName field.

OriginGroup

Description

An origin group includes two origins (a primary origin and a secondary origin to failover to) and a failover criteria that you specify. You create an origin group to support origin failover in CloudFront. When you create or update a distribution, you can specify the origin group instead of a single origin, and CloudFront will failover from the primary origin to the secondary origin under the failover conditions that you've chosen.

Optionally, you can choose selection criteria for your origin group to specify how your origins are selected when your distribution routes viewer requests.

Members
FailoverCriteria
Required: Yes
Type: OriginGroupFailoverCriteria structure

A complex type that contains information about the failover criteria for an origin group.

Id
Required: Yes
Type: string

The origin group's ID.

Members
Required: Yes
Type: OriginGroupMembers structure

A complex type that contains information about the origins in an origin group.

SelectionCriteria
Type: string

The selection criteria for the origin group. For more information, see Create an origin group in the Amazon CloudFront Developer Guide.

OriginGroupFailoverCriteria

Description

A complex data type that includes information about the failover criteria for an origin group, including the status codes for which CloudFront will failover from the primary origin to the second origin.

Members
StatusCodes
Required: Yes
Type: StatusCodes structure

The status codes that, when returned from the primary origin, will trigger CloudFront to failover to the second origin.

OriginGroupMember

Description

An origin in an origin group.

Members
OriginId
Required: Yes
Type: string

The ID for an origin in an origin group.

OriginGroupMembers

Description

A complex data type for the origins included in an origin group.

Members
Items
Required: Yes
Type: Array of OriginGroupMember structures

Items (origins) in an origin group.

Quantity
Required: Yes
Type: int

The number of origins in an origin group.

OriginGroups

Description

A complex data type for the origin groups specified for a distribution.

Members
Items
Type: Array of OriginGroup structures

The items (origin groups) in a distribution.

Quantity
Required: Yes
Type: int

The number of origin groups.

OriginRequestPolicy

Description

An origin request policy.

When it's attached to a cache behavior, the origin request policy determines the values that CloudFront includes in requests that it sends to the origin. Each request that CloudFront sends to the origin includes the following:

  • The request body and the URL path (without the domain name) from the viewer request.

  • The headers that CloudFront automatically includes in every origin request, including Host, User-Agent, and X-Amz-Cf-Id.

  • All HTTP headers, cookies, and URL query strings that are specified in the cache policy or the origin request policy. These can include items from the viewer request and, in the case of headers, additional ones that are added by CloudFront.

CloudFront sends a request when it can't find an object in its cache that matches the request. If you want to send values to the origin and also include them in the cache key, use CachePolicy.

Members
Id
Required: Yes
Type: string

The unique identifier for the origin request policy.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the origin request policy was last modified.

OriginRequestPolicyConfig
Required: Yes
Type: OriginRequestPolicyConfig structure

The origin request policy configuration.

OriginRequestPolicyAlreadyExists

Description

An origin request policy with this name already exists. You must provide a unique name. To modify an existing origin request policy, use UpdateOriginRequestPolicy.

Members
Message
Type: string

OriginRequestPolicyConfig

Description

An origin request policy configuration.

This configuration determines the values that CloudFront includes in requests that it sends to the origin. Each request that CloudFront sends to the origin includes the following:

  • The request body and the URL path (without the domain name) from the viewer request.

  • The headers that CloudFront automatically includes in every origin request, including Host, User-Agent, and X-Amz-Cf-Id.

  • All HTTP headers, cookies, and URL query strings that are specified in the cache policy or the origin request policy. These can include items from the viewer request and, in the case of headers, additional ones that are added by CloudFront.

CloudFront sends a request when it can't find an object in its cache that matches the request. If you want to send values to the origin and also include them in the cache key, use CachePolicy.

Members
Comment
Type: string

A comment to describe the origin request policy. The comment cannot be longer than 128 characters.

CookiesConfig
Required: Yes
Type: OriginRequestPolicyCookiesConfig structure

The cookies from viewer requests to include in origin requests.

HeadersConfig
Required: Yes
Type: OriginRequestPolicyHeadersConfig structure

The HTTP headers to include in origin requests. These can include headers from viewer requests and additional headers added by CloudFront.

Name
Required: Yes
Type: string

A unique name to identify the origin request policy.

QueryStringsConfig
Required: Yes
Type: OriginRequestPolicyQueryStringsConfig structure

The URL query strings from viewer requests to include in origin requests.

OriginRequestPolicyCookiesConfig

Description

An object that determines whether any cookies in viewer requests (and if so, which cookies) are included in requests that CloudFront sends to the origin.

Members
CookieBehavior
Required: Yes
Type: string

Determines whether cookies in viewer requests are included in requests that CloudFront sends to the origin. Valid values are:

  • none – No cookies in viewer requests are included in requests that CloudFront sends to the origin. Even when this field is set to none, any cookies that are listed in a CachePolicy are included in origin requests.

  • whitelist – Only the cookies in viewer requests that are listed in the CookieNames type are included in requests that CloudFront sends to the origin.

  • all – All cookies in viewer requests are included in requests that CloudFront sends to the origin.

  • allExcept – All cookies in viewer requests are included in requests that CloudFront sends to the origin, except for those listed in the CookieNames type, which are not included.

Cookies
Type: CookieNames structure

Contains a list of cookie names.

OriginRequestPolicyHeadersConfig

Description

An object that determines whether any HTTP headers (and if so, which headers) are included in requests that CloudFront sends to the origin.

Members
HeaderBehavior
Required: Yes
Type: string

Determines whether any HTTP headers are included in requests that CloudFront sends to the origin. Valid values are:

  • none – No HTTP headers in viewer requests are included in requests that CloudFront sends to the origin. Even when this field is set to none, any headers that are listed in a CachePolicy are included in origin requests.

  • whitelist – Only the HTTP headers that are listed in the Headers type are included in requests that CloudFront sends to the origin.

  • allViewer – All HTTP headers in viewer requests are included in requests that CloudFront sends to the origin.

  • allViewerAndWhitelistCloudFront – All HTTP headers in viewer requests and the additional CloudFront headers that are listed in the Headers type are included in requests that CloudFront sends to the origin. The additional headers are added by CloudFront.

  • allExcept – All HTTP headers in viewer requests are included in requests that CloudFront sends to the origin, except for those listed in the Headers type, which are not included.

Headers
Type: Headers structure

Contains a list of HTTP header names.

OriginRequestPolicyInUse

Description

Cannot delete the origin request policy because it is attached to one or more cache behaviors.

Members
Message
Type: string

OriginRequestPolicyList

Description

A list of origin request policies.

Members
Items
Type: Array of OriginRequestPolicySummary structures

Contains the origin request policies in the list.

MaxItems
Required: Yes
Type: int

The maximum number of origin request policies requested.

NextMarker
Type: string

If there are more items in the list than are in this response, this element is present. It contains the value that you should use in the Marker field of a subsequent request to continue listing origin request policies where you left off.

Quantity
Required: Yes
Type: int

The total number of origin request policies returned in the response.

OriginRequestPolicyQueryStringsConfig

Description

An object that determines whether any URL query strings in viewer requests (and if so, which query strings) are included in requests that CloudFront sends to the origin.

Members
QueryStringBehavior
Required: Yes
Type: string

Determines whether any URL query strings in viewer requests are included in requests that CloudFront sends to the origin. Valid values are:

  • none – No query strings in viewer requests are included in requests that CloudFront sends to the origin. Even when this field is set to none, any query strings that are listed in a CachePolicy are included in origin requests.

  • whitelist – Only the query strings in viewer requests that are listed in the QueryStringNames type are included in requests that CloudFront sends to the origin.

  • all – All query strings in viewer requests are included in requests that CloudFront sends to the origin.

  • allExcept – All query strings in viewer requests are included in requests that CloudFront sends to the origin, except for those listed in the QueryStringNames type, which are not included.

QueryStrings
Type: QueryStringNames structure

Contains the specific query strings in viewer requests that either are or are not included in requests that CloudFront sends to the origin. The behavior depends on whether the QueryStringBehavior field in the OriginRequestPolicyQueryStringsConfig type is set to whitelist (the listed query strings are included) or allExcept (the listed query strings are not included, but all other query strings are).

OriginRequestPolicySummary

Description

Contains an origin request policy.

Members
OriginRequestPolicy
Required: Yes
Type: OriginRequestPolicy structure

The origin request policy.

Type
Required: Yes
Type: string

The type of origin request policy, either managed (created by Amazon Web Services) or custom (created in this Amazon Web Services account).

OriginShield

Description

CloudFront Origin Shield.

Using Origin Shield can help reduce the load on your origin. For more information, see Using Origin Shield in the Amazon CloudFront Developer Guide.

Members
Enabled
Required: Yes
Type: boolean

A flag that specifies whether Origin Shield is enabled.

When it's enabled, CloudFront routes all requests through Origin Shield, which can help protect your origin. When it's disabled, CloudFront might send requests directly to your origin from multiple edge locations or regional edge caches.

OriginShieldRegion
Type: string

The Amazon Web Services Region for Origin Shield.

Specify the Amazon Web Services Region that has the lowest latency to your origin. To specify a region, use the region code, not the region name. For example, specify the US East (Ohio) region as us-east-2.

When you enable CloudFront Origin Shield, you must specify the Amazon Web Services Region for Origin Shield. For the list of Amazon Web Services Regions that you can specify, and for help choosing the best Region for your origin, see Choosing the Amazon Web Services Region for Origin Shield in the Amazon CloudFront Developer Guide.

OriginSslProtocols

Description

A complex type that contains information about the SSL/TLS protocols that CloudFront can use when establishing an HTTPS connection with your origin.

Members
Items
Required: Yes
Type: Array of strings

A list that contains allowed SSL/TLS protocols for this distribution.

Quantity
Required: Yes
Type: int

The number of SSL/TLS protocols that you want to allow CloudFront to use when establishing an HTTPS connection with this origin.

Origins

Description

Contains information about the origins for this distribution.

Members
Items
Required: Yes
Type: Array of Origin structures

A list of origins.

Quantity
Required: Yes
Type: int

The number of origins for this distribution.

ParametersInCacheKeyAndForwardedToOrigin

Description

This object determines the values that CloudFront includes in the cache key. These values can include HTTP headers, cookies, and URL query strings. CloudFront uses the cache key to find an object in its cache that it can return to the viewer.

The headers, cookies, and query strings that are included in the cache key are also included in requests that CloudFront sends to the origin. CloudFront sends a request when it can't find an object in its cache that matches the request's cache key. If you want to send values to the origin but not include them in the cache key, use OriginRequestPolicy.

Members
CookiesConfig
Required: Yes
Type: CachePolicyCookiesConfig structure

An object that determines whether any cookies in viewer requests (and if so, which cookies) are included in the cache key and in requests that CloudFront sends to the origin.

EnableAcceptEncodingBrotli
Type: boolean

A flag that can affect whether the Accept-Encoding HTTP header is included in the cache key and included in requests that CloudFront sends to the origin.

This field is related to the EnableAcceptEncodingGzip field. If one or both of these fields is true and the viewer request includes the Accept-Encoding header, then CloudFront does the following:

  • Normalizes the value of the viewer's Accept-Encoding header

  • Includes the normalized header in the cache key

  • Includes the normalized header in the request to the origin, if a request is necessary

For more information, see Compression support in the Amazon CloudFront Developer Guide.

If you set this value to true, and this cache behavior also has an origin request policy attached, do not include the Accept-Encoding header in the origin request policy. CloudFront always includes the Accept-Encoding header in origin requests when the value of this field is true, so including this header in an origin request policy has no effect.

If both of these fields are false, then CloudFront treats the Accept-Encoding header the same as any other HTTP header in the viewer request. By default, it's not included in the cache key and it's not included in origin requests. In this case, you can manually add Accept-Encoding to the headers whitelist like any other HTTP header.

EnableAcceptEncodingGzip
Required: Yes
Type: boolean

A flag that can affect whether the Accept-Encoding HTTP header is included in the cache key and included in requests that CloudFront sends to the origin.

This field is related to the EnableAcceptEncodingBrotli field. If one or both of these fields is true and the viewer request includes the Accept-Encoding header, then CloudFront does the following:

  • Normalizes the value of the viewer's Accept-Encoding header

  • Includes the normalized header in the cache key

  • Includes the normalized header in the request to the origin, if a request is necessary

For more information, see Compression support in the Amazon CloudFront Developer Guide.

If you set this value to true, and this cache behavior also has an origin request policy attached, do not include the Accept-Encoding header in the origin request policy. CloudFront always includes the Accept-Encoding header in origin requests when the value of this field is true, so including this header in an origin request policy has no effect.

If both of these fields are false, then CloudFront treats the Accept-Encoding header the same as any other HTTP header in the viewer request. By default, it's not included in the cache key and it's not included in origin requests. In this case, you can manually add Accept-Encoding to the headers whitelist like any other HTTP header.

HeadersConfig
Required: Yes
Type: CachePolicyHeadersConfig structure

An object that determines whether any HTTP headers (and if so, which headers) are included in the cache key and in requests that CloudFront sends to the origin.

QueryStringsConfig
Required: Yes
Type: CachePolicyQueryStringsConfig structure

An object that determines whether any URL query strings in viewer requests (and if so, which query strings) are included in the cache key and in requests that CloudFront sends to the origin.

Paths

Description

A complex type that contains information about the objects that you want to invalidate. For more information, see Specifying the Objects to Invalidate in the Amazon CloudFront Developer Guide.

Members
Items
Type: Array of strings

A complex type that contains a list of the paths that you want to invalidate.

Quantity
Required: Yes
Type: int

The number of invalidation paths specified for the objects that you want to invalidate.

PreconditionFailed

Description

The precondition in one or more of the request fields evaluated to false.

Members
Message
Type: string

PublicKey

Description

A public key that you can use with signed URLs and signed cookies, or with field-level encryption.

Members
CreatedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the public key was uploaded.

Id
Required: Yes
Type: string

The identifier of the public key.

PublicKeyConfig
Required: Yes
Type: PublicKeyConfig structure

Configuration information about a public key that you can use with signed URLs and signed cookies, or with field-level encryption.

PublicKeyAlreadyExists

Description

The specified public key already exists.

Members
Message
Type: string

PublicKeyConfig

Description

Configuration information about a public key that you can use with signed URLs and signed cookies, or with field-level encryption.

Members
CallerReference
Required: Yes
Type: string

A string included in the request to help make sure that the request can't be replayed.

Comment
Type: string

A comment to describe the public key. The comment cannot be longer than 128 characters.

EncodedKey
Required: Yes
Type: string

The public key that you can use with signed URLs and signed cookies, or with field-level encryption.

Name
Required: Yes
Type: string

A name to help identify the public key.

PublicKeyInUse

Description

The specified public key is in use.

Members
Message
Type: string

PublicKeyList

Description

A list of public keys that you can use with signed URLs and signed cookies, or with field-level encryption.

Members
Items
Type: Array of PublicKeySummary structures

A list of public keys.

MaxItems
Required: Yes
Type: int

The maximum number of public keys you want in the response.

NextMarker
Type: string

If there are more elements to be listed, this element is present and contains the value that you can use for the Marker request parameter to continue listing your public keys where you left off.

Quantity
Required: Yes
Type: int

The number of public keys in the list.

PublicKeySummary

Description

Contains information about a public key.

Members
Comment
Type: string

A comment to describe the public key. The comment cannot be longer than 128 characters.

CreatedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the public key was uploaded.

EncodedKey
Required: Yes
Type: string

The public key.

Id
Required: Yes
Type: string

The identifier of the public key.

Name
Required: Yes
Type: string

A name to help identify the public key.

QueryArgProfile

Description

Query argument-profile mapping for field-level encryption.

Members
ProfileId
Required: Yes
Type: string

ID of profile to use for field-level encryption query argument-profile mapping

QueryArg
Required: Yes
Type: string

Query argument for field-level encryption query argument-profile mapping.

QueryArgProfileConfig

Description

Configuration for query argument-profile mapping for field-level encryption.

Members
ForwardWhenQueryArgProfileIsUnknown
Required: Yes
Type: boolean

Flag to set if you want a request to be forwarded to the origin even if the profile specified by the field-level encryption query argument, fle-profile, is unknown.

QueryArgProfiles
Type: QueryArgProfiles structure

Profiles specified for query argument-profile mapping for field-level encryption.

QueryArgProfileEmpty

Description

No profile specified for the field-level encryption query argument.

Members
Message
Type: string

QueryArgProfiles

Description

Query argument-profile mapping for field-level encryption.

Members
Items
Type: Array of QueryArgProfile structures

Number of items for query argument-profile mapping for field-level encryption.

Quantity
Required: Yes
Type: int

Number of profiles for query argument-profile mapping for field-level encryption.

QueryStringCacheKeys

Description

This field is deprecated. We recommend that you use a cache policy or an origin request policy instead of this field.

If you want to include query strings in the cache key, use QueryStringsConfig in a cache policy. See CachePolicy.

If you want to send query strings to the origin but not include them in the cache key, use QueryStringsConfig in an origin request policy. See OriginRequestPolicy.

A complex type that contains information about the query string parameters that you want CloudFront to use for caching for a cache behavior.

Members
Items
Type: Array of strings

A list that contains the query string parameters that you want CloudFront to use as a basis for caching for a cache behavior. If Quantity is 0, you can omit Items.

Quantity
Required: Yes
Type: int

The number of whitelisted query string parameters for a cache behavior.

QueryStringNames

Description

Contains a list of query string names.

Members
Items
Type: Array of strings

A list of query string names.

Quantity
Required: Yes
Type: int

The number of query string names in the Items list.

RealtimeLogConfig

Description

A real-time log configuration.

Members
ARN
Required: Yes
Type: string

The Amazon Resource Name (ARN) of this real-time log configuration.

EndPoints
Required: Yes
Type: Array of EndPoint structures

Contains information about the Amazon Kinesis data stream where you are sending real-time log data for this real-time log configuration.

Fields
Required: Yes
Type: Array of strings

A list of fields that are included in each real-time log record. In an API response, the fields are provided in the same order in which they are sent to the Amazon Kinesis data stream.

For more information about fields, see Real-time log configuration fields in the Amazon CloudFront Developer Guide.

Name
Required: Yes
Type: string

The unique name of this real-time log configuration.

SamplingRate
Required: Yes
Type: long (int|float)

The sampling rate for this real-time log configuration. The sampling rate determines the percentage of viewer requests that are represented in the real-time log data. The sampling rate is an integer between 1 and 100, inclusive.

RealtimeLogConfigAlreadyExists

Description

A real-time log configuration with this name already exists. You must provide a unique name. To modify an existing real-time log configuration, use UpdateRealtimeLogConfig.

Members
Message
Type: string

RealtimeLogConfigInUse

Description

Cannot delete the real-time log configuration because it is attached to one or more cache behaviors.

Members
Message
Type: string

RealtimeLogConfigOwnerMismatch

Description

The specified real-time log configuration belongs to a different Amazon Web Services account.

Members
Message
Type: string

RealtimeLogConfigs

Description

A list of real-time log configurations.

Members
IsTruncated
Required: Yes
Type: boolean

A flag that indicates whether there are more real-time log configurations than are contained in this list.

Items
Type: Array of RealtimeLogConfig structures

Contains the list of real-time log configurations.

Marker
Required: Yes
Type: string

This parameter indicates where this list of real-time log configurations begins. This list includes real-time log configurations that occur after the marker.

MaxItems
Required: Yes
Type: int

The maximum number of real-time log configurations requested.

NextMarker
Type: string

If there are more items in the list than are in this response, this element is present. It contains the value that you should use in the Marker field of a subsequent request to continue listing real-time log configurations where you left off.

RealtimeMetricsSubscriptionConfig

Description

A subscription configuration for additional CloudWatch metrics.

Members
RealtimeMetricsSubscriptionStatus
Required: Yes
Type: string

A flag that indicates whether additional CloudWatch metrics are enabled for a given CloudFront distribution.

ResourceInUse

Description

Cannot delete this resource because it is in use.

Members
Message
Type: string

ResponseHeadersPolicy

Description

A response headers policy.

A response headers policy contains information about a set of HTTP response headers.

After you create a response headers policy, you can use its ID to attach it to one or more cache behaviors in a CloudFront distribution. When it's attached to a cache behavior, the response headers policy affects the HTTP headers that CloudFront includes in HTTP responses to requests that match the cache behavior. CloudFront adds or removes response headers according to the configuration of the response headers policy.

For more information, see Adding or removing HTTP headers in CloudFront responses in the Amazon CloudFront Developer Guide.

Members
Id
Required: Yes
Type: string

The identifier for the response headers policy.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time when the response headers policy was last modified.

ResponseHeadersPolicyConfig
Required: Yes
Type: ResponseHeadersPolicyConfig structure

A response headers policy configuration.

ResponseHeadersPolicyAccessControlAllowHeaders

Description

A list of HTTP header names that CloudFront includes as values for the Access-Control-Allow-Headers HTTP response header.

For more information about the Access-Control-Allow-Headers HTTP response header, see Access-Control-Allow-Headers in the MDN Web Docs.

Members
Items
Required: Yes
Type: Array of strings

The list of HTTP header names. You can specify * to allow all headers.

Quantity
Required: Yes
Type: int

The number of HTTP header names in the list.

ResponseHeadersPolicyAccessControlAllowMethods

Description

A list of HTTP methods that CloudFront includes as values for the Access-Control-Allow-Methods HTTP response header.

For more information about the Access-Control-Allow-Methods HTTP response header, see Access-Control-Allow-Methods in the MDN Web Docs.

Members
Items
Required: Yes
Type: Array of strings

The list of HTTP methods. Valid values are:

  • GET

  • DELETE

  • HEAD

  • OPTIONS

  • PATCH

  • POST

  • PUT

  • ALL

ALL is a special value that includes all of the listed HTTP methods.

Quantity
Required: Yes
Type: int

The number of HTTP methods in the list.

ResponseHeadersPolicyAccessControlAllowOrigins

Description

A list of origins (domain names) that CloudFront can use as the value for the Access-Control-Allow-Origin HTTP response header.

For more information about the Access-Control-Allow-Origin HTTP response header, see Access-Control-Allow-Origin in the MDN Web Docs.

Members
Items
Required: Yes
Type: Array of strings

The list of origins (domain names). You can specify * to allow all origins.

Quantity
Required: Yes
Type: int

The number of origins in the list.

ResponseHeadersPolicyAccessControlExposeHeaders

Description

A list of HTTP headers that CloudFront includes as values for the Access-Control-Expose-Headers HTTP response header.

For more information about the Access-Control-Expose-Headers HTTP response header, see Access-Control-Expose-Headers in the MDN Web Docs.

Members
Items
Type: Array of strings

The list of HTTP headers. You can specify * to expose all headers.

Quantity
Required: Yes
Type: int

The number of HTTP headers in the list.

ResponseHeadersPolicyAlreadyExists

Description

A response headers policy with this name already exists. You must provide a unique name. To modify an existing response headers policy, use UpdateResponseHeadersPolicy.

Members
Message
Type: string

ResponseHeadersPolicyConfig

Description

A response headers policy configuration.

A response headers policy configuration contains metadata about the response headers policy, and configurations for sets of HTTP response headers.

Members
Comment
Type: string

A comment to describe the response headers policy.

The comment cannot be longer than 128 characters.

CorsConfig

A configuration for a set of HTTP response headers that are used for cross-origin resource sharing (CORS).

CustomHeadersConfig

A configuration for a set of custom HTTP response headers.

Name
Required: Yes
Type: string

A name to identify the response headers policy.

The name must be unique for response headers policies in this Amazon Web Services account.

RemoveHeadersConfig

A configuration for a set of HTTP headers to remove from the HTTP response.

SecurityHeadersConfig

A configuration for a set of security-related HTTP response headers.

ServerTimingHeadersConfig

A configuration for enabling the Server-Timing header in HTTP responses sent from CloudFront.

ResponseHeadersPolicyContentSecurityPolicy

Description

The policy directives and their values that CloudFront includes as values for the Content-Security-Policy HTTP response header.

For more information about the Content-Security-Policy HTTP response header, see Content-Security-Policy in the MDN Web Docs.

Members
ContentSecurityPolicy
Required: Yes
Type: string

The policy directives and their values that CloudFront includes as values for the Content-Security-Policy HTTP response header.

Override
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront overrides the Content-Security-Policy HTTP response header received from the origin with the one specified in this response headers policy.

ResponseHeadersPolicyContentTypeOptions

Description

Determines whether CloudFront includes the X-Content-Type-Options HTTP response header with its value set to nosniff.

For more information about the X-Content-Type-Options HTTP response header, see X-Content-Type-Options in the MDN Web Docs.

Members
Override
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront overrides the X-Content-Type-Options HTTP response header received from the origin with the one specified in this response headers policy.

ResponseHeadersPolicyCorsConfig

Description

A configuration for a set of HTTP response headers that are used for cross-origin resource sharing (CORS). CloudFront adds these headers to HTTP responses that it sends for CORS requests that match a cache behavior associated with this response headers policy.

For more information about CORS, see Cross-Origin Resource Sharing (CORS) in the MDN Web Docs.

Members
AccessControlAllowCredentials
Required: Yes
Type: boolean

A Boolean that CloudFront uses as the value for the Access-Control-Allow-Credentials HTTP response header.

For more information about the Access-Control-Allow-Credentials HTTP response header, see Access-Control-Allow-Credentials in the MDN Web Docs.

AccessControlAllowHeaders
Required: Yes
Type: ResponseHeadersPolicyAccessControlAllowHeaders structure

A list of HTTP header names that CloudFront includes as values for the Access-Control-Allow-Headers HTTP response header.

For more information about the Access-Control-Allow-Headers HTTP response header, see Access-Control-Allow-Headers in the MDN Web Docs.

AccessControlAllowMethods
Required: Yes
Type: ResponseHeadersPolicyAccessControlAllowMethods structure

A list of HTTP methods that CloudFront includes as values for the Access-Control-Allow-Methods HTTP response header.

For more information about the Access-Control-Allow-Methods HTTP response header, see Access-Control-Allow-Methods in the MDN Web Docs.

AccessControlAllowOrigins
Required: Yes
Type: ResponseHeadersPolicyAccessControlAllowOrigins structure

A list of origins (domain names) that CloudFront can use as the value for the Access-Control-Allow-Origin HTTP response header.

For more information about the Access-Control-Allow-Origin HTTP response header, see Access-Control-Allow-Origin in the MDN Web Docs.

AccessControlExposeHeaders

A list of HTTP headers that CloudFront includes as values for the Access-Control-Expose-Headers HTTP response header.

For more information about the Access-Control-Expose-Headers HTTP response header, see Access-Control-Expose-Headers in the MDN Web Docs.

AccessControlMaxAgeSec
Type: int

A number that CloudFront uses as the value for the Access-Control-Max-Age HTTP response header.

For more information about the Access-Control-Max-Age HTTP response header, see Access-Control-Max-Age in the MDN Web Docs.

OriginOverride
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront overrides HTTP response headers received from the origin with the ones specified in this response headers policy.

ResponseHeadersPolicyCustomHeader

Description

An HTTP response header name and its value. CloudFront includes this header in HTTP responses that it sends for requests that match a cache behavior that's associated with this response headers policy.

Members
Header
Required: Yes
Type: string

The HTTP response header name.

Override
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront overrides a response header with the same name received from the origin with the header specified here.

Value
Required: Yes
Type: string

The value for the HTTP response header.

ResponseHeadersPolicyCustomHeadersConfig

Description

A list of HTTP response header names and their values. CloudFront includes these headers in HTTP responses that it sends for requests that match a cache behavior that's associated with this response headers policy.

Members
Items
Type: Array of ResponseHeadersPolicyCustomHeader structures

The list of HTTP response headers and their values.

Quantity
Required: Yes
Type: int

The number of HTTP response headers in the list.

ResponseHeadersPolicyFrameOptions

Description

Determines whether CloudFront includes the X-Frame-Options HTTP response header and the header's value.

For more information about the X-Frame-Options HTTP response header, see X-Frame-Options in the MDN Web Docs.

Members
FrameOption
Required: Yes
Type: string

The value of the X-Frame-Options HTTP response header. Valid values are DENY and SAMEORIGIN.

For more information about these values, see X-Frame-Options in the MDN Web Docs.

Override
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront overrides the X-Frame-Options HTTP response header received from the origin with the one specified in this response headers policy.

ResponseHeadersPolicyInUse

Description

Cannot delete the response headers policy because it is attached to one or more cache behaviors in a CloudFront distribution.

Members
Message
Type: string

ResponseHeadersPolicyList

Description

A list of response headers policies.

Members
Items
Type: Array of ResponseHeadersPolicySummary structures

The response headers policies in the list.

MaxItems
Required: Yes
Type: int

The maximum number of response headers policies requested.

NextMarker
Type: string

If there are more items in the list than are in this response, this element is present. It contains the value that you should use in the Marker field of a subsequent request to continue listing response headers policies where you left off.

Quantity
Required: Yes
Type: int

The number of response headers policies returned.

ResponseHeadersPolicyReferrerPolicy

Description

Determines whether CloudFront includes the Referrer-Policy HTTP response header and the header's value.

For more information about the Referrer-Policy HTTP response header, see Referrer-Policy in the MDN Web Docs.

Members
Override
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront overrides the Referrer-Policy HTTP response header received from the origin with the one specified in this response headers policy.

ReferrerPolicy
Required: Yes
Type: string

The value of the Referrer-Policy HTTP response header. Valid values are:

  • no-referrer

  • no-referrer-when-downgrade

  • origin

  • origin-when-cross-origin

  • same-origin

  • strict-origin

  • strict-origin-when-cross-origin

  • unsafe-url

For more information about these values, see Referrer-Policy in the MDN Web Docs.

ResponseHeadersPolicyRemoveHeader

Description

The name of an HTTP header that CloudFront removes from HTTP responses to requests that match the cache behavior that this response headers policy is attached to.

Members
Header
Required: Yes
Type: string

The HTTP header name.

ResponseHeadersPolicyRemoveHeadersConfig

Description

A list of HTTP header names that CloudFront removes from HTTP responses to requests that match the cache behavior that this response headers policy is attached to.

Members
Items
Type: Array of ResponseHeadersPolicyRemoveHeader structures

The list of HTTP header names.

Quantity
Required: Yes
Type: int

The number of HTTP header names in the list.

ResponseHeadersPolicySecurityHeadersConfig

Description

A configuration for a set of security-related HTTP response headers. CloudFront adds these headers to HTTP responses that it sends for requests that match a cache behavior associated with this response headers policy.

Members
ContentSecurityPolicy

The policy directives and their values that CloudFront includes as values for the Content-Security-Policy HTTP response header.

For more information about the Content-Security-Policy HTTP response header, see Content-Security-Policy in the MDN Web Docs.

ContentTypeOptions

Determines whether CloudFront includes the X-Content-Type-Options HTTP response header with its value set to nosniff.

For more information about the X-Content-Type-Options HTTP response header, see X-Content-Type-Options in the MDN Web Docs.

FrameOptions

Determines whether CloudFront includes the X-Frame-Options HTTP response header and the header's value.

For more information about the X-Frame-Options HTTP response header, see X-Frame-Options in the MDN Web Docs.

ReferrerPolicy

Determines whether CloudFront includes the Referrer-Policy HTTP response header and the header's value.

For more information about the Referrer-Policy HTTP response header, see Referrer-Policy in the MDN Web Docs.

StrictTransportSecurity

Determines whether CloudFront includes the Strict-Transport-Security HTTP response header and the header's value.

For more information about the Strict-Transport-Security HTTP response header, see Security headers in the Amazon CloudFront Developer Guide and Strict-Transport-Security in the MDN Web Docs.

XSSProtection

Determines whether CloudFront includes the X-XSS-Protection HTTP response header and the header's value.

For more information about the X-XSS-Protection HTTP response header, see X-XSS-Protection in the MDN Web Docs.

ResponseHeadersPolicyServerTimingHeadersConfig

Description

A configuration for enabling the Server-Timing header in HTTP responses sent from CloudFront. CloudFront adds this header to HTTP responses that it sends in response to requests that match a cache behavior that's associated with this response headers policy.

You can use the Server-Timing header to view metrics that can help you gain insights about the behavior and performance of CloudFront. For example, you can see which cache layer served a cache hit, or the first byte latency from the origin when there was a cache miss. You can use the metrics in the Server-Timing header to troubleshoot issues or test the efficiency of your CloudFront configuration. For more information, see Server-Timing header in the Amazon CloudFront Developer Guide.

Members
Enabled
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront adds the Server-Timing header to HTTP responses that it sends in response to requests that match a cache behavior that's associated with this response headers policy.

SamplingRate
Type: double

A number 0–100 (inclusive) that specifies the percentage of responses that you want CloudFront to add the Server-Timing header to. When you set the sampling rate to 100, CloudFront adds the Server-Timing header to the HTTP response for every request that matches the cache behavior that this response headers policy is attached to. When you set it to 50, CloudFront adds the header to 50% of the responses for requests that match the cache behavior. You can set the sampling rate to any number 0–100 with up to four decimal places.

ResponseHeadersPolicyStrictTransportSecurity

Description

Determines whether CloudFront includes the Strict-Transport-Security HTTP response header and the header's value.

For more information about the Strict-Transport-Security HTTP response header, see Strict-Transport-Security in the MDN Web Docs.

Members
AccessControlMaxAgeSec
Required: Yes
Type: int

A number that CloudFront uses as the value for the max-age directive in the Strict-Transport-Security HTTP response header.

IncludeSubdomains
Type: boolean

A Boolean that determines whether CloudFront includes the includeSubDomains directive in the Strict-Transport-Security HTTP response header.

Override
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront overrides the Strict-Transport-Security HTTP response header received from the origin with the one specified in this response headers policy.

Preload
Type: boolean

A Boolean that determines whether CloudFront includes the preload directive in the Strict-Transport-Security HTTP response header.

ResponseHeadersPolicySummary

Description

Contains a response headers policy.

Members
ResponseHeadersPolicy
Required: Yes
Type: ResponseHeadersPolicy structure

The response headers policy.

Type
Required: Yes
Type: string

The type of response headers policy, either managed (created by Amazon Web Services) or custom (created in this Amazon Web Services account).

ResponseHeadersPolicyXSSProtection

Description

Determines whether CloudFront includes the X-XSS-Protection HTTP response header and the header's value.

For more information about the X-XSS-Protection HTTP response header, see X-XSS-Protection in the MDN Web Docs.

Members
ModeBlock
Type: boolean

A Boolean that determines whether CloudFront includes the mode=block directive in the X-XSS-Protection header.

For more information about this directive, see X-XSS-Protection in the MDN Web Docs.

Override
Required: Yes
Type: boolean

A Boolean that determines whether CloudFront overrides the X-XSS-Protection HTTP response header received from the origin with the one specified in this response headers policy.

Protection
Required: Yes
Type: boolean

A Boolean that determines the value of the X-XSS-Protection HTTP response header. When this setting is true, the value of the X-XSS-Protection header is 1. When this setting is false, the value of the X-XSS-Protection header is 0.

For more information about these settings, see X-XSS-Protection in the MDN Web Docs.

ReportUri
Type: string

A reporting URI, which CloudFront uses as the value of the report directive in the X-XSS-Protection header.

You cannot specify a ReportUri when ModeBlock is true.

For more information about using a reporting URL, see X-XSS-Protection in the MDN Web Docs.

Restrictions

Description

A complex type that identifies ways in which you want to restrict distribution of your content.

Members
GeoRestriction
Required: Yes
Type: GeoRestriction structure

A complex type that controls the countries in which your content is distributed. CloudFront determines the location of your users using MaxMind GeoIP databases.

S3Origin

Description

A complex type that contains information about the Amazon S3 bucket from which you want CloudFront to get your media files for distribution.

Members
DomainName
Required: Yes
Type: string

The DNS name of the Amazon S3 origin.

OriginAccessIdentity
Required: Yes
Type: string

The CloudFront origin access identity to associate with the distribution. Use an origin access identity to configure the distribution so that end users can only access objects in an Amazon S3 bucket through CloudFront.

If you want end users to be able to access objects using either the CloudFront URL or the Amazon S3 URL, specify an empty OriginAccessIdentity element.

To delete the origin access identity from an existing distribution, update the distribution configuration and include an empty OriginAccessIdentity element.

To replace the origin access identity, update the distribution configuration and specify the new origin access identity.

For more information, see Using an Origin Access Identity to Restrict Access to Your Amazon S3 Content in the Amazon CloudFront Developer Guide.

S3OriginConfig

Description

A complex type that contains information about the Amazon S3 origin. If the origin is a custom origin or an S3 bucket that is configured as a website endpoint, use the CustomOriginConfig element instead.

Members
OriginAccessIdentity
Required: Yes
Type: string

If you're using origin access control (OAC) instead of origin access identity, specify an empty OriginAccessIdentity element. For more information, see Restricting access to an Amazon Web Services in the Amazon CloudFront Developer Guide.

The CloudFront origin access identity to associate with the origin. Use an origin access identity to configure the origin so that viewers can only access objects in an Amazon S3 bucket through CloudFront. The format of the value is:

origin-access-identity/cloudfront/ID-of-origin-access-identity

The ID-of-origin-access-identity is the value that CloudFront returned in the ID element when you created the origin access identity.

If you want viewers to be able to access objects using either the CloudFront URL or the Amazon S3 URL, specify an empty OriginAccessIdentity element.

To delete the origin access identity from an existing distribution, update the distribution configuration and include an empty OriginAccessIdentity element.

To replace the origin access identity, update the distribution configuration and specify the new origin access identity.

For more information about the origin access identity, see Serving Private Content through CloudFront in the Amazon CloudFront Developer Guide.

SessionStickinessConfig

Description

Session stickiness provides the ability to define multiple requests from a single viewer as a single session. This prevents the potentially inconsistent experience of sending some of a given user's requests to your staging distribution, while others are sent to your primary distribution. Define the session duration using TTL values.

Members
IdleTTL
Required: Yes
Type: int

The amount of time after which you want sessions to cease if no requests are received. Allowed values are 300–3600 seconds (5–60 minutes).

The value must be less than or equal to MaximumTTL.

MaximumTTL
Required: Yes
Type: int

The maximum amount of time to consider requests from the viewer as being part of the same session. Allowed values are 300–3600 seconds (5–60 minutes).

The value must be greater than or equal to IdleTTL.

Signer

Description

A list of Amazon Web Services accounts and the active CloudFront key pairs in each account that CloudFront can use to verify the signatures of signed URLs and signed cookies.

Members
AwsAccountNumber
Type: string

An Amazon Web Services account number that contains active CloudFront key pairs that CloudFront can use to verify the signatures of signed URLs and signed cookies. If the Amazon Web Services account that owns the key pairs is the same account that owns the CloudFront distribution, the value of this field is self.

KeyPairIds
Type: KeyPairIds structure

A list of CloudFront key pair identifiers.

StagingDistributionDnsNames

Description

The CloudFront domain name of the staging distribution.

Members
Items
Type: Array of strings

The CloudFront domain name of the staging distribution.

Quantity
Required: Yes
Type: int

The number of CloudFront domain names in your staging distribution.

StagingDistributionInUse

Description

A continuous deployment policy for this staging distribution already exists.

Members
Message
Type: string

StatusCodes

Description

A complex data type for the status codes that you specify that, when returned by a primary origin, trigger CloudFront to failover to a second origin.

Members
Items
Required: Yes
Type: Array of ints

The items (status codes) for an origin group.

Quantity
Required: Yes
Type: int

The number of status codes.

StreamingDistribution

Description

A streaming distribution tells CloudFront where you want RTMP content to be delivered from, and the details about how to track and manage content delivery.

Members
ARN
Required: Yes
Type: string

The ARN (Amazon Resource Name) for the distribution. For example: arn:aws:cloudfront::123456789012:distribution/EDFDVBD632BHDS5, where 123456789012 is your Amazon Web Services account ID.

ActiveTrustedSigners
Required: Yes
Type: ActiveTrustedSigners structure

A complex type that lists the Amazon Web Services accounts, if any, that you included in the TrustedSigners complex type for this distribution. These are the accounts that you want to allow to create signed URLs for private content.

The Signer complex type lists the Amazon Web Services account number of the trusted signer or self if the signer is the Amazon Web Services account that created the distribution. The Signer element also includes the IDs of any active CloudFront key pairs that are associated with the trusted signer's Amazon Web Services account. If no KeyPairId element appears for a Signer, that signer can't create signed URLs.

For more information, see Serving Private Content through CloudFront in the Amazon CloudFront Developer Guide.

DomainName
Required: Yes
Type: string

The domain name that corresponds to the streaming distribution, for example, s5c39gqb8ow64r.cloudfront.net.

Id
Required: Yes
Type: string

The identifier for the RTMP distribution. For example: EGTXBD79EXAMPLE.

LastModifiedTime
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time that the distribution was last modified.

Status
Required: Yes
Type: string

The current status of the RTMP distribution. When the status is Deployed, the distribution's information is propagated to all CloudFront edge locations.

StreamingDistributionConfig
Required: Yes
Type: StreamingDistributionConfig structure

The current configuration information for the RTMP distribution.

StreamingDistributionAlreadyExists

Description

The caller reference you attempted to create the streaming distribution with is associated with another distribution

Members
Message
Type: string

StreamingDistributionConfig

Description

The RTMP distribution's configuration information.

Members
Aliases
Type: Aliases structure

A complex type that contains information about CNAMEs (alternate domain names), if any, for this streaming distribution.

CallerReference
Required: Yes
Type: string

A unique value (for example, a date-time stamp) that ensures that the request can't be replayed.

If the value of CallerReference is new (regardless of the content of the StreamingDistributionConfig object), CloudFront creates a new distribution.

If CallerReference is a value that you already sent in a previous request to create a distribution, CloudFront returns a DistributionAlreadyExists error.

Comment
Required: Yes
Type: string

Any comments you want to include about the streaming distribution.

Enabled
Required: Yes
Type: boolean

Whether the streaming distribution is enabled to accept user requests for content.

Logging
Type: StreamingLoggingConfig structure

A complex type that controls whether access logs are written for the streaming distribution.

PriceClass
Type: string

A complex type that contains information about price class for this streaming distribution.

S3Origin
Required: Yes
Type: S3Origin structure

A complex type that contains information about the Amazon S3 bucket from which you want CloudFront to get your media files for distribution.

TrustedSigners
Required: Yes
Type: TrustedSigners structure

A complex type that specifies any Amazon Web Services accounts that you want to permit to create signed URLs for private content. If you want the distribution to use signed URLs, include this element; if you want the distribution to use public URLs, remove this element. For more information, see Serving Private Content through CloudFront in the Amazon CloudFront Developer Guide.

StreamingDistributionConfigWithTags

Description

A streaming distribution Configuration and a list of tags to be associated with the streaming distribution.

Members
StreamingDistributionConfig
Required: Yes
Type: StreamingDistributionConfig structure

A streaming distribution Configuration.

Tags
Required: Yes
Type: Tags structure

A complex type that contains zero or more Tag elements.

StreamingDistributionList

Description

A streaming distribution list.

Members
IsTruncated
Required: Yes
Type: boolean

A flag that indicates whether more streaming distributions remain to be listed. If your results were truncated, you can make a follow-up pagination request using the Marker request parameter to retrieve more distributions in the list.

Items
Type: Array of StreamingDistributionSummary structures

A complex type that contains one StreamingDistributionSummary element for each distribution that was created by the current Amazon Web Services account.

Marker
Required: Yes
Type: string

The value you provided for the Marker request parameter.

MaxItems
Required: Yes
Type: int

The value you provided for the MaxItems request parameter.

NextMarker
Type: string

If IsTruncated is true, this element is present and contains the value you can use for the Marker request parameter to continue listing your RTMP distributions where they left off.

Quantity
Required: Yes
Type: int

The number of streaming distributions that were created by the current Amazon Web Services account.

StreamingDistributionNotDisabled

Description

The specified CloudFront distribution is not disabled. You must disable the distribution before you can delete it.

Members
Message
Type: string

StreamingDistributionSummary

Description

A summary of the information for a CloudFront streaming distribution.

Members
ARN
Required: Yes
Type: string

The ARN (Amazon Resource Name) for the streaming distribution. For example: arn:aws:cloudfront::123456789012:streaming-distribution/EDFDVBD632BHDS5, where 123456789012 is your Amazon Web Services account ID.

Aliases
Required: Yes
Type: Aliases structure

A complex type that contains information about CNAMEs (alternate domain names), if any, for this streaming distribution.

Comment
Required: Yes
Type: string

The comment originally specified when this distribution was created.

DomainName
Required: Yes
Type: string

The domain name corresponding to the distribution, for example, d111111abcdef8.cloudfront.net.

Enabled
Required: Yes
Type: boolean

Whether the distribution is enabled to accept end user requests for content.

Id
Required: Yes
Type: string

The identifier for the distribution, for example, EDFDVBD632BHDS5.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The date and time the distribution was last modified.

PriceClass
Required: Yes
Type: string

A complex type that contains information about price class for this streaming distribution.

S3Origin
Required: Yes
Type: S3Origin structure

A complex type that contains information about the Amazon S3 bucket from which you want CloudFront to get your media files for distribution.

Status
Required: Yes
Type: string

Indicates the current status of the distribution. When the status is Deployed, the distribution's information is fully propagated throughout the Amazon CloudFront system.

TrustedSigners
Required: Yes
Type: TrustedSigners structure

A complex type that specifies the Amazon Web Services accounts, if any, that you want to allow to create signed URLs for private content. If you want to require signed URLs in requests for objects in the target origin that match the PathPattern for this cache behavior, specify true for Enabled, and specify the applicable values for Quantity and Items.If you don't want to require signed URLs in requests for objects that match PathPattern, specify false for Enabled and 0 for Quantity. Omit Items. To add, change, or remove one or more trusted signers, change Enabled to true (if it's currently false), change Quantity as applicable, and specify all of the trusted signers that you want to include in the updated distribution.

For more information, see Serving Private Content through CloudFront in the Amazon CloudFront Developer Guide.

StreamingLoggingConfig

Description

A complex type that controls whether access logs are written for this streaming distribution.

Members
Bucket
Required: Yes
Type: string

The Amazon S3 bucket to store the access logs in, for example, amzn-s3-demo-bucket.s3.amazonaws.com.

Enabled
Required: Yes
Type: boolean

Specifies whether you want CloudFront to save access logs to an Amazon S3 bucket. If you don't want to enable logging when you create a streaming distribution or if you want to disable logging for an existing streaming distribution, specify false for Enabled, and specify empty Bucket and Prefix elements. If you specify false for Enabled but you specify values for Bucket and Prefix, the values are automatically deleted.

Prefix
Required: Yes
Type: string

An optional string that you want CloudFront to prefix to the access log filenames for this streaming distribution, for example, myprefix/. If you want to enable logging, but you don't want to specify a prefix, you still must include an empty Prefix element in the Logging element.

Tag

Description

A complex type that contains Tag key and Tag value.

Members
Key
Required: Yes
Type: string

A string that contains Tag key.

The string length should be between 1 and 128 characters. Valid characters include a-z, A-Z, 0-9, space, and the special characters _ - . : / = + @.

Value
Type: string

A string that contains an optional Tag value.

The string length should be between 0 and 256 characters. Valid characters include a-z, A-Z, 0-9, space, and the special characters _ - . : / = + @.

TagKeys

Description

A complex type that contains zero or more Tag elements.

Members
Items
Type: Array of strings

A complex type that contains Tag key elements.

Tags

Description

A complex type that contains zero or more Tag elements.

Members
Items
Type: Array of Tag structures

A complex type that contains Tag elements.

TestFunctionFailed

Description

The CloudFront function failed.

Members
Message
Type: string

TestFunctionRequest

Members
EventObject
Required: Yes
Type: blob (string|resource|Psr\Http\Message\StreamInterface)

The event object to test the function with. For more information about the structure of the event object, see Testing functions in the Amazon CloudFront Developer Guide.

IfMatch
Required: Yes
Type: string

The current version (ETag value) of the function that you are testing, which you can get using DescribeFunction.

Name
Required: Yes
Type: string

The name of the function that you are testing.

Stage
Type: string

The stage of the function that you are testing, either DEVELOPMENT or LIVE.

TestResult

Description

Contains the result of testing a CloudFront function with TestFunction.

Members
ComputeUtilization
Type: string

The amount of time that the function took to run as a percentage of the maximum allowed time. For example, a compute utilization of 35 means that the function completed in 35% of the maximum allowed time.

FunctionErrorMessage
Type: string

If the result of testing the function was an error, this field contains the error message.

FunctionExecutionLogs
Type: Array of strings

Contains the log lines that the function wrote (if any) when running the test.

FunctionOutput
Type: string

The event object returned by the function. For more information about the structure of the event object, see Event object structure in the Amazon CloudFront Developer Guide.

FunctionSummary
Type: FunctionSummary structure

Contains configuration information and metadata about the CloudFront function that was tested.

TooLongCSPInResponseHeadersPolicy

Description

The length of the Content-Security-Policy header value in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyCacheBehaviors

Description

You cannot create more cache behaviors for the distribution.

Members
Message
Type: string

TooManyCachePolicies

Description

You have reached the maximum number of cache policies for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyCertificates

Description

You cannot create anymore custom SSL/TLS certificates.

Members
Message
Type: string

TooManyCloudFrontOriginAccessIdentities

Description

Processing your request would cause you to exceed the maximum number of origin access identities allowed.

Members
Message
Type: string

TooManyContinuousDeploymentPolicies

Description

You have reached the maximum number of continuous deployment policies for this Amazon Web Services account.

Members
Message
Type: string

TooManyCookieNamesInWhiteList

Description

Your request contains more cookie names in the whitelist than are allowed per cache behavior.

Members
Message
Type: string

TooManyCookiesInCachePolicy

Description

The number of cookies in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyCookiesInOriginRequestPolicy

Description

The number of cookies in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyCustomHeadersInResponseHeadersPolicy

Description

The number of custom headers in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyDistributionCNAMEs

Description

Your request contains more CNAMEs than are allowed per distribution.

Members
Message
Type: string

TooManyDistributions

Description

Processing your request would cause you to exceed the maximum number of distributions allowed.

Members
Message
Type: string

TooManyDistributionsAssociatedToCachePolicy

Description

The maximum number of distributions have been associated with the specified cache policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyDistributionsAssociatedToFieldLevelEncryptionConfig

Description

The maximum number of distributions have been associated with the specified configuration for field-level encryption.

Members
Message
Type: string

TooManyDistributionsAssociatedToKeyGroup

Description

The number of distributions that reference this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyDistributionsAssociatedToOriginAccessControl

Description

The maximum number of distributions have been associated with the specified origin access control.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyDistributionsAssociatedToOriginRequestPolicy

Description

The maximum number of distributions have been associated with the specified origin request policy. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyDistributionsAssociatedToResponseHeadersPolicy

Description

The maximum number of distributions have been associated with the specified response headers policy.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyDistributionsWithFunctionAssociations

Description

You have reached the maximum number of distributions that are associated with a CloudFront function. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyDistributionsWithLambdaAssociations

Description

Processing your request would cause the maximum number of distributions with Lambda@Edge function associations per owner to be exceeded.

Members
Message
Type: string

TooManyDistributionsWithSingleFunctionARN

Description

The maximum number of distributions have been associated with the specified Lambda@Edge function.

Members
Message
Type: string

TooManyFieldLevelEncryptionConfigs

Description

The maximum number of configurations for field-level encryption have been created.

Members
Message
Type: string

TooManyFieldLevelEncryptionContentTypeProfiles

Description

The maximum number of content type profiles for field-level encryption have been created.

Members
Message
Type: string

TooManyFieldLevelEncryptionEncryptionEntities

Description

The maximum number of encryption entities for field-level encryption have been created.

Members
Message
Type: string

TooManyFieldLevelEncryptionFieldPatterns

Description

The maximum number of field patterns for field-level encryption have been created.

Members
Message
Type: string

TooManyFieldLevelEncryptionProfiles

Description

The maximum number of profiles for field-level encryption have been created.

Members
Message
Type: string

TooManyFieldLevelEncryptionQueryArgProfiles

Description

The maximum number of query arg profiles for field-level encryption have been created.

Members
Message
Type: string

TooManyFunctionAssociations

Description

You have reached the maximum number of CloudFront function associations for this distribution. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyFunctions

Description

You have reached the maximum number of CloudFront functions for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyHeadersInCachePolicy

Description

The number of headers in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyHeadersInForwardedValues

Description

Your request contains too many headers in forwarded values.

Members
Message
Type: string

TooManyHeadersInOriginRequestPolicy

Description

The number of headers in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyInvalidationsInProgress

Description

You have exceeded the maximum number of allowable InProgress invalidation batch requests, or invalidation objects.

Members
Message
Type: string

TooManyKeyGroups

Description

You have reached the maximum number of key groups for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyKeyGroupsAssociatedToDistribution

Description

The number of key groups referenced by this distribution is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyLambdaFunctionAssociations

Description

Your request contains more Lambda@Edge function associations than are allowed per distribution.

Members
Message
Type: string

TooManyOriginAccessControls

Description

The number of origin access controls in your Amazon Web Services account exceeds the maximum allowed.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyOriginCustomHeaders

Description

Your request contains too many origin custom headers.

Members
Message
Type: string

TooManyOriginGroupsPerDistribution

Description

Processing your request would cause you to exceed the maximum number of origin groups allowed.

Members
Message
Type: string

TooManyOriginRequestPolicies

Description

You have reached the maximum number of origin request policies for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyOrigins

Description

You cannot create more origins for the distribution.

Members
Message
Type: string

TooManyPublicKeys

Description

The maximum number of public keys for field-level encryption have been created. To create a new public key, delete one of the existing keys.

Members
Message
Type: string

TooManyPublicKeysInKeyGroup

Description

The number of public keys in this key group is more than the maximum allowed. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyQueryStringParameters

Description

Your request contains too many query string parameters.

Members
Message
Type: string

TooManyQueryStringsInCachePolicy

Description

The number of query strings in the cache policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyQueryStringsInOriginRequestPolicy

Description

The number of query strings in the origin request policy exceeds the maximum. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyRealtimeLogConfigs

Description

You have reached the maximum number of real-time log configurations for this Amazon Web Services account. For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyRemoveHeadersInResponseHeadersPolicy

Description

The number of headers in RemoveHeadersConfig in the response headers policy exceeds the maximum.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyResponseHeadersPolicies

Description

You have reached the maximum number of response headers policies for this Amazon Web Services account.

For more information, see Quotas (formerly known as limits) in the Amazon CloudFront Developer Guide.

Members
Message
Type: string

TooManyStreamingDistributionCNAMEs

Description

Your request contains more CNAMEs than are allowed per distribution.

Members
Message
Type: string

TooManyStreamingDistributions

Description

Processing your request would cause you to exceed the maximum number of streaming distributions allowed.

Members
Message
Type: string

TooManyTrustedSigners

Description

Your request contains more trusted signers than are allowed per distribution.

Members
Message
Type: string

TrafficConfig

Description

The traffic configuration of your continuous deployment.

Members
SingleHeaderConfig

Determines which HTTP requests are sent to the staging distribution.

SingleWeightConfig

Contains the percentage of traffic to send to the staging distribution.

Type
Required: Yes
Type: string

The type of traffic configuration.

TrustedKeyGroupDoesNotExist

Description

The specified key group does not exist.

Members
Message
Type: string

TrustedKeyGroups

Description

A list of key groups whose public keys CloudFront can use to verify the signatures of signed URLs and signed cookies.

Members
Enabled
Required: Yes
Type: boolean

This field is true if any of the key groups in the list have public keys that CloudFront can use to verify the signatures of signed URLs and signed cookies. If not, this field is false.

Items
Type: Array of strings

A list of key groups identifiers.

Quantity
Required: Yes
Type: int

The number of key groups in the list.

TrustedSignerDoesNotExist

Description

One or more of your trusted signers don't exist.

Members
Message
Type: string

TrustedSigners

Description

A list of Amazon Web Services accounts whose public keys CloudFront can use to verify the signatures of signed URLs and signed cookies.

Members
Enabled
Required: Yes
Type: boolean

This field is true if any of the Amazon Web Services accounts in the list are configured as trusted signers. If not, this field is false.

Items
Type: Array of strings

A list of Amazon Web Services account identifiers.

Quantity
Required: Yes
Type: int

The number of Amazon Web Services accounts in the list.

UnsupportedOperation

Description

This operation is not supported in this region.

Members
Message
Type: string

UpdateFunctionRequest

Members
FunctionCode
Required: Yes
Type: blob (string|resource|Psr\Http\Message\StreamInterface)

The function code. For more information about writing a CloudFront function, see Writing function code for CloudFront Functions in the Amazon CloudFront Developer Guide.

FunctionConfig
Required: Yes
Type: FunctionConfig structure

Configuration information about the function.

IfMatch
Required: Yes
Type: string

The current version (ETag value) of the function that you are updating, which you can get using DescribeFunction.

Name
Required: Yes
Type: string

The name of the function that you are updating.

UpdateKeyValueStoreRequest

Members
Comment
Required: Yes
Type: string

The comment of the key value store to update.

IfMatch
Required: Yes
Type: string

The key value store to update, if a match occurs.

Name
Required: Yes
Type: string

The name of the key value store to update.

UpdateRealtimeLogConfigRequest

Members
ARN
Type: string

The Amazon Resource Name (ARN) for this real-time log configuration.

EndPoints
Type: Array of EndPoint structures

Contains information about the Amazon Kinesis data stream where you are sending real-time log data.

Fields
Type: Array of strings

A list of fields to include in each real-time log record.

For more information about fields, see Real-time log configuration fields in the Amazon CloudFront Developer Guide.

Name
Type: string

The name for this real-time log configuration.

SamplingRate
Type: long (int|float)

The sampling rate for this real-time log configuration. The sampling rate determines the percentage of viewer requests that are represented in the real-time log data. You must provide an integer between 1 and 100, inclusive.

ViewerCertificate

Description

A complex type that determines the distribution's SSL/TLS configuration for communicating with viewers.

If the distribution doesn't use Aliases (also known as alternate domain names or CNAMEs)—that is, if the distribution uses the CloudFront domain name such as d111111abcdef8.cloudfront.net—set CloudFrontDefaultCertificate to true and leave all other fields empty.

If the distribution uses Aliases (alternate domain names or CNAMEs), use the fields in this type to specify the following settings:

  • Which viewers the distribution accepts HTTPS connections from: only viewers that support server name indication (SNI) (recommended), or all viewers including those that don't support SNI.

    • To accept HTTPS connections from only viewers that support SNI, set SSLSupportMethod to sni-only. This is recommended. Most browsers and clients support SNI.

    • To accept HTTPS connections from all viewers, including those that don't support SNI, set SSLSupportMethod to vip. This is not recommended, and results in additional monthly charges from CloudFront.

  • The minimum SSL/TLS protocol version that the distribution can use to communicate with viewers. To specify a minimum version, choose a value for MinimumProtocolVersion. For more information, see Security Policy in the Amazon CloudFront Developer Guide.

  • The location of the SSL/TLS certificate, Certificate Manager (ACM) (recommended) or Identity and Access Management (IAM). You specify the location by setting a value in one of the following fields (not both):

    • ACMCertificateArn

    • IAMCertificateId

All distributions support HTTPS connections from viewers. To require viewers to use HTTPS only, or to redirect them from HTTP to HTTPS, use ViewerProtocolPolicy in the CacheBehavior or DefaultCacheBehavior. To specify how CloudFront should use SSL/TLS to communicate with your custom origin, use CustomOriginConfig.

For more information, see Using HTTPS with CloudFront and Using Alternate Domain Names and HTTPS in the Amazon CloudFront Developer Guide.

Members
ACMCertificateArn
Type: string

If the distribution uses Aliases (alternate domain names or CNAMEs) and the SSL/TLS certificate is stored in Certificate Manager (ACM), provide the Amazon Resource Name (ARN) of the ACM certificate. CloudFront only supports ACM certificates in the US East (N. Virginia) Region (us-east-1).

If you specify an ACM certificate ARN, you must also specify values for MinimumProtocolVersion and SSLSupportMethod.

Certificate
Type: string

This field is deprecated. Use one of the following fields instead:

  • ACMCertificateArn

  • IAMCertificateId

  • CloudFrontDefaultCertificate

CertificateSource
Type: string

This field is deprecated. Use one of the following fields instead:

  • ACMCertificateArn

  • IAMCertificateId

  • CloudFrontDefaultCertificate

CloudFrontDefaultCertificate
Type: boolean

If the distribution uses the CloudFront domain name such as d111111abcdef8.cloudfront.net, set this field to true.

If the distribution uses Aliases (alternate domain names or CNAMEs), set this field to false and specify values for the following fields:

  • ACMCertificateArn or IAMCertificateId (specify a value for one, not both)

  • MinimumProtocolVersion

  • SSLSupportMethod

IAMCertificateId
Type: string

If the distribution uses Aliases (alternate domain names or CNAMEs) and the SSL/TLS certificate is stored in Identity and Access Management (IAM), provide the ID of the IAM certificate.

If you specify an IAM certificate ID, you must also specify values for MinimumProtocolVersion and SSLSupportMethod.

MinimumProtocolVersion
Type: string

If the distribution uses Aliases (alternate domain names or CNAMEs), specify the security policy that you want CloudFront to use for HTTPS connections with viewers. The security policy determines two settings:

  • The minimum SSL/TLS protocol that CloudFront can use to communicate with viewers.

  • The ciphers that CloudFront can use to encrypt the content that it returns to viewers.

For more information, see Security Policy and Supported Protocols and Ciphers Between Viewers and CloudFront in the Amazon CloudFront Developer Guide.

On the CloudFront console, this setting is called Security Policy.

When you're using SNI only (you set SSLSupportMethod to sni-only), you must specify TLSv1 or higher.

If the distribution uses the CloudFront domain name such as d111111abcdef8.cloudfront.net (you set CloudFrontDefaultCertificate to true), CloudFront automatically sets the security policy to TLSv1 regardless of the value that you set here.

SSLSupportMethod
Type: string

If the distribution uses Aliases (alternate domain names or CNAMEs), specify which viewers the distribution accepts HTTPS connections from.

  • sni-only – The distribution accepts HTTPS connections from only viewers that support server name indication (SNI). This is recommended. Most browsers and clients support SNI.

  • vip – The distribution accepts HTTPS connections from all viewers including those that don't support SNI. This is not recommended, and results in additional monthly charges from CloudFront.

  • static-ip - Do not specify this value unless your distribution has been enabled for this feature by the CloudFront team. If you have a use case that requires static IP addresses for a distribution, contact CloudFront through the Amazon Web Services Support Center.

If the distribution uses the CloudFront domain name such as d111111abcdef8.cloudfront.net, don't set a value for this field.

VpcOrigin

Description

An Amazon CloudFront VPC origin.

Members
Arn
Required: Yes
Type: string

The VPC origin ARN.

CreatedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The VPC origin created time.

Id
Required: Yes
Type: string

The VPC origin ID.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The VPC origin last modified time.

Status
Required: Yes
Type: string

The VPC origin status.

VpcOriginEndpointConfig
Required: Yes
Type: VpcOriginEndpointConfig structure

The VPC origin endpoint configuration.

VpcOriginConfig

Description

An Amazon CloudFront VPC origin configuration.

Members
OriginKeepaliveTimeout
Type: int

Specifies how long, in seconds, CloudFront persists its connection to the origin. The minimum timeout is 1 second, the maximum is 60 seconds, and the default (if you don't specify otherwise) is 5 seconds.

For more information, see Keep-alive timeout (custom origins only) in the Amazon CloudFront Developer Guide.

OriginReadTimeout
Type: int

Specifies how long, in seconds, CloudFront waits for a response from the origin. This is also known as the origin response timeout. The minimum timeout is 1 second, the maximum is 60 seconds, and the default (if you don't specify otherwise) is 30 seconds.

For more information, see Response timeout (custom origins only) in the Amazon CloudFront Developer Guide.

VpcOriginId
Required: Yes
Type: string

The VPC origin ID.

VpcOriginEndpointConfig

Description

An Amazon CloudFront VPC origin endpoint configuration.

Members
Arn
Required: Yes
Type: string

The ARN of the CloudFront VPC origin endpoint configuration.

HTTPPort
Required: Yes
Type: int

The HTTP port for the CloudFront VPC origin endpoint configuration.

HTTPSPort
Required: Yes
Type: int

The HTTPS port of the CloudFront VPC origin endpoint configuration.

Name
Required: Yes
Type: string

The name of the CloudFront VPC origin endpoint configuration.

OriginProtocolPolicy
Required: Yes
Type: string

The origin protocol policy for the CloudFront VPC origin endpoint configuration.

OriginSslProtocols
Type: OriginSslProtocols structure

A complex type that contains information about the SSL/TLS protocols that CloudFront can use when establishing an HTTPS connection with your origin.

VpcOriginList

Description

A list of CloudFront VPC origins.

Members
IsTruncated
Required: Yes
Type: boolean

A flag that indicates whether more VPC origins remain to be listed. If your results were truncated, you can make a follow-up pagination request using the Marker request parameter to retrieve more VPC origins in the list.

Items
Type: Array of VpcOriginSummary structures

The items of the VPC origins list.

Marker
Required: Yes
Type: string

The marker associated with the VPC origins list.

MaxItems
Required: Yes
Type: int

The maximum number of items included in the list.

NextMarker
Type: string

The next marker associated with the VPC origins list.

Quantity
Required: Yes
Type: int

The number of VPC origins in the list.

VpcOriginSummary

Description

A summary of the CloudFront VPC origin.

Members
Arn
Required: Yes
Type: string

The VPC origin summary ARN.

CreatedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The VPC origin summary created time.

Id
Required: Yes
Type: string

The VPC origin summary ID.

LastModifiedTime
Required: Yes
Type: timestamp (string|DateTime or anything parsable by strtotime)

The VPC origin summary last modified time.

Name
Required: Yes
Type: string

The VPC origin summary name.

OriginEndpointArn
Required: Yes
Type: string

The VPC origin summary origin endpoint ARN.

Status
Required: Yes
Type: string

The VPC origin summary status.