The Login Resource is used to establish a secure session with the SBC. The user provided in the URI parameters of this resource must be created through the WebUI prior to using the API and must be of the REST access level.In this section, the usage of a POST request using cURL to establish a secure session with the SBC system is demonstrated.

Request
./curl.exe --cacert 192.168.1.183.crt --data "Username=admin&Password=admin" -i -v https://192.168.1.183/rest/login
Response
HTTP/1.1 200 OK
Set-Cookie: PHPSESSID=ima0r3nkaeg8mo0suln67vg4m7; path=/; secure
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Content-type: text/html; charset=UTF-8
Transfer-Encoding: chunked
Date: Tue, 17 May 2011 18:57:03 GMT

<?xml version="1.0">
<root>
 <status>
  <http_code>200</http_code>
 </status>
</root>
Session Token

Use the PHPSESSID=ima0r3nkaeg8mo0suln67vg4m7 cookie from Set-Cookie from above login resource response for subsequent CURL Rest calls.