bitpro가 원문에서 글자만 모은 내용이에요. 표·그림·수식은 빠지거나 깨질 수 있어요. 전체 75쪽 중 67쪽
ate a fee vault for one token mint, configure a fixed list of recipients and shares, fund the vault, and let each recipient claim their share directly on-chain.
It is a distribution layer for splitting funded token balances across **2 to 5** configured recipient entries.
<Info>
Dynamic Fee Sharing runs on the mainnet program `dfsdo2UqvwfN8DuUVrMRNfQe11VaiNoKcMqLHVvDPzh`.
</Info>
## Why Dynamic Fee Sharing Exists
Many on-chain fee streams need to be split between a small group: creators, launchpads, protocol treasuries, strategy operators, partners, or contributors. Without a dedicated vault, teams often collect fees into one wallet and reconcile payouts manually.
Dynamic Fee Sharing moves that split into program state:
* The recipient addresses and share weights are stored in the fee vault.
* Fees are added to a program-controlled token vault.
* Each funding event increases cumulative `fee_per_share` accounting.
* Each recipient claims by index, and the program tracks that recipient's checkpoint.
## Core Features
<CardGroup>
<Card title="Fixed Share Splits" icon="chart-pie">
A vault stores 2 to 5 recipient entries, each with a wallet address, share amount, and claim checkpoint.
</Card>
<Card title="Self-Serve Claims" icon="hand-holding-dollar">
Recipients claim independently by signing with the wallet configured at their recipient index.
</Card>
<Card title="Two Funding Paths" icon="coins">
Vaults can be funded manually. PDA vaults can also fund through whitelisted DAMM v2 and Dynamic Bonding Curve claim actions.
</Card>
<Card title="Token Support" icon="certificate">
Vaults support standard SPL Token mints and Token 2022 mints that only use supported extensions.
</Card>
</CardGroup>
## How Dynamic Fee Sharing Works
The program has three main concepts.
| Component | What It Stores |
| - | - |
| Fee vault | Owner field, token mint, token vault, vault type, base account, total shares, total funded fees, cumulative fee per share, and up to 5 user entries. |
| Token vault | The program-controlled token account that holds funded tokens before claims. |
| User entry | A recipient address, share amount, total fee claimed, and fee-per-share checkpoint. |
A vault lifecycle is short:
```text theme={"system"}
Initialize a fee vault for one token mint
|
Store 2-5 user entries and non-zero shares
|
Fund the token vault manually or through a supported claim action
|
Recipients claim by index with their configured wallet
```
## Fee Vault Types
Dynamic Fee Sharing supports two fee vault types. Both use the same share and claim accounting after initialization.
| Vault Type | How It Is Used |
| - | - |
| Non-PDA fee vault | A standalone vault initialized from an externally generated signer account. Best for manual funding. |
| PDA fee vault | A deterministic vault derived from `["fee_vault", base, token_mint]`. Required for whitelisted claim-by-integration funding. |
## Important Constraints
| Constraint | Program Behavior |
| - | - |
| Recipient entries | Minimum `2`, maximum `5`. |
| Shares | Each share must be greater than `0`. |
| Recipient addresses | Each address must be non-default. The program does not reject duplicate addresses. |
| Token mint | One token mint per vault. |
| Updates | The current program exposes no general instruction to edit recipients, edit shares, withdraw admin funds, or close a vault. |
| Owner field | `owner` is stored and emitted, but current instructions do not use it as an admin authority. |
| Claim authorization | A claim succeeds only when the signer matches the user entry at the provided index. |
<Warning>
Treat the initialized recipient list and shares as permanent for that fee vault. If a split changes, create a new vault for the new arrangement.
</Warning>
## What To Read Next
<CardGroup>
<Card title="Dynamic Fee Sharing Design Guide" href="/helper-products/dynamic-fee-sharing/design-guide" icon="sliders">
Choose the recipient set, shares, token mint, vault type, and funding path before initialization.
</Card>
<Card title="Dynamic Fee Sharing Compatibilities" href="/helper-products/dynamic-fee-sharing/compatibilities" icon="plug">
Review token support, vault types, source programs, and whitelisted claim actions.
</Card>
</CardGroup>
<CardGroup>
<Card title="Dynamic Fee Sharing Formulas" href="/helper-products/dynamic-fee-sharing/formulas" icon="calculator">
Understand fee-per-share accounting, fixed-point precision, rounding, and Token 2022 transfer-fee behavior.
</Card>
</CardGroup>
## Who Dynamic Fee Sharing Is For
<AccordionGroup>
<Accordion title="Protocol teams">
Protocol teams can route revenue into a fee vault and distribute it to contributors, treasuries, integrations, or strategic partners without manual payout operations.
</Accordion>
<Accordion title="Launchpads and creators">
Launchpads and creators can use Dynamic Fee Sharing to split eligible launch revenue between creator, partner, protocol, or campaign wallets.
</Accordion>
<Accordion title="Ecosystem partners">
Partners can receive their share directly from a vault instead of waiting for a centralized operator to reconcile and send payouts.
</Accordion>
<Accordion title="Integrators and dashboards">
Integrators can track funded fees, claim events, recipient allocations, and vault balances as a clear on-chain revenue stream.
</Accordion>
</AccordionGroup>
## What Dynamic Fee Sharing Is Best For
Dynamic Fee Sharing is best when a single supported token needs to be split between a small, known, stable recipient set.
Good use cases include:
* Creator and launchpad fee sharing.
* Treasury-funded partner splits.
* DAMM v2 fee or reward sharing through supported claim actions.
* Dynamic Bonding Curve creator, partner, trading-fee, or migration-fee sharing through supported claim actions.
* Campaign or contributor revenue splits where the recipient set is fixed.
# Presale Vault Access and States
Source: https://docs.meteora.ag/helper-products/presale-vault/access-and-states
Review Presale Vault accounts, access models, escrow creation paths, operator permissions, Merkle roots, lifecycle gates, and close conditions.
Presale Vault uses a small set of program accounts to separate sale configuration, participant state, allowlist data, and token custody. This page is a program-level map for integrators who need to understand which account owns which responsibility.
## Core Accounts
| Account | What It Stores |
| - | - |
| `Presale` | Sale owner, base mint, quote mint, token vaults, mode, whitelist mode, caps, timing, vesting, total deposits, fees, claim totals, token program flags, registries, and one-time lifecycle flags. |
| `PresaleRegistry` | Per-registry supply, total deposits, escrow count, claimed and refunded totals, buyer deposit range, and deposit fee bps. Registries are stored inside the `Presale` account. |
| `Escrow` | A buyer's position: owner, registry index, net deposit, deposit fee, personal cap, pending claim amount, claimed amount, remaining-quote withdrawal flag, and timestamps. |
| `FixedPricePresaleExtraArgs` | Fixed Price extra params: `q_price`, owner, presale, and whether buyer withdrawals are disabled. |
| `Operator` | Permissioned authority mapping between a creator and an operator owner. |
| `MerkleRootConfig` | Merkle root, presale, and version for permissioned Merkle-proof escrows. |
| `PermissionedServerMetadata` | Optional server URL for retrieving Merkle proofs or authority-mode transaction data off-chain. |
The base-token and quote-token vaults are token accounts controlled by the program's presale authority PDA. The program checks that vault and mint accounts match the `Presale` state before moving tokens.
## Access Models
Presale Vault supports three whitelist modes.
### Permissionless
Permissionless sales let anyone create an escrow while the sale is ongoing. The escrow uses the default registry index `0`, and the escrow's personal cap defaults to the registry's buyer maximum.
### Permission with Authority
Authority-mode sales require an `Operator` account. The operator owner signs escrow creation, and the operator must belong to the presale creator. The escrow creation instruction assigns:
* buyer wallet
* registry index
* personal deposit cap
Operator accounts are scoped by creator and operator owner, not by a single presale. The creator can revoke an operator account, which closes it back to the creator.
### Permission with Merkle Proof
Merkle-mode sales require a `MerkleRootConfig`. The buyer provides a proof for a leaf containing:
* buyer wallet
* registry index
* personal deposit cap
The Merkle root config is created by the presale owner while the sale is not started or ongoing, and only for presales using the Merkle whitelist mode. Root configs are versioned, so a creator can publish a new version if the allowlist data changes.
<Note>
The program validates the proof and cap data on-chain, but it does not prevent the same wallet from appearing in multiple registries. Creators and launchpads should prevent unintended duplicate eligibility off-chain.
</Note>
## Permissioned Server Metadata
For permissioned sales, the creator can publish an optional `PermissionedServerMetadata` account with a server URL. The URL can point users to Merkle proofs or authority-mode transaction data.
This account is only allowed for permissioned whitelist modes and can be created while the sale is not started or ongoing. The creator can close it in any sale state.
## Lifecycle Gates
| Action | Gate |
| - | - |
| Initialize presale | Params, token support, registries, mode-specific rules, and base-token funding must validate. |
| Create escrow | Sale must be ongoing. Whitelist mode and registry index must match the selected creation path. |
| Deposit | Sale must be ongoing. Deposit is capped by the mode, registry, personal cap, and fixed-price supply where applicable. |
| Withdraw during sale | Sale must be ongoing. Pro Rata allows withdrawals, FCFS disallows them, and Fixed Price depends on `disable_withdraw`. |
| Claim | Sale must be completed. The claim amount is cumulative and subtracts already claimed and pending amounts. |
| Withdraw remaining quote | Allowed after failed sales, or after completed Pro Rata sales for overflow quote. Each escrow can do this once. |
| Creator withdraw | Allowed after completed or failed sales. The creator can withdraw once. |
| Collect deposit fee | Allowed only after completed sales, and only once. |
| Perform unsold base-token action | Allowed only after completed sales, only if unsold base tokens exist, and only once. |
## Creator Settlement
After a completed sale, the creator can withdraw raised quote token once. The withdrawal is capped by the sale's maximum cap, which is especially important for oversubscribed Pro Rata sales.
After a failed sale, the creator can withdraw the base-token supply instead.
Deposit fees are collected separately. In Fixed Price and FCFS, the creator can collect total deposit fees after completion. In Pro Rata, the collectible fee excludes the fee attributed to overflow quote that buyers can refund. See [Presale Vault Formulas](/helper-products/presale-vault/formulas) for the exact withdrawal and fee formulas.
## Close Conditions
Escrow accounts can only be closed once they have no remaining economic claim:
* during an ongoing sale, the escrow must have zero deposit and zero deposit fee
* after a failed sale, the escrow must have withdrawn remaining quote, unless it has zero deposit and zero fee
* after a completed sale, refundable quote must be withdrawn when applicable, and all tokens claimable through the vesting end must be claimed
Merkle root configs can be closed by the creator when the presale is not ongoing. Fixed-price extra params can be closed by their owner. Permissioned server metadata can be closed by the presale owner in any sale state.
# Presale Vault Configuration Guide
Source: https://docs.meteora.ag/helper-products/presale-vault/configuration-guide
The main decisions and constraints to check before creating a Presale Vault.
Use this guide before creating a vault. It focuses on configuration choices that are enforced by the program, plus the product decisions that should be communicated to buyers.
# 1. Choose the sale mode
## Fixed Price
Use Fixed Price when buyers need a known price before depositing.
You must also create fixed-price extra params with:
* `q_price` in Q64.64 format
* `disable_withdraw` as true or false
Fixed Price is sensitive to integer rounding. Make sure the chosen price, cap, and supply can produce the intended sale outcome in smallest token units.
## FCFS
Use FCFS when deposits should stop at the maximum cap and buyers should be committed once they deposit.
If early completion is enabled, reaching the maximum cap moves the sale end time to the current timestamp. This also recalculates vesting times from the new end time.
## Pro Rata
Use Pro Rata when the sale may be oversubscribed and buyers should receive proportional allocation with proportional overflow refunds.
Pro Rata deposits can exceed the maximum cap, so buyer caps and allowlist design matter more.
# 2. Pick supported tokens
The base and quote mints can be standard SPL Token mints or supported Token-2022 mints. If either mint uses Token-2022 extensions, review [Token 2022 Support](/helper-products/presale-vault/token-2022-support) before launch so the UI and transaction builder handle transfer fees, transfer hooks, and memo requirements correctly.
# 3. Set sale timing
| Timing setting | Requirement |
| - | - |
| Start time | cannot be more than 30 days after initialization |
| End time | must be after the effective start time |
| Sale duration | 60 seconds to 30 days |
The effective start time is the later of the requested start time and the current timestamp.
# 4. Set raise caps
The minimum cap must be greater than zero, and the maximum cap must be at least the minimum cap.
For Fixed Price, the program also checks that:
* the maximum cap can be fulfilled by the configured base supply
* the minimum and maximum caps correspond to different bought base-token amounts
# 5. Design registries
A vault must have 1 to 5 registries. Each registry has:
* base-token supply
* buyer minimum deposit cap
* buyer maximum deposit cap
* deposit fee bps
Registry supply must be greater than zero, and the sum of registry supplies must fit in `u64`.
Registry deposit fee cannot exceed 5,000 bps.
## Permissionless registries
Permissionless mode uses registry index `0`. Buyers create their own escrow in that registry.
## Permissioned registries
Multiple registries require a permissioned mode.
For permissioned sales, the program uses the escrow's personal deposit cap to control each buyer. The registry-level cap range has mode-specific constraints:
| Mode | Permissioned registry cap constraint |
| - | - |
| Fixed Price | minimum must equal the quote amount needed to buy at least one base unit; maximum must equal `presale_maximum_cap` |
| FCFS | minimum must be `1`; maximum must equal `presale_maximum_cap` |
| Pro Rata | minimum must be `1`; maximum must equal `presale_maximum_cap` |
The personal cap supplied during escrow creation must be within the registry range.
# 6. Choose the whitelist mode
Choose the whitelist mode based on who should be able to create buyer escrows:
| Whitelist mode | Use when |
| - | - |
| Permissionless | Anyone should be able to participate through the default registry. |
| Permission with authority | A creator-approved operator should assign buyer escrows, registries, and personal caps. |
| Permission with Merkle proof | Buyers should prove allowlist eligibility on-chain using wallet, registry, and personal cap data. |
See [Access and States](/helper-products/presale-vault/access-and-states) for the escrow creation paths, operator rules, Merkle root accounts, and close conditions.
# 7. Configure deposit fees
Deposit fees are set per registry in bps and charged on top of the net deposit used for allocation.
The program rounds the gross amount up so the requested net deposit is preserved:
```math theme={"system"}
\text{gross} =
\left\lceil
\frac{\text{net\_deposit} \times 10{,}000}
{10{,}000 - \text{fee\_bps}}
\right\rceil
```
In Pro Rata, fee on overflow quote is refundable and is excluded from the creator's collectible fee.
# 8. Configure unlocks
If no lock and vesting params are provided, sold tokens are claimable after the sale completes with no additional lock or drip schedule.
If lock and vesting params are provided:
* immediate release bps must be at most 10,000
* lock duration plus vest duration must be less than 10 years
* if immediate release is 10,000 bps, lock and vest duration must both be zero
* if immediate release is below 10,000 bps, at least one of lock duration or vest duration must be greater than zero
* if immediate release timestamp is set and immediate release bps is greater than zero, it must be between the sale end and vesting end
* if immediate release bps is zero and immediate release timestamp is set, it must equal the sale end
When early completion changes the sale end time, vesting start and end are recalculated from the new end time. The immediate release timestamp preserves its offset from the previous end time.
# 9. Choose unsold base-token action
The unsold action is either:
* **Refund**: return unsold base tokens to the creator
* **Burn**: burn unsold base tokens from the vault
The action is only available after a completed sale, only if there are unsold tokens, and only once.
# 10. Pre-launch checklist
* Base and quote mints use supported token programs and extensions.
* Sale start, end, and duration satisfy the program limits.
* Minimum and maximum caps are intentional and valid.
* Fixed-price `q_price` has been tested in smallest units, if using Fixed Price.
* Registry count, supplies, fee bps, and cap ranges are valid for the selected whitelist mode.
* Permissioned allowlist data includes wallet, registry index, and personal cap.
* Token-2022 transfer hook accounts can be provided where needed.
* Buyer-facing docs explain whether deposits can be withdrawn during the sale.
* Buyer-facing docs explain claim timing and vesting.
* The team has a post-sale plan for creator withdrawal, fee collection, unsold tokens, and liquidity.
# Presale Vault Formulas
Source: https://docs.meteora.ag/helper-products/presale-vault/formulas
The main Presale Vault formulas for fixed-price sales, dynamic allocation, fees, refunds, and vesting.
Presale Vault performs calculations in smallest token units. Display decimals are a UI concern; on-chain math uses integer arithmetic, checked overflow handling, and deterministic rounding.
# Constants
```math theme={"system"}
\text{BPS\_DENOMINATOR} = 10{,}000
```
```math theme={"system"}
\text{Q64\_SCALE} = 2^{64}
```
Deposit fee bps are capped at `5,000`. Immediate release bps are capped at `10,000`.
# Sale success
A sale is completed when the current timestamp is at or after `presale_end_time` and total net deposits meet the minimum cap:
```math theme={"system"}
\text{completed} = \text{total\_deposit} \ge \text{presale\_minimum\_cap}
```
If total deposits are below the minimum cap after the sale ends, the sale is failed.
# Deposit fee
The deposit amount tracked for allocation excludes the deposit fee. If a buyer deposits a net amount `D` into a registry with fee rate `f` bps, the gross amount required before Token-2022 transfer fees is rounded up:
```math theme={"system"}
\text{gross} =
\left\lceil
\frac{D \times 10{,}000}{10{,}000 - f}
\right\rceil
```
```math theme={"system"}
\text{deposit\_fee} = \text{gross} - D
```
The fee is tracked separately on the escrow, registry, and presale. In Pro Rata, the fee attributable to refunded overflow quote is refundable.
# Fixed Price
Fixed Price mode stores `q_price` as a Q64.6프로젝트로 돌아가기