ContentKeyPoliciesOperations Class

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through

AzureMediaServices's

<xref:content_key_policies> attribute.

Inheritance
builtins.object
ContentKeyPoliciesOperations

Constructor

ContentKeyPoliciesOperations(*args, **kwargs)

Methods

create_or_update

Create or update an Content Key Policy.

Create or update a Content Key Policy in the Media Services account.

delete

Delete a Content Key Policy.

Deletes a Content Key Policy in the Media Services account.

get

Get a Content Key Policy.

Get the details of a Content Key Policy in the Media Services account.

get_policy_properties_with_secrets

Get a Content Key Policy with secrets.

Get a Content Key Policy including secret values.

list

List Content Key Policies.

Lists the Content Key Policies in the account.

update

Update a Content Key Policy.

Updates an existing Content Key Policy in the Media Services account.

create_or_update

Create or update an Content Key Policy.

Create or update a Content Key Policy in the Media Services account.

create_or_update(resource_group_name: str, account_name: str, content_key_policy_name: str, parameters: _models.ContentKeyPolicy, *, content_type: str = 'application/json', **kwargs: Any) -> _models.ContentKeyPolicy

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group within the Azure subscription. Required.

account_name
Required
str

The Media Services account name. Required.

content_key_policy_name
Required
str

The Content Key Policy name. Required.

parameters
Required

The request parameters. Is either a model type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

ContentKeyPolicy or the result of cls(response)

Exceptions

Type Description

delete

Delete a Content Key Policy.

Deletes a Content Key Policy in the Media Services account.

delete(resource_group_name: str, account_name: str, content_key_policy_name: str, **kwargs: Any) -> None

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group within the Azure subscription. Required.

account_name
Required
str

The Media Services account name. Required.

content_key_policy_name
Required
str

The Content Key Policy name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

None or the result of cls(response)

Exceptions

Type Description

get

Get a Content Key Policy.

Get the details of a Content Key Policy in the Media Services account.

get(resource_group_name: str, account_name: str, content_key_policy_name: str, **kwargs: Any) -> ContentKeyPolicy

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group within the Azure subscription. Required.

account_name
Required
str

The Media Services account name. Required.

content_key_policy_name
Required
str

The Content Key Policy name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

ContentKeyPolicy or the result of cls(response)

Exceptions

Type Description

get_policy_properties_with_secrets

Get a Content Key Policy with secrets.

Get a Content Key Policy including secret values.

get_policy_properties_with_secrets(resource_group_name: str, account_name: str, content_key_policy_name: str, **kwargs: Any) -> ContentKeyPolicyProperties

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group within the Azure subscription. Required.

account_name
Required
str

The Media Services account name. Required.

content_key_policy_name
Required
str

The Content Key Policy name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

ContentKeyPolicyProperties or the result of cls(response)

Exceptions

Type Description

list

List Content Key Policies.

Lists the Content Key Policies in the account.

list(resource_group_name: str, account_name: str, filter: str | None = None, top: int | None = None, orderby: str | None = None, **kwargs: Any) -> Iterable[ContentKeyPolicy]

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group within the Azure subscription. Required.

account_name
Required
str

The Media Services account name. Required.

filter
Required
str

Restricts the set of items returned. Default value is None.

top
Required
int

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. Default value is None.

orderby
Required
str

Specifies the key by which the result collection should be ordered. Default value is None.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

An iterator like instance of either ContentKeyPolicy or the result of cls(response)

Exceptions

Type Description

update

Update a Content Key Policy.

Updates an existing Content Key Policy in the Media Services account.

update(resource_group_name: str, account_name: str, content_key_policy_name: str, parameters: _models.ContentKeyPolicy, *, content_type: str = 'application/json', **kwargs: Any) -> _models.ContentKeyPolicy

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group within the Azure subscription. Required.

account_name
Required
str

The Media Services account name. Required.

content_key_policy_name
Required
str

The Content Key Policy name. Required.

parameters
Required

The request parameters. Is either a model type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

ContentKeyPolicy or the result of cls(response)

Exceptions

Type Description

Attributes

models

models = <module 'azure.mgmt.media.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.11.9\\x64\\Lib\\site-packages\\azure\\mgmt\\media\\models\\__init__.py'>