REST API Download CA Certificate
Download CA Certificate HTTPS GET
To download a CA certificate using the ZeroSSL API, use the download endpoint and pass the certificate identifier in the {identifier} URL parameter. The identifier can be either a numeric CA certificate ID or a SHA-1 hash.
The optional {method} parameter lets you choose the download format.
API Request URL:
api.zerossl.com/ca_certificates/{identifier}/download/{method}?access_key=...
HTTPS GET Request Parameters:
| Parameter | Description |
|---|---|
access_key |
[Required] Use this parameter to specify your API access key. |
{identifier} |
[Required] Use this parameter to specify the CA certificate identifier. Accepts either the numeric CA certificate ID or the SHA-1 hash of the certificate. |
{method} |
[Optional] Use this parameter to specify the response format for the download.
|
API Responses based on method parameter:
zip:
If your API request is successful, the ZeroSSL API will return your CA certificate files wrapped in a ZIP-file.
json:
If your API request is successful, the ZeroSSL API will return your CA certificate files in JSON format. You will find an example API response below:
{
"certificate_intermediate.crt": "-----BEGIN CERTIFICATE-----\n...\n-----END CERTIFICATE-----",
"bundle_full.crt": "-----BEGIN CERTIFICATE-----\n...\n-----END CERTIFICATE-----",
}
Response attributes:
| Parameter | Description |
|---|---|
certificate_intermediate.crt |
Returns the CA certificate in PEM format. |
bundle_full.crt |
Returns the CA certificate bundle in PEM format. |
pem:
If your API request is successful, the ZeroSSL API will return the CA certificate in plain text PEM format.
chain:
If your API request is successful, the ZeroSSL API will return the CA certificate bundle in plain text format.
xml:
If your API request is successful, the ZeroSSL API will return your CA certificate resource representation in XML format. Note that key names with dots are converted to underscores (e.g. certificate_intermediate.crt becomes certificate_intermediate_crt).