Certificates - Delete

Delete an X509 certificate.
Deletes an existing X509 certificate or does nothing if it does not exist.

DELETE https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}?api-version=2023-06-30

URI Parameters

Name In Required Type Description
certificateName
path True

string

The name of the certificate

Regex pattern: ^[A-Za-z0-9-._]{1,64}$

resourceGroupName
path True

string

The name of the resource group that contains the IoT hub.

resourceName
path True

string

The name of the IoT hub.

subscriptionId
path True

string

The subscription identifier.

api-version
query True

string

The version of the API.

Request Header

Name Required Type Description
If-Match True

string

ETag of the Certificate.

Responses

Name Type Description
200 OK

Certificate has been deleted.

204 No Content

Certificate does not exist.

Other Status Codes

ErrorDetails

DefaultErrorResponse

Security

azure_auth

Azure Active Directory OAuth2 Flow

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Examples

Certificates_Delete

Sample Request

DELETE https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/myhub/certificates/cert?api-version=2023-06-30

Sample Response

Definitions

ErrorDetails

Error details.

Name Type Description
code

string

The error code.

details

string

The error details.

httpStatusCode

string

The HTTP status code.

message

string

The error message.