Securitas Direct (Verisure EU) Custom Component [TESTERS WANTED]

This one, I got it working, the only issue I have is when I change the alarm status from the physical remote control itself, that it doesn’t show in HA. If I change the alarm from the very sure app, it does show it, its just when I use the physical verdure remote control RF when I don’t get the change in state reflected.

Hi,

Suddenly the securitas direct component started reworking again out of the blue and without touching anything to my configuration.yaml.
There was an update from the app over the week-end asking me to enrol the fingerprint login (I’m in the UK).
anyway seems to be working again
Cheers

M

I have been able to install in SPAIN. Thank you for all the work!
two questions:

  1. Which “code” are you actually using? I only have a code-word no number-code with Securitas… This also leads to my next Question:
  2. The Pinpad in HA is not really relevant for me as I have no numeric code. Can I deactivate that? right now I can activate the alarm but not deactivate it as it waits for the numeric code.

Hi,

You need a code for deactivating the alarm in Home Assistant. It is a code that you set up in Home Assistant. I don’t think you can deactivate it as I think this component uses the alarm panel already built in Home Assistant. It is to protect you as anyone with access to Home Assistant could disable the alarm

Hello people,

This component is amazing or rather, it was, because the Securitas Direct application that this component emulates is no longer online, at least in Spain:

Logger: custom_components.securitas_direct.securitas
Source: custom_components/securitas_direct/securitas.py:126
Integration: securitas_direct (documentation, issues)
First occurred: 15:06:54 (1 occurrences)
Last logged: 15:06:54

Gracias por acceder a My Verisure. Esta aplicación ya no está disponible y te recomendamos desinstalarla. Pulsa aceptar para poder acceder a la nueva aplicación.

For new version, use that:

Working in Spain.

config.yaml file:

securitas_direct:
  username: your_securitas_username
  password: your_securitas_password
  installation: your_securitas_installation_number
  code: 1234
  country: ES
  lang: es

Thanks so Much! This version run perfectly

Where is this version repository?

regards

I don’t know… @sesardelaisla send me the file and I uploaded it with lifetime link.

I read that the problem with @segalion repository is that he is not using the “installation” parameter, and it is needed. The new code shared is using pysecuritas dependency (https://github.com/Cebeerre/pysecuritas) from @Cebeerre… while @segalion 's code is copying to his source some files from pysecuritas but an older version with less parameters so is not working with new app.

Also there is a pull request (https://github.com/nragon/core/tree/dev/homeassistant/components/securitas_direct) to HomeAssistant core that is trying to add it to core, using Integrations instead of YAML configuration. It is using the last version of pysecuritas and is working. However, is not added to core yet.

I don’t remember where I downloaded the file from. I think I didn’t do it from the original repository, but from a domotics related Spanish web site, so perhaps someone else tweaked it.

It seems it’s available here:

It’s a fork from @segalion updated to use pysecuritas (with compatibility with new app)

Hello all,

I lost connection to my securitas alarm a few HA versions ago… and I read your post… I upgraded the app a few weeks… and saw this…I hoped to make it work… but I get this error…

This error originated from a custom integration.

Logger: homeassistant.setup
Source: custom_components/securitas_direct/init.py:94
Integration: securitas_direct
First occurred: October 21, 2021, 9:37:48 PM (1 occurrences)
Last logged: October 21, 2021, 9:37:48 PM

Error during setup of component securitas_direct
Traceback (most recent call last):
File “/usr/src/homeassistant/homeassistant/setup.py”, line 254, in _async_setup_component
result = await task
File “/usr/local/lib/python3.9/concurrent/futures/thread.py”, line 52, in run
result = self.fn(*self.args, **self.kwargs)
File “/config/custom_components/securitas_direct/init.py”, line 65, in setup
if not HUB.login():
File “/config/custom_components/securitas_direct/init.py”, line 94, in login
self.installation_alias = self.installation.get_alias()
File “/usr/local/lib/python3.9/site-packages/pysecuritas/api/installation.py”, line 103, in get_alias
return self.get_sim_and_instibs()[“INSTALATION”][“ALIAS”]
File “/usr/local/lib/python3.9/site-packages/pysecuritas/api/installation.py”, line 94, in get_sim_and_instibs
return self.sync_request(“SRV”)
File “/usr/local/lib/python3.9/site-packages/pysecuritas/api/installation.py”, line 171, in sync_request
return self.request(payload)
File “/usr/local/lib/python3.9/site-packages/pysecuritas/api/installation.py”, line 183, in request
result = handle_result(result.get(“RES”), result)
File “/usr/local/lib/python3.9/site-packages/pysecuritas/api/installation.py”, line 40, in handle_result
raise RequestException(result[“MSG”])
pysecuritas.api.installation.RequestException: Hemos tenido problemas para identificarle, por favor, cierre la sesión y vuelva a iniciarla.

Any ideas…?
Thanks in advance

Hello,
thanks for this great module I’m using without problem until now.
I’m using the service from Italy with the new app and I was trying to use the Perimeter capability.
Just tried the pysecuritas PERI command (as you asked for) and it worked flawlessly.
I hope you will integrate this in the HA component/panel too.

pysecuritas -u xxxxxx -p xxxxxx -c IT -l it -i xxxxxx PERI
{
  "RES": "OK",
  "STATUS": "3",
  "MSG": "La modalit\u00e0 Perimetrale \u00e8 attiva",
  "NUMINST": "xxxxxxxx"
}
>pysecuritas -u xxxxxx -p xxxxx -c IT -l it -i xxxxxx DARM
{
  "RES": "OK",
  "STATUS": "0",
  "MSG": "L'Allarme \u00e8 stato disattivato",
  "NUMINST": "xxxxxx"
}

Regards and thanks in advance.

Dunno if this was already requested but… Is it possible to get the data from the sentinel (temp, humidity and air quality)? Thanks

Im having the same issue

ciao,
sono nuovo in questo mondo… sono riuscito a installare tutto ma anche io non riesco a inserire la modalità perimetrale. Come posso fare? credo che in qualche modo ci sei riuscito… grazie in anticipo

What version is the most recent/stable??

GitHub?

Dropbox link from this entry:

This is great, thanks because I was not able to test it. I am wondering if it would be easy to add this to the current version, probably using the custom bypass.

Hi, I have been able to arm the peri from the alarm panel in Home assistant. It seems the custom bypass was not active. so went to custom components folder and edit the alarm_control_panel.py and added the following line on the top:

 import homeassistant.components.alarm_control_panel as alarm
from homeassistant.components.alarm_control_panel.const import (
    SUPPORT_ALARM_ARM_AWAY,
    SUPPORT_ALARM_ARM_HOME,
    SUPPORT_ALARM_ARM_NIGHT,
   SUPPORT_ALARM_ARM_CUSTOM_BYPASS) 

and this on the bottom

 @property
    def supported_features(self) -> int:
        """Return the list of supported features."""
        return (SUPPORT_ALARM_ARM_HOME
                | SUPPORT_ALARM_ARM_AWAY
                | SUPPORT_ALARM_ARM_NIGHT
                | SUPPORT_ALARM_ARM_CUSTOM_BYPASS
)

Now clicking the custom bypass button in the alarm panel it works.

I hope it helps the ones trying to use the perimiter capability.

Hi everyone,

Here you can find my first attempt of having a functional component for using securitas direct in Home Assistant.

https://github.com/guerrerotook/securitas-direct-new-api

This component is using the same configuration as the old one and it’s using the new API that Securitas Direct migrated all users.

Please download the component and tell me what do you think. For now it’s functional and you can arm and disarm your alarm and also works with multiple installations in case that you have more that one alarm in you account.

If you have feedback please create a new issue in my repository.

Thanks!

Im trying to install it now. what parameters are required in the configuration.yaml file?