---
title: Slack overview & authentication
sidebarTitle: Overview & authentication
---

## Overview

Our Slack integration allows you to connect to the Slack API and post messages to Slack.

## Installation

<CodeGroup>

```bash npm
npm install @trigger.dev/slack@latest
```

```bash pnpm
pnpm install @trigger.dev/slack@latest
```

```bash yarn
yarn add @trigger.dev/slack@latest
```

</CodeGroup>

## Authentication

Slack supports OAuth.

## OAuth

To use OAuth you can connect to Slack via the Trigger.dev [web app](https://cloud.trigger.dev). Click 'Integrations' in the side panel of any project, and configure Slack with the ID you want to use in your job and the required [scopes](https://api.slack.com/scopes).

```ts
import { Slack } from "@trigger.dev/slack";

const slack = new Slack({
  id: "slack",
});
```

## Tasks

Once you have set up a Slack client, you can use it to create tasks.

{" "}

<Card title="Tasks" icon="sparkles" href="/integrations/apis/slack-tasks">
  Perform tasks such as posting messages to a channel.
</Card>

## Example jobs

<Card title="Code examples" icon="code" href="https://trigger.dev/apis/slack">
  Check out pre-built jobs using Slack in our API section.
</Card>
