Querying Task Details
Function
Queries the execution status of an asynchronous task, such as a desktop creation task.
Debugging
You can debug this API through automatic authentication in API Explorer or use the SDK sample code generated by API Explorer.
URI
GET /v2/{project_id}/workspace-jobs/{job_id}
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Project ID. |
job_id |
Yes |
String |
Task ID. |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
No |
String |
User token. It can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is the user token. |
Content-Type |
Yes |
String |
MIME type of the request body. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
id |
String |
Task ID. |
job_type |
String |
Task type. |
begin_time |
String |
Task start time. |
end_time |
String |
Task end time. |
status |
String |
Task status. |
job_error_code |
String |
Task error code. |
fail_reason |
String |
Task failure cause. |
sub_jobs_total |
Integer |
Total number of subtasks. |
sub_jobs |
Array of JobDetailInfo objects |
Subtasks. |
Parameter |
Type |
Description |
---|---|---|
id |
String |
Subtask ID. |
job_type |
String |
Task type. |
entities |
JobEntities object |
Task. |
begin_time |
String |
Task creation time. |
end_time |
String |
Task end time. |
status |
String |
Task status. |
error_code |
String |
Error code of a failed task. |
fail_reason |
String |
Task failure cause. |
host |
String |
IP address of the server where the task is executed. |
project_id |
String |
Project ID. |
job_id |
String |
Task ID. |
process |
Integer |
Task progress. |
attach_user |
String |
Associate user. |
entity |
String |
Operation object. |
ip_address |
String |
IP address. |
Parameter |
Type |
Description |
---|---|---|
desktop_id |
String |
Desktop ID. |
product_id |
String |
Package ID. |
user_name |
String |
Username. |
desktop_name |
String |
Desktop name. |
ip_address |
String |
IP address. |
Status code: 404
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code, which is returned upon failure. |
error_msg |
String |
Error message. |
encoded_authorization_message |
String |
Encrypted detailed reason for rejection. You can call the API decode-authorization-message of STS to decrypt the reason. |
Status code: default
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code, which is returned upon failure. |
error_msg |
String |
Error message. |
encoded_authorization_message |
String |
Encrypted detailed reason for rejection. You can call the API decode-authorization-message of STS to decrypt the reason. |
Example Requests
GET /v2/ac234de25c6741d2b1273da49eea1b9e/workspace-jobs/2382dd96-xxxxx56d-axxxc4b09a35b58
Example Responses
Status code: 200
Response to the request for querying task details.
{ }
Status Codes
Status Code |
Description |
---|---|
200 |
Response to the request for querying task details. |
404 |
No resources found. |
default |
Default response to a failure. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot