# eSIM Profiles

An eSIM profile allows access to the mobile data network. The user can install an eSIM using different methods on an eSIM-capable smartphone:

* Scan the Activation Code
* Direct Installation (without a QR code)

To use the **Direct Installation**, please integrate our SDKs, see [master](https://docs.giga.store/technical-integration/master "mention").&#x20;

### eSIM API Object

Each eSIM profile comes with&#x20;

* **uid** - identitier;  used for SDK eSIM download
* **ICCID** - main identifier for end-user support
* **activationCode** - used to install the eSIM
* **IMSI, lastSeen, activatedAt** - additional identifiers for support
* **state** - current state (e.g. INSTALLED)

```
{
    "iccid": "89972123300991848961",
    "imsi": "260060145143896",
    "activationCode": "LPA:1$domain.tld$1234567890ABCDEF123456",
    "appleUniversalLink": "https://esimsetup.apple.com/esim_qrcode_provisioning?carddata=LPA:1$<SM-DP+ Address>$<Activation Code>",
    "installationUrl": "https://dent.giga.store#/esim/profile?token=eyJhbGciOiJIUzUxMiJ9.eyJzdWIiOiI4OTk3MjEyMzMwMDk5MTg0ODk2MSJ9.V34vHdqG6QD9iyCLjIfh2zxsv5MUUjEaOkSw3EY_RVJAxhQQfTeZBfEL_EYwAS9TMNi_Rn6L2Q2cuuI8Ve9zmQ",
    "lastSeen": null,
    "activatedAt": null,
    "state": "RELEASED",
    "uid": "7555cab8-72bc-4e85-b56a-6cdf60e2d6e4",
    "active": true
}
```

### Providing QR code for installation

Once the [first-package](https://docs.giga.store/api/first-package "mention") is activated, the returned eSIM can be used to provide a QR code for installing the eSIM.&#x20;

You can use any QR code renderer to generate a QR code using the `activationCode` and provide it to your user via email or through other channels.

The QR code must be scanned with an eSIM-capable device, like an iPhone 14.

<figure><img src="https://744070168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-M_06ID1EGDSaSa9MhQE%2Fuploads%2FfdfGbylEFD1Bp8nESGQf%2FScreenshot%202024-04-30%20at%2012.25.41.png?alt=media&#x26;token=df2fdc0d-bbf0-4468-83b6-b3b3f29f1357" alt="" width="251"><figcaption><p>Example QR code of <br>LPA:1$domain.tld$1234567890ABCDEF123456</p></figcaption></figure>

<figure><img src="https://744070168-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-M_06ID1EGDSaSa9MhQE%2Fuploads%2F745SioAXW3VBN1l7EE5V%2FIMG_9847.PNG?alt=media&#x26;token=432e8b33-24dc-48a7-8788-0e6c6ce81a9c" alt="" width="188"><figcaption><p>iPhone identifies the code as "Mobile Plan"</p></figcaption></figure>

### eSIM States

An eSIM can have different states. You can use the eSIM state to guide the user during your user journey.

| State     | Meaning                                         | Comment                                       |
| --------- | ----------------------------------------------- | --------------------------------------------- |
| RELEASED  | Not installed on a device                       | Profile ready to be downloaded and installed  |
| DISABLED  | Installed, but user disabled the eSIM in the OS | Not available for all eSIM profiles / devices |
| INSTALLED | Installed and enabled                           |                                               |
| ERROR     | Something went wrong during installation        | Contact support to replace the profile.       |

To receive status updates, use the [esim-status](https://docs.giga.store/webhooks/esim-status "mention") webhook. The webhook is triggered within a few seconds after the user interaction.
