Execute batch ADB commands, supporting up to 20 cloud phones
Note: This interface only supports commands that can be executed within 10 seconds. Commands that take longer may not be executed correctly.
If you need to execute long-running commands, you can append
> /dev/null 2>&1 &
to the end of the command to run it in the background. For example:curl --no-check-certificate -O /sdcard/test.apk https://example.com/test.apk > /dev/null 2>&1 &
POST
/api/v1/cloudPhone/command
Parameter | Type | Required | Description |
---|---|---|---|
image_ids | array | Optional | Cloud Phone IDs, image_ids field is required when image_id is not present |
image_id | string | Optional | Cloud Phone ID, image_id field is required when image_ids is not present |
command | string | Yes | Command to be executed, no need to add adb shell prefix |
ADB Command Reference: https://help.duoplus.net/docs/adb-command-intro
{
"image_ids": [
"7Uw0M"
],
"command": "ls"
}
{
"code": 200,
"data": {
"7Uw0M": {
"success": true,
"content": "data\ntests\ntmp\ntraces\n",
"message": ""
}
},
"message": "Success"
}
{
"image_id": "7Uw0M",
"command": "ls"
}
{
"code": 200,
"data": {
"success": true,
"content": "data\ntests\ntmp\ntraces\n",
"message": ""
},
"message": ""
}