All Products
Search
Document Center

QueryBill

Last Updated: Feb 11, 2020

API Name

QueryBill

Overview

You can call this operation to query the monthly bill information in a specified billing cycle.

Request parameters

Name Type Required Description
BillingCycle String Yes The billing cycle. Format: YYYY-MM. Example: 2018-07
Type String No The type of bill. Valid values: SubscriptionOrder, PayAsYouGoBill, Refund, and Adjustment.
ProductCode String No The code of the specified product.
ProductType String No The type of the specified product.
SubscriptionType String No The type of billing method. Valid values: Subscription and PayAsYouGo.
IsHideZeroCharge String No Whether to hide 0 charge or not True, False and false by default.
IsDisplayLocalCurrency String No Whether to display local currency information or not in bill. True, False and false by default.
OwnerId Long No The ID of the owner. For BID or reseller, owner id is mandatory
PageNum Integer No
PageSize Integer No

Response parameters

Name Type Description
TotalCount Integer Total count number.
BillingCycle String The billing cycle. Format: YYYY-MM.
AccountID String Account unique ID
AccountName String Account name
OwnerID String The ID of the owner.
PageNum Integer
PageSize Integer
Items Item The billing details of Alibaba Cloud services.

Item:

Name Type Description
OwnerId String The id of the owner.
Item String Valid values: SubscriptionOrder, PayAsYouGoBill, Refund, and Adjustment.
ProductCode String The code of the specified product.
ProductName String The name of the specified product.
ProductType String The type of the specified product.
ProductDetail String Product detail information
SubscriptionType String The type of billing method. Valid values: Subscription and PayAsYouGo.
PaymentTime String Order payment time.
UsageStartTime String The time when the usage starts.
UsageEndTime String The time when the usage ends.
RecordID String Record is order id or bill id.
SubOrderId String The corresponding order detail id
PretaxGrossAmount Double The pretax gross amount.
DeductedByCoupons Double The amount deducted with coupons.
InvoiceDiscount Double The invoice discount amount.
RoundDownDiscount Double RoundDownDiscount
PretaxAmount Double The pretax amount, which is the total refunded amount when the system handles a refund request.
PaymentAmount Double The amount paid with cash.
OutstandingAmount Double The outstanding amount of a common user or the amount of credit used by a credit customer.
Currency String CNY/USD/JPY
Status String Payment status, PayFinish/PayUnclear/PayUnsettle/NoSettle
PaymentTransactionID String Payment transaction ID for a specific billrecord(for Intl site only)
PretaxAmountLocal Double Amount after discount(with local currency)
Tax Double Tax(with local currency)
AfterTaxAmount Double Amount after tax(with local currency))
PaymentCurrency String Currency(with local currency)

Error codes

Sample requests

Sample responses