Skip to content

Max deposit / withdraw for add / remove liquidity #1617

@MattPereira

Description

@MattPereira

For the UX lets display warning if user enters underlying token amount > maxDeposit?

Fetch max amount options:

  • query the API and look at maxDeposit / maxWithdraw ? ( 20 min cache duration )
  • make rpc call on chain to erc4626 token to read the values

https://balancerecosystem.slack.com/archives/C02F9EMRKQA/p1758860723233539

Image Image
query MyQuery {
  aggregatorPools(
    where: {chainIn: PLASMA, idIn: ["0xda51975d78cb172b46d7292cec9fa9e74723ef3b", "0x6a74be33b5393d8a3eba4d69b78f9d9da947c48c"], includeHooks: STABLE_SURGE}
  ) {
    type
    poolTokens {
      address
      isErc4626
      maxDeposit
      maxWithdraw
    }
    id
  }
}

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions