Use the API function autologin:
Url:    
https://xxx.xxx.xxx.xxx:2304/v1/user_sessionMethod:    POST
key:    Key authorized by Api administrator
action:    list
user:    Account username (If not specified, a list of accounts will be displayed)
timer:    Expiration time of the session, expressed in Minute, example 2
module:    Indicate the name of the module to be redirected
debug:    (0 / 1) Debug display file: /var/log/cwp/cwp_api.log