Retrieve Policy
Retrieve the Backup Policy for an Existing Droplet
gpu_droplets.backups.retrieve_policy(intdroplet_id) -> policyPolicyBackupRetrievePolicyResponse
get/v2/droplets/{droplet_id}/backups/policy
To show information about an individual Droplet's backup policy, send a GET
request to /v2/droplets/$DROPLET_ID/backups/policy
.
Parameters
droplet_idint
minimum1
Returns
BackupRetrievePolicyResponseclass
from do_gradientai import GradientAI
client = GradientAI()
response = client.gpu_droplets.backups.retrieve_policy(
1,
)
print(response.policy)
200 Example
{
"policy": {
"backup_enabled": true,
"backup_policy": {
"hour": 0,
"plan": "daily",
"weekday": "SUN"
},
"droplet_id": 7101383,
"next_backup_window": {
"end": "2019-12-04T23:00:00Z",
"start": "2019-12-04T00:00:00Z"
}
}
}