

# Delivering VOD content from AWS Elemental MediaPackage
<a name="vod-content"></a>

AWS Elemental MediaPackage uses the following resources for video on demand (VOD) content:
+ *Packaging groups* hold one or more packaging configurations. The group enables you to apply multiple output configurations to an asset at the same time. You can associate a group to multiple assets so that they all have the same configurations for their outputs.
+ *Packaging configurations* tell MediaPackage how to package the output from an asset. In the configuration, you define encryption, bitrate, and packaging settings.
+ *Assets* ingest your source content and dynamically apply packaging configurations in response to playback requests.

  For supported VOD inputs and codecs, see [VOD supported codecs and input types](supported-inputs-vod.md).

The following sections describe how to use these resources to manage VOD content in MediaPackage.

**Topics**
+ [Working with packaging groups in AWS Elemental MediaPackage](pkg-group.md)
+ [Working with packaging configurations in AWS Elemental MediaPackage](pkg-cfig.md)
+ [Working with assets in AWS Elemental MediaPackage](asset.md)

# Working with packaging groups in AWS Elemental MediaPackage
<a name="pkg-group"></a>

A packaging group holds one or more packaging configurations. When a packaging group is associated with an asset, the packaging configurations define the outputs that are available from the asset. You can associate multiple assets with one packaging group. This enables you to apply the same configurations to multiple assets.

**Topics**
+ [Creating a packaging group](pkg-group-create.md)
+ [Viewing packaging group details](pkg-group-view.md)
+ [Editing a packaging group](pkg-group-edit.md)
+ [Deleting a packaging group](pkg-group-delete.md)
+ [Adding a packaging configuration to a packaging group](pkg-group-add-cfig.md)

# Creating a packaging group
<a name="pkg-group-create"></a>

Create a packaging group to hold all of the packaging configurations for an asset. The packaging group, for example, tells AWS Elemental MediaPackage that an asset is available for output to devices that support Apple HLS and DASH-ISO.

 When you create a packaging group, you have the option to enable CDN authorization. For more information about CDN authorization, see [CDN authorization in AWS Elemental MediaPackage](cdn-auth.md).

To create a packaging group, you can use the MediaPackage console, the AWS CLI, or the MediaPackage API. information about creating a packaging group with the AWS CLI or MediaPackage API, see [Packaging\$1groups](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/packaging_groups.html) in the *AWS Elemental MediaPackage VOD API Reference*.

When you're creating a packaging group, don't put sensitive identifying information like customer account numbers into free-form fields, such as the **ID** field. This applies when you're using the MediaPackage console, MediaPackage API, AWS CLI, or AWS SDKs. Any data that you enter into MediaPackage might get picked up for inclusion in diagnostic logs or Amazon CloudWatch Events.

**To create a packaging group (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

1. On the **Packaging groups** page, choose **Create group**.

1. In the **Creating packaging group** dialog box, do the following:

   1. For **ID**, enter a name that describes the packaging group. The ID is the primary identifier for the group, and must be unique for your account in this AWS Region.

   1. Choose **Create**.

MediaPackage displays the new packaging group's details page.

If you exceed the quotas for your account when you're creating a packaging group, you get an error. If you get an error similar to Too many requests, please try again. Resource limit exceeded, either you have exceeded the API request quotas, or you have already reached the maximum number of packaging groups allowed on your account. If this is your first group, or if you think you mistakenly received this error, use the Service Quotas console to [request quota increases](https://console.aws.amazon.com/servicequotas/home?region=us-east-1#!/services/mediapackage/quotas). For more information about quotas in MediaPackage, see [Quotas in AWS Elemental MediaPackage](quotas.md).

# Viewing packaging group details
<a name="pkg-group-view"></a>

You can view all packaging groups that are configured in AWS Elemental MediaPackage or the details of a specific packaging group, including the packaging configurations that are associated with it.

To view packaging group details, you can use the AWS Elemental MediaPackage console, the AWS CLI, or the MediaPackage API. information about viewing a packaging group with the AWS CLI or MediaPackage API, see [Packaging\$1groups id](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/packaging_groups-id.html) in the *AWS Elemental MediaPackage VOD API Reference*.

**To view packaging groups (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

   All groups are displayed on the console.

1. To view more information about a specific packaging group, choose the name of the group.

   MediaPackage displays summary information, such as the assets associated with this packaging group.

# Editing a packaging group
<a name="pkg-group-edit"></a>

Edit the packaging group to configure access control settings.

**Note**  
You can't edit the packager group ID after the packaging group is created. If you want to change the packaging group ID, you must create a new packaging group.

You can use the AWS Elemental MediaPackage console, the AWS CLI, or the MediaPackage API to edit a packaging group's access control settings. For information about editing a packaging group using the AWS CLI or MediaPackage API, see the [MediaPackage VOD API reference](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/packaging_groups).

# Deleting a packaging group
<a name="pkg-group-delete"></a>

To stop AWS Elemental MediaPackage from delivering more content from an asset, delete the packaging group. Before you can delete the packaging group, you must delete the group's packaging configurations and any assets that use the group.
+ To delete a packaging configuration, see [Deleting a packaging configuration](pkg-cfig-delete.md).
+ To delete an asset, see [Deleting an asset](asset-delete.md).

To delete a packaging group, you can use the MediaPackage console, the AWS CLI, or the MediaPackage API. For information about deleting a packaging group with the AWS CLI or MediaPackage API, see [Packaging\$1groups id](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/packaging_groups-id.html) in the *AWS Elemental MediaPackage VOD API Reference*.

**To delete a packaging group (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

1. On the **Packaging groups** page, choose the packaging group that you want to delete.

1. Choose **Delete**.

1. In the **Packaging group delete** dialog box, choose **Delete** to finish deleting the packaging group.

# Adding a packaging configuration to a packaging group
<a name="pkg-group-add-cfig"></a>

 To define how AWS Elemental MediaPackage formats outputs from an asset, add a packaging configuration to a packaging group.

To add a packaging configuration to a packaging group, you can use the MediaPackage console, the AWS CLI, or the MediaPackage API. For more information about adding a packaging configuration with the AWS CLI or MediaPackage API, see [Packaging\$1configurations](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/packaging_configurations.html) in the *AWS Elemental MediaPackage VOD API Reference*.

For instructions on adding packaging configurations to a packaging group from the MediaPackage console, see [Creating a packaging configuration](pkg-cfig-create.md).

# Working with packaging configurations in AWS Elemental MediaPackage
<a name="pkg-cfig"></a>

A packaging configuration defines a single delivery point for an asset. The configuration holds all of the information that's needed for AWS Elemental MediaPackage to integrate with a player or content delivery network (CDN), such as Amazon CloudFront. Configure the configuration to output content in one of the available stream formats:
+ Apple HLS – Packages content to Apple HTTP Live Streaming (HLS) 
+ Microsoft Smooth – Packages content for Microsoft Smooth Streaming players
+ Common Media Application Format (CMAF) – Packages content to devices that support Apple HLS fragmented MP4 (fMP4)
+ DASH-ISO – Packages content for the DASH-ISO ABR streaming protocol

The packaging configuration also holds information about digital rights management (DRM) and encryption integration, bitrate presentation order, and more.

**Topics**
+ [Creating a packaging configuration](pkg-cfig-create.md)
+ [Viewing packaging configuration details](pkg-cfig-view.md)
+ [Editing a packaging configuration](pkg-cfig-edit.md)
+ [Deleting a packaging configuration](pkg-cfig-delete.md)

# Creating a packaging configuration
<a name="pkg-cfig-create"></a>

Create a packaging configuration to define how AWS Elemental MediaPackage prepares content for delivery from an asset. 

To create a packaging configuration, you can use the MediaPackage console, the AWS CLI, or the MediaPackage API. For information about creating a packaging configuration with the AWS CLI or MediaPackage API, see [Packaging\$1configurations](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/packaging_configurations.html) in the *AWS Elemental MediaPackage VOD API Reference*.

When you're creating a packaging configuration, don't put sensitive identifying information like customer account numbers into free-form fields, such as the **ID** field. This applies when you're using the MediaPackage console, MediaPackage API, AWS CLI, or AWS SDKs. Any data that you enter into MediaPackage might get picked up for inclusion in diagnostic logs or Amazon CloudWatch Events.

**Topics**
+ [Creating an HLS packaging configuration](pkg-cfig-create-hls.md)
+ [Creating a DASH packaging configuration](pkg-cfig-create-dash.md)
+ [Creating a Microsoft Smooth packaging configuration](pkg-cfig-create-mss.md)
+ [Creating a CMAF packaging configuration](pkg-cfig-create-cmaf.md)

# Creating an HLS packaging configuration
<a name="pkg-cfig-create-hls"></a>

Create a packaging configuration that formats content for devices that support Apple HLS.

**To create an Apple HLS packaging configuration (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

1. On the **Packaging groups** page, choose the group that will contain the configuration that you're creating.

1. On the details page for the packaging group, under **Packaging configurations**, choose **Manage configurations**.

1. On the **Manage packaging configurations** page, under **Packaging configurations**, choose **Add** and select **New config**.

1. Complete the fields as described in the following topics:
   + [General settings fields](cfigs-hls-new.md)
   + [Manifest settings fields](cfigs-hls-manset.md)
   + [Stream selection fields](cfigs-hls-include-streams.md)
   + [Encryption fields](cfigs-hls-encryption.md)

1. Choose **Save**.

If you exceed the quotas for your account when you're creating a packaging configuration, you get an error. If you get an error similar to Too many requests, please try again. Resource limit exceeded, either you have exceeded the API request quotas, or you have already reached the maximum number of packaging groups allowed on your account. If this is your first group, or if you think you mistakenly received this error, use the Service Quotas console to [request quota increases](https://console.aws.amazon.com/servicequotas/home?region=us-east-1#!/services/mediapackage/quotas). For more information about quotas in MediaPackage, see [Quotas in AWS Elemental MediaPackage](quotas.md).

# General settings fields
<a name="cfigs-hls-new"></a>

Provide general settings that apply to the entire packaging configuration.

1. For **ID**, enter a name that describes the configuration. The ID is the primary identifier for the configuration, and must be unique for your account in the AWS Region.

1. For **Package type**, choose **Apple HLS**.

1. (Optional) For **Segment duration**, enter the duration (in seconds) of each segment. Enter a value equal to, or a multiple of, the input segment duration. If the value that you enter is different from the input segment duration, AWS Elemental MediaPackage rounds segments to the nearest multiple of the input segment duration.

# Manifest settings fields
<a name="cfigs-hls-manset"></a>

Specify the format of the manifest that AWS Elemental MediaPackage delivers from an asset that uses this packaging configuration.

1. (Optional) For **Manifest name**, enter a short string that will be appended to the endpoint URL. The manifest name creates a unique path to this endpoint. If you don't enter a value, MediaPackage uses the default manifest name, *index*.

1. (Optional) Select **Include IFrame-only streams** to include an additional I-frame only stream along with the other tracks in the manifest. MediaPackage generates an I-frame only stream from the first rendition in the manifest. The service inserts `EXT-I-FRAMES-ONLY` tags in the output manifest, and then generates and includes an I-frames only playlist in the stream. This playlist enables player functionality like fast forward and rewind.

1. (Optional) Select **Use audio rendition groups** to group all audio tracks into a single HLS rendition group. For more information about rendition groups, see [Rendition groups reference in AWS Elemental MediaPackage](rendition-groups.md).

1. (Optional) Select **Repeat EXT-X-KEY** if you want the service to repeat the key before every segment of the manifest. By default, the key is written just once, after the header and before the segments. If you select **Repeat EXT-X-KEY**, the manifest is written as header, key, segment, key, segment, key, and so on, with every segment preceded by the key. Set this according to the needs of the player. Selecting this option might result in an increase in client requests to the DRM server.

1. (Optional) Select **Include DVB subtitles** to passthrough digital video broadcasting (DVB) subtitles into the output.

1. (Optional) For **Program date/time interval** enter the interval (in seconds) at which MediaPackage should insert the `EXT-X-PROGRAM-DATE-TIME` tags in the manifest.

   The `EXT-X-PROGRAM-DATE-TIME` tag synchronizes the stream to the wall clock, enabling functionality like viewer seek in the playback timeline and time display on the player.

1. (Optional) For **Ad markers**, choose how ad markers are included in the packaged content. 

   Choose from the following:
   + **None** – Omit all SCTE-35 ad markers from the output.
   + **Passthrough** – Copy the SCTE-35 ad markers directly from the input HLS input stream to the output.
   + **SCTE-35 Enhanced** – Generate ad markers and blackout tags based on the SCTE-35 input messages from the input stream.

# Stream selection fields
<a name="cfigs-hls-include-streams"></a>

Limit what incoming bitrates are available for playback and sort the streams in the output of an asset that uses this packaging configuration. 

The minimum and maximum values take into account only the video bitrates. If the video bitrate is *below the minimum* specified rate, it's *not* included in the output, regardless of the sum of the bitrates for other tracks. Likewise, if the video bitrate is *below the maximum *specified rate, it *is* included in the output, regardless of the sum of the bitrates for other tracks.

To set minimum and maximum bitrates and sort the output, select **Enable stream selection** and complete the additional fields as follows:

1. (Optional) For **Stream order**, choose from the following:
   + **Original** to sort the output streams in the same order that the incoming source uses.
   + **Ascending** to sort the output streams starting with the lowest bitrate and ending with the highest.
   + **Descending** to sort the output streams starting with the highest bitrate and ending with the lowest.

1. (Optional) For **Min video bitrate**, enter the minimum bitrate threshold (in bits per second) that video tracks must must be at or above to be available for playback from this endpoint. This ensures that tracks are *at least* a certain bitrate.

1. (Optional) For **Max video bitrate**, enter the maximum bitrate threshold (in bits per second) that video tracks must be at or below to be available for playback from this endpoint. This ensures that tracks are *no more than* a certain bitrate.

# Encryption fields
<a name="cfigs-hls-encryption"></a>

Protect your content from unauthorized use through content encryption and digital rights management (DRM). AWS Elemental MediaPackage uses the [AWS Secure Packager and Encoder Key Exchange (SPEKE) API](https://aws.amazon.com/media/tech/speke-basics-secure-packager-encoder-key-exchange-api/) to facilitate content encryption and decryption by a DRM provider. Using SPEKE, the DRM provider supplies encryption keys to MediaPackage through the SPEKE API. The DRM provider also supplies licenses to supported media players for decryption. For more information about how SPEKE is used with services and features running in the cloud, see [AWS cloud-based architecture](https://docs.aws.amazon.com/speke/latest/documentation/what-is-speke.html#services-architecture) in the *Secure Packager and Encoder Key Exchange API Specification guide*.

**Note**  
To encrypt content, you must have a DRM solution provider, and be set up to use encryption. For information, see [Content encryption and DRM in AWS Elemental MediaPackage](using-encryption.md). 

To serve content with copyright protection, select **Enable encryption ** and complete the additional fields as follows:

1. For **Encryption method**, choose **Sample-AES** for Apple HLS FairPlay or choose **AES-128** for Apple HLS AES-128. 

1. (Optional) For **Constant initialization vector** enter a 128-bit, 16-byte hex value represented by a 32-character string, to be used with the key for encrypting content.

1. For **URL**, enter the URL of the API Gateway proxy that you set up to talk to your key server. The API Gateway proxy must reside in the same AWS Region as MediaPackage.

   The following example shows a URL. 

   ```
   https://1wm2dx1f33.execute-api.us-west-2.amazonaws.com/SpekeSample/copyProtection
   ```

1. For **Role ARN**, enter the Amazon Resource Name (ARN) of the IAM role that provides you access to send your requests through API Gateway. Get this from your DRM solution provider.

   The following example shows a role ARN. 

   ```
   arn:aws:iam::444455556666:role/SpekeAccess
   ```

1. For **System IDs**, enter unique identifiers for your streaming protocol and DRM system. Provide up to three IDs for CMAF, two IDs for DASH, and exactly one for the other streaming protocols. If you provide more than one system ID, enter one per line and choose **Add**. For a list of common system IDs, see [DASH-IF System IDs](https://dashif.org/identifiers/content_protection/). If you don't know your IDs, ask your DRM solution provider.

# Creating a DASH packaging configuration
<a name="pkg-cfig-create-dash"></a>

Create a packaging configuration that formats content for devices that support DASH-ISO.

**To create a DASH-ISO packaging configuration (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

1. On the **Packaging groups** page, choose the group that will contain the configuration that you're creating.

1. On the details page for the packaging group, under **Packaging configurations**, choose **Manage configurations**.

1. On the **Manage packaging configurations** page, under **Packaging configurations**, choose **Add** and **New config**.

1. Complete the fields as described in the following topics:
   + [General settings fields](cfigs-dash-new.md)
   + [Manifest settings fields](cfigs-dash-manset.md)
   + [Stream selection fields](cfigs-dash-include-streams.md)
   + [Encryption fields](cfigs-dash-encryption.md)

1. Choose **Save**.

If you exceed the quotas for your account when you're creating a packaging configuration, you get an error. If you get an error similar to Too many requests, please try again. Resource limit exceeded, either you have exceeded the API request quotas, or you have already reached the maximum number of packaging groups allowed on your account. If this is your first group, or if you think you mistakenly received this error, use the Service Quotas console to [request quota increases](https://console.aws.amazon.com/servicequotas/home?region=us-east-1#!/services/mediapackage/quotas). For more information about quotas in MediaPackage, see [Quotas in AWS Elemental MediaPackage](quotas.md).

# General settings fields
<a name="cfigs-dash-new"></a>

Provide general settings that apply to the entire packaging configuration.

1. For **ID**, enter a name that describes the configuration. The ID is the primary identifier for the configuration, and must be unique for your account in the Region.

1. For **Package type**, choose **DASH-ISO**.

1. (Optional) For **Segment duration**, enter the duration (in seconds) of each segment. Enter a value equal to, or a multiple of, the input segment duration. If the value that you enter is different from the input segment duration, AWS Elemental MediaPackage rounds segments to the nearest multiple of the input segment duration.

# Manifest settings fields
<a name="cfigs-dash-manset"></a>

Specify the format of the manifest that AWS Elemental MediaPackage delivers from an asset that uses this packaging configuration.

1. (Optional) For **Manifest name**, enter a short string that will be appended to the endpoint URL. The manifest name helps to create a unique path to this endpoint. If you don't enter a value, the default manifest name is *index*.

1. (Optional) For **Min buffer time**, enter the minimum amount of time (in seconds) that a player must keep in the buffer. If network conditions interrupt playback, the player will have additional buffered content before playback fails, allowing for recovery time before the viewer's experience is affected.

1. (Optional) For **Profile**, specify a DASH profile.

   Choose from the following:
   + **None** – the output doesn't use a DASH profile
   + **Hbbtv 1.5** – the output is compliant with HbbTV v1.5. For information about HbbTV v1.5, see the [HbbTV specification website](https://www.hbbtv.org/resource-library/specifications/).

1. (Optional) For **Manifest layout**, choose if you want MediaPackage to serve a full, compact, or DRM top level compact manifest in response to playback requests.
   + If you choose **Full**, MediaPackage presents the `SegmentTemplate` and `SegmentTimeline` tags for every `Representation` in the manifest.
   + If you choose **Compact**, MediaPackage combines duplicate `SegmentTemplate` tags and presents them at the start of the manifest. This shortens the manifest and makes it easier for some devices to process it.
   + If you choose **DRM top level compact**, MediaPackage places content protection elements at the media presentation description (MPD) level and are referenced at the `AdaptationSet` level. You can choose this option only if you're using the SPEKE Version 1.0 or 2.0 SHARED preset.

   For more information about the manifest layout options, see [Compacted DASH manifests](compacted.md).

1. (Optional) For **Segment template format**, choose how MediaPackage and playback requests refer to each segment.
   + If you choose **Number with timeline**, MediaPackage uses the `$Number$` variable to refer to the segment in the `media` attribute of the `SegmentTemplate` tag. The value of the variable is the sequential number of the segment. `SegmentTimeline` is included in each segment template.
   + If you choose **Time with timeline**, MediaPackage uses the `$Time$` variable to refer to the segment. The value of the variable is the timestamp of when on the manifest timeline the segment starts. `SegmentTimeline` is included in each segment template.
   + If you choose **Number with duration**, MediaPackage uses the `$Number$` variable and replaces the `SegmentTimeline` objects with a `duration` attribute in the segment template. 
**Note**  
This option isn't supported in combination with multi-period DASH.

   For more information about the formatting options of the `SegmentTemplate` tag, see [DASH manifest segment template format](segtemp-format.md).

1. (Optional) Select **Include IFrame-only streams** to include an additional I-frame only stream along with the other tracks in the manifest. MediaPackage generates an I-frame only stream from the first rendition in the manifest. This playlist enables player functionality like fast forward and rewind.

1. For **Period triggers**, select how MediaPackage creates MPD periods in the DASH output manifest.
   + **None** – MediaPackage doesn't create additional periods. It formats the manifest as a single period and doesn't include SCTE-35 markers in the segments.
   + **Trigger new periods on ads** – MediaPackage creates and inserts in the manifest multiple periods based on SCTE-35 ad markers from the input content. These periods separate portions of the content, such as setting boundaries between the main content and ad content. For more information about how MediaPackage configures periods in the manifest, see [DASH manifest options in AWS Elemental MediaPackageMulti-period DASH in AWS Elemental MediaPackage](multi-period.md).
**Important**  
Multiple periods are required if you use AWS Elemental MediaTailor for personalized ad insertion in DASH content. For more information about this service, see the [AWS Elemental MediaTailor User Guide](https://docs.aws.amazon.com/mediatailor/latest/ug/).

1. For **SCTE markers source**, specify the source of SCTE-35 markers to use from your input HLS content. 
   +  Select **Segments** to use SCTE-35 markers from input HLS media segments.
   +  Select **Manifest** to use SCTE-35 markers, formatted using SCTE-35 Enhanced syntax (`#EXT-OATCLS-SCTE35` tags), from input HLS child manifests. SCTE-35 Elemental and SCTE-35 Daterange syntaxes are not supported.

1. (Optional) Select **Include encoder configuration in segments** for MediaPackage to place your encoder's Sequence Parameter Set (SPS), Picture Parameter Set (PPS), and Video Parameter Set (VPS) metadata in every video segment instead of in the init fragment. This lets you use different SPS/PPS/VPS settings for your assets during content playback.

# Stream selection fields
<a name="cfigs-dash-include-streams"></a>

Limit which incoming bitrates are available for playback and sort the streams in the output of an asset that uses this packaging configuration. 

The minimum and maximum values take into account only the video bitrates. If the video bitrate is *below the minimum* specified rate, it's *not* included in the output, regardless of the sum of the bitrates for other tracks. Likewise, if the video bitrate is *below the maximum *specified rate, it *is* included in the output, regardless of the sum of the bitrates for other tracks.

To set minimum and maximum bitrates and sort the output, select **Enable stream selection** and complete the additional fields as follows:

1. (Optional) For **Stream order**, choose from the following:
   + **Original** to sort the output streams in the same order that the incoming source uses.
   + **Ascending** to sort the output streams starting with the lowest bitrate and ending with the highest.
   + **Descending** to sort the output streams starting with the highest bitrate and ending with the lowest.

1. (Optional) For **Min video bitrate**, enter the minimum bitrate threshold (in bits per second) that video tracks must be at or above to be available for playback from this endpoint. This ensures that tracks are *at least* a certain bitrate.

1. (Optional) For **Max video bitrate**, enter the maximum bitrate threshold (in bits per second) that video tracks must be at or below to be available for playback from this endpoint. This ensures that tracks are *no more than* a certain bitrate.

# Encryption fields
<a name="cfigs-dash-encryption"></a>

Protect your content from unauthorized use through content encryption and digital rights management (DRM). AWS Elemental MediaPackage uses the [AWS Secure Packager and Encoder Key Exchange (SPEKE) API](https://aws.amazon.com/media/tech/speke-basics-secure-packager-encoder-key-exchange-api/) to facilitate content encryption and decryption by a DRM provider. Using SPEKE, the DRM provider supplies encryption keys to MediaPackage through the SPEKE API. The DRM provider also supplies licenses to supported media players for decryption. For more information about how SPEKE is used with services and features running in the cloud, see [AWS cloud-based architecture](https://docs.aws.amazon.com/speke/latest/documentation/what-is-speke.html#services-architecture) in the *Secure Packager and Encoder Key Exchange API Specification guide*.

**Note**  
To encrypt content, you must have a DRM solution provider, and be set up to use encryption. For information, see [Content encryption and DRM in AWS Elemental MediaPackage](using-encryption.md). 

To serve content with copyright protection, select **Enable encryption** and complete the additional fields as follows:

1. For **URL**, enter the URL of the API Gateway proxy that you set up to talk to your key server. The API Gateway proxy must reside in the same AWS Region as MediaPackage.

   The following example shows a URL. 

   ```
   https://1wm2dx1f33.execute-api.us-west-2.amazonaws.com/SpekeSample/copyProtection
   ```

1. For **Role ARN**, enter the Amazon Resource Name (ARN) of the IAM role that provides you access to send your requests through API Gateway. Get this from your DRM solution provider.

   The following example shows a role ARN. 

   ```
   arn:aws:iam::444455556666:role/SpekeAccess
   ```

1. For **System IDs**, enter unique identifiers for your streaming protocol and DRM system. Provide up to three IDs for CMAF, two IDs for DASH, and exactly one for the other streaming protocols. If you provide more than one system ID, enter one per line and choose **Add**. For a list of common system IDs, see [DASH-IF System IDs](https://dashif.org/identifiers/content_protection/). If you don't know your IDs, ask your DRM solution provider.

1. (Optional) For **SPEKE version**, choose the SPEKE version that you'd like to use for encryption. SPEKE Version 1.0 is the legacy version that uses CPIX Version 2.0, and supports single key encryption. SPEKE Version 2.0 uses CPIX Version 2.3, and supports multiple key encryption. For more information about using SPEKE with MediaPackage, see [Content encryption and DRM in MediaPackage](https://docs.aws.amazon.com/mediapackage/latest/ug/using-encryption.html). 

   If you select **SPEKE Version 2.0**, then also choose a **Video encryption preset** and an **Audio encryption preset**. The video and audio presets determine which content keys MediaPackage uses to encrypt the audio and video tracks in your stream. For more information about these presets, see [SPEKE Version 2.0 presets](drm-content-speke-v2-presets.md).

    When using SPEKE Version 2.0, MediaPackage disables key rotation.

# Creating a Microsoft Smooth packaging configuration
<a name="pkg-cfig-create-mss"></a>

Create a packaging configuration that formats content for devices that support Microsoft Smooth.

**To create a Microsoft Smooth packaging configuration (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

1. On the **Packaging groups** page, choose the group that will contain the configuration that you're creating.

1. On the details page for the packaging group, under **Packaging configurations**, choose **Manage configurations**.

1. On the **Manage packaging configurations** page, under **Packaging configurations**, choose **Add** and select **New config**.

1. Complete the fields as described in the following topics:
   + [General settings fields](cfigs-mss-new.md)
   + [Manifest settings fields](cfigs-mss-manset.md)
   + [Stream selection fields](cfigs-mss-include-streams.md)
   + [Encryption fields](cfigs-mss-encryption.md)

1. Choose **Save**.

If you exceed the quotas for your account when you're creating a packaging configuration, you get an error. If you get an error similar to Too many requests, please try again. Resource limit exceeded, either you have exceeded the API request quota, or you have already reached the maximum number of packaging groups allowed on your account. If this is your first group, or if you think you mistakenly received this error, use the Service Quotas console to [request quota increases](https://console.aws.amazon.com/servicequotas/home?region=us-east-1#!/services/mediapackage/quotas). For more information about quotas in MediaPackage, see [Quotas in AWS Elemental MediaPackage](quotas.md).

# General settings fields
<a name="cfigs-mss-new"></a>

Provide general settings that apply to the entire packaging configuration.

1. For **ID**, enter a name that describes the configuration. The ID is the primary identifier for the configuration, and must be unique for your account in the Region.

1. For **Package type**, choose **Microsoft Smooth**.

1. (Optional) For **Segment duration**, enter the duration (in seconds) of each segment. Enter a value equal to, or a multiple of, the input segment duration. If the value that you enter is different from the input segment duration, AWS Elemental MediaPackage rounds segments to the nearest multiple of the input segment duration.

# Manifest settings fields
<a name="cfigs-mss-manset"></a>

Specify the format of the manifest that AWS Elemental MediaPackage delivers from an asset that uses this packaging configuration.
+ (Optional) For **Manifest name**, enter a short string that will be appended to the endpoint URL. The manifest name helps to create a unique path to this endpoint. If you don't enter a value, the default manifest name is *index*.

# Stream selection fields
<a name="cfigs-mss-include-streams"></a>

Limit which incoming bitrates are available for playback and sort the streams in the output of an asset that uses this packaging configuration. 

The minimum and maximum values take into account only the video bitrates. If the video bitrate is *below the minimum* specified rate, it's *not* included in the output, regardless of the sum of the bitrates for other tracks. Likewise, if the video bitrate is *below the maximum *specified rate, it *is* included in the output, regardless of the sum of the bitrates for other tracks.

To set minimum and maximum bitrates and sort the output, select **Enable stream selection** and complete the additional fields as follows:

1. (Optional) For **Stream order**, choose from the following:
   + **Original** to sort the output streams in the same order that the incoming source uses.
   + **Ascending** to sort the output streams starting with the lowest bitrate and ending with the highest.
   + **Descending** to sort the output streams starting with the highest bitrate and ending with the lowest.

1. (Optional) For **Min video bitrate**, enter the minimum bitrate threshold (in bits per second) that video tracks must be at or above to be available for playback from this endpoint. This ensures that tracks are *at least* a certain bitrate.

1. (Optional) For **Max video bitrate**, enter the maximum bitrate threshold (in bits per second) that video tracks must be at or below to be available for playback from this endpoint. This ensure that tracks are *no more than* a certain bitrate.

# Encryption fields
<a name="cfigs-mss-encryption"></a>

Protect your content from unauthorized use through content encryption and digital rights management (DRM). AWS Elemental MediaPackage uses the [AWS Secure Packager and Encoder Key Exchange (SPEKE) API](https://aws.amazon.com/media/tech/speke-basics-secure-packager-encoder-key-exchange-api/) to facilitate content encryption and decryption by a DRM provider. Using SPEKE, the DRM provider supplies encryption keys to MediaPackage through the SPEKE API. The DRM provider also supplies licenses to supported media players for decryption. For more information about how SPEKE is used with services and features running in the cloud, see [AWS cloud-based architecture](https://docs.aws.amazon.com/speke/latest/documentation/what-is-speke.html#services-architecture) in the *Secure Packager and Encoder Key Exchange API Specification guide*.

**Note**  
To encrypt content, you must have a DRM solution provider, and be set up to use encryption. For information, see [Content encryption and DRM in AWS Elemental MediaPackage](using-encryption.md). 

To serve content with copyright protection, select **Enable encryption ** and complete the additional fields as follows:

1. For **URL**, enter the URL of the API Gateway proxy that you set up to talk to your key server. The API Gateway proxy must reside in the same AWS Region as MediaPackage.

   The following example shows a URL. 

   ```
   https://1wm2dx1f33.execute-api.us-west-2.amazonaws.com/SpekeSample/copyProtection
   ```

1. For **Role ARN**, enter the Amazon Resource Name (ARN) of the IAM role that provides you access to send your requests through API Gateway. Get this from your DRM solution provider.

   The following example shows a role ARN. 

   ```
   arn:aws:iam::444455556666:role/SpekeAccess
   ```

1. For **System IDs**, enter unique identifiers for your streaming protocol and DRM system. Provide up to three IDs for CMAF, two IDs for DASH, and exactly one for the other streaming protocols. If you provide more than one system ID, enter one per line and choose **Add**. For a list of common system IDs, see [DASH-IF System IDs](https://dashif.org/identifiers/content_protection/). If you don't know your IDs, ask your DRM solution provider.

# Creating a CMAF packaging configuration
<a name="pkg-cfig-create-cmaf"></a>

Create a packaging configuration that formats content for devices that support Apple HLS fragmented MP4 (fMP4).

**To create a CMAF packaging configuration (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

1. On the **Packaging groups** page, choose the group that will contain the configuration that you're creating.

1. On the details page for the packaging group, under **Packaging configurations**, choose **Manage configurations**.

1. On the **Manage packaging configurations** page, under **Packaging configurations**, choose **Add** and select **New config**.

1. Complete the fields as described in the following topics:
   + [General settings fields](cfigs-cmaf-new.md)
   + [Manifest settings fields](cfigs-cmaf-manset.md)
   + [Stream selection fields](cfigs-cmaf-include-streams.md)
   + [Encryption fields](cfigs-cmaf-encryption.md)

1. Choose **Save**.

If you exceed the quotas for your account when you're creating a packaging configuration, you get an error. If you get an error similar to Too many requests, please try again. Resource limit exceeded, either you have exceeded the API request quotas, or you have already reached the maximum number of packaging groups allowed on your account. If this is your first group, or if you think you mistakenly received this error, use the Service Quotas console to [request quota increases](https://console.aws.amazon.com/servicequotas/home?region=us-east-1#!/services/mediapackage/quotas). For more information about quotas in MediaPackage, see [Quotas in AWS Elemental MediaPackage](quotas.md).

# General settings fields
<a name="cfigs-cmaf-new"></a>

Provide general settings that apply to the entire packaging configuration.

1. For **ID**, enter a name that describes the configuration. The ID is the primary identifier for the configuration, and must be unique for your account in the Region.

1. For **Package type**, choose **Common Media Application Format (CMAF)**.

1. (Optional) For **Segment duration**, enter the duration (in seconds) of each segment. Enter a value equal to, or a multiple of, the input segment duration. If the value that you enter is different from the input segment duration, AWS Elemental MediaPackage rounds segments to the nearest multiple of the input segment duration.

# Manifest settings fields
<a name="cfigs-cmaf-manset"></a>

Specify the format of the manifest that AWS Elemental MediaPackage delivers from an asset that uses this packaging configuration.

1. (Optional) For **Manifest name**, enter a short string that will be appended to the endpoint URL. The manifest name creates a unique path to this endpoint. If you don't enter a value, MediaPackage uses the default manifest name, *index*.

1. (Optional) In stream sets with a single video track, select **Include IFrame-only streams** to include an additional I-frame only stream along with the other tracks in the manifest. MediaPackage inserts `EXT-I-FRAMES-ONLY` tags in the manifest, and then compiles and includes an I-frames only playlist in the stream. This playlist enables player functionality like fast forward and rewind.

1. (Optional) Select **Repeat EXT-X-KEY** if you want the service to repeat the key before every segment of the manifest. By default, the key is written just once, after the header and before the segments. If you select **Repeat EXT-X-KEY**, the manifest is written as header, key, segment, key, segment, key, and so on, with every segment preceded by the key. Set this according to the needs of the player. Selecting this option might result in an increase in client requests to the DRM server.

1. (Optional) For **Program date/time interval**, enter the interval at which MediaPackage should insert the `EXT-X-PROGRAM-DATE-TIME` tags in the manifest.

   The `EXT-X-PROGRAM-DATE-TIME` tag synchronizes the stream to the wall clock, enabling functionality like viewer seek in the playback timeline and time display on the player.

1. (Optional) For **Ad markers**, choose how ad markers are included in the packaged content. 

   Choose from the following:
   + **None** – Omit all SCTE-35 ad markers from the output.
   + **Passthrough** – Copy the SCTE-35 ad markers directly from the input HLS input stream to the output.
   + **SCTE-35 Enhanced** – Generate ad markers and blackout tags based on the SCTE-35 input messages from the input stream.

1. (Optional) Select **Include encoder configuration in segments**, for MediaPackage to place your encoder's Sequence Parameter Set (SPS), Picture Parameter Set (PPS), and Video Parameter Set (VPS) metadata in every video segment instead of in the init fragment. This lets you use different SPS/PPS/VPS settings for your assets during content playback.

# Stream selection fields
<a name="cfigs-cmaf-include-streams"></a>

Limit which incoming bitrates are available for playback and sort the streams in the output of an asset that uses this packaging configuration. 

The minimum and maximum values take into account only the video bitrates. If the video bitrate is *below the minimum* specified rate, it's *not* included in the output, regardless of the sum of the bitrates for other tracks. Likewise, if the video bitrate is *below the maximum *specified rate, it *is* included in the output, regardless of the sum of the bitrates for other tracks.

To set minimum and maximum bitrates and sort the output, select **Enable stream selection** and complete the additional fields as follows:

1. (Optional) For **Stream order**, choose from the following:
   + **Original** to sort the output streams in the same order that the incoming source uses.
   + **Ascending** to sort the output streams starting with the lowest bitrate and ending with the highest.
   + **Descending** to sort the output streams starting with the highest bitrate and ending with the lowest.

1. (Optional) For **Min video bitrate**, enter the minimum bitrate threshold (in bits per second) that video tracks must be at or above to be available for playback from this endpoint. This ensures that tracks are *at least* a certain bitrate.

1. (Optional) For **Max video bitrate**, enter the maximum bitrate threshold (in bits per second) that video tracks must be at or below to be available for playback from this endpoint. This ensures that tracks are *no more than* a certain bitrate.

# Encryption fields
<a name="cfigs-cmaf-encryption"></a>

Protect your content from unauthorized use through content encryption and digital rights management (DRM). AWS Elemental MediaPackage uses the [AWS Secure Packager and Encoder Key Exchange (SPEKE) API](https://aws.amazon.com/media/tech/speke-basics-secure-packager-encoder-key-exchange-api/) to facilitate content encryption and decryption by a DRM provider. Using SPEKE, the DRM provider supplies encryption keys to MediaPackage through the SPEKE API. The DRM provider also supplies licenses to supported media players for decryption. For more information about how SPEKE is used with services and features running in the cloud, see [AWS cloud-based architecture](https://docs.aws.amazon.com/speke/latest/documentation/what-is-speke.html#services-architecture) in the *Secure Packager and Encoder Key Exchange API Specification guide*.

**Note**  
To encrypt content, you must have a DRM solution provider, and be set up to use encryption. For information, see [Content encryption and DRM in AWS Elemental MediaPackage](using-encryption.md). 

To serve content with copyright protection, Select **Enable encryption** and complete the additional fields as follows:

1. For **System IDs**, enter unique identifiers for your streaming protocol and DRM system. Provide up to two system IDs. If you provide more than one system ID, enter one per line. If you do not know your IDs, ask your DRM solution provider.

1. For **URL**, enter the URL of the API Gateway proxy that you set up to talk to your key server. The API Gateway proxy must reside in the same AWS Region as MediaPackage.

   The following example shows a URL. 

   ```
   https://1wm2dx1f33.execute-api.us-west-2.amazonaws.com/SpekeSample/copyProtection
   ```

1. (Optional) For **SPEKE version**, choose the SPEKE version that you'd like to use for encryption. SPEKE Version 1.0 is the legacy version that uses CPIX Version 2.0, and supports single key encryption. SPEKE Version 2.0 uses CPIX Version 2.3, and supports multiple key encryption. For more information about using SPEKE with MediaPackage, see [Content encryption and DRM in MediaPackage](https://docs.aws.amazon.com/mediapackage/latest/ug/using-encryption.html). 

   If you select **SPEKE Version 2.0**, then also choose a **Video encryption preset** and an **Audio encryption preset**. The video and audio presets determine which content keys MediaPackage uses to encrypt the audio and video tracks in your stream. For more information about these presets, see [SPEKE Version 2.0 presets](drm-content-speke-v2-presets.md).

    When using SPEKE Version 2.0, MediaPackage disables key rotation.

1. (Optional) For **Constant initialization vector** enter a 128-bit, 16-byte hex value represented by a 32-character string, to be used with the key for encrypting content.

1. For **Role ARN**, enter the Amazon Resource Name (ARN) of the IAM role that provides you access to send your requests through API Gateway. Get this from your DRM solution provider.

   The following example shows a role ARN. 

   ```
   arn:aws:iam::444455556666:role/SpekeAccess
   ```

# Viewing packaging configuration details
<a name="pkg-cfig-view"></a>

To ensure that the content is available in all necessary stream formats, view all packaging configurations that are associated with a specific packaging group or with an asset. 

To view packaging configurations, you can use the AWS Elemental MediaPackage console, the AWS CLI, or the MediaPackage API. For information about viewing a packaging configuration with the AWS CLI or MediaPackage API, see [Packaging\$1configurations id](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/packaging_configurations-id.html) in the *AWS Elemental MediaPackage VOD API Reference*.

**To view packaging configurations in a packaging group (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

1. On the **Packaging groups** page, choose the group that contains the configurations that you want to view. 

   The **Packaging configurations** section displays all of the configurations that are in this group.

1. To view the details of a specific packaging configuration, choose the **Id** of that configuration.

MediaPackage displays summary information, such as the assets associated with this packaging configuration.

**To view all packaging configurations associated with an asset (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Assets**.

1. On the **Assets** page, choose the asset that you want to audit. 

   The **Playback details** section displays all of the configurations that are associated with this asset. On this page, you can view the playback status of the asset in the **Status** column. The available statuses are as follows:
+ **Not processed **- The asset hasn't been processed yet.
+ **Processing** - MediaPackage is processing the asset. The asset isn't available for playback yet.
+ **Processed** - The asset has been processed, and is available for playback.
+ **Failed** - Processing failed.

**Note**  
Status information isn't available for most assets ingested before September 30th, 2021.

# Editing a packaging configuration
<a name="pkg-cfig-edit"></a>

You can't edit a packaging configuration. If you need to make changes, create a new configuration and delete the original.
+ To create a configuration, see [Creating a packaging configuration](pkg-group-create.md).
+ To delete a configuration, see [Deleting a packaging configuration](pkg-group-delete.md).

# Deleting a packaging configuration
<a name="pkg-cfig-delete"></a>

To remove a playback endpoint from an asset, delete the packaging configuration.

To delete a packaging configuration, you can use the AWS Elemental MediaPackage console, the AWS CLI, or the MediaPackage API. For information about deleting a packaging configuration with the AWS CLI or MediaPackage API, see [Packaging\$1configurations id](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/packaging_configurations-id.html) in the *AWS Elemental MediaPackage VOD API Reference*.

**To delete a packaging configuration (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Packaging groups**.

1. On the **Packaging groups** page, choose the group that contains the configuration that you're deleting. 

1. On the details page for the packaging group, under **Packaging configurations**, choose either the packaging configuration ID of the configuration that you're deleting and choose **Delete** or choose **Manage configurations**, **Actions**, **Delete**.

1. On the **Delete packaging configurations** page, choose **Delete**.

# Working with assets in AWS Elemental MediaPackage
<a name="asset"></a>

An asset holds all of the information that MediaPackage requires to ingest file-based video content from a source such as Amazon S3. Through the asset, MediaPackage ingests and dynamically packages content in response to playback requests. The configurations associated with the asset determine how it can be packaged for output. 

After you ingest an asset, AWS Elemental MediaPackage provides a URL for each playback configuration associated with the asset. This URL is fixed for the lifetime of the asset, regardless of any failures that might happen over time. Downstream devices use the URL to send playback requests.

For supported VOD inputs and codecs, see [VOD supported codecs and input types](supported-inputs-vod.md).

**Topics**
+ [Ingesting an asset](asset-create.md)
+ [Viewing asset details](asset-view.md)
+ [Editing an asset](asset-edit.md)
+ [Deleting an asset](asset-delete.md)

# Ingesting an asset
<a name="asset-create"></a>

To ingest source content, create an asset in AWS Elemental MediaPackage. When MediaPackage ingests content, it creates a unique playback URL for every packaging configuration that's associated with the asset.

**Important**  
To ingest an asset, MediaPackage must have permissions to access the Amazon S3 bucket where the source content is stored. To create a role that gives MediaPackage the right permissions, see [Allowing AWS Elemental MediaPackage to access other AWS services](setting-up-create-trust-rel.md).

To create an asset, you can use the MediaPackage console, the AWS CLI, or the MediaPackage API. For information about creating a packaging configuration with the AWS CLI or MediaPackage API, see [Assets](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/assets.html) in the *AWS Elemental MediaPackage VOD API Reference*.

When you're creating an asset, don't put sensitive identifying information like customer account numbers into free-form fields, such as the **ID** field. This applies when you're using the MediaPackage console, MediaPackage API, AWS CLI, or AWS SDKs. Any data that you enter into MediaPackage might get picked up for inclusion in diagnostic logs or Amazon CloudWatch Events.

**To ingest an asset (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Assets**.

1. On the **Assets** page, choose **Ingest assets**.

1. On the **Ingest assets** page, complete the fields as described in the following topics:
   + [Asset access fields](asset-create-access.md)
   + [Asset details fields](asset-create-details.md)
   + [Packaging settings field](asset-create-pkg.md)

1. Choose **Ingest assets**.

Ingesting a VOD asset is an asynchronous action. The time it takes before an asset becomes available for playback can vary based on several factors, such as asset duration and asset complexity. You can track when a VOD asset is ready for playback by monitoring the CloudWatch `VodAssetPlayable` events that MediaPackage sends when the asset is ready for playback. For more information, see [VOD Playback Events](cloudwatch-events-example.md#vod-asset-playable). 

If you exceed the quotas for your account when you're creating a packaging configuration, you get an error. If you get an error similar to Too many requests, please try again. Resource limit exceeded, either you have exceeded the API request quotas, or you have already reached the maximum number of packaging groups allowed on your account. If this is your first group, or if you think you mistakenly received this error, use the Service Quotas console to [request quota increases](https://console.aws.amazon.com/servicequotas/home?region=us-east-1#!/services/mediapackage/quotas). For more information about quotas in MediaPackage, see [Quotas in AWS Elemental MediaPackage](quotas.md).

# Asset access fields
<a name="asset-create-access"></a>

The following fields describe how AWS Elemental MediaPackage accesses the source content in your Amazon S3 bucket. MediaPackage must have permissions to access the bucket. To create an IAM role with the right permissions, see [Allowing AWS Elemental MediaPackage to access other AWS services](setting-up-create-trust-rel.md).

1. For **Amazon S3 bucket name**, choose from a list of buckets that MediaPackage has detected in your account or enter the name of the bucket. The Amazon S3 bucket holds the source content that MediaPackage ingests and packages for playback. If you entered the name of the bucket, MediaPackage doesn't have visibility into this bucket, so it can't tell if the bucket is compatible or not.
**Note**  
If you don't have permissions to view Amazon S3 buckets, MediaPackage doesn't display any options. Contact your AWS administrator or enter the bucket name manually in the **Specify bucket name** field.

1. For **IAM role**, choose the IAM role with the MediaPackage permissions to read from the Amazon S3 bucket.
   + To choose from a list of roles that MediaPackage has detected on your account, choose **Use existing role** and choose the role.
**Note**  
If you don't have permissions to view IAM roles, MediaPackage doesn't display any options. Contact your AWS administrator or enter the role ARN manually in the **Specify custom role name** field.
   + To use a role that MediaPackage hasn't detected, choose **Specify custom role name** and enter the custom ARN of the role. Because MediaPackage doesn't have visibility into this role, it can't tell if the role provides the correct permissions or not.

# Asset details fields
<a name="asset-create-details"></a>

The following fields describe the source content that this asset uses.

If you have multiple sources for this asset, choose **Add asset** and complete the fields. Do this for all source contents.

**Important**  
Source content must be in a .smil (MP4) or .m3u8 (HLS/TS) file format.

1. For **Filename**, Enter the full path to either the .smil manifest (MP4) or the .m3u8 parent playlist (HLS) within your Amazon S3 bucket, including the name of the source content. You don't need to enter the bucket name because you chose it in **S3 bucket name** field. For example, if your content is called` lion_movie.m3u8` and is in a subdirectory called `thursday_night` in a bucket called `movies`, you would enter the following in the **Filename** field:

   ```
   thursday_night/lion_movie.m3u8
   ```

   For more information about using .smil manifests with MediaPackage, see [Requirements for .smil manifests](supported-inputs-vod-smil.md).

1. For **ID**, enter a name that describes the asset. The ID is the primary identiﬁer for the asset, and must be unique for your account in this Region. Supported characters are letters, numbers, underscores (\$1), and dashes (-).

1. (Optional) For **Resource ID**, enter an identifier for the content. When you're using SPEKE, the resource ID is the identifier that your key server uses to reference the content. MediaPackage sends the ID to the key server to identify the current asset. How unique you make the ID depends on the level of access controls you need. The service doesn't allow you to use the same ID for two simultaneous encryption processes. The resource ID is also known as the content ID.  
**Example**  

   ```
   MovieNight20171126093045
   ```

# Packaging settings field
<a name="asset-create-pkg"></a>

The following field determines how AWS Elemental MediaPackage packages outputs from this asset.
+ For **Packaging group**, choose the group that holds the configurations that you want to use for this asset. The packaging group determines which packaging configurations MediaPackage uses when it packages content to fulfill playback requests.

# Viewing asset details
<a name="asset-view"></a>

You can view all assets that are configured in AWS Elemental MediaPackage or the details of a specific asset, including the packaging configurations that are associated with it.

To view asset details, you can use the MediaPackage console, the AWS CLI, or the MediaPackage API. For information about creating a packaging configuration with the AWS CLI or MediaPackage API, see [Assets id](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/assets-id.html) in the *AWS Elemental MediaPackage VOD API Reference*.

**To view assets (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Assets**.

   All assets are displayed on the console.

1. To view more information about a specific asset, choose the name of the asset.

   MediaPackage displays summary information, such as the packaging configurations associated with this packaging asset and their playback URLs.

# Editing an asset
<a name="asset-edit"></a>

You can't edit an asset. To make changes, ingest the asset again and delete the original.
+ To ingest an asset, see [Creating a packaging configuration](asset-create.md).
+ To delete an asset, see [Deleting a packaging configuration](asset-delete.md).

# Deleting an asset
<a name="asset-delete"></a>

To remove the packaging group URLs and to stop AWS Elemental MediaPackage from delivering further content, delete an asset. 

To delete an asset, you can use the MediaPackage console, the AWS CLI, or the MediaPackage API. For information about creating a packaging configuration with the AWS CLI or MediaPackage API, see [Assets id](https://docs.aws.amazon.com/mediapackage-vod/latest/apireference/assets-id.html) in the *AWS Elemental MediaPackage VOD API Reference*.

**To delete an asset (console)**

1. Open the MediaPackage console at [https://console.aws.amazon.com/mediapackage/](https://console.aws.amazon.com/mediapackage/).

1. In the navigation pane, under **Video on demand**, choose **Assets**.

1. On the **Assets** page, select the asset that you want to delete.

1. Choose **Delete**.