

# Creating audio-only outputs
<a name="audio-only"></a>

You can set up a MediaLive channel with an output group that contains only audio. You can create a channel with these combinations of output groups:
+ One audio-only output group.
+ Several audio-only output groups.
+ One or more audio-only output groups and other regular (video-plus-audio) output groups.

Set up the channel in the [usual way](creating-channel-scratch.md), using the guidelines in this section to set up the inputs, outputs, and encodes for the audio-only output groups.

**Note**  
The information in this section assumes that you are familiar with the general steps for creating a channel, as described in [Creating a channel from scratch](creating-channel-scratch.md). 

**Topics**
+ [Setting up on the input side](audio-only-inputs.md)
+ [Setting up the output](audio-only-outputs-and-outputgroups.md)
+ [Setting up the encodes](audio-only-streams-and-encodes.md)

# Setting up on the input side
<a name="audio-only-inputs"></a>

To set up an audio-only output in a MediaLive channel, you must verify that the source inputs meet the requirements, then you must set up the audio selectors in the usual way.

## Requirements for the channel and audio sources
<a name="audio-only-input-source"></a>

The channel can have a single input or multiples inputs. All the output groups (both those that are audio-only and those that are video-and-audio) always ingest the same inputs.

Each source must be one of these categories of source.
+ A source that contains *only audio*. In this case, the source must be one of the following: 
  + A transport stream in a MediaConnect input
  + A transport stream in an RTP input
+ Input that contains *both audio and video* (and optionally captions). In this case, the input can be any input type that MediaLive supports.

## Setting up the inputs in the channel
<a name="audio-only-input-attachment"></a>

1. Create the inputs in the usual way. Then in the channel, set up the input attachments. 

1. In each input attachment, create as many audio selectors as you require. For example, create a selector for each language to extract. Or create a selector for each audio quality or codec that is available. 

   Keep in mind that in a channel with both audio-only and audio-and-video output groups, you don't have to create special audio selectors for the sole use of the audio-only output. The same audio selector can be used by both audio-only and audio-and-video output groups.

# Setting up the output
<a name="audio-only-outputs-and-outputgroups"></a>

To set up an audio-only output in a MediaLive channel, you must verify that the output groups you want to create can include audio-only encodes, then you must set up the outputs in a specific way. 

## Setting up output groups
<a name="audio-only-opg"></a>

You can create an audio-only output in the following types of output groups.
+ HLS that contains a transport stream
+ Microsoft Smooth
+ RTMP
+ UDP

## Setting up outputs
<a name="audio-only-outputs"></a>

The following list describes the number and type of required outputs, based on the output group.

**HLS output group**  
Create outputs in the output group as follows:
+ If the output group contains *only one audio encode*, then create one output. Set the container type to **Audio-only**. 
+ If the output group contains *more than one audio encode*, then set up an audio rendition group that doesn't include video. See [Audio rendition groups for HLS](audio-renditions.md).

**Microsoft Smooth output group**  
Create one output for each audio encode. 

**RTMP output groups**  
Create one output for the single audio encode. (RTMP always supports only one audio in each output group.)

**UDP output groups**  
Create one output for all the audio encodes.

# Setting up the encodes
<a name="audio-only-streams-and-encodes"></a>

This section describes the rules for setting up the audio-only encode in a MediaLive channel.

1. Configure the streams in each output so that they are suitable for generating audio-only outputs. 

   **All outputs *except UDP***

   In the **Streams settings** section for each output, set up so that each output has one and only one audio encode: 
   + Remove the video encode that MediaLive automatically adds.
   + Make sure that you don't add any captions encodes.

   **UDP outputs**

   In the **Streams settings** section for the single output, set up so that each output contains only audio encodes:
   + Add as many audio encodes as you require.
   + Remove the video encode that MediaLive automatically adds.
   + Make sure that you don't add any captions encodes.

1. In each **Streams settings** section, in the **Audio** section, set up each encode as follows.
   + In **Audio selector name**, choose one of the audio sources that you set up when you configured the input attachment.
   + In **Codec settings**, choose any output audio codec that the output type supports.