Skip to content

Get Data Query Task Result



GET /api/v1/log_backup_query/get_result

Overview

Get the results of an asynchronous Data Forwarding query task and returns the query results.

Query Request Parameters

Parameter Name Type Required Description
taskId string Y Task ID
Example: xxx
Allow empty: False

Supplementary Parameter Notes

Field descriptions in the response result.

Parameter Name type Description
token string Query cursor. To paginate, include the token from the response in subsequent requests
row string Retrieved row information
task_status string Task status (created, running, completed, failed)
total_files integer Total number of files

Note: When the task status is created or running, the query is still in progress. completed and failed indicate that the query has finished.

Request Example

curl 'https://openapi.guance.com/api/v1/log_backup_query/get_result?taskId=d4ih5flt3l333a0ulmu0:a29kby14LWJhY2t1cGxvZy0w' \
-H 'DF-API-KEY: <DF-API-KEY>' \
--compressed

Response

{
    "code": 200,
    "content": {
        "token": "xxxxx",
        "row": [
            {
                "message": "{\"date\":1764000000519,\"message\":\"{}\",\"source\":\"xxxx\"}",
                "date": 1764000000519
            },
            {
                "message": "{\"date\":1764000000519,\"message\":\"{}\",\"source\":\"xxxx\"}",
                "date": 1764000000220
            }
        ],
        "is_truncated": true,
        "total_files": 2,
        "search_completed": 0,
        "task_status": "completed"
    },
    "errorCode": "",
    "message": "",
    "success": true,
    "traceId": "5f9d98a48909bae85d711a9d5219e882"
}

Feedback

Is this page helpful?