AWS::CloudFront::Distribution FunctionAssociation - Amazon CloudFormation
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

AWS::CloudFront::Distribution FunctionAssociation

A CloudFront function that is associated with a cache behavior in a CloudFront distribution.

Syntax

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

JSON

{ "EventType" : String, "FunctionARN" : String }

YAML

EventType: String FunctionARN: String

Properties

EventType

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.

Required: No

Type: String

Allowed values: viewer-request | viewer-response | origin-request | origin-response

Update requires: No interruption

FunctionARN

The Amazon Resource Name (ARN) of the function.

Required: No

Type: String

Pattern: arn:aws:cloudfront::[0-9]{12}:function\/[a-zA-Z0-9-_]{1,64}

Minimum: 0

Maximum: 108

Update requires: No interruption