Skip to content
v2.277.0

Experimental

@aws-cdk/aws-mediapackagev2-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.

InputConfiguration Class ​

Input configuration for a MediaPackage V2 Channel.

Use the static factory methods to create instances:

  • InputConfiguration.hls() for HLS input
  • InputConfiguration.cmaf() for CMAF input with optional CMAF-specific features

Example ​

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
// Install: dotnet add package Amazon.CDK.AWS.MediaPackageV2.Alpha
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
// Install: go get github.com/aws/aws-cdk-go/awsmediapackagev2alpha/v2
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"),
		}),
	},
})

Properties ​

inputSwitchConfigurationmay be undefinedInputSwitchConfigurationinput_switch_configurationmay be undefinedInputSwitchConfigurationinputSwitchConfigurationmay be undefinedInputSwitchConfigurationInputSwitchConfigurationmay be undefinedInputSwitchConfigurationInputSwitchConfigurationmay be undefinedInputSwitchConfiguration#
Input switch configuration (CMAF only).
inputTypeInputTypeinput_typeInputTypeinputTypeInputTypeInputTypeInputTypeInputTypeInputType#
The input type (HLS or CMAF).
outputHeadersmay be undefinedHeadersCMSD[]output_headersmay be undefinedtyping.List[HeadersCMSD]outputHeadersmay be undefinedList<HeadersCMSD>OutputHeadersmay be undefinedHeadersCMSD[]OutputHeadersmay be undefined*[]HeadersCMSD#
Output headers configuration (CMAF only).

Methods ​

cmaf(props?: CmafInputProps): InputConfiguration // chainable@staticmethod def cmaf(props: typing.Optional[CmafInputProps] = None) -> InputConfigurationpublic static InputConfiguration cmaf(CmafInputProps props)public static InputConfiguration Cmaf(CmafInputProps? props = null)func Cmaf(Props CmafInputProps) InputConfigurationstatic#
Create a CMAF input configuration.
1 parameter

Parameters

  • propspropspropspropsProps — CMAF-specific configuration including input switching and output headers.
hls(): InputConfiguration // chainable@staticmethod def hls() -> InputConfigurationpublic static InputConfiguration hls()public static InputConfiguration Hls()func Hls() InputConfigurationstatic#
Create an HLS input configuration.