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.

The dynamic_fee_sharing program emits Anchor events through event CPI. Indexers should decode these events from Dynamic Fee Sharing program logs and join them with FeeVault account reads when current aggregate state is needed.

Events

EventFieldsEmitted byUse
EvtInitializeFeeVaultfee_vault, token_mint, owner, base, paramsinitialize_fee_vault, initialize_fee_vault_pdaIndex new fee vaults, token mints, owners, PDA bases, and configured user shares.
EvtFundFeesource_program, fee_vault, funded_amount, fee_per_share, payloadfund_fee, fund_by_claiming_feeTrack fee vault funding and the updated accumulated fee per share.
EvtClaimFeefee_vault, user, index, claimed_feeclaim_feeTrack user claims by configured user index.

Event Details

EvtInitializeFeeVault

FieldTypeNotes
fee_vaultPubkeyCreated fee vault account.
token_mintPubkeyMint accepted by the vault.
ownerPubkeyOwner recorded in the vault state.
basePubkeyPDA base for initialize_fee_vault_pda; default public key for non-PDA vaults.
paramsInitializeFeeVaultParametersIncludes reserved padding and configured UserShare[].

EvtFundFee

FieldTypeNotes
source_programPubkeyDefault public key for direct fund_fee; downstream program ID for fund_by_claiming_fee.
fee_vaultPubkeyFee vault that received credited fees.
funded_amountu64Raw token amount credited to share accounting. For Token 2022 transfer-fee mints, this excludes the transfer fee on direct funding.
fee_per_shareu128Vault’s accumulated Q64 fixed-point fee per share after funding.
payloadVec<u8>Empty for direct fund_fee; downstream instruction data for source-program funding.
fund_by_claiming_fee emits EvtFundFee only when the downstream invocation increases the fee vault token balance by more than zero.

EvtClaimFee

FieldTypeNotes
fee_vaultPubkeyFee vault being claimed from.
userPubkeyClaiming shareholder.
indexu8User index passed to claim_fee.
claimed_feeu64Raw token amount transferred to user_token_vault.
claim_fee emits EvtClaimFee only when the computed claim amount is greater than zero.

Indexing Notes

TopicNote
Event CPI accountsGenerated Anchor clients add event_authority and program accounts for all event-emitting instructions.
Amount precisionAmounts are raw token units. Apply mint decimals off-chain for display.
Direct fundingsource_program is the default public key and payload is empty.
Source-program fundingStore source_program and payload if you need to reconstruct which whitelisted DAMM v2 or DBC action funded the vault.
Current stateEvents are append-only. Read FeeVault for current total_funded_fee, fee_per_share, and per-user fee_claimed counters.