Learn how to pay an IP Asset in TypeScript.
payRoyaltyOnBehalf
function. When this happens, the Royalty Module automatically handles the different payment flows such that parent IP Assets who have negotiated a certain commercialRevShare
with the IPA being paid can claim their due share.
payRoyaltyOnBehalf
function.
You will be paying the IP Asset with $WIP. Note that if you don’t have enough $WIP, the function will auto wrap an equivalent amount of $IP into $WIP for you. If you don’t have enough of either, it will fail.
To help with the following scenarios, let’s say we have a parent IP Asset that has negotiated a 50% commercialRevShare
with its child IP Asset.
payerIpId
a zero address because you are not paying on behalf of an IP Asset. Additionally, you would set amount
to 2.
commercialRevShare
, 50% of the revenue (2*0.5 = 1) would automatically be claimable by the parent thanks to the Royalty Module, such that both the parent and child IP Assets earn 1 $WIP. We’ll go over this on the next page.