Bluetooth Clients API - Status

Solved
JudgeyK
Here to help

Bluetooth Clients API - Status

Due to the success of getting  my last question answered so efficiently, I thought I may ask another ;

 

On the Bluetooth Clients Meraki Dashboard there is a Status Column, however in the API I cannot seem to find it in any JSON returned.  Does anybody know where I can get the Status of a Bluetooth Client using the API ?  the links I have tried so far are ;

 

https://n35.meraki.com/api/v0/networks/"Network_ID"/bluetoothClients?perPage=100&includeConnectivity...

 

and

 

https://n35.meraki.com/api/v1/networks/"Network_ID"/bluetoothClients/"Bluetooth_ID"

 

Obviously "Network_ID" and "Bluetooth_ID" are replaced with the actual IDs....

 

Kind Regards

 

Ken

 

 

1 Accepted Solution
Meraki_John
Meraki Employee
Meraki Employee

Hey @JudgeyK!

 

I've had a dig and I can see what you are talking about:

Screenshot 2020-02-21 at 09.10.04.png

 

vs.

 

{
        "id""664243894382658270",
        "mac""df:a1:23:3e:da:ab",
        "networkId""L_664843893860569900",
        "name"null,
        "deviceName""vívosmart HR+",
        "manufacturer""Unknown",
        "lastSeen"1582222415,
        "seenByDeviceMac""83:15:77:50:4a:d4",
        "inSightAlert"false,
        "outOfSightAlert"false,
        "tags": []
    }
 
However, I wouldn't rely on the "status" column as there isn't actually a connection (like WiFi or non-BLE bluetooth). The AP is simply listening out for beacons and then they are being presented in the list.
 
The best thing is to look at the "lastseen" field and then programmatically decide when they no longer exist (which is what dashboard UI is doing).
 
It makes sense in a human readable format (on the dashboard UI) because you can look at the page and quickly see which which BLE beacons have been here in the last minute or two based on the green symbol, but other than that it doesn't really give much info, and the lastseen field actually gives you more information.
 
Hopefully this answers your Q 😁
Happy Friday!

View solution in original post

5 Replies 5
ChrisC83
Meraki Employee
Meraki Employee

Hi,

 

I believe you will need to perform the API query to get the network ID and the Bluetooth client ID first.

 

Try below to retrieve the network ID and Bluetooth client ID. And you can find these in API doc.

 

https://api.meraki.com/api/v0

 

https://api.meraki.com/api/v0/organizations/{organizationId}/networks

 

https://api.meraki.com/api/v0/networks/{networkId}/bluetoothClients

 

 

 

Best Regards,

Chris

If you found this post helpful, please give it kudos. If my answer solved your problem, click "accept as solution" so that others can benefit from it.
JudgeyK
Here to help

Hi Chris,

 

Thanks for your response.  I did state at the bottom of my post that I was replacing the NetworkID and the ClientID with the actual IDs.

 

The problem is,  you DO get the status when you are requesting the Network Clients using ;

https://api.meraki.com/api/v0/organizations/{organizationId}/networks 

 

however,  you DO NOT get the status when requesting the Bluetooth Clients

https://api.meraki.com/api/v0/networks/{networkId}/bluetoothClients 

 

Is this an oversight on Meraki as it is displayed when you use the actual dashboard web pages at https://n35.meraki.com/

 

 

Kind Regards

 

Ken

Meraki_John
Meraki Employee
Meraki Employee

Hey @JudgeyK!

 

I've had a dig and I can see what you are talking about:

Screenshot 2020-02-21 at 09.10.04.png

 

vs.

 

{
        "id""664243894382658270",
        "mac""df:a1:23:3e:da:ab",
        "networkId""L_664843893860569900",
        "name"null,
        "deviceName""vívosmart HR+",
        "manufacturer""Unknown",
        "lastSeen"1582222415,
        "seenByDeviceMac""83:15:77:50:4a:d4",
        "inSightAlert"false,
        "outOfSightAlert"false,
        "tags": []
    }
 
However, I wouldn't rely on the "status" column as there isn't actually a connection (like WiFi or non-BLE bluetooth). The AP is simply listening out for beacons and then they are being presented in the list.
 
The best thing is to look at the "lastseen" field and then programmatically decide when they no longer exist (which is what dashboard UI is doing).
 
It makes sense in a human readable format (on the dashboard UI) because you can look at the page and quickly see which which BLE beacons have been here in the last minute or two based on the green symbol, but other than that it doesn't really give much info, and the lastseen field actually gives you more information.
 
Hopefully this answers your Q 😁
Happy Friday!
JudgeyK
Here to help

Brilliant,

 

Thanks John.

Uberseehandel
Kind of a big deal

@Meraki_John 

 

Somewhat oddly, my phone is picking up Bluetooth fitbits whilst the AP picks up TVs, but not my phone . . . 

Robin St.Clair | Principal, Caithness Analytics | @uberseehandel
Get notified when there are additional replies to this discussion.