Skip to content

Network commands

Network commands are action-oriented endpoints that operate on existing resources rather than managing them as collections. They follow the /v1/commands/ prefix pattern.

Attach and detach operations take effect instantly in the data plane. The two suspension endpoints are Administrator only: they require an admin session and are not callable with a normal workspace token.

See Asynchronous operations for workflow polling conventions.

Attach an IP

POST/v1/commands/attach-ipAttach an IP to an instance

Connects a floating IP to an instance. Network changes are applied immediately. The IP must already be allocated (see POST /v1/workspaces/{wid}/ips) and must not be attached to another instance.

Request body

FieldTypeRequiredDescription
ipintegeryesFloating IP ID
instanceintegeryesInstance ID
bash
curl -X POST https://api.galaxygate.net/v1/commands/attach-ip \
  -H "Authorization: Bearer $GALAXYGATE_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "ip": 9001,
    "instance": 101
  }'

Returns the updated floating IP object with instance populated.

Detach an IP

POST/v1/commands/detach-ipDetach an IP from an instance

Disconnects a floating IP from whichever instance it is currently attached to. Network changes are applied immediately.

Request body

FieldTypeRequiredDescription
ipintegeryesFloating IP ID

Returns the updated floating IP object with instance cleared.

Auto-attach network

POST/v1/commands/network-auto-attachAutomatically attach missing IPs to an instance

Finds and attaches any IPs that the instance is missing. Useful after a live migration or when provisioning detects a gap. Network changes are applied immediately when the operation completes. This is an asynchronous operation.

Request body

FieldTypeRequiredDescription
instanceintegeryesInstance ID
skip_duplicatebooleanyesWhen true, abort without error if the instance already has a matching IP in the requested family
v4objectIPv4 options (see below). Omit to skip IPv4.
v6objectIPv6 options (see below). Omit to skip IPv6.

v4 and v6 object

FieldTypeRequiredDescription
filteredbooleanyesWhen true, restrict candidate IPs to filtered (DDoS-protected) addresses

Returns a workflow wrapping an AttachResult that describes what was attached.

Suspend network

POST/v1/commands/suspend-networkSuspend an instance's network access

Cuts all network connectivity for an instance. Used for abuse mitigation. Administrator only.

Request body

FieldTypeRequiredDescription
instanceintegeryesInstance ID

Returns an audit log entry.

Unsuspend network

POST/v1/commands/unsuspend-networkRestore an instance's network access

Re-enables network connectivity for an instance that was suspended. Administrator only.

Request body

FieldTypeRequiredDescription
instanceintegeryesInstance ID

Returns an audit log entry.