def params(self, key: Optional[str] = None) -> Union[ApiResponse, Dec, dict]: res = self._api_get("/market/parameters") p = JiguBox(res) p["pool_recovery_period"] = int(p["pool_recovery_period"]) p["base_pool"] = Dec.deserialize(p["base_pool"]) p["min_spread"] = Dec.deserialize(p["min_spread"]) p["tobin_tax"] = Dec.deserialize(p["tobin_tax"]) ill = p["illiquid_tobin_tax_list"] p["illiquid_tobin_tax_list"] = JiguBox({}) for item in ill: p["illiquid_tobin_tax_list"][item["denom"]] = Dec(item["tax_rate"]) return project(res, p[key] if key else p)
def reward_weight(self) -> Union[ApiResponse, Dec]: res = self._api_get("/treasury/reward_weight") # rw return project(res, Dec.deserialize(res))
def tax_rate(self) -> Union[ApiResponse, Dec]: res = self._api_get("/treasury/tax_rate") # tr return project(res, Dec.deserialize(res))
def terra_pool_delta(self) -> Union[ApiResponse, Dec]: res = self._api_get("/market/terra_pool_delta") return project(res, Dec.deserialize(res))