Mobility checks the request format and the eligibility of the primary SIM before it accepts the request. A request that fails one of these checks is rejected immediately with HTTP 400 and nothing is activated. Failures that happen at the carrier are sent later in a callback. Secondary SIM Activation must be enabled for your account. If it is not, the API returns HTTP 403. Contact your Account Manager to enable it.
Secondary SIM Activation
Activates a secondary eSIM for a primary SIM that is already in service, so that the device can use two carriers.
urn:grt:gemmapplication/jsonhttps://gemmapi2.granitenet.com/v2/api/gemm/v1Uses and Requirements
Use this API to add a secondary SIM to a primary SIM that is already activated or suspended. To activate a primary SIM and a secondary SIM together in one request, use Activation with Secondary SIM instead.
The Secondary SIM Activation API processes requests asynchronously. The immediate response returns a transactionID. After processing begins, Mobility sends a SubscriberService callback with requestType Activate that confirms the secondary SIM was activated or explains why the activation failed.
Each request holds exactly one entry in sims (the primary SIM, identified by its iccid) with exactly one entry in secondarySims. Bulk requests are not supported. The secondary SIM is activated under the same account as the primary SIM, and it takes the primary SIM’s device user.
Note
Eligibility Rules
| Rule | Requirement |
|---|---|
| Primary SIM status | The primary SIM must be Activated or Suspended. |
| Primary SIM data plan | The primary SIM must be on an Unlimited data plan. |
| Primary SIM carrier | The primary SIM must be on AT&T APEX, TPR (Granite Wireless - VzW) or T-Mobile for Business. |
| Secondary SIM carrier | The secondary SIM must be on a different carrier than the primary SIM. See the carrier table below. |
| Secondary SIM type | The secondary SIM must be an eSIM. Physical SIMs are not supported. |
| Device type | The device must be an iPhone or a Smartphone/Android. Basic phones and M2M/IoT devices are not eligible. |
| Plan | You choose the carrier and the device type. Mobility selects the secondary SIM plan for that combination. If no plan exists for it, the request is rejected. |
| IMEI | The IMEI is the device's second IMEI (IMEI2), 15 digits. It is checked with the same rules as an IMEI on Activation. |
Carrier Combinations
| Primary SIM Carrier | Secondary SIM Carrier Options |
|---|---|
| AT&T APEX | Granite Wireless - VzW, T-Mobile |
| Granite Wireless - VzW (TPR) | ATT, T-Mobile |
| T-Mobile for Business | ATT, Granite Wireless - VzW |
How It Works
- You send the request. Mobility validates the format, then checks the primary SIM (status, Unlimited plan, carrier) and looks up the secondary SIM plan for the carrier and device type you chose. If anything fails, you get an immediate
400and nothing is sent to a carrier. - Mobility accepts the request, creates a transaction and returns the
transactionID. - Mobility submits an eSIM activation for the device’s IMEI2 to the secondary carrier, under the primary SIM’s account. The secondary SIM has no ICCID until the carrier assigns one.
- The carrier completes the activation. How Mobility learns the result depends on the carrier, as shown below.
- Mobility sends you one
SubscriberServicecallback with the result. On success,simInfocarries the ICCID and MSISDN of the secondary SIM.
| Secondary SIM Carrier | What Mobility sends to the carrier | How the result comes back |
|---|---|---|
| ATT | One activation order for the device IMEI, with the plan and any add-on for the plan. | Mobility checks the status of the order until it is complete. An order that stays pending for too long fails. |
| Granite Wireless - VzW | One activation request to Telispire for the device IMEI and the plan. | Telispire sends the result when it finishes. Mobility does not check the status itself. |
| T-Mobile | Mobility first checks that the device is compatible with eSIM. If it is, it submits one purchase order with the IMEI and the plan. | Mobility checks the status of the order until it is completed. An order that stays pending for too long fails. |
Note
If the carrier does not answer within the wait time set for that carrier, Mobility fails the request and sends a failure callback. The activation is not retried automatically. Submit a new request after you check the status of the SIM.
HTTP Status Codes
| Status | When |
|---|---|
200 | The request was accepted and a transactionID was returned. The result is sent later in a callback. |
400 | The request is invalid: the macnum header is missing or is not 8 digits, the body is not valid JSON, sims or secondarySims does not hold exactly one entry, or a field is missing or in the wrong format. Also when the secondary carrier, SIM type or device type is not supported, or the primary SIM is not found, is not Activated or Suspended, is not on an Unlimited plan or an eligible carrier, is on the same carrier as the secondary SIM, or no secondary SIM plan exists for the carrier and device type. Nothing is activated. |
401 | The bearer token is missing, invalid or expired, or you do not have access to the account in the macnum header. |
403 | Your credentials are not permitted to use this API, Secondary SIM Activation is not enabled for your account, or the primary SIM belongs to an account you do not have access to or that is not under the macnum account. |
429 | Too many requests were sent in a short period. Wait briefly and retry. |
500 | An unexpected server error occurred. |
503 | The system is under scheduled maintenance. Retry after the maintenance window. |
504 | A dependent service did not respond in time. Retry the request. |
For a complete list of error codes, messages, causes, and resolutions, see Secondary SIM Activation - Sync Error Messages and Secondary SIM Activation - Async Error Messages.
Available For
The primary SIM and the secondary SIM must be on two different carriers from this list. The secondary SIM is always an eSIM, and the primary SIM must be on an Unlimited data plan.
- ATT
- Granite Wireless - VzW
- T-Mobile
Headers
| Header | Value |
|---|---|
Authorization | Bearer access-token |
Content-Type | application/json |
macnum | Macnum of the top level account for your organization. |
Request Body Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
sims | array of simInfo objects | Yes | The primary SIM and its secondary SIM. The array must hold exactly one simInfo object. |
simInfo | object | Yes | Information about the primary SIM and the secondary SIM. |
iccid | string | Yes | ICCID of the existing primary SIM, 19-20 digits. The 20th character can be F. The SIM must be Activated or Suspended and must be under the account in the macnum header. |
secondarySims | array | Yes | Array containing details of the secondary SIM. It must hold exactly one secondary SIM. |
imei | string | Yes | IMEI2 of the eSIM-capable device. Must be a 15-digit numeric value. |
deviceType | string | Yes | The device type. Mobility uses it to select the secondary SIM plan. Allowed values:
|
simType | string | Yes | Only eSIM secondary SIM activations are supported. Expected value: eSIM Virtual is the earlier name for eSIM and is still accepted. |
carrier | string | Yes | The carrier for the secondary SIM. This must differ from the primary SIM's carrier. Not case-sensitive. Allowed values:
|
Request Examples
Request to activate a secondary SIM on T-Mobile for an iPhone
Request to activate a secondary SIM on ATT for a Smartphone/Android
Responses
Immediate Success Response (200 OK)
Response Fields
| Parameter | Type | Description |
|---|---|---|
transactionID | string | A unique string that associates the request with the result that Mobility sends in a callback. All callbacks for the request have the same transactionID. |
Callback Success Response
Mobility sends one callback for the secondary SIM when its activation is complete. The callback has requestType Activate, the same as an activation callback, and its simInfo describes the new secondary SIM. The deviceUser is the device user of the primary SIM.
Response Fields
| Parameter | Type | Description |
|---|---|---|
requestType | string | Name of the requested action. For a secondary SIM activation, the value is Activate. |
transactionID | string | The transactionID returned in the immediate response. |
simInfo | object | Information about the secondary SIM. |
iccid | string | ICCID assigned to the secondary SIM, 19-20 digits. |
msisdn | string | 10 digits. |
imei | string | IMEI2 of the device, 15 digits. |
deviceUser | string | The device user of the primary SIM. |
simType | string | Virtual. |
result | object | Result of the operation. |
status | string | Result status: success or failure. |
message | string | Result message. |
errors | array of objects | List of errors. Included when the operation fails. |
errorCode | string | Error code. |
errorMessage | string | Error message. |
callbackCount | integer | The number of times this callback has been sent. |
maxCallbackThreshold | integer | The maximum number of times Mobility sends this callback if it is not acknowledged. |
Failure Responses
Immediate Error Message
HTTP 400 when the primary SIM does not qualify. Every immediate error uses this format.
Error Response Fields
| Parameter | Type | Description |
|---|---|---|
result | object | Result of the operation. |
status | string | Result status: success or failure. |
errors | array of objects | List of errors. Included when the operation fails. |
errorCode | string | Error code. |
errorMessage | string | Error message. |
Example Async Error Message
Sent when the carrier could not activate the secondary SIM.
Secondary SIM Activation Options
Before you send a request, you can ask Mobility which carriers and device types have a secondary SIM plan. A carrier or device type is listed only when a plan exists for it. Either list can be empty.
Send the Authorization and macnum headers. The same account must have Secondary SIM Activation enabled.
| Parameter | Type | Description |
|---|---|---|
simCarriers | array of strings | Carriers that you can send in carrier on the secondary SIM. |
deviceTypes | array of strings | Device types that you can send in deviceType. |