> ## 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.

# Promo Codes API

> Promo Code는 구매자가 결제 시 입력하는 할인으로, 비율 할인 또는 정액 할인입니다.

프로모션 코드는 계정에 속하며, 하나의 상품으로 제한할 수 있고, 누가 몇 번까지, 언제까지 사용할 수 있는지와 할인이 몇 번의 청구 주기 동안 유지되는지를 제어합니다.

Promo Codes API를 사용하면 계정의 코드를 생성하고, 목록을 조회하고 개별 코드를 조회하며, 코드를 비활성화하여 사용을 일시 중지하거나 다시 활성화하고, 더 이상 제공하지 않는 코드를 보관 처리할 수 있습니다.

## 엔드포인트

| 엔드포인트 | 요청 |
| - | - |
| [프로모션 코드 목록 조회](https://docs.whop.com/ko/api-reference/promo-codes/list-promo-codes.md) | GET `/promo_codes` |
| [프로모션 코드 조회](https://docs.whop.com/ko/api-reference/promo-codes/retrieve-promo-code.md) | GET `/promo_codes/{id}` |
| [프로모션 코드 생성](https://docs.whop.com/ko/api-reference/promo-codes/create-promo-code.md) | POST `/promo_codes` |
| [프로모션 코드 활성화](https://docs.whop.com/ko/api-reference/promo-codes/activate-promo-code.md) | POST `/promo_codes/{id}/activate` |
| [프로모션 코드 비활성화](https://docs.whop.com/ko/api-reference/promo-codes/deactivate-promo-code.md) | POST `/promo_codes/{id}/deactivate` |
| [프로모션 코드 삭제](https://docs.whop.com/ko/api-reference/promo-codes/delete-promo-code.md) | DELETE `/promo_codes/{id}` |

## 속성

**id** `string` *required*

`promo_` 접두사가 붙은 프로모션 코드 ID입니다.

**account** `object` *required*

프로모션 코드를 소유한 계정입니다.

> [accordion] 속성
>
> **id** `string` *required*
>
> `biz_` 접두사가 붙은 계정 ID입니다.
>
> **title** `string` *required*
>
> 계정 표시 이름입니다.

**affiliate** `object | null` *required*

프로모션 코드를 사용한 추천의 실적을 인정받는 제휴자이며, 연결된 제휴자가 없으면 `null`입니다.

> [accordion] 속성
>
> **id** `string` *required*
>
> `aff_` 접두사가 붙은 제휴자 ID입니다.
>
> **user** `object` *required*
>
> 제휴자인 사용자입니다.
>
> > [accordion] 속성
> >
> > **id** `string` *required*
> >
> > `user_` 접두사가 붙은 제휴자 사용자 ID입니다.
> >
> > **name** `string | null` *required*
> >
> > 제휴자의 표시 이름입니다.
> >
> > **profile\_pic** `string` *required*
> >
> > 제휴자 아바타 URL로, 아바타가 설정되지 않은 경우 생성된 대체 이미지를 포함합니다.
> >
> > **username** `string | null` *required*
> >
> > 제휴자의 공개 사용자 이름입니다.

**amount\_off** `number` *required*

할인 금액입니다. 비율 할인은 소수 분수로 표현됩니다.

**churned\_users\_only** `boolean` *required*

프로모션 코드가 이탈한 고객으로 제한되는지 여부입니다.

**code** `string | null` *required*

결제 시 입력하는 코드입니다.

**created\_at** `string` *required*

프로모션 코드가 생성된 시각으로, ISO 8601 타임스탬프입니다.

**currency** `string` *required*

정액 할인에 사용되는 통화입니다.

사용 가능한 옵션: `usd`, `sgd`, `inr`, `aud`, `brl`, `cad`, `dkk`, `eur`, `nok`, `gbp`, `sek`, `chf`, `hkd`, `huf`, `jpy`, `mxn`, `myr`, `pln`, `czk`, `nzd`, `aed`, `eth`, `ape`, `cop`, `ron`, `thb`, `bgn`, `idr`, `dop`, `php`, `try`, `krw`, `twd`, `vnd`, `pkr`, `clp`, `uyu`, `ars`, `zar`, `dzd`, `tnd`, `mad`, `kes`, `kwd`, `jod`, `all`, `xcd`, `amd`, `bsd`, `bhd`, `bob`, `bam`, `khr`, `crc`, `xof`, `egp`, `etb`, `gmd`, `ghs`, `gtq`, `gyd`, `ils`, `jmd`, `mop`, `mga`, `mur`, `mdl`, `mnt`, `nad`, `ngn`, `mkd`, `omr`, `pyg`, `pen`, `qar`, `rwf`, `sar`, `rsd`, `lkr`, `tzs`, `ttd`, `uzs`, `rub`, `btc`, `cny`, `usdt`, `kzt`, `awg`, `whop_usd`, `xau`, `hnl`

**duration** `string` *required*

할인이 적용되는 기간입니다.

사용 가능한 옵션: `forever`, `once`, `repeating`

**existing\_memberships\_only** `boolean` *required*

프로모션 코드가 기존 멤버십에만 적용되는지 여부입니다.

**expires\_at** `string | null` *required*

프로모션 코드가 만료되는 시각으로, ISO 8601 타임스탬프입니다.

**metadata** `object` *required*

프로모션 코드에 저장된 사용자 정의 키-값 메타데이터입니다.

**new\_users\_only** `boolean` *required*

프로모션 코드가 신규 고객으로 제한되는지 여부입니다.

**one\_per\_customer** `boolean` *required*

각 고객이 프로모션 코드를 한 번만 사용할 수 있는지 여부입니다.

**product** `object | null` *required*

프로모션 코드가 제한되는 상품이며, 상품 범위로 제한되지 않으면 `null`입니다.

> [accordion] 속성
>
> **id** `string` *required*
>
> `prod_` 접두사가 붙은 상품 ID입니다.
>
> **title** `string` *required*
>
> 상품 표시 이름입니다.

**promo\_duration\_months** `integer | null` *required*

할인이 적용되는 청구 주기 수입니다.

**promo\_type** `string` *required*

할인이 비율 기반인지 정액인지 여부입니다.

사용 가능한 옵션: `percentage`, `flat_amount`

**status** `string` *required*

프로모션 코드의 수명 주기 상태입니다.

사용 가능한 옵션: `active`, `inactive`, `archived`

**stock** `integer` *required*

재고가 제한된 경우 최대 사용 횟수입니다.

**unlimited\_stock** `boolean` *required*

프로모션 코드에 사용 한도가 없는지 여부입니다.

**updated\_at** `string` *required*

프로모션 코드가 업데이트된 시각으로, ISO 8601 타임스탬프입니다.

**uses** `integer` *required*

프로모션 코드를 사용한 멤버십 수입니다.

```json PromoCode theme={null}
{
	"id": "promo_xxxxxxxxxxxxxx",
	"code": "SUMMER25",
	"account": {
		"id": "biz_xxxxxxxxxxxxxx",
		"title": "Shine Time Auto Detailing"
	},
	"product": {
		"id": "prod_xxxxxxxxxxxxxx",
		"title": "Ceramic Coating Package"
	},
	"affiliate": {
		"id": "aff_xxxxxxxxxxxxxx",
		"user": {
			"id": "user_xxxxxxxxxxxxxx",
			"username": "danawhitfield",
			"name": "Dana Whitfield",
			"profile_pic": "https://ui-avatars.com/api/?name=Dana+Whitfield"
		}
	},
	"status": "active",
	"promo_type": "percentage",
	"amount_off": 0.25,
	"currency": "usd",
	"duration": "repeating",
	"promo_duration_months": 3,
	"new_users_only": true,
	"churned_users_only": false,
	"existing_memberships_only": false,
	"one_per_customer": true,
	"unlimited_stock": false,
	"stock": 200,
	"uses": 37,
	"expires_at": "2026-12-31T23:59:59.000Z",
	"metadata": {},
	"created_at": "2026-09-01T12:00:00.000Z",
	"updated_at": "2026-09-01T12:00:00.000Z"
}
```
