Snapshot Policies
All operations require authentication.
List snapshot policiesProduction
Returns the snapshot policies, including the default one. Each item contains only the policy ID and name: get a snapshot policy to read its rules and status.
Path parameters
Service name
Response
Snapshot policy creation date
Snapshot policy description
Snapshot policy ID
Is this the default snapshot policy?
Snapshot policy name
Snapshot policy rules, 1 to 4
Snapshot policy status
availablecreatingdeletingerrorupdatingExample uses serviceName = 00000000-0000-0000-0000-000000000000
$ curl https:/ / api.eu.ovhcloud.com/ 1.0/ storage/ netapp/ {serviceName}/ snapshotPolicy \
-H "authorization: Bearer $OVH_TOKEN"[ { "createdAt": "2024-01-01T12:00:00Z", "description": "string", "id": "00000000-0000-0000-0000-000000000000", "isDefault": true, "name": "string", "rules": [ { "copies": 0, "prefix": "string", "schedule": { "days": [ 0 ], "hours": [ 0 ], "minutes": [ 0 ], "months": [ 0 ], "weekdays": [ 0 ] } } ], "status": "available" }]
Get a snapshot policyProduction
Returns the snapshot policy with its rules and status. A policy can be updated, deleted or assigned to a share only when its status is available.
Path parameters
Service name
Snapshot policy ID
Response
Snapshot policy creation date
Snapshot policy description
Snapshot policy ID
Is this the default snapshot policy?
Snapshot policy name
Snapshot policy rules, 1 to 4
Snapshot policy status
availablecreatingdeletingerrorupdatingExample uses serviceName = 00000000-0000-0000-0000-000000000000, snapshotPolicyId = 00000000-0000-0000-0000-000000000000
$ curl https:/ / api.eu.ovhcloud.com/ 1.0/ storage/ netapp/ {serviceName}/ snapshotPolicy/ {snapshotPolicyId} \
-H "authorization: Bearer $OVH_TOKEN"{ "createdAt": "2024-01-01T12:00:00Z", "description": "string", "id": "00000000-0000-0000-0000-000000000000", "isDefault": true, "name": "string", "rules": [ { "copies": 0, "prefix": "string", "schedule": { "days": [ 0 ], "hours": [ 0 ], "minutes": [ 0 ], "months": [ 0 ], "weekdays": [ 0 ] } } ], "status": "available"}
Create a snapshot policyProduction
Creates a policy made of rules, each with a schedule, a snapshot name prefix and a number of copies to keep. Creation is asynchronous: follow the snapshot policy status until it is available. The policy takes effect only once it is assigned to a share.
Path parameters
Service name
Request body (required)
Snapshot policy creation date
Snapshot policy description
Snapshot policy ID
Is this the default snapshot policy?
Snapshot policy name
Snapshot policy rules, 1 to 4
Snapshot policy status
availablecreatingdeletingerrorupdatingResponse
Snapshot policy creation date
Snapshot policy description
Snapshot policy ID
Is this the default snapshot policy?
Snapshot policy name
Snapshot policy rules, 1 to 4
Snapshot policy status
availablecreatingdeletingerrorupdatingExample uses serviceName = 00000000-0000-0000-0000-000000000000
$ curl https:/ / api.eu.ovhcloud.com/ 1.0/ storage/ netapp/ {serviceName}/ snapshotPolicy \
-H "authorization: Bearer $OVH_TOKEN"{ "createdAt": "2024-01-01T12:00:00Z", "description": "string", "id": "00000000-0000-0000-0000-000000000000", "isDefault": true, "name": "string", "rules": [ { "copies": 0, "prefix": "string", "schedule": { "days": [ 0 ], "hours": [ 0 ], "minutes": [ 0 ], "months": [ 0 ], "weekdays": [ 0 ] } } ], "status": "available"}
Delete a snapshot policyProduction
Deletes the snapshot policy and its schedules. A policy applied to a share cannot be deleted: apply another non-default policy to the share first. The default policy cannot be deleted, and deletion is asynchronous: follow the snapshot policy status until the policy is no longer found.
Path parameters
Service name
Snapshot policy ID
Response
Example uses serviceName = 00000000-0000-0000-0000-000000000000, snapshotPolicyId = 00000000-0000-0000-0000-000000000000
$ curl https:/ / api.eu.ovhcloud.com/ 1.0/ storage/ netapp/ {serviceName}/ snapshotPolicy/ {snapshotPolicyId} \
-H "authorization: Bearer $OVH_TOKEN"Update a snapshot policyProduction
Updates the policy name and description. Rules cannot be changed: create a new policy instead. The policy must be available, and the default policy cannot be updated.
Path parameters
Service name
Snapshot policy ID
Request body (required)
New snapshot policy description
New snapshot policy name
Response
Example uses serviceName = 00000000-0000-0000-0000-000000000000, snapshotPolicyId = 00000000-0000-0000-0000-000000000000
$ curl https:/ / api.eu.ovhcloud.com/ 1.0/ storage/ netapp/ {serviceName}/ snapshotPolicy/ {snapshotPolicyId} \
-H "authorization: Bearer $OVH_TOKEN"