@sovryn-zero/lib-base 0.1.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,61 +1,61 @@
1
- import { Decimal } from "./Decimal";
2
- /**
3
- * Total collateral ratio below which recovery mode is triggered.
4
- *
5
- * @public
6
- */
7
- export declare const CRITICAL_COLLATERAL_RATIO: Decimal;
8
- /**
9
- * Collateral ratio below which a Trove can be liquidated in normal mode.
10
- *
11
- * @public
12
- */
13
- export declare const MINIMUM_COLLATERAL_RATIO: Decimal;
14
- /**
15
- * Amount of ZUSD that's reserved for compensating the liquidator of a Trove.
16
- *
17
- * @public
18
- */
19
- export declare const ZUSD_LIQUIDATION_RESERVE: Decimal;
20
- /**
21
- * A Trove must always have at least this much debt on top of the
22
- * {@link ZUSD_LIQUIDATION_RESERVE | liquidation reserve}.
23
- *
24
- * @remarks
25
- * Any transaction that would result in a Trove with less net debt than this will be reverted.
26
- *
27
- * @public
28
- */
29
- export declare const ZUSD_MINIMUM_NET_DEBT: Decimal;
30
- /**
31
- * A Trove must always have at least this much debt.
32
- *
33
- * @remarks
34
- * Any transaction that would result in a Trove with less debt than this will be reverted.
35
- *
36
- * @public
37
- */
38
- export declare const ZUSD_MINIMUM_DEBT: Decimal;
39
- /**
40
- * Value that the {@link Fees.borrowingRate | borrowing rate} will never decay below.
41
- *
42
- * @remarks
43
- * Note that the borrowing rate can still be lower than this during recovery mode, when it's
44
- * overridden by zero.
45
- *
46
- * @public
47
- */
48
- export declare const MINIMUM_BORROWING_RATE: Decimal;
49
- /**
50
- * Value that the {@link Fees.borrowingRate | borrowing rate} will never exceed.
51
- *
52
- * @public
53
- */
54
- export declare const MAXIMUM_BORROWING_RATE: Decimal;
55
- /**
56
- * Value that the {@link Fees.redemptionRate | redemption rate} will never decay below.
57
- *
58
- * @public
59
- */
60
- export declare const MINIMUM_REDEMPTION_RATE: Decimal;
1
+ import { Decimal } from "./Decimal";
2
+ /**
3
+ * Total collateral ratio below which recovery mode is triggered.
4
+ *
5
+ * @public
6
+ */
7
+ export declare const CRITICAL_COLLATERAL_RATIO: Decimal;
8
+ /**
9
+ * Collateral ratio below which a Trove can be liquidated in normal mode.
10
+ *
11
+ * @public
12
+ */
13
+ export declare const MINIMUM_COLLATERAL_RATIO: Decimal;
14
+ /**
15
+ * Amount of ZUSD that's reserved for compensating the liquidator of a Trove.
16
+ *
17
+ * @public
18
+ */
19
+ export declare const ZUSD_LIQUIDATION_RESERVE: Decimal;
20
+ /**
21
+ * A Trove must always have at least this much debt on top of the
22
+ * {@link ZUSD_LIQUIDATION_RESERVE | liquidation reserve}.
23
+ *
24
+ * @remarks
25
+ * Any transaction that would result in a Trove with less net debt than this will be reverted.
26
+ *
27
+ * @public
28
+ */
29
+ export declare const ZUSD_MINIMUM_NET_DEBT: Decimal;
30
+ /**
31
+ * A Trove must always have at least this much debt.
32
+ *
33
+ * @remarks
34
+ * Any transaction that would result in a Trove with less debt than this will be reverted.
35
+ *
36
+ * @public
37
+ */
38
+ export declare const ZUSD_MINIMUM_DEBT: Decimal;
39
+ /**
40
+ * Value that the {@link Fees.borrowingRate | borrowing rate} will never decay below.
41
+ *
42
+ * @remarks
43
+ * Note that the borrowing rate can still be lower than this during recovery mode, when it's
44
+ * overridden by zero.
45
+ *
46
+ * @public
47
+ */
48
+ export declare const MINIMUM_BORROWING_RATE: Decimal;
49
+ /**
50
+ * Value that the {@link Fees.borrowingRate | borrowing rate} will never exceed.
51
+ *
52
+ * @public
53
+ */
54
+ export declare const MAXIMUM_BORROWING_RATE: Decimal;
55
+ /**
56
+ * Value that the {@link Fees.redemptionRate | redemption rate} will never decay below.
57
+ *
58
+ * @public
59
+ */
60
+ export declare const MINIMUM_REDEMPTION_RATE: Decimal;
61
61
  //# sourceMappingURL=constants.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,SAAoB,CAAC;AAE3D;;;;GAIG;AACH,eAAO,MAAM,wBAAwB,SAAoB,CAAC;AAE1D;;;;GAIG;AACH,eAAO,MAAM,wBAAwB,SAAmB,CAAC;AAEzD;;;;;;;;GAQG;AACH,eAAO,MAAM,qBAAqB,SAAoB,CAAC;AAEvD;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB,SAAsD,CAAC;AAErF;;;;;;;;GAQG;AACH,eAAO,MAAM,sBAAsB,SAAsB,CAAC;AAE1D;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,SAAqB,CAAC;AAEzD;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,SAAsB,CAAC"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC;;;;GAIG;AACH,eAAO,MAAM,yBAAyB,SAAoB,CAAC;AAE3D;;;;GAIG;AACH,eAAO,MAAM,wBAAwB,SAAoB,CAAC;AAE1D;;;;GAIG;AACH,eAAO,MAAM,wBAAwB,SAAmB,CAAC;AAEzD;;;;;;;;GAQG;AACH,eAAO,MAAM,qBAAqB,SAAoB,CAAC;AAEvD;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB,SAAsD,CAAC;AAErF;;;;;;;;GAQG;AACH,eAAO,MAAM,sBAAsB,SAAqB,CAAC;AAEzD;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,SAAsB,CAAC;AAE1D;;;;GAIG;AACH,eAAO,MAAM,uBAAuB,SAAsB,CAAC"}
@@ -1,64 +1,64 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MINIMUM_REDEMPTION_RATE = exports.MAXIMUM_BORROWING_RATE = exports.MINIMUM_BORROWING_RATE = exports.ZUSD_MINIMUM_DEBT = exports.ZUSD_MINIMUM_NET_DEBT = exports.ZUSD_LIQUIDATION_RESERVE = exports.MINIMUM_COLLATERAL_RATIO = exports.CRITICAL_COLLATERAL_RATIO = void 0;
4
- const Decimal_1 = require("./Decimal");
5
- /**
6
- * Total collateral ratio below which recovery mode is triggered.
7
- *
8
- * @public
9
- */
10
- exports.CRITICAL_COLLATERAL_RATIO = Decimal_1.Decimal.from(1.5);
11
- /**
12
- * Collateral ratio below which a Trove can be liquidated in normal mode.
13
- *
14
- * @public
15
- */
16
- exports.MINIMUM_COLLATERAL_RATIO = Decimal_1.Decimal.from(1.1);
17
- /**
18
- * Amount of ZUSD that's reserved for compensating the liquidator of a Trove.
19
- *
20
- * @public
21
- */
22
- exports.ZUSD_LIQUIDATION_RESERVE = Decimal_1.Decimal.from(20);
23
- /**
24
- * A Trove must always have at least this much debt on top of the
25
- * {@link ZUSD_LIQUIDATION_RESERVE | liquidation reserve}.
26
- *
27
- * @remarks
28
- * Any transaction that would result in a Trove with less net debt than this will be reverted.
29
- *
30
- * @public
31
- */
32
- exports.ZUSD_MINIMUM_NET_DEBT = Decimal_1.Decimal.from(180);
33
- /**
34
- * A Trove must always have at least this much debt.
35
- *
36
- * @remarks
37
- * Any transaction that would result in a Trove with less debt than this will be reverted.
38
- *
39
- * @public
40
- */
41
- exports.ZUSD_MINIMUM_DEBT = exports.ZUSD_LIQUIDATION_RESERVE.add(exports.ZUSD_MINIMUM_NET_DEBT);
42
- /**
43
- * Value that the {@link Fees.borrowingRate | borrowing rate} will never decay below.
44
- *
45
- * @remarks
46
- * Note that the borrowing rate can still be lower than this during recovery mode, when it's
47
- * overridden by zero.
48
- *
49
- * @public
50
- */
51
- exports.MINIMUM_BORROWING_RATE = Decimal_1.Decimal.from(0.025);
52
- /**
53
- * Value that the {@link Fees.borrowingRate | borrowing rate} will never exceed.
54
- *
55
- * @public
56
- */
57
- exports.MAXIMUM_BORROWING_RATE = Decimal_1.Decimal.from(0.05);
58
- /**
59
- * Value that the {@link Fees.redemptionRate | redemption rate} will never decay below.
60
- *
61
- * @public
62
- */
63
- exports.MINIMUM_REDEMPTION_RATE = Decimal_1.Decimal.from(0.025);
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.MINIMUM_REDEMPTION_RATE = exports.MAXIMUM_BORROWING_RATE = exports.MINIMUM_BORROWING_RATE = exports.ZUSD_MINIMUM_DEBT = exports.ZUSD_MINIMUM_NET_DEBT = exports.ZUSD_LIQUIDATION_RESERVE = exports.MINIMUM_COLLATERAL_RATIO = exports.CRITICAL_COLLATERAL_RATIO = void 0;
4
+ const Decimal_1 = require("./Decimal");
5
+ /**
6
+ * Total collateral ratio below which recovery mode is triggered.
7
+ *
8
+ * @public
9
+ */
10
+ exports.CRITICAL_COLLATERAL_RATIO = Decimal_1.Decimal.from(1.5);
11
+ /**
12
+ * Collateral ratio below which a Trove can be liquidated in normal mode.
13
+ *
14
+ * @public
15
+ */
16
+ exports.MINIMUM_COLLATERAL_RATIO = Decimal_1.Decimal.from(1.1);
17
+ /**
18
+ * Amount of ZUSD that's reserved for compensating the liquidator of a Trove.
19
+ *
20
+ * @public
21
+ */
22
+ exports.ZUSD_LIQUIDATION_RESERVE = Decimal_1.Decimal.from(20);
23
+ /**
24
+ * A Trove must always have at least this much debt on top of the
25
+ * {@link ZUSD_LIQUIDATION_RESERVE | liquidation reserve}.
26
+ *
27
+ * @remarks
28
+ * Any transaction that would result in a Trove with less net debt than this will be reverted.
29
+ *
30
+ * @public
31
+ */
32
+ exports.ZUSD_MINIMUM_NET_DEBT = Decimal_1.Decimal.from(180);
33
+ /**
34
+ * A Trove must always have at least this much debt.
35
+ *
36
+ * @remarks
37
+ * Any transaction that would result in a Trove with less debt than this will be reverted.
38
+ *
39
+ * @public
40
+ */
41
+ exports.ZUSD_MINIMUM_DEBT = exports.ZUSD_LIQUIDATION_RESERVE.add(exports.ZUSD_MINIMUM_NET_DEBT);
42
+ /**
43
+ * Value that the {@link Fees.borrowingRate | borrowing rate} will never decay below.
44
+ *
45
+ * @remarks
46
+ * Note that the borrowing rate can still be lower than this during recovery mode, when it's
47
+ * overridden by zero.
48
+ *
49
+ * @public
50
+ */
51
+ exports.MINIMUM_BORROWING_RATE = Decimal_1.Decimal.from(0.05);
52
+ /**
53
+ * Value that the {@link Fees.borrowingRate | borrowing rate} will never exceed.
54
+ *
55
+ * @public
56
+ */
57
+ exports.MAXIMUM_BORROWING_RATE = Decimal_1.Decimal.from(0.075);
58
+ /**
59
+ * Value that the {@link Fees.redemptionRate | redemption rate} will never decay below.
60
+ *
61
+ * @public
62
+ */
63
+ exports.MINIMUM_REDEMPTION_RATE = Decimal_1.Decimal.from(0.019);
64
64
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":";;;AAAA,uCAAoC;AAEpC;;;;GAIG;AACU,QAAA,yBAAyB,GAAG,iBAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAE3D;;;;GAIG;AACU,QAAA,wBAAwB,GAAG,iBAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAE1D;;;;GAIG;AACU,QAAA,wBAAwB,GAAG,iBAAO,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AAEzD;;;;;;;;GAQG;AACU,QAAA,qBAAqB,GAAG,iBAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAEvD;;;;;;;GAOG;AACU,QAAA,iBAAiB,GAAG,gCAAwB,CAAC,GAAG,CAAC,6BAAqB,CAAC,CAAC;AAErF;;;;;;;;GAQG;AACU,QAAA,sBAAsB,GAAG,iBAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AAE1D;;;;GAIG;AACU,QAAA,sBAAsB,GAAG,iBAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAEzD;;;;GAIG;AACU,QAAA,uBAAuB,GAAG,iBAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC"}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":";;;AAAA,uCAAoC;AAEpC;;;;GAIG;AACU,QAAA,yBAAyB,GAAG,iBAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAE3D;;;;GAIG;AACU,QAAA,wBAAwB,GAAG,iBAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAE1D;;;;GAIG;AACU,QAAA,wBAAwB,GAAG,iBAAO,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AAEzD;;;;;;;;GAQG;AACU,QAAA,qBAAqB,GAAG,iBAAO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAEvD;;;;;;;GAOG;AACU,QAAA,iBAAiB,GAAG,gCAAwB,CAAC,GAAG,CAAC,6BAAqB,CAAC,CAAC;AAErF;;;;;;;;GAQG;AACU,QAAA,sBAAsB,GAAG,iBAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAEzD;;;;GAIG;AACU,QAAA,sBAAsB,GAAG,iBAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AAE1D;;;;GAIG;AACU,QAAA,uBAAuB,GAAG,iBAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sovryn-zero/lib-base",
3
- "version": "0.1.0",
3
+ "version": "0.2.1",
4
4
  "description": "Sovryn Zero SDK shared interfaces",
5
5
  "keywords": [
6
6
  "Sovryn",
@@ -49,4 +49,4 @@
49
49
  "ts-node": "9.1.1",
50
50
  "typescript": "4.1.5"
51
51
  }
52
- }
52
+ }
package/src/constants.ts CHANGED
@@ -51,18 +51,18 @@ export const ZUSD_MINIMUM_DEBT = ZUSD_LIQUIDATION_RESERVE.add(ZUSD_MINIMUM_NET_D
51
51
  *
52
52
  * @public
53
53
  */
54
- export const MINIMUM_BORROWING_RATE = Decimal.from(0.025);
54
+ export const MINIMUM_BORROWING_RATE = Decimal.from(0.05);
55
55
 
56
56
  /**
57
57
  * Value that the {@link Fees.borrowingRate | borrowing rate} will never exceed.
58
58
  *
59
59
  * @public
60
60
  */
61
- export const MAXIMUM_BORROWING_RATE = Decimal.from(0.05);
61
+ export const MAXIMUM_BORROWING_RATE = Decimal.from(0.075);
62
62
 
63
63
  /**
64
64
  * Value that the {@link Fees.redemptionRate | redemption rate} will never decay below.
65
65
  *
66
66
  * @public
67
67
  */
68
- export const MINIMUM_REDEMPTION_RATE = Decimal.from(0.025);
68
+ export const MINIMUM_REDEMPTION_RATE = Decimal.from(0.019);