create_harvest_job
async
¶
create_harvest_job(
channel_group_name: ResourceName,
channel_name: ResourceName,
origin_endpoint_name: ResourceName,
harvested_manifests: HarvestedManifests,
schedule_configuration: HarvesterScheduleConfiguration,
destination: Destination,
*,
config_overrides: Optional[AsyncMediaPackageV2ClientConfig] = None,
description: Optional[ResourceDescription] = None,
client_token: Optional[IdempotencyToken] = None,
harvest_job_name: Optional[ResourceName] = None,
tags: Optional[TagMap] = None,
) -> CreateHarvestJobResponse
Creates a new harvest job to export content from a MediaPackage v2 channel to an S3 bucket.
Parameters:
-
channel_group_name(ResourceName) –The name of the channel group containing the channel from which to harvest content.
-
channel_name(ResourceName) –The name of the channel from which to harvest content.
-
origin_endpoint_name(ResourceName) –The name of the origin endpoint from which to harvest content.
-
description(Optional[ResourceDescription], default:None) –An optional description for the harvest job.
-
harvested_manifests(HarvestedManifests) –A list of manifests to be harvested.
-
schedule_configuration(HarvesterScheduleConfiguration) –The configuration for when the harvest job should run, including start and end times.
-
destination(Destination) –The S3 destination where the harvested content will be placed.
-
client_token(Optional[IdempotencyToken], default:None) –A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.
-
harvest_job_name(Optional[ResourceName], default:None) –A name for the harvest job. This name must be unique within the channel.
-
tags(Optional[TagMap], default:None) –A collection of tags associated with the harvest job.
Raises:
-
AccessDeniedException–Access is denied because either you don't have permissions to perform the requested operation or MediaPackage is getting throttling errors with CDN authorization. The user or role that is making the request must have at least one IAM permissions policy attached that grants the required permissions. For more information, see Access Management in the IAM User Guide. Or, if you're using CDN authorization, you will receive this exception if MediaPackage receives a throttling error from Secrets Manager.
-
ConflictException–Updating or deleting this resource can cause an inconsistent state.
-
InternalServerException–Indicates that an error from the service occurred while trying to process a request.
-
ResourceNotFoundException–The specified resource doesn't exist.
-
ServiceQuotaExceededException–The request would cause a service quota to be exceeded.
-
ThrottlingException–The request throughput limit was exceeded.
-
ValidationException–The input failed to meet the constraints specified by the AWS service.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
Creating a Harvest Job
>>> await client.create_harvest_job(channel_group_name='exampleChannelGroup', channel_name='exampleChannelName', origin_endpoint_name='exampleOriginEndpointName', description='Example HarvestJob description', harvested_manifests={'HlsManifests': [{'ManifestName': 'HlsManifest'}], 'DashManifests': [{'ManifestName': 'DashManifest'}], 'LowLatencyHlsManifests': [{'ManifestName': 'LowLatencyHlsManifest'}]}, schedule_configuration={'StartTime': '2024-05-28T06:00:00.00Z', 'EndTime': '2024-05-28T12:00:00.00Z'}, destination={'S3Destination': {'BucketName': 'harvestJobS3DestinationBucket', 'DestinationPath': 'manifests'}})
Source code in docs_src/capo_mediapackagev2/_services/async_media_package_v2.py
2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 | |