# Slack

## Overview

OneLens integrates with Slack so you can receive **Anomaly Alerts**, **Ticket Notifications**, **Cost Alerts**, and **Resource Digests** directly in your Slack workspace. This enables near real-time visibility into key events without leaving your team’s communication tool.

You can configure workflows to send alerts to specific **users** or **channels**, including private ones.

{% hint style="warning" %}

### Prerequisites

* You must be a **OneLens Admin** user to configure the Slack integration. *Make sure you are log in with the specific account that holds admin access.*
* You must have permission in Slack workspace to authorize third-party integrations.
  {% endhint %}

## Setting Up Slack in OneLens

OneLens uses a trusted third-party provider, **Truto**, to securely connect with Slack.

{% hint style="success" %}
**Your data belongs to you—Truto does not sell or share your data.** All authentication and permissions are handled through a secure, privacy-respecting flow.*To know more about Truto,* [*click here*](https://truto.one/)*.*
{% endhint %}

### Required Slack Permissions

<details>

<summary>The following permissions are required for enabling slack integration:</summary>

<table><thead><tr><th width="217.109375">Permission Scope</th><th>Description</th></tr></thead><tbody><tr><td><code>users:read</code></td><td>View users in your Slack workspace</td></tr><tr><td><code>users:read.email</code></td><td>Access email addresses of users</td></tr><tr><td><code>team:read</code></td><td>Read workspace info</td></tr><tr><td><code>chat:write</code></td><td>Send messages as OneLens</td></tr><tr><td><code>chat:write.public</code></td><td>Post in public channels</td></tr><tr><td><code>im:write</code></td><td>Send messages to direct messages</td></tr><tr><td><code>channels:read</code></td><td>Access channel list</td></tr><tr><td><code>groups:read</code></td><td>Access private channel list</td></tr><tr><td><code>mpim:read</code></td><td>Access group DMs</td></tr><tr><td><code>im:read</code></td><td>Access direct messages</td></tr></tbody></table>

</details>

{% hint style="info" %}

## **Privacy Note**&#x20;

OneLens does **not** access, read, or store your messages or files.\
The integration uses these permissions **only to retrieve basic metadata** like user names, emails, and channel names—solely to enable alert routing.\
There is **no ongoing data pull** or background monitoring beyond the messages OneLens sends as alerts.
{% endhint %}

### Integration Steps

{% stepper %}
{% step %}
**Navigate to Integrations**

* From the OneLens sidebar, go to the **Integrations** section.
  {% endstep %}

{% step %}
**Initiate Slack Integration**

* Click on **Connect** under the Slack option.
  {% endstep %}

{% step %}
**Truto Consent Popup**

* A pop-up will inform you that OneLens uses Truto for Slack integration.

  <figure><img src="/files/d4hqJWw5f88pz5rQr1FF" alt="" width="188"><figcaption></figcaption></figure>
* Click **Continue** to proceed.
  {% endstep %}

{% step %}
**Permission Grant**

* Review the required permissions on the next screen. Click **Connect** to move forward.

{% endstep %}

{% step %}

### **Login to Slack**

* Sign in to your Slack workspace when prompted.

  <figure><img src="/files/3YuNB1ihqFwN7Elcb3pD" alt="" width="375"><figcaption></figcaption></figure>

{% endstep %}

{% step %}
**Workspace Selection**

You’ll be asked to allow OneLens access to a Slack workspace.

* Switch workspaces using the top-right corner if needed.
* You can also add a new workspace here.

  <figure><img src="/files/DkiKmUESGxJS8mSJw4G1" alt="" width="563"><figcaption></figcaption></figure>

{% endstep %}

{% step %}
**Grant Access**

* Click **Allow** to authorize the integration.
  {% endstep %}

{% step %}
**Confirmation**

* You’ll see a confirmation page indicating successful Slack integration.

  <figure><img src="/files/UZ67uoLrsDcdHGSGGqto" alt="" width="375"><figcaption></figcaption></figure>

{% endstep %}
{% endstepper %}

## Managing Integration

You can manage your Slack connection from the **Integrations** section in OneLens.

To **disconnect** Slack, click **Disconnect** under the Slack option.

<figure><img src="/files/cRw7pDxK7kTRRz0CpX8Q" alt="" width="170"><figcaption></figcaption></figure>

{% hint style="warning" %}

## NOTE

Disconnecting will **not remove** previously delivered Slack alerts.\
However, OneLens will **no longer be able to send messages** to your Slack workspace until the integration is reconnected.
{% endhint %}

## What Next

Once Slack is connected, you can now:

* Connect your Private Slack Channels to OneLens

  Head to [Connect Slack Private Channels to OneLens](/facts-and-faqs/faqs/connect-slack-private-channels-to-onelens.md)
* Setup Workflows for Slack Notifications

  Learn more about [Workflows & Automation](/automate/workflows-and-automation.md)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.onelens.cloud/integrations/third-party-integrations/slack.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
