def lan_ip():
"""1:1 implementation of hub/lan_ip
This call will fail with an APIError if the requesting source address is not the same as that of the hub, i.e. if they're not in the same NAT network.
The above is based on observation and may only be partially true.
Returns:
list: List of Hub ip addresses.
"""
response = requests.get(cloudBase + 'hub/lan_ip')
if response.status_code == 200:
return json.loads(response.text)
else:
raise APIError(response.status_code, response.text)
评论列表
文章目录