v1

latestOpenAPI 3.1.02026-07-13897404.3 KB
Accounts

update env var

Updates the value of an existing environment variable for the authenticated user.

CLI Usage: vastai update env-var <key> <value>

put/api/v0/secrets/

Request body

keystring required

The key of the environment variable to update (will be converted to uppercase)

valuestring required

The new value for the environment variable

Example request

{
  "key": "MY_API_KEY",
  "value": "xyz123"
}

Response

Environment variable updated successfully

successboolean
msgstring

Example response

{
  "success": true,
  "msg": "Environment variable updated successfully"
}