From 06b6e4b10332effebdba78e2cf931590c3d9f9e4 Mon Sep 17 00:00:00 2001 From: Adam Dullage Date: Sun, 30 Jul 2017 18:37:08 +0100 Subject: [PATCH] Clarified requirements for allowed_chat_ids parameter (#3068) * Clarified requirements for allowed_chat_ids parameter I'm not 100% sure on this but my tests seem to back it up. Unless I list both the chat id and my user id in the allowed_chat_ids parameter then I receive a "Incoming message is not allowed" message in the HA log. * Provided instructions to obtain user id --- source/_components/telegram_bot.webhooks.markdown | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/_components/telegram_bot.webhooks.markdown b/source/_components/telegram_bot.webhooks.markdown index aacbdffe549..6eeb57f597c 100644 --- a/source/_components/telegram_bot.webhooks.markdown +++ b/source/_components/telegram_bot.webhooks.markdown @@ -36,13 +36,13 @@ telegram_bot: Configuration variables: -- **allowed_chat_ids** (*Required*): A list of user in the `user_id` Telegram format enabled to interact to webhook +- **allowed_chat_ids** (*Required*): A list of ids representing the users and group chats that are authorised to interact with the webhook. - **api_key** (*Required*): The API token of your bot. - **trusted_networks** (*Optional*): Telegram server access ACL as list. Defaults to `149.154.167.197-233`. - **parse_mode** (*Optional*): Default parser for messages if not explicit in message data: 'html' or 'markdown'. Default is 'markdown'. - **url** (*Optional*): Allow to overwrite the `base_url` from http component for diferent configs. -To get your `chat_id` and `api_key` follow the instructions [here](/components/notify.telegram) . +To get your `chat_id` and `api_key` follow the instructions [here](/components/notify.telegram). As well as authorising the chat, if you have added your bot to a group you will also need to authorise any user that will be interacting with the webhook. When an unauthorised user tries to interact with the webhook Home Assistant will raise an error ("Incoming message is not allowed"), you can easily obtain the the users id by looking in the "from" section of this error message. Full configuration sample: