Skip to content

Telegram

GitNotify in Telegram is one bot, @gitnotify_app_bot. You add it to a private group, it makes a topic pair per repository, and it posts live cards there as messages it edits in place. There is nothing to install and no OAuth page: Telegram tells GitNotify when the bot is added to a group.

You need to be a creator or administrator of the group, and an admin of the GitHub repositories you want to follow. Install the GitHub App on the account that owns them first, or from the repository picker in step 4.

  1. Make a private group. A group with a public link (a t.me/<name> username) is refused, because anyone could read its cards. Turn Topics on in the group settings so each repository gets its own topics. Without Topics, cards go to the group itself.

  2. Add @gitnotify_app_bot to the group. It says hello and records the group.

  3. Make the bot an admin with Manage Topics. A group admin does this in the group's administrator settings. /status says what is still missing.

  4. Connect repositories. A group admin runs /connect. GitNotify sends a one-time GitHub sign-in button by private message, never in the group, because anyone in the group could open a link posted there. The link works once, lasts 10 minutes and is bound to that group and that admin. Only repositories the admin administers and where the GitHub App is installed are offered.

    If the bot can't message you yet, it says so and gives you a button to open a chat with it. Press Start there, then run /connect again.

  5. Make the topics. A group admin runs /setup. GitNotify makes two topics per connected repository:

    • <repo> · activity for pull requests
    • <repo> · deploys for CI and deploys

    When Topics are off, or the bot can't manage them, both kinds of card go to the group itself. A group can follow at most 50 repositories. Running /setup again only adds what is missing.

  6. Have your team link themselves. Each member runs /link, then /notify mention, dm or off. See Notifications and linking.

  7. Optionally, turn on digests. An admin can turn on a team digest and members a personal one with /digest. See Digests and email.

Telegram commands are short and separate, such as /status and /setup. In a group with other bots, add the bot's name: /setup@gitnotify_app_bot. In this table, admin means a Telegram group creator or administrator.

Replies appear in the group, or the topic, where the command was run. Sign-in links and secrets arrive by private message instead. In a private chat with the bot, only /help answers, and the rest explains that GitNotify works in groups.

Command Who Does
/help anyone lists the commands and what GitNotify does
/status admin the bot's role in the group (admin, Manage Topics, Topics on or off), connected repositories and where their cards go, anything needing repair, how many people are linked, and the group's digest schedules
/connect admin, who must also be a GitHub repository admin a one-time GitHub sign-in link, sent privately, to choose repositories for this group
/setup admin makes the topics, or routes to the group itself, for every connected repository not set up yet
/repair admin recreates deleted topics, moves group routes into topics once the bot can manage them, and falls back to the group when it can't. Routes paused because GitHub access was suspended stay paused
/link anyone proves your GitHub id and login in this group. The sign-in link arrives privately. GitNotify reads only /user and revokes the GitHub token straight away. A newer link replaces an older one for that GitHub account in this group
/notify mention|dm|off anyone linked chooses review and incident notifications in this group. dm is saved only after a private confirmation arrives. Cards keep updating when notifications are off
/digest team <zone> [times] admin posts the team digest where you run it (the group or that topic) at those local times, and skips it when there is nothing to say
/digest me <zone> [times] [email] anyone linked schedules your own digest by private message (the default) or email. Built-in email sends a test first. Relay email needs a tested relay
/digest email [address] admin with no address, sends you the group's email relay secret privately. Run it again with the relay's HTTPS address to test it. Built-in email needs no relay
/digest off me|team|email anyone linked for me, admin for team or email stops your digest, the team digest or the group's relay. Turning relay email off sets personal email digests to off, because nobody is messaged before pressing Start
/digest preview anyone linked, or admin sends your own digest preview privately if you are linked. An admin who isn't linked gets the team digest in the group
/forget_me anyone asks first, with two buttons only you can answer, then removes your link, notification records and personal digest in this group

Telegram commands can't contain a -, hence /forget_me.

Limits and checks:

  • Every command is limited per group to five a minute. Over the limit, the bot doesn't reply, because a "slow down" reply would use the group's message budget.
  • /connect, /setup, /repair, /link and the team and email digest commands are also limited per group and person.
  • Admin commands check your role with Telegram every time. A command sent as an anonymous admin gets a short note asking you to turn Remain anonymous off for a moment, because Telegram hides who sent it.
  • There is no people or access command. Use /status for the linked count, and Telegram itself to invite members.

Cards are posted once and then edited in place as things change, as HTML text of at most 4,096 characters with link buttons. Run cards with an open incident carry I'll take it and Hand to buttons for the people linked in the group (Incidents and owners).

Each group has its own delivery queue. It folds bursts of changes over 3 seconds into one edit, and waits out Telegram's own retry_after for that group only. Telegram allows about 20 messages a minute per group, so one busy group never holds up another. Mentions and digests share that same queue.

If someone deletes a topic, the repository's route is paused and /status shows "needs /repair". /repair recreates the missing topics, moves routes into topics once the bot can manage them, and falls back to the group itself when it can't.

If the group is upgraded to a supergroup, Telegram gives it a new id. GitNotify moves its connections, routes, links and digests to the new id by itself.

Mentions use Telegram's user-id links, built only from the stored id of a person who linked themselves. Any @ inside GitHub text gets an invisible joiner after it, so a pull request title can't ping anyone. People who chose dm need to have pressed Start in a chat with the bot once, because a bot can't message someone first.

  • Privacy mode is on, Telegram's default for bots. In a group, Telegram then delivers to the bot only commands, replies to its own messages and button presses. GitNotify also asks Telegram for just three kinds of update: messages, button presses and changes to its own membership.
  • Everything that is not a command, a group upgrade, a membership change or a button press is dropped unread. No reply, no write and no log of its content. A command meant for another bot (/x@otherbot) is ignored.
  • Public groups are refused. A group with a public username can be read by anyone, so GitNotify answers with a short refusal and never records it as active. A group that turns public later is paused, and its data is deleted after 30 days. Remove the public link and run a command to bring it back.
  • Every update must carry GitNotify's webhook secret, which is checked before anything else is read.
  • GitNotify never creates groups or channels. People make the group, and GitNotify only makes topics in it. Telegram channels are not supported.

See What GitNotify reads and Security model.

When the bot is removed from a group, Telegram tells GitNotify. The group is marked removed and its routes stop. After 30 days the group's data is deleted. The messages already posted stay in the group. See Data and retention.