tencent cloud

文档反馈

DescribeTIWRoomDailyUsage

最后更新时间:2023-12-07 10:46:28

    1. API Description

    Domain name for API request: tiw.tencentcloudapi.com.

    This API is used to query the daily billable usage by each room of a whiteboard application.

    1. The period queried per request cannot be longer than 31 days.
    2. Due to statistics delays and other reasons, you cannot query the usage data of the current day. You can query today's usage after 7:00 tomorrow.

    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: DescribeTIWRoomDailyUsage.
    Version Yes String Common Params. The value used for this API: 2019-09-19.
    Region No String Common Params. This parameter is not required for this API.
    SdkAppId Yes Integer SdkAppId of the whiteboard application.
    SubProduct Yes String Subproduct usage to be queried. The following parameters are supported:
    - sp_tiw_board: The duration of use of whiteboards, in minutes.
    - sp_tiw_ric: The duration of real-time recording, in minutes.
    StartTime Yes Date Start date in the format of YYYY-MM-DD. The start date is included in the query period.
    EndTime Yes Date End date in the format of YYYY-MM-DD. The end date is included in the query period. The period queried per request cannot be longer than 31 days.
    RoomIDs.N No Array of Integer Room IDs to be queried. If you leave this parameter empty, all room IDs are queried.
    Offset No Integer Offset for query. Default value: 0.
    Limit No Integer Maximum number of entries returned per query. Default value: 20.

    3. Output Parameters

    Parameter Name Type Description
    Usages Array of RoomUsageDataItem Usage of the specified product per room during the specified query period.
    Total Integer Number of usage data entries.
    RequestId String The unique request ID, which is returned for each request. RequestId is required for locating a problem.

    4. Example

    Example1 Querying the daily billable usage by each room

    This example shows you how to query the daily billable usage by each room of a whiteboard application within the period from 2022-11-24 to 2022-11-25.

    Input Example

    POST / HTTP/1.1
    Host: tiw.tencentcloudapi.com
    Content-Type: application/json
    X-TC-Action: DescribeTIWRoomDailyUsage
    <Common request parameters>
    
    {
        "SdkAppId": "1400000001",
        "SubProduct": "sp_tiw_board",
        "Limit": "20",
        "StartTime": "2022-11-24",
        "Offset": "0",
        "EndTime": "2022-11-25"
    }
    

    Output Example

    {
        "Response": {
            "RequestId": "916f3549-8e91-467c-afcb-b8dacf188e12",
            "Usages": [
                {
                    "Time": "2022-11-24",
                    "SdkAppId": 1400000001,
                    "SubProduct": "sp_tiw_board",
                    "RoomID": 432946024,
                    "Value": 5
                },
                {
                    "Time": "2022-11-24",
                    "SdkAppId": 1400000001,
                    "SubProduct": "sp_tiw_board",
                    "RoomID": 523696026,
                    "Value": 60
                },
                {
                    "Time": "2022-11-24",
                    "SdkAppId": 1400000001,
                    "SubProduct": "sp_tiw_board",
                    "RoomID": 1284910005,
                    "Value": 4
                }
            ],
            "Total": 3
        }
    }
    

    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
    AuthFailure
    InternalError Internal error.
    InvalidParameter A parameter error occurred.
    InvalidParameter.SdkAppIdNotFound The SdkAppId does not exist or is invalid.
    InvalidParameter.TranscodeParameter The document transcoding parameter format is invalid.
    ResourceUnavailable.NotRegistered TIW is not enabled.
    ResourceUnavailable.ServiceExpired The account is in arrears or the TIW service has expired.
    UnauthorizedOperation.SdkAppId The SdkAppId does not exist or does not match the current Tencent Cloud account.