Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.meteora.ag/llms.txt

Use this file to discover all available pages before exploring further.

Presale Vault can use standard SPL Token mints or supported Token-2022 mints for both the base token being sold and the quote token buyers deposit. Unlike DLMM, Presale Vault does not use a token-badge review path in this program. A Token-2022 mint must use only the extensions accepted by the presale program.

Supported Mints

Presale Vault accepts:
  • standard SPL Token mints
  • Token-2022 mints with only supported mint extensions
The Token-2022 native mint is rejected.

Supported Token-2022 Extensions

If a base or quote mint is Token-2022, the program currently accepts only these mint extensions:
  • TransferFeeConfig
  • MetadataPointer
  • TokenMetadata
  • TransferHook
Any other Token-2022 mint extension fails validation with UnsupportedToken2022MintOrExtension.
Transfer hooks are supported by passing the hook accounts required by the hook program. Presale Vault does not require the transfer hook program or authority to be revoked.

Transfer Fees

Presale Vault accounts for Token-2022 transfer fees when moving tokens.

Deposits

When a buyer deposits a quote token with transfer fees, the program calculates the transfer-fee-included amount needed for the intended net deposit and registry deposit fee. The escrow and presale state track the net deposit used for allocation, while the buyer may transfer more than the net amount because of Token-2022 transfer fees.

Claims and withdrawals

When tokens move from the presale vault to a user, the transfer amount may be reduced by the token’s transfer fee. Events report transfer-fee-excluded amounts where applicable. This affects:
  • buyer withdrawals during the sale
  • failed-sale quote refunds
  • Pro Rata overflow quote refunds
  • base-token claims
  • creator withdrawals
  • deposit-fee collection
  • unsold base-token refunds

100% transfer-fee edge case

If a Token-2022 mint has a 100% transfer fee, the program uses the mint’s maximum fee when calculating the inverse transfer fee needed for deposits. If that addition overflows, the instruction fails.

Transfer Hooks

If the base or quote mint has a Transfer Hook extension, instructions that transfer that token must pass the required remaining accounts for the hook program. The program separates hook account slices by token side:
Accounts typeUsed for
TransferHookBaseBase-token transfers, such as initialization funding, claims, failed creator withdrawal, and unsold base-token refunds.
TransferHookQuoteQuote-token transfers, such as deposits, buyer quote withdrawals, Pro Rata refunds, creator quote withdrawal, and fee collection.
If a transfer hook exists and the required accounts are missing, the instruction fails. If hook accounts are supplied for a mint without a transfer hook, the instruction also fails.

Memo Transfer

MemoTransfer is an account-level Token-2022 extension, not a mint extension. Presale Vault checks destination token accounts when the program transfers tokens out of the vault. If the destination account requires incoming transfer memos, the program builds a memo with:
Presale
This applies to transfers from the presale vault to users or creator-controlled accounts. User-to-vault transfers do not include a memo context.

Initialization Funding

At initialization, the creator funds the base-token vault with the sum of all registry supplies. If the base mint has a transfer fee, the creator may need to transfer a transfer-fee-included amount so the vault receives the intended base supply. The same transfer-hook rules apply if the base mint uses Transfer Hook.

Integration Checklist

  • Confirm both base and quote mints are either SPL Token mints or supported Token-2022 mints.
  • Reject unsupported Token-2022 extensions before showing a launch flow.
  • Include transfer hook remaining accounts for every instruction that transfers a hook-enabled mint.
  • Display net deposit separately from registry deposit fee and Token-2022 transfer fee.
  • Explain to buyers that transfer-fee tokens may deliver less on claims or refunds.
  • Ensure destination token accounts can receive memo-bearing transfers when MemoTransfer is enabled.