@suilend/sdk 3.0.8 → 5.0.0

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 (73) hide show
  1. package/_generated/_dependencies/source/0x1/ascii/structs.d.ts +4 -4
  2. package/_generated/_dependencies/source/0x1/ascii/structs.js +42 -41
  3. package/_generated/_dependencies/source/0x1/option/structs.js +22 -26
  4. package/_generated/_dependencies/source/0x1/type-name/structs.d.ts +3 -3
  5. package/_generated/_dependencies/source/0x1/type-name/structs.js +21 -25
  6. package/_generated/_dependencies/source/0x2/bag/structs.d.ts +5 -5
  7. package/_generated/_dependencies/source/0x2/bag/structs.js +22 -25
  8. package/_generated/_dependencies/source/0x2/balance/structs.d.ts +4 -4
  9. package/_generated/_dependencies/source/0x2/balance/structs.js +42 -41
  10. package/_generated/_dependencies/source/0x2/object/structs.d.ts +5 -5
  11. package/_generated/_dependencies/source/0x2/object/structs.js +42 -41
  12. package/_generated/_dependencies/source/0x2/object-table/structs.d.ts +5 -5
  13. package/_generated/_dependencies/source/0x2/object-table/structs.js +22 -25
  14. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/i64/structs.d.ts +3 -3
  15. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/i64/structs.js +22 -25
  16. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price/structs.d.ts +9 -9
  17. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price/structs.js +24 -25
  18. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-feed/structs.d.ts +21 -21
  19. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-feed/structs.js +23 -25
  20. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-identifier/structs.d.ts +2 -2
  21. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-identifier/structs.js +21 -25
  22. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-info/structs.d.ts +52 -52
  23. package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-info/structs.js +45 -41
  24. package/_generated/_framework/vector.js +9 -6
  25. package/_generated/suilend/cell/structs.d.ts +1 -1
  26. package/_generated/suilend/cell/structs.js +21 -25
  27. package/_generated/suilend/decimal/structs.d.ts +2 -2
  28. package/_generated/suilend/decimal/structs.js +21 -25
  29. package/_generated/suilend/lending-market/structs.d.ts +129 -129
  30. package/_generated/suilend/lending-market/structs.js +391 -265
  31. package/_generated/suilend/liquidity-mining/structs.d.ts +44 -44
  32. package/_generated/suilend/liquidity-mining/structs.js +122 -89
  33. package/_generated/suilend/obligation/structs.d.ts +98 -98
  34. package/_generated/suilend/obligation/structs.js +194 -121
  35. package/_generated/suilend/rate-limiter/structs.d.ts +12 -12
  36. package/_generated/suilend/rate-limiter/structs.js +46 -41
  37. package/_generated/suilend/reserve/structs.d.ts +128 -128
  38. package/_generated/suilend/reserve/structs.js +243 -153
  39. package/_generated/suilend/reserve-config/structs.d.ts +30 -30
  40. package/_generated/suilend/reserve-config/structs.js +60 -41
  41. package/api/events.js +5 -14
  42. package/client.js +267 -319
  43. package/lib/initialize.d.ts +85 -3
  44. package/lib/initialize.js +119 -52
  45. package/lib/liquidityMining.js +15 -19
  46. package/lib/pyth.d.ts +16 -0
  47. package/lib/pyth.js +30 -15
  48. package/lib/pythAdapter.js +96 -112
  49. package/lib/strategyOwnerCap.js +8 -17
  50. package/margin/margin/admin_cap.d.ts +2 -2
  51. package/margin/margin/deps/std/type_name.d.ts +1 -1
  52. package/margin/margin/deps/suilend/lending_market.d.ts +2 -2
  53. package/margin/margin/market.d.ts +11 -11
  54. package/margin/margin/market.js +22 -22
  55. package/margin/margin/permissions.js +14 -14
  56. package/margin/margin/position.d.ts +47 -47
  57. package/margin/margin/position.js +10 -10
  58. package/margin/margin/router.d.ts +5 -5
  59. package/margin/margin/router.js +16 -16
  60. package/margin/margin/version.d.ts +1 -1
  61. package/margin/utils/index.js +22 -36
  62. package/package.json +1 -1
  63. package/parsers/apiReserveAssetDataEvent.js +4 -1
  64. package/parsers/lendingMarket.js +3 -4
  65. package/parsers/reserve.js +4 -1
  66. package/strategies.js +188 -204
  67. package/swap/quote.d.ts +1 -1
  68. package/swap/quote.js +28 -39
  69. package/swap/transaction.js +17 -26
  70. package/utils/events.js +20 -32
  71. package/utils/obligation.js +111 -135
  72. package/utils/simulate.d.ts +68 -1
  73. package/utils/simulate.js +149 -31
@@ -1,12 +1,3 @@
1
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
- return new (P || (P = Promise))(function (resolve, reject) {
4
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
- step((generator = generator.apply(thisArg, _arguments || [])).next());
8
- });
9
- };
10
1
  import { decodeFromFields, decodeFromFieldsWithTypes, decodeFromJSONField, phantom, } from "../../_framework/reified.js";
11
2
  import { composeSuiType, compressSuiType, } from "../../_framework/util.js";
12
3
  import { Decimal } from "../decimal/structs.js";
@@ -18,10 +9,19 @@ export function isRateLimiter(type) {
18
9
  return type === `${PKG_V1}::rate_limiter::RateLimiter`;
19
10
  }
20
11
  export class RateLimiter {
12
+ __StructClass = true;
13
+ static $typeName = `${PKG_V1}::rate_limiter::RateLimiter`;
14
+ static $numTypeParams = 0;
15
+ static $isPhantom = [];
16
+ $typeName = RateLimiter.$typeName;
17
+ $fullTypeName;
18
+ $typeArgs;
19
+ $isPhantom = RateLimiter.$isPhantom;
20
+ config;
21
+ prevQty;
22
+ windowStart;
23
+ curQty;
21
24
  constructor(typeArgs, fields) {
22
- this.__StructClass = true;
23
- this.$typeName = RateLimiter.$typeName;
24
- this.$isPhantom = RateLimiter.$isPhantom;
25
25
  this.$fullTypeName = composeSuiType(RateLimiter.$typeName, ...typeArgs);
26
26
  this.$typeArgs = typeArgs;
27
27
  this.config = fields.config;
@@ -42,7 +42,7 @@ export class RateLimiter {
42
42
  bcs: RateLimiter.bcs,
43
43
  fromJSONField: (field) => RateLimiter.fromJSONField(field),
44
44
  fromJSON: (json) => RateLimiter.fromJSON(json),
45
- fetch: (client, id) => __awaiter(this, void 0, void 0, function* () { return RateLimiter.fetch(client, id); }),
45
+ fetch: async (client, id) => RateLimiter.fetch(client, id),
46
46
  new: (fields) => {
47
47
  return new RateLimiter([], fields);
48
48
  },
@@ -97,7 +97,11 @@ export class RateLimiter {
97
97
  };
98
98
  }
99
99
  toJSON() {
100
- return Object.assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
100
+ return {
101
+ $typeName: this.$typeName,
102
+ $typeArgs: this.$typeArgs,
103
+ ...this.toJSONField(),
104
+ };
101
105
  }
102
106
  static fromJSONField(field) {
103
107
  return RateLimiter.reified().new({
@@ -113,29 +117,31 @@ export class RateLimiter {
113
117
  }
114
118
  return RateLimiter.fromJSONField(json);
115
119
  }
116
- static fetch(client, id) {
117
- return __awaiter(this, void 0, void 0, function* () {
118
- const { object } = yield client.getObject({ objectId: id, include: { content: true } });
119
- if (!isRateLimiter(object.type)) {
120
- throw new Error(`object at id ${id} is not a RateLimiter object`);
121
- }
122
- return RateLimiter.fromBcs(object.content);
123
- });
120
+ static async fetch(client, id) {
121
+ const { object } = await client.getObject({ objectId: id, include: { content: true } });
122
+ if (!isRateLimiter(object.type)) {
123
+ throw new Error(`object at id ${id} is not a RateLimiter object`);
124
+ }
125
+ return RateLimiter.fromBcs(object.content);
124
126
  }
125
127
  }
126
- RateLimiter.$typeName = `${PKG_V1}::rate_limiter::RateLimiter`;
127
- RateLimiter.$numTypeParams = 0;
128
- RateLimiter.$isPhantom = [];
129
128
  /* ============================== RateLimiterConfig =============================== */
130
129
  export function isRateLimiterConfig(type) {
131
130
  type = compressSuiType(type);
132
131
  return type === `${PKG_V1}::rate_limiter::RateLimiterConfig`;
133
132
  }
134
133
  export class RateLimiterConfig {
134
+ __StructClass = true;
135
+ static $typeName = `${PKG_V1}::rate_limiter::RateLimiterConfig`;
136
+ static $numTypeParams = 0;
137
+ static $isPhantom = [];
138
+ $typeName = RateLimiterConfig.$typeName;
139
+ $fullTypeName;
140
+ $typeArgs;
141
+ $isPhantom = RateLimiterConfig.$isPhantom;
142
+ windowDuration;
143
+ maxOutflow;
135
144
  constructor(typeArgs, fields) {
136
- this.__StructClass = true;
137
- this.$typeName = RateLimiterConfig.$typeName;
138
- this.$isPhantom = RateLimiterConfig.$isPhantom;
139
145
  this.$fullTypeName = composeSuiType(RateLimiterConfig.$typeName, ...typeArgs);
140
146
  this.$typeArgs = typeArgs;
141
147
  this.windowDuration = fields.windowDuration;
@@ -154,7 +160,7 @@ export class RateLimiterConfig {
154
160
  bcs: RateLimiterConfig.bcs,
155
161
  fromJSONField: (field) => RateLimiterConfig.fromJSONField(field),
156
162
  fromJSON: (json) => RateLimiterConfig.fromJSON(json),
157
- fetch: (client, id) => __awaiter(this, void 0, void 0, function* () { return RateLimiterConfig.fetch(client, id); }),
163
+ fetch: async (client, id) => RateLimiterConfig.fetch(client, id),
158
164
  new: (fields) => {
159
165
  return new RateLimiterConfig([], fields);
160
166
  },
@@ -201,7 +207,11 @@ export class RateLimiterConfig {
201
207
  };
202
208
  }
203
209
  toJSON() {
204
- return Object.assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
210
+ return {
211
+ $typeName: this.$typeName,
212
+ $typeArgs: this.$typeArgs,
213
+ ...this.toJSONField(),
214
+ };
205
215
  }
206
216
  static fromJSONField(field) {
207
217
  return RateLimiterConfig.reified().new({
@@ -215,16 +225,11 @@ export class RateLimiterConfig {
215
225
  }
216
226
  return RateLimiterConfig.fromJSONField(json);
217
227
  }
218
- static fetch(client, id) {
219
- return __awaiter(this, void 0, void 0, function* () {
220
- const { object } = yield client.getObject({ objectId: id, include: { content: true } });
221
- if (!isRateLimiterConfig(object.type)) {
222
- throw new Error(`object at id ${id} is not a RateLimiterConfig object`);
223
- }
224
- return RateLimiterConfig.fromBcs(object.content);
225
- });
228
+ static async fetch(client, id) {
229
+ const { object } = await client.getObject({ objectId: id, include: { content: true } });
230
+ if (!isRateLimiterConfig(object.type)) {
231
+ throw new Error(`object at id ${id} is not a RateLimiterConfig object`);
232
+ }
233
+ return RateLimiterConfig.fromBcs(object.content);
226
234
  }
227
235
  }
228
- RateLimiterConfig.$typeName = `${PKG_V1}::rate_limiter::RateLimiterConfig`;
229
- RateLimiterConfig.$numTypeParams = 0;
230
- RateLimiterConfig.$isPhantom = [];
@@ -31,8 +31,8 @@ export declare class BalanceKey implements StructClass {
31
31
  static get r(): reified.StructClassReified<BalanceKey, BalanceKeyFields>;
32
32
  static phantom(): PhantomReified<ToTypeStr<BalanceKey>>;
33
33
  static get p(): reified.PhantomReified<"0x1f54a9a2d71799553197e9ea24557797c6398d6a65f2d4d3818c9304b75d5e21::reserve::BalanceKey" | "0xf95b06141ed4a174f239417323bde3f209b972f5930d8521ea38a52aff3a6ddf::reserve::BalanceKey">;
34
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
35
- dummy_field: import("@mysten/sui/bcs").BcsType<boolean, boolean, "bool">;
34
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
35
+ dummy_field: import("@mysten/bcs").BcsType<boolean, boolean, "bool">;
36
36
  }, string>;
37
37
  static fromFields(fields: Record<string, any>): BalanceKey;
38
38
  static fromFieldsWithTypes(item: FieldsWithTypes): BalanceKey;
@@ -77,21 +77,21 @@ export declare class Balances<P extends PhantomTypeArgument, T extends PhantomTy
77
77
  static get r(): typeof Balances.reified;
78
78
  static phantom<P extends PhantomReified<PhantomTypeArgument>, T extends PhantomReified<PhantomTypeArgument>>(P: P, T: T): PhantomReified<ToTypeStr<Balances<ToPhantomTypeArgument<P>, ToPhantomTypeArgument<T>>>>;
79
79
  static get p(): typeof Balances.phantom;
80
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
81
- available_amount: import("@mysten/sui/bcs").BcsStruct<{
82
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
80
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
81
+ available_amount: import("@mysten/bcs").BcsStruct<{
82
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
83
83
  }, string>;
84
- ctoken_supply: import("@mysten/sui/bcs").BcsStruct<{
85
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
84
+ ctoken_supply: import("@mysten/bcs").BcsStruct<{
85
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
86
86
  }, string>;
87
- fees: import("@mysten/sui/bcs").BcsStruct<{
88
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
87
+ fees: import("@mysten/bcs").BcsStruct<{
88
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
89
89
  }, string>;
90
- ctoken_fees: import("@mysten/sui/bcs").BcsStruct<{
91
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
90
+ ctoken_fees: import("@mysten/bcs").BcsStruct<{
91
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
92
92
  }, string>;
93
- deposited_ctokens: import("@mysten/sui/bcs").BcsStruct<{
94
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
93
+ deposited_ctokens: import("@mysten/bcs").BcsStruct<{
94
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
95
95
  }, string>;
96
96
  }, string>;
97
97
  static fromFields<P extends PhantomReified<PhantomTypeArgument>, T extends PhantomReified<PhantomTypeArgument>>(typeArgs: [P, T], fields: Record<string, any>): Balances<ToPhantomTypeArgument<P>, ToPhantomTypeArgument<T>>;
@@ -157,8 +157,8 @@ export declare class CToken<P extends PhantomTypeArgument, T extends PhantomType
157
157
  static get r(): typeof CToken.reified;
158
158
  static phantom<P extends PhantomReified<PhantomTypeArgument>, T extends PhantomReified<PhantomTypeArgument>>(P: P, T: T): PhantomReified<ToTypeStr<CToken<ToPhantomTypeArgument<P>, ToPhantomTypeArgument<T>>>>;
159
159
  static get p(): typeof CToken.phantom;
160
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
161
- dummy_field: import("@mysten/sui/bcs").BcsType<boolean, boolean, "bool">;
160
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
161
+ dummy_field: import("@mysten/bcs").BcsType<boolean, boolean, "bool">;
162
162
  }, string>;
163
163
  static fromFields<P extends PhantomReified<PhantomTypeArgument>, T extends PhantomReified<PhantomTypeArgument>>(typeArgs: [P, T], fields: Record<string, any>): CToken<ToPhantomTypeArgument<P>, ToPhantomTypeArgument<T>>;
164
164
  static fromFieldsWithTypes<P extends PhantomReified<PhantomTypeArgument>, T extends PhantomReified<PhantomTypeArgument>>(typeArgs: [P, T], item: FieldsWithTypes): CToken<ToPhantomTypeArgument<P>, ToPhantomTypeArgument<T>>;
@@ -201,17 +201,17 @@ export declare class ClaimStakingRewardsEvent implements StructClass {
201
201
  static get r(): reified.StructClassReified<ClaimStakingRewardsEvent, ClaimStakingRewardsEventFields>;
202
202
  static phantom(): PhantomReified<ToTypeStr<ClaimStakingRewardsEvent>>;
203
203
  static get p(): reified.PhantomReified<"0xe5ed361add4433f4d23e56fc0e3bacab39b93592d5e65d508e33fd19ff696669::reserve::ClaimStakingRewardsEvent" | "0x5b54b47971238403d6ade3c8c2cc75814cb55145a5184af916bb5b12aaf184cb::reserve::ClaimStakingRewardsEvent">;
204
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
205
- lending_market_id: import("@mysten/sui/bcs").BcsType<string, string, string>;
206
- coin_type: import("@mysten/sui/bcs").BcsStruct<{
207
- name: import("@mysten/sui/bcs").BcsStruct<{
208
- bytes: import("@mysten/sui/bcs").BcsType<number[], Iterable<number> & {
204
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
205
+ lending_market_id: import("@mysten/bcs").BcsType<string, string, string>;
206
+ coin_type: import("@mysten/bcs").BcsStruct<{
207
+ name: import("@mysten/bcs").BcsStruct<{
208
+ bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
209
209
  length: number;
210
210
  }, string>;
211
211
  }, string>;
212
212
  }, string>;
213
- reserve_id: import("@mysten/sui/bcs").BcsType<string, string, string>;
214
- amount: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
213
+ reserve_id: import("@mysten/bcs").BcsType<string, string, string>;
214
+ amount: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
215
215
  }, string>;
216
216
  static fromFields(fields: Record<string, any>): ClaimStakingRewardsEvent;
217
217
  static fromFieldsWithTypes(item: FieldsWithTypes): ClaimStakingRewardsEvent;
@@ -284,44 +284,44 @@ export declare class InterestUpdateEvent implements StructClass {
284
284
  static get r(): reified.StructClassReified<InterestUpdateEvent, InterestUpdateEventFields>;
285
285
  static phantom(): PhantomReified<ToTypeStr<InterestUpdateEvent>>;
286
286
  static get p(): reified.PhantomReified<"0x1f54a9a2d71799553197e9ea24557797c6398d6a65f2d4d3818c9304b75d5e21::reserve::InterestUpdateEvent" | "0xf95b06141ed4a174f239417323bde3f209b972f5930d8521ea38a52aff3a6ddf::reserve::InterestUpdateEvent">;
287
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
288
- lending_market_id: import("@mysten/sui/bcs").BcsType<string, string, string>;
289
- coin_type: import("@mysten/sui/bcs").BcsStruct<{
290
- name: import("@mysten/sui/bcs").BcsStruct<{
291
- bytes: import("@mysten/sui/bcs").BcsType<number[], Iterable<number> & {
287
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
288
+ lending_market_id: import("@mysten/bcs").BcsType<string, string, string>;
289
+ coin_type: import("@mysten/bcs").BcsStruct<{
290
+ name: import("@mysten/bcs").BcsStruct<{
291
+ bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
292
292
  length: number;
293
293
  }, string>;
294
294
  }, string>;
295
295
  }, string>;
296
- reserve_id: import("@mysten/sui/bcs").BcsType<string, string, string>;
297
- cumulative_borrow_rate: import("@mysten/sui/bcs").BcsStruct<{
298
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
296
+ reserve_id: import("@mysten/bcs").BcsType<string, string, string>;
297
+ cumulative_borrow_rate: import("@mysten/bcs").BcsStruct<{
298
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
299
299
  }, string>;
300
- available_amount: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
301
- borrowed_amount: import("@mysten/sui/bcs").BcsStruct<{
302
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
300
+ available_amount: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
301
+ borrowed_amount: import("@mysten/bcs").BcsStruct<{
302
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
303
303
  }, string>;
304
- unclaimed_spread_fees: import("@mysten/sui/bcs").BcsStruct<{
305
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
304
+ unclaimed_spread_fees: import("@mysten/bcs").BcsStruct<{
305
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
306
306
  }, string>;
307
- ctoken_supply: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
308
- borrow_interest_paid: import("@mysten/sui/bcs").BcsStruct<{
309
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
307
+ ctoken_supply: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
308
+ borrow_interest_paid: import("@mysten/bcs").BcsStruct<{
309
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
310
310
  }, string>;
311
- spread_fee: import("@mysten/sui/bcs").BcsStruct<{
312
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
311
+ spread_fee: import("@mysten/bcs").BcsStruct<{
312
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
313
313
  }, string>;
314
- supply_interest_earned: import("@mysten/sui/bcs").BcsStruct<{
315
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
314
+ supply_interest_earned: import("@mysten/bcs").BcsStruct<{
315
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
316
316
  }, string>;
317
- borrow_interest_paid_usd_estimate: import("@mysten/sui/bcs").BcsStruct<{
318
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
317
+ borrow_interest_paid_usd_estimate: import("@mysten/bcs").BcsStruct<{
318
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
319
319
  }, string>;
320
- protocol_fee_usd_estimate: import("@mysten/sui/bcs").BcsStruct<{
321
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
320
+ protocol_fee_usd_estimate: import("@mysten/bcs").BcsStruct<{
321
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
322
322
  }, string>;
323
- supply_interest_earned_usd_estimate: import("@mysten/sui/bcs").BcsStruct<{
324
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
323
+ supply_interest_earned_usd_estimate: import("@mysten/bcs").BcsStruct<{
324
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
325
325
  }, string>;
326
326
  }, string>;
327
327
  static fromFields(fields: Record<string, any>): InterestUpdateEvent;
@@ -427,9 +427,9 @@ export declare class LiquidityRequest<P extends PhantomTypeArgument, T extends P
427
427
  static get r(): typeof LiquidityRequest.reified;
428
428
  static phantom<P extends PhantomReified<PhantomTypeArgument>, T extends PhantomReified<PhantomTypeArgument>>(P: P, T: T): PhantomReified<ToTypeStr<LiquidityRequest<ToPhantomTypeArgument<P>, ToPhantomTypeArgument<T>>>>;
429
429
  static get p(): typeof LiquidityRequest.phantom;
430
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
431
- amount: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
432
- fee: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
430
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
431
+ amount: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
432
+ fee: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
433
433
  }, string>;
434
434
  static fromFields<P extends PhantomReified<PhantomTypeArgument>, T extends PhantomReified<PhantomTypeArgument>>(typeArgs: [P, T], fields: Record<string, any>): LiquidityRequest<ToPhantomTypeArgument<P>, ToPhantomTypeArgument<T>>;
435
435
  static fromFieldsWithTypes<P extends PhantomReified<PhantomTypeArgument>, T extends PhantomReified<PhantomTypeArgument>>(typeArgs: [P, T], item: FieldsWithTypes): LiquidityRequest<ToPhantomTypeArgument<P>, ToPhantomTypeArgument<T>>;
@@ -504,77 +504,77 @@ export declare class Reserve<P extends PhantomTypeArgument> implements StructCla
504
504
  static get r(): typeof Reserve.reified;
505
505
  static phantom<P extends PhantomReified<PhantomTypeArgument>>(P: P): PhantomReified<ToTypeStr<Reserve<ToPhantomTypeArgument<P>>>>;
506
506
  static get p(): typeof Reserve.phantom;
507
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
508
- id: import("@mysten/sui/bcs").BcsStruct<{
509
- id: import("@mysten/sui/bcs").BcsStruct<{
510
- bytes: import("@mysten/sui/bcs").BcsType<string, string, string>;
507
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
508
+ id: import("@mysten/bcs").BcsStruct<{
509
+ id: import("@mysten/bcs").BcsStruct<{
510
+ bytes: import("@mysten/bcs").BcsType<string, string, string>;
511
511
  }, string>;
512
512
  }, string>;
513
- lending_market_id: import("@mysten/sui/bcs").BcsStruct<{
514
- bytes: import("@mysten/sui/bcs").BcsType<string, string, string>;
513
+ lending_market_id: import("@mysten/bcs").BcsStruct<{
514
+ bytes: import("@mysten/bcs").BcsType<string, string, string>;
515
515
  }, string>;
516
- array_index: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
517
- coin_type: import("@mysten/sui/bcs").BcsStruct<{
518
- name: import("@mysten/sui/bcs").BcsStruct<{
519
- bytes: import("@mysten/sui/bcs").BcsType<number[], Iterable<number> & {
516
+ array_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
517
+ coin_type: import("@mysten/bcs").BcsStruct<{
518
+ name: import("@mysten/bcs").BcsStruct<{
519
+ bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
520
520
  length: number;
521
521
  }, string>;
522
522
  }, string>;
523
523
  }, string>;
524
- config: import("@mysten/sui/bcs").BcsStruct<{
525
- element: import("@mysten/sui/bcs").BcsType<any, any, string>;
524
+ config: import("@mysten/bcs").BcsStruct<{
525
+ element: import("@mysten/bcs").BcsType<any, any, string>;
526
526
  }, string>;
527
- mint_decimals: import("@mysten/sui/bcs").BcsType<number, number, "u8">;
528
- price_identifier: import("@mysten/sui/bcs").BcsStruct<{
529
- bytes: import("@mysten/sui/bcs").BcsType<number[], Iterable<number> & {
527
+ mint_decimals: import("@mysten/bcs").BcsType<number, number, "u8">;
528
+ price_identifier: import("@mysten/bcs").BcsStruct<{
529
+ bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
530
530
  length: number;
531
531
  }, string>;
532
532
  }, string>;
533
- price: import("@mysten/sui/bcs").BcsStruct<{
534
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
533
+ price: import("@mysten/bcs").BcsStruct<{
534
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
535
535
  }, string>;
536
- smoothed_price: import("@mysten/sui/bcs").BcsStruct<{
537
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
536
+ smoothed_price: import("@mysten/bcs").BcsStruct<{
537
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
538
538
  }, string>;
539
- price_last_update_timestamp_s: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
540
- available_amount: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
541
- ctoken_supply: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
542
- borrowed_amount: import("@mysten/sui/bcs").BcsStruct<{
543
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
539
+ price_last_update_timestamp_s: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
540
+ available_amount: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
541
+ ctoken_supply: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
542
+ borrowed_amount: import("@mysten/bcs").BcsStruct<{
543
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
544
544
  }, string>;
545
- cumulative_borrow_rate: import("@mysten/sui/bcs").BcsStruct<{
546
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
545
+ cumulative_borrow_rate: import("@mysten/bcs").BcsStruct<{
546
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
547
547
  }, string>;
548
- interest_last_update_timestamp_s: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
549
- unclaimed_spread_fees: import("@mysten/sui/bcs").BcsStruct<{
550
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
548
+ interest_last_update_timestamp_s: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
549
+ unclaimed_spread_fees: import("@mysten/bcs").BcsStruct<{
550
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
551
551
  }, string>;
552
- attributed_borrow_value: import("@mysten/sui/bcs").BcsStruct<{
553
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
552
+ attributed_borrow_value: import("@mysten/bcs").BcsStruct<{
553
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
554
554
  }, string>;
555
- deposits_pool_reward_manager: import("@mysten/sui/bcs").BcsStruct<{
556
- id: import("@mysten/sui/bcs").BcsStruct<{
557
- id: import("@mysten/sui/bcs").BcsStruct<{
558
- bytes: import("@mysten/sui/bcs").BcsType<string, string, string>;
555
+ deposits_pool_reward_manager: import("@mysten/bcs").BcsStruct<{
556
+ id: import("@mysten/bcs").BcsStruct<{
557
+ id: import("@mysten/bcs").BcsStruct<{
558
+ bytes: import("@mysten/bcs").BcsType<string, string, string>;
559
559
  }, string>;
560
560
  }, string>;
561
- total_shares: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
562
- pool_rewards: import("@mysten/sui/bcs").BcsType<any[], Iterable<any> & {
561
+ total_shares: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
562
+ pool_rewards: import("@mysten/bcs").BcsType<any[], Iterable<any> & {
563
563
  length: number;
564
564
  }, string>;
565
- last_update_time_ms: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
565
+ last_update_time_ms: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
566
566
  }, string>;
567
- borrows_pool_reward_manager: import("@mysten/sui/bcs").BcsStruct<{
568
- id: import("@mysten/sui/bcs").BcsStruct<{
569
- id: import("@mysten/sui/bcs").BcsStruct<{
570
- bytes: import("@mysten/sui/bcs").BcsType<string, string, string>;
567
+ borrows_pool_reward_manager: import("@mysten/bcs").BcsStruct<{
568
+ id: import("@mysten/bcs").BcsStruct<{
569
+ id: import("@mysten/bcs").BcsStruct<{
570
+ bytes: import("@mysten/bcs").BcsType<string, string, string>;
571
571
  }, string>;
572
572
  }, string>;
573
- total_shares: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
574
- pool_rewards: import("@mysten/sui/bcs").BcsType<any[], Iterable<any> & {
573
+ total_shares: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
574
+ pool_rewards: import("@mysten/bcs").BcsType<any[], Iterable<any> & {
575
575
  length: number;
576
576
  }, string>;
577
- last_update_time_ms: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
577
+ last_update_time_ms: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
578
578
  }, string>;
579
579
  }, string>;
580
580
  static fromFields<P extends PhantomReified<PhantomTypeArgument>>(typeArg: P, fields: Record<string, any>): Reserve<ToPhantomTypeArgument<P>>;
@@ -860,51 +860,51 @@ export declare class ReserveAssetDataEvent implements StructClass {
860
860
  static get r(): reified.StructClassReified<ReserveAssetDataEvent, ReserveAssetDataEventFields>;
861
861
  static phantom(): PhantomReified<ToTypeStr<ReserveAssetDataEvent>>;
862
862
  static get p(): reified.PhantomReified<"0x1f54a9a2d71799553197e9ea24557797c6398d6a65f2d4d3818c9304b75d5e21::reserve::ReserveAssetDataEvent" | "0xf95b06141ed4a174f239417323bde3f209b972f5930d8521ea38a52aff3a6ddf::reserve::ReserveAssetDataEvent">;
863
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
864
- lending_market_id: import("@mysten/sui/bcs").BcsType<string, string, string>;
865
- coin_type: import("@mysten/sui/bcs").BcsStruct<{
866
- name: import("@mysten/sui/bcs").BcsStruct<{
867
- bytes: import("@mysten/sui/bcs").BcsType<number[], Iterable<number> & {
863
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
864
+ lending_market_id: import("@mysten/bcs").BcsType<string, string, string>;
865
+ coin_type: import("@mysten/bcs").BcsStruct<{
866
+ name: import("@mysten/bcs").BcsStruct<{
867
+ bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
868
868
  length: number;
869
869
  }, string>;
870
870
  }, string>;
871
871
  }, string>;
872
- reserve_id: import("@mysten/sui/bcs").BcsType<string, string, string>;
873
- available_amount: import("@mysten/sui/bcs").BcsStruct<{
874
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
872
+ reserve_id: import("@mysten/bcs").BcsType<string, string, string>;
873
+ available_amount: import("@mysten/bcs").BcsStruct<{
874
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
875
875
  }, string>;
876
- supply_amount: import("@mysten/sui/bcs").BcsStruct<{
877
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
876
+ supply_amount: import("@mysten/bcs").BcsStruct<{
877
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
878
878
  }, string>;
879
- borrowed_amount: import("@mysten/sui/bcs").BcsStruct<{
880
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
879
+ borrowed_amount: import("@mysten/bcs").BcsStruct<{
880
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
881
881
  }, string>;
882
- available_amount_usd_estimate: import("@mysten/sui/bcs").BcsStruct<{
883
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
882
+ available_amount_usd_estimate: import("@mysten/bcs").BcsStruct<{
883
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
884
884
  }, string>;
885
- supply_amount_usd_estimate: import("@mysten/sui/bcs").BcsStruct<{
886
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
885
+ supply_amount_usd_estimate: import("@mysten/bcs").BcsStruct<{
886
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
887
887
  }, string>;
888
- borrowed_amount_usd_estimate: import("@mysten/sui/bcs").BcsStruct<{
889
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
888
+ borrowed_amount_usd_estimate: import("@mysten/bcs").BcsStruct<{
889
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
890
890
  }, string>;
891
- borrow_apr: import("@mysten/sui/bcs").BcsStruct<{
892
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
891
+ borrow_apr: import("@mysten/bcs").BcsStruct<{
892
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
893
893
  }, string>;
894
- supply_apr: import("@mysten/sui/bcs").BcsStruct<{
895
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
894
+ supply_apr: import("@mysten/bcs").BcsStruct<{
895
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
896
896
  }, string>;
897
- ctoken_supply: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
898
- cumulative_borrow_rate: import("@mysten/sui/bcs").BcsStruct<{
899
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
897
+ ctoken_supply: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
898
+ cumulative_borrow_rate: import("@mysten/bcs").BcsStruct<{
899
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
900
900
  }, string>;
901
- price: import("@mysten/sui/bcs").BcsStruct<{
902
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
901
+ price: import("@mysten/bcs").BcsStruct<{
902
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
903
903
  }, string>;
904
- smoothed_price: import("@mysten/sui/bcs").BcsStruct<{
905
- value: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u256">;
904
+ smoothed_price: import("@mysten/bcs").BcsStruct<{
905
+ value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
906
906
  }, string>;
907
- price_last_update_timestamp_s: import("@mysten/sui/bcs").BcsType<string, string | number | bigint, "u64">;
907
+ price_last_update_timestamp_s: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
908
908
  }, string>;
909
909
  static fromFields(fields: Record<string, any>): ReserveAssetDataEvent;
910
910
  static fromFieldsWithTypes(item: FieldsWithTypes): ReserveAssetDataEvent;
@@ -1019,8 +1019,8 @@ export declare class StakerKey implements StructClass {
1019
1019
  static get r(): reified.StructClassReified<StakerKey, StakerKeyFields>;
1020
1020
  static phantom(): PhantomReified<ToTypeStr<StakerKey>>;
1021
1021
  static get p(): reified.PhantomReified<"0xe5ed361add4433f4d23e56fc0e3bacab39b93592d5e65d508e33fd19ff696669::reserve::StakerKey" | "0x5b54b47971238403d6ade3c8c2cc75814cb55145a5184af916bb5b12aaf184cb::reserve::StakerKey">;
1022
- static get bcs(): import("@mysten/sui/bcs").BcsStruct<{
1023
- dummy_field: import("@mysten/sui/bcs").BcsType<boolean, boolean, "bool">;
1022
+ static get bcs(): import("@mysten/bcs").BcsStruct<{
1023
+ dummy_field: import("@mysten/bcs").BcsType<boolean, boolean, "bool">;
1024
1024
  }, string>;
1025
1025
  static fromFields(fields: Record<string, any>): StakerKey;
1026
1026
  static fromFieldsWithTypes(item: FieldsWithTypes): StakerKey;