Detailed Protocol Flows

1. Strategy Deployment Flow

Call Chain:

Registry.deploy(implementation, name, symbol, asset, assetDecimals, manager, initData)
  • Checks authorization

  • Deploys strategy using minimal proxy

  • Initializes strategy and tRWA token

  • Registers deployed strategy

State Changes:

  • Registry registers strategy

  • Strategy instance is initialized

  • Token and (optionally) escrow are deployed

Events:

  • Deploy(strategy, token, asset)

  • StrategyInitialized(admin, manager, asset, sToken)

  • SetReporter(reporter)


2. Standard Deposit Flow

Call Chain:

  • Calculates shares

  • Runs deposit hooks

  • Transfers assets via Conduit

  • Mints shares

State Changes:

  • totalSupply increases

  • Receiver's balance updated

  • Assets transferred

Events:

  • Deposit(sender, receiver, assets, shares)


3. Standard Withdrawal Flow

Call Chain:

  • Runs withdrawal hooks

  • Burns shares

  • Transfers assets

State Changes:

  • totalSupply decreases

  • Owner's balance updated

  • Assets transferred

Events:

  • Withdraw(sender, receiver, owner, assets, shares)

  • WithdrawalQueued(withdrawalId, owner, assets, shares) (if queued)


4. Two-Phase Deposit Flow (GatedMintRWA)

Deposit Request Phase:

  • Runs deposit hooks

  • Transfers assets to escrow

  • Emits DepositPending

Accept Flow:

  • Moves assets to strategy

  • Calls mintShares

  • Emits DepositAccepted

Reject Flow:

  • Returns assets to depositor

  • Emits DepositRefunded

Events:

  • DepositPending

  • DepositAccepted / BatchDepositsAccepted

  • DepositRefunded / BatchDepositsRefunded


5. KYC / Compliance Validation Flow

KYC Setup:

  • Modifies allowlist/denylist

Validation on Token Operations:

  • Runs hooks: onBeforeTransfer, onBeforeDeposit, onBeforeWithdraw

  • Checks sender/receiver permissions

Events:

  • AddressAllowed

  • AddressDenied

  • AddressRestrictionRemoved

Last updated