Events and indexing
Vestige can run without an indexer, but events are the clean path to activity history, heir discovery, analytics, and support tooling.
Why index events
The current dApp reads a specific owner vault directly from the contract. That is enough for dashboard and manual claim flows. An indexer improves discovery: it can show all vaults created by an owner, all vaults where a wallet is heir, and all lifecycle events in one timeline.
- Build owner activity history.
- Find vaults by configured heir address.
- Detect claimed-but-not-disabled vaults.
- Show token deposit and claim timelines.
- Power support tooling without asking users to paste every transaction hash.
Event map
These events should be indexed first.
VaultCreated
Owner, heir, inactivity period, grace period, initial timestamp.
CheckedIn
Owner and refreshed timestamp.
USDCDeposited
Owner, amount, new native USDC balance.
USDCWithdrawn
Owner, amount, new native USDC balance.
TokenDeposited
Owner, token, amount, new token balance.
TokenWithdrawn
Owner, token, amount, new token balance.
InheritanceActivated
Owner, heir, activation timestamp.
InheritanceUSDCClaimed
Owner, heir, receiver, amount.
InheritanceTokenClaimed
Owner, token, heir, receiver, amount.
VaultDisabled
Owner and caller that performed cleanup.
Recommended index shape
A minimal indexer can store vault rows, event rows, and token balance snapshots.
VaultIndex { owner, heir, state, lastCheckIn, inactivityPeriod, gracePeriod, claimed, disabled }
VaultEvent { owner, type, txHash, blockNumber, timestamp, metadata }
TokenSnapshot { owner, token, balance, active }No-indexer mode
If no indexer exists, the dApp must ask for the owner address in heir flows. This is not a protocol limitation; it is a discovery limitation.
- Owner dashboard can read connected wallet directly.
- Heir page needs an owner address to inspect a vault.
- Token discovery uses getTrackedTokens(owner).
- Activity history is limited to what the frontend stores or what users inspect on ArcScan.
