Skip to main content

AffiliateManager

This contract handles the management of affiliates for the LooksRare protocol.

isAffiliateProgramActive

bool isAffiliateProgramActive

Whether the affiliate program is active.

affiliateController

address affiliateController

Address of the affiliate controller.

affiliateRates

mapping(address => uint256) affiliateRates

It tracks the affiliate rate (in basis point) for a given affiliate address. The basis point represents how much of the protocol fee will be shared to the affiliate.

constructor

constructor(address _owner) public

Constructor

Parameters

NameTypeDescription
_owneraddressOwner address

updateAffiliateRate

function updateAffiliateRate(address affiliate, uint256 bp) external

This function allows the affiliate controller to update the affiliate rate (in basis point).

Parameters

NameTypeDescription
affiliateaddressAffiliate address
bpuint256Rate (in basis point) to collect (e.g. 100 = 1%) per referred transaction

updateAffiliateController

function updateAffiliateController(address newAffiliateController) external

This function allows the owner to update the affiliate controller address.

Only callable by owner.

Parameters

NameTypeDescription
newAffiliateControlleraddressNew affiliate controller address

updateAffiliateProgramStatus

function updateAffiliateProgramStatus(bool isActive) external

This function allows the owner to update the affiliate program status.

Only callable by owner.

Parameters

NameTypeDescription
isActiveboolWhether the affiliate program is active