tencent cloud

Feedback

DescribeStreamLinkFlowLogs

Last updated: 2024-09-09 10:35:14

    1. API Description

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

    This API is used to query the logs of a StreamLink flow.

    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: DescribeStreamLinkFlowLogs.
    Version Yes String Common Params. The value used for this API: 2020-08-28.
    Region No String Common Params. This parameter is not required for this API.
    FlowId Yes String The flow ID.
    StartTime Yes String The start time for query, which is 1 hour ago by default. You can query statistics in the last 7 days.
    It must be in UTC format, such as 2020-01-01T12:00:00Z.
    EndTime Yes String The end time for query, which is 1 hour after the start time by default. The longest time range allowed for query is 24 hours.
    It must be in UTC format, such as 2020-01-01T12:00:00Z.
    Type.N Yes Array of String Whether to query the inputs or outputs. Valid values: input, output.
    Pipeline.N Yes Array of String Whether to query the primary or backup pipeline. Valid values: 0, 1.
    PageSize Yes Integer The page size. Value range: [1, 1000]. Default: 100.
    SortType No String Whether to sort the records by timestamp in descending or ascending order. Valid values: desc (default), asc.
    PageNum No Integer The page number. Value range: [1, 1000]. Default: 1.

    3. Output Parameters

    Parameter Name Type Description
    Infos Array of FlowLogInfo A list of the logs.
    PageNum Integer The current page number.
    PageSize Integer The number of records per page.
    TotalNum Integer The total number of records.
    TotalPage Integer The total number of pages.
    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 Request Sample

    Input Example

    POST / HTTP/1.1
    Host: mdc.tencentcloudapi.com
    Content-Type: application/json
    X-TC-Action: DescribeStreamLinkFlowLogs
    <Common request parameters>
    
    {
        "FlowId": "0175723949ba0956b92d0bf40cfe",
        "StartTime": "2020-12-10T13:00:00Z",
        "EndTime": "2020-12-10T13:27:00Z",
        "Type": [
            "Input",
            "Output"
        ],
        "Pipeline": [
            "0",
            "1"
        ],
        "PageNum": 1,
        "PageSize": 100
    }
    

    Output Example

    {
        "Response": {
            "Infos": [
                {
                    "Timestamp": 1607605513,
                    "Type": "input",
                    "InputOutputId": "0175723949bb0956b92d0bf40cff",
                    "Protocol": "srt",
                    "EventCode": "1000",
                    "EventMessage": "Access Granted",
                    "RemoteIp": "42.194.229.84",
                    "RemotePort": "29000",
                    "Pipeline": "xx",
                    "InputOutputName": "xx"
                }
            ],
            "PageNum": 1,
            "PageSize": 100,
            "RequestId": "137253816",
            "TotalNum": 3,
            "TotalPage": 1
        }
    }
    

    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
    InternalError Internal error.
    InvalidParameter.EndTime Invalid EndTime.
    InvalidParameter.Id Invalid ID.
    InvalidParameter.NotFound No information found.
    InvalidParameter.PageNum Invalid PageNum.
    InvalidParameter.PageSize Invalid PageSize.
    InvalidParameter.Pipeline Invalid Pipeline.
    InvalidParameter.SortType Invalid SortType.
    InvalidParameter.StartTime Invalid StartTime.
    InvalidParameter.Type Invalid Type.