Skip to main content

Posts

Showing posts from June, 2018

Control OpenHab using Telegram Messenger

Recently, I've been trying to discover a way to control my OpenHab instance using Google Assistant. It is rather easy to do this using  IFTTT , but only when You use OpenHab in a cloud. I prefer using private instalation of OpenHab in my LAN, so that was not an option for me. I was searching for another solution, but only app supported by IFTTT which might be usefull form me was Telegram messenger. The only problem is, that OpenHab does not support Telegram controling by default. I google'd a little and it turned out that Telegram has a great public API with good Java support, so I decided to write a simple Spring Boot application as a bridge between Telegram Bot and OpenHab instance. You can find source code of my application on my GitHub account: https://github.com/aogorek/openhabtelegrambot In order to run it there are few steps required: 1. Create Bot in Telegram Messenger First You have to create Your own bot to communicate with. You need to contact @BotFather