Restorable Sql Resources - List
Returnera en lista över databas- och containerkombinationer som finns på kontot vid den angivna tidsstämpeln och platsen. Detta hjälper i scenarier att verifiera vilka resurser som finns vid angiven tidsstämpel och plats. Det här API:et kräver behörigheten Microsoft.DocumentDB/locations/restorableDatabaseAccounts/.../read.
GET https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{instanceId}/restorableSqlResources?api-version=2025-04-15
GET https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{instanceId}/restorableSqlResources?api-version=2025-04-15&restoreLocation={restoreLocation}&restoreTimestampInUtc={restoreTimestampInUtc}
URI-parametrar
Name | I | Obligatorisk | Typ | Description |
---|---|---|---|---|
instance
|
path | True |
string |
InstanceId-GUID för ett återställningsbart databaskonto. |
location
|
path | True |
string |
Cosmos DB-region med blanksteg mellan ord och varje ord med versaler. |
subscription
|
path | True |
string minLength: 1 |
ID för målprenumerationen. |
api-version
|
query | True |
string minLength: 1 |
Den API-version som ska användas för den här åtgärden. |
restore
|
query |
string |
Platsen där de återställningsbara resurserna finns. |
|
restore
|
query |
string |
Tidsstämpeln när de återställningsbara resurserna fanns. |
Svar
Name | Typ | Description |
---|---|---|
200 OK |
Åtgärden har slutförts. |
|
Other Status Codes |
Felsvar som beskriver varför åtgärden misslyckades. |
Säkerhet
azure_auth
Azure Active Directory OAuth2 Flow
Typ:
oauth2
Flow:
implicit
Auktoriseringswebbadress:
https://login.microsoftonline.com/common/oauth2/authorize
Omfattningar
Name | Description |
---|---|
user_impersonation | Personifiera ditt användarkonto |
Exempel
CosmosDBRestorableSqlResourceList
Exempelbegäran
GET https://management.azure.com/subscriptions/2296c272-5d55-40d9-bc05-4d56dc2d7588/providers/Microsoft.DocumentDB/locations/WestUS/restorableDatabaseAccounts/d9b26648-2f53-4541-b3d8-3044f4f9810d/restorableSqlResources?api-version=2025-04-15&restoreLocation=WestUS&restoreTimestampInUtc=06/01/2022 4:56
Exempelsvar
{
"value": [
{
"id": "/subscriptions/2296c272-5d55-40d9-bc05-4d56dc2d7588/providers/Microsoft.DocumentDB/locations/westus/restorableDatabaseAccounts/d9b26648-2f53-4541-b3d8-3044f4f9810d/restorablesqlresources/Database1",
"type": "Microsoft.DocumentDB/locations/restorableDatabaseAccounts/restorablesqlresources",
"name": "Database1",
"databaseName": "Database1",
"collectionNames": [
"Container1"
]
},
{
"id": "/subscriptions/2296c272-5d55-40d9-bc05-4d56dc2d7588/providers/Microsoft.DocumentDB/locations/westus/restorableDatabaseAccounts/d9b26648-2f53-4541-b3d8-3044f4f9810d/restorablesqlresources/Database2",
"type": "Microsoft.DocumentDB/locations/restorableDatabaseAccounts/restorablesqlresources",
"name": "Database2",
"databaseName": "Database2",
"collectionNames": [
"Container1",
"Container2"
]
},
{
"id": "/subscriptions/2296c272-5d55-40d9-bc05-4d56dc2d7588/providers/Microsoft.DocumentDB/locations/westus/restorableDatabaseAccounts/d9b26648-2f53-4541-b3d8-3044f4f9810d/restorablesqlresources/Database3",
"type": "Microsoft.DocumentDB/locations/restorableDatabaseAccounts/restorablesqlresources",
"name": "Database3",
"databaseName": "Database3",
"collectionNames": []
}
]
}
Definitioner
Name | Description |
---|---|
Cloud |
Ett felsvar från tjänsten. |
Error |
Felsvar. |
Restorable |
Specifika databaser som ska återställas. |
Restorable |
Svar på liståtgärd som innehåller de återställningsbara SQL-resurserna. |
CloudError
Ett felsvar från tjänsten.
Name | Typ | Description |
---|---|---|
error |
Felsvar. |
ErrorResponse
Felsvar.
Name | Typ | Description |
---|---|---|
code |
string |
Felkod. |
message |
string |
Felmeddelande som anger varför åtgärden misslyckades. |
RestorableSqlResourcesGetResult
Specifika databaser som ska återställas.
Name | Typ | Description |
---|---|---|
collectionNames |
string[] |
The names of the collections available for restore. |
databaseName |
string |
The name of the database available for restore. |
id |
string |
Den unika resursidentifieraren för ARM-resursen. |
name |
string |
Namnet på ARM-resursen. |
type |
string |
Typen av Azure-resurs. |
RestorableSqlResourcesListResult
Svar på liståtgärd som innehåller de återställningsbara SQL-resurserna.
Name | Typ | Description |
---|---|---|
value |
Lista över återställningsbara SQL-resurser, inklusive databas- och samlingsnamn. |