UNPKG

aftermath-ts-sdk

Version:
93 lines 3.58 kB
import { AftermathApi } from "../../../general/providers/aftermathApi"; import { NftAmmInterfaceGenericTypes, NftAmmMarketObject } from "../nftAmmTypes"; import { NftAmmMarket } from "../nftAmmMarket"; import { Balance, DynamicFieldObjectsWithCursor, Nft, NftAmmAddresses, ObjectId, Slippage, SuiAddress } from "../../../types"; import { TransactionArgument, Transaction } from "@mysten/sui/transactions"; export declare class NftAmmApi { private readonly Provider; private static readonly constants; readonly addresses: NftAmmAddresses; constructor(Provider: AftermathApi); fetchNftsInMarketTable: (inputs: { marketTableObjectId: ObjectId; cursor?: ObjectId; limit?: number; }) => Promise<DynamicFieldObjectsWithCursor<Nft>>; fetchMarket: (inputs: { objectId: ObjectId; }) => Promise<NftAmmMarketObject>; fetchMarkets: (inputs: { objectIds: ObjectId[]; }) => Promise<NftAmmMarketObject[]>; fetchBuildBuyTx: (inputs: { market: NftAmmMarket; walletAddress: SuiAddress; nftObjectIds: ObjectId[]; slippage: Slippage; referrer?: SuiAddress; }) => Promise<Transaction>; fetchBuildSellTx: (inputs: { market: NftAmmMarket; walletAddress: SuiAddress; nftObjectIds: ObjectId[]; slippage: Slippage; referrer?: SuiAddress; }) => Promise<Transaction>; fetchBuildDepositTx: (inputs: { market: NftAmmMarket; walletAddress: SuiAddress; assetCoinAmountIn: Balance; nfts: (ObjectId | TransactionArgument)[]; slippage: Slippage; referrer?: SuiAddress; }) => Promise<Transaction>; fetchBuildWithdrawTx: (inputs: { market: NftAmmMarket; walletAddress: SuiAddress; lpCoinAmount: Balance; nftObjectIds: ObjectId[]; slippage: Slippage; referrer?: SuiAddress; }) => Promise<Transaction>; buyTx: (inputs: { tx: Transaction; marketObjectId: ObjectId; assetCoin: ObjectId | TransactionArgument; nftObjectIds: ObjectId[]; expectedAssetCoinAmountIn: Balance; genericTypes: NftAmmInterfaceGenericTypes; slippage: Slippage; withTransfer?: boolean; }) => import("@mysten/sui/transactions").TransactionResult; sellTx: (inputs: { tx: Transaction; marketObjectId: ObjectId; nfts: (ObjectId | TransactionArgument)[]; expectedAssetCoinAmountOut: Balance; genericTypes: NftAmmInterfaceGenericTypes; slippage: Slippage; withTransfer?: boolean; }) => import("@mysten/sui/transactions").TransactionResult; depositTx: (inputs: { tx: Transaction; marketObjectId: ObjectId; assetCoin: ObjectId | TransactionArgument; nfts: (ObjectId | TransactionArgument)[]; expectedLpRatio: bigint; genericTypes: NftAmmInterfaceGenericTypes; slippage: Slippage; withTransfer?: boolean; }) => import("@mysten/sui/transactions").TransactionResult; addWithdrawCommandToTransaction: (inputs: { tx: Transaction; marketObjectId: ObjectId; lpCoin: ObjectId | TransactionArgument; nftObjectIds: ObjectId[]; expectedAssetCoinAmountOut: Balance; genericTypes: NftAmmInterfaceGenericTypes; slippage: Slippage; withTransfer?: boolean; }) => import("@mysten/sui/transactions").TransactionResult; private static genericTypesForMarket; } //# sourceMappingURL=nftAmmApi.d.ts.map