Files
crewAI/docs/edge/ko/enterprise/integrations/slack.mdx
Lucas Gomide a237ebabba feat: adopt directory-based docs versioning with Edge channel (#6202)
* feat: adopt directory-based docs versioning with Edge channel

Switch docs.crewai.com from navigation-only versioning (every version
selector entry rendered the same docs/<lang>/* source files) to
Mintlify's directory-based versioning so each version selector entry
renders its own snapshot. Add an "Edge" channel under docs/edge/<lang>/*
that always reflects main HEAD for unreleased work, eliminating
pre-release leakage onto frozen release labels. External links to
canonical /<lang>/* URLs are preserved via wildcard redirects that
always land on the current default version.

Layout:
- docs/edge/<lang>/*         rolling source (you edit here)
- docs/edge/enterprise-api.*.yaml
- docs/v<X.Y.Z>/<lang>/*     frozen, immutable snapshots
- docs/v<X.Y.Z>/enterprise-api.*.yaml
- docs/images/               shared, append-only
- docs/docs.json             nav + redirects

URLs follow the Mintlify-idiomatic shape: /edge/<lang>/<page> for
Edge, /v<X.Y.Z>/<lang>/<page> for every frozen snapshot. The wildcard
redirects /<lang>/:slug* -> /<default>/<lang>/:slug* keep stale links
working, and every freeze rewrites them (plus all per-section/per-page
redirects) so destinations always resolve to the current default
without depending on a second redirect hop.

Release flow integration (devtools release):
- New module crewai_devtools.docs_versioning.freeze() materialises
  docs/v<X.Y.Z>/ from docs/edge/, rewrites openapi: refs inside the
  snapshot, inserts the version into every language block in
  docs.json, and refreshes all redirect destinations.
- _update_docs_and_create_pr() in cli.py now calls that freeze during
  Phase 2 of devtools release. Edge changelogs are updated first (so
  the snapshot freeze picks them up), then the snapshot is staged
  alongside docs.json, branched as docs/freeze-v<X.Y.Z>, and the PR
  is titled [docs-freeze] docs: snapshot and changelog for v<X.Y.Z>
  — the title prefix the new CI guard reads.
- The PR still gates tag, GitHub release, PyPI publish, and the
  enterprise release as before; no new PRs are added.
- Pre-releases (1.X.YaN, 1.X.YbN, ...) skip the snapshot — they ride
  Edge — and the docs PR title omits the [docs-freeze] prefix.
- docs_check (AI-generated docs scaffolding) writes to
  docs/edge/<lang>/* so newly-generated unreleased docs land in Edge
  and never accidentally touch a frozen snapshot.

Migration scripts (one-shot):
- scripts/docs/freeze_historical_versions.py reconstructs all 16
  historical snapshots (v1.10.0 .. v1.14.7) from git tags via
  git archive | tar, rewriting openapi: MDX refs so each snapshot
  reads its own enterprise-api YAML rather than the live one.
- scripts/docs/prefix_version_paths.py one-shot-migrates docs.json:
  rewrites every page path in 16 versioned blocks to point under
  docs/v<X.Y.Z>/, inserts a new Edge entry per language, tags
  v1.14.7 as Latest (default), prunes pages whose target file
  doesn't exist in the snapshot (e.g. docs/ar/ didn't exist before
  v1.12.0), and writes the wildcard + per-section redirects.
- scripts/docs/freeze_current_edge.py is now a thin CLI wrapper
  around docs_versioning.freeze for manual one-off freezes (e.g.
  retroactively snapshotting a forgotten release).

CI guards (.github/workflows/docs-snapshots.yml):
- Frozen snapshots under docs/v[0-9]*/ are immutable; only PRs whose
  title contains [docs-freeze] (i.e. release-cut PRs generated by
  devtools release or the manual wrapper) may modify them.
- Images under docs/images/ are append-only since snapshots share a
  single image directory. Deleting or renaming an image breaks every
  historical snapshot that still references it.

Restored docs/images/crewai-otel-export.png from PR #3673; it was
deleted in PR #4908 but v1.10.0 / v1.10.1 snapshots still reference
it. Restoring instead of editing the snapshots preserves historical
rendering fidelity and validates the new append-only rule
retroactively.

Tests:
- lib/devtools/tests/test_docs_versioning.py covers the freeze: file
  copy, openapi rewrite, version insertion, default demotion, redirect
  upserts, per-section redirect rewriting, idempotency, and invalid
  inputs.

Verified locally with mintlify broken-links: 0 broken links across
the full site (Edge + 16 frozen versions, 4 locales).

AGENTS.md (repo root) is the contributor guide for the new model;
RELEASING.md is the release-cut runbook; README's Contribution
section links to both.

Co-authored-by: Cursor <cursoragent@cursor.com>

* style: resolve linter issues

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-17 11:56:59 -04:00

318 lines
9.9 KiB
Plaintext

---
title: Slack 연동
description: "CrewAI를 위한 Slack 연동으로 팀 커뮤니케이션 및 협업 지원."
icon: "slack"
mode: "wide"
---
## 개요
에이전트가 Slack을 통해 팀 커뮤니케이션을 관리할 수 있도록 지원합니다. 메시지를 보내고, 대화를 검색하며, 채널을 관리하고, AI 기반 자동화를 통해 팀 활동을 조율하여 협업 워크플로우를 효율적으로 최적화하세요.
## 사전 준비 사항
Slack 통합을 사용하기 전에 다음을 확인하십시오:
- 활성 구독이 있는 [CrewAI AMP](https://app.crewai.com) 계정
- 적절한 권한이 있는 Slack 워크스페이스
- [통합 페이지](https://app.crewai.com/integrations)를 통해 Slack 워크스페이스를 연결함
## Slack 통합 설정
### 1. Slack 워크스페이스 연결
1. [CrewAI AMP 통합](https://app.crewai.com/crewai_plus/connectors)으로 이동합니다.
2. 인증 통합 섹션에서 **Slack**을 찾습니다.
3. **연결**을 클릭하고 OAuth 과정을 완료합니다.
4. 팀 커뮤니케이션에 필요한 권한을 부여합니다.
5. [통합 설정](https://app.crewai.com/crewai_plus/settings/integrations)에서 Enterprise Token을 복사합니다.
### 2. 필수 패키지 설치
```bash
uv add crewai-tools
```
### 3. 환경 변수 설정
<Note>
`Agent(apps=[])`와 함께 통합을 사용하려면 Enterprise Token으로
`CREWAI_PLATFORM_INTEGRATION_TOKEN` 환경 변수를 설정해야 합니다.
</Note>
```bash
export CREWAI_PLATFORM_INTEGRATION_TOKEN="your_enterprise_token"
```
또는 `.env` 파일에 추가하세요:
```
CREWAI_PLATFORM_INTEGRATION_TOKEN=your_enterprise_token
```
## 사용 가능한 도구
### **사용자 관리**
<AccordionGroup>
<Accordion title="slack/list_members">
**설명:** Slack 채널의 모든 멤버를 나열합니다.
**파라미터:**
- 파라미터 없음 - 모든 채널 멤버를 조회합니다
</Accordion>
<Accordion title="slack/get_user_by_email">
**설명:** 이메일 주소로 Slack 워크스페이스에서 사용자를 찾습니다.
**파라미터:**
- `email` (string, 필수): 워크스페이스 내 사용자의 이메일 주소
</Accordion>
<Accordion title="slack/get_users_by_name">
**설명:** 이름 또는 표시 이름으로 사용자를 검색합니다.
**파라미터:**
- `name` (string, 필수): 검색할 사용자의 실제 이름
- `displayName` (string, 필수): 검색할 사용자의 표시 이름
- `paginationParameters` (object, 선택): 페이지네이션 설정
- `pageCursor` (string, 선택): 페이지네이션을 위한 페이지 커서
</Accordion>
</AccordionGroup>
### **채널 관리**
<AccordionGroup>
<Accordion title="slack/list_channels">
**설명:** Slack 워크스페이스의 모든 채널을 나열합니다.
**파라미터:**
- 파라미터가 필요하지 않습니다 - 접근 가능한 모든 채널을 조회합니다
</Accordion>
</AccordionGroup>
### **메시징**
<AccordionGroup>
<Accordion title="slack/send_message">
**설명:** Slack 채널에 메시지를 전송합니다.
**파라미터:**
- `channel` (string, 필수): 채널 이름 또는 ID - Connect Portal Workflow Settings를 사용하여 사용자가 채널을 선택하도록 하거나, 채널 이름을 입력하여 새 채널을 생성할 수 있습니다.
- `message` (string, 필수): 전송할 메시지 텍스트
- `botName` (string, 필수): 이 메시지를 전송하는 봇의 이름
- `botIcon` (string, 필수): 봇 아이콘 - 이미지 URL 또는 이모지(e.g., ":dog:") 모두 가능합니다.
- `blocks` (object, 선택): 첨부파일 및 인터랙티브 요소 등이 포함된 풍부한 메시지 포맷팅을 위한 Slack Block Kit JSON
- `authenticatedUser` (boolean, 선택): true이면 메시지가 애플리케이션이 아니라 인증된 Slack 사용자로부터 보낸 것처럼 표시됩니다(기본값은 false)
</Accordion>
<Accordion title="slack/send_direct_message">
**설명:** Slack에서 특정 사용자에게 다이렉트 메시지를 전송합니다.
**파라미터:**
- `memberId` (string, 필수): 수신자 사용자 ID - Connect Portal Workflow Settings를 사용하여 사용자가 워크스페이스 멤버를 선택하도록 합니다.
- `message` (string, 필수): 전송할 메시지 텍스트
- `botName` (string, 필수): 이 메시지를 전송하는 봇의 이름
- `botIcon` (string, 필수): 봇 아이콘 - 이미지 URL 또는 이모지(e.g., ":dog:") 모두 가능합니다.
- `blocks` (object, 선택): 첨부파일 및 인터랙티브 요소 등이 포함된 풍부한 메시지 포맷팅을 위한 Slack Block Kit JSON
- `authenticatedUser` (boolean, 선택): true이면 메시지가 애플리케이션이 아니라 인증된 Slack 사용자로부터 보낸 것처럼 표시됩니다(기본값은 false)
</Accordion>
</AccordionGroup>
### **검색 및 탐색**
<AccordionGroup>
<Accordion title="slack/search_messages">
**설명:** Slack 워크스페이스 전체에서 메시지를 검색합니다.
**매개변수:**
- `query` (string, 필수): 지정된 기준과 일치하는 메시지를 찾기 위해 Slack 검색 구문을 사용한 검색 쿼리
**검색 쿼리 예시:**
- `"project update"` - "project update"가 포함된 메시지 검색
- `from:@john in:#general` - #general 채널에서 John이 보낸 메시지 검색
- `has:link after:2023-01-01` - 2023년 1월 1일 이후에 링크가 포함된 메시지 검색
- `in:@channel before:yesterday` - 특정 채널에서 어제 이전에 작성된 메시지 검색
</Accordion>
</AccordionGroup>
## Block Kit 통합
Slack의 Block Kit을 사용하면 풍부하고 상호작용이 가능한 메시지를 생성할 수 있습니다. 다음은 `blocks` 매개변수를 사용하는 방법에 대한 몇 가지 예시입니다:
### 첨부 파일이 있는 간단한 텍스트
```json
[
{
"text": "I am a test message",
"attachments": [
{
"text": "And here's an attachment!"
}
]
}
]
```
### 섹션을 활용한 리치 포매팅
```json
[
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "*프로젝트 업데이트*\n상태: ✅ 완료"
}
},
{
"type": "divider"
},
{
"type": "section",
"text": {
"type": "plain_text",
"text": "모든 작업이 성공적으로 완료되었습니다."
}
}
]
```
## 사용 예시
### 기본 Slack 에이전트 설정
```python
from crewai import Agent, Task, Crew
# Create an agent with Slack capabilities
slack_agent = Agent(
role="Team Communication Manager",
goal="Facilitate team communication and coordinate collaboration efficiently",
backstory="An AI assistant specialized in team communication and workspace coordination.",
apps=['slack']
)
# Task to send project updates
update_task = Task(
description="Send a project status update to the #general channel with current progress",
agent=slack_agent,
expected_output="Project update message sent successfully to team channel"
)
# Run the task
crew = Crew(
agents=[slack_agent],
tasks=[update_task]
)
crew.kickoff()
```
### 특정 Slack 도구 필터링
```python
communication_manager = Agent(
role="Communication Coordinator",
goal="Manage team communications and ensure important messages reach the right people",
backstory="An experienced communication coordinator who handles team messaging and notifications.",
apps=['slack']
)
# Task to coordinate team communication
coordination_task = Task(
description="Send task completion notifications to team members and update project channels",
agent=communication_manager,
expected_output="Team notifications sent and project channels updated successfully"
)
crew = Crew(
agents=[communication_manager],
tasks=[coordination_task]
)
crew.kickoff()
```
### Block Kit을 활용한 고급 메시징
```python
from crewai import Agent, Task, Crew
notification_agent = Agent(
role="Notification Manager",
goal="Create rich, interactive notifications and manage workspace communication",
backstory="An AI assistant that specializes in creating engaging team notifications and updates.",
apps=['slack']
)
# Task to send rich notifications
notification_task = Task(
description="""
1. Send a formatted project completion message to #general with progress charts
2. Send direct messages to team leads with task summaries
3. Create interactive notification with action buttons for team feedback
""",
agent=notification_agent,
expected_output="Rich notifications sent with interactive elements and formatted content"
)
crew = Crew(
agents=[notification_agent],
tasks=[notification_task]
)
crew.kickoff()
```
### 메시지 검색 및 분석
```python
from crewai import Agent, Task, Crew
analytics_agent = Agent(
role="Communication Analyst",
goal="Analyze team communication patterns and extract insights from conversations",
backstory="An analytical AI that excels at understanding team dynamics through communication data.",
apps=['slack']
)
# Complex task involving search and analysis
analysis_task = Task(
description="""
1. 모든 채널에서 최근 프로젝트 관련 메시지 검색
2. 이메일로 사용자를 찾아 팀 구성원 식별
3. 커뮤니케이션 패턴 및 응답 시간 분석
4. 주간 팀 커뮤니케이션 요약 생성
""",
agent=analytics_agent,
expected_output="팀 인사이트 및 권장사항이 포함된 종합적인 커뮤니케이션 분석"
)
crew = Crew(
agents=[analytics_agent],
tasks=[analysis_task]
)
crew.kickoff()
```
## 지원 문의
<Card
title="도움이 필요하신가요?"
icon="headset"
href="mailto:support@crewai.com"
>
Slack 연동 설정 또는 문제 해결에 대해 지원팀에 문의하세요.
</Card>