GET endpoint for products capacities (aggregated from all staking pools, for min cover period) (/v2/capacities)
GET endpoint for individual product capacity (/v2/contracts/:contractAddress/capacity)
Context
In Nexus v1, we display the capacity for each product using capacityETH or capacityDAI.
netStakedNXM was used in a optimized calculation of the cover price on the frontend side.
capacityLimit expresses what is the limiting factor for the capacity - the MCR limit or how much it's staked. This was used to display the right thing to stakers to disallow more stake if MCR is the limiting factor.
For the v2 we'd need capacityETH and capacityDAI for display as well, the key difference is that now we have many pools instead of a global one, so we'd need an extra computation to evaluate that server-side or with a view.
netStakedNXM no longer needed on the frontend.
capacityLimit may still be useful but we need to discuss how we do this, since each pool is independent of each other.
Output
Context
In Nexus v1, we display the capacity for each product using
capacityETH
orcapacityDAI
.netStakedNXM
was used in a optimized calculation of the cover price on the frontend side.capacityLimit
expresses what is the limiting factor for the capacity - the MCR limit or how much it's staked. This was used to display the right thing to stakers to disallow more stake if MCR is the limiting factor.For the v2 we'd need capacityETH and capacityDAI for display as well, the key difference is that now we have many pools instead of a global one, so we'd need an extra computation to evaluate that server-side or with a view.
netStakedNXM
no longer needed on the frontend.capacityLimit
may still be useful but we need to discuss how we do this, since each pool is independent of each other.