Queries the total coverage data of reserved instances (RIs) or storage capacity units (SCUs).

The queried total coverage data is the same as the aggregated data displayed on the Coverage tab of the Manage Reserved Instances page in the Billing Management console.

You can call this operation to query the total coverage data of RIs or SCUs.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes DescribeResourceCoverageTotal

The operation that you want to perform. Set the value to DescribeResourceCoverageTotal.

PeriodType String Yes HOUR

The time granularity at which total coverage data is queried. Valid values: MONTH, DAY, and HOUR.

ResourceType String Yes RI

The type of deduction plans whose total coverage data is queried. Valid values: RI and SCU.

StartPeriod String Yes 2021-01-01 00:00:00

The beginning of the time range to query. The beginning is included in the time range. Specify the time in the format of yyyy-MM-dd HH:mm:ss.

EndPeriod String No 2021-01-02 00:00:00

The end of the time range to query. The end is excluded from the time range. If you do not set this parameter, the end time is the current time. Specify the time in the format of yyyy-MM-dd HH:mm:ss.

BillOwnerId Long No 123745698925000

The ID of the account for which you want to query total coverage data. If you do not set this parameter, the data of the current Alibaba Cloud account and its RAM users is queried. To query the data of a RAM user, specify the ID of the RAM user.

Response parameters

Parameter Type Example Description
Code String Success

The status code.

Data Struct

The returned data.

PeriodCoverage Array of Item

The information about the coverage rate of deduction plans within a period.

CoveragePercentage Float 0.1

The coverage rate of deduction plans within the specified period.

Period String 2020110100

The period.

The value is in the format of yyyyMMddHH.

TotalCoverage Struct

The information about the total coverage data of deduction plans.

CapacityUnit String Calc*Hour

The unit that is used to measure the resources deducted from deduction plans.

CoveragePercentage Float 1

The total coverage rate of deduction plans.

DeductQuantity Float 1

The total amount of the resources deducted from deduction plans.

TotalQuantity Float 1

The total amount of resources consumed.

Message String Successful!

The message returned.

RequestId String 79EE7556-0CFD-44EB-9CD6-B3B526E3A85F

The ID of the request.

Success Boolean true

Indicates whether the operation was successful.

Examples

Sample requests

http(s)://[Endpoint]/?Action=DescribeResourceCoverageTotal
&PeriodType=HOUR
&ResourceType=RI
&StartPeriod=2021-01-01 00:00:00
&EndPeriod=2021-01-02 00:00:00
&<Common request parameters>

Sample success responses

JSON format

{"Message":"Successful!","RequestId":"79EE7556-0CFD-44EB-9CD6-B3B526E3A85F","Data":{"PeriodCoverage":[{"Period":"2020110100","CoveragePercentage":"0.1"}],"TotalCoverage":{"TotalQuantity":"1","CapacityUnit":"Calc*Hour","CoveragePercentage":"1","DeductQuantity":"1"}},"Code":"Success","Success":"true"}

Error codes

For a list of error codes, visit the API Error Center.