@dhedge/backend-flatcoin-core 0.1.23 → 0.1.25

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.
@@ -26,3 +26,25 @@ export declare const LiquidationModule: ({
26
26
  type: string;
27
27
  anonymous?: undefined;
28
28
  })[];
29
+ export declare const Liquidate: {
30
+ inputs: {
31
+ internalType: string;
32
+ name: string;
33
+ type: string;
34
+ }[];
35
+ name: string;
36
+ outputs: never[];
37
+ stateMutability: string;
38
+ type: string;
39
+ }[];
40
+ export declare const LiquidateWithoutPriceFeeds: {
41
+ inputs: {
42
+ internalType: string;
43
+ name: string;
44
+ type: string;
45
+ }[];
46
+ name: string;
47
+ outputs: never[];
48
+ stateMutability: string;
49
+ type: string;
50
+ }[];
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.LiquidationModule = void 0;
3
+ exports.LiquidateWithoutPriceFeeds = exports.Liquidate = exports.LiquidationModule = void 0;
4
4
  exports.LiquidationModule = [
5
5
  {
6
6
  anonymous: false,
@@ -35,27 +35,15 @@ exports.LiquidationModule = [
35
35
  type: 'uint256',
36
36
  },
37
37
  ],
38
- name: 'liquidate',
39
- outputs: [],
40
- stateMutability: 'nonpayable',
41
- type: 'function',
42
- },
43
- {
44
- inputs: [
45
- {
46
- internalType: 'uint256',
47
- name: 'tokenID',
48
- type: 'uint256',
49
- },
38
+ name: 'canLiquidate',
39
+ outputs: [
50
40
  {
51
- internalType: 'bytes[]',
52
- name: 'priceUpdateData',
53
- type: 'bytes[]',
41
+ internalType: 'bool',
42
+ name: 'liquidatable',
43
+ type: 'bool',
54
44
  },
55
45
  ],
56
- name: 'liquidate',
57
- outputs: [],
58
- stateMutability: 'payable',
46
+ stateMutability: 'view',
59
47
  type: 'function',
60
48
  },
61
49
  {
@@ -66,34 +54,50 @@ exports.LiquidationModule = [
66
54
  type: 'uint256',
67
55
  },
68
56
  ],
69
- name: 'canLiquidate',
57
+ name: 'liquidationPrice',
70
58
  outputs: [
71
59
  {
72
- internalType: 'bool',
73
- name: 'liquidatable',
74
- type: 'bool',
60
+ internalType: 'uint256',
61
+ name: 'liqPrice',
62
+ type: 'uint256',
75
63
  },
76
64
  ],
77
65
  stateMutability: 'view',
78
66
  type: 'function',
79
67
  },
68
+ ];
69
+ exports.Liquidate = [
80
70
  {
81
71
  inputs: [
82
72
  {
83
73
  internalType: 'uint256',
84
- name: 'tokenId',
74
+ name: 'tokenID',
85
75
  type: 'uint256',
86
76
  },
77
+ {
78
+ internalType: 'bytes[]',
79
+ name: 'priceUpdateData',
80
+ type: 'bytes[]',
81
+ },
87
82
  ],
88
- name: 'liquidationPrice',
89
- outputs: [
83
+ name: 'liquidate',
84
+ outputs: [],
85
+ stateMutability: 'payable',
86
+ type: 'function',
87
+ },
88
+ ];
89
+ exports.LiquidateWithoutPriceFeeds = [
90
+ {
91
+ inputs: [
90
92
  {
91
93
  internalType: 'uint256',
92
- name: 'liqPrice',
94
+ name: 'tokenId',
93
95
  type: 'uint256',
94
96
  },
95
97
  ],
96
- stateMutability: 'view',
98
+ name: 'liquidate',
99
+ outputs: [],
100
+ stateMutability: 'nonpayable',
97
101
  type: 'function',
98
102
  },
99
103
  ];
@@ -103,7 +103,7 @@ exports.Viewer = [
103
103
  },
104
104
  {
105
105
  internalType: 'uint256',
106
- name: 'entryPrice',
106
+ name: 'lastPrice',
107
107
  type: 'uint256',
108
108
  },
109
109
  {
@@ -3,4 +3,6 @@ export { Viewer } from './abi/viewer';
3
3
  export { FlatcoinErrors } from './abi/flatcoin-errors';
4
4
  export { LeverageModule } from './abi/leverage-module';
5
5
  export { LiquidationModule } from './abi/liquidation-module';
6
+ export { Liquidate } from './abi/liquidation-module';
7
+ export { LiquidateWithoutPriceFeeds } from './abi/liquidation-module';
6
8
  export * from './helpers';
@@ -14,7 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- exports.LiquidationModule = exports.LeverageModule = exports.FlatcoinErrors = exports.Viewer = exports.FlatcoinV1 = void 0;
17
+ exports.LiquidateWithoutPriceFeeds = exports.Liquidate = exports.LiquidationModule = exports.LeverageModule = exports.FlatcoinErrors = exports.Viewer = exports.FlatcoinV1 = void 0;
18
18
  var flatcoin_v1_1 = require("./abi/flatcoin-v1");
19
19
  Object.defineProperty(exports, "FlatcoinV1", { enumerable: true, get: function () { return flatcoin_v1_1.FlatcoinV1; } });
20
20
  var viewer_1 = require("./abi/viewer");
@@ -25,4 +25,8 @@ var leverage_module_1 = require("./abi/leverage-module");
25
25
  Object.defineProperty(exports, "LeverageModule", { enumerable: true, get: function () { return leverage_module_1.LeverageModule; } });
26
26
  var liquidation_module_1 = require("./abi/liquidation-module");
27
27
  Object.defineProperty(exports, "LiquidationModule", { enumerable: true, get: function () { return liquidation_module_1.LiquidationModule; } });
28
+ var liquidation_module_2 = require("./abi/liquidation-module");
29
+ Object.defineProperty(exports, "Liquidate", { enumerable: true, get: function () { return liquidation_module_2.Liquidate; } });
30
+ var liquidation_module_3 = require("./abi/liquidation-module");
31
+ Object.defineProperty(exports, "LiquidateWithoutPriceFeeds", { enumerable: true, get: function () { return liquidation_module_3.LiquidateWithoutPriceFeeds; } });
28
32
  __exportStar(require("./helpers"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dhedge/backend-flatcoin-core",
3
- "version": "0.1.23",
3
+ "version": "0.1.25",
4
4
  "description": "Backend Flatcoin Core",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",