|
| 1 | +{ |
| 2 | + "swagger": "2.0", |
| 3 | + "info": { |
| 4 | + "version": "2023-03-01", |
| 5 | + "title": "ConsumptionManagementClient", |
| 6 | + "description": "Consumption management client provides access to consumption resources for Azure Enterprise Subscriptions." |
| 7 | + }, |
| 8 | + "host": "management.azure.com", |
| 9 | + "schemes": [ |
| 10 | + "https" |
| 11 | + ], |
| 12 | + "consumes": [ |
| 13 | + "application/json" |
| 14 | + ], |
| 15 | + "produces": [ |
| 16 | + "application/json" |
| 17 | + ], |
| 18 | + "security": [ |
| 19 | + { |
| 20 | + "azure_auth": [ |
| 21 | + "user_impersonation" |
| 22 | + ] |
| 23 | + } |
| 24 | + ], |
| 25 | + "securityDefinitions": { |
| 26 | + "azure_auth": { |
| 27 | + "type": "oauth2", |
| 28 | + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", |
| 29 | + "flow": "implicit", |
| 30 | + "description": "Azure Active Directory OAuth2 Flow.", |
| 31 | + "scopes": { |
| 32 | + "user_impersonation": "impersonate your user account" |
| 33 | + } |
| 34 | + } |
| 35 | + }, |
| 36 | + "paths": { |
| 37 | + "/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingPeriods/{billingPeriodName}/providers/Microsoft.Consumption/pricesheets/download": { |
| 38 | + "post": { |
| 39 | + "tags": [ |
| 40 | + "PriceSheet" |
| 41 | + ], |
| 42 | + "operationId": "PriceSheet_DownloadByBillingAccountPeriod", |
| 43 | + "description": "Generates the pricesheet for the provided billing period asynchronously based on the enrollment id", |
| 44 | + "externalDocs": { |
| 45 | + "url": "https://docs.microsoft.com/en-us/rest/api/consumption/" |
| 46 | + }, |
| 47 | + "x-ms-long-running-operation": true, |
| 48 | + "x-ms-long-running-operation-options": { |
| 49 | + "final-state-via": "location" |
| 50 | + }, |
| 51 | + "x-ms-examples": { |
| 52 | + "EAPriceSheetForBillingPeriod": { |
| 53 | + "$ref": "./examples/EAPriceSheetForBillingPeriod.json" |
| 54 | + } |
| 55 | + }, |
| 56 | + "parameters": [ |
| 57 | + { |
| 58 | + "$ref": "#/parameters/billingAccountIdParameter" |
| 59 | + }, |
| 60 | + { |
| 61 | + "$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" |
| 62 | + }, |
| 63 | + { |
| 64 | + "$ref": "#/parameters/billingPeriodNameParameter" |
| 65 | + } |
| 66 | + ], |
| 67 | + "responses": { |
| 68 | + "200": { |
| 69 | + "description": "Request processing completed.", |
| 70 | + "schema": { |
| 71 | + "$ref": "#/definitions/OperationStatus" |
| 72 | + } |
| 73 | + }, |
| 74 | + "202": { |
| 75 | + "description": "Accepted", |
| 76 | + "headers": { |
| 77 | + "Location": { |
| 78 | + "type": "string" |
| 79 | + }, |
| 80 | + "Retry-After": { |
| 81 | + "type": "integer", |
| 82 | + "format": "int64" |
| 83 | + } |
| 84 | + } |
| 85 | + }, |
| 86 | + "default": { |
| 87 | + "description": "Error response describing why the operation failed.", |
| 88 | + "schema": { |
| 89 | + "$ref": "../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" |
| 90 | + } |
| 91 | + } |
| 92 | + } |
| 93 | + } |
| 94 | + } |
| 95 | + }, |
| 96 | + "definitions": { |
| 97 | + "OperationStatus": { |
| 98 | + "description": "The status of the long running operation.", |
| 99 | + "type": "object", |
| 100 | + "properties": { |
| 101 | + "status": { |
| 102 | + "description": "The status of the long running operation.", |
| 103 | + "type": "string", |
| 104 | + "enum": [ |
| 105 | + "Running", |
| 106 | + "Completed", |
| 107 | + "Failed" |
| 108 | + ], |
| 109 | + "x-ms-enum": { |
| 110 | + "name": "OperationStatusType", |
| 111 | + "modelAsString": true |
| 112 | + } |
| 113 | + }, |
| 114 | + "properties": { |
| 115 | + "x-ms-client-flatten": true, |
| 116 | + "description": "The properties of the resource generated.", |
| 117 | + "$ref": "#/definitions/PricesheetDownloadProperties" |
| 118 | + } |
| 119 | + } |
| 120 | + }, |
| 121 | + "PricesheetDownloadProperties": { |
| 122 | + "description": "The properties of the price sheet download.", |
| 123 | + "type": "object", |
| 124 | + "properties": { |
| 125 | + "downloadUrl": { |
| 126 | + "description": "The link (url) to download the pricesheet.", |
| 127 | + "type": "string", |
| 128 | + "readOnly": true |
| 129 | + }, |
| 130 | + "validTill": { |
| 131 | + "description": "Download link validity.", |
| 132 | + "type": "string", |
| 133 | + "format": "date-time", |
| 134 | + "readOnly": true |
| 135 | + } |
| 136 | + } |
| 137 | + } |
| 138 | + }, |
| 139 | + "parameters": { |
| 140 | + "billingAccountIdParameter": { |
| 141 | + "name": "billingAccountId", |
| 142 | + "in": "path", |
| 143 | + "description": "BillingAccount ID", |
| 144 | + "required": true, |
| 145 | + "type": "string", |
| 146 | + "x-ms-parameter-location": "method" |
| 147 | + }, |
| 148 | + "billingPeriodNameParameter": { |
| 149 | + "name": "billingPeriodName", |
| 150 | + "in": "path", |
| 151 | + "description": "Billing Period Name.", |
| 152 | + "required": true, |
| 153 | + "type": "string", |
| 154 | + "pattern": "^[0-9]*$", |
| 155 | + "x-ms-parameter-location": "method" |
| 156 | + } |
| 157 | + } |
| 158 | +} |
0 commit comments