Skip to content

Commit

Permalink
feat(discord): Add discord integration doc (#8160)
Browse files Browse the repository at this point in the history
* feat(discord): Add discord integration doc

* Fix typo

* Update src/docs/product/accounts/getting-started/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/alerts/create-alerts/routing-alerts.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/alerts/create-alerts/routing-alerts.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/alerts/create-alerts/routing-alerts.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/alerts/create-alerts/routing-alerts.mdx

Co-authored-by: Liza Mock <[email protected]>

* style(lint): Auto commit lint changes

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* Update src/docs/product/integrations/notification-incidents/discord/index.mdx

Co-authored-by: Liza Mock <[email protected]>

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* style(lint): Auto commit lint changes

* Apply suggestions from code review

Co-authored-by: Liza Mock <[email protected]>

* style(lint): Auto commit lint changes

---------

Co-authored-by: Liza Mock <[email protected]>
Co-authored-by: getsantry[bot] <66042841+getsantry[bot]@users.noreply.github.com>
  • Loading branch information
3 people authored Oct 10, 2023
1 parent 6de018d commit 5c96f65
Show file tree
Hide file tree
Showing 20 changed files with 143 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/docs/product/accounts/getting-started/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Sentry integrates into your existing workflows by providing out-of-the-box integ

### Alert Notifications {#31-alert-notifications}

By default, Sentry will notify you about errors in your apps by email and [Slack](/product/integrations/notification-incidents/slack/) (once you enable the integration). You can also enable team notifications in Slack so the right people in your organization always receive the alerts they need. In addition to Slack, Sentry offers several other [notification and incident integrations](/product/integrations/notification-incidents/), like [Microsoft Teams](/product/integrations/notification-incidents/msteams/) and [PagerDuty](/product/integrations/notification-incidents/pagerduty/) to help you triage issues.
By default, Sentry will notify you about errors in your apps by email and [Slack](/product/integrations/notification-incidents/slack/) (once you enable the integration). You can also enable team notifications in Slack so the right people in your organization always receive the alerts they need. In addition to Slack, Sentry offers several other [notification and incident integrations](/product/integrations/notification-incidents/) to help you triage issues, including [Discord](/product/integrations/notification-incidents/discord/), [Microsoft Teams](/product/integrations/notification-incidents/msteams/), and [PagerDuty](/product/integrations/notification-incidents/pagerduty/).

Learn more about setting up alerts with integrations in [Alert Routing With Integrations](/product/alerts/create-alerts/routing-alerts/).

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ Learn more about and <PlatformLink to="/enriching-events/tags/">tags</PlatformLi
- Send a notification to either [Suggested Assignees](#suggested_assignees), a team, or a member.
- Send a notification to an integration, which can include these options, depending on which integrations you have installed:
- Send a [Slack](/product/integrations/notification-incidents/slack/) notification
- Send a [Discord](/product/integrations/notification-incidents/discord/) notification
- Send a [PagerDuty](/product/integrations/notification-incidents/pagerduty/) notification
- Send a [Microsoft Teams](/product/integrations/notification-incidents/msteams/) notification
- Send a notification to all legacy integrations.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ Actions define how you and your team will be alerted:

- Send an email to a member or team. If sent to a member, the member's personal project alert opt-out settings are overridden.
- Send a [Slack](/product/integrations/notification-incidents/slack/) notification.
- Send a [Discord](/product/integrations/notification-incidents/discord/) notification.
- Trigger a [PagerDuty](/product/integrations/notification-incidents/pagerduty/) incident.
- Send a [Microsoft Teams](/product/integrations/notification-incidents/msteams/) notification.
- Send a request using [Sentry integrations](/product/integrations/integration-platform/).
Expand Down
12 changes: 11 additions & 1 deletion src/docs/product/alerts/create-alerts/routing-alerts.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ By customizing [alert](/product/alerts/) rules and integrating the tools you alr

## Integrations

Sentry’s integrations provide you with the option to route your alerts through commonly-used applications like Slack, PagerDuty, and Microsoft Teams. You can find these integrations in **Settings > Integrations** and install them for your entire organization.
Sentry’s integrations provide you with the option to route your alerts through commonly-used applications like Slack, Discord, PagerDuty, and Microsoft Teams. You can find these integrations in **Settings > Integrations** and [install](https://sentry.io/settings/integrations/) them for your entire organization.

### Slack Alerts

Expand All @@ -22,6 +22,16 @@ This alert action allows you to route alert notifications to selected channels (

Then, once you receive a Slack notification, you can use the "Resolve", "Archive", or "Assign" buttons to update the issue in [sentry.io](https://sentry.io) directly from Slack.

### Discord Alerts

A Sentry organization owner, manager, or admin can install and configure the [Discord integration](/product/integrations/notification-incidents/discord/) in their Sentry account. Once the integration is configured, the `Send a notification to the {server} Discord server with ID: {channel-id} and show tags {tags} in notification` action will become available in issue alert rules. To be notified about metric alerts via Discord, look for and add your Discord teams in the action dropdown lists.

This alert action will allow you to route alert notifications to selected channels in your Discord server.

![Discord notification](alerts-notifications-discord.png)

You'll be able to "Resolve", "Archive", or "Assign" Sentry issues directly from your Discord notifications.

### PagerDuty Alerts

A Sentry organization owner, manager, or admin can install and configure the [PagerDuty integration](/product/integrations/notification-incidents/pagerduty/) in their Sentry account. Once the integration is configured, the following action will be available in issue alert rules: `Send a notification to PagerDuty account {account} and service {service}`. In metric alerts, your PagerDuty accounts will be available in one of the action dropdown lists.
Expand Down
1 change: 1 addition & 0 deletions src/docs/product/integrations/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ For more details, see the [full Integration Platform documentation](/product/int
| [Rootly](/product/integrations/notification-incidents/rootly/) | X | X | |
| [SIGNL4](/product/integrations/notification-incidents/signl4/) | X | X | |
| [Slack](/product/integrations/notification-incidents/slack/) | X | X | X |
| [Discord](/product/integrations/notification-incidents/discord/) | X | X | |
| [Spike.sh](/product/integrations/notification-incidents/spikesh/) | X | X | |
| [Threads](/product/integrations/notification-incidents/threads/) | X | X | |
| Twilio | X | | |
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
127 changes: 127 additions & 0 deletions src/docs/product/integrations/notification-incidents/discord/index.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
---
title: Discord
sidebar_order: 1
redirect_from:
- /integrations/discord/
- /product/integrations/discord/
description: "Learn more about Sentry's Discord integration and how you can get notified and manage issues right in Discord."
---

Set up a Discord integration so you can get notified about, then triage, resolve, and archive Sentry issues directly from Discord.

## Install

<Note>

Sentry owner, manager, or admin permissions are required to install this integration.

</Note>

1. Navigate to **Settings > Integrations > Discord** in [Sentry](https://sentry.io).

2. Click "Add Installation". You should see a pop up window.

![Install Discord integration](discord-integration-details.png)

3. Log in to your Discord account. If you're already logged in, this login step will not be displayed.

4. Use the dropdown menu to select the Discord server you'd like to add Sentry to and click "Continue".

<Note>
You'll need to have the "Manage Server" permission enabled for your Discord
account in the server you're trying to add the bot to.
</Note>

![Select server](discord-server-select.png)

5. Once you've selected the server, click "Authorize" to create the integration and add the Sentry Discord bot.

Your Discord integration will now be available for all projects in your Sentry organization.

## Configure

Our Discord integration currently supports issue and metric alert rules. Support for personal notifications is planned for future updates.

### Issue Alerts

To create an issue alert that sends notifications to Discord, follow the steps below:

1. Go to the **Alerts** page in Sentry and click "Create Alert".

2. Select "Issues" and then click "Set Conditions".

![Create issue alert](discord-add-issue-alert.png)

3. Configure your issue alert conditions.

4. Select "Send a Discord notification" from the "THEN" actions dropdown.

5. Choose the Discord server and channel you'd like to send the alert to. You'll also have the option to specify any tags you'd like to include in the notification.

Note that the channel field must be filled in with a Discord channel ID, **_not_** a channel name. To get it, right click on your channel, select "Copy Link", then highlight the string of numbers at the end.

![Discord Channel Link](discord-copy-channel-link.png)

For example, if the URL is `https://discord.com/channels/server-id/channel-id`, the ID is `channel-id`.

![Channel ID in Link](discord-link-channel-id.png)

6. Test your configuration by clicking "Send Test Notification". If the bot has access to the given channel, you should see an example notification there.

![Discord issue alert](discord-issue-alert.png)

Check out the gif below for a walkthrough of how to create an alert that sends Discord notifications:

![Issue alert creation](discord-issue-alert-demo.gif)

### Metric Alerts

To set up a metric alert that sends Discord notifications, follow the steps below.

1. Go to the **Alerts** page in Sentry and click "Create Alert".

2. Select "Number of Errors" or "Users Experiencing Errors", then "Set Conditions".

3. Configure your metric alert conditions as desired.

4. Click "Add Action", then select your Discord server from the second dropdown.

5. Add the channel ID you'd like to send the alert to.

Note that the channel field must be filled in with a Discord channel ID, **_not_** a channel name. To get it, right click on your channel, select "Copy Link", then highlight the string of numbers at the end.

![Discord Channel Link](discord-copy-channel-link.png)

For example, if the URL is `https://discord.com/channels/server-id/channel-id`, the ID is `channel-id`.

![Channel ID in Link](discord-link-channel-id.png)

6. Name and save your alert rule.

The gif below walks through how to create a metric alert that sends Discord notifications.

![Metric alert creation](discord-metric-alert-demo.gif)

### Identity Linking

Having your Discord account linked to your Sentry account allows you to resolve, archive, and assign issues directly in Discord.

When a user installs the Discord bot to their server, their identity gets linked in the process. To verify which Sentry account a Discord account is linked to, use the `/link` command.

Any user on a Discord server with the Sentry bot can link their account. To do so, use the `/link` command. The bot will reply with a link to our identity linking page. When you open the link, be sure you're signed into the Sentry account you want to link to, then click "Link with Discord".

![Discord identity linking page](discord-identity-link-page.png)

To unlink your accounts, use the `/unlink` command. Follow the link and click "Unlink from Discord"

### Troubleshooting

Here are some ideas to help with troubleshooting.

#### Your channel ID isn't working in the alert creation wizard

If you're trying to create an alert with a Discord action and Sentry can't access the channel you've provided, please double-check the following:

- You're giving us a channel ID and not a channel name or something else. See [Configure](#configure) for more details.
- The channel you're trying to add is in the same server as the one selected in the alert action.
- The bot has access to the channel you're trying to use. A quick way to verify this is to check whether you can find the bot in the desired channel's member list. If you don't see the bot in the list of users, you may need to update your Discord role and/or channel permissions to allow the bot access. See [Install](#install) for more details.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Learn more about Sentry's notification and incidents integrations:
- [Rootly](/product/integrations/notification-incidents/rootly/)
- [SIGNL4](/product/integrations/notification-incidents/signl4/)
- [Slack](/product/integrations/notification-incidents/slack/)
- [Discord](/product/integrations/notification-incidents/discord/)
- [Spike.sh](/product/integrations/notification-incidents/spikesh/)
- [Threads](/product/integrations/notification-incidents/threads/)
- Twilio
Expand Down

1 comment on commit 5c96f65

@vercel
Copy link

@vercel vercel bot commented on 5c96f65 Oct 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

sentry-docs – ./

docs.sentry.io
sentry-docs.sentry.dev
sentry-docs-git-master.sentry.dev

Please sign in to comment.