Ingesting an Asset

Add the content that you want to distribute in the playlists in Media Streams.

Assets (content) are ingested (added) into a distribution channel and streamed using a packaging configuration. To run the ingest operation, the asset publisher must have the MEDIA_WORKFLOW_JOB_CREATE permission on the compartment where the asset is ingested.

Asset Publishers (or roles which ingest assets into a distribution channel) must have rights to perform the following actions:
  • Read the primary playlist (m3u8) from the Object Storage location in the region.
  • Read the bucket, playlist, and any rendered files in the channel.
Note

Media Streams can ingest only HLS playlists. To use OCI Media Streams to deliver your content, create an HLS playlist by using OCI Media Flow.
    1. Open the navigation menu  and select Analytics & AI. Under Media Services, select Media Streams.
    2. On the Distribution channels list page, select the compartment that contains the distribution channel where you want to ingest the assets.
    3. Select the name of the channel where you want to ingest the assets.
    4. On the details page, select Playlist assets.
    5. Select Ingest playlist asset.
    6. In the Ingest playlist asset panel, enter a name for the playlist asset.
    7. For Input file, select the bucket in the compartment that contains the content. If you don't see the bucket that you want, you might need to change the compartment.
    8. Select the file. This object is your HLS primary playlist (m3u8) with all the Variable Bitrate (VBR) renditions of the asset that you want to ingest. You can select only valid HLS content to ingest. If the content is in formats such as MP4, then convert the files to HLS format. For more details, see OCI Media Flow.
    9. (Optional) In the Tags section, add one or more tags to the playlist asset.
      If you have permissions to create a resource, then you also have permissions to apply free-form tags to that resource. To apply a defined tag, you must have permissions to use the tag namespace. For more information about tagging, see Resource Tags. If you're not sure whether to apply tags, skip this option or ask an administrator. You can apply tags later.
    10. Select Ingest.
      The playlist is created. On the playlist asset details page, in the Asset information section, the Ingest asset job status is set to Accepted.
    For information about creating a preview URL and playing the asset, see Managing Content Delivery in Media Streams.
  • Asset ingestion using the CLI requires a media asset ID for ingestion.

    You can use the Console to view the existing media asset IDs and proceed with asset ingestion or you can create a new one in the CLI based on the HLS media in your object storage bucket using the create command:

    oci media-services media-asset create [OPTIONS]

    Required parameters for the create command are:

    • --compartment id [text]
    • --type [text]: <use the type PLAYLIST for the HLS media>
    • --namespace-name [text]
    • --bucket-name [text]
    • --object-name [text]: <name of the primary HLS or m3u8 file>

    After the media asset ID is created, you can ingest the asset.

    To ingest an asset, use the ingest-stream-distribution-channel-asset-metadata-entry-details command:

    oci media-services stream-distribution-channel ingest-stream-distribution-channel-asset-metadata-entry-details [OPTIONS]

    Required parameters for the ingest-stream-distribution-channel-asset-metadata-entry-details command are:

    • --media-asset-id [text]
    • --stream-distribution-channel-id [text]
    • --compartment-id [text]

    To get all the commands for stream-distribution-channel:

    oci media-services stream-distribution-channel -h

    To get help for the ingest-stream-distribution-channel-asset-metadata-entry-details command:

    oci media-services stream-distribution-channel ingest-stream-distribution-channel-asset-metadata-entry-details -h

    For a complete list of flags and variable options for CLI commands, see the Command Line Reference.

  • To ingest an asset, use the IngestStreamDistributionChannel operation.

    After the asset is successfully ingested, you can manually create a Preview URL. For details, see Creating a Preview URL.