Home/AI capabilities/Automation and scripting
Automation and scripting

If the existing capabilities cannot be covered, a script will be written to make up for it.

Standard actions are enough to use the capabilities that come with the platform. When encountering platform-specific processes or your own business logic, The task script is written and connected to the same scheduling and logging system, so it can be checked and rerun like other tasks.

What it provides

  • Script execution environmentThe script runs in the cloud environment and does not occupy your machine
  • Run logs and rerunsEach run will leave traces, and if it fails, you can rerun it separately.
  • Confirmation before going onlineScripts involving external sending are first tested on a small scale.
  • Programmatic accessAPI Key, Webhook, CDP Broker, MQTT Device
Why it exists

You've probably run into these

There is a platform with a rather special process, and the ready-made functions are just one step away.

The missing step is written as a task script to make up for it, and it is linked to the same task chain. No need to wait for a product to be scheduled for a special case.

The scripts I wrote are scattered on several computers. I don’t know who has run them or whether they are successful.

The scripts are unified in the platform, and the running records, successes, failures, and outputs are all left in the running logs, which can be checked by person and time.

I don’t know how to write code, and I have to wait in line for even a small amount of logic.

AI programming can generate a draft script according to your description, and you can run it after you understand it. The generated stuff is readable code, not a black box.

The script hangs when the platform is revised, and you often don’t know until you find that the result is wrong.

If the operation fails, the reason will be recorded and the operation can be rerun. Continuous failures of the scheduled script can be directly seen in the log, and there is no need to wait for business problems to be discovered.

Capabilities

What it can do

For a script to be able to enter production, running alone is not enough: it must be able to be scheduled, checked, and called by external systems.

Task script

Write non-standard steps into scripts and execute them as part of the task. Scripts can be versioned and enabled separately by group.

AI programming

Describe what you want to do, and the AI generates a draft script and explains what each paragraph is doing. It is not recommended to go directly to production after making changes.

script template

Commonly used logic is stored in templates for reuse. You only need to change the parameters when changing account groups or platforms, and there is no need to rewrite them.

Run logs and reruns

The time, target, results and output of each run are saved one by one. Failed tasks are rerun independently without affecting other subtasks.

scheduled

The script can be executed on a scheduled or recurring basis, or it can be executed only once. Time windows and priorities can be configured as needed.

CDP access

Each cloud browser environment provides a CDP debugging address that your own scripts or third-party automation tools can directly connect to and operate.

API Key and API Documentation

Task distribution, environment management, and data reading on the platform side can be called through API and connected to your existing scheduling system.

Webhooks and MQTT

Task status changes can be pushed to your system through Webhook; MQTT is used for command issuance and status reporting on the device side.

How it works

From a piece of logic to timing running

The script must be verified on a small scale before it is put online, and if it is sent to external parties, it must be confirmed separately. The destructive power of a script is directly proportional to its degree of automation.

01
Write or generate scripts

Write it yourself, or use AI programming to generate a draft as described. You can also start from the script template and save the repeated parts.

Automatic
02
Review the script and test it on a small scale

See clearly which accounts it will operate, what data it will change, and what content it will post. First execute it once on one or two accounts and look at the running log.

Needs you
03
Confirm execution scope and schedule

Which account groups should be released, what cycle should be run, and whether to automatically retry after failure. Those involving external sending and paid resources should be nodded separately.

Needs you
04
Execute as scheduled and leave traces

The script is run in the corresponding cloud environment and logs are written every time it is run. Task status can be pushed to your system via webhooks.

Automatic
05
Look at the reasons for failure and fix them

Platform revisions, selector invalidations, and login status expirations will all be reflected in the logs. Just modify the script and rerun the part that failed.

Automatic

The script must be tested on a small scale before being released in volume. This should not be omitted. After a problematic script is scheduled, it will stably and regularly repeat the same error to all your accounts - automation amplifies efficiency, but it also amplifies errors. Therefore, trial running and large-scale confirmation are two steps, not one.

Prerequisites

Specifications and prerequisites

Scripting capabilities have technical requirements for users, so state them clearly and truthfully to avoid planning based on the expectation of ”no need to write code”.

Someone who can read scripts
The draft generated by AI still needs to be understood by someone before it can be put online. When there is no one in the team who can review the code, it is recommended to only use existing capabilities.
Cloud environment or cloud phone
The script needs to operate the account in a specific environment. Accounts without bound environments cannot be driven by scripts.
Access protocol
The browser uses the CDP debugging protocol, the platform uses API Key and API documents, and the device uses MQTT. Supported runtimes and languages
Maintenance expectations
The script depends on the page structure of the target platform. The script may become invalid after the platform is revised, and someone needs to follow up and fix it.
Concurrency and frequencySized to you
The number of script concurrencies and execution frequency are enabled based on your actual usage and are subject to the resource constraints of the node where you are located. Caps and valuations are confirmed by the consultant.
The system that receives the webhookOptional
It can be used even if you don’t accept it, and the task status can be checked in the platform. To synchronize the status to your own system, you need to prepare the receiving end.
Works with

Who it works with

FAQ

FAQ

When should you write a script and when should you not?

Scripts are suitable for steps that are stable, repetitive, and have clear rules, such as data sorting in a fixed format, a platform-specific operation process, and connection with your own system. It is not suitable for three types of situations: links that require judgment (whether the content is appropriate, whether the customer should follow up), because the script has no judgment and only conditional branches; operations that are sensitive to the risk control of the target platform, the script's action rhythm is more regular than humans and easier to identify; and temporary jobs that only run once or twice, writing scripts takes longer than doing it by hand. There is also a practical constraint - the script depends on the platform page structure, and it may become invalid if the platform is revised. Maintenance costs will be included in long-term use.

Can I use it if I don’t know how to write code?

Drafts can be generated using AI programming, but it is still recommended to have someone on the team who can read what the script is doing. The script will actually operate your account and go online if you don't understand it. When a problem occurs, you can neither troubleshoot nor explain the scope of the impact. When there is no such manpower at all, it is recommended to only use existing capabilities.

Where does the script run and will it occupy my machine?

It runs in the cloud environment of the platform and does not occupy your local resources. If you have local environment access, you can also let the script operate on the local environment, in which case the resources of your own machine will be used.

Can I use Puppeteer or Playwright?

Yes. Each cloud browser environment provides a CDP debugging address, and such tools can be operated directly by connecting to it. There are also API keys and API documents for task and environment management on the platform side, which can be initiated from your own scheduling system.

Will the script keep retrying if it fails?

You decide the retry strategy. You can not retry, retry a fixed number of times, or stop and wait for someone to handle it after failure. Timing scripts that continuously fail can be directly seen in the running log. It is recommended to cooperate with Webhook to push the failure status to your alarm channel.

Can anyone on the team create scripts?

Controlled by permissions. Script creation, script modification, and large-scale execution can be divided into different permission items, and the creation and execution actions are written into the operation log. In a production environment, it is recommended to only give volume permissions to a few people.

Let’s try a stuck process first.

The consultant will look at the step where you are currently stuck on the ready-made function and determine whether you should use a script to fix it or try another approach.