Options for withdrawing accumulated protocol fees via OnboardingBridgeSDK.withdrawFees.

Only the configured fee-collector address may call this.

const balance = await sdk.getFeeBalance('CD...');
await sdk.withdrawFees({ asset: 'CD...', amount: balance }, feeCollectorKeypair);
interface WithdrawFeesOptions {
    amount: string;
    asset: string;
}

Properties

Properties

amount: string

Amount to withdraw, in the token's smallest unit. Must not exceed accrued fees.

asset: string

Token contract address to withdraw fees for.