getFunction

Creates a CF 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, and the function’s stage. By default, when you create a function, it’s in the `DEVELOPMENT` stage. In this stage, you can test the function in the CF console (or with `TestFunction` in the CF API). When you’re ready to use your function with a CF distribution, publish the function to the `LIVE` stage. You can do this in the CF console, with `PublishFunction` in the CF API, or by updating the `AWS::CloudFront::Function` resource with the `AutoPublish` property set to `true`. When the function is published to the `LIVE` stage, you can attach it to a distribution’s cache behavior, using the function’s ARN. To automatically publish the function to the `LIVE` stage when it’s created, set the `AutoPublish` property to `true`.

Return

null

Parameters

argument

null


suspend fun getFunction(functionArn: String): GetFunctionResult

Return

null

Parameters

functionArn

The ARN of the function. For example: arn:aws:cloudfront::123456789012:function/ExampleFunction . To get the function ARN, use the following syntax: !GetAtt *Function_Logical_ID* .FunctionMetadata.FunctionARN

See also


suspend fun getFunction(argument: suspend GetFunctionPlainArgsBuilder.() -> Unit): GetFunctionResult

Return

null

Parameters

argument

Builder for com.pulumi.awsnative.cloudfront.kotlin.inputs.GetFunctionPlainArgs.

See also