eSIM
POST/v1/esim/orders
Order an eSIM — who pays follows your key
What this call does depends on the settlement mode of the key you present, and on nothing else. It is not a choice per request: sending settlement in the body is a CHECK, and a value that contradicts your key is refused rather than obeyed.
**partner settlement (mode A).** You are the merchant. We reserve the net price on your account, order from the supplier, then charge what was actually due — three steps, inside this one call. If the supplier declines, the reservation is released and you are not charged. You get the eSIM back provisioned, checkout is null, and you have already invoiced your own customer.
**vacabee settlement (mode B).** WE are the merchant and your TRAVELLER pays us. Your account is never touched — there is no reservation, no charge and no 402. The order comes back at AWAITING_PAYMENT with a checkout.url: send your traveller there. Nothing is bought at the supplier until he has paid, so nothing is held for him either — the link carries a price with a deadline, and letting it run out is an ordinary outcome, not a fault. You are told either way through the esim.provisioned / esim.failed webhooks.
402 insufficient_funds and 403 account_not_active can only reach a partner key: they are answers about an account that mode B does not use.
- Auth
- API key
- Scope
- esim:order
- Rate limit
- BOOKING
- Search quota
- Free
- Idempotency
- Idempotency-Key
Request headers
Request body
CreateEsimOrderDto — required, sent as application/json.
Responses
201 · EsimOrderDto
Errors
Every one of these carries the same envelope. What each error.type means, and whether a retry can succeed, is on the error index — once, for all operations.
Response headers
Set on every response of this operation, successful or not.
Example
curl -sS -X POST "$VACABEE_API_URL/v1/esim/orders" \
-H "Authorization: Bearer $VACABEE_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"planId": "plan_01J8…",
"externalReference": "order-2026-0915-abc",
"customer": {
"firstName": "Ada",
"lastName": "Lovelace",
"email": "ada@example.com"
}
}'Set VACABEE_API_URL to https://api.vacabee.com with a live key, or to https://sandbox-api.vacabee.com with a vcb_test_ key. Binding a host to one kind of key is planned and is not enforced by the host yet, so nothing stops a key from being answered at the wrong base URL — assert the prefix against your configured URL yourself. What the sandbox answers
TypeScript SDK
await vacabee.esim.order(…);The typed method sends the right headers, derives the idempotency key where one is required, and returns the response type generated from this document. Installing and using the SDK

