Get query history

Prev Next

Available in VPC

Get the query execution history.

Request

This section describes the request format. The method and URI are as follows:

Method URI
GET /api/v2/queries

Request headers

For information about the headers common to all Data Query APIs, see Data Query request headers.

Request query parameters

You can use the following query parameters with your request:

Field Type Required Description
status String Optional Filter by the query status.
  • QUEUED | STARTING | RUNNING | FINISHED | FAILED | CANCELED
    • QUEUED: Pending.
    • STARTING: Execution started.
    • RUNNING: Running.
    • FINISHED: Execution finished.
    • FAILED: Execution failed.
    • CANCELED: Execution canceled.
pageNo Integer Optional Page number
  • 1-N (default: 1)
pageSize Integer Optional Number of items per page
  • 1-500 (default: 20)

Request example

The request example is as follows:

curl --location --request GET 'https://kr.dataquery.naverncp.com/api/v2/queries?pageNo=1&pageSize=2' \
--header 'x-ncp-apigw-timestamp: {Timestamp}' \
--header 'x-ncp-iam-access-key: {Access Key}' \
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}'

Response

This section describes the response format.

Response body

The response body includes the following data:

Field Type Required Description
pageNo Integer - Page number
pageSize Integer - Number of items per page
hasMore Boolean - Whether next page exists
  • true | false
    • true: It exists.
    • false: It doesn't exist.
queryList Array - Query execution history: QueryHistory

QueryHistory

The following describes QueryHistory.

Field Type Required Description
id String - Execution ID
projectId Integer - Query execution project ID
query String - Execution query statement
status String - Query status
isReuse Boolean - Whether to reuse query results
  • true | false
    • true: Reuse
    • false: Not reuse
clientType String - Query request client type
  • CONSOLE | API
errorMessage String - Error message
  • Display null when call is successful.
runTime Number - Query execution run time (millisecond)
processDataSize Number - Processing data size
startTime String - Query execution start date and time
  • ISO 8601 format

Response status codes

For information about the HTTP status codes common to all Data Query APIs, see Data Query response status codes.

Response example

The response example is as follows:

{
    "pageNo": 1,
    "pageSize": 2,
    "hasMore": true,
    "queryList": [
        {
            "id": "eab65f48-****-****-****-c87f0db59b49",
            "projectId": 309,
            "query": "SELECT date, area_name, fine_dust_per_day\r\nFROM data_catalog.default.a_datacatalog_c512_4c8f9378\r\nWHERE area_name = 'downtown'",
            "status": "FINISHED",
            "isReuse": false,
            "clientType": "CONSOLE",
            "errorMessage": null,
            "runTime": 827,
            "processDataSize": 2783,
            "startTime": "2025-07-14T04:17:24.501+00:00"
        },
        {
            "id": "d7d1c896-****-****-****-1abcd2f816a2",
            "projectId": 309,
            "query": "SELECT date, area_name, fine_dust_per_day\r\nFROM data_catalog.default.a_datacatalog_c512_4c8f9378\r\nWHERE area_name = 'downtown'",
            "status": "FINISHED",
            "isReuse": false,
            "clientType": "CONSOLE",
            "errorMessage": null,
            "runTime": 268,
            "processDataSize": 2783,
            "startTime": "2025-07-14T02:43:14.411+00:00"
        }
    ]
}