tencent cloud


Exporting Service Logs

Last updated: 2020-09-04 15:42:44


    This document describes how to export service logs through the API Gateway console for data analysis and problem location.


    1. Log in to the API Gateway console and click Service in the left sidebar to access the service list page.
    2. On the service list page, click a service name to access the service details page.
    3. Click the Service Log tab.
    4. Click the Export icon in the red box as shown in the following figure to export service logs.


    • The time range of the logs to be exported is consistent with the time range of the queried logs. You can modify the time range of the logs to be exported by modifying the time range of the queried logs.
    • The exported log file is a CSV file. The file name is in the following format: Service Log-service ID (start time - end time).

    Log Format

    The format of exported service logs is as follows:


    The following table describes the parameters.

    Parameter Description
    app_id User ID.
    env_name Environment name.
    service_id Service ID.
    http_host Domain name.
    api_id API ID.
    uri Request path.
    scheme HTTP/HTTPS protocol.
    rsp_st Request response status code.
    ups_st Backend business server's response status code (if the request is passed through to the backend, this variable will not be empty. If the request is blocked by the API Gateway, this variable will be displayed as -).
    cip Client IP.
    uip Backend business service (upstream) IP.
    vip VIP requested to be accessed.
    rsp_len Response length.
    req_len Request length.
    req_t Total request and response time.
    ups_rsp_t Total backend response time (time between the connection establishment by the API Gateway and the backend response receipt).
    ups_conn_t Time when the backend business server is successfully connected to.
    ups_head_t Time when the backend response header arrives.
    err_msg Error message.
    tcp_rtt Client TCP connection information. Round Trip Time (RTT) consists of 3 parts: link propagation delay, end system processing delay, and queuing delay in the router cache.
    pid Process ID.
    time_local Time when the request is initiated.
    req_id Request ID.
    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