Restorable Mongodb Resources - List
Returnera en lista över databas- och samlingskombinationer 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}/restorableMongodbResources?api-version=2025-04-15
GET https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{instanceId}/restorableMongodbResources?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-flöde
Typ:
oauth2
Flow:
implicit
Auktoriseringswebbadress:
https://login.microsoftonline.com/common/oauth2/authorize
Omfattningar
| Name | Description |
|---|---|
| user_impersonation | Personifiera ditt användarkonto |
Exempel
CosmosDBRestorableMongodbResourceList
Exempelbegäran
GET https://management.azure.com/subscriptions/2296c272-5d55-40d9-bc05-4d56dc2d7588/providers/Microsoft.DocumentDB/locations/WestUS/restorableDatabaseAccounts/d9b26648-2f53-4541-b3d8-3044f4f9810d/restorableMongodbResources?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/restorablemongodbresources/Database1",
"type": "Microsoft.DocumentDB/locations/restorableDatabaseAccounts/restorablemongodbresources",
"name": "Database1",
"databaseName": "Database1",
"collectionNames": [
"Collection1"
]
},
{
"id": "/subscriptions/2296c272-5d55-40d9-bc05-4d56dc2d7588/providers/Microsoft.DocumentDB/locations/westus/restorableDatabaseAccounts/d9b26648-2f53-4541-b3d8-3044f4f9810d/restorablemongodbresources/Database2",
"type": "Microsoft.DocumentDB/locations/restorableDatabaseAccounts/restorablemongodbresources",
"name": "Database2",
"databaseName": "Database2",
"collectionNames": [
"Collection1",
"Collection2"
]
},
{
"id": "/subscriptions/2296c272-5d55-40d9-bc05-4d56dc2d7588/providers/Microsoft.DocumentDB/locations/westus/restorableDatabaseAccounts/d9b26648-2f53-4541-b3d8-3044f4f9810d/restorablemongodbresources/Database3",
"type": "Microsoft.DocumentDB/locations/restorableDatabaseAccounts/restorablemongodbresources",
"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 MongoDB-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. |
RestorableMongodbResourcesGetResult
Specifika databaser som ska återställas.
| Name | Typ | Description |
|---|---|---|
| collectionNames |
string[] |
Namnen på samlingarna som är tillgängliga för återställning. |
| databaseName |
string |
Namnet på databasen som är tillgänglig för återställning. |
| id |
string |
Den unika resursidentifieraren för ARM-resursen. |
| name |
string |
Namnet på ARM-resursen. |
| type |
string |
Typen av Azure-resurs. |
RestorableMongodbResourcesListResult
Svar på liståtgärd som innehåller de återställningsbara MongoDB-resurserna.
| Name | Typ | Description |
|---|---|---|
| value |
Lista över återställningsbara MongoDB-resurser, inklusive databas- och samlingsnamn. |