Instance

Instances are the virtual machines at the core of the Exoscale Compute service.

Read more

create-instance

Create a Compute instance

POST /instance

Request body

  • application/json
    • application-consistent-snapshot-enabled (boolean): Enable application-consistent snapshot for the instance
    • anti-affinity-groups (array[object]): Instance Anti-affinity Groups - schema details
    • public-ip-assignment (string)
    • labels (object)
    • auto-start (boolean): Start Instance on creation (default: true)
    • security-groups (array[object]): Instance Security Groups - schema details
    • name (string): Instance name
    • instance-type (required) (object): Compute instance type - schema details
    • template (required) (object): Instance template - schema details
    • secureboot-enabled (boolean): Enable secure boot
    • ssh-key (object): SSH key - schema details
    • user-data (string): Instance Cloud-init user-data (base64 encoded)
    • tpm-enabled (boolean): Enable Trusted Platform Module (TPM)
    • deploy-target (object): Deploy target - schema details
    • ipv6-enabled (boolean): Enable IPv6. DEPRECATED: use public-ip-assignments.
    • disk-size (required) (integer): Instance disk size in GiB
    • ssh-keys (array[object]): Instance SSH Keys - schema details

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for create-instance: golang | Python | Java

CLI: exo api create-instance

get-instance

Retrieve Compute instance details

GET /instance/{id}

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • application-consistent-snapshot-enabled (boolean): Indicates if the instance will take application-consistent snapshots
      • anti-affinity-groups (array[object]): Instance Anti-affinity Groups - schema details
      • public-ip-assignment (string)
      • labels (object)
      • security-groups (array[object]): Instance Security Groups - schema details
      • elastic-ips (array[object]): Instance Elastic IPs - schema details
      • name (string): Instance name
      • instance-type (object): Compute instance type - schema details
      • private-networks (array[object]): Instance Private Networks - schema details
      • template (object): Instance template - schema details
      • state (string)
      • secureboot-enabled (boolean): Indicates if the instance has secure boot enabled
      • ssh-key (object): SSH key - schema details
      • user-data (string): Instance Cloud-init user-data (base64 encoded)
      • mac-address (string): Instance MAC address
      • manager (object): Resource manager - schema details
      • tpm-enabled (boolean): Indicates if the instance has tpm enabled
      • deploy-target (object): Deploy target - schema details
      • ipv6-address (string): Instance IPv6 address
      • id (string): Instance ID
      • snapshots (array[object]): Instance Snapshots - schema details
      • disk-size (integer): Instance disk size in GiB
      • ssh-keys (array[object]): Instance SSH Keys - schema details
      • created-at (string): Instance creation date
      • public-ip (string): Instance public IPv4 address

SDK reference for get-instance: golang | Python | Java

CLI: exo api get-instance

reset-instance

Reset a Compute instance to a base/target template

PUT /instance/{id}:reset

This operation re-installs a Compute instance to a base template. If target template is provided it will be used to recreated instance from. Warning: the operation wipes all data stored on the disk.

Path parameters

  • id in path (required)

Request body

  • application/json
    • template (object): Instance template - schema details
    • disk-size (integer): Instance disk size in GiB

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for reset-instance: golang | Python | Java

CLI: exo api reset-instance

start-instance

Start a Compute instance

PUT /instance/{id}:start

This operation starts a virtual machine, potentially using a rescue profile if specified

Path parameters

  • id in path (required)

Request body

  • application/json
    • rescue-profile (string): Boot in Rescue Mode, using named profile (supported: netboot, netboot-efi)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for start-instance: golang | Python | Java

CLI: exo api start-instance

scale-instance

Scale a Compute instance to a new Instance Type

PUT /instance/{id}:scale

This operation changes the Compute instance’s type. Note: the new Instance Type must be within the same family (e.g. a standard instance cannot be scaled to gpu2 or storage).

Path parameters

  • id in path (required)

Request body

  • application/json
    • instance-type (required) (object): Compute instance type - schema details

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for scale-instance: golang | Python | Java

CLI: exo api scale-instance

stop-instance

Stop a Compute instance

PUT /instance/{id}:stop

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for stop-instance: golang | Python | Java

CLI: exo api stop-instance

reboot-instance

Reboot a Compute instance

PUT /instance/{id}:reboot

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for reboot-instance: golang | Python | Java

CLI: exo api reboot-instance

update-instance

Update a Compute instance

PUT /instance/{id}

Path parameters

  • id in path (required)

Request body

  • application/json
    • name (string): Instance name
    • user-data (string): Instance Cloud-init user-data (base64 encoded)
    • public-ip-assignment (string)
    • labels (object)
    • application-consistent-snapshot-enabled (boolean): Enable/Disable Application Consistent Snapshot for Instance

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for update-instance: golang | Python | Java

CLI: exo api update-instance

delete-instance

Delete a Compute instance

DELETE /instance/{id}

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for delete-instance: golang | Python | Java

CLI: exo api delete-instance

reveal-instance-password

Reveal the password used during instance creation or the latest password reset.

GET /instance/{id}:password

Reveal the password used during instance creation or the latest password reset. This is only available for VMs created against templates having the password-enabled property set to true.

        Passwords are transiently stored for at most 24 hours and intended to be retrieved shortly after
        creation or resets.

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • password (string): Password

SDK reference for reveal-instance-password: golang | Python | Java

CLI: exo api reveal-instance-password

reset-instance-password

Reset a compute instance password

PUT /instance/{id}:reset-password

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for reset-instance-password: golang | Python | Java

CLI: exo api reset-instance-password

remove-instance-protection

Remove instance destruction protection

PUT /instance/{id}:remove-protection

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for remove-instance-protection: golang | Python | Java

CLI: exo api remove-instance-protection

add-instance-protection

Set instance destruction protection

PUT /instance/{id}:add-protection

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for add-instance-protection: golang | Python | Java

CLI: exo api add-instance-protection


Other Operations

get-console-proxy-url

Retrieve signed url valid for 60 seconds to connect via console-proxy websocket to VM VNC console.

GET /console/{id}

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • url (string)
      • host (string)
      • path (string)

SDK reference for get-console-proxy-url: golang | Python | Java

CLI: exo api get-console-proxy-url

resize-instance-disk

Resize a Compute instance disk

PUT /instance/{id}:resize-disk

This operation resizes a Compute instance’s disk volume. Note: the disk can only grow, cannot be shrunk.

Path parameters

  • id in path (required)

Request body

  • application/json
    • disk-size (required) (integer): Instance disk size in GiB

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for resize-instance-disk: golang | Python | Java

CLI: exo api resize-instance-disk

reset-instance-field

Reset Instance field

DELETE /instance/{id}/{field}

Path parameters

  • id in path (required)
  • field in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for reset-instance-field: golang | Python | Java

CLI: exo api reset-instance-field

revert-instance-to-snapshot

Revert a snapshot for an instance

POST /instance/{instance-id}:revert-snapshot

This operation reverts the snapshot to the Compute instance volume, restoring stored data as it was at the time of the snapshot. The Compute instance must be previously stopped.

Path parameters

  • instance-id in path (required)

Request body

  • application/json
    • id (required) (string): Snapshot ID

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for revert-instance-to-snapshot: golang | Python | Java

CLI: exo api revert-instance-to-snapshot

list-instances

List Compute instances

GET /instance

Query parameters

  • manager-id in query (optional)
  • manager-type in query (optional)
  • ip-address in query (optional)

Responses

SDK reference for list-instances: golang | Python | Java

CLI: exo api list-instances

create-snapshot

Create a Snapshot of a Compute instance

POST /instance/{id}:create-snapshot

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for create-snapshot: golang | Python | Java

CLI: exo api create-snapshot

enable-tpm

Enable tpm for the instance.

POST /instance/{id}:enable-tpm

Path parameters

  • id in path (required)

Responses

  • 200: 200
    • application/json
      • id (string): Operation ID
      • reason (string): Operation failure reason
      • reference (object): Related resource reference - schema details
      • message (string): Operation message
      • state (string): Operation status

SDK reference for enable-tpm: golang | Python | Java

CLI: exo api enable-tpm

Last updated on