affiliate

POST /v1/affiliate

Join the affiliate programme.

Tất cả các điểm cuối affiliate

Xác thực

Gửi khóa API dưới dạng mã thông báo bearer. Điểm cuối này không nêu rõ quyền cụ thể trong thông số kỹ thuật, vì vậy hãy cấp cho khóa của bạn quyền tối thiểu cần thiết và kiểm tra phản hồi thay vì phỏng đoán.

Nơi điền id tổ chức của bạn

Điểm cuối này nhận org_id làm tham số truy vấn. Hãy bỏ trống để áp dụng cho toàn bộ cây thuê của bạn; hoặc truyền giá trị vào để thu hẹp phạm vi gọi về một tổ chức duy nhất.

Mã tổ chức của bạn nằm ở màn hình khóa API trong bảng điều khiển, ngay bên cạnh khóa đó. Đây là cùng một mã trong mọi lệnh gọi mà bạn thực hiện.

Dùng thử

Thay thế bất kỳ nội dung nào trong ngoعل (angle brackets) bằng giá trị của riêng bạn và trình giữ chỗ key bằng một key từ trang tổng quan của bạn.

curl -X POST https://api.zinndigital.com/v1/affiliate \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "commission_plan": <string<recurring_12m, lifetime>>, "payout_destination": <string<wallet, cash>>, "accept_terms": <boolean> }'

Đã đăng nhập? Bảng điều khiển API trong trang quản lý của bạn sẽ tự điền ID tổ chức thực tế và khóa của riêng bạn, sau đó chạy yêu cầu đối với API trực tiếp để bạn có thể xem phản hồi thực tế. Mở điểm cuối này trong bảng điều khiển API

Chi tiết

Gated on `affiliate.manage`. The account lands `pending` and accrues nothing until staff approve it — otherwise the programme is an open invitation to self-refer at scale. Choosing cash payouts sets `kyc_state` to `required`; wallet credit needs no verification because the money never leaves the platform.

Tham số

TênLoạiBắt buộcNội dung này là gì
org_id (query)stringKhông

Nội dung yêu cầu

TênLoạiBắt buộcNội dung này là gì
commission_planstring<recurring_12m, lifetime>
payout_destinationstring<wallet, cash>
accept_termsbooleanMust be `true`. An affiliate agreement is a contract about money, so acceptance is recorded explicitly rather than assumed.

Phản hồi

TênLoạiBắt buộcNội dung này là gì
idstring
org_idstring
statestring<pending, approved, rejected, suspended>
codestringThe referral code. Its alphabet excludes the characters people transcribe wrongly (`0`/`O`, `1`/`I`/`l`), because it is read aloud and typed off a slide.
referral_urlstringThe link to share — the public site with `?ref=CODE`.
commission_planstring<recurring_12m, lifetime>The line **new** referrals will be created on. Changing it never affects customers already referred.
payout_destinationstring<wallet, cash>
kyc_statestring<not_required, required, submitted, verified, rejected>
review_notestringKhông
terms_accepted_atstringKhông
applied_atstringKhông

Các lỗi điểm cuối này có thể trả về

401 · 403 · 409 · 422