npm i @blockswaplab/k2-sdk
fundSplitter
sub-class, the SDK instance can be initialised with the fund splitter contract address as follows:
The SDK supports bothgoerli
(until it is deprecated) andmainnet
, hence the user should choose the network as per the need.
Please note that the SDK is anethers.js
based SDK and hence requiresethers
based signer instance. It also returns values inethers.js
supported format. For example, it returnsBigNumbers
for the smart contract view functions that might returnuint
.
Also note that K2 SDK v2 uses ethers v6(recommended). If you are using K2 SDK v1 which makes use of ethers v5, please create the signer and provider instances in the following way: