Create a custom SSL certificate

POST/v1/ssl_certificates/custom

Send a POST request to /v1/ssl_certificates/custom to create a new custom SSL certificate. Specify mandatory parameters marked as required in the request body.

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Request Body

FieldDetails
name
string

Give a name to a new SSL certificate.

public_key
string

Open a file containing a public key in the PEM format using a text editor. Usually, it has .pem, .crt, or .cer extensions. Copy and paste the file's content into this parameter with strings indicating a key's beginning and end.

The key has to be in accordance with the X.509 standard and be no longer than 32766 characters.

private_key
string

By analogy to a public key, open a file and paste its content in this parameter. The private key file typically has the .key extension.

This key also has to be in accordance with the X.509 standard and have no more than 32766 characters.

chain_key?
string

The chain key is an optional part of some certificates, also known as a chain of trust.

You can add intermediate and root certificates in this order. They are similar to the public key but belong to Certificate Authority.

labels?
object

Specify labels you want to attach to the resource. Refer to the Labels section for more details.

Response Body

application/json

application/json

curl -X POST "https://example.com/v1/ssl_certificates/custom" \  -H "Content-Type: application/json" \  -d '{    "name": "name504",    "public_key": "-----BEGIN CERTIFICATE-----\\nMIICuDCCAiGgAwIBAgIBADANBgkqhkiG9w0BAQUFADBEMQswCQYDVQQGEwJCRTEO\\nMAwGA1UECgwFVGVzdE8xDzANBgNVBAsMBlRlc3RPVTEUMBIGA1UEAwwLc2VydmVy\\ncy5jb20wHhcNMjYwNTI4MDY1ODIwWhcNMzYwNTI4MDY1ODIwWjBEMQswCQYDVQQG\\nEwJCRTEOMAwGA1UECgwFVGVzdE8xDzANBgNVBAsMBlRlc3RPVTEUMBIGA1UEAwwL\\nc2VydmVycy5jb20wgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBALXM5GNqJv13\\ndR38MtEESUomfXnXn1IPdstTsCmh+SMecpFYWylvmtudqSACnYTTqU4t7ptx320z\\nB7RpdH+vGUV9Q6+vGyRJn1Fr1trHQZ2dNba6stdQ6gew041Zlh300YKWHGlrCv+I\\nLfcFeMphIa0q8ZD1wJpiLAZR+E+6DBqBAgMBAAGjgbkwgbYwDwYDVR0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BBakQpUvkwJAKSggSv7Arw+rErRnd7HmY/cCzqbM\\nLdGMS2KRVPsqsxX5/q6ge/XGjfhG7H2EfhZgI6uU8A6RLWnD6D60RIuCIwJBAINU\\n4xjc2YvjoEHgC8m6f3BpS80Cpjlf7fq7jAZuZIDegYz5zFo7gFgGlNWyHfGfsy35\\nk4b2t5FFfwe17KEHaPUCQQDHe7r9XaUIeBd8WKYSTLhR2zM2nwkVAH9csF2U64EI\\nVaZf/gUh73DHWIisLVUCtyZMleOPWShf6Fj+uWUy855S\\n-----END RSA PRIVATE KEY-----\\n",    "labels": {      "environment": "production",      "service": "my-web-app",      "example.com/project": "my-project",      "example.com/owner": "my-team"    }  }'
{  "id": "Jxbojagw",  "name": "name504",  "type": "custom",  "issuer": "servers.com",  "subject": "servers.com",  "domain_names": [    "servers.com"  ],  "sha1_fingerprint": "22a36f9b730b22b4fd391f4173d86515f34cb126",  "labels": {    "environment": "production",    "service": "my-web-app",    "example.com/project": "my-project",    "example.com/owner": "my-team"  },  "expires_at": "2036-05-28T06:58:20Z",  "created_at": "2026-05-28T06:58:20Z",  "updated_at": "2026-05-28T06:58:20Z"}