Generate domain validation challenges

POST https://{{host}}/papi/v1/hostnames/certificate-challenges

If you're using Default Domain Validation (DV) certificates, you can generate the domain validation challenges ahead of setting hostnames for your property. Ordinarily, you get the challenges when you add hostnames to a property version or add hostnames to a property's hostname bucket. This operation returns the validationCname object that you use to validate the certificate's domain. For each requested property hostname, create a new CNAME record in the DNS configuration and map the object's hostname to the target.

Note: If you're using a new account, first register it on the Akamai network by activating any property version on either staging or production. Otherwise, your attempts to generate certificates will fail with a 403 error.

Request Params

KeyDatatypeRequiredDescription
accountSwitchKeystring(Optional) For customers who manage more than one account, this runs the operation from another account. The Identity and Access Management API provides a list of available account switch keys.

Request Body

{"cnamesFrom"=>["www.example1.com", "www.example2.com"]}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring
Acceptstring

RESPONSES

status: OK

{"accountId":"act_A-CCT9012","hostnames":{"items":[{"cnameFrom":"www.example1.com","validationCname":{"hostname":"_acme-challenge.www.example1.com","target":"ac.afae21b9a98d2d845d8032da0d689252.www.example1.com.validate-akdv.net"}},{"cnameFrom":"www.example2.com","validationCname":{"hostname":"_acme-challenge.www.example2.com.com","target":"ac.afae21b9a98d2d845d8032da0d689252.www.example2.com.validate-akdv.net"}}]}}