carbon-js-sdk 0.2.15 → 0.2.16-dev.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.
Files changed (272) hide show
  1. package/lib/CarbonSDK.d.ts +13 -1
  2. package/lib/CarbonSDK.js +31 -2
  3. package/lib/clients/ETHClient.d.ts +1 -1
  4. package/lib/clients/NEOClient.d.ts +1 -1
  5. package/lib/clients/NEOClient.js +1 -1
  6. package/lib/clients/TokenClient.d.ts +5 -0
  7. package/lib/clients/TokenClient.js +38 -10
  8. package/lib/clients/ZILClient.d.ts +1 -1
  9. package/lib/codec/book/genesis.d.ts +1 -1
  10. package/lib/codec/book/genesis.js +1 -1
  11. package/lib/codec/book/query.d.ts +1 -1
  12. package/lib/codec/book/query.js +1 -1
  13. package/lib/codec/broker/genesis.d.ts +1 -1
  14. package/lib/codec/broker/genesis.js +1 -1
  15. package/lib/codec/broker/query.d.ts +3 -3
  16. package/lib/codec/broker/query.js +3 -3
  17. package/lib/codec/btcx/denom_cross_chain_info.d.ts +1 -1
  18. package/lib/codec/btcx/denom_cross_chain_info.js +1 -1
  19. package/lib/codec/btcx/query.d.ts +1 -1
  20. package/lib/codec/btcx/query.js +1 -1
  21. package/lib/codec/ccm/genesis.d.ts +1 -1
  22. package/lib/codec/ccm/genesis.js +1 -1
  23. package/lib/codec/cdp/asset_params.d.ts +1 -1
  24. package/lib/codec/cdp/asset_params.js +11 -10
  25. package/lib/codec/cdp/event.d.ts +389 -22
  26. package/lib/codec/cdp/event.js +2494 -83
  27. package/lib/codec/cdp/genesis.d.ts +97 -4
  28. package/lib/codec/cdp/genesis.js +648 -23
  29. package/lib/codec/cdp/params.d.ts +8 -0
  30. package/lib/codec/cdp/params.js +52 -9
  31. package/lib/codec/cdp/query.d.ts +439 -89
  32. package/lib/codec/cdp/query.js +1995 -177
  33. package/lib/codec/cdp/reward_scheme.d.ts +0 -13
  34. package/lib/codec/cdp/reward_scheme.js +1 -91
  35. package/lib/codec/cdp/tx.d.ts +760 -96
  36. package/lib/codec/cdp/tx.js +3645 -235
  37. package/lib/codec/coin/event.d.ts +1 -1
  38. package/lib/codec/coin/event.js +1 -1
  39. package/lib/codec/coin/genesis.d.ts +2 -2
  40. package/lib/codec/coin/genesis.js +2 -2
  41. package/lib/codec/coin/proposal.d.ts +1 -1
  42. package/lib/codec/coin/proposal.js +1 -1
  43. package/lib/codec/coin/query.d.ts +2 -2
  44. package/lib/codec/coin/query.js +2 -2
  45. package/lib/codec/coin/tx.d.ts +1 -1
  46. package/lib/codec/coin/tx.js +1 -1
  47. package/lib/codec/cosmos/auth/v1beta1/genesis.d.ts +1 -1
  48. package/lib/codec/cosmos/auth/v1beta1/genesis.js +1 -1
  49. package/lib/codec/cosmos/auth/v1beta1/query.d.ts +2 -2
  50. package/lib/codec/cosmos/auth/v1beta1/query.js +2 -2
  51. package/lib/codec/cosmos/authz/v1beta1/genesis.d.ts +1 -1
  52. package/lib/codec/cosmos/authz/v1beta1/genesis.js +1 -1
  53. package/lib/codec/cosmos/authz/v1beta1/query.d.ts +2 -2
  54. package/lib/codec/cosmos/authz/v1beta1/query.js +2 -2
  55. package/lib/codec/cosmos/authz/v1beta1/tx.d.ts +1 -1
  56. package/lib/codec/cosmos/authz/v1beta1/tx.js +1 -1
  57. package/lib/codec/cosmos/bank/v1beta1/authz.d.ts +1 -1
  58. package/lib/codec/cosmos/bank/v1beta1/authz.js +1 -1
  59. package/lib/codec/cosmos/bank/v1beta1/bank.d.ts +1 -1
  60. package/lib/codec/cosmos/bank/v1beta1/bank.js +1 -1
  61. package/lib/codec/cosmos/bank/v1beta1/genesis.d.ts +2 -2
  62. package/lib/codec/cosmos/bank/v1beta1/genesis.js +2 -2
  63. package/lib/codec/cosmos/bank/v1beta1/query.d.ts +3 -3
  64. package/lib/codec/cosmos/bank/v1beta1/query.js +3 -3
  65. package/lib/codec/cosmos/bank/v1beta1/tx.d.ts +2 -2
  66. package/lib/codec/cosmos/bank/v1beta1/tx.js +2 -2
  67. package/lib/codec/cosmos/base/tendermint/v1beta1/query.d.ts +1 -1
  68. package/lib/codec/cosmos/base/tendermint/v1beta1/query.js +1 -1
  69. package/lib/codec/cosmos/capability/v1beta1/genesis.d.ts +1 -1
  70. package/lib/codec/cosmos/capability/v1beta1/genesis.js +1 -1
  71. package/lib/codec/cosmos/crisis/v1beta1/genesis.d.ts +1 -1
  72. package/lib/codec/cosmos/crisis/v1beta1/genesis.js +1 -1
  73. package/lib/codec/cosmos/distribution/v1beta1/distribution.d.ts +1 -1
  74. package/lib/codec/cosmos/distribution/v1beta1/distribution.js +1 -1
  75. package/lib/codec/cosmos/distribution/v1beta1/genesis.d.ts +2 -2
  76. package/lib/codec/cosmos/distribution/v1beta1/genesis.js +2 -2
  77. package/lib/codec/cosmos/distribution/v1beta1/query.d.ts +3 -3
  78. package/lib/codec/cosmos/distribution/v1beta1/query.js +3 -3
  79. package/lib/codec/cosmos/distribution/v1beta1/tx.d.ts +1 -1
  80. package/lib/codec/cosmos/distribution/v1beta1/tx.js +1 -1
  81. package/lib/codec/cosmos/evidence/v1beta1/query.d.ts +1 -1
  82. package/lib/codec/cosmos/evidence/v1beta1/query.js +1 -1
  83. package/lib/codec/cosmos/feegrant/v1beta1/feegrant.d.ts +1 -1
  84. package/lib/codec/cosmos/feegrant/v1beta1/feegrant.js +1 -1
  85. package/lib/codec/cosmos/feegrant/v1beta1/genesis.d.ts +1 -1
  86. package/lib/codec/cosmos/feegrant/v1beta1/genesis.js +1 -1
  87. package/lib/codec/cosmos/feegrant/v1beta1/query.d.ts +2 -2
  88. package/lib/codec/cosmos/feegrant/v1beta1/query.js +2 -2
  89. package/lib/codec/cosmos/gov/v1beta1/genesis.d.ts +1 -1
  90. package/lib/codec/cosmos/gov/v1beta1/genesis.js +1 -1
  91. package/lib/codec/cosmos/gov/v1beta1/gov.d.ts +1 -1
  92. package/lib/codec/cosmos/gov/v1beta1/gov.js +1 -1
  93. package/lib/codec/cosmos/gov/v1beta1/query.d.ts +2 -2
  94. package/lib/codec/cosmos/gov/v1beta1/query.js +2 -2
  95. package/lib/codec/cosmos/gov/v1beta1/tx.d.ts +2 -2
  96. package/lib/codec/cosmos/gov/v1beta1/tx.js +2 -2
  97. package/lib/codec/cosmos/mint/v1beta1/genesis.d.ts +1 -1
  98. package/lib/codec/cosmos/mint/v1beta1/genesis.js +1 -1
  99. package/lib/codec/cosmos/mint/v1beta1/query.d.ts +1 -1
  100. package/lib/codec/cosmos/mint/v1beta1/query.js +1 -1
  101. package/lib/codec/cosmos/params/v1beta1/query.d.ts +1 -1
  102. package/lib/codec/cosmos/params/v1beta1/query.js +1 -1
  103. package/lib/codec/cosmos/slashing/v1beta1/genesis.d.ts +1 -1
  104. package/lib/codec/cosmos/slashing/v1beta1/genesis.js +1 -1
  105. package/lib/codec/cosmos/slashing/v1beta1/query.d.ts +2 -2
  106. package/lib/codec/cosmos/slashing/v1beta1/query.js +2 -2
  107. package/lib/codec/cosmos/staking/v1beta1/authz.d.ts +1 -1
  108. package/lib/codec/cosmos/staking/v1beta1/authz.js +1 -1
  109. package/lib/codec/cosmos/staking/v1beta1/genesis.d.ts +1 -1
  110. package/lib/codec/cosmos/staking/v1beta1/genesis.js +1 -1
  111. package/lib/codec/cosmos/staking/v1beta1/query.d.ts +2 -2
  112. package/lib/codec/cosmos/staking/v1beta1/query.js +2 -2
  113. package/lib/codec/cosmos/staking/v1beta1/staking.d.ts +1 -1
  114. package/lib/codec/cosmos/staking/v1beta1/staking.js +1 -1
  115. package/lib/codec/cosmos/staking/v1beta1/tx.d.ts +2 -2
  116. package/lib/codec/cosmos/staking/v1beta1/tx.js +2 -2
  117. package/lib/codec/cosmos/tx/signing/v1beta1/signing.d.ts +1 -1
  118. package/lib/codec/cosmos/tx/signing/v1beta1/signing.js +1 -1
  119. package/lib/codec/cosmos/tx/v1beta1/service.d.ts +3 -3
  120. package/lib/codec/cosmos/tx/v1beta1/service.js +3 -3
  121. package/lib/codec/cosmos/tx/v1beta1/tx.d.ts +3 -3
  122. package/lib/codec/cosmos/tx/v1beta1/tx.js +3 -3
  123. package/lib/codec/cosmos/upgrade/v1beta1/query.d.ts +1 -1
  124. package/lib/codec/cosmos/upgrade/v1beta1/query.js +1 -1
  125. package/lib/codec/cosmos/vesting/v1beta1/tx.d.ts +1 -1
  126. package/lib/codec/cosmos/vesting/v1beta1/tx.js +1 -1
  127. package/lib/codec/cosmos/vesting/v1beta1/vesting.d.ts +2 -2
  128. package/lib/codec/cosmos/vesting/v1beta1/vesting.js +2 -2
  129. package/lib/codec/fee/genesis.d.ts +1 -1
  130. package/lib/codec/fee/genesis.js +1 -1
  131. package/lib/codec/fee/proposal.d.ts +1 -1
  132. package/lib/codec/fee/proposal.js +1 -1
  133. package/lib/codec/fee/query.d.ts +1 -1
  134. package/lib/codec/fee/query.js +1 -1
  135. package/lib/codec/fee/tx.d.ts +1 -1
  136. package/lib/codec/fee/tx.js +1 -1
  137. package/lib/codec/headersync/genesis.d.ts +1 -1
  138. package/lib/codec/headersync/genesis.js +1 -1
  139. package/lib/codec/headersync/query.d.ts +1 -1
  140. package/lib/codec/headersync/query.js +1 -1
  141. package/lib/codec/index.d.ts +89 -18
  142. package/lib/codec/index.js +463 -180
  143. package/lib/codec/inflation/genesis.d.ts +1 -1
  144. package/lib/codec/inflation/genesis.js +1 -1
  145. package/lib/codec/inflation/query.d.ts +1 -1
  146. package/lib/codec/inflation/query.js +1 -1
  147. package/lib/codec/insurance/genesis.d.ts +1 -1
  148. package/lib/codec/insurance/genesis.js +1 -1
  149. package/lib/codec/leverage/genesis.d.ts +1 -1
  150. package/lib/codec/leverage/genesis.js +1 -1
  151. package/lib/codec/leverage/query.d.ts +1 -1
  152. package/lib/codec/leverage/query.js +1 -1
  153. package/lib/codec/liquidation/genesis.d.ts +1 -1
  154. package/lib/codec/liquidation/genesis.js +1 -1
  155. package/lib/codec/liquidation/query.d.ts +1 -1
  156. package/lib/codec/liquidation/query.js +1 -1
  157. package/lib/codec/liquidation/quote_changes.d.ts +1 -1
  158. package/lib/codec/liquidation/quote_changes.js +1 -1
  159. package/lib/codec/liquiditypool/event.d.ts +2 -2
  160. package/lib/codec/liquiditypool/event.js +2 -2
  161. package/lib/codec/liquiditypool/genesis.d.ts +2 -2
  162. package/lib/codec/liquiditypool/genesis.js +2 -2
  163. package/lib/codec/liquiditypool/liquiditypool.d.ts +3 -0
  164. package/lib/codec/liquiditypool/liquiditypool.js +44 -1
  165. package/lib/codec/liquiditypool/proposal.d.ts +1 -1
  166. package/lib/codec/liquiditypool/proposal.js +1 -1
  167. package/lib/codec/liquiditypool/query.d.ts +39 -2
  168. package/lib/codec/liquiditypool/query.js +195 -3
  169. package/lib/codec/liquiditypool/tx.d.ts +3 -1
  170. package/lib/codec/liquiditypool/tx.js +35 -1
  171. package/lib/codec/lockproxy/genesis.d.ts +1 -1
  172. package/lib/codec/lockproxy/genesis.js +1 -1
  173. package/lib/codec/lockproxy/query.d.ts +1 -1
  174. package/lib/codec/lockproxy/query.js +1 -1
  175. package/lib/codec/market/event.d.ts +1 -1
  176. package/lib/codec/market/event.js +1 -1
  177. package/lib/codec/market/genesis.d.ts +1 -1
  178. package/lib/codec/market/genesis.js +1 -1
  179. package/lib/codec/market/proposal.d.ts +1 -1
  180. package/lib/codec/market/proposal.js +1 -1
  181. package/lib/codec/market/query.d.ts +1 -1
  182. package/lib/codec/market/query.js +1 -1
  183. package/lib/codec/market/tx.d.ts +1 -1
  184. package/lib/codec/market/tx.js +1 -1
  185. package/lib/codec/marketstats/genesis.d.ts +1 -1
  186. package/lib/codec/marketstats/genesis.js +1 -1
  187. package/lib/codec/marketstats/query.d.ts +2 -2
  188. package/lib/codec/marketstats/query.js +2 -2
  189. package/lib/codec/misc/message.d.ts +1 -1
  190. package/lib/codec/misc/message.js +1 -1
  191. package/lib/codec/misc/query.d.ts +3 -3
  192. package/lib/codec/misc/query.js +3 -3
  193. package/lib/codec/misc/transaction.d.ts +1 -1
  194. package/lib/codec/misc/transaction.js +1 -1
  195. package/lib/codec/oracle/event.d.ts +1 -1
  196. package/lib/codec/oracle/event.js +1 -1
  197. package/lib/codec/oracle/genesis.d.ts +4 -1
  198. package/lib/codec/oracle/genesis.js +34 -3
  199. package/lib/codec/oracle/proposal.d.ts +1 -1
  200. package/lib/codec/oracle/proposal.js +1 -1
  201. package/lib/codec/oracle/query.d.ts +2 -2
  202. package/lib/codec/oracle/query.js +2 -2
  203. package/lib/codec/order/event.d.ts +1 -1
  204. package/lib/codec/order/event.js +1 -1
  205. package/lib/codec/order/genesis.d.ts +1 -1
  206. package/lib/codec/order/genesis.js +1 -1
  207. package/lib/codec/order/query.d.ts +1 -1
  208. package/lib/codec/order/query.js +1 -1
  209. package/lib/codec/position/event.d.ts +1 -1
  210. package/lib/codec/position/event.js +1 -1
  211. package/lib/codec/position/genesis.d.ts +1 -1
  212. package/lib/codec/position/genesis.js +1 -1
  213. package/lib/codec/position/query.d.ts +1 -1
  214. package/lib/codec/position/query.js +1 -1
  215. package/lib/codec/pricing/event.d.ts +56 -1
  216. package/lib/codec/pricing/event.js +298 -2
  217. package/lib/codec/pricing/genesis.d.ts +2 -1
  218. package/lib/codec/pricing/genesis.js +20 -5
  219. package/lib/codec/pricing/legacy.d.ts +22 -0
  220. package/lib/codec/pricing/legacy.js +93 -0
  221. package/lib/codec/pricing/pricing.d.ts +14 -0
  222. package/lib/codec/pricing/pricing.js +103 -1
  223. package/lib/codec/pricing/query.d.ts +68 -1
  224. package/lib/codec/pricing/query.js +321 -2
  225. package/lib/codec/pricing/tx.d.ts +96 -0
  226. package/lib/codec/pricing/tx.js +399 -1
  227. package/lib/codec/profile/event.d.ts +1 -1
  228. package/lib/codec/profile/event.js +1 -1
  229. package/lib/codec/profile/genesis.d.ts +1 -1
  230. package/lib/codec/profile/genesis.js +1 -1
  231. package/lib/codec/profile/query.d.ts +1 -1
  232. package/lib/codec/profile/query.js +1 -1
  233. package/lib/codec/subaccount/genesis.d.ts +1 -1
  234. package/lib/codec/subaccount/genesis.js +1 -1
  235. package/lib/codec/subaccount/query.d.ts +1 -1
  236. package/lib/codec/subaccount/query.js +1 -1
  237. package/lib/codec/tendermint/abci/types.d.ts +4 -4
  238. package/lib/codec/tendermint/abci/types.js +4 -4
  239. package/lib/codec/tendermint/types/block.d.ts +2 -2
  240. package/lib/codec/tendermint/types/block.js +2 -2
  241. package/lib/codec/tendermint/types/evidence.d.ts +2 -2
  242. package/lib/codec/tendermint/types/evidence.js +2 -2
  243. package/lib/codec/tendermint/types/types.d.ts +3 -3
  244. package/lib/codec/tendermint/types/types.js +3 -3
  245. package/lib/codec/tendermint/types/validator.d.ts +1 -1
  246. package/lib/codec/tendermint/types/validator.js +1 -1
  247. package/lib/constant/network.js +1 -1
  248. package/lib/constant/token.d.ts +4 -0
  249. package/lib/constant/token.js +5 -1
  250. package/lib/modules/admin.d.ts +114 -7
  251. package/lib/modules/admin.js +275 -53
  252. package/lib/modules/cdp.d.ts +152 -13
  253. package/lib/modules/cdp.js +796 -20
  254. package/lib/modules/liquiditypool.d.ts +2 -0
  255. package/lib/modules/liquiditypool.js +2 -0
  256. package/lib/provider/amino/types/admin.js +72 -7
  257. package/lib/provider/amino/types/cdp.js +102 -32
  258. package/lib/provider/amino/types/liquidityPool.js +2 -0
  259. package/lib/provider/keplr/KeplrAccount.js +5 -0
  260. package/lib/util/address.d.ts +1 -0
  261. package/lib/util/address.js +8 -0
  262. package/lib/util/number.d.ts +1 -0
  263. package/lib/util/number.js +2 -1
  264. package/lib/util/tx.d.ts +75 -10
  265. package/lib/wallet/CarbonSigner.d.ts +5 -2
  266. package/lib/wallet/CarbonSigner.js +13 -0
  267. package/lib/wallet/CarbonWallet.js +0 -1
  268. package/lib/websocket/channel.js +115 -21
  269. package/lib/websocket/models.d.ts +155 -0
  270. package/lib/websocket/types.d.ts +87 -3
  271. package/lib/websocket/types.js +31 -0
  272. package/package.json +1 -1
@@ -1,7 +1,7 @@
1
1
  import Long from "long";
2
2
  import _m0 from "protobufjs/minimal";
3
- import { Vote, LightBlock } from "../../tendermint/types/types";
4
- import { Validator } from "../../tendermint/types/validator";
3
+ import { Vote, LightBlock } from "./types";
4
+ import { Validator } from "./validator";
5
5
  export declare const protobufPackage = "tendermint.types";
6
6
  export interface Evidence {
7
7
  duplicateVoteEvidence?: DuplicateVoteEvidence | undefined;
@@ -7,9 +7,9 @@ exports.EvidenceList = exports.LightClientAttackEvidence = exports.DuplicateVote
7
7
  /* eslint-disable */
8
8
  const long_1 = __importDefault(require("long"));
9
9
  const minimal_1 = __importDefault(require("protobufjs/minimal"));
10
- const types_1 = require("../../tendermint/types/types");
10
+ const types_1 = require("./types");
11
11
  const timestamp_1 = require("../../google/protobuf/timestamp");
12
- const validator_1 = require("../../tendermint/types/validator");
12
+ const validator_1 = require("./validator");
13
13
  exports.protobufPackage = "tendermint.types";
14
14
  const baseEvidence = {};
15
15
  exports.Evidence = {
@@ -1,8 +1,8 @@
1
1
  import Long from "long";
2
2
  import _m0 from "protobufjs/minimal";
3
- import { Proof } from "../../tendermint/crypto/proof";
4
- import { Consensus } from "../../tendermint/version/types";
5
- import { ValidatorSet } from "../../tendermint/types/validator";
3
+ import { Proof } from "../crypto/proof";
4
+ import { Consensus } from "../version/types";
5
+ import { ValidatorSet } from "./validator";
6
6
  export declare const protobufPackage = "tendermint.types";
7
7
  /** BlockIdFlag indicates which BlcokID the signature is for */
8
8
  export declare enum BlockIDFlag {
@@ -7,9 +7,9 @@ exports.TxProof = exports.BlockMeta = exports.LightBlock = exports.SignedHeader
7
7
  /* eslint-disable */
8
8
  const long_1 = __importDefault(require("long"));
9
9
  const minimal_1 = __importDefault(require("protobufjs/minimal"));
10
- const proof_1 = require("../../tendermint/crypto/proof");
11
- const types_1 = require("../../tendermint/version/types");
12
- const validator_1 = require("../../tendermint/types/validator");
10
+ const proof_1 = require("../crypto/proof");
11
+ const types_1 = require("../version/types");
12
+ const validator_1 = require("./validator");
13
13
  const timestamp_1 = require("../../google/protobuf/timestamp");
14
14
  exports.protobufPackage = "tendermint.types";
15
15
  /** BlockIdFlag indicates which BlcokID the signature is for */
@@ -1,6 +1,6 @@
1
1
  import Long from "long";
2
2
  import _m0 from "protobufjs/minimal";
3
- import { PublicKey } from "../../tendermint/crypto/keys";
3
+ import { PublicKey } from "../crypto/keys";
4
4
  export declare const protobufPackage = "tendermint.types";
5
5
  export interface ValidatorSet {
6
6
  validators: Validator[];
@@ -7,7 +7,7 @@ exports.SimpleValidator = exports.Validator = exports.ValidatorSet = exports.pro
7
7
  /* eslint-disable */
8
8
  const long_1 = __importDefault(require("long"));
9
9
  const minimal_1 = __importDefault(require("protobufjs/minimal"));
10
- const keys_1 = require("../../tendermint/crypto/keys");
10
+ const keys_1 = require("../crypto/keys");
11
11
  exports.protobufPackage = "tendermint.types";
12
12
  const baseValidatorSet = { totalVotingPower: long_1.default.ZERO };
13
13
  exports.ValidatorSet = {
@@ -45,7 +45,7 @@ exports.NetworkConfigs = {
45
45
  byteCodeHash: "0x1b147c1cef546fcbcc1284df778073d65b90f80d5b649a69d5f8a01e186c0ec1",
46
46
  },
47
47
  neo: {
48
- rpcURL: "http://seed5.ngd.network:10332",
48
+ rpcURL: "https://mainnet2.neo2.coz.io:443",
49
49
  wrapperScriptHash: "f46719e2d16bf50cddcef9d4bbfece901f73cbb6",
50
50
  },
51
51
  n3: {
@@ -1,4 +1,8 @@
1
1
  import { OptionalNetworkMap, SimpleMap } from "../util/type";
2
+ export declare const DenomPrefix: {
3
+ LPToken: string;
4
+ CDPToken: string;
5
+ };
2
6
  export declare const CommonAssetName: SimpleMap<string>;
3
7
  export declare const CoinGeckoTokenNames: SimpleMap<string>;
4
8
  export declare const TokenBlacklist: OptionalNetworkMap<string[]>;
@@ -1,7 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.TokenBlacklist = exports.CoinGeckoTokenNames = exports.CommonAssetName = void 0;
3
+ exports.TokenBlacklist = exports.CoinGeckoTokenNames = exports.CommonAssetName = exports.DenomPrefix = void 0;
4
4
  const network_1 = require("./network");
5
+ exports.DenomPrefix = {
6
+ LPToken: "clpt",
7
+ CDPToken: "cibt",
8
+ };
5
9
  exports.CommonAssetName = {
6
10
  swth: 'swth',
7
11
  'swth-n': 'swth',
@@ -1,6 +1,7 @@
1
1
  import { Any, SettlementPriceParams } from "../codec";
2
2
  import { Coin } from "../codec/cosmos/base/v1beta1/coin";
3
3
  import { Description } from "../codec/cosmos/staking/v1beta1/staking";
4
+ import { CarbonWallet } from "../wallet";
4
5
  import { CarbonTx } from "../util";
5
6
  import BigNumber from "bignumber.js";
6
7
  import Long from "long";
@@ -16,7 +17,6 @@ export declare class AdminModule extends BaseModule {
16
17
  linkToken(params: AdminModule.LinkTokenParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
17
18
  createMarket(params: AdminModule.CreateMarketParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
18
19
  createMarkets(params: AdminModule.CreateMarketParams[], opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
19
- createVaultType(params: AdminModule.CreateVaultTypeParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
20
20
  linkPool(params: AdminModule.LinkPoolParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
21
21
  unlinkPool(params: AdminModule.UnlinkPoolParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
22
22
  setRewardsWeights(params: AdminModule.SetRewardsWeightsParams[], opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
@@ -33,6 +33,19 @@ export declare class AdminModule extends BaseModule {
33
33
  editValidator(params: AdminModule.EditValidatorParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
34
34
  authorizeBridge(params: AdminModule.AuthorizeBridgeParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
35
35
  deauthorizeBridge(params: AdminModule.DeauthorizeBridgeParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
36
+ addRateStrategy(params: AdminModule.AddRateStrategyParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
37
+ updateRateStrategy(params: AdminModule.UpdateRateStrategyParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
38
+ removeRateStrategy(params: AdminModule.RemoveRateStrategyParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
39
+ addAsset(params: AdminModule.AddAssetParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
40
+ updateAsset(params: AdminModule.UpdateAssetParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
41
+ setLiquidationFee(params: AdminModule.SetLiquidationFeeParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
42
+ setInterestFee(params: AdminModule.SetInterestFeeParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
43
+ setStableCoinInterestRate(params: AdminModule.SetStableCoinInterestRateParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
44
+ setCompleteLiquidationThreshold(params: AdminModule.SetCompleteLiquidationThresholdParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
45
+ setMinimumCloseFactor(params: AdminModule.SetMinimumCloseFactorParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
46
+ setSmallLiquidationSize(params: AdminModule.SetSmallLiquidationSizeParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
47
+ createRewardScheme(params: AdminModule.CreateRewardSchemeParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
48
+ updateRewardScheme(params: AdminModule.UpdateRewardSchemeParams, opts?: CarbonTx.SignTxOpts): Promise<import("@cosmjs/stargate").DeliverTxResponse>;
36
49
  }
37
50
  export declare namespace AdminModule {
38
51
  interface AuthorizeBridgeParams {
@@ -181,6 +194,83 @@ export declare namespace AdminModule {
181
194
  commissionRate: BigNumber;
182
195
  minSelfDelegation: BigNumber;
183
196
  }
197
+ interface RateStrategy {
198
+ name: string;
199
+ optimalUsage: BigNumber;
200
+ baseVariableBorrowRate: BigNumber;
201
+ variableRateSlope1: BigNumber;
202
+ variableRateSlope2: BigNumber;
203
+ baseStableBorrowRate: BigNumber;
204
+ stableRateSlope1: BigNumber;
205
+ stableRateSlope2: BigNumber;
206
+ optimalStableToTotalDebtRatio: BigNumber;
207
+ }
208
+ interface Asset {
209
+ denom: string;
210
+ oracleId: string;
211
+ rateStrategyName: string;
212
+ loanToValue: BigNumber;
213
+ liquidationThreshold: BigNumber;
214
+ liquidationDiscount: BigNumber;
215
+ supplyCap: BigNumber;
216
+ borrowCap: BigNumber;
217
+ }
218
+ interface AddRateStrategyParams {
219
+ rateStrategy: RateStrategy;
220
+ }
221
+ interface UpdateRateStrategyParams {
222
+ rateStrategy: RateStrategy;
223
+ }
224
+ interface RemoveRateStrategyParams {
225
+ name: string;
226
+ }
227
+ interface AddAssetParams {
228
+ asset: Asset;
229
+ }
230
+ interface UpdateAssetParams {
231
+ asset: Asset;
232
+ }
233
+ interface SetLiquidationFeeParams {
234
+ liquidationFee: BigNumber;
235
+ }
236
+ interface SetInterestFeeParams {
237
+ interestFee: BigNumber;
238
+ }
239
+ interface SetStableCoinInterestRateParams {
240
+ stablecoinInterestRate: BigNumber;
241
+ }
242
+ interface SetCompleteLiquidationThresholdParams {
243
+ completeLiquidationThreshold: BigNumber;
244
+ }
245
+ interface SetMinimumCloseFactorParams {
246
+ minimumCloseFactor: BigNumber;
247
+ }
248
+ interface SetSmallLiquidationSizeParams {
249
+ smallLiquidationSize: BigNumber;
250
+ }
251
+ interface CreateRewardSchemeParams {
252
+ rewardDenom: string;
253
+ assetDenom: string;
254
+ rewardType: string;
255
+ rewardAmountPerSecond: BigNumber;
256
+ startTime?: Date;
257
+ endTime?: Date;
258
+ }
259
+ interface UpdateRewardSchemeParams {
260
+ rewardSchemeId: number;
261
+ rewardDenom?: string;
262
+ assetDenom?: string;
263
+ rewardType?: string;
264
+ rewardAmountPerSecond: BigNumber;
265
+ startTime?: Date;
266
+ endTime?: Date;
267
+ }
268
+ interface AddRewardReserveParams {
269
+ creator?: string;
270
+ rewardSchemeId: number;
271
+ amount: BigNumber;
272
+ denom: string;
273
+ }
184
274
  }
185
275
  export declare function transfromCreateOracleParams(msg: AdminModule.CreateOracleParams, address: string): {
186
276
  creator: string;
@@ -207,12 +297,6 @@ export declare function transfromSyncTokenParams(msg: AdminModule.SyncTokenParam
207
297
  syncer: string;
208
298
  denom: string;
209
299
  };
210
- export declare function transfromCreateVaultTypeParams(msg: AdminModule.CreateVaultTypeParams, address: string): {
211
- creator: string;
212
- collateralDenom: string;
213
- debtDenom: string;
214
- collateralizationRatio: string;
215
- };
216
300
  export declare function transfromLinkPoolParams(msg: AdminModule.LinkPoolParams): {
217
301
  poolId: Long.Long;
218
302
  market: string;
@@ -261,3 +345,26 @@ export declare function transformSetSettlementPriceParams(msg: SettlementPricePa
261
345
  settlementPrice: string;
262
346
  };
263
347
  export declare function transformCommunityPoolSpendAmount(amount: Coin[]): Coin[];
348
+ export declare function transformCreateRewardScheme(msg: AdminModule.CreateRewardSchemeParams): {
349
+ rewardDenom: string;
350
+ assetDenom: string;
351
+ rewardType: string;
352
+ rewardAmountPerSecond: string;
353
+ startTime: Date | undefined;
354
+ endTime: Date | undefined;
355
+ };
356
+ export declare function transformUpdateRewardScheme(msg: AdminModule.UpdateRewardSchemeParams): {
357
+ rewardSchemeId: Long.Long;
358
+ rewardDenom: string | undefined;
359
+ assetDenom: string | undefined;
360
+ rewardType: string | undefined;
361
+ rewardAmountPerSecond: string;
362
+ startTime: Date | undefined;
363
+ endTime: Date | undefined;
364
+ };
365
+ export declare function transformAddRewardReserve(msg: AdminModule.AddRewardReserveParams, wallet: CarbonWallet): {
366
+ creator: string;
367
+ rewardSchemeId: Long.Long;
368
+ amount: string;
369
+ denom: string;
370
+ };