All Products
Search
Document Center

Object Storage Service:Query OSS billing data generated on an hourly basis

Last Updated:Aug 20, 2024

This topic describes how to call the QueryUserOmsData operation to query Object Storage Service (OSS) billing data generated on an hourly basis.

Request parameters

Parameter

Type

Required

Example

Description

Action

String

Yes

QueryUserOmsData

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

DataType

String

Yes

Hour

The unit in which billing data is generated. Set the value to Hour.

Table

String

Yes

OSS

The type of report that contains billable items. Valid values:

  • OSS: the OSS billing report that contains basic OSS billable items.

  • OssDataReplication: the OSS billing report that contains billable items related to cross-region replication (CRR).

  • OssSddpScan: the OSS billing report that contains billable items related to Sensitive Data Discovery and Protection (SDDP).

  • OssCache: the OSS billing report that contains billable items related to the accelerator cache capacity.

StartTime

String

Yes

2022-12-01T09:12:43Z

The beginning of the time range to query. The time must be in UTC.

EndTime

String

Yes

2022-12-01T09:13:46Z

The end of the time range to query. The time must be in UTC.

Marker

String

No

test

Specifies that billing data that is alphabetically after the value of Marker is returned. By default, if this parameter is not specified, all billing data is returned.

PageSize

Integer

No

50

The number of entries to return on each page.

Valid values: 1 to 200.

Default value: 100

Note

For more information about common request parameters involved in the operation, see Common Parameters.

Response parameters

Response parameters for basic billable items

Parameter

Type

Example

Description

HostId

String

intl

The site to which the user belongs. Valid value: intl.

Marker

string

NextToken

Specifies that the query operation starts from the value of the Marker parameter until all data on all pages is queried. If the value of the Marker parameter is empty, all data is returned.

ProviderId

String

26888

The ID of the product provider. Valid value: 26888.

UserId

String

148562088256****

The ID of the Alibaba Cloud account.

LessthanMonthDatasize

Integer

180

The billed storage usage of Infrequent Access (IA) and Archive objects that are stored for less than the minimum storage duration. Unit: bytes.

  • Storage usage of IA objects that are stored for less than the minimum storage duration

    If an IA locally redundant storage (LRS) object is overwritten or deleted when it is stored for less than 30 days (720 hours), you are charged for the remainder (720 hours - Actual storage duration) of the minimum storage duration.

  • Storage usage of Archive objects that are stored for less than the minimum storage duration

    If an Archive LRS object is overwritten or deleted when it is stored for less than 60 days (1,440 hours), you are charged for the remainder (1,440 hours - Actual storage duration) of the minimum storage duration.

ChargedDatasize

Integer

200

The billed storage usage of IA LRS and Archive LRS objects. Unit: bytes.

RetrievalData

Integer

200

The retrieval of IA and Archive objects.

  • Data retrieval of IA objects

    When you access IA objects, you are charged data retrieval fees based on the size of the retrieved IA objects.

  • Data retrieval of Archive objects

    When you access Archive objects, you need to restore them. You are charged data retrieval fees based on the size of the restored Archive objects.

RetrievalDataArchiveDirect

Integer

200

The retrieval of Archive objects in real time. When you access Archive objects without restoring the objects, you are charged Archive data retrieval fees based on the size of the retrieved Archive objects.

ChargedDatasizeCA

Integer

100

The billed storage usage of Cold Archive LRS objects. You are charged storage fees for Cold Archive LRS objects based on the total size and storage duration of the objects.

Important

Cold Archive LRS objects have a minimum billable size of 64 KB. Objects that are smaller than 64 KB are charged for 64 KB of storage usage. Objects that are greater than or equal to 64 KB are charged based on their actual sizes.

EarlyDeletionCA

Integer

100

The billed storage usage of Cold Archive objects that are stored for less than the minimum storage duration. If a Cold Archive object is overwritten or deleted when it is stored for less than 180 days (4,320 hours), you are charged for the remainder (4,320 hours - Actual storage duration) of the minimum storage duration.

Bucket

String

examplebucket

The name of the bucket.

NetworkIn

Integer

2000

The traffic generated by data transmission from the client to OSS over the Internet within the specified time range. Unit: bytes.

NetworkOut

Integer

2000

The traffic generated by data transmission from OSS to the client over the Internet within the specified time range. Unit: bytes.

PutRequest

Integer

1000

The number of PUT requests initiated by calling OSS API operations. This is a billable item for API operation fees.

GetRequest

Integer

2000

The number of GET requests initiated by calling OSS API operations. This is a billable item for API operation fees.

ProcessImgSize

Integer

200

The size of processed images. You are charged image processing fees based on the size of the source images. Unit: bytes.

AdvImageProcLow

Integer

200

The number of times you use the advanced image compression feature to generate compressed images with a resolution smaller than 800 × 600 pixels.

AdvImageProcMed

Integer

200

The number of times you use the advanced image compression feature to generate compressed images with a resolution smaller than 1600 × 1200 pixels.

Storage

Integer

2000

The billed storage usage of objects in a storage class specified by StorageType. Unit: bytes.

Note
  • If you call the GetBucketInfo operation by using an endpoint that does not correspond to the region in which the bucket is located, the value of Storage may be 0.

  • The metered storage usage of IA, Archive, Cold Archive, or Deep Cold Archive objects may not equal the billed storage usage of these objects because each of these objects has a minimum billable size of 64 KB.

StorageType

String

standard

The storage class of objects. Values:

  • standard: Standard LRS

  • IA: IA LRS

  • archive: Archive LRS

  • coldarchive: Cold Archive

  • deepcoldarchive: Deep Cold Archive

  • standard-zrs: Standard zone-redundant storage (ZRS)

  • IA-zrs: IA ZRS

  • archive-zrs: Archive ZRS

For more information, see Overview.

CAStdRetrievalData

Integer

65536

The amount of Cold Archive data that is restored using the standard priority (within 2 to 5 hours). Unit: bytes.

CABulkRetrievalData

Integer

65536

The amount of Cold Archive data that is restored using the bulk priority (within 5 to 12 hours). Unit: bytes.

CAHighPriorRetrievalData

Integer

65536

The amount of Cold Archive data that is restored using the expedited priority (within 1 hour). Unit: bytes.

DeepCAStdRetrievalData

Integer

65536

The amount of Deep Cold Archive data that is restored using the standard priority (within 48 hours). Unit: bytes.

DeepCAHighPriorRetrievalData

Integer

65536

The amount of Deep Cold Archive data that is restored using the expedited priority (within 12 hours). Unit: bytes.

CAStdRetrievalRequest

Integer

10000

The number of requests initiated to restore Cold Archive data based on the standard priority.

CABulkRetrievalRequest

Integer

10000

The number of requests initiated to restore Cold Archive data based on the bulk priority.

CAHighPriorRetrievalRequest

Integer

10000

The number of requests initiated to restore Cold Archive data based on the expedited priority.

DeepCAStdRetrievalRequest

Integer

10000

The number of requests initiated to restore Deep Cold Archive data based on the standard priority.

DeepCAHighPriorRetrievalRequest

Integer

10000

The number of requests initiated to restore Deep Cold Archive data based on the expedited priority.

CdnIn

Integer

500

The inbound traffic generated when you access data by using Alibaba Cloud CDN. Unit: bytes.

CdnOut

Integer

500

The outbound traffic generated when you access data by using Alibaba Cloud CDN. The outbound traffic is also the origin traffic. Unit: bytes.

ProcessI

Integer

50

The number of images captured by using video snapshots. You are charged based on the number of images.

StorageZRS

Integer

100

The billed storage usage of Standard ZRS objects. You are charged storage fees for Standard ZRS objects based on the total size and storage duration of the objects.

ChargedDatasizeZRS

Integer

65536

The billed storage usage of IA ZRS objects. You are charged storage fees for IA ZRS objects based on the total size and storage duration of the objects.

IA ZRS objects have a minimum billable size of 64 KB. Objects that are smaller than 64 KB are charged for 64 KB of storage usage. Objects that are greater than or equal to 64 KB are charged based on their actual sizes.

LessthanMonthDatasizeZRS

Integer

700

The billed storage usage of IA ZRS objects that are stored for less than the minimum storage duration. If an IA ZRS object is overwritten or deleted when it is stored for less than 30 days (720 hours), you are charged for the remainder (720 hours - Actual storage duration) of the minimum storage duration.

AccM2MIn

Integer

500

The traffic generated when your transfer acceleration endpoint is used to upload data between regions inside the Chinese mainland. Unit: bytes.

AccM2MOut

Integer

500

The traffic generated when your acceleration endpoint is used to download data between regions inside the Chinese mainland. Unit: bytes.

AccM2OIn

Integer

500

The traffic generated when your acceleration endpoint is used to upload data from regions inside the Chinese mainland to regions outside the Chinese mainland. Unit: bytes.

AccM2OOut

Integer

500

The traffic generated when your acceleration endpoint is used to download data from regions outside the Chinese mainland to regions inside the Chinese mainland. Unit: bytes.

AccO2MIn

Integer

500

The traffic generated when your acceleration endpoint is used to upload data from regions outside the Chinese mainland to regions inside the Chinese mainland. Unit: bytes.

AccO2MOut

Integer

500

The traffic generated when your acceleration endpoint is used to download data from regions inside the Chinese mainland to regions outside the Chinese mainland. Unit: bytes.

AccO2OIn

Integer

500

The traffic generated when your acceleration endpoint is used to upload data between regions outside the Chinese mainland. Unit: bytes.

AccO2OOut

Integer

500

The traffic generated when your acceleration endpoint is used to download data between regions outside the Chinese mainland. Unit: bytes.

TempStorageCAStd

Integer

500

The temporary storage usage of Standard LRS replica objects that are created for temporary access when you restore Cold Archive and Deep Cold Archive objects. You are charged for the temporary storage of the replicas until the restored Cold Archive or Deep Cold Archive objects return to the frozen state. The replicas are automatically deleted after the Cold Archive or Deep Cold Archive objects return to the frozen state.

SelectScanSize

Integer

300

The size of objects scanned by calling the SelectObject operation. This is a billable item for data processing fees.

TagCount

Integer

100

The number of object tags in a bucket. You are charged for object tagging based on the number of tags.

StartTime

String

2022-12-01T09:12:43Z

The start time of the billing data. The time is in UTC.

EndTime

String

2022-12-01T09:13:46Z

The end time of the billing data. The time is in UTC.

Response parameters in the OssDeepColdArchive billing report

Parameter

Type

Example

Description

HostId

String

cn

The site to which the user belongs. Valid value: intl.

Marker

string

NextToken

Specifies that the query operation starts from the value of the Marker parameter until all data on all pages is queried. If the value of the Marker parameter is empty, all data is returned.

ProviderId

String

26842

The ID of the product provider. Valid value: 26888.

UserId

String

148562088256****

The ID of the Alibaba Cloud account.

ChargedDatasizeDeepCA

Integer

100

The billed storage usage of Deep Cold Archive LRS objects. You are charged storage fees for Deep Cold Archive LRS objects based on the total size and storage duration of the objects.

Important

Deep Cold Archive objects have a minimum billable size of 64 KB. Objects that are smaller than 64 KB are charged for 64 KB of storage usage. Objects that are greater than or equal to 64 KB are charged based on their actual sizes.

EarlyDeletionDeepCA

Integer

100

The billed storage usage of Deep Cold Archive objects that are stored for less than the minimum storage duration. If a Deep Cold Archive object is overwritten or deleted after it is stored for less than 180 days (4,320 hours), you are charged for the remainder (4,320 hours - Actual storage duration) of the minimum storage duration.

StartTime

String

2022-12-01T09:12:43Z

The start time of the billing data. The time is in UTC.

EndTime

String

2022-12-01T09:13:46Z

The end time of the billing data. The time is in UTC.

Response parameters in the OssDataReplication billing report

Parameter

Type

Example

Description

HostId

String

cn

The site to which the user belongs. Valid value: intl.

Marker

string

NextToken

Specifies that the query operation starts from the value of the Marker parameter until all data on all pages is queried. If the value of the Marker parameter is empty, all data is returned.

ProviderId

String

26842

The ID of the product provider. Valid value: 26888.

UserId

String

148562088256****

The ID of the Alibaba Cloud account.

SourceRegion

String

oss-cn-hangzhou

The region in which the source bucket is located when CRR is used.

DestRegion

String

oss-us-west-1

The region in which the destination bucket is located when CRR is used.

SourceBucket

String

srcbucket

The name of the source bucket.

DestBucket

String

destbucket

The name of the destination bucket.

ReplicationDatasize

Integer

1000

The size of the data replicated from the source bucket to the destination bucket. Unit: bytes.

RtcDatasize

Integer

1000

The data replication traffic generated by data replication tasks for which Replication Time Control (RTC) is enabled. Unit: bytes.

StartTime

String

2022-12-01T09:12:43Z

The start time of the billing data. The time is in UTC.

EndTime

String

2022-12-01T09:13:46Z

The end time of the billing data. The time is in UTC.

Response parameters in the OssSec billing report

Parameter

Type

Example

Description

HostId

String

cn

The site to which the user belongs. Valid value: intl.

Marker

string

NextToken

Specifies that the query operation starts from the value of the Marker parameter until all data on all pages is queried. If the value of the Marker parameter is empty, all data is returned.

ProviderId

String

26842

The ID of the product provider. Valid value: 26888.

UserId

String

148562088256****

The ID of the Alibaba Cloud account.

Bucket

String

examplebucket

The name of the bucket for which Anti-DDoS Proxy is enabled.

StartTime

String

2022-12-01T09:12:43Z

The start time of the billing data. The time is in UTC.

EndTime

String

2022-12-01T09:13:46Z

The end time of the billing data. The time is in UTC.

SecReserved

Integer

5

The number of Anti-DDoS Proxy instances. You are charged based on the number of Anti-DDoS Proxy instances that you purchase and the usage duration of the instances.

SecEarlyReleased

Integer

100

The fees for Anti-DDoS Proxy instances that are stored for less than the minimum usage duration. If an Anti-DDoS Proxy instance is released within seven days after the instance is created, you are charged for the remainder (7 days × 24 hours - Actual usage duration) of the minimum usage duration.

SecFlow

Integer

2000

The outbound traffic and inbound traffic that are generated over the Internet when the buckets that are attached to the purchased Anti-DDoS Proxy instance are accessed. You are charged for the generated outbound traffic and inbound traffic. The fees are calculated based on the maximum outbound or inbound traffic.

SecRequest

Integer

10000

The number of requests initiated to access buckets that are attached to the purchased Anti-DDoS Proxy instances. You are charged for the API requests. The fees are calculated based on the number of API requests.

Note

You are charged for both successful and failed requests.

Response parameters in the OssSddpScan billing report

Parameter

Type

Example

Description

HostId

String

cn

The site to which the user belongs. Valid value: intl.

Marker

string

NextToken

Specifies that the query operation starts from the value of the Marker parameter until all data on all pages is queried. If the value of the Marker parameter is empty, all data is returned.

ProviderId

String

26842

The ID of the product provider. Valid value: 26888.

UserId

String

148562088256****

The ID of the Alibaba Cloud account.

Bucket

String

examplebucket

The name of the bucket in which sensitive data is stored.

StartTime

String

2022-12-01T09:12:43Z

The start time of the billing data. The time is in UTC.

EndTime

String

2022-12-01T09:13:46Z

The end time of the billing data. The time is in UTC.

SddpScanSize

Integer

1000

The size of data on which Data Security Center (DSC) is authorized to perform full or incremental scanning. Unit: bytes.

Examples

  • Sample request

    https://business.aliyuncs.com/?Action=QueryUserOmsData
    &DataType=Hour
    &EndTime=2022-12-01T09:13:46Z
    &StartTime=2022-12-01T09:12:43Z
    &Table=oss
    &<Common request parameters>
  • Sample response

    {
        "Data": {
            "Marker": "NextToken",
            "OmsData": [
                {
                    "LessthanMonthDatasize": "180",                
                    "RetrievalData": "200",
                    "RetrievalDataArchiveDirect": "200",
                    "ChargedDatasize": "200",
                    "Bucket": "examplebucket",
                    "NetworkIn": "2000",
                    "PutRequest": "1000",
                    "NetworkOut": "2000",
                    "GetRequest": "2000",
                    "ProcessImgSize": "200",                
                    "Storage": "2000",
                    "Region": "cn-hangzhou",
                    "ProviderId": "26842",
                    "CdnIn": "500",
                    "EndTime": "2022-12-01T09:13:46Z",
                    "StartTime": "2022-12-01T09:12:43Z",
                    "StorageType": "standard",
                    "ProcessI": "50",
                    "CdnOut": "500"
                }
            ],
            "HostId": "cn"
        },
        "Message": "Successful!",
        "RequestId": "4C489CA2-5036-4B06-95A9-34AF55FDE1B2",
        "Success": true,
        "Code": "Success"
    }