

# Creating an AWS Elemental MediaLive schedule
<a name="working-with-schedule"></a>

In AWS Elemental MediaLive, you can manipulate the processing of a channel while it is running. You perform this manipulation by adding actions to the schedule that is associated with the channel. The schedule holds each action until the start time for the action, at which point MediaLive passes the action to the channel, and the channel performs the action.

We recommend that you read this schedule chapter before you start the channel. A key schedule action is input switching, which you must implement if you have a multiple-input channel (if you have attached more than one input to the channel). But there are other actions that might be relevant to your workflow. 

Typically, you set up the schedule before you start the channel. At the least, you create schedule actions that you know must occur soon. After you start the channel, you can continue to add schedule actions. You can add actions you already have planned and ad-hoc actions. 

**Topics**
+ [

# Types of actions in the schedule
](x-actions-in-schedule.md)
+ [

# Types of timing for actions
](sched-timing-types.md)
+ [

# How schedule actions work
](sched-how-actions-work.md)
+ [

# Working with the schedule (console)
](schedule-using-console.md)
+ [

# Working with the schedule (AWS CLI)
](schedule-using-cli.md)

# Types of actions in the schedule
<a name="x-actions-in-schedule"></a>

The schedule is a list of actions that a channel performs as it is running. You can use actions to do the following:
+ Switch the input that the running channel is ingesting.
+ Prepare an input that is associated with an immediate input switch, in order to reduce the delay that occurs when MediaLive performs the switch.
+ Insert a static image overlay (an image layered over the underlying video) in every output in every output group. This action is called global image overlay.
+ Insert a static image overlay into the running channel, only in specific outputs in specific output groups. The action is called per-outputs image overlay.
+ Insert a motion graphics overlay into the running channel. 
+ Insert SCTE 35 messages into the running channel.
+ Insert ID3 metadata into the running channel.
+ Insert ID3 segment tags into the running channel.
+ Pause one or both of the pipelines in the channel.
+ Unpause one or both of the pipelines in the channel.

For more information, see [How schedule actions work](sched-how-actions-work.md). 

# Types of timing for actions
<a name="sched-timing-types"></a>

There are several ways to specify the timing for an action:
+ Fixed – Perform the action at a specific time that you specify.

  For most actions, the specified time must be at least 15 seconds in the future. For input prepare actions, the specified time must be at least 15 seconds before the start of the associated input switch. 
+ Immediate – Perform the action as soon as possible. 

  You don't specify a time.
+ Follow – Perform the action just before the specified input switch starts, or just after the currently running input has finished. 

The following table shows the types of timing that apply to each type of action. To read this table, find an action in the first column, then read across the row for the applicable types of timing.


| Type of action | Supported types of timing |  | Fixed | Follow (Note A) | Immediate | 
| --- | --- | --- | --- | --- | --- | 
| Switch the input (perform an input switch) | Yes | Yes | Yes | 
| Prepare the input (perform an input prepare) | Yes | Yes | Yes | 
| Activate a global static image overlay | Yes |  | Yes | 
| Activate a per-outputs static image overlay | Yes |  | Yes | 
| Activate a motion graphics overlay | Yes |  | Yes | 
| Deactivate a global static image overlay | Yes |  | Yes | 
| Deactivate a per-outputs static image overlay | Yes |  | Yes | 
| Deactivate a motion graphics overlay | Yes |  | Yes | 
| Insert a SCTE 35 message | Yes | Yes | Yes | 
| Insert ID3 metadata | Yes |  | Yes | 
| Insert an ID3 segment tag | Yes |  | Yes | 
| Pause or unpause one or both pipelines | Yes |  | Yes | 

**Note A**  
With a follow, the applicable action can follow an input switch. It can't follow other types of actions. Therefore, the action that is *being followed *is always an input switch. The action that does the follow is an input switch, an input prepare, or a SCTE 35 message. 

# How schedule actions work
<a name="sched-how-actions-work"></a>

This section describes how MediaLive handles each combination of [action type](x-actions-in-schedule.md) and [start type](sched-timing-types.md). 

**Topics**
+ [

# How input switch actions work
](x-actions-in-schedule-ips.md)
+ [

# How input prepare actions work
](x-actions-in-schedule-prep.md)
+ [

# How image overlay actions work
](x-actions-in-schedule-image-overlay.md)
+ [

# How motion graphics overlay works
](x-actions-in-schedule-mg.md)
+ [

# How SCTE 35 actions work
](x-actions-in-schedule-SCTE35.md)
+ [

# How ID3 metadata actions work
](x-actions-in-schedule-id3.md)
+ [

# How ID3 segment tag actions work
](x-actions-in-schedule-id3-segment-tag.md)
+ [

# How pause and unpause actions work
](x-actions-in-schedule-pause.md)

# How input switch actions work
<a name="x-actions-in-schedule-ips"></a>

You can set up an action to switch the input that the running channel is ingesting. The channel stops ingesting the current input and starts ingesting the specified input. 

The input must already be attached to the channel. 

Before you add input switching actions to the schedule, read [Setting up for input switching](scheduled-input-switching.md).

**Input switch with fixed start**  
When you create the action, you include a start time. The start time for the action must be at least 15 seconds in the future but not more than 14 days in the future. After that cutoff, MediaLive rejects the request to create the action. 

After you have created the action, the action sits in the schedule. Approximately 15 seconds before the start time, the schedule passes the action to the channel. The channel sets up so that the input switches at the specified time.

**Input switch with immediate start**  
When you create the action, you set the start type to *immediate*. 

For an input switch in a standard channel (a channel with two pipelines), MediaLive internally sets the start time to 10 seconds in the future. This delay ensures that the switch occurs at exactly the same time for the two pipelines.

The schedule immediately passes the action to the channel. The channel immediately starts to switch the input (for a single-pipeline channel), or sets up to switch at the specified time (for a standard channel).

**Input switch with follow start**  
When you create the action, you specify the input switch action that you want this action to follow. That *reference action* must be an input switch. 

The input for the reference action must have a source end behavior of *Continue*. To find the **Source end behavior** field, go to the **Create channel** page, find the input in the **Input attachment** list, and then find **General input settings**. 

After you create the action, the action waits in the schedule. Just before the reference action is due to finish, the schedule passes the action to the channel so that the channel can switch to the new input as soon as the current input has finished.

# How input prepare actions work
<a name="x-actions-in-schedule-prep"></a>

You can set up an action to prepare an input that is associated with an immediate input switch, in order to reduce the delay that occurs when MediaLive performs the switch.

The input must already be attached to the channel. However, there is no requirement for the input switch for this input to already exist in the schedule. For example, input X must be *attached *to the channel. You can create action A to prepare input X and later on you can create action B to switch to input X. Or you can create action B and then create action A.

Before you add input prepare actions to the schedule, read [Preparing inputs in AWS Elemental MediaLive](feature-prepare-input.md).

**Input prepare with fixed start**  
When you create the action, include a start time. The start time for the action must be at least 15 seconds before the start time of the associated input switch, but not more than 14 days in the future. After that cutoff, MediaLive rejects the request to create the action. 

After you have created the action, the action sits in the schedule. Approximately 15 seconds before the start time of the prepare action, the schedule passes the action to the channel. The channel starts preparing the input.

**Input prepare with immediate start**  
When you create the action, you set the start type to *immediate*. 

The schedule immediately passes the action to the channel. The channel immediately starts the prepare.

**Input prepare with follow start**  
When you create the action, you specify the input switch action that you want this action to follow. That *reference action* must be an input switch.

The input for the reference action must have a source end behavior of *Continue*. To find the **Source end behavior** field, go to the **Create channel** page, find the input in the **Input attachment** list, and then find **General input settings**. 

After you create the action, the action waits in the schedule. Just before the reference action is due to finish, the schedule passes the action to the channel. As soon as the current input has finished, the channel switches to the new input.

# How image overlay actions work
<a name="x-actions-in-schedule-image-overlay"></a>

You can set up an action to insert and remove an image overlay on the video:
+ The activate action inserts an image overlay and activates it so that it is superimposed on the underlying video. If the image overlay information includes a duration, then at the appropriate time the image overlay is removed.
+ The deactivate action removes an image overlay. You therefore use this action to remove a currently running image overlay before the specified duration, or remove it when no duration is specified.

Before you add image overlay actions to the schedule, read [Working with image overlays](working-with-image-overlay.md).

**Global or per-outputs insertion**

There are two ways to insert image overlays:
+ Use the **Static image activate** feature to insert globally: You can create an action to insert an image overlay in every output in every output group in a channel.
+ Use the** Static image output activate** feature to insert per-output: You can create an action to insert an image overlay in specific outputs in specific output groups in a channel.

**Activate or deactivate with fixed start**

When you create the action, you include a start time. The start time for the action must be at least 15 seconds in the future but not more than 14 days in the future. After that cutoff, MediaLive rejects the request to create the action. 

After you have created the action, the action sits in the schedule. Approximately 15 seconds before the start time, the schedule passes the action to the channel. At the start time, the channel inserts the image overlay or removes the image overlay from the video.

**Activate or deactivate with immediate start**

When you create the action, you set the start type to *immediate*. 

The schedule immediately passes the action to the channel. The channel immediately inserts the image overlay or removes the image overlay.

# How motion graphics overlay works
<a name="x-actions-in-schedule-mg"></a>

You can set up an action to insert and remove a motion graphics overlay on the video:
+ The activate motion graphics action inserts a motion graphic and activates it so that it is superimposed on the underlying video. If the image overlay information includes a duration, then at the appropriate time the motion graphic is removed.
+ The deactivate motion graphics action removes an image overlay. You therefore use this action to remove a currently running motion graphics before the specified duration, or remove it when no duration is specified.

For information about preparing the motion graphics asset that the action inserts, see [Working with motion graphics overlays](feature-mgi.md).

**Activate or deactivate with fixed start**  
When you create the action, you include a start time. The start time for the action must be at least 15 seconds in the future but not more than 14 days in the future. After that cutoff, MediaLive rejects the request to create the action. 

After you have created the action, the action sits in the schedule. Approximately 15 seconds before the start time, the schedule passes the action to the channel. At the start time, the channel inserts the motion graphic or removes the motion graphic from the video.

**Activate or deactivate with immediate start**  
When you create the action, you set the start type to *immediate*. 

The schedule immediately passes the action to the channel. The channel immediately inserts the motion graphic or removes the motion graphic.

# How SCTE 35 actions work
<a name="x-actions-in-schedule-SCTE35"></a>

You can set up an action to insert a SCTE 35 message in the channel. There are three types of actions:
+ Action to insert a splice\$1insert into the channel: a SCTE 35 message with splice\$1command\$1type set to splice\$1insert.
+ Action to insert a time\$1signal into the channel: a SCTE 35 message with splice\$1command\$1type set to time\$1signal.
+ Action to insert a SCTE 35 return-to-network message into the schedule in order to end a splice\$1insert that either has a duration or has no duration.

Before you add SCTE 35 actions to the schedule, read [Processing SCTE 35 messages](scte-35-message-processing.md).

**Insert SCTE 35 message with fixed start**  
When you create the action, you include a start time. The start time for the action must be at least 15 seconds in the future but not more than 14 days in the future. After that cutoff, MediaLive rejects the request to create the action. 

After you have created the action, the action sits in the schedule. Approximately 15 seconds before the start time, the schedule passes the action to the channel. At the start time, the channel inserts the SCTE 35 message into the stream.

After the channel inserts the message, MediaLive processes the inserted message in the same way as it processes messages that were already in the source content. 

**Insert SCTE 35 message with immediate start**  
When you create the action, you set the start type to *immediate*. 

The schedule immediately passes the action to the channel. The channel immediately inserts the SCTE 35 message into the stream.

After the channel inserts the message, MediaLive processes the inserted message in the same way as it processes messages that were already in the source content. 

**Insert SCTE 35 message with follow start**  
When you create the action, you specify the input switch action that you want this action to follow. That *reference action* must be an input switch.

The input for the reference action must have a source end behavior of *Continue*. To find the **Source end behavior** field, go to the **Create channel** page, find the input in the **Input attachment** list, and then find **General input settings**. 

After you create the action, the action waits in the schedule. Just before the reference action is due to finish, the schedule passes the action to the channel. As soon as the current input has finished, the channel inserts the SCTE 35 message into the stream.

After the channel inserts the message, MediaLive processes the inserted message in the same way as it processes messages that were already in the source content. 

# How ID3 metadata actions work
<a name="x-actions-in-schedule-id3"></a>

You can set up an action to insert ID3 data in the channel. You can set up an action to insert ID3 data in each segment in the following types of outputs:
+ CMAF Ingest
+ HLS
+ MediaPackage

Before you add ID3 metadata actions to the schedule, read [Inserting ID3 metadata using the schedule](insert-id3-metadata-via-schedule.md).

**Insert ID3 metadata with fixed start**

When you create the action, you include a start time. The start time for the action must be at least 15 seconds in the future but not more than 14 days in the future. After that cutoff, MediaLive rejects the request to create the action. 

After you have created the action, the action sits in the schedule. Approximately 15 seconds before the start time, the schedule passes the action to the channel. At the start time, the channel inserts the data into the channel.

**Insert ID3 metadata with immediate start**

When you create the action, you set the start type to *immediate*. 

The schedule immediately passes the action to the channel. The channel immediately inserts the data into the channel.

# How ID3 segment tag actions work
<a name="x-actions-in-schedule-id3-segment-tag"></a>

You can set up an action to insert ID3 data in each segment in the following types of outputs:
+ CMAF Ingest
+ HLS
+ MediaPackage

Before you add ID3 segment tag actions to the schedule, read [Inserting ID3 metadata using the schedule](insert-id3-metadata-via-schedule.md).

**Insert ID3 segment tags with fixed start**

When you create the action, you include a start time. The start time for the action must be at least 15 seconds in the future but not more than 14 days in the future. After that cutoff, MediaLive rejects the request to create the action. 

After you have created the action, the action sits in the schedule. Approximately 15 seconds before the start time, the schedule passes the action to the channel. At the start time, the channel inserts the data into the channel.

**Insert ID3 data with immediate start**

When you create the action, you set the start type to *immediate*. 

The schedule immediately passes the action to the channel. The channel immediately inserts the data into the channel.

# How pause and unpause actions work
<a name="x-actions-in-schedule-pause"></a>

You can insert an action to pause and unpause one or both pipelines in the channel. The action pauses the specified pipelines and unpauses any unspecified pipelines:
+ Action with *one* pipeline specified–The action pauses the specified pipeline and unpauses the other pipeline.
+ Action with *both* pipelines specified–The action pauses both pipelines.
+ Action with *no* pipelines specified–The action unpauses both pipelines. 

**Note**  
The pipelines that you don't specify are not left in their current state. They are always set to unpaused.

**Pause or unpause with fixed start**

When you create the action, you include a start time. The start time for the action must be at least 15 seconds in the future but not more than 14 days in the future. After that cutoff, MediaLive rejects the request to create the action. 

After you have created the action, the action sits in the schedule. Approximately 15 seconds before the start time, the schedule passes the action to the channel. At the start time, the channel pauses or unpauses the pipelines in the channel.

**Pause or unpause with immediate start**

When you create the action, you set the start type to *immediate*.

The schedule immediately passes the action to the channel. The channel immediately pauses or unpauses the pipelines in the channel.

# Working with the schedule (console)
<a name="schedule-using-console"></a>

You can use the AWS Elemental MediaLive console to create or delete any of the [schedule actions](x-actions-in-schedule.md) in a channel. You can work with the schedule when the channel is running or when it is idle. 

The actions are performed in the channel when the channel is running.

The console provides two views for working with actions:
+ A list view that lists actions in tabular format
+ A timeline view that shows a timeline representation of the actions

In either view, you can do the following:
+ Create individual actions.
+ Delete individual actions.
+ Delete several actions in one request (a batch command).
+ View the actions currently in the schedule.

**Topics**
+ [

# Creating actions in the schedule (console)
](schedule-using-console-create.md)
+ [

# Deleting actions from the schedule (console)
](schedule-using-console-delete.md)
+ [

# Modifying actions in the schedule (console)
](schedule-modify.md)
+ [

# Viewing the schedule (console)
](schedule-using-console-view.md)

# Creating actions in the schedule (console)
<a name="schedule-using-console-create"></a>

You can create different actions in the schedule. For a list of supported actions, see [Types of actions in the schedule](x-actions-in-schedule.md).

The general procedure is the same to create any type of action.

**To create an action**

1. Read the information about [planning the actions](sched-how-actions-work.md) you want to add. 

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

1. In the navigation pane, choose **Channel**, and then choose the channel that you want to work with.

1. On the **Details** pane, choose the **Schedule** tab.

1. Choose the **Switch** button to display the view that you want: **List** view or **Timeline** view. For information about the layout and color coding of the timeline view, see [Viewing the schedule (console)](schedule-using-console-view.md).

1. For **List** view, choose the appropriate action:
   + To create a fixed, follow, or immediate action from scratch, choose **Create**. 
   + To create a follow action after an existing action, choose that action, choose **Schedule actions**, and then choose **Create follow actions from**. 

     This method displays the **Create schedule action** page with some fields already completed, so you can quickly create a follow switch for that existing action.

1. For **Timeline** view, choose the appropriate action:
   + To create a fixed, follow, or immediate action from scratch, choose **Create**.
   + To create a follow action, find the input switch that you want to follow, and then choose **Create follow action** in that card.

     This method displays the **Create schedule action** page with some fields already completed, so you can quickly create a follow switch for that existing action.

1. On the **Create schedule action** page, complete the fields. For information about completing the fields, see the following topics.

1. When you have finished, choose **Create**.

   MediaLive adds the action to the list or the timeline at its appropriate time slot. 

When you create a follow input switch, you effectively create an *input follow chain*. The input follow chain starts with the input above the first follow and ends with the last follow input. For more information about input follow chains, see [Fixed, immediate, and follow switches](ips-switch-types.md).

**Topics**
+ [

# Fields for an input switch
](schedule-fields-for-ips.md)
+ [

# Fields for an input prepare
](schedule-fields-for-input-prep.md)
+ [

# Fields for activating a global image overlay
](schedule-fields-for-activate-image.md)
+ [

# Fields for deactivating a global image overlay
](schedule-fields-for-deactivate-image.md)
+ [

# Fields for activating a per-outputs image overlay
](schedule-fields-activate-image-per-output.md)
+ [

# Fields for deactivating a per-outputs image overlay
](schedule-fields-deactivate-image-per-output.md)
+ [

# Fields for activating a motion graphics overlay
](schedule-fields-for-mg.md)
+ [

# Fields for deactivating a motion graphics overlay
](schedule-fields-for-mg-deactivate.md)
+ [

# Fields for a splice\$1insert message
](schedule-fields-for-splice_insert.md)
+ [

# Fields for a time\$1signal message
](schedule-fields-for-time-signal.md)
+ [

# Fields for a return-to-network message
](schedule-fields-for-return-to-network.md)
+ [

# Fields for ID3 metadata
](schedule-fields-for-id3-userdata.md)
+ [

# Fields for ID3 segment tags
](schedule-fields-for-id3-segment-tags.md)
+ [

# Fields for pause
](schedule-fields-for-pause.md)
+ [

# Fields for unpause
](schedule-fields-for-unpause.md)

# Fields for an input switch
<a name="schedule-fields-for-ips"></a>

This section describes how to complete the fields for these three types of input switches:
+ A switch to a static live input 
+ A switch to a static file input 
+ A switch to a dynamic file input

**Topics**
+ [

## Fields for a switch to a static live input
](#schedule-fields-ips-static-live)
+ [

## Fields for a switch to a static file input
](#schedule-fields-ips-static-file)
+ [

## Fields for a switch to a dynamic file input
](#schedule-fields-ips-static-dynamic)

## Fields for a switch to a static live input
<a name="schedule-fields-ips-static-live"></a>

This table shows the fields that apply for an action to switch to a static live input. 


| Field | Description | 
| --- | --- | 
| Action name |  A name for this input switch.  | 
| Action type |  Input Switch. | 
| Input attachment | The live input to switch to. The input must already be set up as an [input attachment](creating-a-channel-step2.md) in this channel. For example, if you want to switch from input A to input B, specify input B in this field. | 
| Start type  | Fixed, Immediate, or Follow. For information about start types for input prepare, see [Fixed, immediate, and follow switches](ips-switch-types.md). | 
| Date and time | If the Start type is Fixed, specify the date and time (in UTC format) that the channel must switch to this new input. This time must be at least 30 seconds in the future.Note that the time is the wall clock time, not the timecode in the input. | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to switch from, which is the input that precedes this new input. The dropdown list shows all existing input switches that are file inputs. Remember that input B can follow input A only if input A is a file input and the source end behavior for input A is *continue*. For information about these switching rules, see [Fixed, immediate, and follow switches](ips-switch-types.md). For example, if you want to switch from input A to input B, specify input A in this field.  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the switch will occur when the input in Reference action name has finished. | 

## Fields for a switch to a static file input
<a name="schedule-fields-ips-static-file"></a>

This table shows the fields that apply for an action to switch to a static file input. 


| Field | Description | 
| --- | --- | 
| Action name |  A name for this input switch.  | 
| Action type |  Input Switch. | 
| Input attachment | The file input to switch to. The input must already be set up as an [input attachment](creating-a-channel-step2.md) in this channel. For example, if you want to switch from input A to input B, specify input B in this field. | 
| Input clippings settings – Enable input clipping | This field appears only for a file input that is [eligible for input clipping](input-clipping.md).Enable the field if you want to clip the file at the start and end, or only at the start, or only at the end. | 
| Input clippings settings – Input timecode source |  Choose the source: Zero-based – To set the start and end times relative to the start of the file, which is 00:00:00:00. Embedded – To set the times based on the timecode in the file. The file must have a timecode, otherwise the clipping instruction is ignored.  | 
| Input clippings settings – Start timecode, Stop timecode |  Complete one or both fields. Enter values in the format hh:mm:ss:ff.  | 
| Input clippings settings – Last frame clipping behavior | This field appears only if you specify a stop timecode. Exclude last frame – Clip the file before the frame specified in the end timecode. For example, if the end timecode is 01:00:30:19, don't include frame 19.Include last frame – Don't clip the file. In the preceding example, include frame 19. | 
| Start type  | Fixed, Immediate, or Follow. For information about start types for input prepare, see [Fixed, immediate, and follow switches](ips-switch-types.md). | 
| Date and time | If the Start type is Fixed, specify the date and time (in UTC format) that the channel must switch to this new input. This time must be at least 30 seconds in the future.Note that the time is the wall clock time, not the timecode in the input. | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to switch from, which is the input that precedes this new input. The dropdown list shows all existing input switches that are file inputs. Remember that input B can follow input A only if input A is a file input. For information about these switching rules, see [Fixed, immediate, and follow switches](ips-switch-types.md). For example, if you want to switch from input A to input B, specify input A in this field.  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the switch will occur when the input in Reference action name has finished. | 

## Fields for a switch to a dynamic file input
<a name="schedule-fields-ips-static-dynamic"></a>

This table shows the fields that apply for an action to switch to a dynamic file input. 


| Field | Description | 
| --- | --- | 
| Action name |  A name for this input switch.  | 
| Action type |  Input Switch. | 
| Input attachment | The file input to switch to. The input must already be set up as an [input attachment](creating-a-channel-step2.md) in this channel.For example, if you want to switch from input A to input B, specify input B in this field. | 
| Dynamic input setting – URL path for input source A | This field appears if the input is set up as a [dynamic input](dynamic-inputs.md). Enter a value to replace the \$1urlPath\$1 portion of the URL for source A in the input. A hint below the fields shows the URL path that you created for this source. | 
| Dynamic input setting – Use the same URL path for input source B | This field appears if the input is attached to a standard channel, meaning that it has two pipelines and therefore has two sources.Enable this field (the default) if you want to use the same value for the `$urlPath$` in source A and source B.Disable this field to use a different value, then enter the value. | 
| Input clippings settings – Enable input clipping | This field appears only for a file input.Enable the field if you want to clip the file at the start and end, or only at the start, or only at the end. | 
| Input clippings settings – Input timecode source |  Choose the source: Zero-based – To set the start and end times relative to the start of the file, which is 00:00:00:00. Embedded – To set the times based on the timecode in the file. The file must have a timecode, otherwise the clipping instruction is ignored.  | 
| Input clippings settings – Start timecode, Stop timecode |  Complete one or both fields. Enter values in the format hh:mm:ss:ff.  | 
| Input clippings settings – Last frame clipping behavior | This field appears only if you specify a stop timecode. Exclude last frame – Clip the file before the frame specified in the end timecode. For example, if the end timecode is 01:00:30:19, don't include frame 19.Include last frame – Don't clip the file. In the preceding example, include frame 19. | 
| Start type  | Fixed, Immediate, or Follow. For information about start types for input prepare, see [Fixed, immediate, and follow switches](ips-switch-types.md). | 
| Date and time | If the Start type is Fixed, specify the date and time (in UTC format) when the channel must switch to this new input. This time must be at least 30 seconds in the future.Note that the time is the wall clock time, not the timecode in the input. | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to switch from, which is the input that precedes this new input. The dropdown list shows all existing input switches that are file inputs. Remember that input B can follow input A only if input A is a file input. For information about these switching rules, see [Fixed, immediate, and follow switches](ips-switch-types.md). For example, if you want to switch from input A to input B, specify input A in this field.  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the switch will occur when the input in Reference action name has finished. | 

# Fields for an input prepare
<a name="schedule-fields-for-input-prep"></a>

This section describes how to complete the fields for these three types of input prepares:
+ A prepare of a static live input 
+ A prepare of a static file input 
+ A prepare of a dynamic file input

## Fields for a prepare of a static live input
<a name="sched-fields-prep-static-live"></a>

This table shows the fields that apply for an action to prepare a static live input. 


| Field | Description | 
| --- | --- | 
| Action name |  A name for this input prepare.  | 
| Action type |  Input Prepare. | 
| Input attachment | The live input to prepare. The input must already be set up as an [input attachment](creating-a-channel-step2.md) in this channel. | 
| Start type  | Fixed, Immediate, or Follow. For information about start types for input prepare, see [Types of starts for input prepares](plan-prep-start-types.md). | 
| Date and time | If the Start type is Fixed, specify the date and time (in UTC format) that the channel must start to prepare the input. This time should be at least 10 seconds before the upcoming input switch.Note that the time is the wall clock time, not the timecode in the input. | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to follow. This input is the input whose end you want to use as the trigger for the input prepare. It is not the input for the upcoming input switch. The dropdown list shows all existing input switches. If the input switch that you want to use as the reference (trigger) isn't listed, you need to first create that input switch. For information about start types for input prepare, see [Types of starts for input prepares](plan-prep-start-types.md).  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the input prepare will occur when the input in Reference action name has finished. | 

## Fields for a prepare of a static file input
<a name="sched-fields-prep-static-file"></a>

This table shows the fields that apply for an action to prepare a static file input. 


| Field | Description | 
| --- | --- | 
| Action name |  A name for this input prepare.  | 
| Action type |  Input Prepare. | 
| Input attachment | The file input to prepare. The input must already be set up as an [input attachment](creating-a-channel-step2.md) in this channel. | 
| Input clippings settings – Enable input clipping | This field appears only for a file input that is [eligible for input clipping](input-clipping.md).Enable the field if the upcoming input switch (which you are preparing) will also be clipped. You must set up the prepare action with identical clipping instructions as the switch action. | 
| Input clippings settings – Input timecode source |  Choose the source: Zero-based – To set the start and end times relative to the start of the file, which is 00:00:00:00. Embedded – To set the times based on the timecode in the file. The file must have a timecode, otherwise the clipping instruction is ignored. Make sure you choose the same source in this prepare action and the upcoming switch action.  | 
| Input clippings settings – Start timecode, Stop timecode |  Complete one or both fields. Enter values in the format hh:mm:ss:ff. Make sure you enter the same values in this prepare action and the upcoming switch action.  | 
| Input clippings settings – Last frame clipping behavior | This field appears only if you specify a stop timecode. Exclude last frame – Clip the file before the frame specified in the end timecode. For example, if the end timecode is 01:00:30:19, don't include frame 19.Include last frame – Don't clip the file. In the preceding example, include frame 19.Make sure you choose the same option in this prepare action and the upcoming switch action. | 
| Start type  | Fixed, Immediate, or Follow. For information about start types for input prepare, see [Types of starts for input prepares](plan-prep-start-types.md). | 
| Date and time | If the Start type is Fixed, specify the date and time (in UTC format) that the channel must start to prepare this input. This time should be at least 10 seconds before the upcoming input switch.Note that the time is the wall clock time, not the timecode in the input. | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to follow. This input is the input whose end you want to use as the trigger for the input prepare. It is not the input for the upcoming input switch. The dropdown list shows all existing input switches. If the input switch that you want to use as the reference (trigger) isn't listed, you need to first create that input switch. For information about start types for input prepare, see [Types of starts for input prepares](plan-prep-start-types.md).  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the input prepare will occur when the input in Reference action name has finished. | 

## Fields for a prepare of a dynamic file input
<a name="sched-fields-prep-static-dynamic"></a>

This table shows the fields that apply for an action to prepare a dynamic file input. 


| Field | Description | 
| --- | --- | 
| Action name |  A name for this input prepare.  | 
| Action type |  Input Prepare. | 
| Input attachment | The file input to prepare. The input must already be set up as an [input attachment](creating-a-channel-step2.md) in this channel. | 
| Dynamic input setting – URL path for input source A | This field appears if the input is set up as a [dynamic input](dynamic-inputs.md). Enter a value to replace the `$urlPath$` portion of the URL for source A in the input. A hint below the fields shows the URL path that you created for this source.Make sure you enter the same values in this prepare action and the upcoming switch action. | 
| Dynamic input setting – Use the same URL path for input source B | This field appears if the input is attached to a standard channel, meaning that it has two pipelines and therefore has two sources.Enable this field (the default) if you want to use the same value for the `$urlPath$` in source A and source B.Disable this field to use a different value, then enter the value.Make sure you choose the same option in this prepare action and the upcoming switch action. | 
| Input clippings settings – Enable input clipping | This field appears only for a file input that is [eligible for input clipping](input-clipping.md).Enable the field if the upcoming input switch (which you are preparing) will also be clipped. You must set up the prepare action with identical clipping instructions as the switch action. | 
| Input clippings settings – Input timecode source |  Choose the source: Zero-based – To set the start and end times relative to the start of the file, which is 00:00:00:00. Embedded – To set the times based on the timecode in the file. The file must have a timecode, otherwise the clipping instruction is ignored. Make sure you choose the same source in this prepare action and the upcoming switch action.  | 
| Input clippings settings – Start timecode, Stop timecode |  Complete one or both fields. Enter values in the format hh:mm:ss:ff. Make sure you enter the same values in this prepare action and the upcoming switch action.  | 
| Input clippings settings – Last frame clipping behavior | This field appears only if you specify a stop timecode. Exclude last frame – Clip the file before the frame specified in the end timecode. For example, if the end timecode is 01:00:30:19, don't include frame 19.Include last frame – Don't clip the file. In the preceding example, include frame 19.Make sure you choose the same option in this prepare action and the upcoming switch action. | 
| Start type  | Fixed, Immediate, or Follow. For information about start types for input prepare, see [Types of starts for input prepares](plan-prep-start-types.md). | 
| Date and time | If the Start type is Fixed, specify the date and time (in UTC format) that the channel must start to prepare this input. This time should be at least 10 seconds before the upcoming input switch.Note that the time is the wall clock time, not the timecode in the input. | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to follow. This input is the input whose end you want to use as the trigger for the input prepare. It is not the input for the upcoming input switch. The dropdown list shows all existing input switches. If the input switch that you want to use as the reference (trigger) isn't listed, you need to first create that input switch.  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the input prepare will occur when the input in Reference action name has finished. | 

# Fields for activating a global image overlay
<a name="schedule-fields-for-activate-image"></a>

This table shows the fields that apply for an action to activate an image overlay. 


| Field | Description | 
| --- | --- | 
| Action type | Static Image Activate. | 
| Action name | A name for this activation action. For example, the layer and the name of the image to overlay.  | 
| Start type  | Fixed or Immediate. | 
| Date and time |  The date and time (in UTC format) that the channel must activate the image overlay. The time should be at least 60 seconds later than the time that you submit the action.  Note that the time is the wall clock time, not the timecode in the input.  | 
| Input location | Enter the locations (URLs) on the server where the image file is stored.Also complete **Credentials**, if the server requires that you provide user credentials. | 
| Other fields | Complete these fields to control the layer, position, look (such as fade-in), and other behavior of the image.  | 

# Fields for deactivating a global image overlay
<a name="schedule-fields-for-deactivate-image"></a>

This table shows the fields that apply for an action to deactivate an image overlay. 


| Field | Description | 
| --- | --- | 
| Action type | Static Image Deactivate.  | 
| Action name | A name for this deactivation action. For example, the name of the image. Or a name that ties back to the activation action plus the term "deactivate." | 
| Start type  | Fixed or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the date and time (in UTC format) that the channel must deactivate the image overlay. The time should be at least 60 seconds later than the time that you submit the action.  Note that the time is the wall clock time, not the timecode in the input.  | 
| Layer | Enter the layer that contains the image overlay that you want to deactivate. A value 0 to 7. Default is 0. | 
| Fade out |  Enter the time in milliseconds for the image to fade out. Default is 0 (no fade-out).  | 

# Fields for activating a per-outputs image overlay
<a name="schedule-fields-activate-image-per-output"></a>

This table shows the fields that apply for an action to activate an image overlay. 


| Field | Description | 
| --- | --- | 
| Action type | Static Image Output Activate. | 
| Action name | A name for this activation action. For example, the layer and the name of the image to overlay.  | 
| Start type  | Fixed or Immediate. | 
| Date and time |  The date and time (in UTC format) that the channel must activate the image overlay. The time should be at least 60 seconds later than the time that you submit the action.  Note that the time is the wall clock time, not the timecode in the input.  | 
| Input location | Enter the locations (URLs) on the server where the image file is stored.Also complete **Credentials**, if the server requires that you provide user credentials. | 
| Other fields | Complete these fields to control the layer, position, look (such as fade-in), and other behavior of the image.  | 

# Fields for deactivating a per-outputs image overlay
<a name="schedule-fields-deactivate-image-per-output"></a>

This table shows the fields that apply for an action to deactivate the image. The deactivate action operates on one per-output layer that you specify and on the outputs that you specify. It doesn't operate on a specific image. 

To understand how this statement is significant, consider this example. You might specify layer 4 and outputs A and C. Layer 4 in output A contains the image overlay X, output B contains image overlay X, and output C contains image X. MediaLive removes X from output A, and removes Y from output C. Image X in output B will remain active.


| Field | Description | 
| --- | --- | 
| Action type | Static Image Output Deactivate.  | 
| Action name | A name for this deactivation action. For example, the name of the image. Or a name that ties back to the activation action plus the term "deactivate." | 
| Start type  | Fixed or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the date and time (in UTC format) that the channel must deactivate the image overlay. The time should be at least 60 seconds later than the time that you submit the action.  Note that the time is the wall clock time, not the timecode in the input.  | 
| Outputs | Select the output or outputs where you want to deactivate a specific layer. | 
| Layer | Identify the layer that you want to deactivate. Enter a value 0 to 7. Default is 0. | 
| Fade out |  Enter the time in milliseconds for the image to fade out. Default is 0 (no fade-out).  | 

# Fields for activating a motion graphics overlay
<a name="schedule-fields-for-mg"></a>

This table shows the fields that apply for an action to activate a motion graphics overlay. 


| Field | Description | 
| --- | --- | 
| Action type | Motion Graphics Activate. | 
| Action name | A name for this activation action. For example, the name of the motion graphic asset.  | 
| Start type  | Fixed or Immediate. | 
| Date and time |  The date and time (in UTC format) that the channel must activate the motion graphics overlay. The time should be at least 60 seconds later than the time that you submit the action.  Note that the time is the wall clock time, not the timecode in the input.  | 
| Duration | Optional. The duration in milliseconds for the motion graphic to remain on the video. If you omit this field or set it to 0, the duration is unlimited and the motion graphic will remain until you create a deactivate action. | 
| URL | The URL of the motion graphics asset. This asset is always an HTML file. The URL follows this syntax:`<protocol>://<path>/<file>.html`For example:`https://example.com/ticker_tape.html` | 
| Credentials |  Complete this section only if the server where the motion graphics asset is stored requires user authentication from MediaLive. Enter the user name provided by the owner of the server. For the password, enter the name of the password stored on the AWS Systems Manager Parameter Store. Don't enter the password itself. For more information, see [Requirements for AWS Systems Manager password parameters](requirements-for-EC2.md).  | 

# Fields for deactivating a motion graphics overlay
<a name="schedule-fields-for-mg-deactivate"></a>

This table shows the fields that apply for an action to deactivate an motion graphics overlay. 


| Field | Description | 
| --- | --- | 
| Action type | Motion Graphics Deactivate.  | 
| Action name | A name for this deactivation action. For example, deactivate\$1motion\$1graphic. | 
| Start type  | Fixed or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the date and time (in UTC format) that the channel must deactivate the motion graphics overlay. The time should be at least 60 seconds later than the time that you submit the action.  Note that the time is the wall clock time, not the timecode in the input.  | 

# Fields for a splice\$1insert message
<a name="schedule-fields-for-splice_insert"></a>

This table shows the fields that apply for an action to insert a splice\$1insert SCTE 35 message. 


| Field | Description | 
| --- | --- | 
| Action type | SCTE 35 Splice Insert. | 
| Action name | A name for this splice\$1insert action. For example, splice\$1insert actions could be numbered sequentially, restarting every day or every month.  | 
| Start type  | Fixed or Follow or Immediate.  | 
| Date and time |  If the **Start type** is **Fixed**, specify the UTC start time for the splice\$1insert action. The time should be at least 15 seconds in the future. Note that the time is the wall clock time, not the timecode in the input.  | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to follow. The dropdown list shows all existing input switches that are file inputs. Remember that a SCTE 35 action can follow input A only if input A is a file input and the source end behavior for input A is *continue*. For information about these switching rules, see [Fixed, immediate, and follow switches](ips-switch-types.md).  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the switch will occur when the input in Reference action name has finished. | 
| Splice event id | The ID for the splice event. Enter an ID for the splice event that is unique among all scheduled and active splice\$1insert messages in this channel. A message is active if the schedule action is in process in the channel and has not completed.  | 
| Duration | The duration for the splice event. Complete in one of these ways:[\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/medialive/latest/ug/schedule-fields-for-splice_insert.html) | 

The splice\$1insert inserted in the transport stream will have the following:

```
      segmentation_event_cancel_indicator = 0 
      out_of_network = 1
      duration_flag = 1
      duration = the specified time
```

Or

```
      segmentation_event_cancel_indicator = 0
      out_of_network = 1
      duration_flag = 0
```

# Fields for a time\$1signal message
<a name="schedule-fields-for-time-signal"></a>

This table shows the fields that apply for an action to insert a time\$1signal SCTE 35 message.


| Field | Description | 
| --- | --- | 
| Action type | SCTE 35 Time Signal. | 
| Action name | A name for this time\$1signal action. For example, you might name time\$1signal actions with a sequential number, restarting every day or every month. | 
| Start type  | Fixed or Follow or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the UTC start time for the time\$1signal. The time should be at least 15 seconds in the future. Note that the time is the wall clock time, not the timecode in the input.  | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to follow. The dropdown list shows all existing input switches that are file inputs. Remember that a SCTE 35 action can follow input A only if input A is a file input and the source end behavior for input A is *continue*. For information about these switching rules, see [Fixed, immediate, and follow switches](ips-switch-types.md).  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the switch will occur when the input in Reference action name has finished. | 
| Add Scte35 descriptors | Choose this button and complete the fields that appear. The descriptors are a standard component of a time\$1signal message. | 

# Fields for a return-to-network message
<a name="schedule-fields-for-return-to-network"></a>

This table shows the fields that apply for an action to insert a return-to-network SCTE 35 message.


| Field | Description | 
| --- | --- | 
| Action type | SCTE 35 Return to Network. | 
| Action name | A name for this return-to-network action. For example, splice0003\$1 return\$1early. | 
|  Start type  | Fixed or Follow or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the UTC start time for the return. The time should be at least 15 seconds in the future. Note that the time is the wall clock time, not the timecode in the input.  | 
| Reference action name |  If the **Start type** is **Follow**, choose the input to follow. The dropdown list shows all existing input switches that are file inputs. Remember that a SCTE 35 action can follow input A only if input A is a file input and the source end behavior for input A is *continue*. For information about these switching rules, see [Fixed, immediate, and follow switches](ips-switch-types.md).  | 
| Follow point | If the Start type is Follow, complete this field. The follow point is always End, to indicate that the switch will occur when the input in Reference action name has finished. | 
| Splice event id | The ID of the splice\$1insert that the return-to-network should end. You assigned this ID when you created the splice\$1insert. | 

# Fields for ID3 metadata
<a name="schedule-fields-for-id3-userdata"></a>

This table shows the fields that apply for an action to perform a one-time insertion of ID3 metadata. MediaLive inserts the metadata as base64.


| Field | Description | 
| --- | --- | 
| Action type | HLS Timed Metadata. Choose this option to insert in HLS or MediaPackage outputs.**Timed Metadata**. Choose this option to insert in CMAF Ingest outputs. | 
| Action name | A name for the metadata item. You might want to design a convention for naming ID3 metadata items, such as id3\$1metadata-<UTC time>. | 
|  Start type  | Fixed or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the UTC start time for the ID3 metadata item. The time should be at least 15 seconds in the future. Note that the time is the wall clock time, not the timecode in the input.  | 
| ID3 |  Enter the ID3 metadata encoded as base64. The metadata must be fully formed ID3 metadata (including both a header and a frame, as per the ID3 2.4.0 specification).  The content of the `value` property can include MediaLive [variable data](variable-data-identifiers.md). MediaLive will examine the contents of the base64 and perform substitutions. For example, MediaLive will change **\$1dt\$1** to the date and time.  | 

# Fields for ID3 segment tags
<a name="schedule-fields-for-id3-segment-tags"></a>

This table shows the fields that apply for an action to insert ID3 metadata in every segment. There are two options for inserting the metadata:
+ The **tag** option, to insert metadata as plain text.
+ The **ID3** option, to insert metadata as base64.

For details about the types of output groups that support each option, see the table in [Different mechanisms for including metadata](id3-enable-result.md).


| Field | Description | 
| --- | --- | 
| Action type | HLS ID3 Segment Tagging. Choose this option to insert in HLS or MediaPackage outputs.**ID3 Segment Tagging**. Choose this option to insert in CMAF Ingest outputs. | 
| Action name | A name for the segment tag.  | 
|  Start type  | Fixed or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the UTC start time for the ID3 segment tag. The time should be at least 15 seconds in the future. Note that the time is the wall clock time, not the timecode in the input.  | 
| Tag | Complete this field if the content of the tag is free text. Enter the value for a TXXX field inside the ID3 tag. MediaLive creates an ID3 tag with a single TXXX field and inserts the tag in every segmenThe content can include MediaLive [variable data](variable-data-identifiers.md). In the following example, the content consists of the date and time, and the current segment number. The tag contents will be different in each segment.**\$1dt\$1-\$1sn\$1** | 
| ID3 | Complete this field if the content of the tag is ID3 metadata. Enter the content encoded as base64. The metadata must be fully formed ID3 metadata (including both a header and a frame, as per the ID3 specification).  | 

# Fields for pause
<a name="schedule-fields-for-pause"></a>

In **Schedule action settings**, complete the following fields.


| Field | Description | 
| --- | --- | 
| Action type | Pause. | 
| Action name | A name for the action.  | 
|  Start type  | Fixed or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the UTC start time for the action. The time should be at least 15 seconds in the future. Note that the time is the wall clock time, not the timecode in the input.  | 
| Actions | Choose Add actions, then for Pipeline id, choose the pipeline that you want to pause: PIPELINE\$10 or PIPELINE\$11.  | 

When you choose **Create**, MediaLive adds an action to the schedule to pause the specified pipeline and to unpause any pipeline that isn't specified. As a result, only the specified pipeline will be paused after the action is performed.

# Fields for unpause
<a name="schedule-fields-for-unpause"></a>

In **Schedule action settings**, complete the following fields.


| Field | Description | 
| --- | --- | 
| Action type | Pause. | 
| Action name | A name for the action.  | 
|  Start type  | Fixed or Immediate. | 
| Date and time |  If the **Start type** is **Fixed**, specify the UTC start time for the action. The time should be at least 15 seconds in the future. Note that the time is the wall clock time, not the timecode in the input.  | 
| Actions | Keep this section empty. Don't add any actions.  | 

When you choose **Create**, the empty **Actions** section instructs MediaLive to add an action to the schedule to unpause all pipelines.

# Deleting actions from the schedule (console)
<a name="schedule-using-console-delete"></a>

These rule apply when you add delete actions to the schedule:
+ In a single-input channel (a channel that doesn't involve input switching), you can delete actions as follows: 
  + You can delete an action with a start time that is more than 15 seconds in the future. The channel won't perform the action.
  + You can delete an action that has already been performed. Deleting this action doesn't reverse the action, it only removes it from the schedule.
+ In a multiple-input channel, you can delete actions as follows:
  + You can delete an action with a start time that is more than 15 seconds in the future. The channel won't perform the action.

    There are some constraints that apply to deleting inputs switches and input prepare, event when they are in the future. For more information, see [Deleting actions from the schedule](ips-manage-schedule.md) and [Deleting and stopping input prepare actions in the MediaLive schedule](input-prep-delete.md).
  + You can delete an action that has already been performed. Deleting this action doesn't reverse the action, it only removes it from the schedule.

    There are some constraints that apply to deleting inputs switches and input prepare, event when they are in the future. For more information, see [Deleting actions from the schedule](ips-manage-schedule.md) and [Deleting and stopping input prepare actions in the MediaLive schedule](input-prep-delete.md).

**Deleting versus reversing**

It is important to understand that deleting a stale action from the schedule doesn't reverse its effect in the channel. For example, if you have paused the channel, and the channel has performed the action, you unpause the channel by entering a new action. You don't unpause it by deleting the action.

**Note**  
If the channel has already received the action, you might be able to modify it to effectively delete it. For more information, see [Modifying actions in the schedule (console)](schedule-modify.md).

You can delete any number of actions in one request, or any combination of types of actions in one request. For example, you can mix the deletion of SCTE 35 message actions and image overlay actions.

The general procedure is the same to delete any type of action.

**To delete actions in list view**

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

1. In the navigation pane, choose **Channel**, and then choose the channel that you want to work with.

1. On the **Details** pane, choose the **Schedule** tab.

1. If necessary, choose the **Switch** button to display the **List** view. For information about the layout and color coding of the timeline view, see [Viewing the schedule (console)](schedule-using-console-view.md).

1. Choose one or more actions to delete.

   If you choose an input switch that is in an input follow chain, a prompt appears. This prompt notifies you that all the follow input switch actions and the follow SCTE 35 actions up to the next fixed input switch will also be deleted. You can cancel or continue. 

   Choose **Actions**, and then choose **Delete**.

**To delete actions in timeline view (console)**

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

1. In the navigation pane, choose **Channel**, and then choose the channel that you want to work with.

1. On the **Details** pane, choose the **Schedule** tab.

1. If necessary, choose the **Switch** button to display the **Timeline** view. For information about the layout and color coding of the timeline view, see [Viewing the schedule (console)](schedule-using-console-view.md).

1. In each action section, choose the **X** to delete the action.

   If you choose an input switch that is in an input follow chain, a prompt appears to notify you that the follow actions below this action (up to the next fixed input switch) will also be deleted. You can cancel or continue. 

# Modifying actions in the schedule (console)
<a name="schedule-modify"></a>

You can't modify an action in the schedule, even if it hasn't been received by the channel. However, you can sometimes achieve a modify effect using a create action, a delete action, or both.

**Topics**
+ [

## General rule about modifying actions
](#modify-action-not-started)
+ [

## Modifying an input switch action
](#schedule-modify-ips)
+ [

## Modifying an input switch action in a follow chain
](#schedule-modify-ips-follow)
+ [

## Inserting an input switch action into a follow chain
](#schedule-insert-follow)
+ [

## Modifying an input prepare action
](#schedule-modify-prep)
+ [

## Modifying an image overlay that is in progress
](#schedule-modify-image-overlay)
+ [

## Modifying a motion graphics overlay that is in progress
](#schedule-modify-mg)

## General rule about modifying actions
<a name="modify-action-not-started"></a>

You can't modify an action in the schedule, even if it hasn't been received by the channel. 

To change an action that hasn't yet started, delete the action and create it again. See the following sections for important tips on deleting and recreating.

## Modifying an input switch action
<a name="schedule-modify-ips"></a>

You can't modify input switches in the schedule. But you can achieve the same result by deleting the action and creating it again. 

Keep in mind that you can't delete or create an action that has a start time less than 15 seconds in the future. Give yourself enough time to delete and recreate the action before this deadline.

## Modifying an input switch action in a follow chain
<a name="schedule-modify-ips-follow"></a>

When you delete an action in an *input follow chain* (in order to delete and recreate it), you must also delete and recreate the input switch follow actions and SCTE 35 follow actions below this one. You must do this because each action refers to the previous action. If you delete the previous action, the next action becomes an orphan. Orphan actions aren't permitted. 

**Example 1: Modify an action**  
For example, assume this is the input follow chain:

```
Input A              Fixed    File
           Input B   Follow   File
           Input C   Follow   File
           Input D   Follow   File or Live
Input E              Fixed    File or Live
```

To delete and modify input A, you must also delete inputs B, C, and D. You must delete input B to prevent it becoming an orphan. The same rule applies until the next fixed input (input E), which isn't chained to another input. Therefore, you aren't required to delete input E.

When you delete input A using the console, a prompt appears to notify you that the follow actions below this action (up to input E, which is the next fixed input switch) will also be deleted. You can cancel or continue. You must then recreate inputs A to D. Recreate them in order going down the chain: input A, input B, input C, input D.

**Example 2: Delete an action**  
This example shows how to delete input B: 

```
Input A              Fixed    File
           Input B   Follow   File
           Input C   Follow   File
           Input D   Follow   File or Live
Input E              Fixed    File or Live
```

When you delete input B using the console, a prompt appears to notify you that the follow actions below this action (up to input E, which is the next fixed input switch) will also be deleted. You can cancel or continue. You must then recreate inputs C and D. Recreate them in order going down the chain: input C, input D. Remember to set up input C to follow input A instead of input B. 

## Inserting an input switch action into a follow chain
<a name="schedule-insert-follow"></a>

To insert a follow switch action into an *input follow chain* (between two existing follow switch actions), you must delete and recreate the follow actions below the insertion. You do that to prevent two actions from following one previous action. Branching is not allowed in the chain. 

For example, suppose that you want to insert input X between input B and input C. Input C already refers to input B. You also want input X to refer to input B, but that is not allowed. Therefore, you must delete input C and the inputs that follow. You then recreate the chain in the following order: input X (refers to input B), input C (refers to input X), input D (refers to input C).

## Modifying an input prepare action
<a name="schedule-modify-prep"></a>

You can't modify input switches in the schedule. But you can achieve the same result by deleting the action and creating it again. 

Keep in mind that you can't delete or create an action that has a start time less than 15 seconds in the future. Give yourself enough time to delete and recreate the action before this deadline.

### Modifying a SCTE 35 message that is in progress
<a name="schedule-modify-scte35"></a>

You can't modify a SCTE 35 message that is active in the channel. Specifically, you can't shorten the duration of a splice\$1insert. But you can achieve the same result by creating a return-to-network action. 

### Modifying or deleting an ID3 segment tag that is in progress
<a name="schedule-modify-id3segmenttag"></a>

You can't modify the contents of an ID3 segment tag that is active in the channel. Instead, create a new action to override the active tag. The new action can contain a tag with new content, or it can contain an empty tag:
+ If the new action contains a tag with content, the channel starts inserting the contents of the new action into every segment.
+ If the new action contains an empty tag, the channel stops inserting segment tags, which means you have effectively deleted the tag.

## Modifying an image overlay that is in progress
<a name="schedule-modify-image-overlay"></a>

You can't directly modify an image overlay (either global or per-outputs) that is running in the channel. But you can achieve the same result by creating a new action with the same layer specified. You can do the following:
+ Shorten or extend the duration of an image overlay.
+ Change one or more attributes.
+ Specify an attribute that isn't currently specified in an image overlay. For example, you might want to specify a fadeout where there is no fadeout in the current overlay. 
+ Create a new action (with a new action name) that inserts an image overlay 15 seconds in the future. Make sure to specify the following:
  + The same layer as the image that you want to modify.
  + A duration that is appropriate (the image doesn't inherit the duration of the current image). 
  + All the attributes that you want. 

  The new action replaces the current action because you specified the same layer. 

## Modifying a motion graphics overlay that is in progress
<a name="schedule-modify-mg"></a>

You can't modify a motion graphic overlay that is running in the channel. But you can achieve the same result in other ways. For example, the authoring system (that produces the motion graphic asset) can modify the content that is being published to the URL associated with the action. For information about preparing and publishing the motion graphics asset, see [Step 1: Prepare the motion graphic asset](mgi-prepare-asset.md).

# Viewing the schedule (console)
<a name="schedule-using-console-view"></a>

You can display the list of actions currently in the schedule and view them in list or timeline view.

**To view actions (console)**

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

1. In the navigation pane, choose **Channel**, and then choose the channel that you want to work with.

1. On the **Details** pane, choose the **Schedule** tab.

   The **Schedule actions** pane shows the actions in the schedule's current window of time. 

   You can switch between the two views of the schedule by choosing the **Switch** button. 

**List view**  
The actions are mostly listed in chronological order.

Input switches in an input follow chain are grouped together starting from the top of the chain (which is the action above the first follow action) to the last follow action. Other actions, such as actions for SCTE 35 and image overlay, might occur between two follow actions. MediaLive can't predict whether a SCTE 35 or image overlay action will occur between two follow actions and doesn't attempt to show it in the list view. 

**Timeline view**  
The actions are arranged in cards along a vertical axis. The card titles are color-coded by the action type. For example, SCTE 35 time\$1signal messages are yellow.

One card might contain several input switches. The first input switch is always a fixed-type input switch. The remaining input switches in that card are always follow-type input switches.

# Working with the schedule (AWS CLI)
<a name="schedule-using-cli"></a>

You can use the AWS CLI to work with the schedule programmatically. The sections later in this chapter describe how to enter the appropriate commands. These sections assume that you are familiar with the basics of using the AWS CLI. For information about the basics, see the [AWS CLI Command Reference](https://docs.aws.amazon.com/cli/latest/reference/). 

The following sections describe each command and provide this additional information:
+ A description of the AWS CLI command syntax.
+ A description of the schema for the request or response JSON payload. This payload is shown using the syntax for the AWS CLI. 
+ An example of the request or response JSON payload. This payload is also shown using the syntax for the AWS CLI.

For details on the JSON contents, we recommend that you read the [AWS Elemental MediaLive API Reference](https://docs.aws.amazon.com/medialive/latest/apireference/). This guide is easy to use because it includes links from elements in the JSON payload to tables that describe the element. But you must adjust the syntax of the elements in the JSON code because the AWS CLI uses one form of capitalization for elements (for example, `SubSegmentNum`) and the API uses another form (for example, `subSegmentNum`). 

**Topics**
+ [

# Creating and deleting using a batch command
](about-batch-update-schedule.md)
+ [

# Submitting a batch update schedule command
](submitting-batch-command.md)
+ [

# JSON payload for create actions
](schedule-create-json.md)
+ [

# JSON payload for delete actions
](cli-schedule-delete-json.md)
+ [

# JSON payload for combining create and delete
](schedule-create-and-delete-json.md)
+ [

# Viewing the schedule (AWS CLI)
](viewing-schedule-using-cli.md)

# Creating and deleting using a batch command
<a name="about-batch-update-schedule"></a>

To create and delete actions in the schedule for a channel, you use the batch update schedule command. This command lets you perform multiple actions in one request. There isn't one command for creating actions and another for deleting actions.

**Important**  
When working with a started and running channel, use the **batch-update-schedule** command to add or remove actions. Use the **delete-schedule** command only on idle channels. The **delete-schedule** command will delete all scheduled actions and could cause service interruptions if used on a live channel. 

You can use the command as follows:
+ Submit a *single* request such as a request to do the following:
  + Create one action.
  + Delete one action.
+ Submit a *batch* request such as one request to do the following:
  + Create several actions.
  + Delete several actions.
  + Create one or more actions and delete one or more actions.

**Important**  
In a command that combines create actions and delete actions, the delete actions are *always* performed before the create actions. This means that MediaLive removes the delete actions from the schedule before it adds the create actions to the schedule.

**Topics**
+ [

# How a batch request works
](how-batch-schedule-requests-work.md)
+ [

# Batch command in different interfaces
](batchupdatecommand-interfaces.md)
+ [

# JSON payload in different interfaces
](batchupdatecommand-payloads.md)

# How a batch request works
<a name="how-batch-schedule-requests-work"></a>

The intention of batching is to pass or fail all the actions together. Therefore, AWS Elemental MediaLive validates batch actions together. MediaLive performs the following validation:
+ It ensures that each action that is created or deleted has an explicit or implied start time that is at least 15 seconds in the future. 
+ If an action refers to an existing action in the schedule, it ensures that the reference to the existing action is correct. For example, a follow input switch includes a reference to the action that it follows. That action must exist.

If the validation fails for any one action, it fails for all the actions in the batch.

If you don't want the actions to pass or fail together, don't submit a batch. Instead, create each action in its own batch update schedule command.

If the validation succeeds, MediaLive processes all the delete requests before the create requests, regardless of the start times of the actions.

**Example 1**  
An important use of batching is to perform several actions that must pass or fail together. For example, suppose that you want to remove the corporate logo and immediately insert a splice\$1insert (in order to go to an ad avail). To do that, you must create an action to remove the logo and another action to insert the splice\$1insert. However, you don't want MediaLive to insert the remove action if the splice\$1insert action fails, or vice versa. It's better if both actions fail because that allows you to fix the badly formed action, and then submit both actions again.

You therefore submit the two actions together, in one batch update schedule command. 

**Example 2**  
Another important use of batching is to fix an error in an action in the schedule. For example, you might want to fix an image overlay that hasn't started yet and that was created with the wrong start time. To do that, you submit one batch update schedule command with JSON that contains the following:
+ A payload to remove the original action to activate the image overlay. This action has the incorrect start time.
+ A payload to add a new action to activate the same image overlay. This action has the correct start time.

# Batch command in different interfaces
<a name="batchupdatecommand-interfaces"></a>

The batch update schedule command is represented differently in different interfaces: 
+ In the AWS CLI, the command is `batch-update-schedule`.
+ In the API, the command is represented by an `HTTP PUT` on `channels/channelId/schedule`.
+ In the AWS SDKs, the command is represented by constructs that are suitable to that SDK language.

# JSON payload in different interfaces
<a name="batchupdatecommand-payloads"></a>

The JSON payload for the command is different for the different interfaces:
+ In the AWS CLI, the contents of the payload depend on how you use the command:
  + You can enter a command with two parameters: `channel-id` and `--cli-input-json`. In this case, you create a file that repeats the channel ID and includes the JSON payload. 
  + You can enter a command with three parameters: one for the channel ID, one for the JSON payload for the create actions (if applicable), and one for the JSON payload for the delete actions (if applicable). You pass the payloads in the command. If both parameters are present, each parameter takes a separate payload. But the two payloads are validated and performed as a batch. 

  The payload for the AWS CLI is always pascal case (upper camel case). 
+ In the API, there is one payload with two sections, a `CREATES` section and a `DELETES` section. A request can contain one or both sections. 

  The payload for the API is always camel case for variable names and pascal case for classes.
+ In the AWS SDKs, the JSON payload is represented by constructs that are suitable to that SDK language. 

To get more familiar with individual actions, we recommend that you use the MediaLive console to create an action. After you create the action, use the [DescribeSchedule](viewing-schedule-using-cli.md) command in the appropriate interface (for example, the AWS CLI or an SDK) to obtain the raw JSON payload for the entire schedule. You can then copy individual actions and save them as models to use when working programmatically.

# Submitting a batch update schedule command
<a name="submitting-batch-command"></a>

The command for a batch update schedule command is identical for creating actions, deleting actions, or submitting a combination of create and delete actions. The command is identical. Only the contents of the JSON payload differ.

There are different ways to enter the command to create an action. We recommend that you follow this usage:
+ Enter the command with two parameters: `channel-id` and `--cli-input-json`. In this case, you create a file that repeats the channel ID and includes the JSON payload. 

The instructions and examples in this section illustrate this usage. 

The following general rules apply to batch update commands:
+ You can create actions when the channel is running or when it is idle. 
+ You can create any number of actions in one request, or any combination of types of actions in one request. For example, you can mix the creation of SCTE 35 message actions and image overlay actions. 
+ If you create several actions in one request and one of the create requests fails (usually because the start time isn't sufficiently in the future), then they all fail.

The following rules apply to delete actions:
+ You can delete an action when the channel is running or when it is idle. 
+ You can delete any number of actions in one request, or any combination of types of actions in one request. For example, you can mix the deletion of SCTE 35 message actions and image overlay actions. 
+ If you delete several actions in one request and one of the delete requests fails (usually because the start time isn't sufficiently in the future), then they all fail.

**To submit a batch command**

1. Before you add or delete actions, read [Creating actions in the schedule (console)](schedule-using-console-create.md) and [Deleting actions from the schedule (console)](schedule-using-console-delete.md).

1. Prepare a file that contains the channel ID and the appropriate JSON payload for the actions. For the structure and examples of the JSON payload for different actions, see the sections that follow. 

1. Give the file a suitable name with a `.txt` extension. For example, the file name for a payload that creates only actions might be `schedule-create-actions.txt`. 

1. Save the file to the folder where you are running the AWS CLI.

1. On the command line, enter this command:

   `AWS medialive batch-update-schedule --channel-id value --cli-input-json value`
   + In the value for `--channel-id`, enter the channel ID as a number.
   + In the value for `--cli-input-json`, enter the file name in this format:

     `file://filename.txt`

   For example: 

   `aws medialive batch-update-schedule --channel-id 999999 --cli-input-json schedule-create-actions.txt`

1. To submit the command, press **Enter**. The response appears on the screen. The response repeats the data from the request.

# JSON payload for create actions
<a name="schedule-create-json"></a>

The following sections show the structure of the payload and an example of the payload for every type of create action for a MediaLive schedule.

**Topics**
+ [

# Input switch action – payload
](cli-schedule-fields-for-input-switch.md)
+ [

# Input prepare action – payload
](cli-schedule-fields-for-input-prep.md)
+ [

# Activate global image action – payload
](cli-schedule-fields-for-activate-image.md)
+ [

# Deactivate global overlay action – payload
](cli-schedule-fields-for-deactivate-image.md)
+ [

# Activate per-outputs image action – payload
](cli-schedule-fields-for-activate-image-per-output.md)
+ [

# Deactivate per-outputs overlay action – payload
](cli-schedule-fields-for-deactivate-image-per-output.md)
+ [

# Activate motion graphic overlay – payload
](cli-schedule-fields-activate-mgi.md)
+ [

# Deactivate motion graphic overlay – payload
](cli-schedule-fields-deactivate-mgi.md)
+ [

# Splice\$1insert message – payload
](cli-schedule-fields-for-splice-insert.md)
+ [

# Time\$1signal message – payload
](cli-schedule-fields-for-time-signal.md)
+ [

# Return-to-network message – payload
](cli-schedule-fields-for-return-network.md)
+ [

# ID3 metadata item – payload
](cli-schedule-fields-for-id3.md)
+ [

# ID3 segment tag item – payload
](cli-schedule-fields-id3-segment-tag.md)
+ [

# Pause pipeline action – payload
](cli-schedule-fields-for-pause.md)
+ [

# Combination of create actions
](cli-example-multiple-creates.md)

# Input switch action – payload
<a name="cli-schedule-fields-for-input-switch"></a>

The following sections show the payload for input switch actions. 

In this payload, the `ScheduleActionStartSettings` contains only one of `FixedModeScheduleActionStartSettings`, `ImmediateModeScheduleActionStartSettings`, or `FollowModeScheduleActionStartSettings`.

See the examples that follow for samples of each of these tags.

For information about the meaning and values for the fields in the following JSON, see [Fields for an input switch](schedule-fields-for-ips.md).

```
{
"ChannelId": "string",
"Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "FollowModeScheduleActionStartSettings": {
     "FollowPoint": "enum",
     "ReferenceActionName": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "InputSwitchSettings": {
     "InputAttachmentNameReference": "string",
     "InputClippingSettings": {
      "InputTimecodeSource": "enum",
      "StartTimecode": {
       "Timecode": "string"
      },
      "StopTimecode": {
       "LastFrameClippingBehavior": "enum",
       "Timecode": "string"
      }
     },
     "UrlPath": ["string", ...]
    }
   }
  ]
 }
}
```

## Example of a switch to a live input with fixed start time
<a name="json-switch-example-1"></a>

This example of a request is to switch to a live input at a fixed start time. The switch action is called `studio-feed` and it switches to the input that is connected to the input attachment called `live-studio-feed`. It switches to this input at the specified UTC time. 

```
{
  "ChannelId": "999999",
  "Creates": {
    "ScheduleActions": [
      {
       "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:19.000Z"
           }
          },
      "ActionName": "studio-feed",
      "ScheduleActionSettings": {
        "InputSwitchSettings": {
          "InputAttachmentNameReference": "live-studio-feed" 
     }
    }
   }
  ]
 }
}
```

## Example of a static file switch as a follow
<a name="json-switch-example"></a>

This example of a request is to switch to a static file input to follow the end of the previous input. The switch action is called `action-ad-003` and it switches to the input that is connected to the input attachment called `zel-cafe`. It switches to this input when the action called `action-ad-002` ends. The file for this action is clipped so that it ends after 30 seconds and 11 frames:

```
{
  "ChannelId": "999999",
  "Creates": {
      "ScheduleActions": [
          {
            "ScheduleActionStartSettings": {
              "FollowModeScheduleActionStartSettings": {
                "FollowPoint": "END",
                "ReferenceActionName": "action-ad-002"
              }
            },
            "ActionName": "action-ad-003",
              "ScheduleActionSettings": {
                 "InputSwitchSettings": {
                    "InputAttachmentNameReference": "zel-cafe",
                      "InputClippingSettings": {
                          "InputTimecodeSource": "ZEROBASED",
               "StopTimecode":{
                 "Timecode": "00:00:30:11",
                 "LastFrameClippingBehavior": "INCLUDE_LAST_FRAME"
       }
      }
     }
    }
   }
  ]
 }
}
```

## Example of a switch to a dynamic input with immediate start time
<a name="json-switch-example2"></a>

This example of a request is to switch to a dynamic file input immediately. The switch action is called `action-unscheduled-standby` and it switches to the input that is connected to the input attachment called `dynamic-unscheduled-standby`. For this usage of the dynamic input, the files to use are `oceanwaves.mp4`.

```
{
  "ChannelId": "999999",
  "Creates": {
    "ScheduleActions": [
      {
        "ScheduleActionStartSettings": 
          {
          "ImmediateModeScheduleActionStartSettings": {
          }
         },
       "ActionName": "action-unscheduled-slate",
        "ScheduleActionSettings": {
          "InputSwitchSettings": {
            "InputAttachmentNameReference": "slate",
            "UrlPath":[
              "main/oceanwaves.mp4",
              "redundant/oceanwaves.mp4"]
     }
    }
   }
  ]
 }
}
```

# Input prepare action – payload
<a name="cli-schedule-fields-for-input-prep"></a>

The following sections show the payload for input switch actions. 

In this payload, the `ScheduleActionStartSettings` contains only one of `FixedModeScheduleActionStartSettings`, `ImmediateModeScheduleActionStartSettings`, or `FollowModeScheduleActionStartSettings`.

See the examples that follow for samples of each of these tags.

For information about the meaning and values for the fields in the following JSON, see [Fields for an input switch](schedule-fields-for-ips.md).

```
{
"ChannelId": "string",
"Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "FollowModeScheduleActionStartSettings": {
     "FollowPoint": "enum",
     "ReferenceActionName": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "InputPrepareSettings": {
     "InputAttachmentNameReference": "string",
     "InputClippingSettings": {
      "InputTimecodeSource": "enum",
      "StartTimecode": {
       "Timecode": "string"
      },
      "StopTimecode": {
       "LastFrameClippingBehavior": "enum",
       "Timecode": "string"
      }
     },
     "UrlPath": ["string", ...]
     }
    }
   }
  ]
 }
}
```

## Example of an input prepare with a fixed start time
<a name="json-prep-example-1"></a>

This example of a request is to switch to a live input at a fixed start time. The switch action is called `studio-feed` and it switches to the input that is connected to the input attachment called `live-studio-feed`. It switches to this input at the specified UTC time. 

```
{
  "ChannelId": "999999",
  "Creates": {
    "ScheduleActions": [
      {
       "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:19.000Z"
           }
          },
      "ActionName": "studio-feed",
      "ScheduleActionSettings": {
        "InputSwitchSettings": {
          "InputAttachmentNameReference": "live-studio-feed"
     }
    }
   }
  ]
 }
}
```

## Example of an input prepare as a follow
<a name="json-prep-example-2"></a>

This example of a request is to switch to a static file input to follow the end of the previous input. The switch action is called `action-ad-003` and it switches to the input that is connected to the input attachment called `zel-cafe`. It switches to this input when the action called `action-ad-002` ends. The file for this action is clipped so that it ends after 30 seconds and 11 frames:

```
{
  "ChannelId": "999999",
  "Creates": {
      "ScheduleActions": [
          {
            "ScheduleActionStartSettings": {
              "FollowModeScheduleActionStartSettings": {
                "FollowPoint": "END",
                "ReferenceActionName": "action-ad-002"
              }
            },
            "ActionName": "action-ad-003",
              "ScheduleActionSettings": {
                 "InputSwitchSettings": {
                    "InputAttachmentNameReference": "zel-cafe",
                      "InputClippingSettings": {
                          "InputTimecodeSource": "ZEROBASED",
               "StopTimecode":{
                 "Timecode": "00:00:30:11",
                 "LastFrameClippingBehavior": "INCLUDE_LAST_FRAME"
              }
            }
          }
        }
      }
    ]
  }
}
```

# Activate global image action – payload
<a name="cli-schedule-fields-for-activate-image"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for activating a global image overlay](schedule-fields-for-activate-image.md).

```
{
"ChannelId": "string",
"Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "StaticImageActivateSettings": {
     "Duration": integer,
     "FadeIn": integer,
     "FadeOut": integer,
     "Height": integer,
     "Image": {
      "PasswordParam": "string",
      "Uri": "string",
      "Username": "string"
     },
     "ImageX": integer,
     "ImageY": integer,
     "Layer": integer,
     "Opacity": integer,
     "Width": integer
     }
    }
   }
  ]
 }
}
```

## Example
<a name="json-activate-image-example"></a>

This example of a request creates an image overlay to be inserted in every video output in every output group in the channel. The overlay uses a file that is stored in an Amazon S3 bucket. The request doesn't include a duration and therefore doesn't include a fadeout. Instead, the intention is to send a separate deactivate request at the appropriate time. All the times are in milliseconds, and all the positioning values are in pixels:

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
      "ScheduleActionStartSettings": {
        "FixedModeScheduleActionStartSettings": {
          "Time": "2018-05-21T20:42:19.000Z"
        }
      },
      "ActionName": "corporate-logo-030",
      "ScheduleActionSettings": {
        "StaticImageActivateSettings": {
          "Image": {
          "PasswordParam": "corplogo!2312",
          "Uri": "s3ssl://amzn-s3-demo-bucket/logos/corporate/high-res.bmp",
          "Username": "medialiveoperator"
          },
          "Layer": 1,
          "FadeIn": 1500,
          "Height": 900
          "Width": 800,
          "ImageX": 200,
          "ImageY": 300,
          "Opacity": 60,
          }
        }
      }
    ]
  }
}
```

# Deactivate global overlay action – payload
<a name="cli-schedule-fields-for-deactivate-image"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for deactivating a global image overlay](schedule-fields-for-deactivate-image.md).

```
{
 "ChannelId": "string",
 "Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "StaticImageDeactivateSettings": {
     "FadeOut": integer,
     "Layer": integer
    }
   }
  }
 ]
}
```

## Example
<a name="json-deactivate-image-example"></a>

This example of a request creates an action to remove an image overlay at 20:42:04.000 (UTC) with a 500-millisecond fadeout that is added onto the end time, which means that the overlay will be invisible at 20:42:04.500. 

The action removes the images overlay that is in the global layer 4. This means it removes the image *only if* it was inserted using the global action (StaticImageActivateSettings). It doesn't remove the overlay from the per-outputs layer 4. 

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
      "ScheduleActionStartSettings": {
        "FixedModeScheduleActionStartSettings": {
          "Time": "2018-05-21T20:42:04.000Z"
        }
      },
      "ActionName": "stop-overlay-029",
      "ScheduleActionSettings": {
        "StaticImageDeactivateSettings": {
          "FadeOut": 500,
          "Layer": 4
          }
        }
      }
    ]
  }
}
```

# Activate per-outputs image action – payload
<a name="cli-schedule-fields-for-activate-image-per-output"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for activating a per-outputs image overlay](schedule-fields-activate-image-per-output.md).

```
{
"ChannelId": "string",
"Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "StaticImageOutputActivateSettings": {
     "Duration": integer,
     "FadeIn": integer,
     "FadeOut": integer,
     "Height": integer,
     "Image": {
      "PasswordParam": "string",
      "Uri": "string",
      "Username": "string"
     },
     "ImageX": integer,
     "ImageY": integer,
     "Layer": integer,
     "Opacity": integer,
     "OutputNames": [
       {}
      ],
     "Width": integer
     }
    }
   }
  ]
 }
}
```

## Example
<a name="json-deactivate-image-per-output-example"></a>

This example of a request creates an image overlay to be inserted in specific outputs in the channel. The overlay uses a file that is stored in an Amazon S3 bucket. The request inserts the image in the outputs `hls-high-res` and `mss-high-res`. The image is sized appropriately for the video resolution in these outputs. 

The request is intended to be always present. Therefore, it is set up to start immediately (as soon as the channel starts). All the times are in milliseconds, and all the positioning values are in pixels:

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
        "ScheduleActionStartSettings": 
          {
          "ImmediateModeScheduleActionStartSettings": {
          }
         },
      },
      "ActionName": "logo-1280",
      "ScheduleActionSettings": {
        "StaticImageOutputActivateSettings": {
          "Image": {
          "PasswordParam": "corplogo!2312",
          "Uri": "s3ssl://amzn-s3-demo-bucket/logos/corporate/10percent-1280.bmp",
          "Username": "medialiveoperator"
          },
          "Layer": 0,
          "outputNames": [
            hls-high-res,mss-high-res
           ],
          "ImageX": 200,
          "ImageY": 300,
          "FadeIn": 1500,
          "Opacity": 60
          }
        }
      }
    ]
  }
}
```

# Deactivate per-outputs overlay action – payload
<a name="cli-schedule-fields-for-deactivate-image-per-output"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for deactivating a per-outputs image overlay](schedule-fields-deactivate-image-per-output.md).

```
{
 "ChannelId": "string",
 "Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "StaticImageOutputDeactivateSettings": {
     "FadeOut": integer,
     "Layer": integer,
     "OutputNames"
    }
   }
  }
 ]
}
```

## Example
<a name="cli-schedule-fields-for-deactivate-image-per-output-example"></a>

The deactivate action deactivates the image in the specified per-output layer, in the specified output or outputs.

In this example, which follows on from the activate example, the action removes all image overlays that are in per-outputs layer 4 in the output hls-high-res. 

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
      "ScheduleActionStartSettings": {
        "FixedModeScheduleActionStartSettings": {
          "Time": "2018-05-21T20:42:04.000Z"
        }
      },
      "ActionName": "stop-layer4-all-outputs",
      "ScheduleActionSettings": {
        "StaticImageOutputDeactivateSettings": {
          "outputNames": [
            hls-high-res
           ],
          "FadeOut": 500,
          "Layer": 4
          }
        }
      }
    ]
  }
}
```

# Activate motion graphic overlay – payload
<a name="cli-schedule-fields-activate-mgi"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for activating a motion graphics overlay](schedule-fields-for-mg.md).

```
{
 "ChannelId": "string",
 "Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "MotionGraphicsImageActivateSettings": {
     "Duration": integer
     "Url": "string"
     "Username": "string",
     "PasswordParam": "string"
    }
   }
  ]
 }
}
```

## Example
<a name="json-activate-mgi-example"></a>

This example of a request creates a motion graphics overlay action called mg\$1ticker\$1tape. The motion graphic asset is stored at http://example.com/ticker\$1tape.html. This server requires user credentials. The request doesn't include a duration. Instead, the intention is to send a separate deactivate request at the appropriate time. 

```
{
"ChannelId": "999999",
"Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "2018-05-21T20:42:04.000Z"
    }
   },
   "ActionName": "mg_ticker_tape",
   "ScheduleActionSettings": {
    "MotionGraphicsImageActivateSettings": {
     "Url": "https://example.com/ticker_tape.html"
     "Username": "medialiveoperator",
     "PasswordParam": "/medialive/12345"
    }
   }
  ]
 }
}
```

# Deactivate motion graphic overlay – payload
<a name="cli-schedule-fields-deactivate-mgi"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for deactivating a motion graphics overlay](schedule-fields-for-mg-deactivate.md).

```
{
"ChannelId": "string",
"Creates": {
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "MotionGraphicsImageDeactivateSettings": {
     }
    }
   }
  ]
 }
}
```

## Example
<a name="json-deactivate-mgi-example"></a>

This example of a request creates an action to end a motion graphic overlay at 23:59:00.000 (UTC). :

```
{
"ChannelId": "999999",
"Creates": {
 "ScheduleActions": [
  {
  "ScheduleActionStartSettings": {
   "FixedModeScheduleActionStartSettings": {
   "Time": "2018-05-21T23:59:00.000Z"
   },
   "ActionName": "deactivate-ticker-tape",
   "ScheduleActionSettings": {
    "MotionGraphicsImageDeactivateSettings": {
     }
    }
   }
  ]
 }
}
```

# Splice\$1insert message – payload
<a name="cli-schedule-fields-for-splice-insert"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for a splice\$1insert message](schedule-fields-for-splice_insert.md).

```
{
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "FollowModeScheduleActionStartSettings": {
     "FollowPoint": "enum",
     "ReferenceActionName": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "Scte35SpliceInsertSettings": {
     "Duration": integer,
     "SpliceEventId": integer
    }
   }
  }
 ]
}
```

## Example of a splice insert with a fixed start time
<a name="json-splice-insert-example"></a>

This example of a request creates an action for a splice\$1insert with a UTC start time of 20:42:04.000. It also has an `ActionName` that perhaps references an ad avail from your database, a unique integer for the splice event ID, and a duration of 1,350,000 kHz ticks (15 seconds).

```
{
  "ChannelId": "999999",
  "Creates": {
    "ScheduleActions": [
      {
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:04.000Z"
          }
        },
      "ActionName": "adavail-3708",
      "ScheduleActionSettings": {
        "Scte35SpliceInsertSettings": {
          "SpliceEventId": 3708,
          "Duration": 1350000
          }
        }
      }
    ]
  }
}
```

## Example of a splice insert as a follow
<a name="json-splice-insert-example2"></a>

This example of a request creates an action for a splice\$1insert to be inserted after the input switch called nature-doco-003 ends. The action has an `ActionName` that perhaps references an ad avail from your database, a unique integer for the splice event ID, and a duration of 1,350,000 kHz ticks (15 seconds).

Follow mode for a SCTE 35 message is useful when you want an ad avail to occur as soon as an input finishes, but you don't know when that will happen. 

```
{
  "ChannelId": "999999",
  "Creates": {
    "ScheduleActions": [
      {
        "ScheduleActionStartSettings": {
         "FollowModeScheduleActionStartSettings": {
                "FollowPoint": "END",
                "ReferenceActionName": "nature-doco-003"
        }
      },
      "ActionName": "adavail-3708",
      "ScheduleActionSettings": {
        "Scte35SpliceInsertSettings": {
          "SpliceEventId": 3708,
          "Duration": 1350000
          }
        }
      }
    ]
  }
}
```

# Time\$1signal message – payload
<a name="cli-schedule-fields-for-time-signal"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for a time\$1signal message](schedule-fields-for-time-signal.md).

```
{
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "FollowModeScheduleActionStartSettings": {
     "FollowPoint": "enum",
     "ReferenceActionName": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "Scte35TimeSignalSettings": {
     "Scte35Descriptors": [
      {
       "Scte35DescriptorSettings": {
        "SegmentationDescriptorScte35DescriptorSettings": {
         "DeliveryRestrictions": {
          "ArchiveAllowedFlag": "enum",
          "DeviceRestrictions": "enum",
          "NoRegionalBlackoutFlag": "enum",
          "WebDeliveryAllowedFlag": "enum"
         },
         "SegmentNum": integer,
         "SegmentationCancelIndicator": "enum",
         "SegmentationDuration": integer,
         "SegmentationEventId": integer,
         "SegmentationTypeId": integer,
         "SegmentationUpid": "string",
         "SegmentationUpidType": integer,
         "SegmentsExpected": integer,
         "SubSegmentNum": integer,
         "SubSegmentsExpected": integer
        }
       }
      }
     ]
    }
   }
  }
 ]
}
```

## Example
<a name="json-time-signal-example"></a>

This example of a request creates an action for a time\$1signal with a UTC start time of 20:42:04.000 and with a unique integer for `SegmentationEventId`. For the restrictions fields, `NoRegionalBlackoutFlag` has a restriction set (regional blackouts are in place).

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
      "ScheduleActionStartSettings": {
        "FixedModeScheduleActionStartSettings": {
          "Time": "2018-05-21T20:42:04.000Z"
        }
      },
      "ActionName": "adavail-3708",
      "ScheduleActionSettings": {
        "Scte35TimeSignalSettings": {
          "Scte35Descriptors": [
          {
            "Scte35DescriptorSettings": {
              "SegmentationDescriptorScte35DescriptorSettings": {
                "SubSegmentsExpected": 0,
                "SegmentationEventId": 7054,
                "SegmentationDuration": 1350000,
                "SegmentationCancelIndicator": 0,
                "SubSegmentNum": 0,
                "SegmentationUpidType": 12,
                "SegmentNum": 0,
                "SegmentationCancelIndicator": "SEGMENTATION_EVENT_NOT_CANCELED",
                "DeliveryRestrictions": {
                  "DeviceRestrictions": "NONE",
                  "WebDeliveryAllowedFlag": "WEB_DELIVERY_ALLOWED",
                  "NoRegionalBlackoutFlag": "REGIONAL_BLACKOUT",
                  "ArchiveAllowedFlag": "ARCHIVE_ALLOWED"
                },
                "SegmentationUpid": "4a414e3136494e4155303031",
                "SegmentationTypeId": 52,
                "SegmentsExpected": 0
                  }
                }
              }
            ]
          }
        }
      }
    ]
  }
}
```

# Return-to-network message – payload
<a name="cli-schedule-fields-for-return-network"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for a return-to-network message](schedule-fields-for-return-to-network.md).

```
{
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "FollowModeScheduleActionStartSettings": {
     "FollowPoint": "enum",
     "ReferenceActionName": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "Scte35ReturnToNetworkSettings": {
     "SpliceEventId": integer                
    }
   }
  }
 ]
}
```

## Example
<a name="json-return-network-example"></a>

This example of a request creates a return-to-network with a UTC start time of 20:42:19.

```
{
  "ChannelId": "999999",
  "Creates": {
    "ScheduleActions": [
      {
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:19.000Z"
          }
      },
      "ActionName": "end-adavail-3708",
      "ScheduleActionSettings": {
        "Scte35ReturnToNetworkSettings": {
          }
        }
      }
    ]
  }
}
```

# ID3 metadata item – payload
<a name="cli-schedule-fields-for-id3"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for ID3 metadata](schedule-fields-for-id3-userdata.md).

**Payload for the HlsTimedMetadataSettings action**

```
{
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
     "HlsTimedMetadataSettings": {
     "Id3": "string"
    }
   }
  }
 ]
}
```

**Payload for the TimedMetadataSettings action**

```
{
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
     "TimedMetadataSettings": {
     "Id3": "string"
    }
   }
  }
 ]
}
```

## Example
<a name="json-id3-example"></a>

This example of a request uses the `HlsTimedMetadataSettings` action. It creates ID3 metadata to be inserted in a appropriate output groups at 13:35:59 UTC.

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
      "ScheduleActionStartSettings": {
        "FixedModeScheduleActionStartSettings": {
          "Time": "2019-01-02T13:35:59Z"
        }
      },
      "ActionName": "id3-metadata.2019-01-02T13:35:59Z",
      "ScheduleActionSettings": {
        "HlsTimedMetadataSettings": {
          "Id3": "SUQzBAAAAAAAF1RJVDIAAAANAAADSGVsbG8gV29ybGQA"
          }
        }
      }
    ]
  }
}
```

# ID3 segment tag item – payload
<a name="cli-schedule-fields-id3-segment-tag"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for ID3 segment tags](schedule-fields-for-id3-segment-tags.md).

**Payload for the HlsId3SegmentTaggingSettings action**

```
{
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
	"HlsId3SegmentTaggingSettings": {
         "Tag": "string"
         "Id3": "string"
    }
   }
  }
 ]
}
```

**Payload for the Id3SegmentTaggingSettings action**

```
{
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
	"Id3SegmentTaggingSettings": {
         "Tag": "string"
         "Id3": "string"
    }
   }
  }
 ]
}
```

## Example using the tag property
<a name="json-id3-segment-example"></a>

This example of a request uses the `HlsId3SegmentTaggingSettings` action. It creates an ID3 segment tag to be inserted starting at 13:35:59 UTC. This example uses the `Tag` property , which means that you specify only the content of the `value` for the `TXXX` field. In this example, the content is the date, time, and number of the segment. 

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
      "ScheduleActionStartSettings": {
        "FixedModeScheduleActionStartSettings": {
          "Time": "2020-01-02T13:35:59Z"
        }
      },
      "ActionName": "id3-datetime-and-segment",
      "ScheduleActionSettings": {
        "HlsId3SegmentTaggingSettings": {
          "Tag": "$dt$-$sn$"
          }
        }
      }
    ]
  }
}
```

## Example using the Id3 property
<a name="json-ide-segment-id3-example"></a>

This example of a request creates an ID3 segment tag to be inserted immediately. This example uses the `Id3` property, which means that the content is encoded as base64.

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
      "ScheduleActionStartSettings": {
        ImmediateModeScheduleActionStartSettings
       }
      },
      "ActionName": "id3-song309",
      "ScheduleActionSettings": {
        "HlsId3SegmentTaggingSettings": {
          "Id3": "SUQzBAAAAAAAF1RJVDIAAAANAAADSGVsbG8gV29ybGQA"
          }
        }
      }
    ]
  }
}
```

# Pause pipeline action – payload
<a name="cli-schedule-fields-for-pause"></a>

For information about the meaning and values for the fields in the following JSON, see [Fields for pause](schedule-fields-for-pause.md).

```
{
 "ScheduleActions": [
  {
   "ScheduleActionStartSettings": {
    "FixedModeScheduleActionStartSettings": {
     "Time": "string"
    },
    "ImmediateModeScheduleActionStartSettings": {
    }
   },
   "ActionName": "string",
   "ScheduleActionSettings": {
    "PauseStateSettings": {
     "Pipelines": [
      {
       "PipelineId": "enum"
      }
     ]
    }
   }
  }
 ]
}
```

## Example: Pausing one pipeline
<a name="json-pause-example"></a>

This example of a request pauses pipeline 0 at 20:42:19 UTC. MediaLive always reads the command as:*set the specified pipeline or pipelines to pause and set all other pipelines to unpaused.*

```
{
  "ChannelId": "999999",
  "Creates": {
    "ScheduleActions": [
      {
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:19Z"
          }
        },
        "ActionName": "pause-pipeline-0-now",
        "ScheduleActionSettings": {
          "PauseStateSettings": {
            "Pipelines": [
              {
                "PipelineId": "PIPELINE_0"
              }
            ]
          }
        }
      }
    ]
  }
}
```

## Example: Unpausing both pipelines
<a name="json-unpause-example"></a>

This example of a request unpauses all pipelines that are currently paused. 

**Note**  
MediaLive always reads the command as:*set the specified pipeline or pipelines to pause and set all other pipelines to unpaused.* In this example, the `Pipelines` array is empty. MediaLive interprets this empty array as: *set all pipelines to unpaused*.

```
{
 "ChannelId": "999999",
 "Creates": {
     "ScheduleActions": [
      {
       "ScheduleActionStartSettings": {
         "ImmediateModeScheduleActionStartSettings": {}
      },
     "ActionName": "unpause-pipeline-0",
     "ScheduleActionSettings": {
       "PauseStateSettings": {
         "Pipelines": [
       {}
      ]
     }
    }
   }
  ]
 }
}
```

# Combination of create actions
<a name="cli-example-multiple-creates"></a>

Here is an example of a JSON body to pass into the `--creates` parameter of the `batch-update-schedule` AWS CLI command. It contains two actions to create. In this example, both actions are splice\$1inserts, but in fact you can combine any number and any type of create actions.

```
{
    "ScheduleActions": [
      {
        "ScheduleActionSettings": {
          "Scte35SpliceInsertSettings": {
            "Duration": 1350000,
            "SpliceEventId": 3
          }
        },
        "ActionName": "SpliceInsert-01",
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-11-05T16:10:30.000Z"
          }
        }
      },
      {
        "ScheduleActionSettings": {
          "Scte35SpliceInsertSettings": {
            "Duration": 2700000,
            "SpliceEventId": 3
          }
        },
        "ActionName": "SpliceInsert-02",
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-11-05T16:30:45.000Z"
          }
        }
      }
    ]
  }
```

# JSON payload for delete actions
<a name="cli-schedule-delete-json"></a>

 In the `Deletes` section, include the list of actions to delete by entering an array of `ActionNames`. The array contains one or more action names. You can obtain these action names using the `DescribeChannel` command (see [Viewing the schedule (AWS CLI)](viewing-schedule-using-cli.md).

```
{
  "ChannelId": "string",
  "Deletes": {
      "ActionNames": [
          ""
    ]
  }
}
```

## Example
<a name="cli-schedule-delete-json-example"></a>

This example of a request deletes the three actions identified by `ActionNames` that were assigned when you created the actions.

```
{
  "ChannelId": "999999",
  "Deletes": {
      "ActionNames": [
          "stop-overlay-33",
          "adavail-3711",
          "end-adavail-3711"
      ]
  }
}
```

# JSON payload for combining create and delete
<a name="schedule-create-and-delete-json"></a>

To combine a batch of creates and deletes, include both a `Creates` section and a `Deletes` section in the JSON payload. 

In this example, the payload in the `Deletes` section removes an action to activate an image overlay because it has an incorrect start time. The action is named `overlay-21`. The payload in the `Creates` section inserts that action again, this time with the correct start time.

Even though the `Creates` section appears first in the JSON payload, MediaLive always performs the delete actions first. 

In this action, the delete action and the create action have the same `ActionName`. The name is being reused because the batch is a "delete and replace." But you could assign a different name to the create action.

```
{
  "ChannelId": "999999",
  "Creates": {
  "ScheduleActions": [
    {
      "ScheduleActionStartSettings": {
        "FixedModeScheduleActionStartSettings": {
          "Time": "2018-05-21T20:42:19.000Z"
        }
      },
      "ActionName": "overlay-21",
      "ScheduleActionSettings": {
        "StaticImageActivateSettings": {
          "Image": {
          "PasswordParam": "imagespassword",
          "Uri": "s3ssl://amzn-s3-demo-bucket/banner-A/high-res.bmp",
          "Username": "medialiveoperator"
          },
          "ImageY": 300,
          "FadeIn": 1500,
          "ImageX": 200,
          "Width": 800,
          "Opacity": 60,
          "Layer": 1,
          "Height": 900
          }
        }
      }
    ]
  },
  "Deletes": {
       "ActionNames": [
          "overlay-21"
        ]
    }
}
```

# Viewing the schedule (AWS CLI)
<a name="viewing-schedule-using-cli"></a>

You can use the AWS CLI to view a list of the actions that are currently in the schedule for one channel:
+ Actions that have not yet been performed in the channel
+ Actions that have previously been performed 

To view the schedule, use the `DescribeSchedule` command. This command is represented differently in different interfaces:
+ In the AWS CLI, the command is `describe-schedule`.
+ In the API, the command is represented by an `HTTP GET` on `channels/channelId/schedule`.
+ In the AWS SDKs, the command is represented by constructs that are suitable to that SDK language. 

**To view actions (AWS CLI)**

1. Enter this command:

   **aws medialive describe-schedule --channel-id *value* --max-results value**

1. To submit the command, press **Enter**. The response appears on the screen. 

1. If you used the `-max-results` option and the response included `NextToken`, enter the **DescribeChannel** command and pass the value of `NextToken` in `--next-token`. For example:

   **aws medialive describe-schedule --channel-id *value* --next-token 3jhrprd0**

1. To submit the command, press **Enter**. The response appears on the screen. 

## Example
<a name="viewing-schedule-using-cli-example"></a>

The JSON body of the command *response* is similar to that of the `BatchUpdateSchedule` command *request*.

This example of a response shows the following actions:
+ An action with the `ActionName` **corporate-logo-029** to activate an image overlay in layer 1 at 20:30:00 UTC
+ An action with the `ActionName` **stop-overlay-029** to deactivate the overlay in layer 1 at 20:42:04 UTC
+ An action with the `ActionName` **adavail-3708** to insert a splice\$1insert at the same time as the deactivate action
+ An action with the `ActionName` **end-adavail-3708** to return-to-network 15 seconds later, at 20:42:19 UTC
+ An action with the `ActionName` **corporate-logo-030** to reactivate the same overlay in layer 1 at the same time as the return

This schedule describes a workflow where you generally show your corporate logo, but you remove it at the start of each ad avail and then display it again at the end of the ad avail.

```
 {
  "NextToken": "3jhrprd0",
      "ScheduleActions": [
      {
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:30:00.000Z"
          }
        },
        "ActionName": "corporate-logo-029",
        "ScheduleActionSettings": {
          "StaticImageActivateSettings": {
            "Image": {
            "PasswordParam": "corplogo!2312",
            "Uri": "s3ssl://amzn-s3-demo-bucket/logos/corporate/high-res.bmp",
            "Username": "medialiveoperator"
            },
            "ImageY": 300,
            "FadeIn": 1500,
            "ImageX": 200,
            "Width": 800,
            "Opacity": 60,
            "Layer": 1,
            "Height": 900
          }
        }
      },
      {
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:04.000Z"
          }
        },
        "ActionName": " stop-overlay-029",
        "ScheduleActionSettings": {
          "StaticImageDeactivateSettings": {
            "FadeOut": 1500,
            "Layer": 1
          }
        }
      },
      {
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:04.000Z"
          }
        },
        "ActionName": "adavail-3708",
        "ScheduleActionSettings": {
          "Scte35SpliceInsertSettings": {
            "SpliceEventId": 3708,
            "Duration": 1350000
          }
        }
      },
      {
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:19.000Z"
          }
        },
        "ActionName": "end-adavail-3708",
        "ScheduleActionSettings": {
          "Scte35ReturnToNetworkSettings": {
            "SpliceEventId": 3708
          }
        }
      },
      {
        "ScheduleActionStartSettings": {
          "FixedModeScheduleActionStartSettings": {
            "Time": "2018-05-21T20:42:19.000Z"
          }
        },
        "ActionName": "corporate-logo-030",
        "ScheduleActionSettings": {
          "StaticImageActivateSettings": {
            "Image": {
            "PasswordParam": "corplogo!2312",
            "Uri": "s3ssl://amzn-s3-demo-bucket/logos/corporate/high-res.bmp",
            "Username": "medialiveoperator"
            },
            "ImageY": 300,
            "FadeIn": 1500,
            "ImageX": 200,
            "Width": 800,
            "Opacity": 60,
            "Layer": 1,
            "Height": 900
          }
        }
      }
    ]   
  }
```