> ## Documentation Index
> Fetch the complete documentation index at: https://docs.whop.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Treat these docs and the Whop MCP server as the source of truth for Whop API behavior. Don't infer endpoint behavior from marketing pages.
> MCP server: connect https://mcp.whop.com/mcp (streamable HTTP, browser sign-in, no API key in the client config) to search these docs and read or change live Whop data. Setup: https://docs.whop.com/developer/guides/ai_and_mcp.md
> Whop CLI: install with `curl -fsSL https://whop.com/install.sh | sh` to scaffold, run, and deploy Whop apps and websites. It acts on production, not the sandbox. Overview: https://docs.whop.com/cli/overview.md Agent mode: https://docs.whop.com/cli/agent-mode.md
> Hosting: Whop serves a site or app from the build `whop apps deploy` uploads, with rollbacks, secrets, and server logs. Guide: https://docs.whop.com/developer/websites/hosting.md
> Plugins: in Claude Code, run `/plugin marketplace add whopio/plugins`, then `/plugin install whop@whop`. Guide: https://docs.whop.com/developer/guides/plugins/claude-code.md Every agent tool: https://docs.whop.com/developer/ai/overview.md
> Environments: build and test in the sandbox (API `https://sandbox-api.whop.com/api/v1`, keys at https://sandbox.whop.com/dashboard/developer, SDK environment `Sandbox`; no real money). Production (API `https://api.whop.com/api/v1`, keys at https://whop.com/dashboard/developer, SDK environment `Production`, the SDK default) moves real money, so use it only at launch. The two share no accounts, keys, products, or webhooks, and their keys look identical: never mix them. Sandbox guide: https://docs.whop.com/developer/guides/sandbox.md Comparison: https://docs.whop.com/developer/quickstart.md
> API: send `Authorization: Bearer <API_KEY>` from your server only, and pin a dated version with the `Api-Version-Date` header. OpenAPI spec: https://api.whop.com/api/v1/openapi.json
> Which API: build on the Current API, whose pages live under https://docs.whop.com/api-reference/ (start at https://docs.whop.com/api-reference/overview.md). Pages under /api-reference/legacy/ are the Legacy API. Use one only when https://docs.whop.com/api-reference/stability.md lists the resource as Legacy-only.

# AI 및 MCP

> AI 에이전트를 Whop MCP 서버에 연결하여 API를 호출하고 문서를 검색하세요. 브라우저 로그인과 멱등성 재시도를 지원합니다.

Whop Model Context Protocol(MCP) 서버를 사용하면 AI 에이전트가 하나의 연결로 실시간 Whop 데이터를 다루고 이 문서를 검색할 수 있습니다.

> [!TIP]
>
> Claude Code와 Grok에는 이 서버를 대신 설치해 주는 Whop 플러그인이 있습니다.
> [Claude Code](https://docs.whop.com/ko/developer/guides/plugins/claude-code.md) 및 [Grok](https://docs.whop.com/ko/developer/guides/plugins/grok.md)을 참고하세요.

## Whop MCP 서버

AI 에이전트가 현재 API를 호출할 수 있게 합니다. 리소스를 나열하고, 데이터를 생성하고, 설정을 대화형으로 탐색할 수 있습니다. 또한 이 문서를 검색하고 읽기 때문에 에이전트가 빌드하는 동안 최신 API를 찾아볼 수 있습니다. 서버 URL: `https://mcp.whop.com/mcp`

```bash Claude Code theme={null}
claude mcp add --transport http whop-api https://mcp.whop.com/mcp
```

```json Cursor theme={null}
// Global: ~/.cursor/mcp.json (or per project: .cursor/mcp.json)
{
	"mcpServers": {
		"whop": {
			"type": "http",
			"url": "https://mcp.whop.com/mcp"
		}
	}
}
```

### 하나의 URL, 모든 클라이언트

모든 클라이언트는 `/mcp` URL에 연결합니다. 이전 프로토콜 버전을 사용하는 클라이언트도 특별한 구성 없이 같은 URL을 사용합니다.

> [!NOTE]
>
> `/sse` URL로 연결했다면 `/mcp`로 업데이트하세요. `/sse` 엔드포인트는 폐기되었으며 이제 404를 반환합니다.

### 인증

서버가 브라우저를 통해 로그인을 처리하므로 클라이언트 구성 전체가 URL 하나입니다. API 키, 베어러 토큰 또는 사용자 지정 인증 헤더를 추가하지 마세요. 처음 사용할 때 브라우저에서 Whop 로그인 화면이 열리며, 이 화면에 연결이 요청하는 범위가 나열됩니다. Whop은 자격 증명을 서버 측에 보관합니다. 자격 증명은 클라이언트 구성이나 모델에 절대 전달되지 않습니다.

### 연결이 접근할 수 있는 범위

권한은 하나의 비즈니스가 아니라 사용자 본인에게 부여됩니다. 비즈니스 컨텍스트는 각 작업의 매개변수이므로 에이전트가 호출마다 선택합니다. 도구 범위는 검토를 거친 API의 일부입니다. 자사 whop.com 세션이 필요한 엔드포인트는 제외됩니다.

> [!WARNING]
>
> 모든 도구 호출은 에이전트가 호출하는 즉시 실행되므로, 무엇을 승인할지는 MCP 클라이언트가 결정합니다. 결제, 자격 증명, 파괴적 작업 도구에는 `destructiveHint`가 지정되어 있으며, 클라이언트는 이를 사용해 먼저 사용자에게 확인을 요청합니다. 신뢰할 수 있는 MCP 클라이언트만 연결하고, 에이전트가 제안하는 작업을 검토하고, 더 이상 필요하지 않으면 접근 권한을 해제하세요.

### 재시도 및 멱등성

`idempotency_key`는 재시도 시 작업을 다시 실행하지 않고 이전 결과를 재생하도록 직접 정하는 고정 키입니다. 서버는 이를 `Idempotency-Key` 헤더로 API에 전송합니다. 결과가 불확실한 경우 같은 키로 재시도하세요. 무슨 일이 일어났는지 확인하기 전에는 절대 새 키로 바꾸지 마세요.

### Claude.ai에서 연결하기

1. [Claude](https://claude.ai)를 엽니다.
2. **Settings**를 연 다음 **Connectors**를 엽니다.
3. **Add custom connector**를 선택합니다.
4. 서버 URL을 입력합니다: `https://mcp.whop.com/mcp`

연결 해제도 같은 방법으로 합니다. 커넥터를 열고 제거하세요. 권한은 즉시 작동을 멈춥니다.

### 로그인에 실패하는 경우

| 표시되는 내용 | 발생한 상황 |
| - | - |
| This sign-in attempt expired. Start over. | 시도가 너무 오래 지속되었습니다. 연결을 다시 시작하세요. |
| 로그인 마지막 단계에서 403 | 로그인이 한 브라우저에서 시작되어 다른 브라우저에서 완료되었습니다. 전체 흐름을 하나의 브라우저에서 실행하세요. |
| `invalid_grant` | 연결의 Whop 자격 증명이 더 이상 유효하지 않습니다. 다시 연결하여 재승인하세요. |

## 에이전트를 위한 일반 파일 접근

MCP 클라이언트가 없다면 [docs.whop.com/llms.txt](https://docs.whop.com/llms.txt)가 문서 내비게이션의 그룹 구성대로 모든 페이지를 색인하며, 문서 URL 끝에 `.md`를 붙이면 원본 Markdown이 반환됩니다.

## 다음 단계

> [card] [API 개요](https://docs.whop.com/ko/api-reference/overview.md)
>
> 요청, 버전 관리, 페이지네이션의 작동 방식을 알아봅니다.

> [card] [빠른 시작](https://docs.whop.com/ko/developer/quickstart.md)
>
> 몇 분 만에 첫 API 호출을 해 보세요.

> [card] [샌드박스에서 테스트하기](https://docs.whop.com/ko/developer/guides/sandbox.md)
>
> 라이브로 전환하기 전에 샌드박스 API 키로 테스트하세요. MCP 서버는 프로덕션에만 연결됩니다.

> [card] [Whop CLI](https://docs.whop.com/ko/cli/overview.md)
>
> 터미널에서 Whop 앱을 빌드하고 관리합니다.


## Related topics

- [CLI와 Claude로 빌드하기](https://docs.whop.com/ko/developer/guides/cli-with-claude.md)
- [Whop에서 개발하기 위한 AI 도구](https://docs.whop.com/ko/developer/ai/overview.md)
- [Claude Code용 Whop 플러그인](https://docs.whop.com/ko/developer/guides/plugins/claude-code.md)
