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
  • Wrap > and < in quotes on the command line
  • For string values (e.g. gpu_name), replace spaces with underscores: RTX_3090 not RTX 3090

Examples

vastai search invoices 'amount_cents>3000'

Available Fields

FieldTypeDescription
idintinvoice unique ID
user_idintuser ID
whenfloatUTC epoch timestamp of initial invoice creation
paid_onfloatactual payment date (UTC epoch timestamp)
payment_expectedfloatexpected payment date (UTC epoch timestamp)
amount_centsintamount of payment in cents
is_creditboolis a credit purchase
is_delayedboolis not yet paid
balance_beforefloatbalance before payment
balance_afterfloatbalance after payment
original_amountintoriginal amount of payment
event_idstringassociated event ID
cut_amountintcut amount
cut_percentfloatcut percentage
extrajsonextra metadata
servicestringtype of payment
stripe_chargejsonStripe charge object
stripe_refundjsonStripe refund object
stripe_payoutjsonStripe payout object
errorjsonerror details if any
paypal_emailstringemail for PayPal/Wise payments
transfer_groupstringtransfer group identifier
failedboolpayment failed
refundedboolpayment refunded
is_checkboolis a check payment

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)