Web Apps - List Backups
取得應用程式的現有備份的描述。
GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups?api-version=2025-03-01
URI 參數
| 名稱 | 位於 | 必要 | 類型 | Description |
|---|---|---|---|---|
|
name
|
path | True |
string |
應用程式的名稱。 |
|
resource
|
path | True |
string minLength: 1maxLength: 90 pattern: ^[-\w\._\(\)]+[^\.]$ |
資源所屬資源群組的名稱。 |
|
subscription
|
path | True |
string |
您的 Azure 訂用帳戶識別碼。 這是 GUID 格式的字串(例如 0000000000-0000-0000-0000-0000000000000000)。 |
|
api-version
|
query | True |
string |
API 版本 |
回應
| 名稱 | 類型 | Description |
|---|---|---|
| 200 OK |
OK |
|
| Other Status Codes |
App Service 錯誤回應。 |
安全性
azure_auth
Azure Active Directory OAuth2 流
類型:
oauth2
Flow:
implicit
授權 URL:
https://login.microsoftonline.com/common/oauth2/authorize
範圍
| 名稱 | Description |
|---|---|
| user_impersonation | 冒充您的使用者帳戶 |
範例
List web app backups
範例要求
GET https://management.azure.com/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/sites/sitef6141/backups?api-version=2025-03-01
範例回覆
{
"value": [
{
"id": "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Web/sites/sitef6141/backups/12345",
"name": "sitef6141",
"type": "Microsoft.Web/sites",
"properties": {
"id": 12345,
"storageAccountUrl": "DefaultEndpointsProtocol=https;AccountName=storagesample;AccountKey=<account-key>",
"blobName": "sitef6141_2025-03-01",
"name": "sitef6141_2025-03-01",
"status": "InProgress",
"sizeInBytes": 56091883,
"created": "2022-09-03T17:33:11.641Z",
"log": "Succeeded",
"databases": [
{
"databaseType": "SqlAzure",
"name": "backenddb",
"connectionStringName": "backend",
"connectionString": "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;<Attribute>=<value>]"
},
{
"databaseType": "SqlAzure",
"name": "statsdb",
"connectionStringName": "stats",
"connectionString": "DSN=data-source-name[;SERVER=value] [;PWD=value] [;UID=value] [;<Attribute>=<value>]"
}
],
"scheduled": true,
"lastRestoreTimeStamp": "2022-09-04T17:33:11.641Z",
"finishedTimeStamp": "2022-09-05T17:33:11.641Z",
"websiteSizeInBytes": 56091883
}
}
]
}
定義
| 名稱 | Description |
|---|---|
|
Backup |
備份說明。 |
|
Backup |
備份項目的集合。 |
|
Backup |
備份狀態。 |
|
Database |
資料庫備份設定。 |
|
Database |
資料庫類型 (例如 SqlAzure / MySql)。 |
|
Default |
App Service 錯誤回應。 |
| Details | |
| Error |
錯誤模型。 |
BackupItem
備份說明。
| 名稱 | 類型 | Description |
|---|---|---|
| id |
string |
資源標識碼。 |
| kind |
string |
資源種類。 |
| name |
string |
資源名稱。 |
| properties.blobName |
string |
包含此備份資料的 Blob 名稱。 |
| properties.correlationId |
string |
唯一相關識別碼。 請在與 Azure 支援人員通訊時,搭配時間戳記使用。 |
| properties.created |
string (date-time) |
備份建立的時間戳記。 |
| properties.databases |
備份中包含的資料庫清單。 |
|
| properties.finishedTimeStamp |
string (date-time) |
此備份完成的時間戳記。 |
| properties.id |
integer (int32) |
備份的 ID。 |
| properties.lastRestoreTimeStamp |
string (date-time) |
使用此備份的最後一次還原作業的時間戳記。 |
| properties.log |
string |
有關此備份的詳細資訊。 可能包含錯誤訊息。 |
| properties.name |
string |
此備份的名稱。 |
| properties.scheduled |
boolean |
如果此備份是由於觸發排程而建立的,則為 True。 |
| properties.sizeInBytes |
integer (int64) |
備份的大小 (以位元組為單位)。 |
| properties.status |
備份狀態。 |
|
| properties.storageAccountUrl |
string |
包含此備份之儲存體帳戶容器的 SAS URL。 |
| properties.websiteSizeInBytes |
integer (int64) |
已備份的原始 Web 應用程式的大小。 |
| type |
string |
資源類型。 |
BackupItemCollection
備份項目的集合。
| 名稱 | 類型 | Description |
|---|---|---|
| nextLink |
string |
連結至下一頁的資源。 |
| value |
資源的收集。 |
BackupItemStatus
備份狀態。
| 值 | Description |
|---|---|
| InProgress | |
| Failed | |
| Succeeded | |
| TimedOut | |
| Created | |
| Skipped | |
| PartiallySucceeded | |
| DeleteInProgress | |
| DeleteFailed | |
| Deleted |
DatabaseBackupSetting
資料庫備份設定。
| 名稱 | 類型 | Description |
|---|---|---|
| connectionString |
string |
包含要備份或還原之資料庫的連接字串。 如果還原應該發生在新的資料庫,內部的資料庫名稱就是新的資料庫名稱。 |
| connectionStringName |
string |
包含連結到 SiteConfig.ConnectionStrings 的連接字串名稱。 這會在還原期間使用覆寫連接字串選項。 |
| databaseType |
資料庫類型 (例如 SqlAzure / MySql)。 |
|
| name |
string |
DatabaseType
資料庫類型 (例如 SqlAzure / MySql)。
| 值 | Description |
|---|---|
| SqlAzure | |
| MySql | |
| LocalMySql | |
| PostgreSql |
DefaultErrorResponse
App Service 錯誤回應。
| 名稱 | 類型 | Description |
|---|---|---|
| error |
錯誤模型。 |
Details
| 名稱 | 類型 | Description |
|---|---|---|
| code |
string |
標準化字串,以程式設計方式識別錯誤。 |
| message |
string |
詳細的錯誤描述和偵錯資訊。 |
| target |
string |
詳細的錯誤描述和偵錯資訊。 |
Error
錯誤模型。
| 名稱 | 類型 | Description |
|---|---|---|
| code |
string |
標準化字串,以程式設計方式識別錯誤。 |
| details |
Details[] |
詳細的錯誤。 |
| innererror |
string |
偵錯錯誤的詳細資訊。 |
| message |
string |
詳細的錯誤描述和偵錯資訊。 |
| target |
string |
詳細的錯誤描述和偵錯資訊。 |