#HttpOnly_sandboxsdwan.cisco.com. FALSE / TRUE
0 JSESSIONID.
v9QcTVL_ZBdIQZRsI2V95vBi7Bz47IMxRY3XAYA6.4854266f-
a8ad-4068-9651-
d4e834384f51
The long string after JSESSIONID is the value of the
authorization cookie that will be needed in all
subsequent API calls.
Figure 8-12 shows the same API call in Postman.
Figure 8-12 Cisco SD-WAN REST API Authorization
Call
The status code of the response should be 200 OK, the
body should be empty, and the JSESSIONID cookie
should be stored under the Cookies tab. The advantage
with Postman is that it automatically saves the
JSESSIONID cookie and reuses it in all API calls that
follow this initial authorization request. With curl, in
contrast, you have to pass in the cookie value manually.
To see an example, you can try to get a list of all the
devices that are part of this Cisco SD-WAN fabric.
According to the documentation, the resource that will
return this information is /dataservice/device. It will
have to be a GET call, and the JSESSIONID cookie needs
to be passed as a header in the request. The curl
command to get a list of all the devices in the fabric
should look like as follows:
Click here to view code image