@suilend/sdk 1.1.99 → 2.0.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.
- package/_generated/_dependencies/source/0x1/ascii/structs.d.ts +7 -7
- package/_generated/_dependencies/source/0x1/ascii/structs.js +35 -75
- package/_generated/_dependencies/source/0x1/index.js +3 -6
- package/_generated/_dependencies/source/0x1/option/structs.d.ts +3 -3
- package/_generated/_dependencies/source/0x1/option/structs.js +31 -69
- package/_generated/_dependencies/source/0x1/type-name/structs.d.ts +5 -5
- package/_generated/_dependencies/source/0x1/type-name/structs.js +20 -25
- package/_generated/_dependencies/source/0x2/bag/structs.d.ts +7 -7
- package/_generated/_dependencies/source/0x2/bag/structs.js +24 -29
- package/_generated/_dependencies/source/0x2/balance/structs.d.ts +7 -7
- package/_generated/_dependencies/source/0x2/balance/structs.js +49 -56
- package/_generated/_dependencies/source/0x2/index.js +3 -6
- package/_generated/_dependencies/source/0x2/object/structs.d.ts +8 -8
- package/_generated/_dependencies/source/0x2/object/structs.js +34 -41
- package/_generated/_dependencies/source/0x2/object-table/structs.d.ts +7 -7
- package/_generated/_dependencies/source/0x2/object-table/structs.js +31 -36
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/i64/structs.d.ts +5 -5
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/i64/structs.js +23 -28
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/index.js +4 -7
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price/structs.d.ts +11 -11
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price/structs.js +32 -37
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-feed/structs.d.ts +23 -23
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-feed/structs.js +29 -34
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-identifier/structs.d.ts +4 -4
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-identifier/structs.js +21 -59
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-info/structs.d.ts +55 -55
- package/_generated/_dependencies/source/0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e/price-info/structs.js +46 -53
- package/_generated/_framework/reified.d.ts +2 -2
- package/_generated/_framework/reified.js +27 -40
- package/_generated/_framework/util.js +26 -40
- package/_generated/_framework/vector.d.ts +4 -4
- package/_generated/_framework/vector.js +16 -21
- package/_generated/suilend/cell/structs.d.ts +4 -4
- package/_generated/suilend/cell/structs.js +31 -36
- package/_generated/suilend/decimal/structs.d.ts +4 -4
- package/_generated/suilend/decimal/structs.js +19 -24
- package/_generated/suilend/index.js +8 -12
- package/_generated/suilend/lending-market/functions.d.ts +1 -0
- package/_generated/suilend/lending-market/functions.js +271 -302
- package/_generated/suilend/lending-market/structs.d.ts +146 -146
- package/_generated/suilend/lending-market/structs.js +549 -617
- package/_generated/suilend/lending-market-registry/functions.js +7 -11
- package/_generated/suilend/liquidity-mining/structs.d.ts +50 -50
- package/_generated/suilend/liquidity-mining/structs.js +159 -205
- package/_generated/suilend/obligation/structs.d.ts +106 -106
- package/_generated/suilend/obligation/structs.js +313 -363
- package/_generated/suilend/rate-limiter/functions.js +23 -31
- package/_generated/suilend/rate-limiter/structs.d.ts +15 -15
- package/_generated/suilend/rate-limiter/structs.js +49 -56
- package/_generated/suilend/reserve/structs.d.ts +139 -139
- package/_generated/suilend/reserve/structs.js +397 -451
- package/_generated/suilend/reserve-config/functions.js +149 -190
- package/_generated/suilend/reserve-config/structs.d.ts +33 -33
- package/_generated/suilend/reserve-config/structs.js +109 -149
- package/api/events.js +1 -5
- package/api/index.js +1 -17
- package/client.d.ts +10 -10
- package/client.js +118 -128
- package/index.js +7 -23
- package/lib/constants.js +3 -9
- package/lib/index.js +5 -21
- package/lib/initialize.d.ts +3 -3
- package/lib/initialize.js +103 -140
- package/lib/liquidityMining.d.ts +3 -3
- package/lib/liquidityMining.js +57 -72
- package/lib/pyth.js +9 -14
- package/lib/strategyOwnerCap.js +106 -119
- package/lib/transactions.js +2 -7
- package/lib/types.js +4 -7
- package/mmt.js +2 -5
- package/package.json +1 -1
- package/parsers/apiReserveAssetDataEvent.js +25 -33
- package/parsers/index.js +5 -21
- package/parsers/lendingMarket.d.ts +1 -1
- package/parsers/lendingMarket.js +12 -19
- package/parsers/obligation.js +19 -26
- package/parsers/rateLimiter.js +11 -19
- package/parsers/reserve.d.ts +1 -1
- package/parsers/reserve.js +42 -85
- package/strategies.d.ts +11 -11
- package/strategies.js +547 -586
- package/swap/index.js +2 -18
- package/swap/quote.js +57 -65
- package/swap/transaction.d.ts +2 -2
- package/swap/transaction.js +40 -35
- package/utils/events.d.ts +3 -3
- package/utils/events.js +18 -35
- package/utils/index.js +16 -40
- package/utils/obligation.d.ts +4 -4
- package/utils/obligation.js +17 -60
- package/utils/simulate.js +118 -143
|
@@ -7,7 +7,7 @@ import { Vector } from "../../_framework/vector";
|
|
|
7
7
|
import { Decimal } from "../decimal/structs";
|
|
8
8
|
import { PKG_V1, PKG_V11 } from "../index";
|
|
9
9
|
import { UserRewardManager } from "../liquidity-mining/structs";
|
|
10
|
-
import {
|
|
10
|
+
import { SuiJsonRpcClient, SuiObjectData, SuiParsedData } from "@mysten/sui/jsonRpc";
|
|
11
11
|
export declare function isBorrow(type: string): boolean;
|
|
12
12
|
export interface BorrowFields {
|
|
13
13
|
coinType: ToField<TypeName>;
|
|
@@ -38,25 +38,25 @@ export declare class Borrow implements StructClass {
|
|
|
38
38
|
static get r(): reified.StructClassReified<Borrow, BorrowFields>;
|
|
39
39
|
static phantom(): PhantomReified<ToTypeStr<Borrow>>;
|
|
40
40
|
static get p(): reified.PhantomReified<"0x1f54a9a2d71799553197e9ea24557797c6398d6a65f2d4d3818c9304b75d5e21::obligation::Borrow" | "0xf95b06141ed4a174f239417323bde3f209b972f5930d8521ea38a52aff3a6ddf::obligation::Borrow">;
|
|
41
|
-
static get bcs(): import("@mysten/
|
|
42
|
-
coin_type: import("@mysten/
|
|
43
|
-
name: import("@mysten/
|
|
44
|
-
bytes: import("@mysten/
|
|
41
|
+
static get bcs(): import("@mysten/bcs").BcsStruct<{
|
|
42
|
+
coin_type: import("@mysten/bcs").BcsStruct<{
|
|
43
|
+
name: import("@mysten/bcs").BcsStruct<{
|
|
44
|
+
bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
|
|
45
45
|
length: number;
|
|
46
46
|
}, string>;
|
|
47
47
|
}, string>;
|
|
48
48
|
}, string>;
|
|
49
|
-
reserve_array_index: import("@mysten/
|
|
50
|
-
borrowed_amount: import("@mysten/
|
|
51
|
-
value: import("@mysten/
|
|
49
|
+
reserve_array_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
50
|
+
borrowed_amount: import("@mysten/bcs").BcsStruct<{
|
|
51
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
52
52
|
}, string>;
|
|
53
|
-
cumulative_borrow_rate: import("@mysten/
|
|
54
|
-
value: import("@mysten/
|
|
53
|
+
cumulative_borrow_rate: import("@mysten/bcs").BcsStruct<{
|
|
54
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
55
55
|
}, string>;
|
|
56
|
-
market_value: import("@mysten/
|
|
57
|
-
value: import("@mysten/
|
|
56
|
+
market_value: import("@mysten/bcs").BcsStruct<{
|
|
57
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
58
58
|
}, string>;
|
|
59
|
-
user_reward_manager_index: import("@mysten/
|
|
59
|
+
user_reward_manager_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
60
60
|
}, string>;
|
|
61
61
|
static fromFields(fields: Record<string, any>): Borrow;
|
|
62
62
|
static fromFieldsWithTypes(item: FieldsWithTypes): Borrow;
|
|
@@ -99,7 +99,7 @@ export declare class Borrow implements StructClass {
|
|
|
99
99
|
static fromJSON(json: Record<string, any>): Borrow;
|
|
100
100
|
static fromSuiParsedData(content: SuiParsedData): Borrow;
|
|
101
101
|
static fromSuiObjectData(data: SuiObjectData): Borrow;
|
|
102
|
-
static fetch(client:
|
|
102
|
+
static fetch(client: SuiJsonRpcClient, id: string): Promise<Borrow>;
|
|
103
103
|
}
|
|
104
104
|
export declare function isBorrowRecord(type: string): boolean;
|
|
105
105
|
export interface BorrowRecordFields {
|
|
@@ -131,25 +131,25 @@ export declare class BorrowRecord implements StructClass {
|
|
|
131
131
|
static get r(): reified.StructClassReified<BorrowRecord, BorrowRecordFields>;
|
|
132
132
|
static phantom(): PhantomReified<ToTypeStr<BorrowRecord>>;
|
|
133
133
|
static get p(): reified.PhantomReified<"0x1f54a9a2d71799553197e9ea24557797c6398d6a65f2d4d3818c9304b75d5e21::obligation::BorrowRecord" | "0xf95b06141ed4a174f239417323bde3f209b972f5930d8521ea38a52aff3a6ddf::obligation::BorrowRecord">;
|
|
134
|
-
static get bcs(): import("@mysten/
|
|
135
|
-
coin_type: import("@mysten/
|
|
136
|
-
name: import("@mysten/
|
|
137
|
-
bytes: import("@mysten/
|
|
134
|
+
static get bcs(): import("@mysten/bcs").BcsStruct<{
|
|
135
|
+
coin_type: import("@mysten/bcs").BcsStruct<{
|
|
136
|
+
name: import("@mysten/bcs").BcsStruct<{
|
|
137
|
+
bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
|
|
138
138
|
length: number;
|
|
139
139
|
}, string>;
|
|
140
140
|
}, string>;
|
|
141
141
|
}, string>;
|
|
142
|
-
reserve_array_index: import("@mysten/
|
|
143
|
-
borrowed_amount: import("@mysten/
|
|
144
|
-
value: import("@mysten/
|
|
142
|
+
reserve_array_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
143
|
+
borrowed_amount: import("@mysten/bcs").BcsStruct<{
|
|
144
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
145
145
|
}, string>;
|
|
146
|
-
cumulative_borrow_rate: import("@mysten/
|
|
147
|
-
value: import("@mysten/
|
|
146
|
+
cumulative_borrow_rate: import("@mysten/bcs").BcsStruct<{
|
|
147
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
148
148
|
}, string>;
|
|
149
|
-
market_value: import("@mysten/
|
|
150
|
-
value: import("@mysten/
|
|
149
|
+
market_value: import("@mysten/bcs").BcsStruct<{
|
|
150
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
151
151
|
}, string>;
|
|
152
|
-
user_reward_manager_index: import("@mysten/
|
|
152
|
+
user_reward_manager_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
153
153
|
}, string>;
|
|
154
154
|
static fromFields(fields: Record<string, any>): BorrowRecord;
|
|
155
155
|
static fromFieldsWithTypes(item: FieldsWithTypes): BorrowRecord;
|
|
@@ -192,7 +192,7 @@ export declare class BorrowRecord implements StructClass {
|
|
|
192
192
|
static fromJSON(json: Record<string, any>): BorrowRecord;
|
|
193
193
|
static fromSuiParsedData(content: SuiParsedData): BorrowRecord;
|
|
194
194
|
static fromSuiObjectData(data: SuiObjectData): BorrowRecord;
|
|
195
|
-
static fetch(client:
|
|
195
|
+
static fetch(client: SuiJsonRpcClient, id: string): Promise<BorrowRecord>;
|
|
196
196
|
}
|
|
197
197
|
export declare function isDeposit(type: string): boolean;
|
|
198
198
|
export interface DepositFields {
|
|
@@ -224,22 +224,22 @@ export declare class Deposit implements StructClass {
|
|
|
224
224
|
static get r(): reified.StructClassReified<Deposit, DepositFields>;
|
|
225
225
|
static phantom(): PhantomReified<ToTypeStr<Deposit>>;
|
|
226
226
|
static get p(): reified.PhantomReified<"0x1f54a9a2d71799553197e9ea24557797c6398d6a65f2d4d3818c9304b75d5e21::obligation::Deposit" | "0xf95b06141ed4a174f239417323bde3f209b972f5930d8521ea38a52aff3a6ddf::obligation::Deposit">;
|
|
227
|
-
static get bcs(): import("@mysten/
|
|
228
|
-
coin_type: import("@mysten/
|
|
229
|
-
name: import("@mysten/
|
|
230
|
-
bytes: import("@mysten/
|
|
227
|
+
static get bcs(): import("@mysten/bcs").BcsStruct<{
|
|
228
|
+
coin_type: import("@mysten/bcs").BcsStruct<{
|
|
229
|
+
name: import("@mysten/bcs").BcsStruct<{
|
|
230
|
+
bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
|
|
231
231
|
length: number;
|
|
232
232
|
}, string>;
|
|
233
233
|
}, string>;
|
|
234
234
|
}, string>;
|
|
235
|
-
reserve_array_index: import("@mysten/
|
|
236
|
-
deposited_ctoken_amount: import("@mysten/
|
|
237
|
-
market_value: import("@mysten/
|
|
238
|
-
value: import("@mysten/
|
|
235
|
+
reserve_array_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
236
|
+
deposited_ctoken_amount: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
237
|
+
market_value: import("@mysten/bcs").BcsStruct<{
|
|
238
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
239
239
|
}, string>;
|
|
240
|
-
user_reward_manager_index: import("@mysten/
|
|
241
|
-
attributed_borrow_value: import("@mysten/
|
|
242
|
-
value: import("@mysten/
|
|
240
|
+
user_reward_manager_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
241
|
+
attributed_borrow_value: import("@mysten/bcs").BcsStruct<{
|
|
242
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
243
243
|
}, string>;
|
|
244
244
|
}, string>;
|
|
245
245
|
static fromFields(fields: Record<string, any>): Deposit;
|
|
@@ -279,7 +279,7 @@ export declare class Deposit implements StructClass {
|
|
|
279
279
|
static fromJSON(json: Record<string, any>): Deposit;
|
|
280
280
|
static fromSuiParsedData(content: SuiParsedData): Deposit;
|
|
281
281
|
static fromSuiObjectData(data: SuiObjectData): Deposit;
|
|
282
|
-
static fetch(client:
|
|
282
|
+
static fetch(client: SuiJsonRpcClient, id: string): Promise<Deposit>;
|
|
283
283
|
}
|
|
284
284
|
export declare function isDepositRecord(type: string): boolean;
|
|
285
285
|
export interface DepositRecordFields {
|
|
@@ -311,22 +311,22 @@ export declare class DepositRecord implements StructClass {
|
|
|
311
311
|
static get r(): reified.StructClassReified<DepositRecord, DepositRecordFields>;
|
|
312
312
|
static phantom(): PhantomReified<ToTypeStr<DepositRecord>>;
|
|
313
313
|
static get p(): reified.PhantomReified<"0x1f54a9a2d71799553197e9ea24557797c6398d6a65f2d4d3818c9304b75d5e21::obligation::DepositRecord" | "0xf95b06141ed4a174f239417323bde3f209b972f5930d8521ea38a52aff3a6ddf::obligation::DepositRecord">;
|
|
314
|
-
static get bcs(): import("@mysten/
|
|
315
|
-
coin_type: import("@mysten/
|
|
316
|
-
name: import("@mysten/
|
|
317
|
-
bytes: import("@mysten/
|
|
314
|
+
static get bcs(): import("@mysten/bcs").BcsStruct<{
|
|
315
|
+
coin_type: import("@mysten/bcs").BcsStruct<{
|
|
316
|
+
name: import("@mysten/bcs").BcsStruct<{
|
|
317
|
+
bytes: import("@mysten/bcs").BcsType<number[], Iterable<number> & {
|
|
318
318
|
length: number;
|
|
319
319
|
}, string>;
|
|
320
320
|
}, string>;
|
|
321
321
|
}, string>;
|
|
322
|
-
reserve_array_index: import("@mysten/
|
|
323
|
-
deposited_ctoken_amount: import("@mysten/
|
|
324
|
-
market_value: import("@mysten/
|
|
325
|
-
value: import("@mysten/
|
|
322
|
+
reserve_array_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
323
|
+
deposited_ctoken_amount: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
324
|
+
market_value: import("@mysten/bcs").BcsStruct<{
|
|
325
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
326
326
|
}, string>;
|
|
327
|
-
user_reward_manager_index: import("@mysten/
|
|
328
|
-
attributed_borrow_value: import("@mysten/
|
|
329
|
-
value: import("@mysten/
|
|
327
|
+
user_reward_manager_index: import("@mysten/bcs").BcsType<string, string | number | bigint, "u64">;
|
|
328
|
+
attributed_borrow_value: import("@mysten/bcs").BcsStruct<{
|
|
329
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
330
330
|
}, string>;
|
|
331
331
|
}, string>;
|
|
332
332
|
static fromFields(fields: Record<string, any>): DepositRecord;
|
|
@@ -366,7 +366,7 @@ export declare class DepositRecord implements StructClass {
|
|
|
366
366
|
static fromJSON(json: Record<string, any>): DepositRecord;
|
|
367
367
|
static fromSuiParsedData(content: SuiParsedData): DepositRecord;
|
|
368
368
|
static fromSuiObjectData(data: SuiObjectData): DepositRecord;
|
|
369
|
-
static fetch(client:
|
|
369
|
+
static fetch(client: SuiJsonRpcClient, id: string): Promise<DepositRecord>;
|
|
370
370
|
}
|
|
371
371
|
export declare function isExistStaleOracles(type: string): boolean;
|
|
372
372
|
export interface ExistStaleOraclesFields {
|
|
@@ -388,8 +388,8 @@ export declare class ExistStaleOracles implements StructClass {
|
|
|
388
388
|
static get r(): reified.StructClassReified<ExistStaleOracles, ExistStaleOraclesFields>;
|
|
389
389
|
static phantom(): PhantomReified<ToTypeStr<ExistStaleOracles>>;
|
|
390
390
|
static get p(): reified.PhantomReified<"0xe5ed361add4433f4d23e56fc0e3bacab39b93592d5e65d508e33fd19ff696669::obligation::ExistStaleOracles" | "0xd2a67633ccb8de063163e25bcfca242929caf5cf1a26c2929dab519ee0b8f331::obligation::ExistStaleOracles">;
|
|
391
|
-
static get bcs(): import("@mysten/
|
|
392
|
-
dummy_field: import("@mysten/
|
|
391
|
+
static get bcs(): import("@mysten/bcs").BcsStruct<{
|
|
392
|
+
dummy_field: import("@mysten/bcs").BcsType<boolean, boolean, "bool">;
|
|
393
393
|
}, string>;
|
|
394
394
|
static fromFields(fields: Record<string, any>): ExistStaleOracles;
|
|
395
395
|
static fromFieldsWithTypes(item: FieldsWithTypes): ExistStaleOracles;
|
|
@@ -406,7 +406,7 @@ export declare class ExistStaleOracles implements StructClass {
|
|
|
406
406
|
static fromJSON(json: Record<string, any>): ExistStaleOracles;
|
|
407
407
|
static fromSuiParsedData(content: SuiParsedData): ExistStaleOracles;
|
|
408
408
|
static fromSuiObjectData(data: SuiObjectData): ExistStaleOracles;
|
|
409
|
-
static fetch(client:
|
|
409
|
+
static fetch(client: SuiJsonRpcClient, id: string): Promise<ExistStaleOracles>;
|
|
410
410
|
}
|
|
411
411
|
export declare function isObligation(type: string): boolean;
|
|
412
412
|
export interface ObligationFields<P extends PhantomTypeArgument> {
|
|
@@ -456,16 +456,16 @@ export declare class Obligation<P extends PhantomTypeArgument> implements Struct
|
|
|
456
456
|
static get r(): typeof Obligation.reified;
|
|
457
457
|
static phantom<P extends PhantomReified<PhantomTypeArgument>>(P: P): PhantomReified<ToTypeStr<Obligation<ToPhantomTypeArgument<P>>>>;
|
|
458
458
|
static get p(): typeof Obligation.phantom;
|
|
459
|
-
static get bcs(): import("@mysten/
|
|
460
|
-
id: import("@mysten/
|
|
461
|
-
id: import("@mysten/
|
|
462
|
-
bytes: import("@mysten/
|
|
459
|
+
static get bcs(): import("@mysten/bcs").BcsStruct<{
|
|
460
|
+
id: import("@mysten/bcs").BcsStruct<{
|
|
461
|
+
id: import("@mysten/bcs").BcsStruct<{
|
|
462
|
+
bytes: import("@mysten/bcs").BcsType<string, string, string>;
|
|
463
463
|
}, string>;
|
|
464
464
|
}, string>;
|
|
465
|
-
lending_market_id: import("@mysten/
|
|
466
|
-
bytes: import("@mysten/
|
|
465
|
+
lending_market_id: import("@mysten/bcs").BcsStruct<{
|
|
466
|
+
bytes: import("@mysten/bcs").BcsType<string, string, string>;
|
|
467
467
|
}, string>;
|
|
468
|
-
deposits: import("@mysten/
|
|
468
|
+
deposits: import("@mysten/bcs").BcsType<{
|
|
469
469
|
coin_type: {
|
|
470
470
|
name: {
|
|
471
471
|
bytes: number[];
|
|
@@ -500,7 +500,7 @@ export declare class Obligation<P extends PhantomTypeArgument> implements Struct
|
|
|
500
500
|
}> & {
|
|
501
501
|
length: number;
|
|
502
502
|
}, string>;
|
|
503
|
-
borrows: import("@mysten/
|
|
503
|
+
borrows: import("@mysten/bcs").BcsType<{
|
|
504
504
|
coin_type: {
|
|
505
505
|
name: {
|
|
506
506
|
bytes: number[];
|
|
@@ -539,29 +539,29 @@ export declare class Obligation<P extends PhantomTypeArgument> implements Struct
|
|
|
539
539
|
}> & {
|
|
540
540
|
length: number;
|
|
541
541
|
}, string>;
|
|
542
|
-
deposited_value_usd: import("@mysten/
|
|
543
|
-
value: import("@mysten/
|
|
542
|
+
deposited_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
543
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
544
544
|
}, string>;
|
|
545
|
-
allowed_borrow_value_usd: import("@mysten/
|
|
546
|
-
value: import("@mysten/
|
|
545
|
+
allowed_borrow_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
546
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
547
547
|
}, string>;
|
|
548
|
-
unhealthy_borrow_value_usd: import("@mysten/
|
|
549
|
-
value: import("@mysten/
|
|
548
|
+
unhealthy_borrow_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
549
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
550
550
|
}, string>;
|
|
551
|
-
super_unhealthy_borrow_value_usd: import("@mysten/
|
|
552
|
-
value: import("@mysten/
|
|
551
|
+
super_unhealthy_borrow_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
552
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
553
553
|
}, string>;
|
|
554
|
-
unweighted_borrowed_value_usd: import("@mysten/
|
|
555
|
-
value: import("@mysten/
|
|
554
|
+
unweighted_borrowed_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
555
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
556
556
|
}, string>;
|
|
557
|
-
weighted_borrowed_value_usd: import("@mysten/
|
|
558
|
-
value: import("@mysten/
|
|
557
|
+
weighted_borrowed_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
558
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
559
559
|
}, string>;
|
|
560
|
-
weighted_borrowed_value_upper_bound_usd: import("@mysten/
|
|
561
|
-
value: import("@mysten/
|
|
560
|
+
weighted_borrowed_value_upper_bound_usd: import("@mysten/bcs").BcsStruct<{
|
|
561
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
562
562
|
}, string>;
|
|
563
|
-
borrowing_isolated_asset: import("@mysten/
|
|
564
|
-
user_reward_managers: import("@mysten/
|
|
563
|
+
borrowing_isolated_asset: import("@mysten/bcs").BcsType<boolean, boolean, "bool">;
|
|
564
|
+
user_reward_managers: import("@mysten/bcs").BcsType<{
|
|
565
565
|
pool_reward_manager_id: {
|
|
566
566
|
bytes: string;
|
|
567
567
|
};
|
|
@@ -606,10 +606,10 @@ export declare class Obligation<P extends PhantomTypeArgument> implements Struct
|
|
|
606
606
|
}> & {
|
|
607
607
|
length: number;
|
|
608
608
|
}, string>;
|
|
609
|
-
bad_debt_usd: import("@mysten/
|
|
610
|
-
value: import("@mysten/
|
|
609
|
+
bad_debt_usd: import("@mysten/bcs").BcsStruct<{
|
|
610
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
611
611
|
}, string>;
|
|
612
|
-
closable: import("@mysten/
|
|
612
|
+
closable: import("@mysten/bcs").BcsType<boolean, boolean, "bool">;
|
|
613
613
|
}, string>;
|
|
614
614
|
static fromFields<P extends PhantomReified<PhantomTypeArgument>>(typeArg: P, fields: Record<string, any>): Obligation<ToPhantomTypeArgument<P>>;
|
|
615
615
|
static fromFieldsWithTypes<P extends PhantomReified<PhantomTypeArgument>>(typeArg: P, item: FieldsWithTypes): Obligation<ToPhantomTypeArgument<P>>;
|
|
@@ -768,7 +768,7 @@ export declare class Obligation<P extends PhantomTypeArgument> implements Struct
|
|
|
768
768
|
static fromJSON<P extends PhantomReified<PhantomTypeArgument>>(typeArg: P, json: Record<string, any>): Obligation<ToPhantomTypeArgument<P>>;
|
|
769
769
|
static fromSuiParsedData<P extends PhantomReified<PhantomTypeArgument>>(typeArg: P, content: SuiParsedData): Obligation<ToPhantomTypeArgument<P>>;
|
|
770
770
|
static fromSuiObjectData<P extends PhantomReified<PhantomTypeArgument>>(typeArg: P, data: SuiObjectData): Obligation<ToPhantomTypeArgument<P>>;
|
|
771
|
-
static fetch<P extends PhantomReified<PhantomTypeArgument>>(client:
|
|
771
|
+
static fetch<P extends PhantomReified<PhantomTypeArgument>>(client: SuiJsonRpcClient, typeArg: P, id: string): Promise<Obligation<ToPhantomTypeArgument<P>>>;
|
|
772
772
|
}
|
|
773
773
|
export declare function isObligationDataEvent(type: string): boolean;
|
|
774
774
|
export interface ObligationDataEventFields {
|
|
@@ -816,10 +816,10 @@ export declare class ObligationDataEvent implements StructClass {
|
|
|
816
816
|
static get r(): reified.StructClassReified<ObligationDataEvent, ObligationDataEventFields>;
|
|
817
817
|
static phantom(): PhantomReified<ToTypeStr<ObligationDataEvent>>;
|
|
818
818
|
static get p(): reified.PhantomReified<"0x1f54a9a2d71799553197e9ea24557797c6398d6a65f2d4d3818c9304b75d5e21::obligation::ObligationDataEvent" | "0xf95b06141ed4a174f239417323bde3f209b972f5930d8521ea38a52aff3a6ddf::obligation::ObligationDataEvent">;
|
|
819
|
-
static get bcs(): import("@mysten/
|
|
820
|
-
lending_market_id: import("@mysten/
|
|
821
|
-
obligation_id: import("@mysten/
|
|
822
|
-
deposits: import("@mysten/
|
|
819
|
+
static get bcs(): import("@mysten/bcs").BcsStruct<{
|
|
820
|
+
lending_market_id: import("@mysten/bcs").BcsType<string, string, string>;
|
|
821
|
+
obligation_id: import("@mysten/bcs").BcsType<string, string, string>;
|
|
822
|
+
deposits: import("@mysten/bcs").BcsType<{
|
|
823
823
|
coin_type: {
|
|
824
824
|
name: {
|
|
825
825
|
bytes: number[];
|
|
@@ -854,7 +854,7 @@ export declare class ObligationDataEvent implements StructClass {
|
|
|
854
854
|
}> & {
|
|
855
855
|
length: number;
|
|
856
856
|
}, string>;
|
|
857
|
-
borrows: import("@mysten/
|
|
857
|
+
borrows: import("@mysten/bcs").BcsType<{
|
|
858
858
|
coin_type: {
|
|
859
859
|
name: {
|
|
860
860
|
bytes: number[];
|
|
@@ -893,32 +893,32 @@ export declare class ObligationDataEvent implements StructClass {
|
|
|
893
893
|
}> & {
|
|
894
894
|
length: number;
|
|
895
895
|
}, string>;
|
|
896
|
-
deposited_value_usd: import("@mysten/
|
|
897
|
-
value: import("@mysten/
|
|
896
|
+
deposited_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
897
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
898
898
|
}, string>;
|
|
899
|
-
allowed_borrow_value_usd: import("@mysten/
|
|
900
|
-
value: import("@mysten/
|
|
899
|
+
allowed_borrow_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
900
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
901
901
|
}, string>;
|
|
902
|
-
unhealthy_borrow_value_usd: import("@mysten/
|
|
903
|
-
value: import("@mysten/
|
|
902
|
+
unhealthy_borrow_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
903
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
904
904
|
}, string>;
|
|
905
|
-
super_unhealthy_borrow_value_usd: import("@mysten/
|
|
906
|
-
value: import("@mysten/
|
|
905
|
+
super_unhealthy_borrow_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
906
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
907
907
|
}, string>;
|
|
908
|
-
unweighted_borrowed_value_usd: import("@mysten/
|
|
909
|
-
value: import("@mysten/
|
|
908
|
+
unweighted_borrowed_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
909
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
910
910
|
}, string>;
|
|
911
|
-
weighted_borrowed_value_usd: import("@mysten/
|
|
912
|
-
value: import("@mysten/
|
|
911
|
+
weighted_borrowed_value_usd: import("@mysten/bcs").BcsStruct<{
|
|
912
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
913
913
|
}, string>;
|
|
914
|
-
weighted_borrowed_value_upper_bound_usd: import("@mysten/
|
|
915
|
-
value: import("@mysten/
|
|
914
|
+
weighted_borrowed_value_upper_bound_usd: import("@mysten/bcs").BcsStruct<{
|
|
915
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
916
916
|
}, string>;
|
|
917
|
-
borrowing_isolated_asset: import("@mysten/
|
|
918
|
-
bad_debt_usd: import("@mysten/
|
|
919
|
-
value: import("@mysten/
|
|
917
|
+
borrowing_isolated_asset: import("@mysten/bcs").BcsType<boolean, boolean, "bool">;
|
|
918
|
+
bad_debt_usd: import("@mysten/bcs").BcsStruct<{
|
|
919
|
+
value: import("@mysten/bcs").BcsType<string, string | number | bigint, "u256">;
|
|
920
920
|
}, string>;
|
|
921
|
-
closable: import("@mysten/
|
|
921
|
+
closable: import("@mysten/bcs").BcsType<boolean, boolean, "bool">;
|
|
922
922
|
}, string>;
|
|
923
923
|
static fromFields(fields: Record<string, any>): ObligationDataEvent;
|
|
924
924
|
static fromFieldsWithTypes(item: FieldsWithTypes): ObligationDataEvent;
|
|
@@ -1049,5 +1049,5 @@ export declare class ObligationDataEvent implements StructClass {
|
|
|
1049
1049
|
static fromJSON(json: Record<string, any>): ObligationDataEvent;
|
|
1050
1050
|
static fromSuiParsedData(content: SuiParsedData): ObligationDataEvent;
|
|
1051
1051
|
static fromSuiObjectData(data: SuiObjectData): ObligationDataEvent;
|
|
1052
|
-
static fetch(client:
|
|
1052
|
+
static fetch(client: SuiJsonRpcClient, id: string): Promise<ObligationDataEvent>;
|
|
1053
1053
|
}
|