Nello.io对讲机的Python库
pynello的Python项目详细描述
皮内洛
公共API
这是与Nello设备交互的新首选方式。
开始
向hello@nello.io发送电子邮件,让他们为您生成一个client_id
。
代码示例
frompynello.publicimportNellon=Nello(client_id='you-need-to-ask-nello-for-this',username='me@example.com',password='somethingLong')# Get available locationsn.locations# Open the door ("main" ie. first available location)n.main_location.open_door()# Setup a webhook for new eventsn.main_location.set_webook('https://example.com/nello/event')
上游文件
专用API
此API已弃用
非常感谢Oskar Neumann在FHEM integration上的original work。
代码示例
frompynello.privateimportNellon=Nello(username='me@example.com',password='somethingLong')# Get available locationsn.locations# Open the door ("main" ie. first available location)n.main_location.open_door()# Get the recent activityn.main_location.activity