vastai) is installed via pip install vastai — the same package exposes both the vastai command-line entry point and the Python SDK.
Every command supports a shared set of global options (shown under “Global options” in each command’s --help output):
| Option | Description |
|---|---|
--url URL | Server REST API URL |
--retry N | Retry limit |
--raw | Output machine-readable JSON |
--explain | Verbose explanation of API calls |
--curl | Print the equivalent curl command |
--api-key KEY | API key (defaults to ~/.config/vastai/vast_api_key) |
--no-color | Disable colored output |
--version | Show CLI version |
Command Index
Instances
| Command | Description |
|---|---|
vastai show instance | Display user’s current instances |
vastai show instances | List instances with filtering, sorting, and pagination |
vastai create instance | Create a new instance |
vastai create instances | Create instances from a list of offers |
vastai destroy instance | Destroy an instance (irreversible, deletes data) |
vastai destroy instances | Destroy a list of instances (irreversible, deletes data) |
vastai start instance | Start a stopped instance |
vastai start instances | Start a list of instances |
vastai stop instance | Stop a running instance |
vastai stop instances | Stop a list of instances |
vastai reboot instance | Reboot (stop/start) an instance |
vastai recycle instance | Recycle (destroy/create) an instance |
vastai update instance | Update recreate an instance from a new/updated template |
vastai label instance | Assign a string label to an instance |
vastai prepay instance | Deposit credits into reserved instance |
vastai change bid | Change the bid price for a spot/interruptible instance |
vastai launch instance | Launch the top instance from the search offers based on the given parameters |
vastai execute | Execute a (constrained) remote command on a machine |
vastai logs | Get the logs for an instance |
vastai attach ssh | Attach an ssh key to an instance. This will allow you to connect to the instance with the ssh key |
vastai detach ssh | Detach an ssh key from an instance |
vastai ssh-url | ssh url helper |
vastai scp-url | scp url helper |
vastai copy | Copy directories between instances and/or local |
vastai cloud copy | Copy files/folders to and from cloud providers |
vastai cancel copy | Cancel a remote copy in progress, specified by DST id |
vastai cancel sync | Cancel a remote copy in progress, specified by DST id |
vastai show connections | Display user’s cloud connections |
vastai take snapshot | Schedule a snapshot of a running container and push it to your repo in a container registry |
Search & Templates
| Command | Description |
|---|---|
vastai search offers | Search for instance types using custom query |
vastai search benchmarks | Search for benchmark results using custom query |
vastai search templates | Search for template results using custom query |
vastai search invoices | Search for invoices using custom query |
vastai search volumes | Search for volume offers using custom query |
vastai search network-volumes | Search for network volume offers using custom query |
vastai create template | Create a new template |
vastai update template | Update an existing template |
vastai delete template | Delete a Template |
Volumes
| Command | Description |
|---|---|
vastai create volume | Create a new volume |
vastai create network-volume | Create a new network volume |
vastai delete volume | Delete a volume |
vastai clone volume | Clone an existing volume |
vastai show volumes | Show stats on owned volumes. |
vastai list volume | [Host] list disk space for rent as a volume on a machine |
vastai list volumes | [Host] list disk space for rent as a volume on machines |
vastai list network-volume | [Host] list disk space for rent as a network volume |
vastai unlist volume | [Host] unlist volume offer |
vastai unlist network-volume | [Host] Unlists network volume offer |
Serverless
| Command | Description |
|---|---|
vastai create endpoint | Create a new endpoint group |
vastai show endpoints | Display user’s current endpoint groups |
vastai update endpoint | Update an existing endpoint group |
vastai delete endpoint | Delete an endpoint group |
vastai get endpt-logs | Fetch logs for a specific serverless endpoint group |
vastai create workergroup | Create a new autoscale group |
vastai show workergroups | Display user’s current workergroups |
vastai update workergroup | Update an existing autoscale group |
vastai update workers | Trigger a rolling update of all workers in a workergroup, or cancel an in-progress update |
vastai delete workergroup | Delete a workergroup group |
vastai get wrkgrp-logs | Fetch logs for a specific serverless worker group |
vastai show deployments | Display user’s current deployments |
vastai show deployment | Display a single deployment |
vastai delete deployment | Delete a deployment by id, or by name and optional tag |
Teams
| Command | Description |
|---|---|
vastai create team | Create a new team |
vastai destroy team | Destroy your team |
vastai create team-role | Add a new role to your team |
vastai show team-role | Show your team role |
vastai show team-roles | Show roles for a team |
vastai update team-role | Update an existing team role |
vastai remove team-role | Remove a role from your team |
vastai invite member | Invite a team member |
vastai show members | Show your team members |
vastai remove member | Remove a team member |
Accounts & Keys
| Command | Description |
|---|---|
vastai create api-key | Create a new api-key with restricted permissions. Can be sent to other users and teammates |
vastai show api-keys | List your api-keys associated with your account |
vastai delete api-key | Remove an api-key |
vastai set api-key | Set api-key (get your api-key from the console/CLI) |
vastai create ssh-key | Create a new ssh-key |
vastai show ssh-keys | List your ssh keys associated with your account |
vastai delete ssh-key | Remove an ssh-key |
vastai update ssh-key | Update an existing SSH key |
vastai show user | Get current user data |
vastai set user | Update user data from json file |
vastai show subaccounts | Get current subaccounts |
vastai create subaccount | Create a subaccount |
vastai show ipaddrs | Display user’s history of ip addresses |
vastai show audit-logs | Display account’s history of important actions |
vastai show env-vars | Show user environment variables |
vastai create env-var | Create a new user environment variable |
vastai update env-var | Update an existing user environment variable |
vastai delete env-var | Delete a user environment variable |
vastai transfer credit | Transfer credits to another account |
vastai show scheduled-jobs | Display the list of scheduled jobs |
vastai delete scheduled-job | Delete a scheduled job |
vastai tfa activate | Activate a new 2FA method by verifying the code |
vastai tfa delete | Remove a 2FA method from your account |
vastai tfa login | Complete 2FA login by verifying code |
vastai tfa resend-sms | Resend SMS 2FA code |
vastai tfa regen-codes | Regenerate backup codes for 2FA |
vastai tfa send-sms | Request a 2FA SMS verification code |
vastai tfa send-email | Request a 2FA Email verification code |
vastai tfa auth-new | Authorize your account to add a new 2FA method |
vastai tfa status | Shows the current 2FA status and configured methods |
vastai tfa totp-setup | Generate TOTP secret and QR code for Authenticator app setup |
vastai tfa update | Update a 2FA method’s settings |
Billing
| Command | Description |
|---|---|
vastai show invoices | Get billing (invoices/charges) history reports with advanced filtering and pagination |
vastai show earnings | Get machine earning history reports |
vastai show deposit | Display reserve deposit info for an instance |
Host
| Command | Description |
|---|---|
vastai show machine | [Host] Show hosted machines |
vastai show machines | [Host] Show hosted machines |
vastai show maints | [Host] Show maintenance information for host machines |
vastai show network-disks | [Host] Show network disks associated with your account. |
vastai list machine | [Host] list a machine for rent |
vastai list machines | [Host] list machines for rent |
vastai unlist machine | [Host] Unlist a listed machine |
vastai delete machine | [Host] Delete machine if the machine is not being used by clients. host jobs on their own machines are disregarded and machine is force deleted. |
vastai cleanup machine | [Host] Remove all expired storage instances from the machine, freeing up space |
vastai defrag machines | [Host] Defragment machines |
vastai set min-bid | [Host] Set the minimum bid/rental price for a machine |
vastai set defjob | [Host] Create default jobs for a machine |
vastai remove defjob | [Host] Delete default jobs |
vastai schedule maint | [Host] Schedule upcoming maint window |
vastai cancel maint | [Host] Cancel maint window |
vastai add network-disk | [Host] Add Network Disk to Physical Cluster. |
vastai self-test machine | [Host] Perform a self-test on the specified machine |
vastai reports | Get the user reports for a given machine |
Misc
| Command | Description |
|---|---|
vastai benchmark | Compare GPU perf/cost using live marketplace data |
Commands
Instances
show instance
Display user’s current instancesText
show instances
List instances with filtering, sorting, and paginationText
create instance
Create a new instanceText
create instances
Create instances from a list of offersText
destroy instance
Destroy an instance (irreversible, deletes data)Text
destroy instances
Destroy a list of instances (irreversible, deletes data)Text
start instance
Start a stopped instanceText
start instances
Start a list of instancesText
stop instance
Stop a running instanceText
stop instances
Stop a list of instancesText
reboot instance
Reboot (stop/start) an instanceText
recycle instance
Recycle (destroy/create) an instanceText
update instance
Update recreate an instance from a new/updated templateText
label instance
Assign a string label to an instanceText
prepay instance
Deposit credits into reserved instanceText
change bid
Change the bid price for a spot/interruptible instanceText
launch instance
Launch the top instance from the search offers based on the given parametersText
execute
Execute a (constrained) remote command on a machineText
logs
Get the logs for an instanceText
attach ssh
Attach an ssh key to an instance. This will allow you to connect to the instance with the ssh keyText
detach ssh
Detach an ssh key from an instanceText
ssh-url
ssh url helperText
scp-url
scp url helperText
copy
Copy directories between instances and/or localText
cloud copy
Copy files/folders to and from cloud providersText
cancel copy
Cancel a remote copy in progress, specified by DST idText
cancel sync
Cancel a remote copy in progress, specified by DST idText
show connections
Display user’s cloud connectionsText
take snapshot
Schedule a snapshot of a running container and push it to your repo in a container registryText
Search & Templates
search offers
Search for instance types using custom queryText
search benchmarks
Search for benchmark results using custom queryText
search templates
Search for template results using custom queryText
search invoices
Search for invoices using custom queryText
search volumes
Search for volume offers using custom queryText
search network-volumes
Search for network volume offers using custom queryText
create template
Create a new templateText
update template
Update an existing templateText
delete template
Delete a TemplateText
Volumes
create volume
Create a new volumeText
create network-volume
Create a new network volumeText
delete volume
Delete a volumeText
clone volume
Clone an existing volumeText
show volumes
Show stats on owned volumes.Text
list volume
[Host] list disk space for rent as a volume on a machineText
list volumes
[Host] list disk space for rent as a volume on machinesText
list network-volume
[Host] list disk space for rent as a network volumeText
unlist volume
[Host] unlist volume offerText
unlist network-volume
[Host] Unlists network volume offerText
Serverless
create endpoint
Create a new endpoint groupText
show endpoints
Display user’s current endpoint groupsText
update endpoint
Update an existing endpoint groupText
delete endpoint
Delete an endpoint groupText
get endpt-logs
Fetch logs for a specific serverless endpoint groupText
create workergroup
Create a new autoscale groupText
show workergroups
Display user’s current workergroupsText
update workergroup
Update an existing autoscale groupText
update workers
Trigger a rolling update of all workers in a workergroup, or cancel an in-progress updateText
delete workergroup
Delete a workergroup groupText
get wrkgrp-logs
Fetch logs for a specific serverless worker groupText
show deployments
Display user’s current deploymentsText
show deployment
Display a single deploymentText
delete deployment
Delete a deployment by id, or by name and optional tagText
Teams
create team
Create a new teamText
destroy team
Destroy your teamText
create team-role
Add a new role to your teamText
show team-role
Show your team roleText
show team-roles
Show roles for a teamText
update team-role
Update an existing team roleText
remove team-role
Remove a role from your teamText
invite member
Invite a team memberText
show members
Show your team membersText
remove member
Remove a team memberText
Accounts & Keys
create api-key
Create a new api-key with restricted permissions. Can be sent to other users and teammatesText
show api-keys
List your api-keys associated with your accountText
delete api-key
Remove an api-keyText
set api-key
Set api-key (get your api-key from the console/CLI)Text
create ssh-key
Create a new ssh-keyText
show ssh-keys
List your ssh keys associated with your accountText
delete ssh-key
Remove an ssh-keyText
update ssh-key
Update an existing SSH keyText
show user
Get current user dataText
set user
Update user data from json fileText
show subaccounts
Get current subaccountsText
create subaccount
Create a subaccountText
show ipaddrs
Display user’s history of ip addressesText
show audit-logs
Display account’s history of important actionsText
show env-vars
Show user environment variablesText
create env-var
Create a new user environment variableText
update env-var
Update an existing user environment variableText
delete env-var
Delete a user environment variableText
transfer credit
Transfer credits to another accountText
show scheduled-jobs
Display the list of scheduled jobsText
delete scheduled-job
Delete a scheduled jobText
tfa activate
Activate a new 2FA method by verifying the codeText
tfa delete
Remove a 2FA method from your accountText
tfa login
Complete 2FA login by verifying codeText
tfa resend-sms
Resend SMS 2FA codeText
tfa regen-codes
Regenerate backup codes for 2FAText
tfa send-sms
Request a 2FA SMS verification codeText
tfa send-email
Request a 2FA Email verification codeText
tfa auth-new
Authorize your account to add a new 2FA methodText
tfa status
Shows the current 2FA status and configured methodsText
tfa totp-setup
Generate TOTP secret and QR code for Authenticator app setupText
tfa update
Update a 2FA method’s settingsText
Billing
show invoices
Get billing (invoices/charges) history reports with advanced filtering and paginationText
show earnings
Get machine earning history reportsText
show deposit
Display reserve deposit info for an instanceText
Host
show machine
[Host] Show hosted machinesText
show machines
[Host] Show hosted machinesText
show maints
[Host] Show maintenance information for host machinesText
show network-disks
[Host] Show network disks associated with your account.Text
list machine
[Host] list a machine for rentText
list machines
[Host] list machines for rentText
unlist machine
[Host] Unlist a listed machineText
delete machine
[Host] Delete machine if the machine is not being used by clients. host jobs on their own machines are disregarded and machine is force deleted.Text
cleanup machine
[Host] Remove all expired storage instances from the machine, freeing up spaceText
defrag machines
[Host] Defragment machinesText
set min-bid
[Host] Set the minimum bid/rental price for a machineText
set defjob
[Host] Create default jobs for a machineText
remove defjob
[Host] Delete default jobsText
schedule maint
[Host] Schedule upcoming maint windowText
cancel maint
[Host] Cancel maint windowText
add network-disk
[Host] Add Network Disk to Physical Cluster.Text
self-test machine
[Host] Perform a self-test on the specified machineText
reports
Get the user reports for a given machineText
Misc
benchmark
Compare GPU perf/cost using live marketplace dataText