> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ouraicalling.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Messaging channels (Telegram, Slack, Messenger)

> Connect text bots to assistants via Settings → Channels

Multi-channel text lets the same assistant answer customers on Telegram, Slack, Messenger, Microsoft Teams, Discord, Google Chat, X, and WhatsApp. Phone and WhatsApp **voice** use the platform’s voice stack; these messaging channels are text-only (WhatsApp voice shares the same Meta credentials as text).

## Tools (voice parity)

All seven messaging platforms share one reply pipeline. The assistant can use the same text-safe tools as on voice:

* API tools (HTTP)
* MCP tools (workspace + assistant servers)
* Knowledge base search
* Calendar integrations (native / Cal.com / Calendly)
* Built-ins: current time, business hours, send SMS, send email, schedule callback, set variable

Voice-only actions are skipped on text channels: call/assistant transfer, end call, DTMF/keypad, payment card collect. Email auto-replies use the same tool layer (`purpose=email`).

## Prerequisites

1. Your plan includes the channel you want to connect (Telegram, Slack, Messenger, Teams, Discord, Google Chat, X, WhatsApp text / WhatsApp voice).
2. The webhook base is your **base app URL** — either the platform host (e.g. `https://app.famulor.io`) or this workspace’s verified custom domain. You do not need access to server environment variables; the product builds webhook URLs for you after you connect a channel.
3. Platform AI for text replies is configured by the operator.

## Connect (product UI)

Settings → Channels → Telegram / Slack / Messenger:

1. Pick an assistant.
2. Connect with one-click where available (**Add to Slack**, **Connect with Facebook**) or paste bot credentials (manual fallback).
3. Configure conversation settings (below).
4. Save — Telegram webhooks are registered automatically; Slack/Messenger **BYO** need the shown webhook URL in their developer consoles. One-click installs use the shared platform webhook (no URL copy).

### Slack — Add to Slack

Preferred onboarding (platform domain / root workspaces only — not whitelabel hosts) uses the **shared Famulor Slack app**:

1. Settings → Channels → Slack → **Add to Slack**
2. User grants bot scopes in Slack → we store the bot token, signing secret (platform), and `team_id`
3. Platform operators configure Event Subscriptions once on the **base app URL** (`/api/webhooks/slack`) with Socket Mode **off**
4. Events are routed by Slack `team_id` to the workspace connector

Manual bot-token + signing-secret paste remains available as a fallback (per-connector webhook URL shown in Settings). Whitelabel hosts keep manual only (the shared bot would appear as Famulor).

Public API: `GET/POST /api/v1/slack/oauth` · MCP: `get_slack_oauth_config`, `start_slack_oauth`.

### Messenger — Connect with Facebook

Preferred onboarding (platform domain / root workspaces only — not whitelabel hosts) uses the **same platform Meta app** as WhatsApp:

1. Settings → Channels → Messenger → **Connect with Facebook** (HTTPS required)
2. User grants Page scopes → picks a Facebook Page → we create the connector and call `subscribed_apps`
3. Platform operators configure the Meta app-level Messenger webhook on the **base app URL** (`/api/webhooks/meta/messenger-platform`) and subscribe to **messages**
4. Events are routed by Page ID to the workspace connector

Manual page-token paste remains available as a fallback (per-connector webhook URL shown in Settings).

Public API: `GET/POST /api/v1/messenger/facebook-login` · MCP: `complete_messenger_facebook_login`.

## Conversation settings

Applies to every text channel (Telegram, Slack, Messenger):

| Setting                            | Default | Description                                                                                                                                         |
| ---------------------------------- | ------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Response delay (seconds)**       | `5`     | Slider `0`–`30`. Wait after the last customer message before one reply (merges quick multi-message bursts). `0` = reply instantly to every message. |
| **Inactivity timeout (minutes)**   | `30`    | Minutes of inactivity after the last customer message before the conversation is marked ended.                                                      |
| **Allow re-triggering**            | off     | If enabled, the conversation-ended webhook can fire again when the customer resumes an ended conversation and goes inactive again.                  |
| **Conversation ended webhook URL** | empty   | Optional HTTPS URL. Leave empty to disable. Use **Make test request** to send a sample payload.                                                     |

### Conversation ended webhook

When a conversation ends (inactivity timeout), the platform:

1. Marks the conversation as ended.
2. Runs the assistant’s **post-call analysis** variables against the chat transcript (same `analysis_config` as voice).
3. POSTs a JSON payload to your webhook URL (if set), including extracted variables.

Cron: `/api/cron/messaging-inactivity` (every minute on the platform).

## Platform apps you create

| Channel     | What you create                                                               | Key fields                                                                           |
| ----------- | ----------------------------------------------------------------------------- | ------------------------------------------------------------------------------------ |
| Telegram    | Bot via [@BotFather](https://t.me/BotFather)                                  | Bot token                                                                            |
| Slack       | Famulor Slack app (Add to Slack) or BYO Slack App (Bot + Event Subscriptions) | OAuth install; or bot token `xoxb-…` + Signing secret (BYO)                          |
| Messenger   | Platform Meta app (Connect with Facebook) or BYO Meta app + Page              | Page access token, App secret, Verify token (BYO); Facebook Login for preferred path |
| Teams       | Azure Bot                                                                     | App ID, App password                                                                 |
| Discord     | Discord Application                                                           | Bot token, Public key, Application ID                                                |
| Google Chat | GCP Chat app + service account                                                | Service account JSON                                                                 |
| X           | X developer app + Activity API webhook                                        | Consumer secret, OAuth user token (or client ID + refresh token)                     |

Webhook URL pattern:

`https://app.famulor.io/api/webhooks/messaging/{platform}/{connector_id}`

Host resolution (only these two — no reseller/subdomain fallback):

1. This workspace’s own verified custom domain, managed under **Tenant Admin → Settings → Domains**
2. Else the platform **base app URL**

Telegram `setWebhook` uses that same resolved URL automatically.

## Public API & MCP

* REST: `GET/POST /api/v1/messaging-connectors`, `PATCH/DELETE /api/v1/messaging-connectors/{id}`
* Slack OAuth: `GET/POST /api/v1/slack/oauth`
* WhatsApp templates: `GET/POST /api/v1/whatsapp/templates`
* WhatsApp outbound voice: `POST /api/v1/calls/whatsapp-outbound`
* MCP tools: `list_messaging_connectors`, `create_messaging_connector`, `update_messaging_connector`, `delete_messaging_connector`, `get_slack_oauth_config`, `start_slack_oauth`, plus WhatsApp template/call tools
* OpenAPI tag: **Messaging** / **Calls**

## WhatsApp

Full setup (credentials, webhook fields, templates, voice toggles): **[WhatsApp (Text + Voice)](/channels/whatsapp)**.

* **Text:** Meta Cloud API on `messaging_connectors` (`platform=whatsapp`), plan flag `whatsapp_channel`.
* **Voice:** platform WhatsApp voice connector on the same credentials — see [WhatsApp Voice](/telephony/whatsapp-voice), plan flag `whatsapp_voice`.
* **Templates:** `GET/POST /api/v1/whatsapp/templates` (+ MCP tools).
* **Outbound voice:** `POST /api/v1/calls/whatsapp-outbound`.
