Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1425,6 +1425,11 @@
],
"operationId": "Operations_List",
"description": "Lists all of the available consumption REST API operations.",
"x-ms-examples": {
"PriceSheetForBillingPeriod": {
"$ref": "./examples/OperationList.json"
}
},
"parameters": [
{
"$ref": "#/parameters/apiVersionParameter"
Expand Down Expand Up @@ -1740,6 +1745,61 @@
}
}
},
"/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/customers/{customerId}/providers/Microsoft.Consumption/lots": {
"get": {
"tags": [
"Lots"
],
"operationId": "Lots_ListByCustomer",
"description": "Lists all Azure credits and Microsoft Azure consumption commitments for a billing account or a billing profile and a customer. Microsoft Azure consumption commitments are only supported for the billing account scope.",
"externalDocs": {
"url": "https://docs.microsoft.com/en-us/rest/api/consumption/"
},
"x-ms-examples": {
"LotsListByCustomer": {
"$ref": "./examples/LotsListByCustomer.json"
},
"LotsListByCustomerWithFilter": {
"$ref": "./examples/LotsListByCustomerWithFilters.json"
}
},
"parameters": [
{
"$ref": "#/parameters/billingAccountIdParameter"
},
{
"$ref": "#/parameters/customerIdParameter"
},
{
"$ref": "#/parameters/apiVersionParameter"
},
{
"name": "$filter",
"description": "May be used to filter the lots by Status, Source etc. The filter supports 'eq', 'lt', 'gt', 'le', 'ge', and 'and'. Tag filter is a key value pair string where key and value is separated by a colon (:).",
"in": "query",
"required": false,
"type": "string"
}
],
"responses": {
"200": {
"description": "OK. The request has succeeded.",
"schema": {
"$ref": "#/definitions/Lots"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-pageable": {
"nextLinkName": "nextLink"
}
}
},
"/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}/providers/Microsoft.Consumption/credits/balanceSummary": {
"get": {
"tags": [
Expand Down Expand Up @@ -3775,7 +3835,6 @@
"ModernReservationTransaction": {
"description": "Modern Reservation transaction resource.",
"type": "object",
"x-ms-discriminator-value": "Modern",
"allOf": [
{
"$ref": "#/definitions/ReservationTransactionResource"
Expand Down Expand Up @@ -5539,6 +5598,14 @@
"type": "string",
"x-ms-parameter-location": "method"
},
"customerIdParameter": {
"name": "customerId",
"in": "path",
"description": "Customer ID",
"required": true,
"type": "string",
"x-ms-parameter-location": "method"
},
"departmentIdParameter": {
"name": "departmentId",
"in": "path",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
{
"parameters": {
"api-version": "2021-05-01",
"billingAccountId": "1234:5678",
"customerId": "1234:5678"
},
"responses": {
"200": {
"body": {
"value": [
{
"id": "/providers/Microsoft.Billing/billingAccounts/1234/customers/456/providers/Microsoft.Consumption/lots/lot1",
"name": "lot1",
"type": "Microsoft.Consumption/lots",
"properties": {
"originalAmount": {
"currency": "USD",
"value": 5000.00
},
"closedBalance": {
"currency": "USD",
"value": 60.90
},
"source": "PurchasedCredit",
"startDate": "2021-05-01T00:00:00Z",
"expirationDate": "2021-05-01T00:00:00Z",
"poNumber": "3524"
}
},
{
"id": "/providers/Microsoft.Billing/billingAccounts/1234/customers/456/providers/Microsoft.Consumption/lots/lot2",
"name": "lot2",
"type": "Microsoft.Consumption/lots",
"properties": {
"originalAmount": {
"currency": "USD",
"value": 6000.00
},
"closedBalance": {
"currency": "USD",
"value": 80.90
},
"source": "PurchasedCredit",
"startDate": "2021-05-01T00:00:00Z",
"expirationDate": "2019-12-31T00:00:00Z",
"poNumber": "31224"
}
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"parameters": {
"api-version": "2021-05-01",
"billingAccountId": "1234:5678",
"customerId": "1234:5678",
"$filter": "status eq 'active' AND source eq 'consumptioncommitment'"
},
"responses": {
"200": {
"body": {
"value": [
{
"id": "/providers/Microsoft.Billing/billingAccounts/1234/customers/456/providers/Microsoft.Consumption/lots/lot1",
"name": "lot1",
"type": "Microsoft.Consumption/lots",
"properties": {
"originalAmount": {
"currency": "USD",
"value": 5000.00
},
"closedBalance": {
"currency": "USD",
"value": 60.90
},
"source": "PurchasedCredit",
"startDate": "2021-05-01T00:00:00Z",
"expirationDate": "2021-05-01T00:00:00Z",
"poNumber": "3524"
}
}
]
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"parameters": {
"api-version": "2021-10-01"
},
"responses": {
"200": {
"body": {
"value": [
{
"name": "Microsoft.Consumption/Operation",
"display": {
"provider": "Microsoft Azure Distributed Managed Service",
"resource": "Managed Applications",
"operation": "Create or Update Managed Applications",
"description": "Create or Update Managed Applications"
}
}
]
}
}
}
}