Skip to main content
Ejecuta cualquier Skill en Manus
con un clic

biz-affiliate-system

Estrellas0
Forks0
Actualizado5 de julio de 2026 a las 14:05

Thêm hệ thống affiliate (tiếp thị liên kết) cho landing page Next.js App Router đã có Sepay payment + Supabase lead store — đối tác gắn link aff `?aff=CODE`, skill tự động gán đơn theo last-touch cookie 30 ngày, tính hoa hồng theo tier (Pro 30% / Elite 40%, chỉnh được), tạo bản ghi hoa hồng khi đơn được thanh toán, theo dõi trạng thái chi trả (chờ duyệt → đã duyệt → đã trả). Skill scaffold 3 bảng Supabase (affiliates / affiliate_clicks / affiliate_commissions) + ALTER `leads` thêm cột `aff_code`, thư viện `lib/affiliate.ts`, component `AffiliateTracker` bắt `?aff=` ghi cookie + đếm click, 3 API route (`/api/affiliate/click` public, `/api/affiliate` portal data, `/api/admin/affiliates` quản trị), trang quản trị `/admin/affiliates` (thêm/sửa đối tác, xem doanh thu + hoa hồng từng aff, duyệt + đánh dấu đã trả hoa hồng) và portal đối tác `/affiliate` (đối tác đăng nhập bằng mã aff + email để tự xem link, click, đơn giới thiệu, hoa hồng). Patch 4 file có sẵn (`leads-supabase.ts`, `api/register`, `api/sepay-webhook

Instalación

Instalar con Codex o Claude Copia este prompt, pégalo en Codex, Claude u otro asistente, y deja que revise la página de la skill y la instale por ti.

Explorador de archivos
18 archivos
SKILL.md
readonly