Skip to main content
PUT
/
api
/
v0
/
instances
/
prepay
/
{id}
prepay instance
curl --request PUT \
  --url https://console.vast.ai/api/v0/instances/prepay/{id}/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "amount": 500
}'
{
  "success": true,
  "timescale": 3.5,
  "discount_rate": 0.3
}

Documentation Index

Fetch the complete documentation index at: https://vastai-80aa3a82-fix-google-validation-docs-404s.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

API key must be provided in the Authorization header

Path Parameters

id
integer
required

ID of the instance to prepay for

Body

application/json
amount
number<float>
required

Amount of credits to prepay

Example:

500

Response

Successfully applied prepayment

success
boolean
Example:

true

timescale
number<float>

Number of months the prepayment will cover

Example:

3.5

discount_rate
number<float>

Applied discount rate (0.0-0.4)

Example:

0.3