Create Key Rotation Policy

POST {{apiPath}}/environments/{{envID}}/keyRotationPolicies

The POST /environments/{{envID}}/keyRotationPolicies operation creates a new key rotation policy in the specified environment.

Prerequisites

For property descriptions, see Key Rotation Policy data model.

PropertyTypeRequired?
algorithmStringRequired
currentKeyIdUUIDN/A
dnStringRequired
idUUIDN/A
keyLengthIntegerRequired
nameStringRequired
nextKeyIdUUIDN/A
rotatedAtDateN/A
rotationPeriodIntegerOptional
signatureAlgorithmStringRequired
usageTypeStringRequired
validityPeriodIntegerRequired

Request Body

{"name"=>"Test Key Rotation Policy", "dn"=>"CN=Test Key Rotation Policy, OU=Ping Identity, O=Ping Identity, L=, ST=, C=US", "algorithm"=>"RSA", "keyLength"=>2048, "validityPeriod"=>365, "signatureAlgorithm"=>"SHA256withRSA", "usageType"=>"SIGNING", "rotationPeriod"=>120}

RESPONSES

status: Created

{"_links":{"self":{"href":"https://api.pingone.com/v1/environments/abfba8f6-49eb-49f5-a5d9-80ad5c98f9f6/keyRotationPolicies/ff6bf166-f28a-4a11-a0b3-4ce5ed2355f7"},"environment":{"href":"https://api.pingone.com/v1/environments/abfba8f6-49eb-49f5-a5d9-80ad5c98f9f6"}},"id":"ff6bf166-f28a-4a11-a0b3-4ce5ed2355f7","environment":{"id":"abfba8f6-49eb-49f5-a5d9-80ad5c98f9f6"},"name":"Test Key Rotation Policy","usageType":"SIGNING","default":false,"dn":"CN=Test Key Rotation Policy, OU=Ping Identity, O=Ping Identity, L=, ST=, C=US","algorithm":"RSA","keyLength":2048,"validityPeriod":365,"signatureAlgorithm":"SHA256withRSA","rotationPeriod":120,"currentKeyId":"96301ec0-944e-11ee-80f0-d99b1186931d","nextKeyId":"963e4f90-944e-11ee-80f0-d99b1186931d","rotatedAt":"2023-12-06T15:46:13.988Z"}