ArubaOS-CX REST API reference summary
The following information is intended as a quick reference for experienced users. Values are not configurable unless noted otherwise.
Switch REST API access default
8320, 8325, 8400 Series switches: Disabled
6300, 6400 Series switches: Enabled on the
mgmt
VRF
Switch REST API read/write access default
Read-only
Enabling access to the Web UI and REST API
CLI command:
https-server vrf
<VRF-NAME>
Example:
switch(config)# https-server vrf mgmt
Setting the REST API access mode to read/write
CLI command:
https-server rest access-mode read-write
Example:
switch(config)# https-server rest access-mode read-write
Showing the REST API access configuration
CLI command:
show https-server
Example:
switch(config)# show https-server HTTPS Server Configuration ---------------------------- VRF : default, mgmt REST Access Mode : read-only
ArubaOS-CX REST API Reference URL:
REST v10.04 API:
https://<IP-ADDR>/api/v10.04/
REST v1 API:
https://<IP-ADDR>/api/v1
or
https://<IP-ADDR>/api/
<IP-ADDR>
is the IP address or hostname of your switch.
Example:
https://192.0.2.5/api/v1/
REST API versions and switch software versions
REST API version | Switch software version |
---|---|
v10.04 | ArubaOS-CX 10.04 |
v1 | ArubaOS-CX 10.00 through 10.04 |
Getting REST API version information from a switch
Method and URI to get the REST API versions supported on the switch:
GET "https://<IP-ADDR>/rest"
<IP-ADDR>
is the IP address or hostname of your switch.
Protocol
HTTPS
Port
443
Request and response body format
JSON
Session idle timeout
20 minutes
Session hard timeout
Eight hours, regardless of whether the session is active.
Authentication
Session cookie from successful HTTPS login request.
HTTPS client sessions
Maximum of 48 sessions per switch.
Maximum of three concurrent client sessions per user.
The same session cookie is shared across browser tabs and, depending on the browser, multiple browser windows.
The same session cookie is not shared across devices and scripts.
For example, if a user logs into the Web UI from a laptop, again with a tablet, and then uses the same user name in a curl command, that user has three concurrent client sessions.
VSX peer switch access
If Virtual Switching Extension (VSX) is enabled on both switches, and the ISL is up, you can access the VSX peer switch from your connected switch. To access the peer VSX switch, insert
/vsx-peer
in the URI path between the server URL and
/rest
. Not supported for login, Web UI, or
ArubaOS-CX REST API Reference access.
For example:
Accessing a VSX switch:
https://192.0.2.5/rest/v1/…
Accessing its VSX peer switch:
https://192.0.2.5/vsx-peer/rest/v1/…