CertificateOperations Class

CertificateOperations operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Inheritance
builtins.object
CertificateOperations

Constructor

CertificateOperations(client, config, serializer, deserializer)

Parameters

client
Required

Client for service requests.

config
Required

Configuration of service client.

serializer
Required

An object model serializer.

deserializer
Required

An object model deserializer.

Variables

models

Alias to model classes used in this operation group.

Methods

begin_delete

Deletes the specified certificate.

cancel_deletion

Cancels a failed deletion of a certificate from the specified account.

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this operation to set the status of the certificate back to active. If you intend to delete the certificate, you do not need to run this operation after the deletion failed. You must make sure that the certificate is not being used by any resources, and then you can try again to delete the certificate.

create

Creates a new certificate inside the specified account.

get

Gets information about the specified certificate.

list_by_batch_account

Lists all of the certificates in the specified account.

update

Updates the properties of an existing certificate.

begin_delete

Deletes the specified certificate.

begin_delete(resource_group_name: str, account_name: str, certificate_name: str, **kwargs: Any) -> azure.core.polling._poller.LROPoller[None]

Parameters

resource_group_name
str
Required

The name of the resource group that contains the Batch account.

account_name
str
Required

The name of the Batch account.

certificate_name
str
Required

The identifier for the certificate. This must be made up of algorithm and thumbprint separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5.

cls
callable

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

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or PollingMethod

By default, your polling method will be ARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of LROPoller that returns either None or the result of cls(response)

Return type

Exceptions

cancel_deletion

Cancels a failed deletion of a certificate from the specified account.

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this operation to set the status of the certificate back to active. If you intend to delete the certificate, you do not need to run this operation after the deletion failed. You must make sure that the certificate is not being used by any resources, and then you can try again to delete the certificate.

cancel_deletion(resource_group_name: str, account_name: str, certificate_name: str, **kwargs: Any) -> azure.mgmt.batch.models._models_py3.Certificate

Parameters

resource_group_name
str
Required

The name of the resource group that contains the Batch account.

account_name
str
Required

The name of the Batch account.

certificate_name
str
Required

The identifier for the certificate. This must be made up of algorithm and thumbprint separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5.

cls
callable

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

Returns

Certificate, or the result of cls(response)

Return type

Exceptions

create

Creates a new certificate inside the specified account.

create(resource_group_name: str, account_name: str, certificate_name: str, parameters: azure.mgmt.batch.models._models_py3.CertificateCreateOrUpdateParameters, if_match: Optional[str] = None, if_none_match: Optional[str] = None, **kwargs: Any) -> azure.mgmt.batch.models._models_py3.Certificate

Parameters

resource_group_name
str
Required

The name of the resource group that contains the Batch account.

account_name
str
Required

The name of the Batch account.

certificate_name
str
Required

The identifier for the certificate. This must be made up of algorithm and thumbprint separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5.

parameters
CertificateCreateOrUpdateParameters
Required

Additional parameters for certificate creation.

if_match
str
Required

The entity state (ETag) version of the certificate to update. A value of "*" can be used to apply the operation only if the certificate already exists. If omitted, this operation will always be applied. Default value is None.

if_none_match
str
Required

Set to '*' to allow a new certificate to be created, but to prevent updating an existing certificate. Other values will be ignored. Default value is None.

cls
callable

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

Returns

Certificate, or the result of cls(response)

Return type

Exceptions

get

Gets information about the specified certificate.

get(resource_group_name: str, account_name: str, certificate_name: str, **kwargs: Any) -> azure.mgmt.batch.models._models_py3.Certificate

Parameters

resource_group_name
str
Required

The name of the resource group that contains the Batch account.

account_name
str
Required

The name of the Batch account.

certificate_name
str
Required

The identifier for the certificate. This must be made up of algorithm and thumbprint separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5.

cls
callable

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

Returns

Certificate, or the result of cls(response)

Return type

Exceptions

list_by_batch_account

Lists all of the certificates in the specified account.

list_by_batch_account(resource_group_name: str, account_name: str, maxresults: Optional[int] = None, select: Optional[str] = None, filter: Optional[str] = None, **kwargs: Any) -> Iterable[azure.mgmt.batch.models._models_py3.ListCertificatesResult]

Parameters

resource_group_name
str
Required

The name of the resource group that contains the Batch account.

account_name
str
Required

The name of the Batch account.

maxresults
int
Required

The maximum number of items to return in the response. Default value is None.

select
str
Required

Comma separated list of properties that should be returned. e.g. "properties/provisioningState". Only top level properties under properties/ are valid for selection. Default value is None.

filter
str
Required

OData filter expression. Valid properties for filtering are "properties/provisioningState", "properties/provisioningStateTransitionTime", "name". Default value is None.

cls
callable

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

Returns

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

Return type

Exceptions

update

Updates the properties of an existing certificate.

update(resource_group_name: str, account_name: str, certificate_name: str, parameters: azure.mgmt.batch.models._models_py3.CertificateCreateOrUpdateParameters, if_match: Optional[str] = None, **kwargs: Any) -> azure.mgmt.batch.models._models_py3.Certificate

Parameters

resource_group_name
str
Required

The name of the resource group that contains the Batch account.

account_name
str
Required

The name of the Batch account.

certificate_name
str
Required

The identifier for the certificate. This must be made up of algorithm and thumbprint separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5.

parameters
CertificateCreateOrUpdateParameters
Required

Certificate entity to update.

if_match
str
Required

The entity state (ETag) version of the certificate to update. This value can be omitted or set to "*" to apply the operation unconditionally. Default value is None.

cls
callable

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

Returns

Certificate, or the result of cls(response)

Return type

Exceptions

Attributes

models

models = <module 'azure.mgmt.batch.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.9.13\\x64\\lib\\site-packages\\azure\\mgmt\\batch\\models\\__init__.py'>