Polyv Help Center

Help Center

Query Quarantine Zone Bill List

Updated: 2022-09-02 18:08:07

API Description

1、集团账号查询主账号账单
2、接口支持https协议

API URL


Request Method

GET

API Constraints

  1. The API supports both HTTP and HTTPS. HTTPS is recommended for security. API calls have frequency limits. Click for details

  2. For group account API signature calculation, use the appId and appSecret of the primary group account.

  3. The billing period must be after 202204.

Request Parameter Description

Parameter Required Type Description
appId true String Primary group account appId
timestamp true Long Current 13-digit millisecond timestamp, valid within 3 minutes
sign true String Signature, a 32-character uppercase MD5 value. The appSecret used to generate the signature is critical for communication data security. It must never be stored or used directly on the client. All API calls must be relayed through the customer's own server to the POLYV server to obtain response data. See signature generation rules
billingDate true String Billing period, format yyyyMM, e.g., 202205. Must be after 202204.
isolationId true String Quarantine zone ID, use the [User Global ID] returned when creating the account, i.e., userId.
The quarantine zone ID cannot be used across different group accounts.
pageSize false Integer Number of items per page, default 10, maximum 1000.
pageNumber false Integer Current page number, default 1.

Example


Response Parameter Description

Parameter Type Description
code Integer Status code, same as HTTP status code, used to determine the basic response status.
status String Response result, determined by the business. Returns "success" on success, "error" on failure.
success Boolean Whether the request was successful.
requestId String Request ID, a unique UUID generated for each request. Only for troubleshooting and debugging; should not be tied to business logic.
error Object Error information when the status code is not 200. See Error field description
data Object Bill list. See data field description

Error Parameter Description

Parameter Type Description
code Integer Error code, used to determine the specific error reason.
desc String Error description, corresponding to error.code.

Data Parameter Description

Parameter Type Description
pageNumber Integer Current page number.
pageSize Integer Number of items per page.
totalPages Long Total number of pages.
totalItems Long Total number of items.
contents Array Content of the current page. See contents field description

Contents Parameter Description

Parameter Type Description
unionId String Primary group account ID.
accountPeriod String Billing period.
production String Product: Cloud Live / Cloud VOD.
category String Usage type.
Cloud Live: Viewing minutes / Co-hosting minutes / Ultra-low latency minutes / Studio duration.
Cloud VOD: Video playback / Storage space.
itemConsumed Float Usage amount.
itemConsumedUnit String Usage unit.
statAt String Settlement date, day, format YYYY-MM-DD.
tradeType Integer Transaction type.
1: Usage settlement
2: Amount settlement
3: Deduction adjustment
4: Refund adjustment

Java Request Example


Response Example

For global system error descriptions, see Global Error Description

Success Example

{
    "code": 200,
    "status": "success",
    "requestId": "71c487ed89a94ca0b29e8779ea96f84b.57.16529454016270601",
    "data":
    {
        "pageNumber": 1,
        "pageSize": 10,
        "totalPages": 1,
        "totalItems": 7,
        "contents": [
            {
                "unionId": "******",
                "accountPeriod": "2022-05",
                "email": null,
                "memo": null,
                "production": "直播",
                "category": "导播时长",
                "itemConsumed": 120.00,
                "itemConsumedUnit": "分钟",
                "statAt": "2022-05-12",
                "tradeType": 1
            },
            {
                "unionId": "******",
                "accountPeriod": "2022-05",
                "email": null,
                "memo": null,
                "production": "直播",
                "category": "导播时长",
                "itemConsumed": 80.00,
                "itemConsumedUnit": "分钟",
                "statAt": "2022-05-12",
                "tradeType": 2
            },
            {
                "unionId": "******",
                "accountPeriod": "2022-05",
                "email": null,
                "memo": null,
                "production": "直播",
                "category": "国内观看时长",
                "itemConsumed": 71.00,
                "itemConsumedUnit": "分钟",
                "statAt": "2022-05-16",
                "tradeType": 2
            },
            {
                "unionId": "******",
                "accountPeriod": "2022-05",
                "email": null,
                "memo": null,
                "production": "点播",
                "category": "存储空间",
                "itemConsumed": 0.50,
                "itemConsumedUnit": "GB",
                "statAt": "2022-05-17",
                "tradeType": 2
            },
            {
                "unionId": "******",
                "accountPeriod": "2022-05",
                "email": null,
                "memo": null,
                "production": "直播",
                "category": "国内观看时长",
                "itemConsumed": 88.00,
                "itemConsumedUnit": "分钟",
                "statAt": "2022-05-18",
                "tradeType": 2
            },
            {
                "unionId": "******",
                "accountPeriod": "2022-05",
                "email": null,
                "memo": null,
                "production": "点播",
                "category": "存储空间",
                "itemConsumed": 0.50,
                "itemConsumedUnit": "GB",
                "statAt": "2022-05-18",
                "tradeType": 2
            },
            {
                "unionId": "******",
                "accountPeriod": "2022-05",
                "email": null,
                "memo": null,
                "production": "点播",
                "category": "存储空间",
                "itemConsumed": 0.50,
                "itemConsumedUnit": "GB",
                "statAt": "2022-05-19",
                "tradeType": 2
            }]
    },
    "success": true
}

Error Example

{
    "code": 400,
    "status": "error",
    "error": {
        "code": 10003,
        "desc": "时间戳过期"
    },
    "success": false
}
联系客服,在线咨询