Skip to content

Commit 5d617cf

Browse files
Adding backupUsageSummaries API in 2018-12-20 version[Passive stamp] (#14309)
* Adding backupUsageSummaries API in 2018-12-20 version[Passive stamp] * Adding example * Adding example * Adding default error response * Fixing operationId * Revert "Fixing operationId" This reverts commit f7327d7. * Fixing operationId for getbackupusageSummaries * Adding nextLink * Adding nextLink in definition * Update * Reverting nextLink
1 parent 4c38684 commit 5d617cf

File tree

3 files changed

+263
-0
lines changed

3 files changed

+263
-0
lines changed

specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2018-12-20/bms.json

Lines changed: 157 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,72 @@
1818
"application/json"
1919
],
2020
"paths": {
21+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupUsageSummaries": {
22+
"get": {
23+
"tags": [
24+
"BackupUsageSummaries_CRR"
25+
],
26+
"description": "Fetches the backup management usage summaries of the vault.",
27+
"operationId": "BackupUsageSummariesCRR_List",
28+
"produces": [
29+
"application/json"
30+
],
31+
"parameters": [
32+
{
33+
"$ref": "#/parameters/ApiVersion"
34+
},
35+
{
36+
"$ref": "#/parameters/VaultName"
37+
},
38+
{
39+
"$ref": "#/parameters/ResourceGroupName"
40+
},
41+
{
42+
"$ref": "#/parameters/SubscriptionId"
43+
},
44+
{
45+
"name": "$filter",
46+
"in": "query",
47+
"description": "OData filter options.",
48+
"required": false,
49+
"type": "string"
50+
},
51+
{
52+
"name": "$skipToken",
53+
"in": "query",
54+
"description": "skipToken Filter.",
55+
"required": false,
56+
"type": "string"
57+
}
58+
],
59+
"responses": {
60+
"200": {
61+
"description": "OK",
62+
"schema": {
63+
"$ref": "#/definitions/BackupManagementUsageList"
64+
}
65+
},
66+
"default": {
67+
"description": "Error response describing why the operation failed.",
68+
"schema": {
69+
"$ref": "#/definitions/NewErrorResponse"
70+
}
71+
}
72+
},
73+
"x-ms-odata": "#/definitions/BMSBackupSummariesQueryObject",
74+
"x-ms-pageable": {
75+
"nextLinkName": null
76+
},
77+
"x-ms-examples": {
78+
"Get Protected Items Usages Summary": {
79+
"$ref": "./examples/Common/BackupProtectedItem_UsageSummary_Get.json"
80+
},
81+
"Get Protected Containers Usages Summary": {
82+
"$ref": "./examples/Common/BackupProtectionContainers_UsageSummary_Get.json"
83+
}
84+
}
85+
}
86+
},
2187
"/subscriptions/{subscriptionId}/providers/Microsoft.RecoveryServices/locations/{azureRegion}/backupAadProperties": {
2288
"get": {
2389
"tags": [
@@ -707,6 +773,97 @@
707773
}
708774
},
709775
"definitions": {
776+
"BackupManagementUsage": {
777+
"description": "Backup management usages of a vault.",
778+
"type": "object",
779+
"properties": {
780+
"unit": {
781+
"description": "Unit of the usage.",
782+
"enum": [
783+
"Count",
784+
"Bytes",
785+
"Seconds",
786+
"Percent",
787+
"CountPerSecond",
788+
"BytesPerSecond"
789+
],
790+
"type": "string",
791+
"x-ms-enum": {
792+
"name": "UsagesUnit",
793+
"modelAsString": true
794+
}
795+
},
796+
"quotaPeriod": {
797+
"description": "Quota period of usage.",
798+
"type": "string"
799+
},
800+
"nextResetTime": {
801+
"format": "date-time",
802+
"description": "Next reset time of usage.",
803+
"type": "string"
804+
},
805+
"currentValue": {
806+
"format": "int64",
807+
"description": "Current value of usage.",
808+
"type": "integer"
809+
},
810+
"limit": {
811+
"format": "int64",
812+
"description": "Limit of usage.",
813+
"type": "integer"
814+
},
815+
"name": {
816+
"$ref": "#/definitions/NameInfo",
817+
"description": "Name of usage."
818+
}
819+
}
820+
},
821+
"NameInfo": {
822+
"description": "The name of usage.",
823+
"type": "object",
824+
"properties": {
825+
"value": {
826+
"description": "Value of usage.",
827+
"type": "string"
828+
},
829+
"localizedValue": {
830+
"description": "Localized value of usage.",
831+
"type": "string"
832+
}
833+
}
834+
},
835+
"BackupManagementUsageList": {
836+
"description": "Backup management usage for vault.",
837+
"type": "object",
838+
"properties": {
839+
"value": {
840+
"description": "The list of backup management usages for the given vault.",
841+
"type": "array",
842+
"items": {
843+
"$ref": "#/definitions/BackupManagementUsage"
844+
}
845+
}
846+
}
847+
},
848+
"BMSBackupSummariesQueryObject": {
849+
"description": "Query parameters to fetch backup summaries.",
850+
"type": "object",
851+
"properties": {
852+
"type": {
853+
"description": "Backup management type for this container.",
854+
"enum": [
855+
"Invalid",
856+
"BackupProtectedItemCountSummary",
857+
"BackupProtectionContainerCountSummary"
858+
],
859+
"type": "string",
860+
"x-ms-enum": {
861+
"name": "Type",
862+
"modelAsString": true
863+
}
864+
}
865+
}
866+
},
710867
"NewErrorResponse": {
711868
"properties": {
712869
"error": {
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
{
2+
"parameters": {
3+
"subscriptionId": "00000000-0000-0000-0000-000000000000",
4+
"resourceGroupName": "testRG",
5+
"vaultName": "testVault",
6+
"api-version": "2017-07-01",
7+
"$filter": "type eq 'BackupProtectedItemCountSummary'"
8+
},
9+
"responses": {
10+
"200": {
11+
"body": {
12+
"value": [
13+
{
14+
"unit": "Count",
15+
"currentValue": 7,
16+
"limit": -1,
17+
"name": {
18+
"value": "AzureIaasVM",
19+
"localizedValue": "Azure Virtual Machine"
20+
}
21+
},
22+
{
23+
"unit": "Count",
24+
"currentValue": 3,
25+
"limit": -1,
26+
"name": {
27+
"value": "MAB",
28+
"localizedValue": "Azure Backup Agent"
29+
}
30+
},
31+
{
32+
"unit": "Count",
33+
"currentValue": 1,
34+
"limit": -1,
35+
"name": {
36+
"value": "AzureBackupServer",
37+
"localizedValue": "Azure Backup Server"
38+
}
39+
},
40+
{
41+
"unit": "Count",
42+
"currentValue": 2,
43+
"limit": -1,
44+
"name": {
45+
"value": "AzureStorage",
46+
"localizedValue": "Azure Storage (Azure Files)"
47+
}
48+
},
49+
{
50+
"unit": "Count",
51+
"currentValue": 2,
52+
"limit": -1,
53+
"name": {
54+
"value": "AzureWorkload",
55+
"localizedValue": "SQL in Azure VM"
56+
}
57+
}
58+
]
59+
}
60+
}
61+
}
62+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
{
2+
"parameters": {
3+
"subscriptionId": "00000000-0000-0000-0000-000000000000",
4+
"resourceGroupName": "testRG",
5+
"vaultName": "testVault",
6+
"api-version": "2017-07-01",
7+
"$filter": "type eq 'BackupProtectionContainerCountSummary'"
8+
},
9+
"responses": {
10+
"200": {
11+
"body": {
12+
"value": [
13+
{
14+
"unit": "Count",
15+
"currentValue": 2,
16+
"limit": -1,
17+
"name": {
18+
"value": "AzureBackupServer",
19+
"localizedValue": "Azure Backup Server"
20+
}
21+
},
22+
{
23+
"unit": "Count",
24+
"currentValue": 3,
25+
"limit": -1,
26+
"name": {
27+
"value": "MAB",
28+
"localizedValue": "Azure Backup Agent"
29+
}
30+
},
31+
{
32+
"unit": "Count",
33+
"currentValue": 1,
34+
"limit": -1,
35+
"name": {
36+
"value": "AzureWorkload",
37+
"localizedValue": "SQL in Azure VM"
38+
}
39+
}
40+
]
41+
}
42+
}
43+
}
44+
}

0 commit comments

Comments
 (0)