Skip to content

Telegroam: a bridge between Roam and Telegram. 🤩 When Roam Research receives one message, it automatically returns a previously random note 😁, based on https://github.com/mbrock/telegroam

Notifications You must be signed in to change notification settings

JimmyLv/telegroam

Repository files navigation

Feature

When Roam Research receives one message, it automatically returns a previously random note:

CleanShot 2022-02-18 at 16 14 15@2x

Installation

  1. In Telegram, talk to @BotFather to create a new bot and get an API key for it.
  2. Send something to your bot in a private message.
  3. Make a page in your Roam called [[Telegram Bot]].
  4. Paste these nodes somewhere on the [[Telegram Bot]] page:
- Inbox Name:: [[Inbox]]
- API Key:: insert key you get from Telegram's bot system
  - {{[[TODO]]}} update the Telegram API key above
- Chat Id::
- Serendipity Page:: [[TODO]]
- BibiGPT API URL:: https://bibigpt.co/api/open/[apiToken]
- Trusted Media Proxy:: https://tg.aipkm.com/tg
- Latest Update ID::

How to get your BibiGPT.co Open API URL? https://aitodo.co/docs/bibigpt-api 5. Make a block with the text {{[[roam/js]]}}. 6. Add a nested CHILD block /JavaScript Code Block with this code...

var existing = document.getElementById("telegroam");
if (!existing) {
  var extension = document.createElement("script");
  extension.src = "https://tg.aipkm.com/main.js";
  extension.id = "telegroam";
  extension.async = true;
  extension.type = "text/javascript";
  document.getElementsByTagName("head")[0].appendChild(extension);
}
  1. Press the BIG RED button to enable the script and refresh the page.

Q&A

  1. How to get your Telegram chat id?

option 1: https://t.me/getmyid_bot

This TG bot will send you your telegram user ID, current chat ID and sender ID or chat ID of forwarded message.

20220408-Telegram-001263@2x

option 2: if you are FE dev, just open the Chrome DevTool, as you can see

  1. How to select the block content that Bot is replying to?

Just change the [[TODO]] in Serendipity Page:: [[TODO]] to your own tag, such as [[ZK]] or [[Zettel]]

About

Telegroam: a bridge between Roam and Telegram. 🤩 When Roam Research receives one message, it automatically returns a previously random note 😁, based on https://github.com/mbrock/telegroam

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published