# Enable Slack User Groups for AI Mentions

> Let Type.com create Slack User Groups so people can mention the managed agent of a specific Space in Slack, for example @sales-operations.

Canonical page: https://docs.type.com/automations/slack-user-groups/

Type.com uses Slack User Groups to create Space-specific handles, for example `@sales-operations`. The handle comes from the handle of the Space's agent. When you connect a Slack channel to a Space in the **@mentions** or **Channel messages** mode, Type.com tries to create the User Group. The **Every message** mode does not use a User Group. People can then mention the Space handle, and Type sends the mention to the managed agent of that Space.

User Group handles apply to Slack channels connected to a Space. See [Slack channels connected to a Space](https://docs.type.com/automations/slack/index.md#slack-channels-connected-to-a-space). A Slack automation that you create with **New automation → Slack** responds to mentions of the Type app, for example `@Type`. It does not create a User Group.

If Slack blocks User Group creation, the channel still connects. People can continue to mention the Type app directly. These are the common reasons that Slack blocks it:

- **Slack permissions**: the workspace does not let members create User Groups. A Slack admin must [update the Slack permissions](#update-the-slack-permissions).
- **Missing Slack scope**: the Slack connection does not have access to User Groups. Someone must [reconnect Slack in Type](#reconnect-slack-and-sync-user-groups).

> **Note:** Slack User Groups are available on paid Slack plans. If your workspace is on Enterprise Grid, an organization-level policy can control the workspace setting. In that case, an org owner or org admin must update the policy first. Then workspace admins can change the workspace setting.

## Update the Slack permissions

1. In the Slack desktop app, open your workspace or organization menu.
2. Open **Tools & settings**.
3. If you have a single workspace, select **Workspace settings**. If you use Enterprise Grid and an org policy controls this permission, select **Organization settings**.
4. Open **Roles & permissions**.
5. On **Account types**, find **Create and edit user groups**.
6. Open the three-dot menu. Select **Edit permission**. Let regular members create and edit user groups.
7. Find **Deactivate user groups**.
8. Open the three-dot menu. Select **Edit permission**. Let regular members deactivate user groups.
9. Save the changes.

Type.com needs the two permissions:

- **Create and edit user groups**: Type creates and updates Space handles.
- **Deactivate user groups**: Type deactivates a handle after the last Slack channel connection that uses it is removed.

For Slack's official instructions, see [Manage user groups from the admin dashboard](https://slack.com/help/articles/115004952926-Manage-user-groups-from-the-admin-dashboard).

## Reconnect Slack and sync user groups

After the Slack permissions are updated, do these steps in Type:

1. Open Type workspace settings.
2. Go to **Connections**.
3. Open **Slack**.
4. If Type asks you to reconnect Slack, reconnect it. This gives Type access to User Groups.
5. In **Type mentions**, select **Sync user groups**. Type tries again to create the Space handles that Slack did not let it create before.

You can also select **Sync user groups** from the Slack connection in **Space settings → Connections**. Reconnecting alone does not create the handles.

When Type can create the User Group, the Slack channel announcement shows the Space-specific handle that people must mention.

## Remove a Slack channel connection

When you remove a Slack channel from a Space, Type.com deactivates the Space User Group if no other connected Slack channel uses it.

If Slack does not let Type make this change, Type still removes the connection. Type also shows a warning. An admin can then fix the permission and select **Sync user groups** again.

## Before the permissions are fixed

Type.com keeps the channel connection active. In the **@mentions** mode, Type uses the Slack app mention, for example `@Type`. It does not use the Space-specific User Group handle. After you fix the permissions and sync user groups, people can mention the Space handle.
