diff --git a/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/billing.json b/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/billing.json index 041933c43746..fb69cd2d8e32 100644 --- a/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/billing.json +++ b/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/billing.json @@ -158,6 +158,45 @@ } } }, + "/providers/Microsoft.Billing/billingAccounts/{billingAccountName}/listInvoiceSectionsWithCreateSubscriptionPermission": { + "post": { + "tags": [ + "BillingAccounts" + ], + "x-ms-examples": { + "InvoiceSectionsListWithCreateSubPermission": { + "$ref": "./examples/InvoiceSectionsListWithCreateSubPermission.json" + } + }, + "operationId": "BillingAccounts_ListInvoiceSectionsByCreateSubscriptionPermission", + "description": "Lists all invoice sections with create subscription permission for a user.", + "parameters": [ + { + "$ref": "#/parameters/apiVersionParameter" + }, + { + "$ref": "#/parameters/billingAccountNameParameter" + } + ], + "responses": { + "200": { + "description": "OK. The request has succeeded.", + "schema": { + "$ref": "#/definitions/InvoiceSectionListWithCreateSubPermissionResult" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/ErrorResponse" + } + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, "/providers/Microsoft.Billing/billingAccounts/{billingAccountName}/paymentMethods": { "get": { "tags": [ @@ -2591,7 +2630,7 @@ } } }, - "/subscriptions/{subscriptionId}/providers/Microsoft.Billing/billingProperty": { + "/subscriptions/{subscriptionId}/providers/Microsoft.Billing/billingProperty/default": { "get": { "tags": [ "BillingProperties" @@ -2630,48 +2669,6 @@ } } }, - "/providers/Microsoft.Billing/billingAccounts/{billingAccountName}/products/{productName}/updateAutoRenew": { - "post": { - "tags": [ - "Products" - ], - "operationId": "Products_UpdateAutoRenewByBillingAccount", - "description": "Cancel auto renew for product by product id and billing account name", - "x-ms-examples": { - "ProductsCancelByBillingAccount": { - "$ref": "./examples/ProductCancelByBillingAccount.json" - } - }, - "parameters": [ - { - "$ref": "#/parameters/billingAccountNameParameter" - }, - { - "$ref": "#/parameters/productNameParameter" - }, - { - "$ref": "#/parameters/apiVersionParameter" - }, - { - "$ref": "#/parameters/updateAutoRenewRequestParameter" - } - ], - "responses": { - "200": { - "description": "OK. The request has succeeded.", - "schema": { - "$ref": "#/definitions/UpdateAutoRenewOperation" - } - }, - "default": { - "description": "Error response describing why the operation failed.", - "schema": { - "$ref": "#/definitions/ErrorResponse" - } - } - } - } - }, "/providers/Microsoft.Billing/billingAccounts/{billingAccountName}/billingProfiles/{billingProfileName}/invoiceSections/{invoiceSectionName}/products/{productName}/updateAutoRenew": { "post": { "tags": [ @@ -5529,6 +5526,56 @@ } } }, + "InvoiceSectionListWithCreateSubPermissionResult": { + "type": "object", + "description": "Result of listing invoice section properties with create subscription permission.", + "properties": { + "value": { + "description": "The list of invoice section properties with create subscription permission.", + "type": "array", + "items": { + "$ref": "#/definitions/InvoiceSectionWithCreateSubPermission" + } + }, + "nextLink": { + "description": "The link (url) to the next page of results.", + "type": "string", + "readOnly": true + } + } + }, + "InvoiceSectionWithCreateSubPermission": { + "description": "Invoice section properties with create subscription permission.", + "properties": { + "invoiceSectionId": { + "description": "Invoice Section Id.", + "type": "string", + "readOnly": true + }, + "invoiceSectionDisplayName": { + "description": "Invoice Section display name.", + "type": "string", + "readOnly": true + }, + "billingProfileId": { + "description": "Billing profile Id.", + "type": "string", + "readOnly": true + }, + "billingProfileDisplayName": { + "description": "Billing profile display name.", + "type": "string", + "readOnly": true + }, + "enabledAzurePlans": { + "description": "Enabled azure plans for the associated billing profile.", + "type": "array", + "items": { + "$ref": "#/definitions/AzurePlan" + } + } + } + }, "AzurePlan": { "description": "Details about the azure plan.", "properties": { diff --git a/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/examples/InvoiceSectionsListWithCreateSubPermission.json b/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/examples/InvoiceSectionsListWithCreateSubPermission.json new file mode 100644 index 000000000000..dfc97353d0d6 --- /dev/null +++ b/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/examples/InvoiceSectionsListWithCreateSubPermission.json @@ -0,0 +1,30 @@ +{ + "parameters": { + "api-version": "2018-11-01-preview", + "billingAccountName": "{billingAccountName}" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "invoiceSectionId": "/providers/Microsoft.Billing/billingAccounts/{billingAccountName}/billingProfiles/11000000-0000-0000-0000-000000000000/invoiceSections/22000000-0000-0000-0000-000000000000", + "invoiceSectionDisplayName": "invoiceSection1", + "billingProfileId": "/providers/Microsoft.Billing/billingAccounts/{billingAccountName}/billingProfiles/11000000-0000-0000-0000-000000000000", + "billingProfileDisplayName": "Contoso operations billing", + "enabledAzurePlans": [ + { + "skuId": "0001", + "skuDescription": "Microsoft Azure Plan" + }, + { + "skuId": "0002", + "skuDescription": "Microsoft Azure Plan for DevTest" + } + ] + } + ] + } + } + } +} diff --git a/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/examples/ProductCancelByBillingAccount.json b/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/examples/ProductCancelByBillingAccount.json deleted file mode 100644 index f644c52ce463..000000000000 --- a/specification/billing/resource-manager/Microsoft.Billing/preview/2019-10-01-preview/examples/ProductCancelByBillingAccount.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "parameters": { - "api-version": "2019-10-01-preview", - "billingAccountName": "{billingAccountName}", - "productName": "{productName}", - "body": { - "autoRenew": "false" - } - }, - "responses": { - "200": { - "body": { - "properties": { - "endDate": "2018-05-01T17:32:28Z" - } - } - } - } -}