Query task details¶
Read an export task and its file statistics.
POST https://moi.matrixorigin.cn/newmoi/export/task/info
Preparation before calling¶
First Query task list to confirm the export tasks you want to view. Prepare a personal access token with access to the target workspace, the target workspace ID, and the export task ID.
The example below uses:
$AI_STUDIO_API_KEY: The actual personal access token, passed through theX-API-KeyHeader.$WORKSPACE_ID: Target workspace ID, passed throughX-Workspace-IDHeader.$TASK_ID: The export task ID to be viewed, fill in theidfield of the request body.
Request example¶
curl -X POST "https://moi.matrixorigin.cn/newmoi/export/task/info" \
-H "X-API-Key: $AI_STUDIO_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID" \
-H 'Content-Type: application/json' \
-d '{
"id": "'$TASK_ID'"
}'
Request body¶
Field |
Type |
Is it required |
Description |
|---|---|---|---|
|
string |
Yes |
The export task ID to be queried. |
[] after a type denotes an array. [] in a field path denotes each item in an array.
Successful response¶
Returns 200 on success. data contains task definition and file statistics; task status is 2 only means that the task has been completed, and file_stats.failed should still be used to determine whether there is a failed file.
{
"code": "OK",
"msg": "OK",
"data": {
"id": "export-task-123",
"name": "export-to-s3",
"creator": "user-001",
"connector_name": "target-s3",
"type": 5,
"status": 2,
"config": {"s3_config": {"path": "exports/", "need_compress": false, "compress_method": ""}},
"create_time": "2026-08-18T10:00:00Z",
"end_time": "2026-08-18T10:02:00Z",
"file_stats": {"total": 4, "pending": 0, "running": 0, "failed": 1, "completed": 3},
"fileSuccess": 3,
"fileFail": 1
}
}
The response fields are as follows.
Field |
Type |
Description |
|---|---|---|
|
string |
|
|
string |
|
|
string |
Task ID. |
|
string |
Task name. |
|
string |
Creator ID. |
|
string |
Target connector name. |
|
integer |
Export target category: |
|
integer |
Task status: |
|
object |
The export configuration saved when created. Its fields are as follows. |
|
string |
The language identifier used when saving the task. |
|
boolean |
The title merge text settings saved by the task. |
|
object or null |
The target configuration for object storage tasks; |
|
string |
The export path within the connector bucket. |
|
boolean |
Whether to compress the exported content. |
|
string |
Compression method. |
|
object or null |
Target table configuration for MatrixOne tasks; |
|
string |
Target database name. |
|
string |
Target table name. |
|
boolean |
Whether to create a new target table. |
|
integer |
Duplicate data processing method: |
|
object |
Export column and column mapping configuration. |
|
object[] |
Export column mapping list. |
|
string |
The source column name in the processing result. |
|
string |
Column name in the target table. |
|
string[] |
The source column for merging processing; it is an empty array when not combined. |
|
string or null |
Creation time. |
|
string or null |
End time; |
|
object |
Summary of file count. |
|
integer |
The total number of files in the task. |
|
integer |
The number of files to be processed. |
|
integer |
Number of files being exported. |
|
integer |
The number of files that failed to export. |
|
integer |
The number of files that have been successfully completed. |
|
integer |
The number of files that have been successfully exported. |
|
integer |
The number of files that failed to export. |
Error response¶
{
"code": "ErrServer",
"msg": "Internal server error",
"data": null
}
Common HTTP errors¶
HTTP status code |
error code |
Common causes |
Recommended actions |
|---|---|---|---|
|
— |
The request body cannot be parsed; this compatible path returns an |
Pass in a JSON object containing |
|
|
The task does not exist or the details cannot be read. |
Check the task ID and try again. |
|
|
The current identity does not have permission to read the task. |
Request that read permission be granted to the export task. |
Follow-up operations¶
Use task ID Query export files to view file-level results; when progress summary is needed, Query task status.