Usage
Returns
Parameters
channelAddress
- type:
string
transactionOverrides (optional)
- type:
TransactionOverrides
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Distribute rewards and settle a finite channel. This function is callable by anyone after the channel mintEnd has passed.
import { uplinkClient } from './config'
const { event } = await uplinkClient.settleFiniteChannel({
channelAddress: '0x1234567890123456789012345678901234567890'
})
import { TransmissionsClient } from '@tx-kit/sdk'
import { CreatePublicClient, CreateWalletClient } from 'viem'
import { base } from 'viem/chains'
const publicClient = createPublicClient({
chain: base,
transport: http()
})
const walletClient = createWalletClient({
account, // from local private key or browser wallet
chain: base,
transport: http()
})
export const { uplinkClient } = new TransmissionsClient({
publicClient,
walletClient,
chain: base
})
{
event: Log
}
stringconst { event } = await uplinkClient.settleFiniteChannel({
channelAddress: '0x1234567890123456789012345678901234567890',
...
})
TransactionOverridestype TransactionOverrides = {
accessList?: AccessList
gas?: bigint
maxFeePerGas?: bigint
maxPriorityFeePerGas?: bigint
nonce?: number
value?: bigint
}
const { event } = await uplinkClient.settleFiniteChannel({
...
transactionOverrides: {
gas: 1000000n
}
})
const { address, data } = await uplinkClient.calldata.settleFiniteChannel({...})
{
address: string, // address of the target contract
data: string // calldata for the transaction
}
const gas = await uplinkClient.estimateGas.settleFiniteChannel({...})
bigint // gas estimate in wei