Skip to main content
Search for invoices using custom query

Usage

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

Arguments

query
string
required
Search query in simple query syntax (see below)

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 somewhat reliable single RTX 3090 instances, filter out any duplicates or offers that conflict with our existing stopped instances
        vastai search invoices 'amount_cents>3000  '

    Available fields:

  Name                  Type       Description

id                  int,
user_id             int,
when                float,          utc epoch timestamp of initial invoice creation
paid_on             float,          actual payment date (utc epoch timestamp )
payment_expected    float,          expected payment date (utc epoch timestamp )
amount_cents        int,            amount of payment in cents
is_credit           bool,           is a credit purchase
is_delayed          bool,           is not yet paid
balance_before      float,          balance before
balance_after       float,          balance after
original_amount     int,            original amount of payment
event_id            string,
cut_amount          int,
cut_percent         float,
extra               json,
service             string,         type of payment
stripe_charge       json,
stripe_refund       json,
stripe_payout       json,
error               json,
paypal_email        string,         email for paypal/wise payments
transfer_group      string,
failed              bool,
refunded            bool,
is_check            bool,

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)