Skip to main content

Interface: GetResponseUserBalance

The indexer returns user's contract balance in this structure. Also, SDK's modal to claim user's balance consumes this as an input to display the balance for the user before claiming

Example

How returned values might look like for pending and claimable ETH/USDT/USDC balance
{
pending: [
{
token: {
address: "0x0000000000000000000000000000000000000000",
symbol: "ETH",
decimals: 18
},
status: "Pending",
amount: "1586200000000000000",
total: "1586200000000000000",
displayableAmount: "1.5862",
amountBN: "1.5862"
}
],
readyForClaim: [
{
token: {
address: "0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8",
symbol: "USDC",
decimals: 6
},
status: "Ready to claim",
amount: "1786200000",
total: "1786200000",
displayableAmount: "1786.2",
amountBN: "1786.2"
},
{
token: {
address: "0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9",
symbol: "USDT",
decimals: 6
},
status: "Ready to claim",
amount: "2379300000",
total: "2379300000",
displayableAmount: "2379.3",
amountBN: "2379.3"
}
]
}

Properties

pending

pending: IBalanceWithTokenInfo[]

Balance in escrows where the challenge period hasn't ended yet

Defined in

typing/index.ts:992


readyForClaim

readyForClaim: IBalanceWithTokenInfo[]

Balance that can be claimed from the contract

Defined in

typing/index.ts:994