# Post notices to Telegram

A bot posts new lessons and dates to your Telegram groups and channels. You choose per product where they go.

Your platform posts a notice to Telegram when a lesson opens, or when a date is new or moves. The notice goes out 5 minutes later. Lessons that open per member (drip) get no notice. For this, you need a bot of your own. You manage who is in the groups in Telegram itself.

## 1. Create the bot

1. In Telegram, open @BotFather, send `/newbot` and follow the steps.
2. Open **Admin**, then **Integrations**, then the tab **Telegram**.
3. Copy the token from BotFather into the field **Bot token**.
4. Click **Add the bot**.

## 2. Add the bot to the group

1. Add the bot to your group.
2. In a channel, make it an admin with only the right "Post messages".
3. If the bot was in the group before, send `/start@your_bot` there once.

Under **Integrations**, **Telegram**, you then see each group with its state: **can post**, **no right to post** or **removed**.

## 3. Link chats to a product

1. Open **Admin**, then **Products**, then the product.
2. Open the tab **Telegram**.
3. Under **Available chats**, click **Add** next to the group.
4. Under **Added chats**, select the **Notices**: **New lesson**, **New date**, **Rescheduled date**.
5. Select the **Language** and, if needed, a **Cohort**. For groups with topics, enter the **Topic ID**.
6. Click **Save**.

Under **Custom texts**, you change the text of each notice. Placeholders such as `{lesson_title}` and `{lesson_url}` are under **Variables**. An empty text uses the default.

> [!WARNING]
> **Send a test** posts into the real chat. Your members see the test.

## When a notice goes out

- Notices go out 5 minutes later. This gives you time to correct a quick mistake.
- The platform collects several new lessons or dates into one message.
- A lesson gets a notice when you publish it for the first time.
- Lessons that open per member (drip) get no notice.

On the page of a lesson, **Telegram notice** shows when the last one went out. **Send notice again** sends it once more, with the current title.

**Recent notices** in the tab **Telegram** shows what went out and whether it worked.

## Direct messages to the bot

The bot only posts. When somebody sends it a direct message, it replies with a fixed text. You change that text under **Integrations**, **Telegram**, **Answer to a direct message**.
