Updated on 2026-07-21 GMT+08:00

Querying Download Information About Historical Session Analysis

Function

This API is used to query download information about historical session analysis.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.
  • If you are using role/policy-based authorization, see Permissions and Supported Actions for details on the required permissions.
  • If you are using identity policy-based authorization, the following identity policy-based permissions are required.

Action

Access Level

Resource Type (*: required)

Condition Key

Alias

Dependencies

rds:instance:getHistorySessionDownload

read

-

g:EnterpriseProjectId

g:ResourceTag/<tag-key>

-

-

Constraints

This API is available only for RDS for PostgreSQL.

URI

  • URI format

    GET /v3/{project_id}/instances/{instance_id}/history-session-analyse-upload?type={type}

  • Parameter description
    Table 1 Parameters

    Parameter

    Mandatory

    Description

    project_id

    Yes

    Definition

    Project ID of a tenant in a region.

    To obtain the value, see Obtaining a Project ID.

    Constraints

    N/A

    Range

    N/A

    Default Value

    N/A

    instance_id

    Yes

    Definition

    Instance ID.

    You can obtain the value of this parameter from id in Table 4 by calling the API for querying DB instances.

    Constraints

    N/A

    Range

    N/A

    Default Value

    N/A

    type

    Yes

    Definition

    Download information type.

    Constraints

    N/A

    Range

    • session: historical session download information
    • wait_event: historical wait event download information
    • top_sql: historical top SQL download information

    Default Value

    N/A

Request

None

Example Request

Query download information about historical session analysis.

GET https://{Endpoint}/v3/0483b6b16e954cb88930a360d2c4e663/instances/24c6678f474241fe89ee9c42f768022ein03/history-session-analyse-upload?type=session

Response

  • Normal response
    Table 2 Parameters

    Parameter

    Type

    Description

    count

    Integer

    Definition

    Number of records.

    Range

    N/A

    list

    Array of objects

    Definition

    Download information.

    For details, see Table 3.

    Table 3 list field description

    Parameter

    Type

    Description

    workflow_id

    String

    Definition

    Task ID.

    Range

    N/A

    file_name

    String

    Definition

    Name of the generated file for downloading.

    Range

    N/A

    status

    String

    Definition

    Status of the current link.

    Range

    N/A

    file_size

    String

    Definition

    File size, in bytes.

    Range

    N/A

    file_link

    String

    Definition

    Download link.

    Range

    N/A

    file_link_expiration_time

    Long

    Definition

    Time when the download link expires.

    Range

    N/A

    start_time

    Long

    Definition

    Start time.

    The value is in the UTC timestamp format.

    Range

    N/A

    end_time

    Long

    Definition

    End time.

    The value is in the UTC timestamp format.

    Range

    N/A

  • Example normal response
    { 
      "list" : [ { 
        "status" : "SUCCESS", 
        "workflow_id" : "705bbb2d-b568-42ee-8ad7-f9b43f6780f1", 
        "file_name" : "a8e531baf4804b0a840e1b98cd146caf_topSql_download_1_20251209115539926.zip", 
        "file_size" : "225.0", 
        "file_link" : "xxx", 
        "file_link_expiration_time" : 1765281653734, 
        "start_time" : 1764869600000, 
        "end_time" : 1765249216000 
      } ], 
      "count" : 1 
    }
  • Abnormal response

    For details, see Abnormal Request Results.

Status Code

Error Code

For details, see Error Codes.