Get Time Zone - Cisco 340 Series Configuration Manual

Table of Contents

Advertisement

Chapter 4
Configuring HTTP API

Get Time Zone

Example: get time zone
Request
curl -k -X GET -H 'password: cisco123!' https://localhost/api/2.0/sys/timeZone
Reply
{"timeZone":"8","success":"true","getAt":"2013-05-10 15:38:15"}
Set Time Zone
Example: set time zone
Request
curl -k -X PUT -H 'password: cisco123!' -H 'Content-Type: application/json' -d
'{"timeZone":"Asia/Shanghai"}' https://localhost/api/2.0/sys/timeZone
Reply
{"success":"true","updatedAt":"2013-04-08 13:14:51"}
Parameter Restrictions
The valid parameter is any city in the /usr/share/zoneinfo/posix/ folder.
Get Auto-Login Status
Example: get Auto-Login status
Request
curl -k -X GET -H 'password: cisco123!' https:// localhost /api/2.0/sys/autologin
Reply
{"autologin":"enable","success":"true","getAt":"2013-05-10 15:04:35"}
Parameter Restrictions
r is reported.
Set Auto-Login
Example: set Auto-Login to disable
Request
curl -k -X PUT -H 'password: cisco123!' -H 'Content-Type: application/json' -d
'{"autologin":"disable"}' https:// localhost /api/2.0/sys/autologin
Reply
{"success":"true","updatedAt":"2013-05-10 15:05:54"}
OL-29491-01
Cisco Edge 340 Series Software Configuration Guide, Release 1.0
System API
4-5

Advertisement

Table of Contents
loading

Table of Contents