Skip to main content
Search for volume offers using custom query

Usage

vastai search volumes [--help] [--api-key API_KEY] [--raw] <query>

Arguments

query
string
required
Query to search for. default: ‘external=false verified=true disk_space>=1’, pass -n to ignore default

Options

-n
boolean
Disable default query (alias: --no-default)
--limit
integer
--storage
number
default:"1.0"
Amount of storage to use for pricing, in GiB. default=1.0GiB
-o
string
default:"score-"
Comma-separated list of fields to sort on. postfix field with - to sort desc. ex: -o ‘disk_space,inet_up-’. default=‘score-’ (alias: --order)

Description

Query syntax: query = comparison comparison… comparison = field op value field = <name of a field> op = one of: <, <=, ==, !=, >=, >, in, notin value = <bool, int, float, string> | ‘any’ | [value0, value1, …] bool: True, False note: to pass ’>’ and ’<’ on the command line, make sure to use quotes note: to encode a string query value (ie for gpu_name), replace any spaces ’ ’ with underscore ’_‘

Examples

# search for volumes with greater than 50GB of available storage and greater than 500 Mb/s upload and download speed
    vastai search volumes "disk_space>50 inet_up>500 inet_down>500"

Available fields:

      Name                  Type       Description

    cpu_arch:               string    host machine cpu architecture (e.g. amd64, arm64)
    cuda_vers:              float     machine max supported cuda version (based on driver version)
    datacenter:             bool      show only datacenter offers
    disk_bw:                float     disk read bandwidth, in MB/s
    disk_space:             float     disk storage space, in GB
    driver_version:         string    machine's nvidia/amd driver version as 3 digit string ex. "535.86.05"
    duration:               float     max rental duration in days
    geolocation:            string    Two letter country code. Works with operators =, !=, in, notin (e.g. geolocation not in ['XV','XZ'])
    gpu_arch:               string    host machine gpu architecture (e.g. nvidia, amd)
    gpu_name:               string    GPU model name (no quotes, replace spaces with underscores, ie: RTX_3090 rather than 'RTX 3090')
    has_avx:                bool      CPU supports AVX instruction set.
    id:                     int       volume offer unique ID
    inet_down:              float     internet download speed in Mb/s
    inet_up:                float     internet upload speed in Mb/s
    machine_id:             int       machine id of volume offer
    pci_gen:                float     PCIE generation
    pcie_bw:                float     PCIE bandwidth (CPU to GPU)
    reliability:            float     machine reliability score (see FAQ for explanation)
    storage_cost:           float     storage cost in $/GB/month
    static_ip:              bool      is the IP addr static/stable
    total_flops:            float     total TFLOPs from all GPUs
    ubuntu_version:         string    host machine ubuntu OS version
    verified:               bool      is the machine verified

Global Options

The following options are available for all commands:
OptionDescription
--url URLServer REST API URL
--retry NRetry limit
--rawOutput machine-readable JSON
--explainVerbose explanation of API calls
--api-key KEYAPI key (defaults to ~/.config/vastai/vast_api_key)