0g-chain/x/cdp
Derrick Lee f84a8b0be0
Add /cdp/totalPrincipal and /cdp/totalCollateral Endpoints (#1027)
* Add cdp/totals rest endpoint for aggregated principal and fees

* Add total collateral to aggregated cdp

* Add pagination

* Update totalPrincipal endpoint to use keeper GetTotalPrincipal

* Update documentation for queryGetTotalPrincipal

Co-authored-by: Kevin Davis <karzak@users.noreply.github.com>

* Remove unused AggregatedCDP types

* Make CDP type optional, return all if not provided

* add total collateral endpoint that efficient fetches collateral
for a types, only iterating cdps for types b, etc

* correctly and efficienlty filter for a single collateral type

Co-authored-by: Kevin Davis <karzak@users.noreply.github.com>
Co-authored-by: Nick DeLuca <nickdeluca08@gmail.com>
2021-10-23 13:09:59 -05:00
..
client Add /cdp/totalPrincipal and /cdp/totalCollateral Endpoints (#1027) 2021-10-23 13:09:59 -05:00
keeper Add /cdp/totalPrincipal and /cdp/totalCollateral Endpoints (#1027) 2021-10-23 13:09:59 -05:00
legacy fix: replace is zero time check (#787) 2021-02-02 14:42:51 -07:00
simulation Misc simulation fixes (#963) 2021-07-15 10:46:56 -05:00
spec add liquidate msg to cdp spec (#850) 2021-02-23 12:41:17 -07:00
types Add /cdp/totalPrincipal and /cdp/totalCollateral Endpoints (#1027) 2021-10-23 13:09:59 -05:00
abci_test.go fix: enforce max number of liquidations in cdp begin blocker (#849) 2021-02-23 12:39:39 -07:00
abci.go fix: enforce max number of liquidations in cdp begin blocker (#849) 2021-02-23 12:39:39 -07:00
alias.go [R4R] CDP module migrations from v0.11 -> v0.13 (#769) 2021-01-21 10:37:35 -07:00
genesis_test.go Test CDP init/export genesis (#1014) 2021-09-09 11:54:39 -06:00
genesis.go Genesis import/export fixes (#871) 2021-03-10 21:32:35 -07:00
handler_test.go Add collateral type to cdp (#629) 2020-08-21 15:42:46 -04:00
handler.go Cdp accumulators (#751) 2021-01-18 12:12:37 -07:00
integration_test.go Cdp accumulators (#751) 2021-01-18 12:12:37 -07:00
module.go update format 2020-04-30 10:23:41 -04:00