# Discord 대상

## 개요

Destinations는 룰, 정책, 시스템 상태 알림 및 룰 오류로부터 알림을 수신하는 통합 기능입니다. Panther는 Discord를 알림을 수신할 대상지로 설정하는 것을 지원합니다.

## Panther 알림을 Discord로 보내도록 구성하는 방법

### 사전 요구 사항

* Discord 서버에서 새 채널을 만들거나, Panther 알림을 보낼 기존 채널이 무엇인지 확인하세요.

### 1단계: Discord 채널의 웹훅 URL 가져오기

알림을 보내려는 Discord 채널에 대해 다음 단계를 따르세요:

1. Discord에서 서버를 선택합니다. 아래에서 *텍스트 채널*, 사용할 Discord 채널을 찾습니다. 다음을 선택합니다. **채널 편집(톱니바퀴 아이콘)**.

   <figure><img src="/files/acdcab980fc611e752867a09159f88f670c2f5fd" alt="In Discord, the gear icon next to &#x22;#general&#x22;, under &#x22;Text Channels&#x22; is highlighted."><figcaption></figcaption></figure>
2. 클릭 **통합** 있으며 **웹훅 만들기**.

   <figure><img src="/files/2ad30cd5f7a1fc20b0a652c7bd270307fdbd1e21" alt="In Discord on the Integrations page, there is a button in the center of the page labeled &#x22;Create Webhook.&#x22;"><figcaption></figcaption></figure>
3. Discord는 기본 이름으로 새 웹훅을 생성합니다. 웹훅을 클릭하세요(아래 예시에서는 **Spidey Bot**)를 확장하여 세부 정보를 확인합니다.

   <figure><img src="/files/93db068e62b5b9adf2692459a26d2cfb92eeb1c4" alt="In Discord under the &#x22;New Webhook&#x22; button, there is a webhook called &#x22;Spidey Bot.&#x22;"><figcaption></figcaption></figure>
4. 원한다면 웹훅 이름을 변경한 다음 **변경 사항 저장을 클릭하세요**.
   * 웹훅 이름은 알림이 전송될 때 채널의 발신자로 표시됩니다.

     <figure><img src="/files/0b12687e7a84e8f1d2b4c56d0a89fb861295b41e" alt="In Discord, the webhook details are expanded. &#x22;My Discord Destination&#x22; has been typed into the &#x22;Name&#x22; field."><figcaption></figcaption></figure>
5. 클릭 **웹훅 URL 복사**. 다음 단계에서 이 값이 필요합니다.

Discord에서 웹훅 사용에 대한 자세한 내용은 다음을 참조하세요 [Discord의 webhook 리소스 문서](https://discord.com/developers/docs/resources/webhook).

### 2단계: Panther에서 webhook 통합 만들기

1. Panther 콘솔에서 다음으로 이동합니다. **Configure > 알러트 대상.**
2. 클릭 **+ 첫 번째 대상 추가**.
   * 이미 대상을 만든 적이 있다면 다음을 클릭합니다 **새로 만들기** 페이지 오른쪽 상단에서 새 대상을 추가합니다.
3. 클릭 **Discord**.
4. "Configure Your Webhook Destination page"에서 양식을 작성합니다:
   * **표시 이름:** 설명적인 이름을 입력하세요.
   * **Discord Webhook URL**: 1단계에서 얻은 Discord 웹훅 URL을 입력하세요.
     * 웹훅 URL은 다음 형식을 갖게 됩니다: `https://discord.com/api/webhooks/<token-string>`
   * **Severity**: 이 대상(Destination)으로 보낼 알러트의 심각도 수준을 선택하세요.
   * **알러트 유형**: 이 대상지로 보낼 알러트 유형을 선택하세요.
   * **Log Type**: 기본적으로 모든 로그 유형에서 알러트를 보냅니다. 특정 로그 유형의 알러트만 보내려면 여기에서 로그 유형을 지정하세요.
   * **수동 배포 허용**: 다음을 할 수 있도록 하려면 이 토글을 켜세요. [알러트를 수동으로 배포](https://docs.panther.com/alerts#manual-alert-dispatch) 이 대상지로.\
     ![](/files/d1ca45c1c746ebd1681a576de2ab642dd5acaa4f)
5. 클릭 **대상지 추가**.
6. 클릭 **테스트 알러트 보내기** 모든 것이 올바르게 작동하는지 확인하기 위해.
   * 이제 Discord 채널에 테스트 이벤트가 있어야 합니다.
7. 클릭 **설정 완료.**

## 테스트 알러트 생성

클릭 **테스트 알러트** 알러트를 생성하고 Discord로 전송합니다. 알러트의 페이로드는 아래와 같습니다:

```json
{"id":"Test.Alert","createdAt":"2022-04-26T03:17:32.099054303Z","severity":"INFO","type":"RULE","link":"https://domain.runpanther.net","title":"This is a Test 알러트","name":"Test 알러트","alertId":"Test.Alert","alertContext":{},"description":"This is a Test 알러트","runbook":"Stuck? Check out our docs: https://docs.runpanther.io","tags":["test"],"version":"1"}
```

알러트가 Discord에 의해 수신되면, Discord의 채널로 메시지가 전송됩니다:

<figure><img src="/files/74f8ace1140b8ea0eb6367ef75ea522fc8645207" alt="The channel in Discord contains a test alert."><figcaption></figcaption></figure>


---

# 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.panther.com/ko/alerts/destinations/discord.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.
