- Navigation GuideYou are on a Command (operation) page with structural examples. Use the navigation breadcrumb if you would like to return to the Client landing page.
GetPrefetchScheduleCommand
Retrieves a prefetch schedule for a playback configuration. A prefetch schedule allows you to tell MediaTailor to fetch and prepare certain ads before an ad break happens. For more information about ad prefetching, see Using ad prefetching in the MediaTailor User Guide.
Example Syntax
Use a bare-bones client and the command you need to make an API call.
import { MediaTailorClient, GetPrefetchScheduleCommand } from "@aws-sdk/client-mediatailor"; // ES Modules import
// const { MediaTailorClient, GetPrefetchScheduleCommand } = require("@aws-sdk/client-mediatailor"); // CommonJS import
const client = new MediaTailorClient(config);
const input = { // GetPrefetchScheduleRequest
Name: "STRING_VALUE", // required
PlaybackConfigurationName: "STRING_VALUE", // required
};
const command = new GetPrefetchScheduleCommand(input);
const response = await client.send(command);
// { // GetPrefetchScheduleResponse
// Arn: "STRING_VALUE",
// Consumption: { // PrefetchConsumption
// AvailMatchingCriteria: [ // __listOfAvailMatchingCriteria
// { // AvailMatchingCriteria
// DynamicVariable: "STRING_VALUE", // required
// Operator: "EQUALS", // required
// },
// ],
// EndTime: new Date("TIMESTAMP"), // required
// StartTime: new Date("TIMESTAMP"),
// },
// Name: "STRING_VALUE",
// PlaybackConfigurationName: "STRING_VALUE",
// Retrieval: { // PrefetchRetrieval
// DynamicVariables: { // __mapOf__string
// "<keys>": "STRING_VALUE",
// },
// EndTime: new Date("TIMESTAMP"), // required
// StartTime: new Date("TIMESTAMP"),
// },
// StreamId: "STRING_VALUE",
// };
GetPrefetchScheduleCommand Input
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
Name Required | string | undefined | The name of the prefetch schedule. The name must be unique among all prefetch schedules that are associated with the specified playback configuration. |
PlaybackConfigurationName Required | string | undefined | Returns information about the prefetch schedule for a specific playback configuration. If you call |
GetPrefetchScheduleCommand Output
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
$metadata Required | ResponseMetadata | Metadata pertaining to this request. |
Arn | string | undefined | The Amazon Resource Name (ARN) of the prefetch schedule. |
Consumption | PrefetchConsumption | undefined | Consumption settings determine how, and when, MediaTailor places the prefetched ads into ad breaks. Ad consumption occurs within a span of time that you define, called a consumption window. You can designate which ad breaks that MediaTailor fills with prefetch ads by setting avail matching criteria. |
Name | string | undefined | The name of the prefetch schedule. The name must be unique among all prefetch schedules that are associated with the specified playback configuration. |
PlaybackConfigurationName | string | undefined | The name of the playback configuration to create the prefetch schedule for. |
Retrieval | PrefetchRetrieval | undefined | A complex type that contains settings for prefetch retrieval from the ad decision server (ADS). |
StreamId | string | undefined | An optional stream identifier that you can specify in order to prefetch for multiple streams that use the same playback configuration. |
Throws
Name | Fault | Details |
---|
Name | Fault | Details |
---|---|---|
MediaTailorServiceException | Base exception class for all service exceptions from MediaTailor service. |