@msafe/sui-app-store 0.0.350 → 0.0.352
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/dist/index.d.mts +43 -6
- package/dist/index.d.ts +43 -6
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.d.mts
CHANGED
|
@@ -4,9 +4,9 @@ import { NumStr } from '@firefly-exchange/library-sui';
|
|
|
4
4
|
import { Pool, NFT, Trade } from 'turbos-clmm-sdk';
|
|
5
5
|
import { Transaction } from '@mysten/sui/transactions';
|
|
6
6
|
import { IdentifierString, WalletAccount, SuiSignTransactionBlockInput } from '@mysten/wallet-standard';
|
|
7
|
-
import { SuiJsonRpcClient } from '@mysten/sui/jsonRpc';
|
|
8
7
|
import { SuiGrpcClient } from '@mysten/sui/grpc';
|
|
9
|
-
import {
|
|
8
|
+
import { DevInspectResults } from '@mysten/sui/jsonRpc';
|
|
9
|
+
import { SuiClient as SuiClient$1 } from '@mysten/sui.js/client';
|
|
10
10
|
import { TransactionBlock } from '@mysten/sui.js/transactions';
|
|
11
11
|
|
|
12
12
|
type AlphaFiIntentionData = DepositDoubleAssetIntentionData | DepositSingleAssetIntentionData | WithdrawAlphaIntentionData | WithdrawIntentionData$2 | EmptyIntentionData;
|
|
@@ -241,6 +241,8 @@ interface IAppHelperInternalGrpc<T> {
|
|
|
241
241
|
}): Promise<Transaction>;
|
|
242
242
|
}
|
|
243
243
|
|
|
244
|
+
type SuiNetworkName = 'mainnet' | 'testnet' | 'devnet' | 'localnet';
|
|
245
|
+
|
|
244
246
|
type MPayIntentionData = CreateStreamIntentionData | SetAutoClaimIntentionData | ClaimStreamIntentionData | ClaimByProxyStreamIntentionData | CancelStreamIntentionData;
|
|
245
247
|
|
|
246
248
|
interface CoinTransferIntentionData {
|
|
@@ -257,6 +259,41 @@ interface ObjectTransferIntentionData {
|
|
|
257
259
|
|
|
258
260
|
type CoreIntentionData = CoinTransferIntentionData | ObjectTransferIntentionData;
|
|
259
261
|
|
|
262
|
+
type SuiClientOptions = {
|
|
263
|
+
network: SuiNetworkName;
|
|
264
|
+
/** @deprecated Prefer baseUrl. Accepted for existing call sites. */
|
|
265
|
+
url?: string;
|
|
266
|
+
baseUrl?: string;
|
|
267
|
+
};
|
|
268
|
+
/**
|
|
269
|
+
* SuiClient backed by gRPC, with a few JSON-RPC-shaped helpers still used by apps
|
|
270
|
+
* (getCoins, devInspectTransactionBlock) until those call sites migrate fully.
|
|
271
|
+
*/
|
|
272
|
+
declare class SuiClient extends SuiGrpcClient {
|
|
273
|
+
constructor(options: SuiClientOptions);
|
|
274
|
+
getCoins(input: {
|
|
275
|
+
owner: string;
|
|
276
|
+
coinType?: string;
|
|
277
|
+
cursor?: string | null;
|
|
278
|
+
limit?: number;
|
|
279
|
+
}): Promise<{
|
|
280
|
+
data: {
|
|
281
|
+
coinType: string;
|
|
282
|
+
coinObjectId: string;
|
|
283
|
+
version: string;
|
|
284
|
+
digest: string;
|
|
285
|
+
balance: string;
|
|
286
|
+
previousTransaction: string;
|
|
287
|
+
}[];
|
|
288
|
+
hasNextPage: boolean;
|
|
289
|
+
nextCursor: string;
|
|
290
|
+
}>;
|
|
291
|
+
devInspectTransactionBlock(input: {
|
|
292
|
+
sender: string;
|
|
293
|
+
transactionBlock: Transaction | Uint8Array | string;
|
|
294
|
+
}): Promise<DevInspectResults>;
|
|
295
|
+
}
|
|
296
|
+
|
|
260
297
|
interface IAppHelperInternal<T> {
|
|
261
298
|
application: string;
|
|
262
299
|
supportSDK: '@mysten/sui';
|
|
@@ -264,7 +301,7 @@ interface IAppHelperInternal<T> {
|
|
|
264
301
|
transaction: Transaction;
|
|
265
302
|
chain: IdentifierString;
|
|
266
303
|
network: SuiNetworks;
|
|
267
|
-
suiClient:
|
|
304
|
+
suiClient: SuiClient;
|
|
268
305
|
account: WalletAccount;
|
|
269
306
|
appContext?: any;
|
|
270
307
|
}): Promise<{
|
|
@@ -277,7 +314,7 @@ interface IAppHelperInternal<T> {
|
|
|
277
314
|
txType: TransactionType;
|
|
278
315
|
txSubType: string;
|
|
279
316
|
intentionData: T;
|
|
280
|
-
suiClient:
|
|
317
|
+
suiClient: SuiClient;
|
|
281
318
|
account: WalletAccount;
|
|
282
319
|
}): Promise<Transaction>;
|
|
283
320
|
}
|
|
@@ -640,7 +677,7 @@ interface IAppHelperInternalLegacy<T> {
|
|
|
640
677
|
supportSDK: '@mysten/sui.js';
|
|
641
678
|
deserialize(input: SuiSignTransactionBlockInput & {
|
|
642
679
|
network: SuiNetworks;
|
|
643
|
-
suiClient: SuiClient;
|
|
680
|
+
suiClient: SuiClient$1;
|
|
644
681
|
account: WalletAccount;
|
|
645
682
|
appContext?: any;
|
|
646
683
|
}): Promise<{
|
|
@@ -653,7 +690,7 @@ interface IAppHelperInternalLegacy<T> {
|
|
|
653
690
|
txType: TransactionType;
|
|
654
691
|
txSubType: string;
|
|
655
692
|
intentionData: T;
|
|
656
|
-
suiClient: SuiClient;
|
|
693
|
+
suiClient: SuiClient$1;
|
|
657
694
|
account: WalletAccount;
|
|
658
695
|
}): Promise<TransactionBlock>;
|
|
659
696
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -4,9 +4,9 @@ import { NumStr } from '@firefly-exchange/library-sui';
|
|
|
4
4
|
import { Pool, NFT, Trade } from 'turbos-clmm-sdk';
|
|
5
5
|
import { Transaction } from '@mysten/sui/transactions';
|
|
6
6
|
import { IdentifierString, WalletAccount, SuiSignTransactionBlockInput } from '@mysten/wallet-standard';
|
|
7
|
-
import { SuiJsonRpcClient } from '@mysten/sui/jsonRpc';
|
|
8
7
|
import { SuiGrpcClient } from '@mysten/sui/grpc';
|
|
9
|
-
import {
|
|
8
|
+
import { DevInspectResults } from '@mysten/sui/jsonRpc';
|
|
9
|
+
import { SuiClient as SuiClient$1 } from '@mysten/sui.js/client';
|
|
10
10
|
import { TransactionBlock } from '@mysten/sui.js/transactions';
|
|
11
11
|
|
|
12
12
|
type AlphaFiIntentionData = DepositDoubleAssetIntentionData | DepositSingleAssetIntentionData | WithdrawAlphaIntentionData | WithdrawIntentionData$2 | EmptyIntentionData;
|
|
@@ -241,6 +241,8 @@ interface IAppHelperInternalGrpc<T> {
|
|
|
241
241
|
}): Promise<Transaction>;
|
|
242
242
|
}
|
|
243
243
|
|
|
244
|
+
type SuiNetworkName = 'mainnet' | 'testnet' | 'devnet' | 'localnet';
|
|
245
|
+
|
|
244
246
|
type MPayIntentionData = CreateStreamIntentionData | SetAutoClaimIntentionData | ClaimStreamIntentionData | ClaimByProxyStreamIntentionData | CancelStreamIntentionData;
|
|
245
247
|
|
|
246
248
|
interface CoinTransferIntentionData {
|
|
@@ -257,6 +259,41 @@ interface ObjectTransferIntentionData {
|
|
|
257
259
|
|
|
258
260
|
type CoreIntentionData = CoinTransferIntentionData | ObjectTransferIntentionData;
|
|
259
261
|
|
|
262
|
+
type SuiClientOptions = {
|
|
263
|
+
network: SuiNetworkName;
|
|
264
|
+
/** @deprecated Prefer baseUrl. Accepted for existing call sites. */
|
|
265
|
+
url?: string;
|
|
266
|
+
baseUrl?: string;
|
|
267
|
+
};
|
|
268
|
+
/**
|
|
269
|
+
* SuiClient backed by gRPC, with a few JSON-RPC-shaped helpers still used by apps
|
|
270
|
+
* (getCoins, devInspectTransactionBlock) until those call sites migrate fully.
|
|
271
|
+
*/
|
|
272
|
+
declare class SuiClient extends SuiGrpcClient {
|
|
273
|
+
constructor(options: SuiClientOptions);
|
|
274
|
+
getCoins(input: {
|
|
275
|
+
owner: string;
|
|
276
|
+
coinType?: string;
|
|
277
|
+
cursor?: string | null;
|
|
278
|
+
limit?: number;
|
|
279
|
+
}): Promise<{
|
|
280
|
+
data: {
|
|
281
|
+
coinType: string;
|
|
282
|
+
coinObjectId: string;
|
|
283
|
+
version: string;
|
|
284
|
+
digest: string;
|
|
285
|
+
balance: string;
|
|
286
|
+
previousTransaction: string;
|
|
287
|
+
}[];
|
|
288
|
+
hasNextPage: boolean;
|
|
289
|
+
nextCursor: string;
|
|
290
|
+
}>;
|
|
291
|
+
devInspectTransactionBlock(input: {
|
|
292
|
+
sender: string;
|
|
293
|
+
transactionBlock: Transaction | Uint8Array | string;
|
|
294
|
+
}): Promise<DevInspectResults>;
|
|
295
|
+
}
|
|
296
|
+
|
|
260
297
|
interface IAppHelperInternal<T> {
|
|
261
298
|
application: string;
|
|
262
299
|
supportSDK: '@mysten/sui';
|
|
@@ -264,7 +301,7 @@ interface IAppHelperInternal<T> {
|
|
|
264
301
|
transaction: Transaction;
|
|
265
302
|
chain: IdentifierString;
|
|
266
303
|
network: SuiNetworks;
|
|
267
|
-
suiClient:
|
|
304
|
+
suiClient: SuiClient;
|
|
268
305
|
account: WalletAccount;
|
|
269
306
|
appContext?: any;
|
|
270
307
|
}): Promise<{
|
|
@@ -277,7 +314,7 @@ interface IAppHelperInternal<T> {
|
|
|
277
314
|
txType: TransactionType;
|
|
278
315
|
txSubType: string;
|
|
279
316
|
intentionData: T;
|
|
280
|
-
suiClient:
|
|
317
|
+
suiClient: SuiClient;
|
|
281
318
|
account: WalletAccount;
|
|
282
319
|
}): Promise<Transaction>;
|
|
283
320
|
}
|
|
@@ -640,7 +677,7 @@ interface IAppHelperInternalLegacy<T> {
|
|
|
640
677
|
supportSDK: '@mysten/sui.js';
|
|
641
678
|
deserialize(input: SuiSignTransactionBlockInput & {
|
|
642
679
|
network: SuiNetworks;
|
|
643
|
-
suiClient: SuiClient;
|
|
680
|
+
suiClient: SuiClient$1;
|
|
644
681
|
account: WalletAccount;
|
|
645
682
|
appContext?: any;
|
|
646
683
|
}): Promise<{
|
|
@@ -653,7 +690,7 @@ interface IAppHelperInternalLegacy<T> {
|
|
|
653
690
|
txType: TransactionType;
|
|
654
691
|
txSubType: string;
|
|
655
692
|
intentionData: T;
|
|
656
|
-
suiClient: SuiClient;
|
|
693
|
+
suiClient: SuiClient$1;
|
|
657
694
|
account: WalletAccount;
|
|
658
695
|
}): Promise<TransactionBlock>;
|
|
659
696
|
}
|