Skip to content
eSIMTrade
Log inSign up
Skip to content

eSIMTrade Docs

Public API

api.esimtrade.com

cURL
JavaScript
HTTP
JSON

Clear, practical reseller API documentation.

Start with authentication, check your wallet balance, review plans, and then work with orders and inventory. Each endpoint page explains its authentication, request fields, response shape, and copyable examples.

Fast scan
Live route coverage
Copyable examples
Orders
API key or session
POST

Create Order

Place a reseller purchase using your account price and prepaid wallet, with idempotency support.

Endpoint

POST /portal/order

Endpoint behavior

Submit a plan slug and quantity to place an order. Your account price and available wallet balance are checked, and the response includes the purchase result.

If you send an idempotencyKey and retry the same purchase, the API can return the original result instead of placing a duplicate order.

Body fieldTypeRequiredDescription
slugstringYesPlan slug from the plans response
qtynumberNoQuantity, defaults to 1
daysnumberNoOptional provider-specific period value
idempotencyKeystringRecommendedStable client retry key

Insufficient wallet balance returns HTTP 402. Duplicate idempotent purchase conflicts can return HTTP 409.

Create order

cURL
curl --location --request POST 'https://api.esimtrade.com/api/v1/portal/order' \
--header 'x-access-code: YOUR_ACCESS_CODE' \
--header 'x-secret-key: YOUR_SECRET_KEY' \
--header 'Content-Type: application/json' \
--data '{
  "slug": "japan-5gb-30days",
  "qty": 1,
  "idempotencyKey": "order-20260417-001"
}'

Validation error example

JSON
{
  "error": "Invalid quantity"
}

Base URL

https://api.esimtrade.com/api/v1

Open on API host

On this page