Query Task API
API Overview
Used to query the current status and result of an image-to-depth generation task by task ID.
| Protocol | Endpoint | Method | Auth | Request Format | Response Format |
|---|---|---|---|---|---|
| HTTP | /open-api/v1/depth/query-task | GET | Bearer | application/json | application/json |
Request Headers
| Parameter | Value | Description |
|---|---|---|
| Content-Type | application/json | Data exchange format |
| Authorization | Bearer | Replace {accessToken} with the accessToken obtained above |
Request Parameters (HTTP GET)
| Parameter | Type | Required | Description |
|---|---|---|---|
| task_id | string | Yes | Task ID returned by the create-task API result |
text
https://api.hitem3d.ai/open-api/v1/depth/query-task?task_id=depth_20260312_8f92ab3e1cdeResponse Body
| Parameter | Field | Type | Description |
|---|---|---|---|
| code | - | int | Error code, see error code table |
| data | task_id | string | Task ID |
| state | string | Processing status • created: task created • queueing: task queued • processing: task in progress • success: task completed • failed: task failed | |
| id | string | Generated artifact ID | |
| url | string | Generated depth map URL, valid for one hour | |
| msg | - | string | Detailed error message |
json
{
"code": 200,
"data": {
"task_id": "depth_20260312_8f92ab3e1cde",
"state": "success",
"id": "depth_20260312_8f92ab3e1cde_0",
"url": "https://example.com/depth/output/result.exr"
},
"msg": "success"
}Error Codes
Error codes are returned in JSON structure, including code and msg.
json
{
"code": 5001001,
"data": {},
"msg": "generate failed"
}| Error Code | Error Message | Error Description |
|---|---|---|
| 5001001 | generate failed | Timeout or model failed to parse the input image. Retry later; credits are refunded |
Request Example (Shell)
shell
curl --location --request GET 'https://api.hitem3d.ai/open-api/v1/depth/query-task?task_id=depth_20260312_8f92ab3e1cde' \
--header 'Authorization: Bearer {{accessToken}}' \
--header 'Content-Type: application/json'