aftermath-ts-sdk - v3.3.3
    Preparing search index...

    Type Alias ApiPerpetualsCreateVaultBody

    ApiPerpetualsCreateVaultBody: {
        coinMetadataId: ObjectId;
        collateralCoinType: CoinType;
        forceWithdrawDelayMs: bigint;
        isSponsoredTx?: boolean;
        lockPeriodMs: bigint;
        metadata: {
            curatorLogoUrl?: string;
            curatorName?: string;
            curatorUrl?: string;
            description: string;
            extraFields?: Record<string, string>;
            name: string;
        };
        performanceFeePercentage: Percentage;
        sponsor?: PerpetualsSponsorConfig;
        treasuryCapId: ObjectId;
        txKind?: SerializedTransaction;
        walletAddress: SuiAddress;
    } & (
        | { initialDepositAmount: Balance }
        | { initialDepositCoinArg: TransactionObjectArgument }
    )

    Request body for creating a new vault with initial deposit.

    The deposit can be specified either:

    • As a numeric initialDepositAmount, or
    • As an existing depositCoinArg (coin object).

    Type Declaration

    • coinMetadataId: ObjectId

      Object ID of the collateral coin metadata.

    • collateralCoinType: CoinType

      Move coin type used as collateral.

    • forceWithdrawDelayMs: bigint

      Delay before a force withdrawal can be processed, in milliseconds.

    • OptionalisSponsoredTx?: boolean

      Whether the transaction is sponsored rather than paid directly by the wallet.

    • lockPeriodMs: bigint

      Vault lock period in milliseconds.

    • metadata: {
          curatorLogoUrl?: string;
          curatorName?: string;
          curatorUrl?: string;
          description: string;
          extraFields?: Record<string, string>;
          name: string;
      }

      Metadata used to create the vault's LP asset.

      • OptionalcuratorLogoUrl?: string

        An image url for the Vault's curator. Ideally their logo.

      • OptionalcuratorName?: string

        The Vault curator's name.

      • OptionalcuratorUrl?: string

        A url for the Vault's curator. Ideally their website.

      • description: string

        A verbose description of the Vault.

      • OptionalextraFields?: Record<string, string>

        Extra / optional fields for future extensibility. Recommended keys include: twitter_url.

      • name: string

        A human-readable name for the Vault.

    • performanceFeePercentage: Percentage

      Vault performance fee percentage.

    • Optionalsponsor?: PerpetualsSponsorConfig

      Optional transaction sponsorship configuration.

    • treasuryCapId: ObjectId

      Treasury-cap object ID used to create the vault asset.

    • OptionaltxKind?: SerializedTransaction

      Serialized transaction kind sent to the service.

    • walletAddress: SuiAddress

      Wallet address used to identify the signer or owner.

    • { initialDepositAmount: Balance }
      • initialDepositAmount: Balance

        Initial deposit amount in collateral units.

    • { initialDepositCoinArg: TransactionObjectArgument }
      • initialDepositCoinArg: TransactionObjectArgument

        Coin argument containing the initial deposit.