Telegram Notifications Plugin (discourse-telegram-notifications)

Perhaps a dumb question, but what notifications should I expect to see via Telegram? The bot is up and running, I send it a message and get a Chat ID, I put that ID into my user profile, but despite having gotten a couple of email notifications since that time, I haven’t seen anything on Telegram. Should I have, or is there someplace else I need to set up those notifications?

If logs are needed to help figure this out, I’m fine with posting them, but I’ll need some guidance on where to look for them.

Proofreading always helps–turns out I’d (apparently, though I never saw the error) entered the Chat ID incorrectly. Now that it’s re-entered, notifications work as expected. Cool!

3 إعجابات

Hi. I’m trying to get this configured but I’m stuck on trying to get the Bot to send me the Chat ID. No matter what i type, I get no response.

First I created the bot following the directions.
Then I created a Group in Telegram and add the bot as a member.
Then i try to send a message, even tagging the bot and still no response.

I even try to create a channel and message the bot but still no response.
I even tried doing it through the desktop pp and through my mobile phone app, still no luck.

Im not sure what else to do.

Also, Do i need both, discourse-chat-integration and discourse-telegram-notifications installed?

I don’t see anywhere in the docs that it says to create a group, and in fact I see a recommendation to disallow the bot from being added to a group. Send a message directly to the bot, not to a group that includes the bot.

According to the OP (it’s even in a shaded box at the top), they do different things:

إعجاب واحد (1)

thanks for the input, ill try again.

Can I use Chatroom Integration Plugin & Telegram notification plugins at the same? I have integrated chatroom integration plugin successfully and its working fine, but Telegram notification plugin is not notifying users. The bot just show me this!

testbot, [28.12.19 15:58]
Hi Administrator, I'll message you when you have new notifications on Engineer's Asylum. 
Replying to a notification will post a reply on Engineer's Asylum.
To disable, visit your user preferences.

From the OP:

I haven’t done it myself, but that appears to answer the question.

إعجاب واحد (1)

I found where i went wrong, i was putting the access token in the chat integration plugin area, i found the one in the plugins settings area for telegram, messaged the bot and I got a response!

Blockquote Im still not getting the bot to respond and provide me the chat id via telegram. I tried to send a message to the bot itself. i tried to create a channel via telegram and tag the bot with a message. still i got nothing

Have you found a fix for this? I got this issue too.

لقد فتحت للتو هذا الطلب في الإضافة:

وهو يضيف دعمًا لذلك السلسلة النصية، وكذلك لإضافة Discourse Follow Plugin
آمل أن يقوم الموظفون بدمجه قريبًا

يبدو رائعًا، لقد دمجتُها للتو - شكرًا لك @barreeeiroo :smiley:

4 إعجابات

إذا كنت تخطط لتوسيع هذا المشروع ليشمل إشعارات عبر Viber ورسائل SMS، فراجع مشروعي على GitHub - Sprachprofi/notifications_sample: Demonstrating how to cleanly handle opt-in/opt-out and notifications via a variety of platforms · GitHub

إعجاب واحد (1)

@david
ملحق مفيد جداً، شكراً لك! :blush:

هل يمكنني استخدام {name} بدلاً من {username} في الترجمات؟

للأسف لا، فهذا سيتطلب تغييرًا في كود الإضافة

4 إعجابات

مرحبًا @david، يبدو أن البوت الخاص بي لا يعمل أحيانًا… لقد تحققت من الرمز المميز (token) وشهادة SSL للموقع، وكلها تبدو جيدة… هل لديك أي أفكار؟

لقد راجعت السجلات (logs) وجميعها تتعلق بالرسائل الخاصة:
فشل في إرسال رسالة عبر تيليجرام. بيانات الرسالة = “… رسالة خاصة …”

/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/logster-2.5.1/lib/logster/logger.rb:112:in `report_to_store'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/logster-2.5.1/lib/logster/logger.rb:103:in `add_with_opts'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/logster-2.5.1/lib/logster/logger.rb:54:in `add'
/usr/local/lib/ruby/2.6.0/logger.rb:543:in `error'
/var/www/discourse/plugins/discourse-telegram-notifications/services/discourse_telegram_notifications/telegram-notifier.rb:46:in `doRequest'
/var/www/discourse/plugins/discourse-telegram-notifications/services/discourse_telegram_notifications/telegram-notifier.rb:7:in `sendMessage'
/var/www/discourse/plugins/discourse-telegram-notifications/plugin.rb:234:in `execute'
/var/www/discourse/app/jobs/base.rb:232:in `block (2 levels) in perform'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/rails_multisite-2.0.7/lib/rails_multisite/connection_management.rb:63:in `with_connection'
/var/www/discourse/app/jobs/base.rb:221:in `block in perform'
/var/www/discourse/app/jobs/base.rb:217:in `each'
/var/www/discourse/app/jobs/base.rb:217:in `perform'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:196:in `execute_job'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:164:in `block (2 levels) in process'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/middleware/chain.rb:138:in `block in invoke'
/var/www/discourse/lib/sidekiq/pausable.rb:138:in `call'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/middleware/chain.rb:140:in `block in invoke'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/middleware/chain.rb:143:in `invoke'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:163:in `block in process'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:136:in `block (6 levels) in dispatch'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/job_retry.rb:111:in `local'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:135:in `block (5 levels) in dispatch'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq.rb:37:in `block in <module:Sidekiq>'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:131:in `block (4 levels) in dispatch'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:257:in `stats'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:126:in `block (3 levels) in dispatch'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/job_logger.rb:13:in `call'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:125:in `block (2 levels) in dispatch'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/job_retry.rb:78:in `global'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:124:in `block in dispatch'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/logger.rb:10:in `with'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/job_logger.rb:33:in `prepare'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:123:in `dispatch'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:162:in `process'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:78:in `process_one'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/processor.rb:68:in `run'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/util.rb:15:in `watchdog'
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/sidekiq-6.0.4/lib/sidekiq/util.rb:24:in `block in safe_thread'

مرحباً.
نفس المشكلة مع تثبيت هذه الإضافة..

المشكلة والحل:

المشكلة:
كنت مشوشًا جدًا بين الإضافتين، وبين روبوتيي تيليجرام، وبين محادثتي تيليجرام (قناة تيليجرام ومجموعة تيليجرام). وفي هذا الارتباك، كان يُعطاني دائمًا حقل واحد باسم “رمز تيليجرام” أو ما شابه ذلك. لكنني استمررت في الخلط بينهما.

الحل:
في النهاية، اكتشفت أنه في إعدادات Discourse، يوجد حقلان مختلفان، لهما تسميات/أسماء متشابهة جدًا، ويقعان بجوار بعضهما البعض تمامًا، لكنهما، حسنًا، لَيسَا نفس الشيء.

لذلك، يرجى ملاحظة أن هذين شيئين مختلفين، ولهما أغراض مختلفة:

لاحظت أن محادثات قناة تيليجرام/المجموعة لم تعد تُبلغ/تستجيب لأمر /getchatid. لا يمكننا أن نجعلها تكشف معرف الدردشة الخاص بها بالطرق العادية. في السابق، كلما أنشأنا روبوتًا جديدًا، كان يقول معرفه تلقائيًا بمجرد بدء محادثة معه. لكن لم يعد يتصرف بهذه الطريقة.

هل من الممكن تنفيذ إمكانية استلام إشعار عند وجود منشور في انتظار الموافقة؟

مرحبًا @david!
أولاً، شكرًا لك على هذا الإضافة. لقد تم إعدادها بالكامل وتعمل بشكل ممتاز، ولا يسعني الانتظار للإعلان عنها للمجتمع.
ومع ذلك، لديّ بضعة أسئلة:

  1. كيف يمكنني ترجمتها إلى لغتي الخاصة لتسهيل الأمور أكثر على مجتمعنا؟

  2. هل توجد طريقة، سواء عبر Telegram أو Discourse، للتحكم في مظهر رسالة Telegram؟ الخط غير جذاب، وهناك مسافتان فارغتان بين كلمات النص الفعلي المرسَل من Discourse (بينما نصوص الإضافة تبدو جيدة تمامًا).

أنا أيضًا. لا يعجبني حقًا كيف يبدو.

من الجيد سماع أن هذا لا يزال يعمل. أعتقد أنني سأجرب هذا على مجتمعي.