Python
import os
from gcore import Gcore
client = Gcore(
api_key=os.environ.get("GCORE_API_KEY"), # This is the default and can be omitted
)
alias_detail = client.cdn.aliases.get(
0,
)
print(alias_detail)package main
import (
"context"
"fmt"
"github.com/G-Core/gcore-go"
"github.com/G-Core/gcore-go/option"
)
func main() {
client := gcore.NewClient(
option.WithAPIKey("My API Key"),
)
aliasDetail, err := client.CDN.Aliases.Get(context.TODO(), 0)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", aliasDetail)
}
curl --request GET \
--url https://api.gcore.com/cdn/aliases/{alias_id} \
--header 'Authorization: <api-key>'const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.gcore.com/cdn/aliases/{alias_id}', 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}",
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;
}HttpResponse<String> response = Unirest.get("https://api.gcore.com/cdn/aliases/{alias_id}")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gcore.com/cdn/aliases/{alias_id}")
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": 123,
"cname": "shop.example.com",
"resource_id": 4567,
"automated": true,
"challenge_type": "http_01",
"ssl_id": 890,
"active": true,
"enabled": true,
"status": "active",
"ssl_status": "issued",
"ssl_validity_not_after": "2027-01-01T10:00:00Z",
"created": "2026-09-01T10:00:00Z",
"updated": "2026-09-01T10:05:00Z",
"ssl_provisioning": {
"acme_delegation": {
"cname_name": "_acme-challenge.shop.example.com",
"cname_target": "0a1b2c3d4e5f6789.le-challenges.example.net"
},
"http_validation": {
"cname_name": "shop.example.com",
"cname_target": "cl-1a2b3c.cdn.example.net"
}
}
}Aliases
Get alias details
GET
/
cdn
/
aliases
/
{alias_id}
Python
import os
from gcore import Gcore
client = Gcore(
api_key=os.environ.get("GCORE_API_KEY"), # This is the default and can be omitted
)
alias_detail = client.cdn.aliases.get(
0,
)
print(alias_detail)package main
import (
"context"
"fmt"
"github.com/G-Core/gcore-go"
"github.com/G-Core/gcore-go/option"
)
func main() {
client := gcore.NewClient(
option.WithAPIKey("My API Key"),
)
aliasDetail, err := client.CDN.Aliases.Get(context.TODO(), 0)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", aliasDetail)
}
curl --request GET \
--url https://api.gcore.com/cdn/aliases/{alias_id} \
--header 'Authorization: <api-key>'const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.gcore.com/cdn/aliases/{alias_id}', 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}",
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;
}HttpResponse<String> response = Unirest.get("https://api.gcore.com/cdn/aliases/{alias_id}")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gcore.com/cdn/aliases/{alias_id}")
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": 123,
"cname": "shop.example.com",
"resource_id": 4567,
"automated": true,
"challenge_type": "http_01",
"ssl_id": 890,
"active": true,
"enabled": true,
"status": "active",
"ssl_status": "issued",
"ssl_validity_not_after": "2027-01-01T10:00:00Z",
"created": "2026-09-01T10:00:00Z",
"updated": "2026-09-01T10:05:00Z",
"ssl_provisioning": {
"acme_delegation": {
"cname_name": "_acme-challenge.shop.example.com",
"cname_target": "0a1b2c3d4e5f6789.le-challenges.example.net"
},
"http_validation": {
"cname_name": "shop.example.com",
"cname_target": "cl-1a2b3c.cdn.example.net"
}
}
}This endpoint is in beta. BETA
Authorizations
Response
Successful.
Alias status.
Possible values:
inactive– The alias or its CDN resource is disabled; the alias is not served.pending– The alias configuration has not reached the CDN yet.http_only– The alias is served over HTTP only.active– The alias is served over HTTP and HTTPS.
Available options:
inactive, pending, http_only, active Example:
"active"
Outcome of the certificate we manage for the alias.
Possible values:
pending– A certificate attempt is in progress, or was stopped by pausing the alias and starts again after it is resumed.issued– The latest attempt succeeded.failed– The latest attempt ended without a certificate.null– No certificate is managed for the alias: the alias uses a certificate you provided, or is automated and has never opened an attempt.
Available options:
pending, issued, failed Example:
"issued"
Was this page helpful?