Cosmos DB Backup Policies

The /policies/cosmosdb resource collection represents Cosmos DB backup policies configured in Veeam Backup for Microsoft Azure.

Get Collection of Cosmos DB Backup Policies

The HTTP GET request to the /policies/cosmosDb endpoint retrieves a list of Cosmos DB backup policies configured in Veeam Backup for Microsoft Azure.

SecurityBearer
Request
query Parameters
PolicyName
string or null

Returns a backup policy with the specified name.

x-veeam-parameter-group: CosmosDbPolicyQueryOptions
AccountId
string or null

Returns only backup policies that protect a Cosmos DB account with the specified ID.

x-veeam-parameter-group: CosmosDbPolicyQueryOptions
LastJobStatus
Array of strings or null (JobStatus)

Returns only backup policies with the specified status of the latest session.

Enum: "Canceled" "Canceling" "Error" "NeverExecuted" "Running" "RunningWithError" "RunningWithWarning" "Success" "Warning" "Pending" "Unknown"
x-veeam-parameter-group: CosmosDbPolicyQueryOptions
x-veeam-model-binder: Veeam.Azure.REST.RequestQuery.V2.CsvModelBinder<Veeam.Azure.REST.Latest.JobStatus>
PolicyStatus
Array of strings or null (PolicyStatus)

Returns only backup policies with the specified status.

Enum: "Enabled" "Disabled" "Unknown"
x-veeam-parameter-group: CosmosDbPolicyQueryOptions
x-veeam-model-binder: Veeam.Azure.REST.RequestQuery.V2.CsvModelBinder<Veeam.Azure.REST.Latest.PolicyStatus>
RepositoryId
string or null

/[Applies only to backup policies that have the Backup to repository option enabled] Returns only backup policies that store backup files in a repository with the specified ID.

x-veeam-parameter-group: CosmosDbPolicyQueryOptions
Offset
integer <int32> >= 0

Specifies the first N items of a resource collection that will be excluded from the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Limit
integer <int32> >= -1

Specifies the maximum number of items of a resource collection that will be returned in the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Responses
200

OK

400

Bad Request

401

Unauthorized

403

Forbidden

get/api/v8/policies/cosmosDb
Request samples
curl -i -X GET \
  'https://123.123.123.123/api/v8/policies/cosmosDb?PolicyName=string&AccountId=string&LastJobStatus=Canceled&PolicyStatus=Enabled&RepositoryId=string&Offset=0&Limit=-1' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/json
{
  • "offset": 0,
  • "limit": 0,
  • "totalCount": 0,
  • "_links": {},
  • "results": [
    ]
}

Create Backup Policy

The HTTP POST request to the /policies/cosmosDb endpoint creates a new Cosmos DB backup policy.

SecurityBearer
Request
Request Body schema: application/json
required
backupType
required
string or null (BackupTypeNullable)

Defines whether you want to include to the backup scope all resources residing in the specified Azure regions and to which the specified service account has access.

Enum: "AllSubscriptions" "SelectedItems" "Unknown"
x-external-type: Veeam.Azure.REST.Latest.BackupType
isEnabled
required
boolean or null

Defines whether to enable the policy.

name
required
string [ 1 .. 255 ] characters

Specifies a name for the backup policy.

required
Array of objects (PolicyRegionFromClient) non-empty

Azure regions where the resources that will be backed up reside.

tenantId
required
string

Specifies a Microsoft Azure ID assigned to a tenant with which the service account used to protect Azure resources is associated.

serviceAccountId
required
string <uuid>

Specifies the system ID assigned in the Veeam Backup for Microsoft Azure REST API to a service account whose permissions will be used to perform Cosmos DB backup.

object or null (CosmosDbPolicyBackupItemsFromClient)

Specifies information on Azure resources to protect by the backup policy.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
object or null (CosmosDbPolicyExcludedItemsFromClient)

Specifies Azure resources to exclude from the backup scope.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
continuousBackupType
string or null (PolicyCosmosDbBackupTier)

Specifies the retention period for Cosmos DB continuous backup.

Enum: "Continuous7Days" "Continuous30Days"
x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
description
string or null

Specifies a description for the backup policy.

object or null (RetrySettings)

Specifies the retry settings for the backup policy.

object or null (PolicyNotificationSettings)

Specifies the notification settings for the backup policy.

backupWorkloads
Array of strings or null (PolicyCosmosDbBackupWorkload)

Specifies kinds of the Cosmos DB accounts protected using the Backup to repository option.

Enum: "PostgreSQL" "MongoDB"
object or null (DailyCosmosDbSchedule)

/[Applies only to backup policies that have the Backup to repository option enabled] Specifies daily schedule settings for the backup policy.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
object or null (WeeklyCosmosDbSchedule)

/[Applies only to backup policies that have the Backup to repository option enabled] Specifies weekly schedule settings for the backup policy.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
object or null (MonthlyCosmosDbSchedule)

/[Applies only to backup policies that have the Backup to repository option enabled] Specifies monthly schedule settings for the backup policy.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
object or null (YearlySchedule)

Specifies the yearly schedule settings for the backup policy.

object or null (HealthCheckSchedule)

[Applies if backup creation is enabled for the backup policy] Specifies the health check schedule settings.

defaultBackupAccountId
string or null <int64>

/[Applies only to backup policies that have the Backup to repository option enabled] Specifies the system ID assigned in the Veeam Backup for Microsoft Azure REST API to a default database account that will be used to access all protected databases.

object or null (CosmosDbProcessingCredentials)

Specifies a list of credentials that will be used to connect to the databases of the specified Cosmos DB accounts.

Responses
201

Created

400

Bad Request

401

Unauthorized

403

Forbidden

415

Client Error

post/api/v8/policies/cosmosDb
Request samples
application/json
{
  • "tenantId": "string",
  • "serviceAccountId": "a814cf67-aaac-43ae-acb4-8d34e82a4b4c",
  • "regions": [
    ],
  • "selectedItems": {
    },
  • "excludedItems": {
    },
  • "continuousBackupType": "Continuous7Days",
  • "name": "string",
  • "description": "string",
  • "retrySettings": {
    },
  • "policyNotificationSettings": {
    },
  • "isEnabled": true,
  • "backupWorkloads": [
    ],
  • "backupType": "AllSubscriptions",
  • "dailySchedule": {
    },
  • "weeklySchedule": {
    },
  • "monthlySchedule": {
    },
  • "yearlySchedule": {
    },
  • "healthCheckSchedule": {
    },
  • "defaultBackupAccountId": "string",
  • "credentialsList": {
    }
}
Response samples
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "priority": 0,
  • "excludedItemsCount": 0,
  • "tenantId": "string",
  • "serviceAccountId": "a814cf67-aaac-43ae-acb4-8d34e82a4b4c",
  • "backupWorkloads": [
    ],
  • "backupStatus": "Canceled",
  • "archiveStatus": "Canceled",
  • "healthCheckStatus": "Canceled",
  • "configurationStatus": "Canceled",
  • "continuousBackupType": "Continuous7Days",
  • "nextExecutionTime": "2019-08-24T14:15:22Z",
  • "isArchiveBackupConfigured": true,
  • "_links": {},
  • "name": "string",
  • "description": "string",
  • "retrySettings": {
    },
  • "policyNotificationSettings": {
    },
  • "isEnabled": true,
  • "backupType": "AllSubscriptions",
  • "dailySchedule": {
    },
  • "weeklySchedule": {
    },
  • "monthlySchedule": {
    },
  • "yearlySchedule": {
    },
  • "healthCheckSchedule": {
    },
  • "defaultBackupAccountId": "string",
  • "credentialsList": {
    }
}

Get Backup Policy Data

The HTTP GET request to the /policies/cosmosDb/{policyId} endpoint retrieves information on a Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

Responses
200

OK

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

get/api/v8/policies/cosmosDb/{policyId}
Request samples
curl -i -X GET \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "priority": 0,
  • "excludedItemsCount": 0,
  • "tenantId": "string",
  • "serviceAccountId": "a814cf67-aaac-43ae-acb4-8d34e82a4b4c",
  • "backupWorkloads": [
    ],
  • "backupStatus": "Canceled",
  • "archiveStatus": "Canceled",
  • "healthCheckStatus": "Canceled",
  • "configurationStatus": "Canceled",
  • "continuousBackupType": "Continuous7Days",
  • "nextExecutionTime": "2019-08-24T14:15:22Z",
  • "isArchiveBackupConfigured": true,
  • "_links": {},
  • "name": "string",
  • "description": "string",
  • "retrySettings": {
    },
  • "policyNotificationSettings": {
    },
  • "isEnabled": true,
  • "backupType": "AllSubscriptions",
  • "dailySchedule": {
    },
  • "weeklySchedule": {
    },
  • "monthlySchedule": {
    },
  • "yearlySchedule": {
    },
  • "healthCheckSchedule": {
    },
  • "defaultBackupAccountId": "string",
  • "credentialsList": {
    }
}

Modify Backup Policy

The HTTP PUT request to the /policies/cosmosDb/{policyId} endpoint updates settings of a Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

Request Body schema: application/json
required
backupType
required
string or null (BackupTypeNullable)

Defines whether you want to include to the backup scope all resources residing in the specified Azure regions and to which the specified service account has access.

Enum: "AllSubscriptions" "SelectedItems" "Unknown"
x-external-type: Veeam.Azure.REST.Latest.BackupType
isEnabled
required
boolean or null

Defines whether to enable the policy.

name
required
string [ 1 .. 255 ] characters

Specifies a name for the backup policy.

required
Array of objects (PolicyRegionFromClient) non-empty

Specifies Azure regions where the backed up resources will reside.

tenantId
string or null

Specifies a Microsoft Azure ID assigned to a tenant to which the protected Azure resources belong.

serviceAccountId
string or null <uuid>

Specifies the system ID assigned in the Veeam Backup for Microsoft Azure REST API to the service account whose permissions will be used to create backups of Cosmos DB accounts.

object or null (CosmosDbPolicyBackupItemsFromClient)

Specifies information on Azure resources to protect by the backup policy.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
object or null (CosmosDbPolicyExcludedItemsFromClient)

Specifies Azure resources to exclude from the backup scope.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
continuousBackupType
string or null (PolicyCosmosDbBackupTier)

Specifies the retention period for Cosmos DB continuous backup.

Enum: "Continuous7Days" "Continuous30Days"
x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
description
string or null

Specifies a description for the backup policy.

object or null (RetrySettings)

Specifies the retry settings for the backup policy.

object or null (PolicyNotificationSettings)

Specifies the notification settings for the backup policy.

backupWorkloads
Array of strings or null (PolicyCosmosDbBackupWorkload)

Specifies kinds of the Cosmos DB accounts protected using the Backup to repository option.

Enum: "PostgreSQL" "MongoDB"
object or null (DailyCosmosDbSchedule)

/[Applies only to backup policies that have the Backup to repository option enabled] Specifies daily schedule settings for the backup policy.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
object or null (WeeklyCosmosDbSchedule)

/[Applies only to backup policies that have the Backup to repository option enabled] Specifies weekly schedule settings for the backup policy.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
object or null (MonthlyCosmosDbSchedule)

/[Applies only to backup policies that have the Backup to repository option enabled] Specifies monthly schedule settings for the backup policy.

x-veeam-namespace: Veeam.Azure.REST.Latest.Representation.PolicyCosmosDb
object or null (YearlySchedule)

Specifies the yearly schedule settings for the backup policy.

object or null (HealthCheckSchedule)

[Applies if backup creation is enabled for the backup policy] Specifies the health check schedule settings.

defaultBackupAccountId
string or null <int64>

/[Applies only to backup policies that have the Backup to repository option enabled] Specifies the system ID assigned in the Veeam Backup for Microsoft Azure REST API to a default database account that will be used to access all protected databases.

object or null (CosmosDbProcessingCredentials)

Specifies a list of credentials that will be used to connect to the databases of the specified Cosmos DB accounts.

Responses
200

OK

204

No Content

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

415

Client Error

put/api/v8/policies/cosmosDb/{policyId}
Request samples
application/json
{
  • "tenantId": "string",
  • "serviceAccountId": "a814cf67-aaac-43ae-acb4-8d34e82a4b4c",
  • "regions": [
    ],
  • "selectedItems": {
    },
  • "excludedItems": {
    },
  • "continuousBackupType": "Continuous7Days",
  • "name": "string",
  • "description": "string",
  • "retrySettings": {
    },
  • "policyNotificationSettings": {
    },
  • "isEnabled": true,
  • "backupWorkloads": [
    ],
  • "backupType": "AllSubscriptions",
  • "dailySchedule": {
    },
  • "weeklySchedule": {
    },
  • "monthlySchedule": {
    },
  • "yearlySchedule": {
    },
  • "healthCheckSchedule": {
    },
  • "defaultBackupAccountId": "string",
  • "credentialsList": {
    }
}
Response samples
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "priority": 0,
  • "excludedItemsCount": 0,
  • "tenantId": "string",
  • "serviceAccountId": "a814cf67-aaac-43ae-acb4-8d34e82a4b4c",
  • "backupWorkloads": [
    ],
  • "backupStatus": "Canceled",
  • "archiveStatus": "Canceled",
  • "healthCheckStatus": "Canceled",
  • "configurationStatus": "Canceled",
  • "continuousBackupType": "Continuous7Days",
  • "nextExecutionTime": "2019-08-24T14:15:22Z",
  • "isArchiveBackupConfigured": true,
  • "_links": {},
  • "name": "string",
  • "description": "string",
  • "retrySettings": {
    },
  • "policyNotificationSettings": {
    },
  • "isEnabled": true,
  • "backupType": "AllSubscriptions",
  • "dailySchedule": {
    },
  • "weeklySchedule": {
    },
  • "monthlySchedule": {
    },
  • "yearlySchedule": {
    },
  • "healthCheckSchedule": {
    },
  • "defaultBackupAccountId": "string",
  • "credentialsList": {
    }
}

Remove Backup Policy

The HTTP DELETE request to the /policies/cosmosDb/{policyId} endpoint deletes a specific Cosmos DB backup policy from the Veeam Backup for Microsoft Azure configuration database.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

Responses
204

No Content

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

409

Conflict

delete/api/v8/policies/cosmosDb/{policyId}
Request samples
curl -i -X DELETE \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/problem+json
{
  • "detail": "string",
  • "errors": {
    },
  • "status": 0,
  • "title": "string",
  • "traceId": "string",
  • "type": "string"
}

Get Resources Selected for Backup Policy

The HTTP GET request to the /policies/cosmosDb/{policyId}/selectedItems endpoint retrieves information on resources protected by a Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

query Parameters
Offset
integer <int32> >= 0

Specifies the first N items of a resource collection that will be excluded from the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Limit
integer <int32> >= -1

Specifies the maximum number of items of a resource collection that will be returned in the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Responses
200

OK

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

get/api/v8/policies/cosmosDb/{policyId}/selectedItems
Request samples
curl -i -X GET \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}/selectedItems?Offset=0&Limit=-1' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/json
{
  • "offset": 0,
  • "limit": 0,
  • "totalCount": 0,
  • "_links": {},
  • "results": [
    ]
}

Get Azure Regions Specified in Policy Settings

The HTTP GET request to the /policies/cosmosDb/{policyId}/regions retrieves a list of Azure regions protected by a Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

query Parameters
Offset
integer <int32> >= 0

Specifies the first N items of a resource collection that will be excluded from the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Limit
integer <int32> >= -1

Specifies the maximum number of items of a resource collection that will be returned in the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Responses
200

OK

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

get/api/v8/policies/cosmosDb/{policyId}/regions
Request samples
curl -i -X GET \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}/regions?Offset=0&Limit=-1' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/json
{
  • "offset": 0,
  • "limit": 0,
  • "totalCount": 0,
  • "_links": {},
  • "results": [
    ]
}

Get Resources Excluded from Backup Policy

The HTTP GET request to the /policies/cosmosDb/{policyId}/excludedItems endpoint retrieves a list of Cosmos DB accounts excluded from a Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

query Parameters
Offset
integer <int32> >= 0

Specifies the first N items of a resource collection that will be excluded from the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Limit
integer <int32> >= -1

Specifies the maximum number of items of a resource collection that will be returned in the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
NameSearchPattern
string or null

Returns only those items of a resource collection whose names match the specified search pattern in the parameter value.

x-veeam-parameter-group: PolicyExcludedItemOptions
Responses
200

OK

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

get/api/v8/policies/cosmosDb/{policyId}/excludedItems
Request samples
curl -i -X GET \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}/excludedItems?Offset=0&Limit=-1&NameSearchPattern=string' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/json
{
  • "offset": 0,
  • "limit": 0,
  • "totalCount": 0,
  • "_links": {},
  • "results": [
    ]
}

Set Backup Policy Priority

The HTTP POST request to the /policies/cosmosDb/orderPriorities endpoint sets the priority order for Cosmos DB backup policies.

SecurityBearer
Request
Request Body schema: application/json
Array
string <uuid>

Specifies system IDs assigned in the Veeam Backup for Microsoft Azure REST API to backup policies in the specified order.

Responses
204

No Content

400

Bad Request

401

Unauthorized

403

Forbidden

415

Client Error

post/api/v8/policies/cosmosDb/orderPriorities
Request samples
application/json
[
  • "497f6eca-6276-4993-bfeb-53cbbbba6f08"
]
Response samples
application/problem+json
{
  • "extensions": { },
  • "status": 0,
  • "title": "string",
  • "detail": "string",
  • "type": "string"
}

Enable Backup Policy

The HTTP POST request to the /policies/cosmosDb/{policyId}/enable endpoint enables a disabled Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

Responses
204

No Content

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

post/api/v8/policies/cosmosDb/{policyId}/enable
Request samples
curl -i -X POST \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}/enable' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/problem+json
{
  • "detail": "string",
  • "errors": {
    },
  • "status": 0,
  • "title": "string",
  • "traceId": "string",
  • "type": "string"
}

Disable Backup Policy

The HTTP POST request to the /policies/cosmosDb/{policyId}/disable endpoint disables an enabled Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

Responses
204

No Content

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

post/api/v8/policies/cosmosDb/{policyId}/disable
Request samples
curl -i -X POST \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}/disable' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/problem+json
{
  • "detail": "string",
  • "errors": {
    },
  • "status": 0,
  • "title": "string",
  • "traceId": "string",
  • "type": "string"
}

Start Backup Policy

The HTTP POST request to the /policies/cosmosDb/{policyId}/start endpoint launches a Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

Responses
202

Accepted

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

409

Conflict

post/api/v8/policies/cosmosDb/{policyId}/start
Request samples
curl -i -X POST \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}/start' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/json
[
  • {
    }
]

Stop Backup Policy

The HTTP POST request to the /policies/cosmosDb/{policyId}/stop endpoint stops execution of a Cosmos DB backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

Responses
204

No Content

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

post/api/v8/policies/cosmosDb/{policyId}/stop
Request samples
curl -i -X POST \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}/stop' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/problem+json
{
  • "detail": "string",
  • "errors": {
    },
  • "status": 0,
  • "title": "string",
  • "traceId": "string",
  • "type": "string"
}

Export Backup Policies

The HTTP POST request to the /policies/cosmosDb/export endpoint exports a list of Cosmos DB backup policies created in Veeam Backup for Microsoft Azure to a .CSV or an .XML file.

x-veeam-custom-response: true
SecurityBearer
Request
header Parameters
Accept
string or null

Specifies a media type of representation of the exported data. The default value is text/csv media type.

Request Body schema: application/json
policyIds
Array of strings or null <uuid>

Returns only information on the policies with the specified IDs.

policyName
string or null

Returns a backup policy with the specified name.

lastJobStatus
Array of strings or null (JobStatus)

Returns only backup policies with the specified status of the latest session.

Enum: "Canceled" "Canceling" "Error" "NeverExecuted" "Running" "RunningWithError" "RunningWithWarning" "Success" "Warning" "Pending" "Unknown"
x-veeam-model-binder: Veeam.Azure.REST.RequestQuery.V2.CsvModelBinder<Veeam.Azure.REST.Latest.JobStatus>
policyStatus
Array of strings or null (PolicyStatus)

Returns only backup policies with the specified status.

Enum: "Enabled" "Disabled" "Unknown"
x-veeam-model-binder: Veeam.Azure.REST.RequestQuery.V2.CsvModelBinder<Veeam.Azure.REST.Latest.PolicyStatus>
Responses
200

OK

401

Unauthorized

403

Forbidden

post/api/v8/policies/cosmosDb/export
Request samples
application/json
{
  • "policyIds": [
    ],
  • "policyName": "string",
  • "lastJobStatus": [
    ],
  • "policyStatus": [
    ]
}
Response samples
application/problem+json
{
  • "extensions": { },
  • "status": 0,
  • "title": "string",
  • "type": "string",
  • "licenseAgreementAcceptanceRequired": true
}

Get Collection of Protected Items

The HTTP GET request to the /policies/cosmosDb/protectedItems endpoint retrieves a list of Cosmos DB accounts that are protected by backup policies configured in Veeam Backup for Microsoft Azure.

SecurityBearer
Request
query Parameters
Offset
integer <int32> >= 0

Specifies the first N items of a resource collection that will be excluded from the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Limit
integer <int32> >= -1

Specifies the maximum number of items of a resource collection that will be returned in the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Responses
200

OK

401

Unauthorized

403

Forbidden

get/api/v8/policies/cosmosDb/protectedItems
Request samples
curl -i -X GET \
  'https://123.123.123.123/api/v8/policies/cosmosDb/protectedItems?Offset=0&Limit=-1' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/json
{
  • "offset": 0,
  • "limit": 0,
  • "totalCount": 0,
  • "_links": {},
  • "results": [
    ]
}

Get Resources Protected by Backup Policy

The HTTP GET request to the /policies/cosmosDb/{policyId}/protectedItems endpoint retrieves a list of Cosmos DB accounts protected by a backup policy with the specified ID.

SecurityBearer
Request
path Parameters
policyId
required
string <uuid>

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

query Parameters
Offset
integer <int32> >= 0

Specifies the first N items of a resource collection that will be excluded from the response.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Limit
integer <int32> >= -1

Specifies the system ID assigned to a backup policy in the Veeam Backup for Microsoft Azure REST API.

x-veeam-parameter-group: Veeam.Azure.REST.RequestQuery.V2.PageProperties
Responses
200

OK

401

Unauthorized

403

Forbidden

get/api/v8/policies/cosmosDb/{policyId}/protectedItems
Request samples
curl -i -X GET \
  'https://123.123.123.123/api/v8/policies/cosmosDb/{policyId}/protectedItems?Offset=0&Limit=-1' \
  -H 'Authorization: YOUR_API_KEY_HERE'
Response samples
application/json
{
  • "offset": 0,
  • "limit": 0,
  • "totalCount": 0,
  • "_links": {},
  • "results": [
    ]
}