Get Bucket SSL Certificate
Returns the stored certificate detail of a bucket, if applicable.
GET
/
storage
/
buckets
/
{bucketName}
/
ssl_certificate
JavaScript
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
const sslCertificate = await client.storage.buckets.sslCertificate.retrieve('');
console.log(sslCertificate.data);import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
ssl_certificate = client.storage.buckets.ssl_certificate.retrieve(
"",
)
print(ssl_certificate.data)package main
import (
"context"
"fmt"
"github.com/team-telnyx/telnyx-go"
"github.com/team-telnyx/telnyx-go/option"
)
func main() {
client := telnyx.NewClient(
option.WithAPIKey("My API Key"),
)
sslCertificate, err := client.Storage.Buckets.SslCertificate.Get(context.TODO(), "")
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", sslCertificate.Data)
}package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
import com.telnyx.sdk.models.storage.buckets.sslcertificate.SslCertificateRetrieveParams;
import com.telnyx.sdk.models.storage.buckets.sslcertificate.SslCertificateRetrieveResponse;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
SslCertificateRetrieveResponse sslCertificate = client.storage().buckets().sslCertificate().retrieve("");
}
}require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
ssl_certificate = telnyx.storage.buckets.ssl_certificate.retrieve("")
puts(ssl_certificate)<?php
require_once dirname(__DIR__) . '/vendor/autoload.php';
use Telnyx\Client;
use Telnyx\Core\Exceptions\APIException;
$client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API Key');
try {
$sslCertificate = $client->storage->buckets->sslCertificate->retrieve('');
var_dump($sslCertificate);
} catch (APIException $e) {
echo $e->getMessage();
}telnyx storage:buckets:ssl-certificate retrieve \
--api-key 'My API Key' \
--bucket-name ''curl --request GET \
--url https://api.telnyx.com/v2/storage/buckets/{bucketName}/ssl_certificate \
--header 'Authorization: Bearer <token>'{
"data": {
"id": "<string>",
"issued_to": {
"common_name": "<string>",
"organization": "<string>",
"organization_unit": "<string>"
},
"issued_by": {
"common_name": "<string>",
"organization": "<string>",
"organization_unit": "<string>"
},
"valid_from": "2020-01-01T00:00:00Z",
"valid_to": "2020-01-01T00:00:00Z",
"created_at": "2020-01-01T00:00:00Z"
}
}Was this page helpful?
⌘I
JavaScript
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
const sslCertificate = await client.storage.buckets.sslCertificate.retrieve('');
console.log(sslCertificate.data);import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
ssl_certificate = client.storage.buckets.ssl_certificate.retrieve(
"",
)
print(ssl_certificate.data)package main
import (
"context"
"fmt"
"github.com/team-telnyx/telnyx-go"
"github.com/team-telnyx/telnyx-go/option"
)
func main() {
client := telnyx.NewClient(
option.WithAPIKey("My API Key"),
)
sslCertificate, err := client.Storage.Buckets.SslCertificate.Get(context.TODO(), "")
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", sslCertificate.Data)
}package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
import com.telnyx.sdk.models.storage.buckets.sslcertificate.SslCertificateRetrieveParams;
import com.telnyx.sdk.models.storage.buckets.sslcertificate.SslCertificateRetrieveResponse;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
SslCertificateRetrieveResponse sslCertificate = client.storage().buckets().sslCertificate().retrieve("");
}
}require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
ssl_certificate = telnyx.storage.buckets.ssl_certificate.retrieve("")
puts(ssl_certificate)<?php
require_once dirname(__DIR__) . '/vendor/autoload.php';
use Telnyx\Client;
use Telnyx\Core\Exceptions\APIException;
$client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API Key');
try {
$sslCertificate = $client->storage->buckets->sslCertificate->retrieve('');
var_dump($sslCertificate);
} catch (APIException $e) {
echo $e->getMessage();
}telnyx storage:buckets:ssl-certificate retrieve \
--api-key 'My API Key' \
--bucket-name ''curl --request GET \
--url https://api.telnyx.com/v2/storage/buckets/{bucketName}/ssl_certificate \
--header 'Authorization: Bearer <token>'{
"data": {
"id": "<string>",
"issued_to": {
"common_name": "<string>",
"organization": "<string>",
"organization_unit": "<string>"
},
"issued_by": {
"common_name": "<string>",
"organization": "<string>",
"organization_unit": "<string>"
},
"valid_from": "2020-01-01T00:00:00Z",
"valid_to": "2020-01-01T00:00:00Z",
"created_at": "2020-01-01T00:00:00Z"
}
}