20% offevery plan

Black Friday Sale. New purchases, extensions and upgrades all qualify.

Ends in
00days
00hrs
00min
00sec
See plans
API

API reference: macros

List the macros you built in the dashboard, run one on an account, stop it, arm event macros, and see what is running.

List macros

GET /macros returns your saved macros. You build and edit them in the dashboard: see the macro guide.

{
  "macros": [
    { "id": "9f2c41d8a07b3e65c1d24f80ab93e7d1", "name": "Sell loop", "stepCount": 6, "trigger": "manual", "loopCount": 1 }
  ],
  "limit": 50
}

trigger is manual for a macro you start yourself and event for one that fires on a trigger. loopCount is how many times it loops when you run it as saved, -1 for until stopped. limit is how many macros your plan can save.

Run a macro

POST /macros/{macroId}/run starts a saved macro on one account, like the Run button.

FieldTypeDetail
accountIdstringRequired. The account to run it on. It should be online.
loopCountnumberOptional. 1 to 1000, or -1 to loop until stopped. A bigger number counts as 1000. Defaults to the value saved with the macro.
loopDelayMsnumberOptional. Pause between loops in milliseconds, 0 to 86400000, and at least 1000 when loopCount is -1. Defaults to the saved value.
curl -X POST https://dashboard.consoleclient.com/api/v1/macros/9f2c41d8a07b3e65c1d24f80ab93e7d1/run \
  -H "Authorization: Bearer $CC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"accountId": "[email protected]", "loopCount": 3}'
{ "ok": true, "runId": "a1b2c3d4e5f60718293a4b5c" }

Keep the runId to stop this exact run later. Running the same macro again on the same account restarts it instead of stacking a second copy. A run carries on across a reconnect until it finishes or you stop it, as in the dashboard.

ErrorHTTPMeaning
macro_not_found404No saved macro with that ID.
invalid_account400accountId is missing.
not_assigned404The account has not been started. Connect it first.
event_macro_not_supported400The macro is an event macro. Arm it with POST /macros/{macroId}/arm instead.
no_steps, invalid_macro400The saved macro is empty or no longer valid. Open it in the dashboard and save it again.
tier2_required, tier3_required403The macro has Auto Sell, Spawner Sentry or Replay steps that your plan does not include.
feature_cap_reached, node_update_required403, 409An Auto Sell or Spawner Sentry step cannot start: the feature already runs on as many accounts as your plan allows, or the account’s Node needs its update first. message says which.

Arm event macros

POST /macros/{macroId}/arm arms a saved event macro on one account, like switching it on in the dashboard. From then on it fires by itself when its trigger happens.

POST /macros/{macroId}/disarm takes it off the account again and stops a run of it that is still going. It answers { "ok": true } also when the macro was not armed.

FieldTypeDetail
accountIdstringRequired for both. The account to arm it on. It has to have been started at least once.
curl -X POST https://dashboard.consoleclient.com/api/v1/macros/5d1e0c9a8b7f6e5d4c3b2a1908f7e6d5/arm \
  -H "Authorization: Bearer $CC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"accountId": "[email protected]"}'
{ "ok": true }

Arming it again updates it with the steps and settings saved now. Armed macros show in events of GET /macros/active.

ErrorHTTPMeaning
invalid_account400accountId is missing.
macro_not_found404No saved macro with that ID.
not_event_macro400You start this macro yourself. Run it with POST /macros/{macroId}/run.
not_assigned404The account has never been started. Connect it first.
missing_chat_keywords400A chat keyword trigger without keywords. Add them in the dashboard and save the macro.
no_steps, invalid_macro, invalid_event_value400The saved macro is empty, or it or its trigger is no longer valid. Open it in the dashboard and save it again.
tier2_required, tier3_required403A block break trigger needs Tier 2, a nearby enemy trigger Tier 3, and Auto Sell, Spawner Sentry or Replay steps their own tier.
feature_cap_reached, node_update_required403, 409As for running a macro.

Stop a macro

POST /macros/stop stops macros on one account.

FieldTypeDetail
accountIdstringRequired.
runIdstringOptional. Stops that one run. Leave it out to stop every manual run on the account. A malformed value answers 400 invalid_run.
{ "ok": true }

See what is running

GET /macros/active returns the runs in progress and the armed event macros.

{
  "runs": [
    {
      "accountId": "[email protected]",
      "username": "ConsoleClient",
      "runId": "a1b2c3d4e5f60718293a4b5c",
      "macroId": "9f2c41d8a07b3e65c1d24f80ab93e7d1",
      "macroName": "Sell loop",
      "loopTotal": 3,
      "loopCurrent": 2,
      "source": "manual",
      "startedAt": 1790000460000,
      "updatedAt": 1790000520000,
      "held": false
    }
  ],
  "events": [
    {
      "accountId": "[email protected]",
      "username": "ConsoleClient2",
      "macroId": "5d1e0c9a8b7f6e5d4c3b2a1908f7e6d5",
      "macroName": "Eat when hungry",
      "eventType": "on-food-low",
      "enabled": true,
      "updatedAt": 1790000300000
    }
  ]
}

loopTotal is -1 for an endless loop. A run leaves runs when it finishes, so polling this endpoint is how you wait for a macro to complete.

FieldMeaning
heldtrue while a run waits after a reconnect, because your plan no longer includes one of its Auto Sell, Spawner Sentry or Replay steps, or the account’s Node needs its update. It carries on by itself once that is fixed. Stop it to remove it.
eventsThe event macros armed on your accounts. eventType lists the macro’s triggers, separated by commas. enabled is false while one is armed but switched off.
Need a hand?

Check the troubleshooting guide or return to all guides.