Skip to content
v2.274.0

AWS::MediaPackageV2 Construct Library ​

Version 2.274.0-alpha.0

Separate package

@aws-cdk/aws-mediapackagev2-alpha is not part of aws-cdk-lib — install it separately:

sh
npm install @aws-cdk/aws-mediapackagev2-alpha
pip install aws-cdk.aws-mediapackagev2-alpha

This module is experimental (alpha): its API may change in any release, without a major version bump.


cdk-constructs: Experimental

The APIs of higher level constructs in this module are experimental and under active development. They are subject to non-backward compatible changes or removal in any future version. These are not subject to the Semantic Versioning model and breaking changes will be announced in the release notes. This means that while you may use them, you may need to update your source code when upgrading to a newer version of this package.


AWS Elemental MediaPackage V2 ​

MediaPackage delivers high-quality video without concern for capacity and makes it easier to implement popular DVR features such as start over, pause, and rewind. Your content will be protected with comprehensive support for DRM. The service seamlessly integrates with other AWS media services as a complete set of tools for cloud-based video processing and delivery.

This package contains constructs for working with AWS Elemental MediaPackage V2. Allowing you to define AWS Elemental MediaPackage V2 Channel Groups, Channels, Origin Endpoints, Channel Policies and Origin Endpoint Policies.

For further information on AWS Elemental MediaPackage V2, see the documentation.

The following example creates an AWS Elemental MediaPackage V2 Channel Group, Channel and Origin Endpoint:

ts
declare const stack: Stack;
const group = new ChannelGroup(stack, 'MyChannelGroup', {
    channelGroupName: 'my-test-channel-group',
});

const channel = new Channel(stack, 'MyChannel', {
    channelGroup: group,
    channelName: 'my-testchannel',
    input: InputConfiguration.cmaf(),
});

const endpoint = new OriginEndpoint(stack, 'MyOriginEndpoint', {
    channel,
    originEndpointName: 'my-test-endpoint',
    segment: Segment.cmaf(),
    manifests: [Manifest.hls({
        manifestName: 'index',
    })],
});
python
# stack: Stack

group = ChannelGroup(stack, "MyChannelGroup",
    channel_group_name="my-test-channel-group"
)

channel = Channel(stack, "MyChannel",
    channel_group=group,
    channel_name="my-testchannel",
    input=InputConfiguration.cmaf()
)

endpoint = OriginEndpoint(stack, "MyOriginEndpoint",
    channel=channel,
    origin_endpoint_name="my-test-endpoint",
    segment=Segment.cmaf(),
    manifests=[Manifest.hls(
        manifest_name="index"
    )]
)
java
Stack stack;

ChannelGroup group = ChannelGroup.Builder.create(stack, "MyChannelGroup")
        .channelGroupName("my-test-channel-group")
        .build();

Channel channel = Channel.Builder.create(stack, "MyChannel")
        .channelGroup(group)
        .channelName("my-testchannel")
        .input(InputConfiguration.cmaf())
        .build();

OriginEndpoint endpoint = OriginEndpoint.Builder.create(stack, "MyOriginEndpoint")
        .channel(channel)
        .originEndpointName("my-test-endpoint")
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder()
                .manifestName("index")
                .build())))
        .build();
csharp
Stack stack;

var group = new ChannelGroup(stack, "MyChannelGroup", new ChannelGroupProps {
    ChannelGroupName = "my-test-channel-group"
});

var channel = new Channel(stack, "MyChannel", new ChannelProps {
    ChannelGroup = group,
    ChannelName = "my-testchannel",
    Input = InputConfiguration.Cmaf()
});

var endpoint = new OriginEndpoint(stack, "MyOriginEndpoint", new OriginEndpointProps {
    Channel = channel,
    OriginEndpointName = "my-test-endpoint",
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration {
        ManifestName = "index"
    }) }
});
go
var stack Stack

group := awsmediapackagev2alpha.NewChannelGroup(stack, jsii.String("MyChannelGroup"), &ChannelGroupProps{
	ChannelGroupName: jsii.String("my-test-channel-group"),
})

channel := awsmediapackagev2alpha.NewChannel(stack, jsii.String("MyChannel"), &ChannelProps{
	ChannelGroup: group,
	ChannelName: jsii.String("my-testchannel"),
	Input: awsmediapackagev2alpha.InputConfiguration_Cmaf(),
})

endpoint := awsmediapackagev2alpha.NewOriginEndpoint(stack, jsii.String("MyOriginEndpoint"), &OriginEndpointProps{
	Channel: Channel,
	OriginEndpointName: jsii.String("my-test-endpoint"),
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

Using Factory Methods ​

ts
declare const stack: Stack;

// Create a channel group
const group = new ChannelGroup(stack, 'MyChannelGroup', {
  channelGroupName: 'my-channel-group',
});

// Add a channel using the factory method
const channel = group.addChannel('MyChannel', {
  channelName: 'my-channel',
  input: InputConfiguration.cmaf(),
});

// Add an origin endpoint using the factory method
const endpoint = channel.addOriginEndpoint('MyEndpoint', {
  originEndpointName: 'my-endpoint',
  segment: Segment.cmaf(),
  manifests: [Manifest.hls({ manifestName: 'index' })],
});
python
# stack: Stack


# Create a channel group
group = ChannelGroup(stack, "MyChannelGroup",
    channel_group_name="my-channel-group"
)

# Add a channel using the factory method
channel = group.add_channel("MyChannel",
    channel_name="my-channel",
    input=InputConfiguration.cmaf()
)

# Add an origin endpoint using the factory method
endpoint = channel.add_origin_endpoint("MyEndpoint",
    origin_endpoint_name="my-endpoint",
    segment=Segment.cmaf(),
    manifests=[Manifest.hls(manifest_name="index")]
)
java
Stack stack;


// Create a channel group
ChannelGroup group = ChannelGroup.Builder.create(stack, "MyChannelGroup")
        .channelGroupName("my-channel-group")
        .build();

// Add a channel using the factory method
Channel channel = group.addChannel("MyChannel", ChannelOptions.builder()
        .channelName("my-channel")
        .input(InputConfiguration.cmaf())
        .build());

// Add an origin endpoint using the factory method
OriginEndpoint endpoint = channel.addOriginEndpoint("MyEndpoint", OriginEndpointOptions.builder()
        .originEndpointName("my-endpoint")
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .build());
csharp
Stack stack;


// Create a channel group
var group = new ChannelGroup(stack, "MyChannelGroup", new ChannelGroupProps {
    ChannelGroupName = "my-channel-group"
});

// Add a channel using the factory method
var channel = group.AddChannel("MyChannel", new ChannelOptions {
    ChannelName = "my-channel",
    Input = InputConfiguration.Cmaf()
});

// Add an origin endpoint using the factory method
var endpoint = channel.AddOriginEndpoint("MyEndpoint", new OriginEndpointOptions {
    OriginEndpointName = "my-endpoint",
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) }
});
go
var stack Stack


// Create a channel group
group := awsmediapackagev2alpha.NewChannelGroup(stack, jsii.String("MyChannelGroup"), &ChannelGroupProps{
	ChannelGroupName: jsii.String("my-channel-group"),
})

// Add a channel using the factory method
channel := group.addChannel(jsii.String("MyChannel"), &ChannelOptions{
	ChannelName: jsii.String("my-channel"),
	Input: awsmediapackagev2alpha.InputConfiguration_Cmaf(),
})

// Add an origin endpoint using the factory method
endpoint := channel.addOriginEndpoint(jsii.String("MyEndpoint"), &OriginEndpointOptions{
	OriginEndpointName: jsii.String("my-endpoint"),
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

Channel Group ​

A channel group is the top-level resource that consists of channels and origin endpoints associated with it.

The following code creates a Channel Group:

ts
declare const stack: Stack;
const group = new ChannelGroup(stack, 'MyChannelGroup', {
    channelGroupName: 'my-test-channel-group',
});
python
# stack: Stack

group = ChannelGroup(stack, "MyChannelGroup",
    channel_group_name="my-test-channel-group"
)
java
Stack stack;

ChannelGroup group = ChannelGroup.Builder.create(stack, "MyChannelGroup")
        .channelGroupName("my-test-channel-group")
        .build();
csharp
Stack stack;

var group = new ChannelGroup(stack, "MyChannelGroup", new ChannelGroupProps {
    ChannelGroupName = "my-test-channel-group"
});
go
var stack Stack

group := awsmediapackagev2alpha.NewChannelGroup(stack, jsii.String("MyChannelGroup"), &ChannelGroupProps{
	ChannelGroupName: jsii.String("my-test-channel-group"),
})

The following code imports an existing channel group using the name attribute:

ts
declare const stack: Stack;
const channelGroup = ChannelGroup.fromChannelGroupAttributes(stack, 'ImportedChannelGroup', {
    channelGroupName: 'MyChannelGroup',
});
python
# stack: Stack

channel_group = ChannelGroup.from_channel_group_attributes(stack, "ImportedChannelGroup",
    channel_group_name="MyChannelGroup"
)
java
Stack stack;

IChannelGroup channelGroup = ChannelGroup.fromChannelGroupAttributes(stack, "ImportedChannelGroup", ChannelGroupAttributes.builder()
        .channelGroupName("MyChannelGroup")
        .build());
csharp
Stack stack;

var channelGroup = ChannelGroup.FromChannelGroupAttributes(stack, "ImportedChannelGroup", new ChannelGroupAttributes {
    ChannelGroupName = "MyChannelGroup"
});
go
var stack Stack

channelGroup := awsmediapackagev2alpha.ChannelGroup_FromChannelGroupAttributes(stack, jsii.String("ImportedChannelGroup"), &ChannelGroupAttributes{
	ChannelGroupName: jsii.String("MyChannelGroup"),
})

You can also import from an ARN, which automatically extracts the name and region:

ts
declare const stack: Stack;
const channelGroup = ChannelGroup.fromChannelGroupArn(stack, 'ImportedChannelGroup',
    'arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyChannelGroup',
);
python
# stack: Stack

channel_group = ChannelGroup.from_channel_group_arn(stack, "ImportedChannelGroup", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyChannelGroup")
java
Stack stack;

IChannelGroup channelGroup = ChannelGroup.fromChannelGroupArn(stack, "ImportedChannelGroup", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyChannelGroup");
csharp
Stack stack;

var channelGroup = ChannelGroup.FromChannelGroupArn(stack, "ImportedChannelGroup", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyChannelGroup");
go
var stack Stack

channelGroup := awsmediapackagev2alpha.ChannelGroup_FromChannelGroupArn(stack, jsii.String("ImportedChannelGroup"), jsii.String("arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyChannelGroup"))

For cross-region imports, pass the region parameter to ensure the correct ARN is constructed:

ts
declare const stack: Stack;
const channelGroup = ChannelGroup.fromChannelGroupAttributes(stack, 'ImportedChannelGroup', {
    channelGroupName: 'MyChannelGroup',
    region: 'us-west-2',
});
python
# stack: Stack

channel_group = ChannelGroup.from_channel_group_attributes(stack, "ImportedChannelGroup",
    channel_group_name="MyChannelGroup",
    region="us-west-2"
)
java
Stack stack;

IChannelGroup channelGroup = ChannelGroup.fromChannelGroupAttributes(stack, "ImportedChannelGroup", ChannelGroupAttributes.builder()
        .channelGroupName("MyChannelGroup")
        .region("us-west-2")
        .build());
csharp
Stack stack;

var channelGroup = ChannelGroup.FromChannelGroupAttributes(stack, "ImportedChannelGroup", new ChannelGroupAttributes {
    ChannelGroupName = "MyChannelGroup",
    Region = "us-west-2"
});
go
var stack Stack

channelGroup := awsmediapackagev2alpha.ChannelGroup_FromChannelGroupAttributes(stack, jsii.String("ImportedChannelGroup"), &ChannelGroupAttributes{
	ChannelGroupName: jsii.String("MyChannelGroup"),
	Region: jsii.String("us-west-2"),
})

Channel ​

A channel is part of a channel group and represents the entry point for a content stream into MediaPackage.

Input Configuration ​

Channels support two input types: HLS and CMAF.

ts
declare const stack: Stack;
declare const group: ChannelGroup;

const hlsChannel = new Channel(stack, 'HlsChannel', {
  channelGroup: group,
  input: InputConfiguration.hls(),
});

const cmafChannel = new Channel(stack, 'CmafChannel', {
  channelGroup: group,
  input: InputConfiguration.cmaf({
    inputSwitchConfiguration: {
      mqcsInputSwitching: true,
    },
    outputHeaders: [HeadersCMSD.MQCS],
  }),
});

const simpleCmafChannel = new Channel(stack, 'SimpleCmafChannel', {
  channelGroup: group,
  input: InputConfiguration.cmaf({
    outputHeaders: [HeadersCMSD.MQCS],
  }),
});
python
from aws_cdk.aws_mediapackagev2_alpha import InputSwitchConfiguration
# stack: Stack
# group: ChannelGroup


hls_channel = Channel(stack, "HlsChannel",
    channel_group=group,
    input=InputConfiguration.hls()
)

cmaf_channel = Channel(stack, "CmafChannel",
    channel_group=group,
    input=InputConfiguration.cmaf(
        input_switch_configuration=InputSwitchConfiguration(
            mqcs_input_switching=True
        ),
        output_headers=[HeadersCMSD.MQCS]
    )
)

simple_cmaf_channel = Channel(stack, "SimpleCmafChannel",
    channel_group=group,
    input=InputConfiguration.cmaf(
        output_headers=[HeadersCMSD.MQCS]
    )
)
java
Stack stack;
ChannelGroup group;


Channel hlsChannel = Channel.Builder.create(stack, "HlsChannel")
        .channelGroup(group)
        .input(InputConfiguration.hls())
        .build();

Channel cmafChannel = Channel.Builder.create(stack, "CmafChannel")
        .channelGroup(group)
        .input(InputConfiguration.cmaf(CmafInputProps.builder()
                .inputSwitchConfiguration(InputSwitchConfiguration.builder()
                        .mqcsInputSwitching(true)
                        .build())
                .outputHeaders(List.of(HeadersCMSD.MQCS))
                .build()))
        .build();

Channel simpleCmafChannel = Channel.Builder.create(stack, "SimpleCmafChannel")
        .channelGroup(group)
        .input(InputConfiguration.cmaf(CmafInputProps.builder()
                .outputHeaders(List.of(HeadersCMSD.MQCS))
                .build()))
        .build();
csharp
Stack stack;
ChannelGroup group;


var hlsChannel = new Channel(stack, "HlsChannel", new ChannelProps {
    ChannelGroup = group,
    Input = InputConfiguration.Hls()
});

var cmafChannel = new Channel(stack, "CmafChannel", new ChannelProps {
    ChannelGroup = group,
    Input = InputConfiguration.Cmaf(new CmafInputProps {
        InputSwitchConfiguration = new InputSwitchConfiguration {
            MqcsInputSwitching = true
        },
        OutputHeaders = new [] { HeadersCMSD.MQCS }
    })
});

var simpleCmafChannel = new Channel(stack, "SimpleCmafChannel", new ChannelProps {
    ChannelGroup = group,
    Input = InputConfiguration.Cmaf(new CmafInputProps {
        OutputHeaders = new [] { HeadersCMSD.MQCS }
    })
});
go
var stack Stack
var group ChannelGroup


hlsChannel := awsmediapackagev2alpha.NewChannel(stack, jsii.String("HlsChannel"), &ChannelProps{
	ChannelGroup: group,
	Input: awsmediapackagev2alpha.InputConfiguration_Hls(),
})

cmafChannel := awsmediapackagev2alpha.NewChannel(stack, jsii.String("CmafChannel"), &ChannelProps{
	ChannelGroup: group,
	Input: awsmediapackagev2alpha.InputConfiguration_Cmaf(&CmafInputProps{
		InputSwitchConfiguration: &InputSwitchConfiguration{
			MqcsInputSwitching: jsii.Boolean(true),
		},
		OutputHeaders: []HeadersCMSD{
			awsmediapackagev2alpha.HeadersCMSD_MQCS(),
		},
	}),
})

simpleCmafChannel := awsmediapackagev2alpha.NewChannel(stack, jsii.String("SimpleCmafChannel"), &ChannelProps{
	ChannelGroup: group,
	Input: awsmediapackagev2alpha.InputConfiguration_*Cmaf(&CmafInputProps{
		OutputHeaders: []HeadersCMSD{
			awsmediapackagev2alpha.HeadersCMSD_MQCS(),
		},
	}),
})

Importing an Existing Channel ​

The following code imports an existing channel using the name attributes:

ts
declare const stack: Stack;
const channel = Channel.fromChannelAttributes(stack, 'ImportedChannel', {
    channelName: 'MyChannel',
    channelGroupName: 'MyChannelGroup',
});
python
# stack: Stack

channel = Channel.from_channel_attributes(stack, "ImportedChannel",
    channel_name="MyChannel",
    channel_group_name="MyChannelGroup"
)
java
Stack stack;

IChannel channel = Channel.fromChannelAttributes(stack, "ImportedChannel", ChannelAttributes.builder()
        .channelName("MyChannel")
        .channelGroupName("MyChannelGroup")
        .build());
csharp
Stack stack;

var channel = Channel.FromChannelAttributes(stack, "ImportedChannel", new ChannelAttributes {
    ChannelName = "MyChannel",
    ChannelGroupName = "MyChannelGroup"
});
go
var stack Stack

channel := awsmediapackagev2alpha.Channel_FromChannelAttributes(stack, jsii.String("ImportedChannel"), &ChannelAttributes{
	ChannelName: jsii.String("MyChannel"),
	ChannelGroupName: jsii.String("MyChannelGroup"),
})

You can also import from an ARN:

ts
declare const stack: Stack;
const channel = Channel.fromChannelArn(stack, 'ImportedChannel',
    'arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel',
);
python
# stack: Stack

channel = Channel.from_channel_arn(stack, "ImportedChannel", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel")
java
Stack stack;

IChannel channel = Channel.fromChannelArn(stack, "ImportedChannel", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel");
csharp
Stack stack;

var channel = Channel.FromChannelArn(stack, "ImportedChannel", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel");
go
var stack Stack

channel := awsmediapackagev2alpha.Channel_FromChannelArn(stack, jsii.String("ImportedChannel"), jsii.String("arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel"))

Imported channels expose a region property, which is parsed from the ARN or falls back to the importing stack's region.

Channel Resource Policy ​

The following code creates a resource policy directly on the channel. This will automatically create a policy on the first call:

ts
declare const channel: Channel;
channel.addToResourcePolicy(new PolicyStatement({
    sid: 'AllowMediaLiveRoleToAccessEmpChannel',
    principals: [new ArnPrincipal('arn:aws:iam::AccountID:role/MediaLiveAccessRole')],
    effect: Effect.ALLOW,
    actions: ['mediapackagev2:PutObject'],
    resources: [channel.channelArn],
}));
python
# channel: Channel

channel.add_to_resource_policy(PolicyStatement(
    sid="AllowMediaLiveRoleToAccessEmpChannel",
    principals=[ArnPrincipal("arn:aws:iam::AccountID:role/MediaLiveAccessRole")],
    effect=Effect.ALLOW,
    actions=["mediapackagev2:PutObject"],
    resources=[channel.channel_arn]
))
java
Channel channel;

channel.addToResourcePolicy(PolicyStatement.Builder.create()
        .sid("AllowMediaLiveRoleToAccessEmpChannel")
        .principals(List.of(new ArnPrincipal("arn:aws:iam::AccountID:role/MediaLiveAccessRole")))
        .effect(Effect.ALLOW)
        .actions(List.of("mediapackagev2:PutObject"))
        .resources(List.of(channel.getChannelArn()))
        .build());
csharp
Channel channel;

channel.AddToResourcePolicy(new PolicyStatement(new PolicyStatementProps {
    Sid = "AllowMediaLiveRoleToAccessEmpChannel",
    Principals = new [] { new ArnPrincipal("arn:aws:iam::AccountID:role/MediaLiveAccessRole") },
    Effect = Effect.ALLOW,
    Actions = new [] { "mediapackagev2:PutObject" },
    Resources = new [] { channel.ChannelArn }
}));
go
var channel Channel

channel.addToResourcePolicy(awscdk.NewPolicyStatement(&PolicyStatementProps{
	Sid: jsii.String("AllowMediaLiveRoleToAccessEmpChannel"),
	Principals: []IPrincipal{
		awscdk.NewArnPrincipal(jsii.String("arn:aws:iam::AccountID:role/MediaLiveAccessRole")),
	},
	Effect: awscdk.Effect_ALLOW,
	Actions: []*string{
		jsii.String("mediapackagev2:PutObject"),
	},
	Resources: []*string{
		channel.ChannelArn,
	},
}))

Origin Endpoint ​

ts
declare const stack: Stack;
declare const channel: Channel;
new OriginEndpoint(stack, 'myendpoint', {
    channel,
    originEndpointName: 'my-test-endpoint',
    segment: Segment.cmaf(),
    manifests: [
      Manifest.hls({
        manifestName: 'index',
      }),
    ],
});
python
# stack: Stack
# channel: Channel

OriginEndpoint(stack, "myendpoint",
    channel=channel,
    origin_endpoint_name="my-test-endpoint",
    segment=Segment.cmaf(),
    manifests=[
        Manifest.hls(
            manifest_name="index"
        )
    ]
)
java
Stack stack;
Channel channel;

OriginEndpoint.Builder.create(stack, "myendpoint")
        .channel(channel)
        .originEndpointName("my-test-endpoint")
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder()
                .manifestName("index")
                .build())))
        .build();
csharp
Stack stack;
Channel channel;

new OriginEndpoint(stack, "myendpoint", new OriginEndpointProps {
    Channel = channel,
    OriginEndpointName = "my-test-endpoint",
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration {
        ManifestName = "index"
    }) }
});
go
var stack Stack
var channel Channel

awsmediapackagev2alpha.NewOriginEndpoint(stack, jsii.String("myendpoint"), &OriginEndpointProps{
	Channel: Channel,
	OriginEndpointName: jsii.String("my-test-endpoint"),
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

The following code imports an existing origin endpoint using the name attributes:

ts
declare const stack: Stack;
const originEndpoint = OriginEndpoint.fromOriginEndpointAttributes(stack, 'ImportedOriginEndpoint', {
    channelGroupName: 'MyChannelGroup',
    channelName: 'MyChannel',
    originEndpointName: 'MyExampleOriginEndpoint',
});
python
# stack: Stack

origin_endpoint = OriginEndpoint.from_origin_endpoint_attributes(stack, "ImportedOriginEndpoint",
    channel_group_name="MyChannelGroup",
    channel_name="MyChannel",
    origin_endpoint_name="MyExampleOriginEndpoint"
)
java
Stack stack;

IOriginEndpoint originEndpoint = OriginEndpoint.fromOriginEndpointAttributes(stack, "ImportedOriginEndpoint", OriginEndpointAttributes.builder()
        .channelGroupName("MyChannelGroup")
        .channelName("MyChannel")
        .originEndpointName("MyExampleOriginEndpoint")
        .build());
csharp
Stack stack;

var originEndpoint = OriginEndpoint.FromOriginEndpointAttributes(stack, "ImportedOriginEndpoint", new OriginEndpointAttributes {
    ChannelGroupName = "MyChannelGroup",
    ChannelName = "MyChannel",
    OriginEndpointName = "MyExampleOriginEndpoint"
});
go
var stack Stack

originEndpoint := awsmediapackagev2alpha.OriginEndpoint_FromOriginEndpointAttributes(stack, jsii.String("ImportedOriginEndpoint"), &OriginEndpointAttributes{
	ChannelGroupName: jsii.String("MyChannelGroup"),
	ChannelName: jsii.String("MyChannel"),
	OriginEndpointName: jsii.String("MyExampleOriginEndpoint"),
})

You can also import from an ARN:

ts
declare const stack: Stack;
const originEndpoint = OriginEndpoint.fromOriginEndpointArn(stack, 'ImportedOriginEndpoint',
    'arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel/originEndpoint/MyEndpoint',
);
python
# stack: Stack

origin_endpoint = OriginEndpoint.from_origin_endpoint_arn(stack, "ImportedOriginEndpoint", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel/originEndpoint/MyEndpoint")
java
Stack stack;

IOriginEndpoint originEndpoint = OriginEndpoint.fromOriginEndpointArn(stack, "ImportedOriginEndpoint", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel/originEndpoint/MyEndpoint");
csharp
Stack stack;

var originEndpoint = OriginEndpoint.FromOriginEndpointArn(stack, "ImportedOriginEndpoint", "arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel/originEndpoint/MyEndpoint");
go
var stack Stack

originEndpoint := awsmediapackagev2alpha.OriginEndpoint_FromOriginEndpointArn(stack, jsii.String("ImportedOriginEndpoint"), jsii.String("arn:aws:mediapackagev2:us-west-2:123456789012:channelGroup/MyGroup/channel/MyChannel/originEndpoint/MyEndpoint"))

The following code creates a resource policy on the origin endpoint. This will automatically create a policy on the first call:

ts
declare const origin: OriginEndpoint;

origin.addToResourcePolicy(new PolicyStatement({
    sid: 'AllowRequestsFromCloudFront',
    principals: [new ServicePrincipal('cloudfront.amazonaws.com')],
    effect: Effect.ALLOW,
    actions: ['mediapackagev2:GetHeadObject', 'mediapackagev2:GetObject'],
    resources: [origin.originEndpointArn],
    conditions: {
      StringEquals: {
        'aws:SourceArn': 'arn:aws:cloudfront::123456789012:distribution/AAAAAAAAA',
      },
    },
}));
python
# origin: OriginEndpoint


origin.add_to_resource_policy(PolicyStatement(
    sid="AllowRequestsFromCloudFront",
    principals=[ServicePrincipal("cloudfront.amazonaws.com")],
    effect=Effect.ALLOW,
    actions=["mediapackagev2:GetHeadObject", "mediapackagev2:GetObject"],
    resources=[origin.origin_endpoint_arn],
    conditions={
        "StringEquals": {
            "aws:SourceArn": "arn:aws:cloudfront::123456789012:distribution/AAAAAAAAA"
        }
    }
))
java
OriginEndpoint origin;


origin.addToResourcePolicy(PolicyStatement.Builder.create()
        .sid("AllowRequestsFromCloudFront")
        .principals(List.of(new ServicePrincipal("cloudfront.amazonaws.com")))
        .effect(Effect.ALLOW)
        .actions(List.of("mediapackagev2:GetHeadObject", "mediapackagev2:GetObject"))
        .resources(List.of(origin.getOriginEndpointArn()))
        .conditions(Map.of(
                "StringEquals", Map.of(
                        "aws:SourceArn", "arn:aws:cloudfront::123456789012:distribution/AAAAAAAAA")))
        .build());
csharp
OriginEndpoint origin;


origin.AddToResourcePolicy(new PolicyStatement(new PolicyStatementProps {
    Sid = "AllowRequestsFromCloudFront",
    Principals = new [] { new ServicePrincipal("cloudfront.amazonaws.com") },
    Effect = Effect.ALLOW,
    Actions = new [] { "mediapackagev2:GetHeadObject", "mediapackagev2:GetObject" },
    Resources = new [] { origin.OriginEndpointArn },
    Conditions = new Dictionary<string, object> {
        { "StringEquals", new Dictionary<string, string> {
            { "aws:SourceArn", "arn:aws:cloudfront::123456789012:distribution/AAAAAAAAA" }
        } }
    }
}));
go
var origin OriginEndpoint


origin.addToResourcePolicy(awscdk.NewPolicyStatement(&PolicyStatementProps{
	Sid: jsii.String("AllowRequestsFromCloudFront"),
	Principals: []IPrincipal{
		awscdk.NewServicePrincipal(jsii.String("cloudfront.amazonaws.com")),
	},
	Effect: awscdk.Effect_ALLOW,
	Actions: []*string{
		jsii.String("mediapackagev2:GetHeadObject"),
		jsii.String("mediapackagev2:GetObject"),
	},
	Resources: []*string{
		origin.OriginEndpointArn,
	},
	Conditions: map[string]interface{}{
		"StringEquals": map[string]*string{
			"aws:SourceArn": jsii.String("arn:aws:cloudfront::123456789012:distribution/AAAAAAAAA"),
		},
	},
}))

CDN Authorization ​

MediaPackage V2 supports two ways to lock an origin endpoint to your CDN:

  • AWS Signature Version 4 (SigV4) — the CDN signs requests with an IAM role. For Amazon CloudFront, see CloudFront Integration. See the SigV4 authentication guide.
  • Header-based CDN authorization — the CDN attaches a shared secret in a request header that MediaPackage validates. Use this when your CDN doesn't support SigV4. See the CDN authorization guide.

To configure header-based authorization, set cdnAuth on the OriginEndpoint props. The L2 auto-creates the endpoint policy with:

  • a PolicyStatement requiring the mediapackagev2:RequestHasMatchingCdnAuthHeader condition on every GetObject request
  • the CdnAuthConfiguration block that references the secrets and the read role

If you don't supply a role, one is created with the needed Secrets Manager and KMS permissions.

ts
import * as secretsmanager from 'aws-cdk-lib/aws-secretsmanager';

declare const channel: Channel;
declare const mySecret: secretsmanager.ISecret;

new OriginEndpoint(this, 'OriginEndpoint', {
  channel,
  segment: Segment.ts(),
  manifests: [Manifest.hls({ manifestName: 'index' })],
  cdnAuth: {
    secrets: [mySecret],
  },
});
python
from aws_cdk.aws_mediapackagev2_alpha import CdnAuthConfiguration
import aws_cdk.aws_secretsmanager as secretsmanager

# channel: Channel
# my_secret: secretsmanager.ISecret


OriginEndpoint(self, "OriginEndpoint",
    channel=channel,
    segment=Segment.ts(),
    manifests=[Manifest.hls(manifest_name="index")],
    cdn_auth=CdnAuthConfiguration(
        secrets=[my_secret]
    )
)
java
import software.amazon.awscdk.services.secretsmanager.*;

Channel channel;
ISecret mySecret;


OriginEndpoint.Builder.create(this, "OriginEndpoint")
        .channel(channel)
        .segment(Segment.ts())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .cdnAuth(CdnAuthConfiguration.builder()
                .secrets(List.of(mySecret))
                .build())
        .build();
csharp
using Amazon.CDK.AWS.SecretsManager;

Channel channel;
ISecret mySecret;


new OriginEndpoint(this, "OriginEndpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Ts(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) },
    CdnAuth = new CdnAuthConfiguration {
        Secrets = new [] { mySecret }
    }
});
go
import secretsmanager "github.com/aws/aws-cdk-go/awscdk"

var channel Channel
var mySecret ISecret


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("OriginEndpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Ts(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
	CdnAuth: &CdnAuthConfiguration{
		Secrets: []ISecret{
			mySecret,
		},
	},
})

You can still call addToResourcePolicy() to add extra statements (e.g. a harvester allow); they're appended to the auto-created policy alongside the gating statement.

Granting Permissions ​

Granting Ingest Access to MediaLive ​

To allow AWS Elemental MediaLive to ingest content into a MediaPackage channel, use the grants.ingest() method:

ts
declare const channel: Channel;
declare const mediaLiveRole: iam.IRole;

// Grant MediaLive permission to ingest content
channel.grants.ingest(mediaLiveRole);
python
# channel: Channel
# media_live_role: iam.IRole


# Grant MediaLive permission to ingest content
channel.grants.ingest(media_live_role)
java
Channel channel;
IRole mediaLiveRole;


// Grant MediaLive permission to ingest content
channel.grants.ingest(mediaLiveRole);
csharp
Channel channel;
IRole mediaLiveRole;


// Grant MediaLive permission to ingest content
channel.Grants.Ingest(mediaLiveRole);
go
var channel Channel
var mediaLiveRole IRole


// Grant MediaLive permission to ingest content
channel.grants.Ingest(mediaLiveRole)

CloudFront Integration ​

MediaPackage origin endpoints are designed to be used with Content Delivery Network (CDN) like Amazon CloudFront distributions. CloudFront provides caching, DDoS protection, and global content delivery for your streaming content.

The simplest way to connect CloudFront to a MediaPackage V2 endpoint is with MediaPackageV2Origin, which automatically creates an Origin Access Control (OAC) and wires the endpoint policy:

ts
declare const endpoint: OriginEndpoint;
declare const group: ChannelGroup;

new cloudfront.Distribution(this, 'Distribution', {
  defaultBehavior: {
    origin: new MediaPackageV2Origin(endpoint, {
      channelGroup: group,
    }),
  },
});
python
# endpoint: OriginEndpoint
# group: ChannelGroup


cloudfront.Distribution(self, "Distribution",
    default_behavior=cloudfront.BehaviorOptions(
        origin=MediaPackageV2Origin(endpoint,
            channel_group=group
        )
    )
)
java
OriginEndpoint endpoint;
ChannelGroup group;


Distribution.Builder.create(this, "Distribution")
        .defaultBehavior(BehaviorOptions.builder()
                .origin(MediaPackageV2Origin.Builder.create(endpoint)
                        .channelGroup(group)
                        .build())
                .build())
        .build();
csharp
OriginEndpoint endpoint;
ChannelGroup group;


new Distribution(this, "Distribution", new DistributionProps {
    DefaultBehavior = new BehaviorOptions {
        Origin = new MediaPackageV2Origin(endpoint, new MediaPackageV2OriginProps {
            ChannelGroup = group
        })
    }
});
go
var endpoint OriginEndpoint
var group ChannelGroup


cloudfront.NewDistribution(this, jsii.String("Distribution"), &DistributionProps{
	DefaultBehavior: &BehaviorOptions{
		Origin: awsmediapackagev2alpha.NewMediaPackageV2Origin(endpoint, &MediaPackageV2OriginProps{
			ChannelGroup: group,
		}),
	},
})

This handles OAC creation, HTTPS-only origin config, and the IAM policy granting CloudFront access to the endpoint (including GetHeadObject for MQAR support).

For more control, you can manually configure the policy and OAC:

ts
declare const originEndpoint: OriginEndpoint;
declare const distribution: cloudfront.Distribution;

originEndpoint.addToResourcePolicy(new iam.PolicyStatement({
  sid: 'AllowCloudFrontServicePrincipal',
  principals: [new iam.ServicePrincipal('cloudfront.amazonaws.com')],
  effect: iam.Effect.ALLOW,
  actions: ['mediapackagev2:GetObject', 'mediapackagev2:GetHeadObject'],
  resources: [originEndpoint.originEndpointArn],
  conditions: {
    StringEquals: {
      'aws:SourceArn': distribution.distributionArn,
    },
  },
}));
python
# origin_endpoint: OriginEndpoint
# distribution: cloudfront.Distribution


origin_endpoint.add_to_resource_policy(iam.PolicyStatement(
    sid="AllowCloudFrontServicePrincipal",
    principals=[iam.ServicePrincipal("cloudfront.amazonaws.com")],
    effect=iam.Effect.ALLOW,
    actions=["mediapackagev2:GetObject", "mediapackagev2:GetHeadObject"],
    resources=[origin_endpoint.origin_endpoint_arn],
    conditions={
        "StringEquals": {
            "aws:SourceArn": distribution.distribution_arn
        }
    }
))
java
OriginEndpoint originEndpoint;
Distribution distribution;


originEndpoint.addToResourcePolicy(PolicyStatement.Builder.create()
        .sid("AllowCloudFrontServicePrincipal")
        .principals(List.of(new ServicePrincipal("cloudfront.amazonaws.com")))
        .effect(Effect.ALLOW)
        .actions(List.of("mediapackagev2:GetObject", "mediapackagev2:GetHeadObject"))
        .resources(List.of(originEndpoint.getOriginEndpointArn()))
        .conditions(Map.of(
                "StringEquals", Map.of(
                        "aws:SourceArn", distribution.getDistributionArn())))
        .build());
csharp
OriginEndpoint originEndpoint;
Distribution distribution;


originEndpoint.AddToResourcePolicy(new PolicyStatement(new PolicyStatementProps {
    Sid = "AllowCloudFrontServicePrincipal",
    Principals = new [] { new ServicePrincipal("cloudfront.amazonaws.com") },
    Effect = Effect.ALLOW,
    Actions = new [] { "mediapackagev2:GetObject", "mediapackagev2:GetHeadObject" },
    Resources = new [] { originEndpoint.OriginEndpointArn },
    Conditions = new Dictionary<string, object> {
        { "StringEquals", new Dictionary<string, string> {
            { "aws:SourceArn", distribution.DistributionArn }
        } }
    }
}));
go
var originEndpoint OriginEndpoint
var distribution Distribution


originEndpoint.addToResourcePolicy(iam.NewPolicyStatement(&PolicyStatementProps{
	Sid: jsii.String("AllowCloudFrontServicePrincipal"),
	Principals: []IPrincipal{
		iam.NewServicePrincipal(jsii.String("cloudfront.amazonaws.com")),
	},
	Effect: iam.Effect_ALLOW,
	Actions: []*string{
		jsii.String("mediapackagev2:GetObject"),
		jsii.String("mediapackagev2:GetHeadObject"),
	},
	Resources: []*string{
		originEndpoint.OriginEndpointArn,
	},
	Conditions: map[string]interface{}{
		"StringEquals": map[string]*string{
			"aws:SourceArn": distribution.distributionArn,
		},
	},
}))

Graduation plan: MediaPackageV2Origin currently lives in this alpha module. When MediaPackage V2 graduates to stable, it will move to aws-cloudfront-origins alongside S3BucketOrigin and other origin helpers.

Manifest Configuration ​

MediaPackage V2 supports multiple manifest formats: HLS, Low-Latency HLS (LL-HLS), DASH, and Microsoft Smooth Streaming (MSS).

HLS Manifests ​

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [
    Manifest.hls({
      manifestName: 'index',
      manifestWindow: Duration.seconds(60),
      programDateTimeInterval: Duration.seconds(60),
      scteAdMarkerHls: AdMarkerHls.DATERANGE,
    }),
  ],
});
python
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[
        Manifest.hls(
            manifest_name="index",
            manifest_window=Duration.seconds(60),
            program_date_time_interval=Duration.seconds(60),
            scte_ad_marker_hls=AdMarkerHls.DATERANGE
        )
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder()
                .manifestName("index")
                .manifestWindow(Duration.seconds(60))
                .programDateTimeInterval(Duration.seconds(60))
                .scteAdMarkerHls(AdMarkerHls.DATERANGE)
                .build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration {
        ManifestName = "index",
        ManifestWindow = Duration.Seconds(60),
        ProgramDateTimeInterval = Duration.Seconds(60),
        ScteAdMarkerHls = AdMarkerHls.DATERANGE
    }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
			ManifestWindow: awscdk.Duration_Seconds(jsii.Number(60)),
			ProgramDateTimeInterval: awscdk.Duration_*Seconds(jsii.Number(60)),
			ScteAdMarkerHls: awsmediapackagev2alpha.AdMarkerHls_DATERANGE,
		}),
	},
})

Low-Latency HLS Manifests ​

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [
    Manifest.lowLatencyHLS({
      manifestName: 'index',
      manifestWindow: Duration.seconds(30),
      programDateTimeInterval: Duration.seconds(5),
      childManifestName: 'child',
    }),
  ],
});
python
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[
        Manifest.low_latency_hls(
            manifest_name="index",
            manifest_window=Duration.seconds(30),
            program_date_time_interval=Duration.seconds(5),
            child_manifest_name="child"
        )
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.lowLatencyHLS(LowLatencyHlsManifestConfiguration.builder()
                .manifestName("index")
                .manifestWindow(Duration.seconds(30))
                .programDateTimeInterval(Duration.seconds(5))
                .childManifestName("child")
                .build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.LowLatencyHLS(new LowLatencyHlsManifestConfiguration {
        ManifestName = "index",
        ManifestWindow = Duration.Seconds(30),
        ProgramDateTimeInterval = Duration.Seconds(5),
        ChildManifestName = "child"
    }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_LowLatencyHLS(&LowLatencyHlsManifestConfiguration{
			ManifestName: jsii.String("index"),
			ManifestWindow: awscdk.Duration_Seconds(jsii.Number(30)),
			ProgramDateTimeInterval: awscdk.Duration_*Seconds(jsii.Number(5)),
			ChildManifestName: jsii.String("child"),
		}),
	},
})

DASH Manifests ​

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [
    Manifest.dash({
      manifestName: 'index',
      manifestWindow: Duration.seconds(60),
      minBufferTime: Duration.seconds(30),
      minUpdatePeriod: Duration.seconds(10),
      segmentTemplateFormat: SegmentTemplateFormat.NUMBER_WITH_TIMELINE,
      periodTriggers: [
        DashPeriodTriggers.AVAILS,
        DashPeriodTriggers.DRM_KEY_ROTATION,
      ],
    }),
  ],
});
python
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[
        Manifest.dash(
            manifest_name="index",
            manifest_window=Duration.seconds(60),
            min_buffer_time=Duration.seconds(30),
            min_update_period=Duration.seconds(10),
            segment_template_format=SegmentTemplateFormat.NUMBER_WITH_TIMELINE,
            period_triggers=[DashPeriodTriggers.AVAILS, DashPeriodTriggers.DRM_KEY_ROTATION
            ]
        )
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.dash(DashManifestConfiguration.builder()
                .manifestName("index")
                .manifestWindow(Duration.seconds(60))
                .minBufferTime(Duration.seconds(30))
                .minUpdatePeriod(Duration.seconds(10))
                .segmentTemplateFormat(SegmentTemplateFormat.NUMBER_WITH_TIMELINE)
                .periodTriggers(List.of(DashPeriodTriggers.AVAILS, DashPeriodTriggers.DRM_KEY_ROTATION))
                .build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Dash(new DashManifestConfiguration {
        ManifestName = "index",
        ManifestWindow = Duration.Seconds(60),
        MinBufferTime = Duration.Seconds(30),
        MinUpdatePeriod = Duration.Seconds(10),
        SegmentTemplateFormat = SegmentTemplateFormat.NUMBER_WITH_TIMELINE,
        PeriodTriggers = new [] { DashPeriodTriggers.AVAILS, DashPeriodTriggers.DRM_KEY_ROTATION }
    }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Dash(&DashManifestConfiguration{
			ManifestName: jsii.String("index"),
			ManifestWindow: awscdk.Duration_Seconds(jsii.Number(60)),
			MinBufferTime: awscdk.Duration_*Seconds(jsii.Number(30)),
			MinUpdatePeriod: awscdk.Duration_*Seconds(jsii.Number(10)),
			SegmentTemplateFormat: awsmediapackagev2alpha.SegmentTemplateFormat_NUMBER_WITH_TIMELINE,
			PeriodTriggers: []DashPeriodTriggers{
				awsmediapackagev2alpha.DashPeriodTriggers_AVAILS,
				awsmediapackagev2alpha.DashPeriodTriggers_DRM_KEY_ROTATION,
			},
		}),
	},
})

MSS Manifests ​

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.ism(),
  manifests: [
    Manifest.mss({
      manifestName: 'index',
      manifestWindow: Duration.seconds(60),
      manifestLayout: MssManifestLayout.COMPACT,
    }),
  ],
});
python
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.ism(),
    manifests=[
        Manifest.mss(
            manifest_name="index",
            manifest_window=Duration.seconds(60),
            manifest_layout=MssManifestLayout.COMPACT
        )
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.ism())
        .manifests(List.of(Manifest.mss(MssManifestConfiguration.builder()
                .manifestName("index")
                .manifestWindow(Duration.seconds(60))
                .manifestLayout(MssManifestLayout.COMPACT)
                .build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Ism(),
    Manifests = new [] { Manifest.Mss(new MssManifestConfiguration {
        ManifestName = "index",
        ManifestWindow = Duration.Seconds(60),
        ManifestLayout = MssManifestLayout.COMPACT
    }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Ism(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Mss(&MssManifestConfiguration{
			ManifestName: jsii.String("index"),
			ManifestWindow: awscdk.Duration_Seconds(jsii.Number(60)),
			ManifestLayout: awsmediapackagev2alpha.MssManifestLayout_COMPACT,
		}),
	},
})

Multiple Manifests ​

You can configure multiple manifest formats for a single origin endpoint:

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [
    Manifest.hls({ manifestName: 'hls' }),
    Manifest.dash({ manifestName: 'dash' }),
  ],
});
python
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[
        Manifest.hls(manifest_name="hls"),
        Manifest.dash(manifest_name="dash")
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("hls").build()), Manifest.dash(DashManifestConfiguration.builder().manifestName("dash").build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "hls" }), Manifest.Dash(new DashManifestConfiguration { ManifestName = "dash" }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("hls"),
		}),
		awsmediapackagev2alpha.Manifest_Dash(&DashManifestConfiguration{
			ManifestName: jsii.String("dash"),
		}),
	},
})
Segment typeSupported manifests
Segment.cmaf()HLS, LL-HLS, DASH
Segment.ts()HLS, LL-HLS
Segment.ism()MSS

Each origin endpoint has a single segment configuration. If you need segments with different configurations, use multiple origin endpoints on the same channel.

@see https://docs.aws.amazon.com/mediapackage/latest/userguide/endpoints-create.html

Manifest Filtering ​

Manifest filters control which variants are included in the manifest. Filters are type-safe and validated against the MediaPackage manifest filtering rules.

FilterMethod
Audio / video bitratebitrate(), bitrateRange(), bitrateCombo()
Audio channels, sample rate, video height, framerate, trickplay heightnumeric(), numericList(), numericRange(), numericCombo()
Audio codecaudioCodec(), audioCodecList()
Video codecvideoCodec(), videoCodecList()
Video dynamic rangevideoDynamicRange(), videoDynamicRangeList()
Trickplay typetrickplayType(), trickplayTypeList()
Audio / subtitle languagetext(), textList()
Advanced patternscustom()

The following example creates an HD streaming endpoint that serves only H.264/H.265 content between 1–5 Mbps with stereo audio in English or French:

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [
    Manifest.hls({
      manifestName: 'index',
      filterConfiguration: {
        manifestFilter: [
          ManifestFilter.bitrateRange(BitrateFilterKey.VIDEO_BITRATE, Bitrate.mbps(1), Bitrate.mbps(5)),
          ManifestFilter.numericRange(NumericFilterKey.VIDEO_HEIGHT, 720, 1080),
          ManifestFilter.videoCodecList([VideoCodec.H264, VideoCodec.H265]),
          ManifestFilter.numeric(NumericFilterKey.AUDIO_CHANNELS, 2),
          ManifestFilter.textList(TextFilterKey.AUDIO_LANGUAGE, ['en-US', 'fr']),
        ],
        timeDelay: Duration.seconds(30),
      },
    }),
  ],
});
python
from aws_cdk.aws_mediapackagev2_alpha import FilterConfiguration
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[
        Manifest.hls(
            manifest_name="index",
            filter_configuration=FilterConfiguration(
                manifest_filter=[
                    ManifestFilter.bitrate_range(BitrateFilterKey.VIDEO_BITRATE, Bitrate.mbps(1), Bitrate.mbps(5)),
                    ManifestFilter.numeric_range(NumericFilterKey.VIDEO_HEIGHT, 720, 1080),
                    ManifestFilter.video_codec_list([VideoCodec.H264, VideoCodec.H265]),
                    ManifestFilter.numeric(NumericFilterKey.AUDIO_CHANNELS, 2),
                    ManifestFilter.text_list(TextFilterKey.AUDIO_LANGUAGE, ["en-US", "fr"])
                ],
                time_delay=Duration.seconds(30)
            )
        )
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder()
                .manifestName("index")
                .filterConfiguration(FilterConfiguration.builder()
                        .manifestFilter(List.of(ManifestFilter.bitrateRange(BitrateFilterKey.VIDEO_BITRATE, Bitrate.mbps(1), Bitrate.mbps(5)), ManifestFilter.numericRange(NumericFilterKey.VIDEO_HEIGHT, 720, 1080), ManifestFilter.videoCodecList(List.of(VideoCodec.H264, VideoCodec.H265)), ManifestFilter.numeric(NumericFilterKey.AUDIO_CHANNELS, 2), ManifestFilter.textList(TextFilterKey.AUDIO_LANGUAGE, List.of("en-US", "fr"))))
                        .timeDelay(Duration.seconds(30))
                        .build())
                .build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration {
        ManifestName = "index",
        FilterConfiguration = new FilterConfiguration {
            ManifestFilter = new [] { ManifestFilter.BitrateRange(BitrateFilterKey.VIDEO_BITRATE, Bitrate.Mbps(1), Bitrate.Mbps(5)), ManifestFilter.NumericRange(NumericFilterKey.VIDEO_HEIGHT, 720, 1080), ManifestFilter.VideoCodecList(new [] { VideoCodec.H264, VideoCodec.H265 }), ManifestFilter.Numeric(NumericFilterKey.AUDIO_CHANNELS, 2), ManifestFilter.TextList(TextFilterKey.AUDIO_LANGUAGE, new [] { "en-US", "fr" }) },
            TimeDelay = Duration.Seconds(30)
        }
    }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
			FilterConfiguration: &FilterConfiguration{
				ManifestFilter: []ManifestFilter{
					awsmediapackagev2alpha.ManifestFilter_BitrateRange(awsmediapackagev2alpha.BitrateFilterKey_VIDEO_BITRATE, awscdk.Bitrate_Mbps(jsii.Number(1)), awscdk.Bitrate_*Mbps(jsii.Number(5))),
					awsmediapackagev2alpha.ManifestFilter_NumericRange(awsmediapackagev2alpha.NumericFilterKey_VIDEO_HEIGHT, jsii.Number(720), jsii.Number(1080)),
					awsmediapackagev2alpha.ManifestFilter_VideoCodecList([]VideoCodec{
						awsmediapackagev2alpha.VideoCodec_H264,
						awsmediapackagev2alpha.VideoCodec_H265,
					}),
					awsmediapackagev2alpha.ManifestFilter_Numeric(awsmediapackagev2alpha.NumericFilterKey_AUDIO_CHANNELS, jsii.Number(2)),
					awsmediapackagev2alpha.ManifestFilter_TextList(awsmediapackagev2alpha.TextFilterKey_AUDIO_LANGUAGE, []*string{
						jsii.String("en-US"),
						jsii.String("fr"),
					}),
				},
				TimeDelay: awscdk.Duration_Seconds(jsii.Number(30)),
			},
		}),
	},
})

For advanced patterns that combine ranges and single values, use numericCombo() or bitrateCombo():

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [
    Manifest.hls({
      manifestName: 'index',
      filterConfiguration: {
        manifestFilter: [
          // video_height:240-360,720-1080,1440
          ManifestFilter.numericCombo(NumericFilterKey.VIDEO_HEIGHT, [
            NumericExpression.range(240, 360),
            NumericExpression.range(720, 1080),
            NumericExpression.value(1440),
          ]),
        ],
      },
    }),
  ],
});
python
from aws_cdk.aws_mediapackagev2_alpha import FilterConfiguration
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[
        Manifest.hls(
            manifest_name="index",
            filter_configuration=FilterConfiguration(
                manifest_filter=[
                    # video_height:240-360,720-1080,1440
                    ManifestFilter.numeric_combo(NumericFilterKey.VIDEO_HEIGHT, [
                        NumericExpression.range(240, 360),
                        NumericExpression.range(720, 1080),
                        NumericExpression.value(1440)
                    ])
                ]
            )
        )
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder()
                .manifestName("index")
                .filterConfiguration(FilterConfiguration.builder()
                        .manifestFilter(List.of(ManifestFilter.numericCombo(NumericFilterKey.VIDEO_HEIGHT, List.of(NumericExpression.range(240, 360), NumericExpression.range(720, 1080), NumericExpression.value(1440)))))
                        .build())
                .build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration {
        ManifestName = "index",
        FilterConfiguration = new FilterConfiguration {
            ManifestFilter = new [] { ManifestFilter.NumericCombo(NumericFilterKey.VIDEO_HEIGHT, new [] { NumericExpression.Range(240, 360), NumericExpression.Range(720, 1080), NumericExpression.Value(1440) }) }
        }
    }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
			FilterConfiguration: &FilterConfiguration{
				ManifestFilter: []ManifestFilter{
					awsmediapackagev2alpha.ManifestFilter_NumericCombo(awsmediapackagev2alpha.NumericFilterKey_VIDEO_HEIGHT, []NumericExpression{
						awsmediapackagev2alpha.NumericExpression_Range(jsii.Number(240), jsii.Number(360)),
						awsmediapackagev2alpha.NumericExpression_*Range(jsii.Number(720), jsii.Number(1080)),
						awsmediapackagev2alpha.NumericExpression_Value(jsii.Number(1440)),
					}),
				},
			},
		}),
	},
})

DRM Settings ​

You can exclude session keys from HLS and LL-HLS multivariant playlists using the drmSettings filter configuration. This improves compatibility with legacy HLS clients and provides more granular access control:

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [
    Manifest.hls({
      manifestName: 'index',
      filterConfiguration: {
        drmSettings: [DrmSettingsKey.EXCLUDE_SESSION_KEYS],
      },
    }),
  ],
});
python
from aws_cdk.aws_mediapackagev2_alpha import FilterConfiguration
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[
        Manifest.hls(
            manifest_name="index",
            filter_configuration=FilterConfiguration(
                drm_settings=[DrmSettingsKey.EXCLUDE_SESSION_KEYS]
            )
        )
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder()
                .manifestName("index")
                .filterConfiguration(FilterConfiguration.builder()
                        .drmSettings(List.of(DrmSettingsKey.EXCLUDE_SESSION_KEYS))
                        .build())
                .build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration {
        ManifestName = "index",
        FilterConfiguration = new FilterConfiguration {
            DrmSettings = new [] { DrmSettingsKey.EXCLUDE_SESSION_KEYS }
        }
    }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
			FilterConfiguration: &FilterConfiguration{
				DrmSettings: []eXCLUDE_SESSION_KEYS{
					awsmediapackagev2alpha.DrmSettingsKey_*eXCLUDE_SESSION_KEYS,
				},
			},
		}),
	},
})

Start Tag Configuration ​

Configure where playback should start in HLS and LL-HLS manifests using the EXT-X-START tag:

ts
declare const channel: Channel;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [
    Manifest.hls({
      manifestName: 'index',
      startTag: StartTag.of(10),
    }),
  ],
});
python
# channel: Channel


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[
        Manifest.hls(
            manifest_name="index",
            start_tag=StartTag.of(10)
        )
    ]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder()
                .manifestName("index")
                .startTag(StartTag.of(10))
                .build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration {
        ManifestName = "index",
        StartTag = StartTag.Of(10)
    }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
			StartTag: awsmediapackagev2alpha.StartTag_Of(jsii.Number(10)),
		}),
	},
})

Segment Configuration ​

Configure segment settings for your origin endpoint.

ts
declare const channel: Channel;

new OriginEndpoint(this, 'TsEndpoint', {
  channel,
  segment: Segment.ts({
    duration: Duration.seconds(6),
    name: 'segment',
    includeDvbSubtitles: true,
    useAudioRenditionGroup: true,
    includeIframeOnlyStreams: false,
    scteFilter: [
      ScteMessageType.BREAK,
      ScteMessageType.DISTRIBUTOR_ADVERTISEMENT,
    ],
  }),
  manifests: [Manifest.hls({ manifestName: 'index' })],
});

new OriginEndpoint(this, 'CmafEndpoint', {
  channel,
  segment: Segment.cmaf({
    duration: Duration.seconds(6),
    name: 'segment',
    includeIframeOnlyStreams: true,
    scteFilter: [ScteMessageType.DISTRIBUTOR_ADVERTISEMENT],
  }),
  manifests: [Manifest.hls({ manifestName: 'index' })],
});

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf(),
  manifests: [Manifest.hls({ manifestName: 'index' })],
});
python
# channel: Channel


OriginEndpoint(self, "TsEndpoint",
    channel=channel,
    segment=Segment.ts(
        duration=Duration.seconds(6),
        name="segment",
        include_dvb_subtitles=True,
        use_audio_rendition_group=True,
        include_iframe_only_streams=False,
        scte_filter=[ScteMessageType.BREAK, ScteMessageType.DISTRIBUTOR_ADVERTISEMENT
        ]
    ),
    manifests=[Manifest.hls(manifest_name="index")]
)

OriginEndpoint(self, "CmafEndpoint",
    channel=channel,
    segment=Segment.cmaf(
        duration=Duration.seconds(6),
        name="segment",
        include_iframe_only_streams=True,
        scte_filter=[ScteMessageType.DISTRIBUTOR_ADVERTISEMENT]
    ),
    manifests=[Manifest.hls(manifest_name="index")]
)

OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(),
    manifests=[Manifest.hls(manifest_name="index")]
)
java
Channel channel;


OriginEndpoint.Builder.create(this, "TsEndpoint")
        .channel(channel)
        .segment(Segment.ts(TsSegmentProps.builder()
                .duration(Duration.seconds(6))
                .name("segment")
                .includeDvbSubtitles(true)
                .useAudioRenditionGroup(true)
                .includeIframeOnlyStreams(false)
                .scteFilter(List.of(ScteMessageType.BREAK, ScteMessageType.DISTRIBUTOR_ADVERTISEMENT))
                .build()))
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .build();

OriginEndpoint.Builder.create(this, "CmafEndpoint")
        .channel(channel)
        .segment(Segment.cmaf(CmafSegmentProps.builder()
                .duration(Duration.seconds(6))
                .name("segment")
                .includeIframeOnlyStreams(true)
                .scteFilter(List.of(ScteMessageType.DISTRIBUTOR_ADVERTISEMENT))
                .build()))
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .build();

OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf())
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .build();
csharp
Channel channel;


new OriginEndpoint(this, "TsEndpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Ts(new TsSegmentProps {
        Duration = Duration.Seconds(6),
        Name = "segment",
        IncludeDvbSubtitles = true,
        UseAudioRenditionGroup = true,
        IncludeIframeOnlyStreams = false,
        ScteFilter = new [] { ScteMessageType.BREAK, ScteMessageType.DISTRIBUTOR_ADVERTISEMENT }
    }),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) }
});

new OriginEndpoint(this, "CmafEndpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(new CmafSegmentProps {
        Duration = Duration.Seconds(6),
        Name = "segment",
        IncludeIframeOnlyStreams = true,
        ScteFilter = new [] { ScteMessageType.DISTRIBUTOR_ADVERTISEMENT }
    }),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) }
});

new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) }
});
go
var channel Channel


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("TsEndpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Ts(&TsSegmentProps{
		Duration: awscdk.Duration_Seconds(jsii.Number(6)),
		Name: jsii.String("segment"),
		IncludeDvbSubtitles: jsii.Boolean(true),
		UseAudioRenditionGroup: jsii.Boolean(true),
		IncludeIframeOnlyStreams: jsii.Boolean(false),
		ScteFilter: []ScteMessageType{
			awsmediapackagev2alpha.ScteMessageType_BREAK,
			awsmediapackagev2alpha.ScteMessageType_DISTRIBUTOR_ADVERTISEMENT,
		},
	}),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("CmafEndpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(&CmafSegmentProps{
		Duration: awscdk.Duration_*Seconds(jsii.Number(6)),
		Name: jsii.String("segment"),
		IncludeIframeOnlyStreams: jsii.Boolean(true),
		ScteFilter: []ScteMessageType{
			awsmediapackagev2alpha.ScteMessageType_DISTRIBUTOR_ADVERTISEMENT,
		},
	}),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_*Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_*Cmaf(),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_*Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

Encryption and DRM ​

Protect your content with encryption using SPEKE (Secure Packager and Encoder Key Exchange). Each container type has its own encryption class with type-safe options:

CMAF Encryption ​

ts
declare const channel: Channel;
declare const spekeRole: iam.IRole;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf({
    encryption: CmafEncryption.speke({
      method: CmafEncryptionMethod.CBCS,
      drmSystems: [CmafDrmSystem.FAIRPLAY, CmafDrmSystem.WIDEVINE],
      resourceId: 'my-content-id',
      url: 'https://example.com/speke',
      role: spekeRole,
      keyRotationInterval: Duration.seconds(300),
      audioPreset: PresetSpeke20Audio.PRESET_AUDIO_2,
      videoPreset: PresetSpeke20Video.PRESET_VIDEO_2,
    }),
  }),
  manifests: [Manifest.hls({ manifestName: 'index' })],
});
python
# channel: Channel
# speke_role: iam.IRole


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(
        encryption=CmafEncryption.speke(
            method=CmafEncryptionMethod.CBCS,
            drm_systems=[CmafDrmSystem.FAIRPLAY, CmafDrmSystem.WIDEVINE],
            resource_id="my-content-id",
            url="https://example.com/speke",
            role=speke_role,
            key_rotation_interval=Duration.seconds(300),
            audio_preset=PresetSpeke20Audio.PRESET_AUDIO_2,
            video_preset=PresetSpeke20Video.PRESET_VIDEO_2
        )
    ),
    manifests=[Manifest.hls(manifest_name="index")]
)
java
Channel channel;
IRole spekeRole;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf(CmafSegmentProps.builder()
                .encryption(CmafEncryption.speke(CmafSpekeEncryptionProps.builder()
                        .method(CmafEncryptionMethod.CBCS)
                        .drmSystems(List.of(CmafDrmSystem.FAIRPLAY, CmafDrmSystem.WIDEVINE))
                        .resourceId("my-content-id")
                        .url("https://example.com/speke")
                        .role(spekeRole)
                        .keyRotationInterval(Duration.seconds(300))
                        .audioPreset(PresetSpeke20Audio.PRESET_AUDIO_2)
                        .videoPreset(PresetSpeke20Video.PRESET_VIDEO_2)
                        .build()))
                .build()))
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .build();
csharp
Channel channel;
IRole spekeRole;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(new CmafSegmentProps {
        Encryption = CmafEncryption.Speke(new CmafSpekeEncryptionProps {
            Method = CmafEncryptionMethod.CBCS,
            DrmSystems = new [] { CmafDrmSystem.FAIRPLAY, CmafDrmSystem.WIDEVINE },
            ResourceId = "my-content-id",
            Url = "https://example.com/speke",
            Role = spekeRole,
            KeyRotationInterval = Duration.Seconds(300),
            AudioPreset = PresetSpeke20Audio.PRESET_AUDIO_2,
            VideoPreset = PresetSpeke20Video.PRESET_VIDEO_2
        })
    }),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) }
});
go
var channel Channel
var spekeRole IRole


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(&CmafSegmentProps{
		Encryption: awsmediapackagev2alpha.CmafEncryption_Speke(&CmafSpekeEncryptionProps{
			Method: awsmediapackagev2alpha.CmafEncryptionMethod_CBCS,
			DrmSystems: []CmafDrmSystem{
				awsmediapackagev2alpha.CmafDrmSystem_FAIRPLAY,
				awsmediapackagev2alpha.CmafDrmSystem_WIDEVINE,
			},
			ResourceId: jsii.String("my-content-id"),
			Url: jsii.String("https://example.com/speke"),
			Role: spekeRole,
			KeyRotationInterval: awscdk.Duration_Seconds(jsii.Number(300)),
			AudioPreset: awsmediapackagev2alpha.PresetSpeke20Audio_PRESET_AUDIO_2,
			VideoPreset: awsmediapackagev2alpha.PresetSpeke20Video_PRESET_VIDEO_2,
		}),
	}),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

TS Encryption ​

ts
declare const channel: Channel;
declare const spekeRole: iam.IRole;

new OriginEndpoint(this, 'TsEndpoint', {
  channel,
  segment: Segment.ts({
    encryption: TsEncryption.speke({
      method: TsEncryptionMethod.SAMPLE_AES,
      resourceId: 'my-content-id',
      url: 'https://example.com/speke',
      role: spekeRole,
    }),
  }),
  manifests: [Manifest.hls({ manifestName: 'index' })],
});
python
# channel: Channel
# speke_role: iam.IRole


OriginEndpoint(self, "TsEndpoint",
    channel=channel,
    segment=Segment.ts(
        encryption=TsEncryption.speke(
            method=TsEncryptionMethod.SAMPLE_AES,
            resource_id="my-content-id",
            url="https://example.com/speke",
            role=speke_role
        )
    ),
    manifests=[Manifest.hls(manifest_name="index")]
)
java
Channel channel;
IRole spekeRole;


OriginEndpoint.Builder.create(this, "TsEndpoint")
        .channel(channel)
        .segment(Segment.ts(TsSegmentProps.builder()
                .encryption(TsEncryption.speke(TsSpekeEncryptionProps.builder()
                        .method(TsEncryptionMethod.SAMPLE_AES)
                        .resourceId("my-content-id")
                        .url("https://example.com/speke")
                        .role(spekeRole)
                        .build()))
                .build()))
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .build();
csharp
Channel channel;
IRole spekeRole;


new OriginEndpoint(this, "TsEndpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Ts(new TsSegmentProps {
        Encryption = TsEncryption.Speke(new TsSpekeEncryptionProps {
            Method = TsEncryptionMethod.SAMPLE_AES,
            ResourceId = "my-content-id",
            Url = "https://example.com/speke",
            Role = spekeRole
        })
    }),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) }
});
go
var channel Channel
var spekeRole IRole


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("TsEndpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Ts(&TsSegmentProps{
		Encryption: awsmediapackagev2alpha.TsEncryption_Speke(&TsSpekeEncryptionProps{
			Method: awsmediapackagev2alpha.TsEncryptionMethod_SAMPLE_AES,
			ResourceId: jsii.String("my-content-id"),
			Url: jsii.String("https://example.com/speke"),
			Role: spekeRole,
		}),
	}),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

TS encryption defaults the DRM system based on the method: FairPlay for SAMPLE_AES, Clear Key AES 128 for AES_128. You can override this with the drmSystems property using TsDrmSystem.

Content Key Encryption ​

You can add content key encryption by providing a certificate imported into AWS Certificate Manager. Your DRM key provider must support content key encryption for this to work:

ts
declare const channel: Channel;
declare const spekeRole: iam.IRole;
declare const certificate: certificatemanager.ICertificate;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf({
    encryption: CmafEncryption.speke({
      method: CmafEncryptionMethod.CBCS,
      drmSystems: [CmafDrmSystem.FAIRPLAY],
      resourceId: 'my-content-id',
      url: 'https://example.com/speke',
      role: spekeRole,
      certificate,
    }),
  }),
  manifests: [Manifest.hls({ manifestName: 'index' })],
});
python
# channel: Channel
# speke_role: iam.IRole
# certificate: certificatemanager.ICertificate


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(
        encryption=CmafEncryption.speke(
            method=CmafEncryptionMethod.CBCS,
            drm_systems=[CmafDrmSystem.FAIRPLAY],
            resource_id="my-content-id",
            url="https://example.com/speke",
            role=speke_role,
            certificate=certificate
        )
    ),
    manifests=[Manifest.hls(manifest_name="index")]
)
java
Channel channel;
IRole spekeRole;
ICertificate certificate;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf(CmafSegmentProps.builder()
                .encryption(CmafEncryption.speke(CmafSpekeEncryptionProps.builder()
                        .method(CmafEncryptionMethod.CBCS)
                        .drmSystems(List.of(CmafDrmSystem.FAIRPLAY))
                        .resourceId("my-content-id")
                        .url("https://example.com/speke")
                        .role(spekeRole)
                        .certificate(certificate)
                        .build()))
                .build()))
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .build();
csharp
Channel channel;
IRole spekeRole;
ICertificate certificate;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(new CmafSegmentProps {
        Encryption = CmafEncryption.Speke(new CmafSpekeEncryptionProps {
            Method = CmafEncryptionMethod.CBCS,
            DrmSystems = new [] { CmafDrmSystem.FAIRPLAY },
            ResourceId = "my-content-id",
            Url = "https://example.com/speke",
            Role = spekeRole,
            Certificate = certificate
        })
    }),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) }
});
go
var channel Channel
var spekeRole IRole
var certificate ICertificate


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(&CmafSegmentProps{
		Encryption: awsmediapackagev2alpha.CmafEncryption_Speke(&CmafSpekeEncryptionProps{
			Method: awsmediapackagev2alpha.CmafEncryptionMethod_CBCS,
			DrmSystems: []CmafDrmSystem{
				awsmediapackagev2alpha.CmafDrmSystem_FAIRPLAY,
			},
			ResourceId: jsii.String("my-content-id"),
			Url: jsii.String("https://example.com/speke"),
			Role: spekeRole,
			Certificate: *Certificate,
		}),
	}),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

Excluding Segment DRM Metadata ​

For CMAF content, you can exclude DRM metadata from segments:

ts
declare const channel: Channel;
declare const spekeRole: iam.IRole;

new OriginEndpoint(this, 'Endpoint', {
  channel,
  segment: Segment.cmaf({
    encryption: CmafEncryption.speke({
      method: CmafEncryptionMethod.CBCS,
      drmSystems: [CmafDrmSystem.FAIRPLAY],
      resourceId: 'my-content-id',
      url: 'https://example.com/speke',
      role: spekeRole,
      excludeSegmentDrmMetadata: true,
    }),
  }),
  manifests: [Manifest.hls({ manifestName: 'index' })],
});
python
# channel: Channel
# speke_role: iam.IRole


OriginEndpoint(self, "Endpoint",
    channel=channel,
    segment=Segment.cmaf(
        encryption=CmafEncryption.speke(
            method=CmafEncryptionMethod.CBCS,
            drm_systems=[CmafDrmSystem.FAIRPLAY],
            resource_id="my-content-id",
            url="https://example.com/speke",
            role=speke_role,
            exclude_segment_drm_metadata=True
        )
    ),
    manifests=[Manifest.hls(manifest_name="index")]
)
java
Channel channel;
IRole spekeRole;


OriginEndpoint.Builder.create(this, "Endpoint")
        .channel(channel)
        .segment(Segment.cmaf(CmafSegmentProps.builder()
                .encryption(CmafEncryption.speke(CmafSpekeEncryptionProps.builder()
                        .method(CmafEncryptionMethod.CBCS)
                        .drmSystems(List.of(CmafDrmSystem.FAIRPLAY))
                        .resourceId("my-content-id")
                        .url("https://example.com/speke")
                        .role(spekeRole)
                        .excludeSegmentDrmMetadata(true)
                        .build()))
                .build()))
        .manifests(List.of(Manifest.hls(HlsManifestConfiguration.builder().manifestName("index").build())))
        .build();
csharp
Channel channel;
IRole spekeRole;


new OriginEndpoint(this, "Endpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Cmaf(new CmafSegmentProps {
        Encryption = CmafEncryption.Speke(new CmafSpekeEncryptionProps {
            Method = CmafEncryptionMethod.CBCS,
            DrmSystems = new [] { CmafDrmSystem.FAIRPLAY },
            ResourceId = "my-content-id",
            Url = "https://example.com/speke",
            Role = spekeRole,
            ExcludeSegmentDrmMetadata = true
        })
    }),
    Manifests = new [] { Manifest.Hls(new HlsManifestConfiguration { ManifestName = "index" }) }
});
go
var channel Channel
var spekeRole IRole


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("Endpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Cmaf(&CmafSegmentProps{
		Encryption: awsmediapackagev2alpha.CmafEncryption_Speke(&CmafSpekeEncryptionProps{
			Method: awsmediapackagev2alpha.CmafEncryptionMethod_CBCS,
			DrmSystems: []CmafDrmSystem{
				awsmediapackagev2alpha.CmafDrmSystem_FAIRPLAY,
			},
			ResourceId: jsii.String("my-content-id"),
			Url: jsii.String("https://example.com/speke"),
			Role: spekeRole,
			ExcludeSegmentDrmMetadata: jsii.Boolean(true),
		}),
	}),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Hls(&HlsManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

ISM (Smooth Streaming) Encryption ​

ISM endpoints use CENC encryption with PlayReady. Audio and video presets are always SHARED, and key rotation is not supported. The DRM system defaults to PlayReady:

ts
declare const channel: Channel;
declare const spekeRole: iam.IRole;

new OriginEndpoint(this, 'IsmEndpoint', {
  channel,
  segment: Segment.ism({
    encryption: IsmEncryption.speke({
      resourceId: 'my-content-id',
      url: 'https://example.com/speke',
      role: spekeRole,
    }),
  }),
  manifests: [Manifest.mss({ manifestName: 'index' })],
});
python
# channel: Channel
# speke_role: iam.IRole


OriginEndpoint(self, "IsmEndpoint",
    channel=channel,
    segment=Segment.ism(
        encryption=IsmEncryption.speke(
            resource_id="my-content-id",
            url="https://example.com/speke",
            role=speke_role
        )
    ),
    manifests=[Manifest.mss(manifest_name="index")]
)
java
Channel channel;
IRole spekeRole;


OriginEndpoint.Builder.create(this, "IsmEndpoint")
        .channel(channel)
        .segment(Segment.ism(IsmSegmentProps.builder()
                .encryption(IsmEncryption.speke(IsmSpekeEncryptionProps.builder()
                        .resourceId("my-content-id")
                        .url("https://example.com/speke")
                        .role(spekeRole)
                        .build()))
                .build()))
        .manifests(List.of(Manifest.mss(MssManifestConfiguration.builder().manifestName("index").build())))
        .build();
csharp
Channel channel;
IRole spekeRole;


new OriginEndpoint(this, "IsmEndpoint", new OriginEndpointProps {
    Channel = channel,
    Segment = Segment.Ism(new IsmSegmentProps {
        Encryption = IsmEncryption.Speke(new IsmSpekeEncryptionProps {
            ResourceId = "my-content-id",
            Url = "https://example.com/speke",
            Role = spekeRole
        })
    }),
    Manifests = new [] { Manifest.Mss(new MssManifestConfiguration { ManifestName = "index" }) }
});
go
var channel Channel
var spekeRole IRole


awsmediapackagev2alpha.NewOriginEndpoint(this, jsii.String("IsmEndpoint"), &OriginEndpointProps{
	Channel: Channel,
	Segment: awsmediapackagev2alpha.Segment_Ism(&IsmSegmentProps{
		Encryption: awsmediapackagev2alpha.IsmEncryption_Speke(&IsmSpekeEncryptionProps{
			ResourceId: jsii.String("my-content-id"),
			Url: jsii.String("https://example.com/speke"),
			Role: spekeRole,
		}),
	}),
	Manifests: []Manifest{
		awsmediapackagev2alpha.Manifest_Mss(&MssManifestConfiguration{
			ManifestName: jsii.String("index"),
		}),
	},
})

CloudWatch Metrics ​

MediaPackage V2 resources expose CloudWatch metrics for monitoring. You can create alarms and dashboards using these metrics:

ts
declare const channelGroup: ChannelGroup;
declare const channel: Channel;
declare const endpoint: OriginEndpoint;

// Create a CloudWatch alarm on channel group egress bytes
const alarm = channelGroup.metricEgressBytes().createAlarm(this, 'HighEgress', {
  threshold: 1000,
  evaluationPeriods: 1,
});

// Monitor channel ingress response time
channel.metricIngressResponseTime().createAlarm(this, 'SlowIngress', {
  threshold: 1000,
  evaluationPeriods: 2,
});

// Track origin endpoint request count
const requestMetric = endpoint.metricEgressRequestCount({
  statistic: 'sum',
  period: Duration.minutes(5),
});
python
# channel_group: ChannelGroup
# channel: Channel
# endpoint: OriginEndpoint


# Create a CloudWatch alarm on channel group egress bytes
alarm = channel_group.metric_egress_bytes().create_alarm(self, "HighEgress",
    threshold=1000,
    evaluation_periods=1
)

# Monitor channel ingress response time
channel.metric_ingress_response_time().create_alarm(self, "SlowIngress",
    threshold=1000,
    evaluation_periods=2
)

# Track origin endpoint request count
request_metric = endpoint.metric_egress_request_count(
    statistic="sum",
    period=Duration.minutes(5)
)
java
ChannelGroup channelGroup;
Channel channel;
OriginEndpoint endpoint;


// Create a CloudWatch alarm on channel group egress bytes
Alarm alarm = channelGroup.metricEgressBytes().createAlarm(this, "HighEgress", CreateAlarmOptions.builder()
        .threshold(1000)
        .evaluationPeriods(1)
        .build());

// Monitor channel ingress response time
channel.metricIngressResponseTime().createAlarm(this, "SlowIngress", CreateAlarmOptions.builder()
        .threshold(1000)
        .evaluationPeriods(2)
        .build());

// Track origin endpoint request count
Metric requestMetric = endpoint.metricEgressRequestCount(MetricOptions.builder()
        .statistic("sum")
        .period(Duration.minutes(5))
        .build());
csharp
ChannelGroup channelGroup;
Channel channel;
OriginEndpoint endpoint;


// Create a CloudWatch alarm on channel group egress bytes
var alarm = channelGroup.MetricEgressBytes().CreateAlarm(this, "HighEgress", new CreateAlarmOptions {
    Threshold = 1000,
    EvaluationPeriods = 1
});

// Monitor channel ingress response time
channel.MetricIngressResponseTime().CreateAlarm(this, "SlowIngress", new CreateAlarmOptions {
    Threshold = 1000,
    EvaluationPeriods = 2
});

// Track origin endpoint request count
var requestMetric = endpoint.MetricEgressRequestCount(new MetricOptions {
    Statistic = "sum",
    Period = Duration.Minutes(5)
});
go
var channelGroup ChannelGroup
var channel Channel
var endpoint OriginEndpoint


// Create a CloudWatch alarm on channel group egress bytes
alarm := channelGroup.metricEgressBytes().CreateAlarm(this, jsii.String("HighEgress"), &CreateAlarmOptions{
	Threshold: jsii.Number(1000),
	EvaluationPeriods: jsii.Number(1),
})

// Monitor channel ingress response time
channel.metricIngressResponseTime().CreateAlarm(this, jsii.String("SlowIngress"), &CreateAlarmOptions{
	Threshold: jsii.Number(1000),
	EvaluationPeriods: jsii.Number(2),
})

// Track origin endpoint request count
requestMetric := endpoint.metricEgressRequestCount(&MetricOptions{
	Statistic: jsii.String("sum"),
	Period: awscdk.Duration_Minutes(jsii.Number(5)),
})

Available metrics include:

  • metricIngressBytes() - Bytes ingested
  • metricEgressBytes() - Bytes delivered
  • metricIngressResponseTime() - Ingress response time (average)
  • metricEgressResponseTime() - Egress response time (average)
  • metricIngressRequestCount() - Number of ingress requests
  • metricEgressRequestCount() - Number of egress requests

All metrics support standard CloudWatch metric options for customizing period, statistic, and dimensions.

Types ​

NameKindSummary
ChannelConstruct (L2)Defines an AWS Elemental MediaPackage V2 Channel.
ChannelGroupConstruct (L2)Defines an AWS Elemental MediaPackage V2 Channel Group.
ChannelPolicyConstruct (L2)The channel policy for an AWS Elemental MediaPackage V2 channel.
OriginEndpointConstruct (L2)Defines an AWS Elemental MediaPackage V2 Origin Endpoint.
OriginEndpointPolicyConstruct (L2)The origin endpoint policy for an AWS Elemental MediaPackage V2 Origin Endpoint.
AdMarkerDashEnumChoose how ad markers are included in the packaged content.
AdMarkerHlsEnumChoose how SCTE-35 ad markers are included in HLS and LL-HLS manifests.
AudioCodecEnumAccepted audio codec values for manifest filtering.
BitrateExpressionClassRepresents a bitrate filter expression segment — either a single value or a range.
BitrateFilterKeyEnumBitrate manifest filter keys.
CdnAuthConfigurationStructOptions for configuring CDN Authorization Configuration.
ChannelAttributesStructRepresents a Channel defined outside of this stack.
ChannelGrantsFacadeCollection of grant methods for a IChannelRef.
ChannelGroupAttributesStructAttributes to enable import of a Channel Group, which in turn can be used to create a Channel and OriginEndpoint).
ChannelGroupPropsStructProperties for the Channel Group.
ChannelOptionsStructConfiguration options for an AWS Elemental MediaPackage V2 Channel.
ChannelPolicyPropsStructProperties for the Channel Policy.
ChannelPropsStructProperties to set on a Channel.
CmafDrmSystemEnumDRM systems available for CMAF encryption.
CmafEncryptionClassEncryption configuration for CMAF segments.
CmafEncryptionMethodEnumEncryption methods for CMAF container type.
CmafInputPropsStructProperties for CMAF input configuration.
CmafSegmentPropsStructProperties for CMAF segment configuration.
CmafSpekeEncryptionPropsStructProperties for CMAF SPEKE encryption configuration.
ContainerTypeEnumThe type of container to attach to this origin endpoint.
DashBaseUrlPropertyStructThe base URLs to use for retrieving segments.
DashDvbFontDownloadStructFor use with DVB-DASH profiles only.
DashDvbMetricsReportingStructFor use with DVB-DASH profiles only.
DashDvbSettingsStructThe font download and error reporting information that you want MediaPackage to pass through to the manifest.
DashManifestCompactnessEnumSTANDARD indicates a default manifest, which is compacted.
DashManifestConfigurationStructThe DASH manifest configuration associated with the origin endpoint.
DashPeriodTriggersEnumOptions for triggers which cause AWS Elemental MediaPackage to create media presentation description (MPD) periods in the output manifest.
DashProgramInformationStructDetails about the content that you want MediaPackage to pass through in the manifest to the playback device.
DashSubtitleConfigurationStructConfiguration for subtitles in DASH manifests.
DashTtmlConfigurationStructConfiguration for TTML subtitles in DASH manifests.
DashUtcTimingModeEnumThe UTC timing mode for DASH.
DrmSettingsKeyEnumDRM settings keys for manifest filter configuration.
DrmSignallingEnumDRM signaling determines the way DASH manifest signals the DRM content.
EncryptionConfigurationClassBase class for encryption configurations.
EndpointErrorConfigurationEnumEndpoint error configuration options.
FilterConfigurationStructFilter configuration includes settings for manifest filtering, start and end times, and time delay that apply to all of your egress requests for this manifest.
HeadersCMSDClassThe settings for what common media server data (CMSD) headers AWS Elemental MediaPackage includes in responses to the CDN.
HlsManifestConfigurationStructThe HLS manifest configuration associated with the origin endpoint.
IChannelInterfaceRepresents a MediaPackage V2 Channel.
IChannelGroupInterfaceInterface for AWS Elemental MediaPackage V2 Channel Group.
IngestEndpointEnumIngest Endpoint options.
InputConfigurationClassInput configuration for a MediaPackage V2 Channel.
InputSwitchConfigurationStructInput Switch Configuration.
InputTypeEnumThe input type will be an immutable field which will be used to define whether the channel will allow CMAF ingest or HLS ingest.
IOriginEndpointInterfaceOrigin Endpoint interface.
IsmDrmSystemEnumDRM systems available for ISM encryption.
IsmEncryptionClassEncryption configuration for ISM (Microsoft Smooth Streaming) segments.
IsmSegmentPropsStructProperties for ISM (Microsoft Smooth Streaming) segment configuration.
IsmSpekeEncryptionPropsStructProperties for ISM SPEKE encryption configuration.
LowLatencyHlsManifestConfigurationStructSpecify a low-latency HTTP live streaming (LL-HLS) manifest configuration.
ManifestClassManifest to add to Origin Endpoint.
ManifestFilterClassEnables you to create filters for your Origin Endpoint.
MediaPackageV2OriginClassA CloudFront Origin for AWS Elemental MediaPackage V2 endpoints.
MediaPackageV2OriginPropsStructProperties for a MediaPackage V2 Origin with OAC.
MssManifestConfigurationStructThe MSS manifest configuration associated with the origin endpoint.
MssManifestLayoutEnumThe layout of the MSS manifest.
NumericExpressionClassRepresents a numeric filter expression segment — either a single value or a range.
NumericFilterKeyEnumNumeric manifest filter keys.
OriginEndpointAttributesStructRepresents an Origin Endpoint defined outside of this stack.
OriginEndpointOptionsStructConfiguration parameters for an AWS Elemental MediaPackage V2 Origin Endpoint.
OriginEndpointPolicyPropsStructProperties for Origin Endpoint policy.
OriginEndpointPropsStructProperties to set on an Origin Endpoint.
PresetSpeke20AudioEnumA collection of audio encryption presets.
PresetSpeke20VideoEnumThe SPEKE Version 2.0 preset video associated with the encryption contract configuration of the origin endpoint.
ScteInSegmentsEnumControls whether SCTE-35 messages are included in segment files.
ScteMessageTypeEnumSCTE-35 message type options available.
SegmentClassHelper class for creating segment configurations.
SegmentConfigurationStructThe segment configuration, including the segment name, duration, and other configuration values.
SegmentPropsBaseStructBase properties common to all segment configurations.
SegmentTemplateFormatEnumThe type of variable that MediaPackage uses in the media attribute of the SegmentTemplate tag.
StartTagClassHelper class for creating EXT-X-START tags in HLS playlists.
StartTagOptionsStructOptions for configuring a StartTag.
TextFilterKeyEnumText manifest filter keys for free-form string values.
TrickplayTypeEnumAccepted trickplay type values for manifest filtering.
TsDrmSystemEnumDRM systems available for TS encryption.
TsEncryptionClassEncryption configuration for TS segments.
TsEncryptionMethodEnumEncryption methods for TS container type.
TsSegmentPropsStructProperties for TS (Transport Stream) segment configuration.
TsSpekeEncryptionPropsStructProperties for TS SPEKE encryption configuration.
TtmlProfileEnumOptions for TTML Profile.
VideoCodecEnumAccepted video codec values for manifest filtering.
VideoDynamicRangeEnumAccepted video dynamic range values for manifest filtering.