tencent cloud

All product documents
International Partners
DescribeCustomerBillDownloadUrl
Last updated: 2025-01-20 16:55:37
DescribeCustomerBillDownloadUrl
Last updated: 2025-01-20 16:55:37

1. API Description

Domain name for API request: intlpartnersmgt.intl.tencentcloudapi.com.

This API is used to get the URL for downloading the customer bill file by reseller. The download conditions are as follows:

  1. Detailed bills (billDetail and billDetailPack) can be downloaded starting from June 2022; resource bills (billResource and billResourcePack) can be downloaded starting from November 2023.
  2. Bill packages (billDetailPack and billResourcePack) can only be downloaded after billing.

A maximum of 20 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

Parameter Name Required Type Description
Action Yes String Common Params. The value used for this API: DescribeCustomerBillDownloadUrl.
Version Yes String Common Params. The value used for this API: 2022-09-28.
Region No String Common Params. This parameter is not required.
Month Yes String The month to which the bill belongs, formatted as yyyy-mm; the earliest month available for query is june, 2022. current month's billing data may be inaccurate; please download the current month's bill after it is generated at 1:00 on the 5th of the next month.
FileType Yes String Bill type. valid values: [billResource, billDetail, billResourcePack, billDetailPack]. billResource: resource bill; billDetail: detailed bill; billResourcePack: resource bill package; billDetailPack: detailed bill package.
CustomerUinType Yes String Customer type. valid values: [Customer, Reseller, ResellerCustomer]. Customer: direct customer; Reseller: secondary reseller; ResellerCustomer: reseller's customers
FileLanguage No String Language. valid values: [zh_cn, en]. default is en (english).
CustomerUin No Integer Customer uin. when downloading the bill package (FileType is billResourcePack or billDetailPack), CustomerUin is not passed

3. Output Parameters

Parameter Name Type Description
DownloadUrl String File download link, with a file validity period of 1 hour.
Ready Integer File generation status. 0: generating; 1: generated.
RequestId String The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.

4. Example

Example1 DescribeCustomerBillDownloadUrl-1

Reseller downloads direct customer L2 resource bill

Input Example

POST / HTTP/1.1
Host: intlpartnersmgt.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeCustomerBillDownloadUrl
<Common request parameters>

{
    "Month": "2024-12",
    "FileType": "billResource",
    "CustomerUinType": "Customer",
    "CustomerUin": 800000425835
}

Output Example

{
    "Response": {
        "DownloadUrl": "https://partner-bill-xxxx.cos.ap-singapore.myqcloud.com/L2-bill_by_Instance-800000425835-202412-xx-test.csv",
        "Ready": 1,
        "RequestId": "fa772ee3-e610-4e5b-905e-35c92a13e052"
    }
}

Example2 DescribeCustomerBillDownloadUrl-2

Reseller obtains indirect customer L3 bill detail link

Input Example

POST / HTTP/1.1
Host: intlpartnersmgt.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeCustomerBillDownloadUrl
<Common request parameters>

{
    "Month": "2024-12",
    "FileType": "billDetail",
    "CustomerUinType": "ResellerCustomer",
    "CustomerUin": 800001608331
}

Output Example

{
    "Response": {
        "DownloadUrl": "https://partner-bill-xxx.cos.ap-singapore.myqcloud.com/L3-bill_details-800001608331-202412-xxx-test.csv",
        "Ready": 1,
        "RequestId": "b93fad4a-1ef8-4011-a93b-bf8b6b5ee3ee"
    }
}

Example3 DescribeCustomerBillDownloadUrl-3

Reseller obtains all customer L2 resource bill packages (billed)

Input Example

POST / HTTP/1.1
Host: intlpartnersmgt.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeCustomerBillDownloadUrl
<Common request parameters>

{
    "Month": "2024-11",
    "FileType": "billResourcePack",
    "CustomerUinType": "Customer"
}

Output Example

{
    "Response": {
        "DownloadUrl": "https://partner-bill-xxx.cos.ap-singapore.myqcloud.com/%2Fmnt/bill/en/L2-bill_by_Instance-800000950266-AllCustomersBills-202411-xxx-test.zip",
        "Ready": 1,
        "RequestId": "0aa8fe2c-5221-4d94-b481-3f329c89b25a"
    }
}

Example4 DescribeCustomerBillDownloadUrl-4

Reseller obtains all indirect customer L3 bill detail packages (billed)

Input Example

POST / HTTP/1.1
Host: intlpartnersmgt.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeCustomerBillDownloadUrl
<Common request parameters>

{
    "Month": "2024-11",
    "FileType": "billDetailPack",
    "CustomerUinType": "ResellerCustomer"
}

Output Example

{
    "Response": {
        "DownloadUrl": "https://partner-bill-xxxx.cos.ap-singapore.myqcloud.com/%2Fmnt/bill/en/L3-bill_details-800000950266-AllResellersBills-202411-xxxx-test.zip",
        "Ready": 1,
        "RequestId": "fb76a1cd-7b8e-435a-909e-3f8ec3b91c9a"
    }
}

5. Developer Resources

SDK

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

Command Line Interface

6. Error Code

The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

Error Code Description
FailedOperation Operation failed.
InvalidParameter Invalid parameter
UnauthorizedOperation.UinNoAuth The current user doesn’t have permission for the operation.
Was this page helpful?
You can also Contact Sales or Submit a Ticket for help.
Yes
No

Feedback

Contact Us

Contact our sales team or business advisors to help your business.

Technical Support

Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

7x24 Phone Support
Hong Kong, China
+852 800 906 020 (Toll Free)
United States
+1 844 606 0804 (Toll Free)
United Kingdom
+44 808 196 4551 (Toll Free)
Canada
+1 888 605 7930 (Toll Free)
Australia
+61 1300 986 386 (Toll Free)
EdgeOne hotline
+852 300 80699
More local hotlines coming soon