Getting started
Getting started with an eSIM API.
A first integration has three moves: keep an API key on the server, request a fulfilment for a plan, and give the installation details to the person who needs them.
Code and responses on this page are illustrative. They show the shape of an integration. Confirm the production schema in your Cuppa account before you ship.
Before the first call
You need a Cuppa business account and an API key created in the dashboard. The key belongs in your server environment. A mobile app or a browser should call your backend, not Cuppa, with that key.
Request a fulfilment
Send the plan you intend to provision and a reference from your own system. The reference is how you will find this eSIM again when a webhook arrives or when someone asks about a booking.
POST /v1/fulfilments
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json
{
"product_id": "example_plan",
"reference": "booking_4821"
}Read the installation details
A successful example returns an identifier, a status and the eSIM installation details. Store them against your reference. Show the installation steps in your own interface.
HTTP/1.1 201 Created
{
"id": "ful_example",
"status": "provisioned",
"product_id": "example_plan",
"reference": "booking_4821",
"esim": {
"iccid": "8900000000000000000",
"activation_code": "LPA:1$example$CODE"
}
}