Assets - Get Encryption Key

Gets the Asset storage key
Gets the Asset storage encryption keys used to decrypt content created by version 2 of the Media Services API

POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Media/mediaServices/{accountName}/assets/{assetName}/getEncryptionKey?api-version=2020-05-01

URI Parameters

Name In Required Type Description
accountName
path True
  • string

The Media Services account name.

assetName
path True
  • string

The Asset name.

resourceGroupName
path True
  • string

The name of the resource group within the Azure subscription.

subscriptionId
path True
  • string

The unique identifier for a Microsoft Azure subscription.

api-version
query True
  • string

The version of the API to be used with the client request.

Responses

Name Type Description
200 OK

OK

Other Status Codes

Detailed error information.

Examples

Get Asset Storage Encryption Keys

Sample Request

POST https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contoso/providers/Microsoft.Media/mediaServices/contosomedia/assets/ClimbingMountSaintHelens/getEncryptionKey?api-version=2020-05-01

Sample Response

{
  "key": "AAAAAAAAAAAAAAAAAAAAAA==",
  "assetFileEncryptionMetadata": [
    {
      "initializationVector": "-988929866",
      "assetFileName": "AssetFile0",
      "assetFileId": "a9536fa7-bd5d-4f84-a137-d1290982fe95"
    },
    {
      "initializationVector": "1604993689",
      "assetFileName": "AssetFile1",
      "assetFileId": "f4060046-94ac-422d-824c-3f1d6aa3ecf2"
    },
    {
      "initializationVector": "100082635",
      "assetFileName": "AssetFile2",
      "assetFileId": "485968d3-ddae-4b13-98e7-901201a9620b"
    }
  ]
}

Definitions

ApiError

The API error.

AssetFileEncryptionMetadata

The Asset File Storage encryption metadata.

ODataError

Information about an error.

StorageEncryptedAssetDecryptionData

Data needed to decrypt asset files encrypted with legacy storage encryption.

ApiError

The API error.

Name Type Description
error

The error properties.

AssetFileEncryptionMetadata

The Asset File Storage encryption metadata.

Name Type Description
assetFileId
  • string

The Asset File Id.

assetFileName
  • string

The Asset File name.

initializationVector
  • string

The Asset File initialization vector.

ODataError

Information about an error.

Name Type Description
code
  • string

A language-independent error name.

details

The error details.

message
  • string

The error message.

target
  • string

The target of the error (for example, the name of the property in error).

StorageEncryptedAssetDecryptionData

Data needed to decrypt asset files encrypted with legacy storage encryption.

Name Type Description
assetFileEncryptionMetadata

Asset File encryption metadata.

key
  • string

The Asset File storage encryption key.