pydo.databases.get_ca()
Generated on 25 November 2024
from pydo
version v0.6.0
Description
To retrieve the public certificate used to secure the connection to the database cluster send a GET request to
/v2/databases/$DATABASE_ID/ca
.
The response will be a JSON object with a ca
key. This will be set to an object
containing the base64 encoding of the public key certificate.
Parameters
Name |
Type |
Required |
Description |
Default Value |
database_cluster_uuid |
string |
True |
A unique identifier for a database cluster. |
|
Request Sample
import os
from pydo import Client
client = Client(token=os.environ.get("DIGITALOCEAN_TOKEN"))
get_resp = client.databases.get_ca(database_cluster_uuid="aba77ada")
Responses
See the API spec for this endpoint to view additional detail on responses, headers, parameters, and more.
A JSON object with a key of ca
.
Click to expand an example response.
{
"ca": {
"certificate": "LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUVRVENDQXFtZ0F3SUJBZ0lVRUZZWTdBWFZQS0Raam9jb1lpMk00Y0dvcU0wd0RRWUpLb1pJaHZjTkFRRU0KQlFBd09qRTRNRFlHQTFVRUF3d3ZOek0zT1RaaE1XRXRaamhrTUMwME9HSmpMV0V4Wm1NdFpqbGhNVFZsWXprdwpORGhsSUZCeWIycGxZM1FnUTBFd0hoY05NakF3TnpFM01UVTFNREEyV2hjTk16QXdOekUxTVRVMU1EQTJXakE2Ck1UZ3dOZ1lEVlFRRERDODNNemM1Tm1FeFlTMW1PR1F3TFRRNFltTXRZVEZtWXkxbU9XRXhOV1ZqT1RBME9HVWcKVUhKdmFtVmpkQ0JEUVRDQ0FhSXdEUVlKS29aSWh2Y05BUUVCQlFBRGdnR1BBRENDQVlvQ2dnR0JBTVdScXhycwpMZnpNdHZyUmxKVEw4MldYMVBLZkhKbitvYjNYcmVBY3FZd1dBUUp2Q3IycmhxSXZieVZzMGlaU0NzOHI4c3RGClljQ0R1bkxJNmUwTy9laERZYTBIT2RrMkFFRzE1ckVOVmNha2NSczcyQWlHVHNrdkNXS2VkUjFTUWswVWt0WCsKQUg4S1ExS3F5bzNtZ2Y2cVV1WUpzc3JNTXFselk3YTN1RVpEb2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lBmaFlLeVIwT0V3eWVvdlhRNzl0LwpTV2ZGTjBreU1Pc1UrNVNIdHJKSEh1eWNWcU0yQlVVK083VjM1UnNwOU9MZGRZMFFVbTZldFpEVEhhSUhYYzRRCnl1Rm1OL1NhSFZtNE0wL3BTVlJQdVd6TmpxMnZyRllvSDRtbGhIZk95TUNJMjc2elE2aWhGNkdDSHlkOUJqajcKUm1UWGEyNHM3NWhmSi9YTDV2bnJSdEtpVHJlVHF6V21EOVhnUmNMQ0gyS1hJaVRtSWc9PQotLS0tLUVORCBDRVJUSUZJQ0FURS0tLS0tCg=="
}
}
Unauthorized
Click to expand an example response.
{
"id": "unauthorized",
"message": "Unable to authenticate you."
}
The resource was not found.
Click to expand an example response.
{
"id": "not_found",
"message": "The resource you requested could not be found."
}
API Rate limit exceeded
Click to expand an example response.
{
"id": "too_many_requests",
"message": "API Rate limit exceeded."
}
Server error.
Click to expand an example response.
{
"id": "server_error",
"message": "Unexpected server-side error"
}
Unexpected error
Click to expand an example response.
{
"id": "example_error",
"message": "some error message"
}