Package: vssapi
This is a package implementing Visionect Software Suite API in Python (3.5.1+ supported).CheckVSS API documentationfor more info.API endpoints and responses are subject to change, so make sure to followrelease notes.InstallationpipinstallvssapiUsefromvssimportApiDeclarationsvss_api_instance=ApiDeclarations(url,key,secret)status_code,response(optional)=vss_api_instance.{function(params)}change an app on devicestatus,content=vss_api_instance.get_session(uuid)content['Backend']['Fields']['url']="you_app.url"vss_api_instance.update_session(uuid,cont)change default appstatus,content=vss_api_instance.get_config()content['Engine']['Backend']['HTML']['DefaultFields']['url']="you_app.url"vss_api_instance.update_config(cont)Function listDeviceretrieve a deviceget_device(uuid)params: uuidstringreturns: status codeint, responsejsonupdate a deviceupdate_device(uuid, device_object)params: uuidstring, device_objectjsonreturns: status codeintdelete a devicedelete_device(uuid)params: uuidstringreturns: status codeint, responsejsonDevice collectionlist all devicesget_all_devices()params: /returns: status codeint, responsejsonupdate a list of devicesupdate_all_devices(device_object_list)params: device_object_listjson listexample:device_object_list = [device_object1, device_object2, ... device_objectN]returns: status codeintDevice configurationget configuration listget_device_config_list(uuid)params: uuidstringreturns: status codeint, responsejsonget configurationget_device_config(uuid, tclv_type)params: uuidstring, tclv_typeintreturns: status codeint, responsejsonset configurationupdate_device_config(uuid, tclv_type, value)params: uuidstring, tclv_typeint, valueintreturns: status codeintRebootreboot devicereboot_device(uuid)params: uuidstringreturns: status codeintreboot a list of devicesreboot_device_list(uuid_list)params: uuid_listlistexample:uuid_list = [uuid1, uuid2, ... uuidN]returns: status codeintSessionsretrieve a sessionget_session(uuid)params: uuidstringreturns: status codeint, responsejsonupdate a sessionupdate_session(uuid, session_object)params: uuidstring, session_objectjsonreturns: status_codeintremove a sessiondelete_session(uuid)params: uuidstringreturns: status_codeintSession collectionlist all sessionsget_session_list()returns: status_codeint, responsejsoncreate a sessioncreate_session(session_object)params: session_objectjsonexample:session_object={"Uuid":{uuid},"Backend":{"Name":"HTML","Fields":{"url":"http://demo.visionect.com/clock/?t=602"}},"Options":{"DefaultDithering":"none","DefaultEncoding":"4"}}returns: status_codeintupdate a list of sessionsupdate_session_list(sessions_object)params: sessions_objectjson listexample:sessions_object = [session_object1, session_object2, ...  session_objectN]returns: status_codeintRestartrestart a sessionrestart_session(uuid)params: uuidstringreturns: status_codeintrestart a list of sessionsrestart_session_list(uuid_list)params: uuid_liststring listexample:[uuid1, uuid2, ... uuidN]returns: status_codeintUserretrieve a userget_user(username)params: usernamestringreturns: status_codeint, responsejsonupdate a userupdate_user(username, user_object)params: usernamestring, user_objectjsonexample:{"Username":{username},"Password":{password},"IsActive":true,"IsAPI":false}returns: status_codeintdelete a userdelete_user(username)params: usernamestringreturns: status_codeintUser listlist all usersget_user_list()returns: status_codeint, responsejsoncreate a usercreate_user(username, password)params: usernamestring, passwordstringreturns: status_codeintupdate a list of usersupdate_user_list(user_list_object)params: user_list_objectjson listexample:user_list_object = [user_object1, user_object2, ... user_objectN]returns: status_codeintConfigretrieve configurationget_config()returns: status_codeint, responsejsonupdate configurationupdate_config(config_object)params: config_objectjsonreturns: status_codeintLive viewget_live_view(uuid, type, file_lv)params: uuidstring, typestring, file_lvstringexample:get_live_view({uuid}, 'image', '.png')returns: status_codeintStatusget_status()returns: status_codeint, responsejsonDevice statusget_device_status(uuid, start, end, group)params: uuidstring, startstring, endstring, groupstringexample:get_device_status(uuid, '1515153600', '1515412800', 'true')returns: status_codeint, responsejsonHTTP BackendUpload an image to the device via HTTP backend. Make sure device's backend is set to the HTTP.set_http(uuid, img)params: uuidstring, imgfileexample:img=os.path.join(os.path.dirname(os.path.realpath(__file__)),'img.png')fr={'image':('img.png',open(img,'rb'),'image/png',{'Expires':'0'})}sc=my_api.set_http(uuid,fr)returns: status_codeint