Front-End
Steps for front-end integration
1. Install SDK in Dapp
2. Initialize the Darkpool
// useDeposit.ts
darkPool.init(signer, chainId, [
{
relayerName: '',
relayerAddress: '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266',
hostUrl: 'https://34.142.142.240:18000',
}
], {
priceOracle: config.networkConfig.priceOracle,
ethAddress: config.networkConfig.ethAddress,
nativeWrapper: config.networkConfig.nativeWrapper,
complianceManager: config.networkConfig.complianceManager,
merkleTreeOperator: config.networkConfig.merkleTreeOperator,
darkpoolAssetManager: config.networkConfig.darkpoolAssetManager,
stakingAssetManager: config.networkConfig.stakingAssetManager,
stakingOperator: config.networkConfig.stakingOperator,
drakpoolSubgraphUrl: ''
})3. User makes deposit of assets into Darkpool
4. User generates defiParameters and generates Proof
5. User withdraws assets from Darkpool
Last updated