origin_endpoints
Creates, updates, deletes or gets an origin_endpoint resource or lists origin_endpoints in a region
Overview
| Name | origin_endpoints |
| Type | Resource |
| Description | Resource schema for AWS::MediaPackage::OriginEndpoint |
| Id | awscc.mediapackage.origin_endpoints |
Fields
- get (all properties)
- list (identifiers only)
| Name | Datatype | Description |
|---|---|---|
arn | string | The Amazon Resource Name (ARN) assigned to the OriginEndpoint. |
url | string | The URL of the packaged OriginEndpoint for consumption. |
id | string | The ID of the OriginEndpoint. |
channel_id | string | The ID of the Channel the OriginEndpoint is associated with. |
description | string | A short text description of the OriginEndpoint. |
whitelist | array | A list of source IP CIDR blocks that will be allowed to access the OriginEndpoint. |
startover_window_seconds | integer | Maximum duration (seconds) of content to retain for startover playback. If not specified, startover playback will be disabled for the OriginEndpoint. |
time_delay_seconds | integer | Amount of delay (seconds) to enforce on the playback of live content. If not specified, there will be no time delay in effect for the OriginEndpoint. |
manifest_name | string | A short string appended to the end of the OriginEndpoint URL. |
origination | string | Control whether origination of video is allowed for this OriginEndpoint. If set to ALLOW, the OriginEndpoint may by requested, pursuant to any other form of access control. If set to DENY, the OriginEndpoint may not be requested. This can be helpful for Live to VOD harvesting, or for temporarily disabling origination |
authorization | object | |
hls_package | object | An HTTP Live Streaming (HLS) packaging configuration. |
dash_package | object | A Dynamic Adaptive Streaming over HTTP (DASH) packaging configuration. |
mss_package | object | A Microsoft Smooth Streaming (MSS) PackagingConfiguration. |
cmaf_package | object | A CMAF packaging configuration. |
tags | array | A collection of tags associated with a resource |
region | string | AWS region. |
| Name | Datatype | Description |
|---|---|---|
id | string | The ID of the OriginEndpoint. |
region | string | AWS region. |
For more information, see AWS::MediaPackage::OriginEndpoint.
Methods
| Name | Resource | Accessible by | Required Params |
|---|---|---|---|
create_resource | origin_endpoints | INSERT | Id, ChannelId, region |
delete_resource | origin_endpoints | DELETE | Identifier, region |
update_resource | origin_endpoints | UPDATE | Identifier, PatchDocument, region |
list_resources | origin_endpoints_list_only | SELECT | region |
get_resource | origin_endpoints | SELECT | Identifier, region |
SELECT examples
- get (all properties)
- list (identifiers only)
Gets all properties from an individual origin_endpoint.
SELECT
region,
arn,
url,
id,
channel_id,
description,
whitelist,
startover_window_seconds,
time_delay_seconds,
manifest_name,
origination,
authorization,
hls_package,
dash_package,
mss_package,
cmaf_package,
tags
FROM awscc.mediapackage.origin_endpoints
WHERE
region = '{{ region }}' AND
Identifier = '{{ id }}';
Lists all origin_endpoints in a region.
SELECT
region,
id
FROM awscc.mediapackage.origin_endpoints_list_only
WHERE
region = '{{ region }}';
INSERT example
Use the following StackQL query and manifest file to create a new origin_endpoint resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.mediapackage.origin_endpoints (
Id,
ChannelId,
region
)
SELECT
'{{ id }}',
'{{ channel_id }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
/*+ create */
INSERT INTO awscc.mediapackage.origin_endpoints (
Id,
ChannelId,
Description,
Whitelist,
StartoverWindowSeconds,
TimeDelaySeconds,
ManifestName,
Origination,
Authorization,
HlsPackage,
DashPackage,
MssPackage,
CmafPackage,
Tags,
region
)
SELECT
'{{ id }}',
'{{ channel_id }}',
'{{ description }}',
'{{ whitelist }}',
'{{ startover_window_seconds }}',
'{{ time_delay_seconds }}',
'{{ manifest_name }}',
'{{ origination }}',
'{{ authorization }}',
'{{ hls_package }}',
'{{ dash_package }}',
'{{ mss_package }}',
'{{ cmaf_package }}',
'{{ tags }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: origin_endpoint
props:
- name: id
value: '{{ id }}'
- name: channel_id
value: '{{ channel_id }}'
- name: description
value: '{{ description }}'
- name: whitelist
value:
- '{{ whitelist[0] }}'
- name: startover_window_seconds
value: '{{ startover_window_seconds }}'
- name: time_delay_seconds
value: '{{ time_delay_seconds }}'
- name: manifest_name
value: '{{ manifest_name }}'
- name: origination
value: '{{ origination }}'
- name: authorization
value:
cdn_identifier_secret: '{{ cdn_identifier_secret }}'
secrets_role_arn: '{{ secrets_role_arn }}'
- name: hls_package
value:
encryption:
constant_initialization_vector: '{{ constant_initialization_vector }}'
encryption_method: '{{ encryption_method }}'
speke_key_provider:
encryption_contract_configuration:
preset_speke20_audio: '{{ preset_speke20_audio }}'
preset_speke20_video: '{{ preset_speke20_video }}'
role_arn: '{{ role_arn }}'
system_ids:
- '{{ system_ids[0] }}'
url: '{{ url }}'
hls_manifests:
- ad_markers: '{{ ad_markers }}'
include_iframe_only_stream: '{{ include_iframe_only_stream }}'
manifest_name: '{{ manifest_name }}'
program_date_time_interval_seconds: '{{ program_date_time_interval_seconds }}'
repeat_ext_xkey: '{{ repeat_ext_xkey }}'
stream_selection:
max_video_bits_per_second: '{{ max_video_bits_per_second }}'
min_video_bits_per_second: '{{ min_video_bits_per_second }}'
stream_order: '{{ stream_order }}'
include_dvb_subtitles: '{{ include_dvb_subtitles }}'
segment_duration_seconds: '{{ segment_duration_seconds }}'
use_audio_rendition_group: '{{ use_audio_rendition_group }}'
- name: dash_package
value:
dash_manifests:
- manifest_layout: '{{ manifest_layout }}'
manifest_name: null
min_buffer_time_seconds: '{{ min_buffer_time_seconds }}'
profile: '{{ profile }}'
scte_markers_source: '{{ scte_markers_source }}'
stream_selection: null
encryption:
speke_key_provider: null
period_triggers:
- '{{ period_triggers[0] }}'
segment_duration_seconds: null
segment_template_format: '{{ segment_template_format }}'
include_encoder_configuration_in_segments: '{{ include_encoder_configuration_in_segments }}'
include_iframe_only_stream: '{{ include_iframe_only_stream }}'
- name: mss_package
value:
encryption:
speke_key_provider: null
mss_manifests:
- manifest_name: null
stream_selection: null
segment_duration_seconds: null
- name: cmaf_package
value:
encryption:
speke_key_provider: null
hls_manifests:
- null
segment_duration_seconds: null
include_encoder_configuration_in_segments: '{{ include_encoder_configuration_in_segments }}'
- name: tags
value:
- key: '{{ key }}'
value: '{{ value }}'
UPDATE example
Use the following StackQL query and manifest file to update a origin_endpoint resource, using stack-deploy.
/*+ update */
UPDATE awscc.mediapackage.origin_endpoints
SET PatchDocument = string('{{ {
"ChannelId": channel_id,
"Description": description,
"Whitelist": whitelist,
"StartoverWindowSeconds": startover_window_seconds,
"TimeDelaySeconds": time_delay_seconds,
"ManifestName": manifest_name,
"Origination": origination,
"Authorization": authorization,
"HlsPackage": hls_package,
"DashPackage": dash_package,
"MssPackage": mss_package,
"CmafPackage": cmaf_package,
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ id }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
DELETE example
/*+ delete */
DELETE FROM awscc.mediapackage.origin_endpoints
WHERE
Identifier = '{{ id }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;
Additional Parameters
Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:
| Parameter | Description |
|---|---|
ClientToken | A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.A client token is valid for 36 hours once used. After that, a resource request with the same client token is treated as a new request. If you do not specify a client token, one is generated for inclusion in the request. |
RoleArn | The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.If you do not specify a role, a temporary session is created using your AWS user credentials. |
TypeVersionId | For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used. |
Permissions
To operate on the origin_endpoints resource, the following permissions are required:
- Create
- Read
- Update
- Delete
- List
mediapackage:CreateOriginEndpoint,
mediapackage:DescribeOriginEndpoint,
mediapackage:DescribeChannel,
mediapackage:TagResource,
iam:PassRole,
acm:DescribeCertificate
mediapackage:DescribeOriginEndpoint
mediapackage:UpdateOriginEndpoint,
mediapackage:TagResource,
mediapackage:ListTagsForResource,
mediapackage:UntagResource,
mediapackage:DescribeOriginEndpoint,
iam:PassRole
mediapackage:DeleteOriginEndpoint
mediapackage:ListOriginEndpoints