forked from storyprotocol/sdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add collectRoyaltyTokens and payRoyaltyOnBehalf in royalty (#120)
* Add royality test setup * Update Royalty abi * Add collectRoyaltyTokens method * Update abi for getRoyaltyData method * Update abi for other royalty methods * Add collectRoyaltyTokens and payRoyaltyOnBehalfin royalty * Update tokenId * Export royalty types * Upgrade version and skip storyNet tests * Refactor code
- Loading branch information
Showing
17 changed files
with
660 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
export default [ | ||
{ | ||
inputs: [ | ||
{ | ||
internalType: "address", | ||
name: "receiverIpId", | ||
type: "address", | ||
}, | ||
{ | ||
internalType: "address", | ||
name: "payerIpId", | ||
type: "address", | ||
}, | ||
{ | ||
internalType: "address", | ||
name: "token", | ||
type: "address", | ||
}, | ||
{ | ||
internalType: "uint256", | ||
name: "amount", | ||
type: "uint256", | ||
}, | ||
], | ||
name: "payRoyaltyOnBehalf", | ||
outputs: [], | ||
stateMutability: "nonpayable", | ||
type: "function", | ||
}, | ||
] as const; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
export default [ | ||
{ | ||
inputs: [ | ||
{ | ||
internalType: "address", | ||
name: "ipId", | ||
type: "address", | ||
}, | ||
], | ||
name: "getRoyaltyData", | ||
outputs: [ | ||
{ | ||
internalType: "bool", | ||
name: "", | ||
type: "bool", | ||
}, | ||
{ | ||
internalType: "address", | ||
name: "", | ||
type: "address", | ||
}, | ||
{ | ||
internalType: "uint32", | ||
name: "", | ||
type: "uint32", | ||
}, | ||
{ | ||
internalType: "address[]", | ||
name: "", | ||
type: "address[]", | ||
}, | ||
{ | ||
internalType: "uint32[]", | ||
name: "", | ||
type: "uint32[]", | ||
}, | ||
], | ||
stateMutability: "view", | ||
type: "function", | ||
}, | ||
{ | ||
inputs: [ | ||
{ | ||
internalType: "address", | ||
name: "caller", | ||
type: "address", | ||
}, | ||
{ | ||
internalType: "address", | ||
name: "ipId", | ||
type: "address", | ||
}, | ||
{ | ||
internalType: "address", | ||
name: "token", | ||
type: "address", | ||
}, | ||
{ | ||
internalType: "uint256", | ||
name: "amount", | ||
type: "uint256", | ||
}, | ||
], | ||
name: "onRoyaltyPayment", | ||
outputs: [], | ||
stateMutability: "nonpayable", | ||
type: "function", | ||
}, | ||
] as const; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
export default [ | ||
{ | ||
inputs: [ | ||
{ | ||
internalType: "uint256[]", | ||
name: "snapshotIds", | ||
type: "uint256[]", | ||
}, | ||
{ | ||
internalType: "address", | ||
name: "token", | ||
type: "address", | ||
}, | ||
], | ||
name: "claimRevenueBySnapshotBatch", | ||
outputs: [], | ||
stateMutability: "nonpayable", | ||
type: "function", | ||
}, | ||
{ | ||
inputs: [ | ||
{ | ||
internalType: "uint256", | ||
name: "snapshotId", | ||
type: "uint256", | ||
}, | ||
{ | ||
internalType: "address[]", | ||
name: "tokens", | ||
type: "address[]", | ||
}, | ||
], | ||
name: "claimRevenueByTokenBatch", | ||
outputs: [], | ||
stateMutability: "nonpayable", | ||
type: "function", | ||
}, | ||
{ | ||
inputs: [ | ||
{ | ||
internalType: "address", | ||
name: "account", | ||
type: "address", | ||
}, | ||
{ | ||
internalType: "uint256", | ||
name: "snapshotId", | ||
type: "uint256", | ||
}, | ||
{ | ||
internalType: "address", | ||
name: "token", | ||
type: "address", | ||
}, | ||
], | ||
name: "claimableRevenue", | ||
outputs: [ | ||
{ | ||
internalType: "uint256", | ||
name: "", | ||
type: "uint256", | ||
}, | ||
], | ||
stateMutability: "view", | ||
type: "function", | ||
}, | ||
{ | ||
inputs: [ | ||
{ | ||
internalType: "address", | ||
name: "ancestorIpId", | ||
type: "address", | ||
}, | ||
], | ||
name: "collectRoyaltyTokens", | ||
outputs: [], | ||
stateMutability: "nonpayable", | ||
type: "function", | ||
}, | ||
{ | ||
inputs: [], | ||
name: "ipId", | ||
outputs: [ | ||
{ | ||
internalType: "address", | ||
name: "", | ||
type: "address", | ||
}, | ||
], | ||
stateMutability: "view", | ||
type: "function", | ||
}, | ||
] as const; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.