Skip to main content

Set network preferences

PUT 
/sim_cards/:sim_card_id/network_preferences

This API allows setting or updating a SIM card network preference.

Every SIM card has default network preferences defined on Telnyx. These preferences will determine how a SIMCard will connect to the network by considering a list of preferable operators.

There can be multiple scenarios where an operator can be preferred over another, for example, when a specific mobile operator can provide better network latency or better pricing.

Request

Path Parameters

    sim_card_id uuidrequired

    Identifies a SIM card.

Body

    mobile_network_operators_preferences

    object[]

    A list of mobile network operators and the priority that should be applied when the SIM is connecting to the network.

  • Array [

  • mobile_network_operator_id uuid

    The mobile network operator resource identification UUID.

    priority integer

    It determines what is the priority of a specific network operator that should be assumed by a SIM card when connecting to a network. The highest priority is 0, the second highest is 1 and so on.

  • ]

  • A list of mobile network operators and the priority that should be applied when the SIM is connecting to the network.

Responses

202:

default: Unexpected error

Request samples


curl -L -X PUT 'https://api.telnyx.com/v2/sim_cards/:sim_card_id/network_preferences' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
-d '{
"mobile_network_operators_preferences": [
{
"mobile_network_operator_id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
"priority": 0
}
]
}'

Response samples


{
"data": {
"record_type": "sim_card_network_preferences",
"sim_card_id": "6b14e151-8493-4fa1-8664-1cc4e6d14158",
"mobile_network_operators_preferences": [
{
"mobile_network_operator_id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
"mobile_network_operator_name": "AT&T Mobility (USACG)",
"priority": 0
}
],
"ota_updates": [
{
"created_at": "2018-02-02T22:25:27.521Z",
"id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
"record_type": "ota_update",
"settings": {
"mobile_network_operators_preferences": [
{
"mobile_network_operator_id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
"mobile_network_operator_name": "AT&T Mobility (USACG)",
"priority": 0
}
]
},
"sim_card_id": "6a09cdc3-8948-47f0-aa62-74ac943d6c58",
"status": "in-progress",
"type": "sim_card_network_preferences",
"updated_at": "2018-02-02T22:25:27.521Z"
}
],
"created_at": "2018-02-02T22:25:27.521Z",
"updated_at": "2018-02-02T22:25:27.521Z"
}
}