How to get or set the internet priority
Perform actions on the internet priority of your SecureEdge device via the API.
SecureEdge API AuthenticationRetrieving or modifying the internet priority requires authentication. See How to authenticate to the API.
Introduction
Use the /api/v1/network/policy endpoint to retrieve or configure the internet priority of the SecureEdge. The internet priority is the order in which the SecureEdge uses its wired, cellular and wireless connections to reach the internet. You can also find it in the local web interface under Network > WAN > Internet priority.
If a connection is unavailable or not configured, its priority is ignored.
Internet priority and a proxyIf a proxy is configured as well, a connection type that is unable to reach the configured proxy server will be lowered in priority. This potentially affects the connection priority, deviating from the configured internet priority. See How to get or set a proxy.
Retrieving the internet priority
Use GET for retrieval:
curl --request GET \
--url 'http://192.168.140.1:80/api/v1/network/policy' \
--cookie 'session.jar'{
"first": "ethernet",
"second": "cellular",
"third": "wireless"
}The fields give the order of the connections, from the most to the least preferred:
| Field | Local web interface |
|---|---|
first | Preferred |
second | First fallback |
third | Second fallback |
Each field contains one of the following connection types:
| Value | Local web interface |
|---|---|
ethernet | Wired network |
cellular | Cellular network |
wireless | Wireless network |
Configuring the internet priority
Use POST to set the internet priority. Send all three fields. For example, to prefer the cellular connection over the wired connection:
curl --request POST \
--url 'http://192.168.140.1:80/api/v1/network/policy' \
--cookie 'session.jar' \
--header 'Content-Type: application/json' \
--data '
{
"first": "cellular",
"second": "ethernet",
"third": "wireless"
}'
Import the configuration into IXON CloudChanges made through the API are applied on the SecureEdge only. To avoid unwanted configuration changes later on, import them into the IXON Cloud: go to Fleet Manager > Devices, click on your device name, open the sync options and select Import config from device. For more details, see How to import a configuration from an agent.
Updated about 1 hour ago
