Power controls
Power a single instance on or off, or run one action across many instances at once. We run both calls in the background. A single power action returns 202 Accepted with WorkflowData. Batch power returns 200 OK with workflow and skipped records.
Power one instance
POST /v1/instances/{iid}/powercurl -X POST "https://api.galaxygate.net/v1/instances/$INSTANCE_ID/power" \
-H "Authorization: Bearer $GALAXYGATE_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "action": "SHUTDOWN" }'action values
The action field takes one of four values:
POWER_ON: boot a stopped instance.SHUTDOWN: ask the OS to shut down cleanly.POWER_OFF: cut power immediately.POWER_CYCLE: hard power off, then power on.
Use SHUTDOWN for routine stops so the OS flushes to disk. Use POWER_OFF and POWER_CYCLE when the machine is unresponsive.
No separate reboot action
There is no REBOOT action. A hard restart is POWER_CYCLE. For a graceful restart, send SHUTDOWN and then POWER_ON once the instance has stopped.
Power a batch of instances
To run one action over several instances in a single request:
POST /v1/commands/batch-instance-powercurl -X POST "https://api.galaxygate.net/v1/commands/batch-instance-power" \
-H "Authorization: Bearer $GALAXYGATE_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "POWER_CYCLE",
"instances": ["101", "102", "103"]
}'The request has two fields:
action(string): one of the four power actions above.instances(array of strings): the instance IDs to act on.
We return 200 OK with workflow data and skipped instance records. See Batch power for eligibility and response details. If you receive 429 Too Many Requests, split the work into smaller batches and wait between them.