Commission rules
Create a commission rule
Counts against the plan's commission-rule quota. Scope to a group or a partner, not both.
Scope: commissions:write (or write)
post/v1/rules
Request
- Base URL: https://api.affiliaterail.com
- URL: https://api.affiliaterail.com/v1/rules
- Auth: HTTP bearer
Request body
Example request
{
"program_id": "prg_7uSyy9FqVLCFWrdPeZaK",
"group_id": "grp_7uSyy9FqVLCFWrdPeZaK",
"partner_id": "part_7uSyy9FqVLCFWrdPeZaK",
"branches": [
{
"id": "flb_7uSyy9FqVLCFWrdPeZaK"
}
]
}Response
The new rule
Example response
{
"id": "flw_7uSyy9FqVLCFWrdPeZaK",
"program_id": "prg_7uSyy9FqVLCFWrdPeZaK",
"group_id": "grp_7uSyy9FqVLCFWrdPeZaK",
"partner_id": "part_7uSyy9FqVLCFWrdPeZaK",
"switch_to_group_id": "grp_7uSyy9FqVLCFWrdPeZaK",
"branches": [
{
"id": "flb_7uSyy9FqVLCFWrdPeZaK",
"rule_id": "flw_7uSyy9FqVLCFWrdPeZaK",
"created_at": "2026-08-21T10:15:30.000Z",
"updated_at": "2026-08-21T10:15:30.000Z"
}
],
"created_at": "2026-08-21T10:15:30.000Z",
"updated_at": "2026-08-21T10:15:30.000Z"
}Changes
No recorded changes to this operation across all 1 revision of this API.