Certificate

akamai_cloudcertificates_certificate

📘

Beta

Hello. Just a note to let you know the underlying API on which this resource is built is general release and has been vetted, but because this is a new feature for our Terraform provider, we've given it beta label.

This status just means we've paused for a bit to get your feedback to make sure this data source works like you need and expect.

Create, update, or delete third-party certificates. You can only update the base_name argument.

resource "akamai_cloudcertificates_certificate" "my-cert" {
  contract_id    = "C-0N7RAC7"
  group_id       = "12345"
  key_size       = "2048"
  key_type       = "RSA"
  secure_network = "ENHANCED_TLS"
  sans           = ["example.com"]
}
resource "akamai_cloudcertificates_certificate" "my-cert" {
  base_name      = "my-cert"
  contract_id    = "C-0N7RAC7"
  group_id       = "12345"
  key_size       = "2048"
  key_type       = "RSA"
  secure_network = "ENHANCED_TLS"
  sans           = ["example.com"]
  subject = {
    common_name  = "example.com"
    organization = "Main Street Corporation"
    country      = "US"
    state        = "MA"
    locality     = "Cambridge"
  }
}
my-cert = {
  account_id          = "A-CCT1234"
  base_name           = "my-cert"
  certificate_id      = "12345"
  certificate_status  = "CSR_READY"
  certificate_type    = "THIRD_PARTY"
  contract_id         = "C-0N7RAC7"
  created_by          = "jsmith"
  created_date        = "2025-11-03T10:36:23.133837Z"
  csr_expiration_date = "2027-01-05T10:36:23Z"
  csr_pem             = <<-EOT
    -----BEGIN CERTIFICATE REQUEST-----
    MIID <sample - removed for readability> .... Mweq
    -----END CERTIFICATE REQUEST-----
  EOT
  group_id            = "98765"
  key_size            = "2048"
  key_type            = "RSA"
  modified_by         = "jsmith"
  modified_date       = "2025-11-03T10:36:23.133839Z"
  name                = "my-cert"
  sans                = [
    "example.com",
  ]
  secure_network      = "ENHANCED_TLS"
  subject             = {
    common_name  = "example.com"
    country      = "US"
    locality     = "Cambridge"
    organization = "Main Street Corporation"
    state        = "MA"
  }
}

Arguments

Send all the required arguments to create a third-party certificate.

Argument Required Description
contract_id Your contract's ID.
key_size Your certificate's key size. Possible values are:
  • 2048 for the RSA key type.
  • P-256 for the ECDSA key type.
key_type Your certificate's key type, either RSA or ECDSA.
sans A list of subject alternative names (SANs) secured by the certificate. Must contain valid, lowercase domain names, each optionally starting with *. for a wildcard.
secure_network The type of security on a deployment network. Only ENHANCED_TLS is supported.
base_name The name for the certificate. If not provided, CCM auto-generates the name.
group_id Required only when creating a new certificate. Your group's ID.
subject Subject fields as defined in X.509 certificates (RFC 5280). Includes:
  • common_name. A fully qualified domain name (FQDN) or other name associated with the subject. Must be a valid domain name with all lowercase letters, optionally starting with *. for a wildcard.
  • organization. The name of your business, organization, or company.
  • locality. The city where your organization resides.
  • state. Your organization's region, typically a state or province.
  • country. A two-letter ISO 3166 code for the country where your organization resides.

Attributes

There's no standard output for this resource as changes are reflected in your state file and based on what you passed in the resource block body.

Attribute Description
account_id The account's ID.
certificate_id The certificate's ID.
name The certificate's name.
certificate_status The certificate's status. Possible values are:
  • CSR_READY. The CSR generation is complete and available for download.
  • READY_FOR_USE. The signed certificate, with or without its trust chain, has been accepted and is now ready for use.
  • ACTIVE. The certificate is bound to a property hostname and is being used on one or more networks.
certificate_type The certificate type. This attribute populates only with the THIRD_PARTY value.
created_by The user who created the certificate.
created_date The timestamp indicating when the certificate was created.
csr_expiration_date The timestamp indicating when the CSR will expire. A signed certificate uploaded based on that CSR won't be accepted beyond this date.
csr_pem A text representation of the certificate signing request (CSR) in PEM format.
modified_by The user who modified the certificate.
modified_date The timestamp indicating when the certificate was modified.