eSIM usage

Get esim data usage

URL

Request Method

  • POST

Rate Limit

  • 5 requests per second

Request Header

Header NameOptionalValue
content-typeyesapplication/json
appIdyesYour app ID
timestampyesCurrent timestamp
signyesHMAC-SHA256 signature

Request Examples

curl --location 'http://sandbox-api.yoni-esim.com/v1/order/e-sim/flow' \
--header 'appId: {{appId}}' \
--header 'timestamp: {{timestamp}}' \
--header 'sign: {{sign}}' \
--header 'Content-Type: application/json' \
--data '{
   "orderNo":"20260324162xxxxxx",
   "iccid":"8910010000xxxxxx"
}'
OkHttpClient client = new OkHttpClient().newBuilder()
  .build();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType, "{\r\n   \"orderNo\":\"20260324162xxxxxx\",\r\n   \"iccid\":\"8910010000xxxxxx\"\r\n}");
Request request = new Request.Builder()
  .url("http://sandbox-api.yoni-esim.com/v1/order/e-sim/flow")
  .method("POST", body)
  .addHeader("appId", "{{appId}}")
  .addHeader("timestamp", "{{timestamp}}")
  .addHeader("sign", "{{sign}}")
  .addHeader("Content-Type", "application/json")
  .build();
Response response = client.newCall(request).execute();
var request = require('request');
var options = {
  'method': 'POST',
  'url': 'http://sandbox-api.yoni-esim.com/v1/order/e-sim/flow',
  'headers': {
    'appId': '{{appId}}',
    'timestamp': '{{timestamp}}',
    'sign': '{{sign}}',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    "orderNo": "20260324162xxxxxx",
    "iccid": "8910010000xxxxxx"
  })

};
request(options, function (error, response) {
  if (error) throw new Error(error);
  console.log(response.body);
});
import requests
import json

url = "http://sandbox-api.yoni-esim.com/v1/order/e-sim/flow"

payload = json.dumps({
  "orderNo": "20260324162xxxxxx",
  "iccid": "8910010000xxxxxx"
})
headers = {
  'appId': '{{appId}}',
  'timestamp': '{{timestamp}}',
  'sign': '{{sign}}',
  'Content-Type': 'application/json'
}

response = requests.request("POST", url, headers=headers, data=payload)

print(response.text)

Response Example

{
    "code": 0,
    "data": {
        "total": "1024",
        "usage": "407.00"
    },
    "msg": "success"
}

Response Result

NameTypeDescription
codeStringeSIM response code (error codes)
msgStringResult description
dataObjectObject containing usage information
data.totalStringTotal data allowance
data.usageStringData used