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

# Slack for OneCLI: Chat With Your Agents

> Slack is a place to talk to your agents, not a tool they call. Message an agent, approve its work from a card, and let teammates onboard themselves.

## Overview

Slack is not an app connection. Agents never call the Slack API as a tool, and there is no Slack credential to grant. It is a **channel**: a place where people talk to agents, in the same threads they already use for everything else.

Two things live here. Agents answer in Slack, and they ask for approval there, so the person who has to decide gets the question where they already are instead of in a dashboard they would have to remember to open.

Connecting takes one click.

## Connect Slack

<Steps>
  <Step title="Install the OneCLI app">
    In OneCLI, open **Settings** > **Channels** and select **Add to Slack**.

    <Frame caption="Team onboarding, on the Channels page in OneCLI.">
      <img src="https://mintcdn.com/chartdbinc/7LmoueGVCazrMm3S/images/integrations/slack/onecli-add-to-slack.png?fit=max&auto=format&n=7LmoueGVCazrMm3S&q=85&s=45c152889dcdab70bdb2bad61b757cb8" alt="The Team onboarding card in OneCLI, showing a Not installed badge, an Add to Slack button, and a link to connect with an App Configuration token instead." width="1160" height="460" data-path="images/integrations/slack/onecli-add-to-slack.png" />
    </Frame>

    Slack's consent page opens. If your workspace requires admin approval for new apps, the install completes on its own once an admin approves it, with nothing more to do in OneCLI.
  </Step>

  <Step title="Let teammates onboard themselves">
    Once installed, anyone in the workspace can DM the OneCLI app to get their own OneCLI account. No invitation, and no admin step per person.
  </Step>
</Steps>

<Note>
  Installing the app is an org-level action, so it needs someone who can install Slack apps in your workspace. After that, individual teammates need nothing.
</Note>

## What happens in Slack

| In Slack | What it does |
| - | - |
| **DM an agent** | Talk to it directly, the same as the chat in the dashboard |
| **Mention it in a channel** | Bring an agent into a thread your team is already having |
| **Approval cards** | Approve or deny a pending action without leaving Slack |
| **Reach requests** | Decide whether an agent may answer someone new: approve, limit to workspace members, or block |
| **Mirrored replies** | An agent's answer appears in the thread it was asked in |

Who may talk to an agent is still yours to set. An agent reached by someone new raises a reach request rather than answering, and you choose each time.

## Controlling access

Slack changes where the conversation happens, not what an agent may do. Its [grants](/docs/guides/agent-access) and your organization [rules](/docs/guides/rules) apply to every message, whether it arrived from Slack or the dashboard, and anything needing approval still waits for a human.

The card is the point. An agent about to send an email or spend money asks in the channel, and whoever is there answers in a click.

To disconnect, open **Settings** > **Channels** and remove the installation. You can also remove the OneCLI app from Slack's own app management page, which revokes its workspace token.

***

## Self-hosted: use your own Slack app

<Info>
  Skip this section on OneCLI Cloud. The shared app is already approved and installed in one click.
</Info>

A self-hosted deployment has no shared OneCLI Slack app, so it creates its own. OneCLI does the creating, and you supply one short-lived token to let it.

<AccordionGroup>
  <Accordion title="Get an App Configuration token">
    1. Open [api.slack.com/apps](https://api.slack.com/apps).
    2. Select **Generate Token** and pick your workspace.
    3. Copy the **Refresh Token**, not the Access Token.

    <Frame caption="The two Copy buttons look identical. Check the column heading.">
      <img src="https://mintcdn.com/chartdbinc/7LmoueGVCazrMm3S/images/integrations/slack/slack-app-config-token.png?fit=max&auto=format&n=7LmoueGVCazrMm3S&q=85&s=78d13d6b4013aad7f401566b550f6beb" alt="Slack's App Configuration Tokens table, with the Refresh Token column's Copy button highlighted next to the Access Token's identical button." width="1290" height="790" data-path="images/integrations/slack/slack-app-config-token.png" />
    </Frame>
  </Accordion>

  <Accordion title="Paste it into OneCLI">
    Open **Settings** > **Channels** and paste the token. OneCLI uses it to create the Slack app for your agents, then rotates it from then on.

    Paste it promptly. Each refresh token works only once, and a used or expired one has to be regenerated from the same page.
  </Accordion>
</AccordionGroup>

<Note>
  An App Configuration token can create and modify Slack apps in your workspace, so treat it like a password. It is also the only part of this setup that differs from Cloud, everything above this divider works the same way once the app exists.
</Note>

## Listing your app on the Slack Marketplace

Only relevant if you run your own Slack app and want to distribute it beyond your workspace. Slack reviews every listing, and its [guidelines](https://api.slack.com/start/distributing/guidelines) ask for a few pages you have to supply yourself.

| Field | What Slack expects |
| - | - |
| **Installation landing page URL** | A public page, not behind a login, built for the Slack app. It needs an **Add to Slack** button or install instructions, an explanation of what the app does in Slack, a link to your privacy policy, and a success page after install. Not a PDF or a repo link. |
| **Privacy policy URL** | What data you collect, how it is used, how long it is kept, and how someone requests access or deletion, with an email or web form to contact. |
| **Support URL** | A public way to reach a human, with replies within two business days, and no extra account required to ask. |
| **Categories** | Up to three. **Developer Tools** and **Productivity** fit OneCLI. |

For OneCLI Cloud these already exist: [onecli.sh](https://onecli.sh) is the landing page and [onecli.sh/privacy](https://onecli.sh/privacy) the policy.

<Note>
  Slack asks for an extra disclaimer when an app exposes people to a language model: say on the landing page and in the long description that outputs can be inaccurate. Slack also forbids training models on Slack data. Both matter for an agent app.
</Note>

Expect scope questions during review. Slack approves only scopes tied to features it can test and asks what each one is for, so keep the list to what the app actually uses.


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