curl --request GET \
--url https://api.gcore.com/cdn/aliases/{alias_id}/status \
--header 'Authorization: <api-key>'import requests
url = "https://api.gcore.com/cdn/aliases/{alias_id}/status"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.gcore.com/cdn/aliases/{alias_id}/status', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.gcore.com/cdn/aliases/{alias_id}/status",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.gcore.com/cdn/aliases/{alias_id}/status"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.gcore.com/cdn/aliases/{alias_id}/status")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gcore.com/cdn/aliases/{alias_id}/status")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": 1,
"statuses": [
{
"id": 1,
"status": "DONE",
"error": "",
"details": "",
"created": "2021-10-29T13:21:01.550849Z",
"retry_after": "2024-01-01T10:00:00Z"
}
],
"latest_status": {
"id": 1,
"status": "DONE",
"error": "",
"details": "",
"created": "2021-10-29T13:21:01.550849Z",
"retry_after": "2024-01-01T10:00:00Z"
},
"started": "2021-10-29T13:20:56.543678Z",
"finished": "2021-10-29T13:21:01.550849Z",
"active": false,
"attempts_count": 1,
"next_attempt_time": "2021-10-29T13:21:01.550849Z",
"resource": 1,
"validation_state": "AWAITING_CNAME",
"cname_records": [
{
"cname_name": "_acme-challenge.shop.customer.com",
"cname_target": "0a1b2c3d4e5f6789.le-challenges.gcorelabs.com"
}
]
}{
"errors": {
"field_name": [
"Error description."
]
}
}Get alias certificate issuing details
Get details about the latest Let’s Encrypt certificate issuing attempt for an alias, including the CNAME records to create for domain validation. Returns attempts in all statuses.
While the alias is switching to a Let’s Encrypt certificate, the attempt for the new certificate is returned.
curl --request GET \
--url https://api.gcore.com/cdn/aliases/{alias_id}/status \
--header 'Authorization: <api-key>'import requests
url = "https://api.gcore.com/cdn/aliases/{alias_id}/status"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.gcore.com/cdn/aliases/{alias_id}/status', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.gcore.com/cdn/aliases/{alias_id}/status",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.gcore.com/cdn/aliases/{alias_id}/status"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.gcore.com/cdn/aliases/{alias_id}/status")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gcore.com/cdn/aliases/{alias_id}/status")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": 1,
"statuses": [
{
"id": 1,
"status": "DONE",
"error": "",
"details": "",
"created": "2021-10-29T13:21:01.550849Z",
"retry_after": "2024-01-01T10:00:00Z"
}
],
"latest_status": {
"id": 1,
"status": "DONE",
"error": "",
"details": "",
"created": "2021-10-29T13:21:01.550849Z",
"retry_after": "2024-01-01T10:00:00Z"
},
"started": "2021-10-29T13:20:56.543678Z",
"finished": "2021-10-29T13:21:01.550849Z",
"active": false,
"attempts_count": 1,
"next_attempt_time": "2021-10-29T13:21:01.550849Z",
"resource": 1,
"validation_state": "AWAITING_CNAME",
"cname_records": [
{
"cname_name": "_acme-challenge.shop.customer.com",
"cname_target": "0a1b2c3d4e5f6789.le-challenges.gcorelabs.com"
}
]
}{
"errors": {
"field_name": [
"Error description."
]
}
}Authorizations
API key for authentication. Make sure to include the word apikey, followed by a single space and then your token.
Example: apikey 1234_abcdef
Path Parameters
Alias ID.
Response
Successful.
ID of the attempt to issue a Let's Encrypt certificate.
1
Detailed information about attempts to issue a Let's Encrypt certificate.
Show child attributes
Show child attributes
Detailed information about last attempt to issue a Let's Encrypt certificate.
The field is null until the first attempt of the issuing process has been recorded.
Show child attributes
Show child attributes
Date when the process of issuing a Let's Encrypt certificate was started (ISO 8601/RFC 3339 format, UTC).
"2021-10-29T13:20:56.543678Z"
Date when the process of issuing a Let's Encrypt certificate was finished (ISO 8601/RFC 3339 format, UTC).
The field is null if the issuing process is not finished.
"2021-10-29T13:21:01.550849Z"
Defines whether the Let's Encrypt certificate issuing process is active.
Possible values:
- true - Issuing process is active.
- false - Issuing process is completed.
false
Number of attempts to issue the Let's Encrypt certificate.
1
Time of the next scheduled attempt to issue the Let's Encrypt certificate (ISO 8601/RFC 3339 format, UTC).
"2021-10-29T13:21:01.550849Z"
CDN resource ID.
1
State of the domain validation for this attempt.
Possible values:
- PENDING - Validation has not started yet.
AWAITING_CNAME- Waiting for the CNAME records below to be created.- VALIDATING - Validation is in progress.
- COMPLETED - Validation succeeded.
- FAILED - Validation did not succeed.
"AWAITING_CNAME"
CNAME records to create so Let's Encrypt domain validation can complete for the alias hostname.
Show child attributes
Show child attributes
Was this page helpful?