Legacy eSIM activation endpoints. For new integrations use API v2.
Header required in all requests:
Authorization: Bearer <your_token>
Prefix: /api/v1/activate/esim. Requires acceso_srcm permission.
/api/v1/activate/esim
Requests the activation of an eSIM using customer's data.
Body (JSON):
{
"selected_plan": "string",
"customer_name": "string",
"customer_surname1": "string",
"customer_surname2": "string",
"customer_document_type_id": "string",
"customer_document_number": "string",
"customer_birthdate": "YYYY-MM-DD",
"customer_sex": "H | M",
"customer_nationality_id": "string"
}
Body fields:
| Field | Type | Description |
|---|---|---|
| selected_plan | string | Plan ID (required) |
| customer_name | string | Customer first name (required) |
| customer_surname1 | string | First surname (required) |
| customer_surname2 | string | Second surname (optional, defaults to surname1) |
| customer_document_type_id | string | Document type ID (required) |
| customer_document_number | string | Document number (required) |
| customer_birthdate | string | Birth date YYYY-MM-DD (required) |
| customer_sex | string | "H" (male) or "M" (female) (required) |
| customer_nationality_id | string | Nationality ID (required) |
Response:
{
"data": {
"iccid": "8934071234123456789",
"phone": "123456789",
"activationCode": "C0D123456789B123AC1234567F123E4E",
"qrCode": "LPA:1$sm-...",
"confirmationCode": "123456",
"plan_name": "Prepago Travel M",
"selected_plan": "14",
"amount": 15,
"customer_name": "Juan",
"customer_surname1": "Pérez",
"customer_surname2": "García",
"customer_document_type_id": "1",
"customer_document_number": "12345678A",
"customer_birthdate": "1990-05-15",
"customer_sex": "M",
"customer_nationality_id": "60"
},
"error": null,
"message": "Request processed successfully."
}
/api/v1/activate/esim/get-avalible-countries
Gets the available countries for activation. Required for selecting the customer_nationality_id field.
Response:
{
"data": [
{ "value": 60, "name": "España" }
],
"error": null,
"message": "Request processed successfully."
}
/api/v1/activate/esim/get-avalible-document-type
Lists the supported document types. Required for selecting the customer_document_type_id field.
Response:
{
"data": [
{ "value": 1, "name": "NIF" }
],
"error": null,
"message": "Document types list retrieved successfully."
}
/api/v1/activate/esim/get-avalible-plans
Returns the available eSIM plans. Required for selecting the selected_plan field.
Response:
{
"data": [
{ "id": 14, "name": "Prepago Travel M", "price": 15 }
],
"error": null,
"message": "Plan list retrieved successfully."
}
/api/v1/activate/esim/get-activation-history
Queries the activation history.
Query params:
| Name | Type | Description |
|---|---|---|
| limit | number | Between 1 and 100 (required) |
| offset | number | Minimum 0 (optional) |
Response:
{
"data": [
{
"iccid": "8934071234123456789",
"phone": "123456789",
"activationCode": "C0D123456789B123AC1234567F123E4E",
"qrCode": "LPA:1$sm-...",
"confirmationCode": "123456",
"plan_name": "Prepago Travel M",
"selected_plan": "14",
"amount": 15,
"customer_name": "Juan",
"customer_surname1": "Pérez",
"customer_surname2": "García",
"customer_document_type_id": "1",
"customer_document_number": "12345678A",
"customer_birthdate": "1990-05-15",
"customer_sex": "M",
"customer_nationality_id": "60",
"createdAt": "2023-10-01T12:00:00Z"
}
],
"error": null,
"message": "Activation history data retrieved successfully."
}