Buy a travel eSIM
buy_esimStarts the purchase of one eSIM plan for the customer and returns a payment link. Pay it with the Machine Payments Protocol (HTTP 402, Stripe shared payment token) to complete the order. Before calling, confirm the plan, the price and the email with the customer, and get their agreement to the terms: By buying, the customer asks for the eSIM to be sent at once and accepts the terms (https://inboxesim.com/terms): the 14-day right to withdraw ends once the eSIM is installed. An eSIM that was never installed or used can be refunded within 30 days from its order page, less the payment fee (no card fee within 14 days in the EU and UK).
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>",
"customer_email": "<customer_email>",
"customer_agreed_to_terms": "<customer_agreed_to_terms>"
},
"name": "buy_esim"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| plan_id | Yes | A plan_id from find_esim_plans, e.g. 'japan-5gb-30d'. | |
| customer_email | Yes | Where the QR code and install link are sent. | |
| customer_agreed_to_terms | Yes | true only if the customer accepted the terms quoted in this tool's description. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| plan | Yes | ||
| status | Yes | ||
| message | No | ||
| page_url | No | ||
| amount_usd | No | ||
| how_to_pay | No | ||
| payment_link | No | POST here and answer the HTTP 402 challenge. | |
| browser_fallback | No |