Use sfrtvctl (control of stb7 decoder from SFR)

I have a set top box sfr tv7 and I want to control it by api.
I found this repository GitHub - dragouf/sfrtvctl: a tool to control SFR TV POWER edition (STB7) (thanks to dragout) using python
I installed on my linux machine (containing ha docker) and I can control my stb with command as

sfrtvctl --host STB7.local APP TVGUIDE

works fine.
I don’t know how to do that with HA
can I use this repository directly in HA (pyscript, python_script)

As I couldn’t get any information on the dragout repository, I created my own decoder.
Be indulgent, this is my first repository

Forking sfrtv from dragouf, created SFR Stb7 mediaplayer component

Searching websocket for STB8 box,It use the same port : 7682
but the command set is very small compared to the stb7
There are only 3 left:

  • buttonEvent corresponding to the buttons on the remote control
  • getStatus to know if the decoder is running
  • getVersions which returns stb8 type, mac address, software version

Unfortunately GetSessionsStatus has disappeared which returned a lot of information such as: the active channel, system paused…

I found this information by the apk “SFR TV8”
to be sure of the possibilities, I would need the Stb8CommandBuilder.kt file

Hello, I just read your post with interest! thank you . did you find something for the sfr box 8?

Hi, unfortunately nothing more.

Hello, i’ll be interested in a function to “getStatus to know if the decoder is running”
I’m controlling my STB8 via Tasmota IR but i have no info back on SFRTV box status (ON or OFF)
Could you explain me how to get a binary sensor for that ?