Menu

Create Loop Task

Usage Instructions

Create Loop Task

Request Instructions

  • Method: POST
  • Endpoint: /api/v1/automation/addPlan

Request Parameters

| Parameter | Type | Required | Description |
| template_id | string | Yes | Template ID |
| template_type | int | Yes | Template source (1: Official template, 2: Custom template) |
| name | string | Yes | Number of items per page. Defaults to 10 per page if not provided |
| remark | string | No | Number of items per page. Defaults to 10 per page if not provided |
| images | array | Yes | Task data |

images

Parameter Type Required Description
image_id string Yes Cloud phone ID
config array No Data configuration
start_at string Yes Start time
end_at string Yes End time
execute_type string Yes Execution frequency (1: Interval, 2: Daily, 3: Weekly, 4: Monthly)
gap_time int No Interval time (Required if execute_type is 1)
execute_time string No Execution start time (Required if execute_type is 2, 3, or 4; otherwise 0)
execute_end_time string No Execution end time (Required if execute_type is 2, 3, or 4 and mode is 2)
mode int No Mode (1: Single execution, 2: Loop execution). Required if execute_type is 2, 3, or 4
weeks array No Week numbers (Required if execute_type is 3; otherwise 0)
days array No Day numbers of the month (Required if execute_type is 4; otherwise 0)

config

Parameter Type Required Description
key string Yes Key
value string Yes Value
type string Yes Value type (file: File, textarea: Bulk text, boolean: Boolean, number: Number, string: String, excel: Excel upload)
required bool Yes Whether required (true: required, false: optional)

Request Example

json Copy
{
    "template_id": "xxx",
    "template_type": "2",
    "name": "name",
    "remark": "remark",
    "images": [
        {
            "image_id": "xxx",
            "config": {
                "file": {
                    "key": "file",
                    "value": [
                        "https://xxx.cn/xxx.png"
                    ],
                    "type": "file",
                    "required": true
                },
                "text": {
                    "key": "text",
                    "value": "123\n456",
                    "type": "textarea",
                    "required": true
                },
                "bool": {
                    "key": "bool",
                    "value": "true",
                    "type": "boolean",
                    "required": true
                },
                "age": {
                    "key": "age",
                    "value": "18",
                    "type": "number",
                    "required": true
                },
                "name": {
                    "key": "name",
                    "value": "duoplus",
                    "type": "string",
                    "required": true
                },
                "email": {
                    "key": "email",
                    "value": "email1,email2",
                    "type": "excel",
                    "required": false
                },
                "password": {
                    "key": "password",
                    "value": "password1,passowrd2",
                    "type": "excel",
                    "required": false
                }
            },
            "start_at": "2025-12-11 17:38",
            "end_at": "2025-12-25 18:08",
            "execute_type": 4,
            "gap_time": 20,
            "execute_time": "15:11",
            "execute_end_time": "18:00",
            "mode": 2,
            "weeks":[1,2,3,4,5],
            "days": [22,23,12,11]
        }
    ]
}

Response Example

json Copy
{
    "code": 200,
    "data": {
        "id": "xxxx"
    },
    "message": "Success"
}
Previous
Create Scheduled Task
Next
Cloud Phone RPA Manual
Last modified: 2025-12-22Powered by