Documentation · Set up
WP-CLI commands
The plugin adds a wp operanse command. Every subcommand is an operator tool run on the server; none of them lets Operanse run anything that is not in the plugin's read-only capability list.
| Command | What it does |
|---|---|
wp operanse pair <token> | Pairs the site with a one-time token from the dashboard. Schedules the first inventory. |
wp operanse status | Prints the plugin's state as JSON: paired, site and key ids, connection mode, buffer tier and size, last upload, last collection, last error, backoff, and the cron check. |
wp operanse collect | Runs the collectors now (heartbeat, host resources, queue counts). |
wp operanse flush | Uploads the buffer now and prints whether it succeeded. |
wp operanse discover | Sends the inventory now. |
wp operanse poll | Checks for pending read jobs now. |
wp operanse cron-check | The same check as wp cron test, stored so the next heartbeat carries the result. |
wp operanse update-check | Asks whether a newer plugin release exists and tells WordPress to re-read its update list. Installing it is wp plugin update operanse-agent. |
wp operanse stream | Holds the outbound job stream; see connection modes. Options --max-jobs=<n> (500) and --max-minutes=<m> (30). |
wp operanse run-capability <name> | Runs one read capability locally and prints its answer, for diagnostics. --params=<json> passes parameters. |
Examples
Check that a site is connected and uploading:
wp operanse statusPair a site from a deployment script:
wp operanse pair "$OPERANSE_PAIRING_TOKEN"See exactly what a capability answers:
wp operanse run-capability get_action_scheduler_summarySettings → Operanse has a button for each of collect, flush, discover, poll and cron check, for sites without shell access.