Crusoe

App · 20 actions

Manage Crusoe Cloud projects, virtual machines, and disks.

Actions

ActionWhat it does
Create diskRequires either a disk snapshot ID, or size and location, where size of disk should be in gibibytes (GiB) or tebibytes (TiB) in the format [Size][Unit].
Create projectThe logged-in user must have the permission to create projects within the organization.
Create virtual machineCreate virtual machine.
Delete diskA successful response from this resource will contain the async operation.
Delete virtual machineDelete virtual machine.
Get current userGet current user.
Get diskSize of disk will be in gibibytes (GiB)
Get projectGet project.
Get virtual machineGet virtual machine.
Get virtual machine operationThis resource retrieves information about the status of an asynchronous operation initiated by the instances resource.
List disksSize of disks will be in gibibytes (GiB)
List imagesList images.
List locationsList locations.
List organizationsList organizations.
List projectsIf querying for projects within an organization, the logged-in user must be the owner of the organization.
List virtual machine operationsThis resource retrieves information about the status of asynchronous operations initiated by the instances resource.
List virtual machine typesList virtual machine types.
List virtual machinesList virtual machines.
Resize diskSize should be in gibibytes (GiB) or tebibytes (TiB) in the format [Size][Unit].
Update virtual machineUpdate virtual machine.

Create disk

Requires either a disk snapshot ID, or size and location, where size of disk should be in gibibytes (GiB) or tebibytes (TiB) in the format [Size][Unit]. E.g. 10GiB. Disk type must be one of: DISK_TYPE_PERSISTENT_SSD. A successful response from this resource will contain the…

Inputs

Projectproject_idtextRequired
ID of the project.
Block sizeblock_sizenumber
Block size for the new disk, in bytes: 512 or 4096.
Locationlocationtext
Location to create the disk in.
NamenametextRequired
Name for the new disk.
Sizesizetext
Storage capacity for the new disk, given as a size and unit in the format [Size][Unit], for example 100GiB or 1TiB.
Snapshot IDsnapshot_idtext
ID of a disk snapshot to create the disk from.
Typetypetext
Type of disk to create: persistent-ssd or shared-volume. Defaults to persistent-ssd.One of: persistent-ssd, shared-volume. Default: persistent-ssd.

Outputs

dataobject
AsyncOperationResponse is the response type for endpoints which return async operations.
Example output
{
  "data": {
    "operation": {
      "completed_at": "example",
      "operation_id": "example",
      "started_at": "example",
      "state": "example"
    }
  }
}

Create project

The logged-in user must have the permission to create projects within the organization. A successful response from this resource contains details of the created project.

Inputs

NamenametextRequired
Name for the new project.
Organizationorganization_idtextRequired
ID of the organization that will own the new project.

Outputs

dataobject
ProjectsPutPostResponseV1 is the response type for PUT and POST requests to the projects endpoint.
Example output
{
  "data": {
    "project": {
      "id": "example",
      "name": "example",
      "organization_id": "example",
      "relation": "example",
      "resources": {
        "disks": {
          "count": 1
        },
        "images": {
          "count": 1
        },
        "instances": {
          "count": 1
        },
        "snapshots": {
          "count": 1
        },
        "vpc_networks": {
          "count": 1
        }
      }
    }
  }
}

Create virtual machine

Create virtual machine.

Inputs

Projectproject_idtextRequired
ID of the project.
Crusoe watch agent install modecrusoe_watch_agent_install_modetext
Installation mode for the Crusoe Watch Agent: docker or native. Defaults to docker.One of: docker, native.
Custom imagecustom_imagetext
ID of a custom image to use for the new VM. Either image or custom_image should be supplied, not both.
Disksdiskslist
Disks to attach to the new VM.
Host channel adaptershost_channel_adapterslist
Host channel adapters to attach to the new VM.
Imageimagetext
Name of the OS image to use for the new VM. Either image or custom_image should be supplied, not both.
Install crusoe watch agentinstall_crusoe_watch_agenttrue/false
Whether to install the Crusoe Watch Agent on the VM. Defaults to true.
LocationlocationtextRequired
Location to create the VM in.
Maintenance policymaintenance_policytext
Host maintenance policy to apply to the new VM: manual, stop-vm, or unspecified.
NamenametextRequired
Name for the new VM.
Network interfacesnetwork_interfaceslist
Network interfaces to attach to the new VM.
Nvlink domain IDnvlink_domain_idtext
ID of the NVLink domain to create the VM in.
Reservation specificationreservation_specificationobject
Reservation specification.
Shutdown scriptshutdown_scripttext
Script to run when the VM shuts down.
SSH public keyssh_public_keytextRequired
SSH public key to grant access to the new VM.
Startup scriptstartup_scripttext
Script to run when the VM starts.
TypetypetextRequired
Product name of the VM type to create.
Virtualization featuresvirtualization_featuresobject
Virtualization features.

Outputs

dataobject
AsyncOperationResponse is the response type for endpoints which return async operations.
Example output
{
  "data": {
    "operation": {
      "completed_at": "example",
      "operation_id": "example",
      "started_at": "example",
      "state": "example"
    }
  }
}

Delete disk

A successful response from this resource will contain the async operation.

Inputs

Projectproject_idtextRequired
ID of the project that owns the disk.
Diskdisk_idtextRequired
ID of the disk.

Outputs

dataobject
AsyncOperationResponse is the response type for endpoints which return async operations.
Example output
{
  "data": {
    "operation": {
      "completed_at": "example",
      "operation_id": "example",
      "started_at": "example",
      "state": "example"
    }
  }
}

Delete virtual machine

Delete virtual machine.

Inputs

Projectproject_idtextRequired
ID of the project that owns the VM.
VMvm_idtextRequired
ID of the VM.

Outputs

dataobject
AsyncOperationResponse is the response type for endpoints which return async operations.
Example output
{
  "data": {
    "operation": {
      "completed_at": "example",
      "operation_id": "example",
      "started_at": "example",
      "state": "example"
    }
  }
}

Get current user

Get current user.

Inputs

None.

Outputs

dataobject
UserResponse is the return type from the GET and PUT handlers to User. The Identity of a user is returned.
Example output
{
  "data": {
    "identity": {
      "accepted_tos": false,
      "company_name": "example",
      "email": "example",
      "id": "example",
      "is_recovery": false,
      "managed_by": "example",
      "name": "example",
      "org_role": "example",
      "registration_type": "example",
      "role": "example",
      "role_bindings": [],
      "sso_enforcement": "example",
      "user_state": "example"
    }
  }
}

Get disk

Size of disk will be in gibibytes (GiB)

Inputs

Projectproject_idtextRequired
ID of the project that owns the disk.
Diskdisk_idtextRequired
ID of the disk.

Outputs

dataobject
Result.
Example output
{
  "data": {
    "attached_to": [],
    "block_size": 1,
    "created_at": "example",
    "dns_name": "example",
    "id": "example",
    "location": "example",
    "name": "example",
    "serial_number": "example",
    "size": "example",
    "type": "example",
    "updated_at": "example",
    "vips": []
  }
}

Get project

Get project.

Inputs

Projectproject_idtextRequired
ID of the project.

Outputs

dataobject
Project contains identifying information for a project.
Example output
{
  "data": {
    "id": "example",
    "name": "example",
    "organization_id": "example",
    "relation": "example",
    "resources": {
      "disks": {
        "count": 1
      },
      "images": {
        "count": 1
      },
      "instances": {
        "count": 1
      },
      "snapshots": {
        "count": 1
      },
      "vpc_networks": {
        "count": 1
      }
    }
  }
}

Get virtual machine

Get virtual machine.

Inputs

Projectproject_idtextRequired
ID of the project that owns the VM.
VMvm_idtextRequired
ID of the VM.

Outputs

dataobject
InstanceV1 contains identifying information about a vm instance for vms.instances endpoints.
Example output
{
  "data": {
    "billing_type": "example",
    "commitment_end": "example",
    "commitment_period": 1,
    "created_at": "example",
    "disks": [],
    "host_channel_adapters": [],
    "id": "example",
    "instance_group_id": "example",
    "instance_template_id": "example",
    "location": "example",
    "maintenance_policy": "example",
    "name": "example",
    "network_interfaces": [],
    "nvlink_domain_id": "example",
    "pod_id": "example",
    "project_id": "example",
    "reservation_id": "example",
    "state": "example",
    "type": "example",
    "unit_id": "example",
    "updated_at": "example",
    "virtualization_features": {
      "nested_virtualization": false
    },
    "waypoint_ids": []
  }
}

Get virtual machine operation

This resource retrieves information about the status of an asynchronous operation initiated by the instances resource. Only information about the operation specified in the path will be returned, or an HTTP 403 will be returned if the operation does not exist, was not…

Inputs

Projectproject_idtextRequired
ID of the project that owns the operation.
Operation IDoperation_idtextRequired
ID of the operation.

Outputs

dataobject
Operation contains the common fields for all Operation API objects. Individual resources that use Operations should populate the metadata field with resource-specific information.
Example output
{
  "data": {
    "completed_at": "example",
    "operation_id": "example",
    "started_at": "example",
    "state": "example"
  }
}

List disks

Size of disks will be in gibibytes (GiB)

Inputs

Projectproject_idtextRequired
ID of the project that owns the disks.
Disk IDSdisk_idslist
Filters results to disks with these IDs.
Locationlocationtext
Filters results to disks in this location.
Disk namesdisk_nameslist
Filters results to disks with these names.
Exclude osexclude_ostrue/false
Excludes OS disks from the results when true.

Outputs

dataobject
ListDisksResponseV1 is the response type for GET requests to the disks endpoint.
Example output
{
  "data": {
    "items": []
  }
}

List images

List images.

Inputs

Product groupproduct_grouptext
Optional filter to return only images compatible with the specified product group (e.g. "a100", "h100").
Product lineproduct_linetext
Optional filter to return only images compatible with the specified product line. an instance type without its size suffix (e.g. "h100-80gb-sxm-ib" for h100-80gb-sxm-ib.8x instances). Mutually exclusive with product_group.

Outputs

dataobject
ListImagesResponseV1 is the resource response type for GET requests to the Images endpoint.
Example output
{
  "data": {
    "items": []
  }
}

List locations

List locations.

Inputs

None.

Outputs

dataobject
Result.
Example output
{
  "data": {
    "items": []
  }
}

List organizations

List organizations.

Inputs

None.

Outputs

dataobject
ListEntitiesResponseV1 is the response type for GET requests to the entities endpoint.
Example output
{
  "data": {
    "items": []
  }
}

List projects

If querying for projects within an organization, the logged-in user must be the owner of the organization.

Inputs

Orgorg_idtext
Filters results to projects in this organization.
Project nameproject_nametext
Filters results to projects with this name.
Skip loading project resourcesskip_loading_project_resourcestrue/false
Whether to skip loading the resource counts for each project.

Outputs

dataobject
ListProjectsResponseV1 is the response type for GET requests to the projects endpoint.
Example output
{
  "data": {
    "items": []
  }
}

List virtual machine operations

This resource retrieves information about the status of asynchronous operations initiated by the instances resource. All operations that are either in-flight or completed but not yet queried will be returned.

Inputs

Resource IDresource_idtext
Filters results to operations on the resource with this ID.
Statestatelist
Filters results to operations in these states.
Lower time boundlower_time_boundtext
Lower time bound.
Projectproject_idtextRequired
ID of the project.

Outputs

dataobject
Result.
Example output
{
  "data": {
    "items": []
  }
}

List virtual machine types

List virtual machine types.

Inputs

Projectproject_idtextRequired
ID of the project.

Outputs

dataobject
Result.
Example output
{
  "data": {
    "items": []
  }
}

List virtual machines

List virtual machines.

Inputs

Projectproject_idtextRequired
ID of the project.
IDSidslist
Filters results to VMs with these IDs.
Namesnameslist
Filters results to VMs with these names.
Typestypeslist
Filters results to VMs of these types.
Locationslocationslist
Filters results to VMs in these locations.
Statesstateslist
Filters results to VMs in these states.
Nvlink domain IDSnvlink_domain_idslist
Filters results to VMs in these NVLink domains.
Limitlimitnumber
Maximum number of VMs to return per page.At least 1.
Sortsorttext
Field to sort the results by.
Next tokennext_tokentext
Token identifying the next page of results to return.
Prev tokenprev_tokentext
Token identifying the previous page of results to return.

Outputs

dataobject
ListInstancesResponseV1 is the response type for GET requests to /compute/vms/instances.
Example output
{
  "data": {
    "items": [],
    "next_page_token": "example",
    "prev_page_token": "example"
  }
}

Resize disk

Size should be in gibibytes (GiB) or tebibytes (TiB) in the format [Size][Unit]. E.g. 10GiB A successful response from this resource will contain the async operation.

Inputs

Projectproject_idtextRequired
ID of the project that owns the disk.
Diskdisk_idtextRequired
ID of the disk.
SizesizetextRequired
New storage capacity for the disk, given as a size and unit in the format [Size][Unit], for example 100GiB or 1TiB.

Outputs

dataobject
AsyncOperationResponse is the response type for endpoints which return async operations.
Example output
{
  "data": {
    "operation": {
      "completed_at": "example",
      "operation_id": "example",
      "started_at": "example",
      "state": "example"
    }
  }
}

Update virtual machine

Update virtual machine.

Inputs

Projectproject_idtextRequired
ID of the project that owns the VM.
VMvm_idtextRequired
ID of the VM.
Remote actionremote_actiontextRequired
Action to perform on the VM: START, STOP, RESET, RESERVE, UNRESERVE, or UPDATE. RESERVE and UNRESERVE operations are done synchronously, and so will have succeeded with a 200 response.One of: START, STOP, RESET, RESERVE, UNRESERVE, UPDATE.
Commitment periodcommitment_periodnumber
CommitmentPeriod is deprecated, please use reservationID instead
Host channel adaptershost_channel_adapterslist
New set of host channel adapters for the VM.
Maintenance policymaintenance_policytext
New host maintenance policy for the VM: manual, stop-vm, or unspecified.
Network interfacesnetwork_interfaceslist
New set of network interfaces for the VM.
Reservation IDreservation_idtext
ID of the reservation to use for the VM.
Typetypetext
New VM type to change the VM to.

Outputs

dataobject
AsyncOperationResponse is the response type for endpoints which return async operations.
Example output
{
  "data": {
    "operation": {
      "completed_at": "example",
      "operation_id": "example",
      "started_at": "example",
      "state": "example"
    }
  }
}

On this page