pagehive

claim_command

Claim a queued command so another run skips it while this one works on it.

Agent commandsChanges dataAll plans

What it does

Claim a queued command so another run skips it while this one works on it. The lease lasts lease_seconds (60 to 3600, default 600); after that the command is pending again. An error with reason claimed or finished means skip it.

Plans

Works on every plan: Free, Basic, Pro and Ultra.

Parameters

NameTypeAbout
site_idrequiredstringThe id of the site. list_sites gives the ids of your sites.
command_idrequiredstringThe id of the queued command, from command_queue.
lease_secondsintegerHow long the claim lasts, 60 to 3600 seconds. Default 600. After that the command is pending again.
idempotency_keystringAny unique string (1-200 printable ASCII). A retry with the same key and arguments returns the first call's result instead of running again. Same as the Idempotency-Key header.

Example

Call claim_command with these arguments:

{
  "site_id": "01a1…",
  "command_id": "01a1…"
}

Ids like 01a1… stand for your own. list_sites and list_tables give you the real ones.

Related guides