Bluetooth Clients API "LastSeen"

Solved
JudgeyK
Here to help

Bluetooth Clients API "LastSeen"

Hi All,

 

Been struggling with this now for days,  I am using C# to return the JSON for the Bluetooth Clients but I cannot seem to convert the Long Integer to a DateTime ;

 

   "lastSeen": 1581935427,

 

Can anybody please point me in the right direction on what this value is,  I thought it maybe Ticks,  but that doesn't work,  any help would be really appreciated as I cannot find any documentation on what this value represents.

 

Kind Regards

 

Ken.

1 Accepted Solution
CBurkhead
Building a reputation

Like many of the datetime values returned by the API, it is a Unix time (# of seconds since 1/1/1970). It will also be in UTC, so if you need local time, you will need to convert it. I would imaging there is a datetime conversion in C# that will take this and convert it to a normal value that you can then manipulate.

View solution in original post

3 Replies 3
CBurkhead
Building a reputation

Like many of the datetime values returned by the API, it is a Unix time (# of seconds since 1/1/1970). It will also be in UTC, so if you need local time, you will need to convert it. I would imaging there is a datetime conversion in C# that will take this and convert it to a normal value that you can then manipulate.

Brilliant, thank you !
CBurkhead
Building a reputation

Not a problem. I had to deal with the same thing getting date information for security events.

Get notified when there are additional replies to this discussion.