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

# Talk to Apostra in Slack, Teams, Discord, or WhatsApp

> Authorize Apostra in Slack or connect a branded Teams, Discord, or WhatsApp app, then approve its people and locations

Your team can talk to Apostra where they already work: Slack, Microsoft Teams,
Discord, or WhatsApp. Each connection belongs to one Apostra account.
People still receive only the data and actions their linked Apostra
membership allows.

> [!NOTE]
>
> On the seller's Listing page, the Distribution tabs show each messaging
> channel's status: Slack always appears, showing **Install in Slack** once
> Apostra's Slack app is publicly available — until then it shows
> **Coming soon**. Microsoft Teams, Discord, and WhatsApp appear as tabs once
> the account is in early access for branded apps; until then they are
> offered in the **+ Add destination** picker. Every tab links to the secure
> setup pane (**Settings → Messaging apps**), where provider client secrets,
> bot tokens, Meta access tokens, and app secrets are entered — never in
> email, chat, or a support ticket. Buyer accounts, which have no Listing
> page, manage the same apps directly from **Settings → Messaging apps**.
> Branded messaging apps are currently available only to accounts enrolled in
> the pilot; the secure setup pane shows when the account is not enabled.
> Enrollment controls setup and administration only; it does not stop an
> already active provider installation.

## Open messaging destinations

**Settings → Messaging apps** lists every channel the same way: one card per
provider — Slack, Microsoft Teams, Discord, and WhatsApp — each carrying what
that provider needs. Whether Apostra owns the underlying app or you register
your own with the provider is a difference in what each card asks you for, not
a division of the page. The Listing page's Distribution tabs are the other way
in, one tab per channel:

* **Slack** opens Slack's authorization flow in a new tab, once Apostra's
  Slack app is publicly available. Slack is the one channel with no app to
  register and no credentials to enter. Finish authorization in Slack;
  Apostra does not show its installation status yet. Until the app is
  available, Slack shows **Coming soon**.
* **Microsoft Teams**, **Discord**, and **WhatsApp** each show a **Set up in
  Settings** button (**Manage in Settings** once an app already exists) that
  opens the secure setup pane. There, connect a Discord, Microsoft Teams, or
  WhatsApp app you created with the provider to the current Apostra
  account. Each registered app then shows the provider webhook endpoint,
  credential readiness, approved install locations, and linked people.

Every tab always carries a status chip: **Install available** once the
Slack app is public, **N connected** once at least one branded app is
registered for that channel, or **Not set up** before the first one is
registered. Only account admins additionally get the button to act on it —
**Install in Slack**, **Set up in Settings**, or **Manage in Settings**;
everyone else sees just the chip.

Each channel's Distribution tab lists at most 20 branded apps. Once a channel
has more than that, the tab shows the first 20 followed by a note reading
"Showing 20 of *N* branded apps — manage the full list in Settings," where
*N* is the channel's true total; the rest of the roster still exists and is
reachable from **Settings → Messaging apps**.

Shared Discord, Teams, and WhatsApp apps are not available. Customer-branded
Slack apps are also not available. WhatsApp is always reply-only. It does not
initiate conversations or send proactive or template notifications.

## Choose a channel

| Channel | Where people can talk to the agent | How a conversation starts | Product-initiated notifications |
| - | - | - | - |
| Slack | Personal chat and an approved workspace channel | Send a message, or mention Apostra in a channel | Supported only for approved events and destinations captured from the authorized workspace |
| Microsoft Teams | Personal chat and an approved team or channel | Send a personal message, or mention the app in a channel | Supported only for approved event types and locations where the app is installed; rollout is controlled per installation |
| Discord | A user install or an approved server channel | Run `/ask`, or mention the app in a server channel | Supported only for approved event types and authorized install targets; rollout is controlled per installation |
| WhatsApp | A direct conversation with the registered business number | The person sends a text message | Not supported. The app replies only inside Meta's current user-initiated customer-service window |

Slack, Teams, and Discord keep separate conversations for separate install
locations. In Teams, a channel thread also keeps its own context. The initial
Discord experience correlates follow-up `/ask` commands but does not promise a
native Discord thread.

## Start a new conversation

Ordinary follow-up messages in the same approved location keep the linked
person's Apostra context for up to 24 hours after the most recent message. After
24 hours without a message, Apostra automatically starts a new Apostra
conversation before handling the next message. Messages and files from the
expired conversation are not included. In an enabled branded app, use the
reset command when you want to start over sooner:

* In a Discord `/ask`, enter `/reset` as the entire `question`. In an approved
  server channel, mention the bot followed only by `/reset`.
* In a Teams personal chat, send `/reset`. In an approved channel thread, reply
  in that thread and mention the app followed only by `/reset`.
* In WhatsApp, send `/reset` as the entire message.

Apostra creates a new conversation for that person in that provider
location. The next message does not include messages or files from the previous
conversation.

The reset applies only to the linked Apostra member who sent it and only in
that provider conversation or thread. It does not reset another person's
context, another channel, or another account. It also does not delete the old
provider transcript or Apostra audit history; it changes which Apostra
conversation receives future messages. The shared Slack app follows its
existing channel and thread behavior and does not support this branded-app
`/reset` command.

## What you need before setup

Prepare the following for every branded app:

* A display name, short description, support URL, privacy-policy URL, and
  optional terms URL.
* Reviewed square and outline artwork that meets the provider's current app
  requirements, plus an accent color where supported.
* Apostra account the app should use with Apostra.
* The exact people and install locations that should be allowed to use it.

A branded setup uses a separate provider registration for the client. It is not
a theme that changes one shared marketplace listing per installation. Provider
naming, publisher, artwork, review, and app-count policies still apply.

## Pilot rollout

Start with one test location and a small group of active Apostra members.
Test Discord `/ask` and a Teams personal chat first, then channel mentions. Add
WhatsApp after Meta approves the business and phone number because WhatsApp is
reply-only.

## Slack setup

1. On the Listing page, open the **Distribution → Slack** tab and select
   **Install in Slack**. (A buyer account opens **Settings → Messaging apps**
   directly.)
2. In the new tab, choose the Slack workspace and approve the requested access.
3. Finish authorization in Slack. Apostra does not show the installation
   result yet, so a completed Slack confirmation is the source of truth.
4. Message Apostra directly, or add it to an approved channel and mention it.
   Access to account data still depends on the person's active Apostra
   membership and the channel's approved account binding.

For the permissions the Slack app asks for and what it does with messages, see
[Apostra in Slack](https://docs.apostra.com/v3/slack-app.md).

This shared Slack app is separate from the incoming webhook used for account
notifications. Authorizing Apostra does not configure the notification webhook or
its event filters.

## Microsoft Teams setup

1. Your Microsoft 365 administrator creates or approves the Microsoft Entra
   application and Azure Bot registration for the branded app. The Bot's
   messaging endpoint is the HTTPS endpoint supplied during Apostra
   provisioning.
2. Apostra generates a Teams app package bound to that exact application ID.
   Review its display name, descriptions, publisher links, accent color, and
   192 px color and 32 px outline icons.
3. Your administrator uploads the package for a pilot or approves it through
   the organization's Teams app policy. Marketplace publication is optional
   for a controlled pilot.
4. Install the app in each approved personal, team, or channel location. Team
   and channel installation does not by itself grant Apostra access.
5. Link each Microsoft Teams user to an active member of the same Apostra
   account. An unlinked person receives a link-account prompt and no account
   data.
6. Test a personal message, then mention the app in an approved channel. A
   channel message that does not mention the app is ignored.

The runtime validates the Microsoft bearer token, issuer, and exact app
audience before reading a message. The app does not accept an email address or
UPN as a destination for a notification. A proactive message, when enabled,
can go only to a conversation captured from an active installation.

> [!NOTE]
>
> The initial Teams package requests `personal` and `team` bot scopes. Group
> chat remains disabled until its separate installation lifecycle is supported.
> These scopes identify an install location; they do not replace Apostra
> membership or identity linking.

## Discord setup

1. Create or approve the client's Discord application and branded bot in the
   Discord Developer Portal.
2. On the Listing page, open the **Distribution → Discord** tab (or the **+
   Add destination** picker if the account is not yet in early access) and
   select **Set up in Settings**. (A buyer account opens **Settings →
   Messaging apps** directly.) Then open **Discord → Add a branded app**.
   Enter the application's ID, public key, bot token, display name,
   description, and legal links. Copy the interaction endpoint that
   Apostra returns into Discord's **Interactions Endpoint URL** field.
   Leave **Linked Roles Verification URL** empty.
3. In the Discord Developer Portal, configure the interaction endpoint,
   Guild/User Install settings, and exact global `/ask` command on the matching
   application.
4. Choose user installation, server installation, or both. For a server
   install, approve only the servers and channels where the agent should be
   used.
5. Register each approved install location in the secure setup pane, then link
   each Discord user to an active member of the same Apostra account.
6. Run `/ask question:...` in an approved direct or server context. The app
   acknowledges the command immediately and edits that response when the
   agent finishes.
7. In an approved server channel, mention the installed bot and add the
   question. Only explicit mentions are accepted; unrelated channel messages
   are ignored before account lookup.

The app uses signed HTTP interactions for commands and a singleton Gateway
worker for explicit server mentions. It does not read general server chat or
request Discord's Message Content privileged intent. A bot token is needed for
the Gateway and durable app-initiated delivery and is stored as a secret, never
in the app definition returned to an administrator.

### Existing Apostra installations

An existing Discord installation can be renamed to **Apostra** without asking
members to reinstall it. Apostra keeps the same Discord application ID, bot
token, public key, interaction endpoint, install settings, permissions,
approved locations, linked people, and conversation references. The `/ask`
command stays `/ask`; it has no product name, so there is no second command or
compatibility period to learn.

Your administrator must first confirm whether the Discord app is verified. If
it is verified, Discord restricts application and bot username changes and the
administrator must request the change from Discord Developer Support before
changing anything. If the rename is allowed, the administrator changes the
application name and bot username to **Apostra**, uses the registered purple
Apostra icon, and verifies the result in an existing server and DM before
rolling it out more widely. Contact [Apostra Support](mailto:support@apostra.com)
if your existing install does not show the new name after that check.

## WhatsApp setup

1. In Meta Business Manager, complete the business, display-name, app, WhatsApp
   Business Account, and phone-number steps required for production Cloud API
   access.
2. Provision the exact Meta app, WhatsApp Business Account, and registered
   phone-number IDs with Apostra. Enter the app secret, system-user access
   token, and a unique webhook verification token only in the secure flow.
3. Configure the supplied HTTPS callback in the Meta app using the same
   verification token and subscribe the app to the WABA `messages` field.
4. Link each WhatsApp user ID to an active member of the same Apostra
   account.
5. From that phone, send a current text message to the registered business
   number and verify that the reply arrives in the same conversation.

WhatsApp is intentionally reply-only. Apostra does not expose template
messages, scheduled messages, broadcasts, arbitrary recipients, or proactive
notifications on this channel. Status events and non-text messages are
acknowledged but do not invoke the agent. If the user-initiated service window
has closed before the answer is ready, the service does not send it.

## Approvals and secure forms

When an agent proposes a governed change, Teams shows **Approve** and
**Cancel** actions in an Adaptive Card and Discord shows equivalent buttons.
Only the linked person who requested the change can use those controls, in the
same provider conversation and before the confirmation expires. A control is
single-use; removing the person's membership, identity link, installation, or
app access also makes a pending control unavailable.

WhatsApp does not receive interactive approval controls. The agent instead
asks for the exact typed confirmation in the active user-initiated conversation.
This remains a synchronous reply path and does not enable later notifications.

Never paste passwords, API tokens, access keys, or other credentials into any
of these chats. Teams and Discord provide a link action to the scoped secure
credential form when one is needed. WhatsApp returns the same HTTPS handoff as
text. Submit the form outside the provider transcript, then reply `done` in the
conversation to continue.

## Permissions and safety

Provider installation proves where the app is installed; it does not prove
who the sender is inside Apostra. Every sender must be explicitly linked
to a current account member. Removing that membership, identity link, or
installation stops new agent turns at that boundary.

Credentials are encrypted and never returned by the provisioning API. Raw
provider user, tenant, channel, server, and phone identifiers are not used as
Apostra authorization. Provider events are authenticated and deduplicated
before the agent runs.

## Settings pane

Administrators of an account in the messaging-apps pilot create and manage apps
in the secure setup pane (**Settings → Messaging apps**, reached from the
Listing page's Distribution tabs for seller accounts). The pane provisions
customer-owned apps, install locations, credentials and identity links. API
keys, service tokens, simulated sessions, staff impersonation and a linked
provider identity are not administrator credentials for it. The account REST
routes behind the pane are described in the
[messaging apps REST reference](https://docs.apostra.com/v2/guides/messaging-apps-routes); V3 has no tool
for them yet.

## Pilot acceptance checklist

* Branding and legal links match the client and have provider approval where
  required.
* An account administrator has approved every installation and identity link.
* An unlinked user cannot retrieve account data.
* A linked user can complete at least two turns in the same conversation.
* After 24 hours without a message, the linked user's next message starts a
  new Apostra conversation without messages or files from the expired context.
* In a branded Discord, Teams, or WhatsApp app, `/reset` starts a new Apostra
  conversation for that linked person. The next turn has no messages or files
  from the previous conversation, while another member's context is unchanged.
* Teams channel messages work only when the app is mentioned.
* Discord works through `/ask` and explicit guild-channel mentions without
  access to unrelated message content.
* Teams and Discord approvals can be used once only by the linked requester in
  the original conversation; another user or location is rejected.
* A credential request opens the scoped secure form and never asks for a secret
  in the provider transcript.
* WhatsApp replies only to a current inbound text from the same person and
  never initiates a conversation.
* Removing an identity or installation prevents later use.

For a failed pilot, record the provider, branded app name, install location,
approximate UTC time, and the safe error shown to the user. Do not include
tokens, secrets, raw webhook payloads, or personal message content.

## Provider references

* [Microsoft Teams app packages](https://learn.microsoft.com/en-us/microsoftteams/platform/concepts/build-and-test/apps-package)
* [Microsoft Teams proactive messaging](https://learn.microsoft.com/en-us/microsoftteams/platform/bots/how-to/conversations/send-proactive-messages)
* [Microsoft Teams card actions](https://learn.microsoft.com/en-us/microsoftteams/platform/task-modules-and-cards/cards/cards-actions)
* [Discord interactions](https://docs.discord.com/developers/interactions/receiving-and-responding)
* [Discord user-installable apps](https://docs.discord.com/developers/tutorials/developing-a-user-installable-app)
* [WhatsApp Business Platform](https://www.postman.com/meta/whatsapp-business-platform/overview/)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.