swagger: '2.0' info: version: 2020-08-01-preview title: Microsoft Azure AccessControlClient AccessConnector PaymentMethods API schemes: - https tags: - name: PaymentMethods paths: /providers/Microsoft.Billing/paymentMethods: get: tags: - PaymentMethods operationId: microsoftAzurePaymentmethodsListbyuser description: Lists the payment methods owned by the caller. externalDocs: url: https://docs.microsoft.com/en-us/rest/api/billing/ x-ms-examples: ListPaymentMethodOwnedByUser: $ref: ./examples/PaymentMethodOwnedByUser_List.json parameters: - $ref: '#/parameters/apiVersionParameter' responses: '200': description: OK. The request has succeeded. schema: $ref: '#/definitions/PaymentMethodsListResult' default: description: Error response describing why the operation failed. schema: $ref: ./types.json#/definitions/ErrorResponse x-ms-pageable: nextLinkName: nextLink summary: Microsoft Azure Get Providers Microsoft Billing Paymentmethods /providers/Microsoft.Billing/paymentMethods/{paymentMethodName}: get: tags: - PaymentMethods operationId: microsoftAzurePaymentmethodsGetbyuser description: Gets a payment method owned by the caller. externalDocs: url: https://docs.microsoft.com/en-us/rest/api/billing/ x-ms-examples: GetPaymentMethodOwnedByUser: $ref: ./examples/PaymentMethodOwnedByUser_Get.json parameters: - $ref: '#/parameters/apiVersionParameter' - $ref: '#/parameters/paymentMethodNameParameter' responses: '200': description: OK. The request has succeeded. schema: $ref: '#/definitions/PaymentMethod' default: description: Error response describing why the operation failed. schema: $ref: ./types.json#/definitions/ErrorResponse summary: Microsoft Azure Get Providers Microsoft Billing Paymentmethods Paymentmethodname delete: tags: - PaymentMethods operationId: microsoftAzurePaymentmethodsDeletebyuser description: Deletes a payment method owned by the caller. externalDocs: url: https://docs.microsoft.com/en-us/rest/api/billing/ x-ms-examples: DeletePaymentMethodOwnedByUser: $ref: ./examples/PaymentMethodOwnedByUser_Delete.json parameters: - $ref: '#/parameters/apiVersionParameter' - $ref: '#/parameters/paymentMethodNameParameter' responses: '200': description: OK. The request has succeeded. '204': description: The resource was not found. default: description: Error response describing why the operation failed. schema: $ref: ./types.json#/definitions/ErrorResponse summary: Microsoft Azure Delete Providers Microsoft Billing Paymentmethods Paymentmethodname /providers/Microsoft.Billing/billingAccounts/{billingAccountName}/paymentMethods: get: tags: - PaymentMethods operationId: microsoftAzurePaymentmethodsListbybillingaccount description: Lists the payment methods available for a billing account. Along with the payment methods owned by the caller, these payment methods can be attached to a billing profile to make payments. The operation is supported only for billing accounts with agreement type Microsoft Customer Agreement. externalDocs: url: https://docs.microsoft.com/en-us/rest/api/billing/ x-ms-examples: PaymentMethodsListByBillingAccount: $ref: ./examples/PaymentMethodAtBillingAccount_List.json parameters: - $ref: '#/parameters/billingAccountNameParameter' - $ref: '#/parameters/apiVersionParameter' responses: '200': description: OK. The request has succeeded. schema: $ref: '#/definitions/PaymentMethodsListResult' default: description: Error response describing why the operation failed. schema: $ref: ./types.json#/definitions/ErrorResponse x-ms-pageable: nextLinkName: nextLink summary: Microsoft Azure Get Providers Microsoft Billing Billingaccounts Billingaccountname Paymentmethods /providers/Microsoft.Billing/billingAccounts/{billingAccountName}/paymentMethods/{paymentMethodName}: get: tags: - PaymentMethods operationId: microsoftAzurePaymentmethodsGetbybillingaccount description: Gets a payment method available for a billing account. The operation is supported only for billing accounts with agreement type Microsoft Customer Agreement. externalDocs: url: https://docs.microsoft.com/en-us/rest/api/billing/ x-ms-examples: PaymentMethodGetAtBillingProfile: $ref: ./examples/PaymentMethodAtBillingAccount_Get.json parameters: - $ref: '#/parameters/apiVersionParameter' - $ref: '#/parameters/billingAccountNameParameter' - $ref: '#/parameters/paymentMethodNameParameter' responses: '200': description: OK. The request has succeeded. schema: $ref: '#/definitions/PaymentMethod' default: description: Error response describing why the operation failed. schema: $ref: ./types.json#/definitions/ErrorResponse summary: Microsoft Azure Get Providers Microsoft Billing Billingaccounts Billingaccountname Paymentmethods Paymentmethodname /providers/Microsoft.Billing/billingAccounts/{billingAccountName}/billingProfiles/{billingProfileName}/paymentMethodLinks: get: tags: - PaymentMethods operationId: microsoftAzurePaymentmethodsListbybillingprofile description: Lists payment methods attached to a billing profile. The operation is supported only for billing accounts with agreement type Microsoft Customer Agreement. externalDocs: url: https://docs.microsoft.com/en-us/rest/api/billing/ x-ms-examples: PaymentMethodsListByBillingProfile: $ref: ./examples/PaymentMethodAtBillingProfile_List.json parameters: - $ref: '#/parameters/billingAccountNameParameter' - $ref: '#/parameters/billingProfileNameParameter' - $ref: '#/parameters/apiVersionParameter' responses: '200': description: OK. The request has succeeded. schema: $ref: '#/definitions/PaymentMethodLinksListResult' default: description: Error response describing why the operation failed. schema: $ref: ./types.json#/definitions/ErrorResponse x-ms-pageable: nextLinkName: nextLink summary: Microsoft Azure Get Providers Microsoft Billing Billingaccounts Billingaccountname Billingprofiles Billingprofilename Paymentmethodlinks ? /providers/Microsoft.Billing/billingAccounts/{billingAccountName}/billingProfiles/{billingProfileName}/paymentMethodLinks/{paymentMethodName} : get: tags: - PaymentMethods operationId: microsoftAzurePaymentmethodsGetbybillingprofile description: Gets a payment method linked with a billing profile. The operation is supported only for billing accounts with agreement type Microsoft Customer Agreement. externalDocs: url: https://docs.microsoft.com/en-us/rest/api/billing/ x-ms-examples: PaymentMethodsGetByBillingProfile: $ref: ./examples/PaymentMethodAtBillingProfile_Get.json parameters: - $ref: '#/parameters/billingAccountNameParameter' - $ref: '#/parameters/billingProfileNameParameter' - $ref: '#/parameters/paymentMethodNameParameter' - $ref: '#/parameters/apiVersionParameter' responses: '200': description: OK. The request has succeeded. schema: $ref: '#/definitions/PaymentMethodLink' default: description: Error response describing why the operation failed. schema: $ref: ./types.json#/definitions/ErrorResponse summary: Microsoft Azure Get Providers Microsoft Billing Billingaccounts Billingaccountname Billingprofiles Billingprofilename Paymentmethodlinks Paymentmethodname delete: tags: - PaymentMethods operationId: microsoftAzurePaymentmethodsDeleteatbillingprofile x-ms-long-running-operation: true description: Deletes a payment method link and removes the payment method from a billing profile. The operation is supported only for billing accounts with agreement type Microsoft Customer Agreement. externalDocs: url: https://docs.microsoft.com/en-us/rest/api/billing/ x-ms-examples: PaymentMethodAtBillingProfileDelete: $ref: ./examples/PaymentMethodAtBillingProfile_Delete.json parameters: - $ref: '#/parameters/apiVersionParameter' - $ref: '#/parameters/billingAccountNameParameter' - $ref: '#/parameters/billingProfileNameParameter' - $ref: '#/parameters/paymentMethodNameParameter' responses: '200': description: OK. The request has succeeded. '202': description: Accepted headers: Location: description: Location URI to poll for result type: string Retry-After: description: Recommended time to wait before making another request to check the status of the operation. The time is specified in seconds. type: integer format: int32 '204': description: The resource was not found. '409': description: Conflict. Payment method cannot be detached from billing profile. x-ms-error-response: true schema: $ref: '#/definitions/DetachPaymentMethodEligibilityResult' default: description: Error response describing why the operation failed. schema: $ref: ./types.json#/definitions/ErrorResponse summary: Microsoft Azure Delete Providers Microsoft Billing Billingaccounts Billingaccountname Billingprofiles Billingprofilename Paymentmethodlinks Paymentmethodname definitions: PaymentMethod: description: A payment method. type: object allOf: - $ref: ./types.json#/definitions/Resource properties: properties: x-ms-client-flatten: true $ref: '#/definitions/PaymentMethodProperties' title: Payment method properties DetachPaymentMethodErrorDetails: type: object description: Error details of the detach payment method eligibility validation. properties: code: description: Error code for the detach payment method eligibility validation. $ref: '#/definitions/DetachPaymentMethodEligibilityErrorCode' message: description: Error message for the detach payment method eligibility validation. type: string PaymentMethodLinkProperties: description: The properties of a payment method link. type: object properties: paymentMethod: description: Projection of a payment method $ref: '#/definitions/PaymentMethodProjectionProperties' PaymentMethodProperties: description: The properties of a payment method. type: object properties: family: description: The family of payment method. type: string enum: - CreditCard - CheckWire x-ms-enum: name: paymentMethodFamily modelAsString: true type: description: The type of payment method. type: string readOnly: true accountHolderName: description: The account holder name for the payment method. This is only supported for payment methods with family CreditCard. type: string readOnly: true expiration: description: The expiration month and year of the payment method. This is only supported for payment methods with family CreditCard. type: string readOnly: true lastFourDigits: description: Last four digits of payment method. type: string readOnly: true displayName: description: The display name of the payment method. type: string readOnly: true logos: description: The list of logos for the payment method. type: array items: $ref: '#/definitions/PaymentMethodLogo' status: description: Status of the payment method. type: string enum: - active - inactive x-ms-enum: name: paymentMethodStatus modelAsString: true DetachPaymentMethodEligibilityError: type: object description: The details of the error. properties: code: description: Error code. type: string readOnly: true message: description: Error message. type: string readOnly: true details: description: The list of detach payment method eligibility errors. type: array readOnly: true items: $ref: '#/definitions/DetachPaymentMethodErrorDetails' DetachPaymentMethodEligibilityResult: description: Error response indicates that payment method cannot be detached from billing profile. type: object properties: error: description: The details of the error. $ref: '#/definitions/DetachPaymentMethodEligibilityError' PaymentMethodLinksListResult: description: The list of payment method links. type: object properties: value: description: The list of payment method links. type: array readOnly: true items: $ref: '#/definitions/PaymentMethodLink' nextLink: description: The link (url) to the next page of results. type: string readOnly: true PaymentMethodProjectionProperties: description: The properties of a payment method projection. type: object properties: id: description: Id of payment method. type: string readOnly: true family: description: The family of payment method. type: string enum: - CreditCard - CheckWire x-ms-enum: name: paymentMethodFamily modelAsString: true type: description: The type of payment method. type: string readOnly: true accountHolderName: description: The account holder name for the payment method. This is only supported for payment methods with family CreditCard. type: string readOnly: true expiration: description: The expiration month and year of the payment method. This is only supported for payment methods with family CreditCard. type: string readOnly: true lastFourDigits: description: Last four digits of payment method. type: string readOnly: true displayName: description: The display name of the payment method. type: string readOnly: true logos: description: The list of logos for the payment method. type: array items: $ref: '#/definitions/PaymentMethodLogo' status: description: Status of the payment method. type: string enum: - active - inactive x-ms-enum: name: paymentMethodStatus modelAsString: true PaymentMethodsListResult: description: The list of payment methods. type: object properties: value: description: The list of payment methods. type: array readOnly: true items: $ref: '#/definitions/PaymentMethod' nextLink: description: The link (url) to the next page of results. type: string readOnly: true DetachPaymentMethodEligibilityErrorCode: type: string description: Error code of the detach payment method eligibility validation response. enum: - AzureSubscriptions - RecurringCharges - ReservedInstances - OutstandingCharges - PendingCharges x-ms-enum: name: detachPaymentMethodEligibilityErrorCode modelAsString: true PaymentMethodLogo: description: Logo of payment method. type: object properties: mimeType: description: MIME type of the logo. type: string readOnly: true url: description: Public URL of image of the logo. type: string readOnly: true PaymentMethodLink: description: A payment method link. type: object allOf: - $ref: ./types.json#/definitions/Resource properties: properties: x-ms-client-flatten: true $ref: '#/definitions/PaymentMethodLinkProperties' title: Payment method link properties parameters: apiVersionParameter: name: api-version in: query required: true type: string description: The version of the API to be used with the client request. The current version is 2021-10-01. paymentMethodNameParameter: name: paymentMethodName in: path description: The ID that uniquely identifies a payment method. required: true type: string x-ms-parameter-location: method billingProfileNameParameter: name: billingProfileName in: path description: The ID that uniquely identifies a billing profile. required: true type: string x-ms-parameter-location: method billingAccountNameParameter: name: billingAccountName in: path description: The ID that uniquely identifies a billing account. required: true type: string x-ms-parameter-location: method x-ms-parameterized-host: hostTemplate: '{endpoint}' useSchemePrefix: false parameters: - $ref: '#/parameters/Endpoint'