X-Sense Security - is it possible to create an integration?

I have the X-Sense Home Security Kit. It’s a bunch of LoRaWAN sensors and a hub (NB, it isn’t the smoke alarm someone else mentioned).

I can’t find an integration for it. Nor can I find any public API.

If I were to decompile the Android app and documented the calls that it makes - mostly to data.iot.eu-central-1.amazonaws.com - would that be enough to start work on a basic integration? Or has someone already tried this?

6 Likes

Did you get any traction on this?

Also interested in this, do you have a list of the calls?

Hi, I’ve aquired the X-Sense smoke detectors with SBS50 base station. At the moment, I just can control the sensors via the app and would like to have them in HA for obvious reasons. So, is there any progress on this? Or can I contribute somehow?

I’d also love to see an integration for x-sense devices.

just got my sbs50 and started sniffing the traffic today. First impression looks promising, I see rest-traffic to api.x-sense-iot.com and authentication with a jwt-token.

I’m not sure if the sbs50 is the same as the home-scurity kit, don’t want to hijack your thread.

I think the sbs50 is the same and only basestation in the x-sense universe. At least I have it, and the last piece missing is the integration in to HA. Ideally, all detectors could be used as siren, if an alarm is triggered within HA. Anyway, the problem is probably to extract the token, right?

currently playing around with the authentication and checking what I need to login. They are using AWS cognito IDP for that.
Besides the normal API, I saw MQTT over websockets.

Didn’t make much progress, will let you know when I have something.

managed to get the authentication working. I’m now able to query the API.
Currently working on the MQTT part.

1 Like

That is nice to hearn. I just buy same SBS50 + smoke detector and wonder can I connet it my home assistant

All tips helps a lot

I’m still working on mqtt/websockets. I believe that I have found everything that is related to the authentication, but I’m still unable to connect to mqtt.

Used mitmproxy and frida to see what is going on and are now able to generate the same urls/signatures for connecting to it. The requests look identical, but I’m probably missing some details.

Does anyone have experience with the AWS IOT-module? That could be helpful. X-sense is using the AWS-libraries a lot.

When I have time, I will start by documenting what I have so far and put it somewhere on github.

Hi, thanks for your job. Once log have you try to launch this kind of request:
/things/SBS50<YOUR_SBS50_ID>/shadow?name=2nd_info_<YOUR_SBS50_ID>
and not trying get MQTT? on my mitmproxy this kind of requests give the state of devices. I can help if you want but i don’t know how amazon token works. I you can share this part of you code…

1 Like

Just put some code and documentation on github. I’m able to login and do API-calls. I’ll focus on the normal API for now, will try to fix the MQTT part later.
I’m not sure if MQTT will add much to an integration. If a smoke-sensor detects a fire, I don’t need to see that in Home Assistant. But I would love to see things like status and battery-level.

There is a list with the ID’s of all API-calls that I found, but I focussed on a few common calls.

You can find it here: GitHub - theosnel/python-xsense: a Python XSense module

If I have the api-calls I need, I will try to build a home assistant integration. Never done that before, so it might take some time.

4 Likes

I haven’t tested it yet, but the code in the repo looks promising. Thanks for your effort!
Do you think, it would also be possible to trigger the alarm of all devices connected to the base station from HA? So it could be used as a multiroom alarm, even with Alarmo, etc.? That really would be nice…

Yes, assuming that it is possible within Home Assistant, cannot think of reasons why not. I expect that these kind of messages will be sent over MQTT. I haven’t tested that yet and haven’t inspected the contents of that feed.

I’m completely new with Home Assistant and it will probably take me some time to figure out how to build my first component. Including a MQTT feed is more advanced, so I’m not sure if I can do that within a reasonable time.

Hello, that’s already great. I’m also ordering the set of 12 and the SBS50 base station. I already had Heiman smoke alarms in use via Zigbee, but they didn’t respond for a few days, I didn’t know if they were still reachable, etc.
I am currently using Homematic IP.

But I think the solution with X-Sense is better. If you can now include this in Homeassistant, you would have a redundant solution for notifications. Once via the X-Sense app and then via HA.

I hope you make progress here.

Thank you very much for your work.
Greetings Tom

+1 on interest and thanks to @theosnel for getting the ball rolling. Watching this thread and happy to help test.

1 Like

My X-Sense XS01-M smoke detectors (15 units) with SBS50 base station will arrive here on Thursday, and I will be happy to test them and provide feedback.

1 Like

Happy to see an active effort to bring X-sense in the HA. This guy is the product manager for x-sense. I have also reached out to them directly.

https://www.linkedin.com/in/yiming-zhang-0b48a43b?utm_source=share&utm_campaign=share_via&utm_content=profile&utm_medium=ios_app

2 Likes

I own a SBS50 and three of the thermometer/hygrometer sensors and would love to see them integrated into Home Assistant. It’s a really inexpensive LoRaWAN system that seems to work really well. I’ll have to take a look at some of the python libraries at some point and see if I can add anything to this, and eagerly await movement on this - I hate to send these back just because they can’t do Home Assistant.

Thank you for looking into this!