DpsCertificateOperations Class
DpsCertificateOperations 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.objectDpsCertificateOperations
Constructor
DpsCertificateOperations(client, config, serializer, deserializer)
Parameters
Name | Description |
---|---|
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
Name | Description |
---|---|
models
|
Alias to model classes used in this operation group. |
Methods
create_or_update |
Upload the certificate to the provisioning service. Add new certificate or update an existing certificate. |
delete |
Delete the Provisioning Service Certificate. Deletes the specified certificate associated with the Provisioning Service. |
generate_verification_code |
Generate verification code for Proof of Possession. |
get |
Get the certificate from the provisioning service. |
list |
Get all the certificates tied to the provisioning service. |
verify_certificate |
Verify certificate's private key possession. Verifies the certificate's private key possession by providing the leaf cert issued by the verifying pre uploaded certificate. |
create_or_update
Upload the certificate to the provisioning service.
Add new certificate or update an existing certificate.
create_or_update(resource_group_name: str, provisioning_service_name: str, certificate_name: str, certificate_description: CertificateBodyDescription, if_match: str | None = None, **kwargs: Any) -> CertificateResponse
Parameters
Name | Description |
---|---|
resource_group_name
Required
|
Resource group identifier. |
provisioning_service_name
Required
|
The name of the provisioning service. |
certificate_name
Required
|
The name of the certificate create or update. |
certificate_description
Required
|
The certificate body. |
if_match
Required
|
ETag of the certificate. This is required to update an existing certificate, and ignored while creating a brand new certificate. |
Keyword-Only Parameters
Name | Description |
---|---|
cls
|
A custom type or function that will be passed the direct response |
Returns
Type | Description |
---|---|
CertificateResponse, or the result of cls(response) |
Exceptions
Type | Description |
---|---|
delete
Delete the Provisioning Service Certificate.
Deletes the specified certificate associated with the Provisioning Service.
delete(resource_group_name: str, if_match: str, provisioning_service_name: str, certificate_name: str, certificate_name1: str | None = None, certificate_raw_bytes: bytearray | None = None, certificate_is_verified: bool | None = None, certificate_purpose: str | CertificatePurpose | None = None, certificate_created: datetime | None = None, certificate_last_updated: datetime | None = None, certificate_has_private_key: bool | None = None, certificate_nonce: str | None = None, **kwargs: Any) -> None
Parameters
Name | Description |
---|---|
resource_group_name
Required
|
Resource group identifier. |
if_match
Required
|
ETag of the certificate. |
provisioning_service_name
Required
|
The name of the provisioning service. |
certificate_name
Required
|
This is a mandatory field, and is the logical name of the certificate that the provisioning service will access by. |
certificate_name1
Required
|
This is optional, and it is the Common Name of the certificate. |
certificate_raw_bytes
Required
|
Raw data within the certificate. |
certificate_is_verified
Required
|
Indicates if certificate has been verified by owner of the private key. |
certificate_purpose
Required
|
A description that mentions the purpose of the certificate. |
certificate_created
Required
|
Time the certificate is created. |
certificate_last_updated
Required
|
Time the certificate is last updated. |
certificate_has_private_key
Required
|
Indicates if the certificate contains a private key. |
certificate_nonce
Required
|
Random number generated to indicate Proof of Possession. |
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 |
---|---|
generate_verification_code
Generate verification code for Proof of Possession.
generate_verification_code(certificate_name: str, if_match: str, resource_group_name: str, provisioning_service_name: str, certificate_name1: str | None = None, certificate_raw_bytes: bytearray | None = None, certificate_is_verified: bool | None = None, certificate_purpose: str | CertificatePurpose | None = None, certificate_created: datetime | None = None, certificate_last_updated: datetime | None = None, certificate_has_private_key: bool | None = None, certificate_nonce: str | None = None, **kwargs: Any) -> VerificationCodeResponse
Parameters
Name | Description |
---|---|
certificate_name
Required
|
The mandatory logical name of the certificate, that the provisioning service uses to access. |
if_match
Required
|
ETag of the certificate. This is required to update an existing certificate, and ignored while creating a brand new certificate. |
resource_group_name
Required
|
name of resource group. |
provisioning_service_name
Required
|
Name of provisioning service. |
certificate_name1
Required
|
Common Name for the certificate. |
certificate_raw_bytes
Required
|
Raw data of certificate. |
certificate_is_verified
Required
|
Indicates if the certificate has been verified by owner of the private key. |
certificate_purpose
Required
|
Description mentioning the purpose of the certificate. |
certificate_created
Required
|
Certificate creation time. |
certificate_last_updated
Required
|
Certificate last updated time. |
certificate_has_private_key
Required
|
Indicates if the certificate contains private key. |
certificate_nonce
Required
|
Random number generated to indicate Proof of Possession. |
Keyword-Only Parameters
Name | Description |
---|---|
cls
|
A custom type or function that will be passed the direct response |
Returns
Type | Description |
---|---|
VerificationCodeResponse, or the result of cls(response) |
Exceptions
Type | Description |
---|---|
get
Get the certificate from the provisioning service.
get(certificate_name: str, resource_group_name: str, provisioning_service_name: str, if_match: str | None = None, **kwargs: Any) -> CertificateResponse
Parameters
Name | Description |
---|---|
certificate_name
Required
|
Name of the certificate to retrieve. |
resource_group_name
Required
|
Resource group identifier. |
provisioning_service_name
Required
|
Name of the provisioning service the certificate is associated with. |
if_match
Required
|
ETag of the certificate. |
Keyword-Only Parameters
Name | Description |
---|---|
cls
|
A custom type or function that will be passed the direct response |
Returns
Type | Description |
---|---|
CertificateResponse, or the result of cls(response) |
Exceptions
Type | Description |
---|---|
list
Get all the certificates tied to the provisioning service.
list(resource_group_name: str, provisioning_service_name: str, **kwargs: Any) -> CertificateListDescription
Parameters
Name | Description |
---|---|
resource_group_name
Required
|
Name of resource group. |
provisioning_service_name
Required
|
Name of provisioning service to retrieve certificates for. |
Keyword-Only Parameters
Name | Description |
---|---|
cls
|
A custom type or function that will be passed the direct response |
Returns
Type | Description |
---|---|
CertificateListDescription, or the result of cls(response) |
Exceptions
Type | Description |
---|---|
verify_certificate
Verify certificate's private key possession.
Verifies the certificate's private key possession by providing the leaf cert issued by the verifying pre uploaded certificate.
verify_certificate(certificate_name: str, if_match: str, resource_group_name: str, provisioning_service_name: str, request: VerificationCodeRequest, certificate_name1: str | None = None, certificate_raw_bytes: bytearray | None = None, certificate_is_verified: bool | None = None, certificate_purpose: str | CertificatePurpose | None = None, certificate_created: datetime | None = None, certificate_last_updated: datetime | None = None, certificate_has_private_key: bool | None = None, certificate_nonce: str | None = None, **kwargs: Any) -> CertificateResponse
Parameters
Name | Description |
---|---|
certificate_name
Required
|
The mandatory logical name of the certificate, that the provisioning service uses to access. |
if_match
Required
|
ETag of the certificate. |
resource_group_name
Required
|
Resource group name. |
provisioning_service_name
Required
|
Provisioning service name. |
request
Required
|
The name of the certificate. |
certificate_name1
Required
|
Common Name for the certificate. |
certificate_raw_bytes
Required
|
Raw data of certificate. |
certificate_is_verified
Required
|
Indicates if the certificate has been verified by owner of the private key. |
certificate_purpose
Required
|
Describe the purpose of the certificate. |
certificate_created
Required
|
Certificate creation time. |
certificate_last_updated
Required
|
Certificate last updated time. |
certificate_has_private_key
Required
|
Indicates if the certificate contains private key. |
certificate_nonce
Required
|
Random number generated to indicate Proof of Possession. |
Keyword-Only Parameters
Name | Description |
---|---|
cls
|
A custom type or function that will be passed the direct response |
Returns
Type | Description |
---|---|
CertificateResponse, or the result of cls(response) |
Exceptions
Type | Description |
---|---|
Attributes
models
models = <module 'azure.mgmt.iothubprovisioningservices.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.11.9\\x64\\Lib\\site-packages\\azure\\mgmt\\iothubprovisioningservices\\models\\__init__.py'>
Azure SDK for Python