Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request to develop a new service to get the balance of qubics and assets for multiple addresses #26

Open
sallymoc opened this issue Sep 20, 2024 · 0 comments

Comments

@sallymoc
Copy link

sallymoc commented Sep 20, 2024

As we don't have support for websockets, our wallet apps (web and mobile) need to fetch periodically (currently every minute in the case of the mobile app) the balance for the accounts/addresses in the wallet.

In qubic.li api there we had for this purpose:
https://api.qubic.li/Wallet/NetworkBalances: returns qubic balances
https://api.qubic.li/Wallet/Assets: returns own and possessed assets

both post services, receiving in the body the array of public IDs from where we want to fetch the data.
Considering N the number of accounts/addressed the user has in his/her wallet, we see in the available APIs, the services available have the following restrictions:

  • /balances/{id} supports a single address, this means, we would have to call this N times
  • for assets, the owned and possessed assets information is returned with two separated services
  • [/assets/{identity}/possessed] and [/assets/{identity}/owned] and both support a single address. This means, we well have to make Nx2 requests for this

We would like to have the response returned by the services mentioned above, consolidated in one single service that supports multiple addresses as input.

Also, it would be possible to also have a service that returns only the lastUpdate timestamp for a group of addresses, so we can fetch every time only the data for the accounts whose balance has changed since the last time it was fetched.

@sallymoc sallymoc changed the title New service to get the balance of qubics and assets for multiple addresses Request to develop a new service to get the balance of qubics and assets for multiple addresses Sep 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant