All Products
Search
Document Center

Key Management Service:DeleteKeyMaterial

Last Updated:Jul 29, 2025

Deletes the key material that you imported.

Operation description

This operation does not delete the CMK that is created by using the key material.

If the CMK is in the PendingDeletion state, the state of the CMK and the scheduled deletion time do not change after you call this operation. If the CMK is not in the PendingDeletion state, the state of the CMK changes to PendingImport after you call this operation.

After you delete the key material, you can upload only the same key material into the CMK.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
KeyIdstringYes

The globally unique ID of the CMK.

1234abcd-12ab-34cd-56ef-12345678****

Response parameters

ParameterTypeDescriptionExample
object
RequestIdstring

The ID of the request.

4162a6af-bc99-40b3-a552-89dcc8aaf7c8

Examples

Sample success responses

JSONformat

{
  "RequestId": "4162a6af-bc99-40b3-a552-89dcc8aaf7c8"
}

Error codes

For a list of error codes, visit the Service error codes.