From 13bec3bce60c5d5434070c1ab67e12aedb8e25d0 Mon Sep 17 00:00:00 2001 From: awstools Date: Fri, 7 Jul 2023 18:16:09 +0000 Subject: [PATCH] feat(client-mediatailor): The AWS Elemental MediaTailor SDK for Channel Assembly has added support for EXT-X-CUE-OUT and EXT-X-CUE-IN tags to specify ad breaks in HLS outputs, including support for EXT-OATCLS, EXT-X-ASSET, and EXT-X-CUE-OUT-CONT accessory tags. --- .../src/commands/CreateChannelCommand.ts | 6 + .../src/commands/CreateProgramCommand.ts | 12 ++ .../src/commands/DescribeChannelCommand.ts | 3 + .../src/commands/DescribeProgramCommand.ts | 6 + .../src/commands/ListChannelsCommand.ts | 3 + .../src/commands/UpdateChannelCommand.ts | 6 + .../src/commands/UpdateProgramCommand.ts | 12 ++ .../client-mediatailor/src/models/models_0.ts | 40 ++++++ .../src/protocols/Aws_restJson1.ts | 14 ++ .../sdk-codegen/aws-models/mediatailor.json | 129 ++++++++++++++++-- 10 files changed, 217 insertions(+), 14 deletions(-) diff --git a/clients/client-mediatailor/src/commands/CreateChannelCommand.ts b/clients/client-mediatailor/src/commands/CreateChannelCommand.ts index 91dccba7d7ed..5451c45e82d2 100644 --- a/clients/client-mediatailor/src/commands/CreateChannelCommand.ts +++ b/clients/client-mediatailor/src/commands/CreateChannelCommand.ts @@ -59,6 +59,9 @@ export interface CreateChannelCommandOutput extends CreateChannelResponse, __Met * }, * HlsPlaylistSettings: { // HlsPlaylistSettings * ManifestWindowSeconds: Number("int"), + * AdMarkupType: [ // adMarkupTypes + * "DATERANGE" || "SCTE35_ENHANCED", + * ], * }, * ManifestName: "STRING_VALUE", // required * SourceGroup: "STRING_VALUE", // required @@ -92,6 +95,9 @@ export interface CreateChannelCommandOutput extends CreateChannelResponse, __Met * // }, * // HlsPlaylistSettings: { // HlsPlaylistSettings * // ManifestWindowSeconds: Number("int"), + * // AdMarkupType: [ // adMarkupTypes + * // "DATERANGE" || "SCTE35_ENHANCED", + * // ], * // }, * // ManifestName: "STRING_VALUE", // required * // PlaybackUrl: "STRING_VALUE", // required diff --git a/clients/client-mediatailor/src/commands/CreateProgramCommand.ts b/clients/client-mediatailor/src/commands/CreateProgramCommand.ts index 9947eb1cf784..0171ec0eac3f 100644 --- a/clients/client-mediatailor/src/commands/CreateProgramCommand.ts +++ b/clients/client-mediatailor/src/commands/CreateProgramCommand.ts @@ -72,6 +72,12 @@ export interface CreateProgramCommandOutput extends CreateProgramResponse, __Met * }, * ], * }, + * AdBreakMetadata: [ // AdBreakMetadataList + * { // KeyValuePair + * Key: "STRING_VALUE", // required + * Value: "STRING_VALUE", // required + * }, + * ], * }, * ], * ChannelName: "STRING_VALUE", // required @@ -123,6 +129,12 @@ export interface CreateProgramCommandOutput extends CreateProgramResponse, __Met * // }, * // ], * // }, + * // AdBreakMetadata: [ // AdBreakMetadataList + * // { // KeyValuePair + * // Key: "STRING_VALUE", // required + * // Value: "STRING_VALUE", // required + * // }, + * // ], * // }, * // ], * // Arn: "STRING_VALUE", diff --git a/clients/client-mediatailor/src/commands/DescribeChannelCommand.ts b/clients/client-mediatailor/src/commands/DescribeChannelCommand.ts index d4ac03589122..25c0d9b425bd 100644 --- a/clients/client-mediatailor/src/commands/DescribeChannelCommand.ts +++ b/clients/client-mediatailor/src/commands/DescribeChannelCommand.ts @@ -68,6 +68,9 @@ export interface DescribeChannelCommandOutput extends DescribeChannelResponse, _ * // }, * // HlsPlaylistSettings: { // HlsPlaylistSettings * // ManifestWindowSeconds: Number("int"), + * // AdMarkupType: [ // adMarkupTypes + * // "DATERANGE" || "SCTE35_ENHANCED", + * // ], * // }, * // ManifestName: "STRING_VALUE", // required * // PlaybackUrl: "STRING_VALUE", // required diff --git a/clients/client-mediatailor/src/commands/DescribeProgramCommand.ts b/clients/client-mediatailor/src/commands/DescribeProgramCommand.ts index 59f10b3465b5..a09ab747cd96 100644 --- a/clients/client-mediatailor/src/commands/DescribeProgramCommand.ts +++ b/clients/client-mediatailor/src/commands/DescribeProgramCommand.ts @@ -78,6 +78,12 @@ export interface DescribeProgramCommandOutput extends DescribeProgramResponse, _ * // }, * // ], * // }, + * // AdBreakMetadata: [ // AdBreakMetadataList + * // { // KeyValuePair + * // Key: "STRING_VALUE", // required + * // Value: "STRING_VALUE", // required + * // }, + * // ], * // }, * // ], * // Arn: "STRING_VALUE", diff --git a/clients/client-mediatailor/src/commands/ListChannelsCommand.ts b/clients/client-mediatailor/src/commands/ListChannelsCommand.ts index bde18182c3f3..c7097410d75c 100644 --- a/clients/client-mediatailor/src/commands/ListChannelsCommand.ts +++ b/clients/client-mediatailor/src/commands/ListChannelsCommand.ts @@ -71,6 +71,9 @@ export interface ListChannelsCommandOutput extends ListChannelsResponse, __Metad * // }, * // HlsPlaylistSettings: { // HlsPlaylistSettings * // ManifestWindowSeconds: Number("int"), + * // AdMarkupType: [ // adMarkupTypes + * // "DATERANGE" || "SCTE35_ENHANCED", + * // ], * // }, * // ManifestName: "STRING_VALUE", // required * // PlaybackUrl: "STRING_VALUE", // required diff --git a/clients/client-mediatailor/src/commands/UpdateChannelCommand.ts b/clients/client-mediatailor/src/commands/UpdateChannelCommand.ts index ac8739188aad..31100e781289 100644 --- a/clients/client-mediatailor/src/commands/UpdateChannelCommand.ts +++ b/clients/client-mediatailor/src/commands/UpdateChannelCommand.ts @@ -59,6 +59,9 @@ export interface UpdateChannelCommandOutput extends UpdateChannelResponse, __Met * }, * HlsPlaylistSettings: { // HlsPlaylistSettings * ManifestWindowSeconds: Number("int"), + * AdMarkupType: [ // adMarkupTypes + * "DATERANGE" || "SCTE35_ENHANCED", + * ], * }, * ManifestName: "STRING_VALUE", // required * SourceGroup: "STRING_VALUE", // required @@ -87,6 +90,9 @@ export interface UpdateChannelCommandOutput extends UpdateChannelResponse, __Met * // }, * // HlsPlaylistSettings: { // HlsPlaylistSettings * // ManifestWindowSeconds: Number("int"), + * // AdMarkupType: [ // adMarkupTypes + * // "DATERANGE" || "SCTE35_ENHANCED", + * // ], * // }, * // ManifestName: "STRING_VALUE", // required * // PlaybackUrl: "STRING_VALUE", // required diff --git a/clients/client-mediatailor/src/commands/UpdateProgramCommand.ts b/clients/client-mediatailor/src/commands/UpdateProgramCommand.ts index 82e3cf0361d6..0c378f361494 100644 --- a/clients/client-mediatailor/src/commands/UpdateProgramCommand.ts +++ b/clients/client-mediatailor/src/commands/UpdateProgramCommand.ts @@ -72,6 +72,12 @@ export interface UpdateProgramCommandOutput extends UpdateProgramResponse, __Met * }, * ], * }, + * AdBreakMetadata: [ // AdBreakMetadataList + * { // KeyValuePair + * Key: "STRING_VALUE", // required + * Value: "STRING_VALUE", // required + * }, + * ], * }, * ], * ChannelName: "STRING_VALUE", // required @@ -117,6 +123,12 @@ export interface UpdateProgramCommandOutput extends UpdateProgramResponse, __Met * // }, * // ], * // }, + * // AdBreakMetadata: [ // AdBreakMetadataList + * // { // KeyValuePair + * // Key: "STRING_VALUE", // required + * // Value: "STRING_VALUE", // required + * // }, + * // ], * // }, * // ], * // Arn: "STRING_VALUE", diff --git a/clients/client-mediatailor/src/models/models_0.ts b/clients/client-mediatailor/src/models/models_0.ts index af3c05d6a7f4..494fb82443a6 100644 --- a/clients/client-mediatailor/src/models/models_0.ts +++ b/clients/client-mediatailor/src/models/models_0.ts @@ -3,6 +3,22 @@ import { ExceptionOptionType as __ExceptionOptionType } from "@smithy/smithy-cli import { MediaTailorServiceException as __BaseException } from "./MediaTailorServiceException"; +/** + * @public + *

For SCTE35_ENHANCED output, defines a key and corresponding value. MediaTailor generates these pairs within the EXT-X-ASSETtag.

+ */ +export interface KeyValuePair { + /** + *

For SCTE35_ENHANCED output, defines a key. MediaTailor takes this key, and its associated value, and generates the key/value pair within the EXT-X-ASSETtag. If you specify a key, you must also specify a corresponding value.

+ */ + Key: string | undefined; + + /** + *

For SCTE35_ENHANCED output, defines a vaue. MediaTailor; takes this value, and its associated key, and generates the key/value pair within the EXT-X-ASSETtag. If you specify a value, you must also specify a corresponding key.

+ */ + Value: string | undefined; +} + /** * @public * @enum @@ -152,6 +168,11 @@ export interface AdBreak { *

See section 9.7.4 of the 2022 SCTE-35 specification for more information.

*/ TimeSignalMessage?: TimeSignalMessage; + + /** + *

Defines a list of key/value pairs that MediaTailor generates within the EXT-X-ASSETtag for SCTE35_ENHANCED output.

+ */ + AdBreakMetadata?: KeyValuePair[]; } /** @@ -267,6 +288,20 @@ export interface DashPlaylistSettings { SuggestedPresentationDelaySeconds?: number; } +/** + * @public + * @enum + */ +export const AdMarkupType = { + DATERANGE: "DATERANGE", + SCTE35_ENHANCED: "SCTE35_ENHANCED", +} as const; + +/** + * @public + */ +export type AdMarkupType = (typeof AdMarkupType)[keyof typeof AdMarkupType]; + /** * @public *

HLS playlist configuration parameters.

@@ -276,6 +311,11 @@ export interface HlsPlaylistSettings { *

The total duration (in seconds) of each manifest. Minimum value: 30 seconds. Maximum value: 3600 seconds.

*/ ManifestWindowSeconds?: number; + + /** + *

Determines the type of SCTE 35 tags to use in ad markup. Specify DATERANGE to use DATERANGE tags (for live or VOD content). Specify SCTE35_ENHANCED to use EXT-X-CUE-OUT and EXT-X-CUE-IN tags (for VOD content only).

+ */ + AdMarkupType?: (AdMarkupType | string)[]; } /** diff --git a/clients/client-mediatailor/src/protocols/Aws_restJson1.ts b/clients/client-mediatailor/src/protocols/Aws_restJson1.ts index e3d203fd435e..832875e8e375 100644 --- a/clients/client-mediatailor/src/protocols/Aws_restJson1.ts +++ b/clients/client-mediatailor/src/protocols/Aws_restJson1.ts @@ -123,6 +123,7 @@ import { AccessConfiguration, AdBreak, AdMarkerPassthrough, + AdMarkupType, Alert, AvailMatchingCriteria, AvailSuppression, @@ -137,6 +138,7 @@ import { HlsPlaylistSettings, HttpConfiguration, HttpPackageConfiguration, + KeyValuePair, LivePreRollConfiguration, LiveSource, LogType, @@ -3589,8 +3591,12 @@ const de_BadRequestExceptionRes = async (parsedOutput: any, context: __SerdeCont // se_AdBreak omitted. +// se_AdBreakMetadataList omitted. + // se_AdMarkerPassthrough omitted. +// se_adMarkupTypes omitted. + // se_AvailMatchingCriteria omitted. // se_AvailSuppression omitted. @@ -3617,6 +3623,8 @@ const de_BadRequestExceptionRes = async (parsedOutput: any, context: __SerdeCont // se_HttpPackageConfigurations omitted. +// se_KeyValuePair omitted. + // se_LivePreRollConfiguration omitted. // se_LogTypes omitted. @@ -3793,8 +3801,12 @@ const de___listOfVodSource = (output: any, context: __SerdeContext): VodSource[] // de_AdBreak omitted. +// de_AdBreakMetadataList omitted. + // de_AdMarkerPassthrough omitted. +// de_adMarkupTypes omitted. + /** * deserializeAws_restJson1Alert */ @@ -3855,6 +3867,8 @@ const de_Channel = (output: any, context: __SerdeContext): Channel => { // de_HttpPackageConfigurations omitted. +// de_KeyValuePair omitted. + // de_LivePreRollConfiguration omitted. /** diff --git a/codegen/sdk-codegen/aws-models/mediatailor.json b/codegen/sdk-codegen/aws-models/mediatailor.json index 642d3cced1cb..8248581ec502 100644 --- a/codegen/sdk-codegen/aws-models/mediatailor.json +++ b/codegen/sdk-codegen/aws-models/mediatailor.json @@ -71,12 +71,24 @@ "traits": { "smithy.api#documentation": "

Defines the SCTE-35 time_signal message inserted around the ad.

\n

Programs on a channel's schedule can be configured with one or more ad breaks. You can attach a splice_insert SCTE-35 message to the ad break. This message provides basic metadata about the ad break.

\n

See section 9.7.4 of the 2022 SCTE-35 specification for more information.

" } + }, + "AdBreakMetadata": { + "target": "com.amazonaws.mediatailor#AdBreakMetadataList", + "traits": { + "smithy.api#documentation": "

Defines a list of key/value pairs that MediaTailor generates within the EXT-X-ASSETtag for SCTE35_ENHANCED output.

" + } } }, "traits": { "smithy.api#documentation": "

Ad break configuration parameters.

" } }, + "com.amazonaws.mediatailor#AdBreakMetadataList": { + "type": "list", + "member": { + "target": "com.amazonaws.mediatailor#KeyValuePair" + } + }, "com.amazonaws.mediatailor#AdMarkerPassthrough": { "type": "structure", "members": { @@ -92,6 +104,23 @@ "smithy.api#documentation": "

For HLS, when set to true, MediaTailor passes through EXT-X-CUE-IN, EXT-X-CUE-OUT, and EXT-X-SPLICEPOINT-SCTE35 ad markers from the origin manifest to the MediaTailor personalized manifest.

\n

No logic is applied to these ad markers. For example, if EXT-X-CUE-OUT has a value of 60, but no ads are filled for that ad break, MediaTailor will not set the value to 0.

" } }, + "com.amazonaws.mediatailor#AdMarkupType": { + "type": "enum", + "members": { + "DATERANGE": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "DATERANGE" + } + }, + "SCTE35_ENHANCED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "SCTE35_ENHANCED" + } + } + } + }, "com.amazonaws.mediatailor#Alert": { "type": "structure", "members": { @@ -342,7 +371,11 @@ "traits": { "aws.api#arn": { "template": "channel/{ChannelName}" - } + }, + "aws.cloudformation#cfnResource": { + "name": "ChannelPolicy" + }, + "smithy.api#unstable": {} } }, "com.amazonaws.mediatailor#ChannelResource": { @@ -396,7 +429,11 @@ "aws.api#arn": { "template": "channel/{ChannelName}" }, - "smithy.api#noReplace": {} + "aws.cloudformation#cfnResource": { + "name": "Channel" + }, + "smithy.api#noReplace": {}, + "smithy.api#unstable": {} } }, "com.amazonaws.mediatailor#ChannelState": { @@ -687,13 +724,17 @@ "Outputs": { "target": "com.amazonaws.mediatailor#ResponseOutputs", "traits": { - "smithy.api#documentation": "

The output properties to assign to the channel.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The output properties to assign to the channel.

", + "smithy.api#unstable": {} } }, "PlaybackMode": { "target": "com.amazonaws.mediatailor#__string", "traits": { - "smithy.api#documentation": "

The playback mode to assign to the channel.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The playback mode to assign to the channel.

", + "smithy.api#unstable": {} } }, "Tags": { @@ -706,7 +747,9 @@ "Tier": { "target": "com.amazonaws.mediatailor#__string", "traits": { - "smithy.api#documentation": "

The tier of the channel.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The tier of the channel.

", + "smithy.api#unstable": {} } } } @@ -1760,13 +1803,17 @@ "Outputs": { "target": "com.amazonaws.mediatailor#ResponseOutputs", "traits": { - "smithy.api#documentation": "

The channel's output properties.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The channel's output properties.

", + "smithy.api#unstable": {} } }, "PlaybackMode": { "target": "com.amazonaws.mediatailor#__string", "traits": { - "smithy.api#documentation": "

The channel's playback mode.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The channel's playback mode.

", + "smithy.api#unstable": {} } }, "Tags": { @@ -1779,7 +1826,9 @@ "Tier": { "target": "com.amazonaws.mediatailor#__string", "traits": { - "smithy.api#documentation": "

The channel's tier.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The channel's tier.

", + "smithy.api#unstable": {} } }, "LogConfiguration": { @@ -2556,6 +2605,12 @@ "smithy.api#default": 0, "smithy.api#documentation": "

The total duration (in seconds) of each manifest. Minimum value: 30 seconds. Maximum value: 3600 seconds.

" } + }, + "AdMarkupType": { + "target": "com.amazonaws.mediatailor#adMarkupTypes", + "traits": { + "smithy.api#documentation": "

Determines the type of SCTE 35 tags to use in ad markup. Specify DATERANGE to use DATERANGE tags (for live or VOD content). Specify SCTE35_ENHANCED to use EXT-X-CUE-OUT and EXT-X-CUE-IN tags (for VOD content only).

" + } } }, "traits": { @@ -2615,6 +2670,28 @@ "smithy.api#documentation": "

The VOD source's HTTP package configuration settings.

" } }, + "com.amazonaws.mediatailor#KeyValuePair": { + "type": "structure", + "members": { + "Key": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

For SCTE35_ENHANCED output, defines a key. MediaTailor takes this key, and its associated value, and generates the key/value pair within the EXT-X-ASSETtag. If you specify a key, you must also specify a corresponding value.

", + "smithy.api#required": {} + } + }, + "Value": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

For SCTE35_ENHANCED output, defines a vaue. MediaTailor; takes this value, and its associated key, and generates the key/value pair within the EXT-X-ASSETtag. If you specify a value, you must also specify a corresponding key.

", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#documentation": "

For SCTE35_ENHANCED output, defines a key and corresponding value. MediaTailor generates these pairs within the EXT-X-ASSETtag.

" + } + }, "com.amazonaws.mediatailor#ListAlerts": { "type": "operation", "input": { @@ -3236,7 +3313,11 @@ "traits": { "aws.api#arn": { "template": "liveSource/{SourceLocationName}/{LiveSourceName}" - } + }, + "aws.cloudformation#cfnResource": { + "name": "LiveSource" + }, + "smithy.api#unstable": {} } }, "com.amazonaws.mediatailor#LogConfiguration": { @@ -5286,7 +5367,11 @@ "aws.api#arn": { "template": "sourceLocation/{SourceLocationName}" }, - "smithy.api#noReplace": {} + "aws.cloudformation#cfnResource": { + "name": "SourceLocation" + }, + "smithy.api#noReplace": {}, + "smithy.api#unstable": {} } }, "com.amazonaws.mediatailor#SpliceInsertMessage": { @@ -5658,13 +5743,17 @@ "Outputs": { "target": "com.amazonaws.mediatailor#ResponseOutputs", "traits": { - "smithy.api#documentation": "

The channel's output properties.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The channel's output properties.

", + "smithy.api#unstable": {} } }, "PlaybackMode": { "target": "com.amazonaws.mediatailor#__string", "traits": { - "smithy.api#documentation": "

The type of playback mode for this channel.

\n

\n LINEAR - Programs play back-to-back only once.

\n

\n LOOP - Programs play back-to-back in an endless loop. When the last program in the schedule plays, playback loops back to the first program in the schedule.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The type of playback mode for this channel.

\n

\n LINEAR - Programs play back-to-back only once.

\n

\n LOOP - Programs play back-to-back in an endless loop. When the last program in the schedule plays, playback loops back to the first program in the schedule.

", + "smithy.api#unstable": {} } }, "Tags": { @@ -5677,7 +5766,9 @@ "Tier": { "target": "com.amazonaws.mediatailor#__string", "traits": { - "smithy.api#documentation": "

The tier associated with this Channel.

" + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The tier associated with this Channel.

", + "smithy.api#unstable": {} } } } @@ -6241,7 +6332,11 @@ "aws.api#arn": { "template": "vodSource/{SourceLocationName}/{VodSourceName}" }, - "smithy.api#noReplace": {} + "aws.cloudformation#cfnResource": { + "name": "VodSource" + }, + "smithy.api#noReplace": {}, + "smithy.api#unstable": {} } }, "com.amazonaws.mediatailor#__boolean": { @@ -6376,6 +6471,12 @@ "traits": { "smithy.api#timestampFormat": "epoch-seconds" } + }, + "com.amazonaws.mediatailor#adMarkupTypes": { + "type": "list", + "member": { + "target": "com.amazonaws.mediatailor#AdMarkupType" + } } } }