veil

Request a first-version salt ticket

Commit the server’s half of the first-version salt before the device chooses its half.

POST/v1/salt-tickets
Access
Creates temporary data
Client
Local or server client

Request examples#

cURL
curl -fsS -X POST 'https://veil.rip/v1/salt-tickets'

Response#

HTTP 201application/json

201 with ticket, serverSalt and expiresAt. The ticket lasts ten minutes, is used once and can be lost on restart.

FieldTypeMeaning
ticketstringSingle-use opaque ticket.
serverSaltstringServer’s 16-byte salt contribution in hex.
expiresAtstringTicket expiry time.

Response headers#

HeaderValueMeaning
Content-Typeapplication/jsonUse the declared media type before choosing a parser.
DateHTTP dateServer time. Compare it with your clock when signing requests.
Cache-Controlno-storeDo not persist private or temporary responses in a shared cache.
Retry-Afterinteger seconds, on rate_limited or busyWait at least this long before retrying. Other 429/503 codes do not necessarily include it.

Errors#

API errors return an error object. Use error.code for program logic; error.message is English text for people and can change. Response and error guide

HTTPCodeMeaning and next step
400invalid_json

The body is not a JSON object, contains duplicate keys or has trailing data.

Send one valid JSON object with Content-Type application/json.

413payload_too_large

The request body exceeds this endpoint’s byte limit.

Reduce the encoded body. API-key management accepts at most 8 KiB.

Shared request errors
HTTPCodeMeaning and next step
429rate_limited

An anonymous, signed-request or API-key allowance was exceeded.

Wait at least Retry-After seconds. Share a queue and retry budget across your workers.

500internal_error

An unexpected server error occurred. Internal details are not returned.

Retry reads with bounded backoff. Check write results before sending a new signed operation.

503busy

The application has reached a temporary concurrency or database limit.

Wait Retry-After seconds and retry with bounded backoff.