Splits
Utility Module for Split Payment Management
The Splits smart contract module is an integration with 0xSplits, designed to facilitate managing and bundling operations related to split payments among multiple parties. It allows for the creation of revenue splits, where a percentage of incoming funds is allocated to designated accounts.
The Splits module serves as an interface and a proxy to 0xSplits, and is inherited by several other contracts, including Edition, Rentable, Series, Crescendo, ZKEdition, and FeeManager. This means the Splits methods documented below can be called directly on any of the inheriting contracts.
Smart Contract Methods
createSplit
Creates a revenue split.
distributeETH
Distributes ETH to split recipients.
distributeERC20
Distributes an ERC20 token to split recipients.
distributeAndWithdraw
Distributes ETH and ERC20 tokens to split recipients, and withdraws for a designated account.
transferToSplit
Transfers ETH and ERC20 tokens to the split wallet
createSplit
Creates a revenue split.
_splitMain (address)
the address of the SplitMain contract
0xSplits SplitMain: 0x2ed6c4B5dA6378c7897AC67Ba9e43102Feb694EE
*Use the above address for Mainnet/Testnet Eth/Polygon/Optimism/Arbitrum
accounts (address[])
an array of addresses representing the accounts that will receive payments
percentAllocations (uint32[])
an array of percentages representing the percentage allocation of payments to each account
distributorFee (uint32)
the percentage of the payment that is kept by the distributor
distributorAddress (address)
the address of the distributor
distributeETH
Distributes ETH to split recipients.
accounts (address[])
an array of addresses representing the accounts that will receive payments
percentAllocations (uint32[])
an array of percentages representing the percentage allocation of payments to each account
distributorFee (uint32)
the percentage of the payment that is kept by the distributor
distributorAddress (address)
the address of the distributor
distributeERC20
Distributes an ERC20 token to split recipients.
token (ERC20)
the ERC20 token to be distributed
accounts (address[])
an array of addresses representing the accounts that will receive payments
percentAllocations (uint32[])
an array of percentages representing the percentage allocation of payments to each account
distributorFee (uint32)
the percentage of the payment that is kept by the distributor
distributorAddress (address)
the address of the distributor
distributeAndWithdraw
Distributes ETH and ERC20 tokens to split recipients, and withdraws for a designated account.
account (address)
the address of the account to withdraw funds to
withdrawETH (uint256)
the amount of ETH to withdraw
tokens (ERC20[])
an array of ERC20 tokens to withdraw
accounts (address[])
an array of addresses representing the accounts that will receive payments
percentAllocations (uint32[])
an array of percentages representing the percentage allocation of payments to each account
distributorFee (uint32)
the percentage of the payment that is kept by the distributor
distributorAddress (address)
the address of the distributor
transferToSplit
Transfers ETH and ERC20 tokens to the split wallet
transferETH (uint256)
a numerical boolean representing whether ETH should be transferred to the split wallet
tokens (ERC20[])
an array of ERC20 tokens to be transferred to the split wallet
Updated about 1 month ago