All Products
Search
Document Center

Drive and Photo Service:GetAsyncTask

更新時間:Aug 04, 2025

Queries the information about an asynchronous task.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

There is currently no authorization information disclosed in the API.

Request syntax

POST /v2/async_task/get HTTP/1.1

Request parameters

ParameterTypeRequiredDescriptionExample
bodyobjectNo

The request parameters.

async_task_idstringYes

The ID of the asynchronous task.

000e89fb-cf8f-11e9-8ab4-b6e980803a3b

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

async_task_idstring

The ID of the asynchronous task.

000e89fb-cf8f-11e9-8ab4-b6e980803a3b
statusstring

Warning This parameter is no longer used. We recommend that you use state instead.

The state of the task. Valid values:

  • Failed
  • Running
  • PartialSucceed
  • Succeed
Succeed
statestring

The state of the task. Valid values:

  • Failed
  • Running
  • PartialSucceed
  • Succeed
Succeed
messagestring

Warning This parameter is no longer used. We recommend that you use error_message instead.

The error message returned if the asynchronous task failed.

The request has been failed due to some unknown error. Please try again later.
err_codelong

Warning This parameter is no longer used. We recommend that you use error_code instead.

The error code returned if the asynchronous task failed.

InternalError
total_processlong

The total amount of work to be done in the asynchronous task, such as the number of files to be packaged for package download on the server.

1000
consumed_processlong

The total amount of work that is done in the asynchronous task, such as the number of files that are packaged for package download on the server.

100
urlstring

The download URL of the data generated by the asynchronous task, such as the download URL of the packaged files generated by the task of package download on the server.

https://data.aliyunpds.com/hz22%2F5d5b986facbec311ef844c25954f96821497b383%2F5d5b986f955410dd991646bb87c6b4e899eff525?Expires=xxx&OSSAccessKeyId=xxx&Signature=xxx
error_codestring

The error code returned if the asynchronous task failed.

InternalError
error_messagestring

The error message returned if the asynchronous task failed.

The request has been failed due to some unknown error. Please try again later.
uncompress_file_listarray

The extracted files.

UncompressedFileInfo

The extracted file.

categorystring

The custom category of the task.

album
created_atstring

The time when the task was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. Example: 2019-03-28T13:03:29.298Z.

2019-08-20T06:51:27.292Z
started_atstring

The time when the task was started. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. Example: 2019-03-28T13:03:29.298Z.

2019-08-20T06:51:27.292Z
finished_atstring

The time when the task was complete. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. Example: 2019-03-28T13:03:29.298Z.

2019-08-20T06:51:27.292Z

Examples

Sample success responses

JSONformat

{
  "async_task_id": "000e89fb-cf8f-11e9-8ab4-b6e980803a3b",
  "status": "Succeed",
  "state": "Succeed",
  "message": "The request has been failed due to some unknown error. Please try again later.",
  "err_code": 0,
  "total_process": 1000,
  "consumed_process": 100,
  "url": "https://data.aliyunpds.com/hz22%2F5d5b986facbec311ef844c25954f96821497b383%2F5d5b986f955410dd991646bb87c6b4e899eff525?Expires=xxx&OSSAccessKeyId=xxx&Signature=xxx",
  "error_code": "InternalError",
  "error_message": "The request has been failed due to some unknown error. Please try again later.",
  "uncompress_file_list": [
    {
      "drive_id": "",
      "file_id": "",
      "is_folder": true,
      "name": "",
      "size": 0,
      "updated_at": 0,
      "items": [
        {
          "drive_id": "",
          "file_id": "",
          "is_folder": true,
          "name": "",
          "size": 0,
          "updated_at": 0,
          "items": [
            {
              "drive_id": "",
              "file_id": "",
              "is_folder": true,
              "name": "",
              "size": 0,
              "updated_at": 0,
              "items": []
            }
          ]
        }
      ]
    }
  ],
  "category": "album",
  "created_at": "2019-08-20T06:51:27.292Z",
  "started_at": "2019-08-20T06:51:27.292Z",
  "finished_at": "2019-08-20T06:51:27.292Z",
  "skipped_process": 0,
  "failed_process": 0
}

Error codes

For a list of error codes, visit the Service error codes.