Retrieve an Asset’s Content Protection Key
Provide the content key for a specific protected asset.
URL
POST https://cloudextension-testservice.local/api/queues/contentProtectionKeyHeader Parameters
| Name | Type | Description |
|---|---|---|
Accept-Language Optional | string | The client’s current user interface language. If possible, respond with localized content for this language. |
User-Agent Required | string | The client’s extension protocol. This is an RFC 7231-compliant string that contains the product name |
x-applecloudextension-retry-count Optional | uint32 | The number of previous requests from the client. The client omits this header on the first attempt. |
x-applecloudextension-session-id Required | string | A session identifier to pair each request and response. Respond to requests with the value the client provides. |
Response Codes
| Status | Reason | Type | Description |
|---|---|---|---|
| 200 | OK Content-Type: application/json | ContentProtectionKeyResponse | The request is successful. |
| 204 | No Content | The service is unable to provide a content key for the specified | |
| 401 | Unauthorized | The request requires authorization. The client can attempt to reauthorize and then retry the request. | |
| 410 | Gone | The request includes an expired UserActivity, which the service is unable to use to provide a content key. |
Discussion
If your service implements content protection, the client requests an item’s content protection key from this endpoint after each of the following events:
The client receives the queue’s initial item.
The client preloads each subsequent item in the queue.
The user manually transitions to an item in the queue.
For more information on providing your service’s content protection configuration, see ExtensionConfig.Media.Queues.ContentProtectionKey.
HTTP Body
A JSON object that contains the encrypted key request and identifies the protected asset.