AWS::IVS::StreamKey - 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).


The AWS::IVS::StreamKey resource specifies an Amazon IVS stream key associated with the referenced channel. Use a stream key to initiate a live stream.


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


{ "Type" : "AWS::IVS::StreamKey", "Properties" : { "ChannelArn" : String, "Tags" : [ Tag, ... ] } }


Type: AWS::IVS::StreamKey Properties: ChannelArn: String Tags: - Tag



Channel ARN for the stream.

Required: Yes

Type: String

Pattern: ^arn:aws:ivs:[a-z0-9-]+:[0-9]+:channel/[a-zA-Z0-9-]+$

Update requires: Replacement


An array of key-value pairs to apply to this resource.

For more information, see Tag.

Required: No

Type: Array of Tag

Maximum: 50

Update requires: No interruption

Return values


When you pass the logical ID of this resource to the intrinsic Ref function, Ref returns the resource ARN. For example:

{ "Ref": "myStreamKey" }

For the Amazon IVS stream key myStreamKey, Ref returns the stream key ARN.

For more information about using the Ref function, see Ref.


The Fn::GetAtt intrinsic function returns a value for a specified attribute of this type. The following are the available attributes and sample return values.

For more information about using the Fn::GetAtt intrinsic function, see Fn::GetAtt.


The stream-key ARN. For example: arn:aws:ivs:us-west-2:123456789012:stream-key/g1H2I3j4k5L6


The stream-key value. For example: sk_us-west-2_abcdABCDefgh_567890abcdef


Channel and Stream Key Template Examples

The following examples specify an Amazon IVS channel and stream key.


{ "AWSTemplateFormatVersion": "2010-09-09", "Resources": { "Channel": { "Type": "AWS::IVS::Channel", "Properties": { "Name": "MyChannel", "Tags": [ { "Key": "MyKey", "Value": "MyValue" } ], "InsecureIngest": true } }, "StreamKey": { "Type": "AWS::IVS::StreamKey", "Properties": { "ChannelArn": {"Ref": "Channel"}, "Tags": [ { "Key": "MyKey", "Value": "MyValue" } ] } } }, "Outputs": { "ChannelArn": { "Value": {"Ref": "Channel"} }, "ChannelIngestEndpoint": { "Value": { "Fn::GetAtt": [ "Channel", "IngestEndpoint" ] } }, "ChannelPlaybackUrl": { "Value": { "Fn::GetAtt": [ "Channel", "PlaybackUrl" ] } }, "StreamKeyArn": { "Value": {"Ref": "StreamKey"} } } }


AWSTemplateFormatVersion: 2010-09-09 Resources: Channel: Type: AWS::IVS::Channel Properties: Name: MyChannel Tags: - Key: MyKey Value: MyValue InsecureIngest: true StreamKey: Type: AWS::IVS::StreamKey Properties: ChannelArn: !Ref Channel Tags: - Key: MyKey Value: MyValue Outputs: ChannelArn: Value: !Ref Channel ChannelIngestEndpoint: Value: !GetAtt Channel.IngestEndpoint ChannelPlaybackUrl: Value: !GetAtt Channel.PlaybackUrl StreamKeyArn: Value: !Ref StreamKey

See also