Buy an eSIM
purchase_esimBuy an eSIM data plan with a user-approved max price and immediate balance charge; no cancellation after issue. Returns eSIM ID and install details, or a new price if higher.
Instructions
Buy an eSIM data plan, charged to your balance immediately. It cannot be cancelled through this server once issued. Requires max_price_cents: the price from search_esim_plans that you showed the user and they approved; if the price is now higher, nothing is charged and the new price comes back to re-confirm. Returns the esim_ id with install details (LPA string, SM-DP+ address, activation code); if it is still processing, poll get_esim_status. get_esim_status with include_qr=true returns the QR image.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"plan_id": "<plan_id>",
"max_price_cents": "<max_price_cents>"
},
"name": "purchase_esim"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| plan_id | Yes | prod_... id from search_esim_plans | |
| max_price_cents | Yes | The price you showed the user and they approved, in US cents (e.g. 250 = $2.50). Nothing is charged if the current price is higher; the new price comes back so you can ask the user again. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| esim | Yes |