# Notifications

---

## Overview

Describe what you care about in natural language, and Fly notifies you in Slack when it happens.

- *"Notify me when a new release is created for payment-service"*
- *"Watch for releases that include Docker image changes"*
- *"Alert me when a release image is pulled to production"*

Notifications are delivered through Slack. Fly uses AI to semantically match incoming events against your watches -- no keywords, no filters, just natural language.

---

## How Watches Work

A watch is a free-text description of what you want to be notified about. Fly evaluates every incoming event against your active watches using semantic matching, not exact keywords.

This means:
- *"notify me when a release is created for payment-service"* matches a release event from the payment-service repository
- *"alert when an image is pulled to production"* matches an image pull event targeting the production environment
- Watches that mean the same thing are automatically deduplicated

Watches are scoped to your Fly team and apply to all events across your team.

### Supported Event Types

| Event Type | Example Watch |
|------------|---------------|
| **Release created** | *"Notify me when a new release is created for payment-service"* |
| **Image pull** | *"Notify me when a release image is pulled to production"* |

### How Matching Works

Fly evaluates incoming events against your watches using AI semantic matching. The matching is **many-to-many**: one event can trigger multiple watches, and one watch can match multiple events.

For each match, Fly generates a human-readable notification explaining what happened and why the watch was triggered.

---

## Watch Notifications

When an event matches a watch, Fly sends a rich Slack notification with:

- **AI-generated notification text** -- A clear, concise summary of what happened and why it matters
- **Event details** -- Structured metadata about the event
- **Action buttons** -- Direct links to the relevant page in Fly Web

### Release Notifications

When a CI workflow completes and creates a release, subscribed channels receive the release title, description, artifacts produced, and a link to the full release. An AI-generated summary is posted as a threaded reply.

### Environment Image Pull Alerts

When a release image is pulled to a connected environment, subscribed channels receive which image was pulled, which environment pulled it, and a link to the environment.

---

## How to Integrate Slack

Notifications are delivered through Slack. Here's how to set it up.

### Installing the Slack App

1. Navigate to **Settings** in Fly Web
2. Click **Connect to Slack**
3. Authorize the Fly Slack app in your Slack workspace

### Account Linking

Each team member links their Slack identity to their Fly account:

1. Open the **Fly Slack app** (Apps section in Slack sidebar)
2. Go to the **Home** tab
3. Click **Connect to Fly**
4. Authenticate with your Fly credentials

Once linked, Fly responses are scoped to your account and permissions.

### `/fly` Slash Commands

All Fly functionality in Slack is accessed through:

```
/fly <prompt>
```

**Ask Fly anything:**
- `/fly what's running in production?`
- `/fly show me the latest release from payment-service`
- `/fly find the release where I fixed the login bug`

**Check status:**
- `/fly status`

**Manage watches:**
- `/fly notify me when a new release is created for payment-service`
- `/fly list my watches`
- `/fly remove the watch about image pulls`

### Chat with Fly in Slack

Beyond slash commands, you can chat with Fly directly:
- **Direct messages** -- Send a DM to the Fly Slack app
- **Assistant threads** -- Open the Fly assistant from Slack's top bar

Conversations maintain context across messages within a thread.

### App Home Tab

The Fly Slack app's Home tab shows connection status, quick start guide, available commands, and useful links.

---

## From Your Coding Agent

Your coding agent can create, list, and remove watches using natural language -- the same prompts you'd use in Slack.

*"Notify me when a new release is created for payment-service"*

*"List my watches"*

*"Remove the watch about Docker deployments"*

---

## In Fly Web

The Notification Manager in Fly Web gives you a visual overview of your active watches, recent matches, and watch history. You can review which events triggered notifications and manage your watches from the settings.

---

## Example

**Watch:** *"Alert me when a release image is pulled to production"*

**Event:** *"Docker image payment-service:v2.4.1 pulled to production environment"*

**Result:** Fly sends a Slack notification with the image details and a link to the environment in Fly Web.

---

## Next Steps

- [Releases →](../releases/) - Release events that trigger notifications
- [Runtime Environments →](../runtime-environments/) - Environment events for image pull alerts
