【发布时间】:2017-01-25 13:18:05
【问题描述】:
是否有可能获取组织的所有信标(包括第三方信标)?
我刚刚在 API 中发现了这个 GET 调用:
https://docs.gimbal.com/rest.html#beacons_get_all
预期的 JSON 响应:
[
{
"id": "beacon_id_one",
"factory_id": "XXXX-ZZZZZ",
"icon_url": "https://api.getfyx.com/assets/fallback/default_icon.png",
"name": "John's Beacon one",
"latitude": 32.7150,
"longitude": 117.1625,
"gimbal_latitude": 33.889916,
"gimbal_longitude": -117.351344,
"gimbal_location_last_updated_date": "2016-07-22T09:32:02.000Z",
"visibility": "Private",
"battery_level": "Battery Level of the Beacon",
"battery_updated_date": "2016-05-28T15:54:11.000Z",
"hardware": "Hardware type of the Beacon",
"owner": "SELF",
"beacon_attributes": {
"key1": "value1",
"key2": "value2"
}
},
{
"id": "beacon_id_two",
"factory_id": "XXXX-YYYYY",
"icon_url": "https://api.getfyx.com/assets/fallback/default_icon.png",
...
这就是我的请求的样子。响应是一个 HTTP 200 和空数组。
遗憾的是它不返回第三方信标。
【问题讨论】:
-
问题中显示的链接返回“拒绝访问”,因此可能需要从云台登录。您可能希望将相关内容的摘录粘贴到问题中的块引用中。
-
抱歉。更正了网址和回复。
-
很明显,该服务调用旨在返回您注册的信标。是什么让您认为可能会返回 3rd 方信标?据我了解,这不是 Gimbal 服务器注册的工作方式——这完全是为了让您的信标保持私密。
-
可以使用第 3 方信标。因此,您可以将它们添加到云台中并使用它们。所以我认为它也应该在这个端点的响应中。
标签: rest api ibeacon beacon gimbal