SumoRouter
SumoRouter Admin API

Affiliates

Server

Referral program results and settings.


List affiliates

GET
https://ai.brandkamu.id/api/admin
/affiliates

Users who referred at least one sign-up, ranked by commission earned, then by referrals.

List affiliates › query Parameters

limit
​integer · min: 1 · max: 200

Page size (clamped to 1-200).

Default: 50
offset
​integer · min: 0

Rows to skip.

Default: 0

List affiliates › Responses

A page of affiliates with program totals.

​Affiliate[] · required
total
​integer · required

Users with at least one referral.

total_commission_nano
​integer · int64 · required

All commission ever paid, nano-USD.

total_bonus_nano
​integer · int64 · required

All referee bonuses ever paid, nano-USD.


Get affiliate settings

GET
https://ai.brandkamu.id/api/admin
/settings/affiliate

The affiliate program terms.

Get affiliate settings › Responses

Affiliate settings.

enabled
​boolean
Default: false
commission_percent
​number · min: 0 · max: 50

Share of each paid top-up of a referred user credited to the referrer.

Default: 10
commission_months
​integer · min: 1 · max: 120

Commission is paid on top-ups within this many months of the referral.

Default: 12
referee_bonus_percent
​number · min: 0 · max: 50

Extra credit for the referred user on their first paid top-up.

Default: 10

Update affiliate settings

PUT
https://ai.brandkamu.id/api/admin
/settings/affiliate

Replaces the program terms. Omitted fields take their defaults (enabled: false, 10 %, 12 months, 10 %), so send all four. Percentages are rounded to two decimals.

Update affiliate settings › Request Body

enabled
​boolean
Default: false
commission_percent
​number · min: 0 · max: 50

Share of each paid top-up of a referred user credited to the referrer.

Default: 10
commission_months
​integer · min: 1 · max: 120

Commission is paid on top-ups within this many months of the referral.

Default: 12
referee_bonus_percent
​number · min: 0 · max: 50

Extra credit for the referred user on their first paid top-up.

Default: 10

Update affiliate settings › Responses

The saved settings.

enabled
​boolean
Default: false
commission_percent
​number · min: 0 · max: 50

Share of each paid top-up of a referred user credited to the referrer.

Default: 10
commission_months
​integer · min: 1 · max: 120

Commission is paid on top-ups within this many months of the referral.

Default: 12
referee_bonus_percent
​number · min: 0 · max: 50

Extra credit for the referred user on their first paid top-up.

Default: 10