List Content Key Policies

get https://app.mk.io/api/v1/projects/:project_name/media/contentKeyPolicies

Listing, Sorting and Filtering Content Key Policies

This endpoint returns the list of content key policies in the specified project.

Sorting

The results from this endpoint can be ordered using the $orderby query parameter. Specify a list of field names, separated by commas where each one can optionally specify asc or desc.

Sorting is valid on the following fields: created, createdBy, id, name, properties/created, properties/lastModified, properties/policyId, updated, updatedBy

Filtering

The $filter query parameter allows for content key policies to be filtered on the basis of fields in the schema using OData query syntax. See this document for more details on the syntax used.

Filters are valid on the following fields: created, createdBy, createdByEmail, createdByName, id, name, properties/created, properties/lastModified, properties/policyId, updated, updatedBy, updatedByEmail, updatedByName

Examples:

?$top=10 - Returns only the first 10 content key policies from the list.

?$orderby=name desc - Sorts content key policies by name in descending order.

?$filter=name eq 'descriptive name' - Returns content key policies that match the provided name.

?$orderby=created desc - Sorts content key policies by creation date in descending order.

?$filter=created ge 2021-01-01T00:00:00Z - Returns content key policies created after January 1, 2021.

Authentication

Authorization Bearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

project_name string Required

Query parameters

$orderby string Optional
Specifies the key by which the result collection should be ordered.
$filter string Optional
Restricts the set of items returned.
$top string Optional
Specifies a non-negative integer n that limits the number of items returned from a collection. The service returns the number of available items up to but not greater than the specified value n.
$skiptoken string Optional
Specifies a start offset to support paginated results. Use @odata.nextLink in the result object to enumerate the collection - it will be present only if there's more than one page of entities.

Response

200 A list of content key policies.
@odata.nextLinkstringOptional
@odata.nextLink URL if the page length and number of items match.
supplementalobjectListResponseSupplementalSchemaRequired
Supplemental info
Show 5 propertiesHide 5 properties
countintegerRequired
Number of items returned
kindstringRequired
Type of items in the list
operationstringRequired
Operation type. Should always say 'list'
paginationobjectPaginationInfoSchemaRequired
Pagination info
Show 4 propertiesHide 4 properties
endintegerRequired
Position of the last item in the list
recordsintegerRequired
Total number of items returned in the list
startintegerRequired
Position of the first item in the list
totalintegerRequired
Total number of items in the project
subscriptionobjectProjectInfoSchemaOptional
Project info
Show 2 propertiesHide 2 properties
idstringRequired
Project ID
namestringRequired
Project name
valuelist of objectsContentKeyPolicySchemaRequired
A list of content key policies.
Show 5 propertiesHide 5 properties
idstringOptional
Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
namestringOptional1-260 characterspattern: ^[^\^\'<>%&:\\?/*+]+$
The name of the resource
propertiesobjectContentKeyPolicyPropertiesRequired
The key policy
Show 6 propertiesHide 6 properties
createdstringOptionalformat: date-time
The creation date of the Policy
descriptionstringOptional0-1024 characters
A description for the Policy.
fairPlayAmsCompatibilitybooleanOptional
FairPlay AMS compatibility enabled.
lastModifiedstringOptionalformat: date-time
The last modified date of the Policy
optionslist of objectsContentKeyPolicyOptionRequired
The Key Policy options.
Show 4 propertiesHide 4 properties
configurationobjectRequired
The key delivery configuration.
Show 5 variantsHide 5 variants

Discriminated by @odata.type. Select one variant:

#Microsoft.Media.ContentKeyPolicyClearKeyConfigurationobjectContentKeyPolicyClearKeyConfiguration
Represents a configuration for non-DRM keys.
@odata.typestringRequired
The discriminator for derived types.
#Microsoft.Media.ContentKeyPolicyFairPlayConfigurationobjectContentKeyPolicyFairPlayConfiguration
Specifies a configuration for FairPlay licenses.
@odata.typestringRequired
The discriminator for derived types.
askstring or nullRequiredformat: byte
The key that must be used as FairPlay Application Secret key. This needs to be base64 encoded.
fairPlayPfxstring or nullRequired
The Base64 representation of FairPlay certificate in PKCS 12 (pfx) format (including private key).
fairPlayPfxPasswordstring or nullRequired
The password encrypting FairPlay certificate in PKCS 12 (pfx) format.
offlineRentalConfigurationobjectContentKeyPolicyFairPlayOfflineRentalConfigurationOptional
Offline rental policy
Show 2 propertiesHide 2 properties
playbackDurationSecondsintegerRequired
Playback duration
storageDurationSecondsintegerRequired
Storage duration
rentalAndLeaseKeyTypeenumRequired
The rental and lease key type.
Allowed values:UnknownUndefinedDualExpiryPersistentUnlimitedPersistentLimited
rentalDurationintegerRequired
The rental duration. Must be greater than or equal to 0.
#Microsoft.Media.ContentKeyPolicyPlayReadyConfigurationobjectContentKeyPolicyPlayReadyConfiguration
Specifies a configuration for PlayReady licenses.
@odata.typestringRequired
The discriminator for derived types.
licenseslist of objectsContentKeyPolicyPlayReadyLicenseRequired
The PlayReady licenses.
Show 11 propertiesHide 11 properties
allowTestDevicesbooleanRequired
A flag indicating whether test devices can use the license.
beginDatestringOptionalformat: date-time
The begin date of license
contentKeyLocationobjectRequired
The content key location.
Show 2 variantsHide 2 variants

Discriminated by @odata.type. Select one variant:

#Microsoft.Media.ContentKeyPolicyPlayReadyContentEncryptionKeyFromHeaderobjectContentKeyPolicyPlayReadyContentEncryptionKeyFromHeader
Specifies that the content key ID is in the PlayReady header.
@odata.typestringRequired
The discriminator for derived types.
#Microsoft.Media.ContentKeyPolicyPlayReadyContentEncryptionKeyFromKeyIdentifierobjectContentKeyPolicyPlayReadyContentEncryptionKeyFromKeyIdentifier
Specifies that the content key ID is specified in the PlayReady configuration.
@odata.typestringRequired
The discriminator for derived types.
keyIdstring or nullRequiredformat: uuid
The content key ID.
contentTypeenumRequired
The PlayReady content type.
Allowed values:UnknownUnspecifiedUltraVioletDownloadUltraVioletStreaming
expirationDatestringOptionalformat: date-time
The expiration date of license.
gracePeriodstringOptionalformat: duration
The grace period of license.
licenseTypeenumRequired
The license type.
Allowed values:UnknownNonPersistentPersistent
playRightobjectContentKeyPolicyPlayReadyPlayRightOptional
The license PlayRight
Show 13 propertiesHide 13 properties
agcAndColorStripeRestrictionintegerOptional0 to 3
Configures Automatic Gain Control (AGC) and Color Stripe in the license. Must be between 0 and 3 inclusive.
allowPassingVideoContentToUnknownOutputenumRequired
Configures Unknown output handling settings of the license.
Allowed values:UnknownNotAllowedAllowedAllowedWithVideoConstriction
analogVideoOplintegerOptional
Specifies the output protection level for compressed digital audio.
compressedDigitalAudioOplintegerOptional
Specifies the output protection level for compressed digital audio.
compressedDigitalVideoOplintegerOptional
Specifies the output protection level for compressed digital video.
digitalVideoOnlyContentRestrictionbooleanRequired
Enables the Image Constraint For Analog Component Video Restriction in the license.
explicitAnalogTelevisionOutputRestrictionobjectContentKeyPolicyPlayReadyExplicitAnalogTelevisionRestrictionOptional
Configures the Explicit Analog Television Output Restriction in the license. Configuration data must be between 0 and 3 inclusive.
Show 2 propertiesHide 2 properties
bestEffortbooleanRequired
Indicates whether this restriction is enforced on a Best Effort basis.
configurationDataintegerRequired0 to 3
Configures the restriction control bits. Must be between 0 and 3 inclusive.
firstPlayExpirationstringOptionalformat: duration
The amount of time that the license is valid after the license is first used to play content.
imageConstraintForAnalogComponentVideoRestrictionbooleanRequired
Enables the Image Constraint For Analog Component Video Restriction in the license.
imageConstraintForAnalogComputerMonitorRestrictionbooleanRequired
Enables the Image Constraint For Analog Component Video Restriction in the license.
scmsRestrictionintegerOptional0 to 3
Configures the Serial Copy Management System (SCMS) in the license. Must be between 0 and 3 inclusive.
uncompressedDigitalAudioOplintegerOptional
Specifies the output protection level for uncompressed digital audio.
uncompressedDigitalVideoOplintegerOptional
Specifies the output protection level for uncompressed digital video.
relativeBeginDatestringOptionalformat: duration
The relative begin date of license.
relativeExpirationDatestringOptionalformat: duration
The relative expiration date of license.
securityLevelenumOptional
The security level.
Allowed values:UnknownSL150SL2000SL3000
responseCustomDatastringOptional
The custom response data.
#Microsoft.Media.ContentKeyPolicyUnknownConfigurationobjectContentKeyPolicyUnknownConfiguration
Represents a ContentKeyPolicyConfiguration that is unavailable in the current API version.
@odata.typestringRequired
The discriminator for derived types.
#Microsoft.Media.ContentKeyPolicyWidevineConfigurationobjectContentKeyPolicyWidevineConfiguration
Specifies a configuration for Widevine licenses.
@odata.typestringRequired
The discriminator for derived types.
widevineTemplatestringRequired
The Widevine template.
namestringOptional
The Policy Option description.
policyOptionIdstringOptionalformat: uuid
The legacy Policy Option ID.
restrictionobjectRequired
The requirements that must be met to deliver keys with this configuration
Show 3 variantsHide 3 variants

Discriminated by @odata.type. Select one variant:

#Microsoft.Media.ContentKeyPolicyOpenRestrictionobjectContentKeyPolicyOpenRestriction
Represents an open restriction. License or key will be delivered on every request.
@odata.typestringRequired
The discriminator for derived types.
#Microsoft.Media.ContentKeyPolicyTokenRestrictionobjectContentKeyPolicyTokenRestriction
Represents a token restriction. Provided token must match these requirements for successful license or key delivery.
@odata.typestringRequired
The discriminator for derived types.
alternateVerificationKeyslist of objectsOptional
A list of alternative verification keys.
Show 3 variantsHide 3 variants

Discriminated by @odata.type. Select one variant:

#Microsoft.Media.ContentKeyPolicyRsaTokenKeyobjectContentKeyPolicyRsaTokenKey
Specifies a RSA key for token validation
@odata.typestringRequired
The discriminator for derived types.
exponentstring or nullRequiredformat: byte
The RSA Parameter exponent
modulusstring or nullRequiredformat: byte
The RSA Parameter modulus
#Microsoft.Media.ContentKeyPolicySymmetricTokenKeyobjectContentKeyPolicySymmetricTokenKey
Specifies a symmetric key for token validation.
@odata.typestringRequired
The discriminator for derived types.
keyValuestring or nullRequiredformat: byte
The key value of the key
#Microsoft.Media.ContentKeyPolicyX509CertificateTokenKeyobjectContentKeyPolicyX509CertificateTokenKey
Specifies a certificate for token validation.
@odata.typestringRequired
The discriminator for derived types.
rawBodystring or nullRequiredformat: byte
The raw data field of a certificate in PKCS 12 format (X509Certificate2 in .NET)
audiencestringRequired
The audience for the token.
issuerstringRequired
The token issuer.
openIdConnectDiscoveryDocumentstringOptional
The OpenID connect discovery document.
primaryVerificationKeyobject or nullRequired
The primary verification key.
Show 3 variantsHide 3 variants

Discriminated by @odata.type. Select one variant:

#Microsoft.Media.ContentKeyPolicyRsaTokenKeyobjectContentKeyPolicyRsaTokenKey
Specifies a RSA key for token validation
@odata.typestringRequired
The discriminator for derived types.
exponentstring or nullRequiredformat: byte
The RSA Parameter exponent
modulusstring or nullRequiredformat: byte
The RSA Parameter modulus
#Microsoft.Media.ContentKeyPolicySymmetricTokenKeyobjectContentKeyPolicySymmetricTokenKey
Specifies a symmetric key for token validation.
@odata.typestringRequired
The discriminator for derived types.
keyValuestring or nullRequiredformat: byte
The key value of the key
#Microsoft.Media.ContentKeyPolicyX509CertificateTokenKeyobjectContentKeyPolicyX509CertificateTokenKey
Specifies a certificate for token validation.
@odata.typestringRequired
The discriminator for derived types.
rawBodystring or nullRequiredformat: byte
The raw data field of a certificate in PKCS 12 format (X509Certificate2 in .NET)
requiredClaimslist of objectsContentKeyPolicyTokenClaimOptional
A list of required token claims.
Show 2 propertiesHide 2 properties
claimTypestringOptional
Token claim type.
claimValuestringOptional
Token claim value.
restrictionTokenTypeenumRequired
The type of token.
Allowed values:UnknownSwtJwt
#Microsoft.Media.ContentKeyPolicyUnknownRestrictionobjectContentKeyPolicyUnknownRestriction
Represents a ContentKeyPolicyRestriction that is unavailable in the current API version.
@odata.typestringRequired
The discriminator for derived types.
policyIdstringOptionalformat: uuid
The legacy Policy ID.
systemDataobjectSystemDataSchemaOptional
Metadata pertaining to creation and last modification of the resource.
Show 7 propertiesHide 7 properties
createdAtstringRequiredformat: date-time
The timestamp of resource creation (UTC).
createdBystringRequired
The identity that created the resource.
createdByTypeenumRequired
The type of identity that created the resource.
Allowed values:UserApplicationManagedIdentityKey
internalIdstringRequiredformat: uuid
The internal ID of the resource.
lastModifiedAtstringRequiredformat: date-time
The timestamp of resource last modification (UTC).
lastModifiedBystringRequired
The identity that last modified the resource.
lastModifiedByTypeenumRequired
The type of identity that last modified the resource.
Allowed values:UserApplicationManagedIdentityKey
typestringOptional
The type of the resource. E.g. "Microsoft.Media/mediaservices/assets"

Errors

400 Bad Request
errorobjectErrorDetailRequired
Pertinent information about the error
Show 3 propertiesHide 3 properties
codestringRequired
The error code.
detailstringRequired
The error message.
extraDetailmap from strings to anyOptional
Extra information regarding this error.
Show value schemaHide value schema
[any key]any
refstringRequired
A reference to the request that caused the error.
statusintegerRequired
The HTTP status code
401 Unauthorized
errorobjectErrorDetailRequired
Pertinent information about the error
Show 3 propertiesHide 3 properties
codestringRequired
The error code.
detailstringRequired
The error message.
extraDetailmap from strings to anyOptional
Extra information regarding this error.
Show value schemaHide value schema
[any key]any
refstringRequired
A reference to the request that caused the error.
statusintegerRequired
The HTTP status code
403 Forbidden
errorobjectErrorDetailRequired
Pertinent information about the error
Show 3 propertiesHide 3 properties
codestringRequired
The error code.
detailstringRequired
The error message.
extraDetailmap from strings to anyOptional
Extra information regarding this error.
Show value schemaHide value schema
[any key]any
refstringRequired
A reference to the request that caused the error.
statusintegerRequired
The HTTP status code
404 Not Found
errorobjectErrorDetailRequired
Pertinent information about the error
Show 3 propertiesHide 3 properties
codestringRequired
The error code.
detailstringRequired
The error message.
extraDetailmap from strings to anyOptional
Extra information regarding this error.
Show value schemaHide value schema
[any key]any
refstringRequired
A reference to the request that caused the error.
statusintegerRequired
The HTTP status code
429 Too Many Requests
errorobjectErrorDetailRequired
Pertinent information about the error
Show 3 propertiesHide 3 properties
codestringRequired
The error code.
detailstringRequired
The error message.
extraDetailmap from strings to anyOptional
Extra information regarding this error.
Show value schemaHide value schema
[any key]any
refstringRequired
A reference to the request that caused the error.
statusintegerRequired
The HTTP status code
500 Internal Server Error
errorobjectErrorDetailRequired
Pertinent information about the error
Show 3 propertiesHide 3 properties
codestringRequired
The error code.
detailstringRequired
The error message.
extraDetailmap from strings to anyOptional
Extra information regarding this error.
Show value schemaHide value schema
[any key]any
refstringRequired
A reference to the request that caused the error.
statusintegerRequired
The HTTP status code