Step 4: Displaying Chain-Aggregated Balances
PreviousStep 3: Initializing and Depositing onto the OneBalance Smart AccountNextStep 5: Fetch a quote for transaction execution
Last updated
Last updated
You can access the relevant API endpoint for aggregated balances .
This API aggregates balances across the chains supported by the application and takes resource locks into account. When funds on the source chain are locked for asynchronous cross-chain execution, the balance may differ from the direct sum of RPC-based balances.
Example client-side query for retrieving balances:
The address expected in the Search Params of the request is the OneBalance SCA you have retrieved from the /predict-address
endpoint previously.
For more details, see the implementation in our sample application .