Query Task Queue
Query the list of tasks for the user that are in the 'queued' status.
GET
https://api.alayanew.com/api/serverless-train/v1/task/queue
Authorizations
Authorizations:StringHeaderRequired
用户可通过已获取Open API Key做验证,例如:plain Credential=[YOUR_AK],Signature=[YOUR_SK]。
Query Parameters
name:String
Task name.
type:String
Task type is 'task', default value is 'task'.
aidcId:String
Intelligent Computing Center (AIDC) ID.
extensions.<key>:String
Format: extensions.<key>: value. After the user specifies some tags, they can query the corresponding tasks through the tags.
page:Int
Page number, default is 1.
size:Int
Number of rows to query, default is 100.
Response
状态码:application/json
200
code:Int
code is a common return value format, representing the execution result of the query operation.
0
-1
0 is the success identifier, indicating the operation was completed successfully.
data:Object
data.count:String
The number of query results.
data.rows:Array
msg:StringRequired
Returns exception information when code value is -1.
cURL
Python
JavaScript
Go
Java
curl -X GET 'https://api.alayanew.com/api/serverless-train/v1/task/queue?name=debug&type=task'
-H 'Authorization: plain Credential=YOUR_AK,Signature=YOUR_SK'
200
400
401
403
404
500
{
"code": 0,
"data": {
"count": 1,
"rows": [
{
"id": "6167a1ea-957a-4f68-b2e8-7f3f49ad5087",
"name": "runtask2",
"createAt": "2025-02-21T02:49:57.000+00:00",
"updateAt": "2025-02-21T02:59:57.000+00:00",
"type": "task",
"aidcId": "1",
"config": {
"cmd": [
"python3",
"a.py"
],
"env": {},
"args": [],
"image": "registry.hd-01.alayanew.com/aladdin/python:3.13",
"vksId": "vc3jedd7crnd",
"labels": {},
"workDir": "/root",
"replicas": 1,
"resource": {
"cpu": 2,
"gpu": {
"count": 0,
"gpuType": ""
},
"mem": 8,
"epheneralStorage": 32
},
"namespace": "default",
"extensions": {
"source": "a.py",
"folders": [
{
"path": "a.py",
"value": ""
}
]
}
}
}
]
}
}