Files
proxmox/docs/11-references/DEX_AND_CROSS_CHAIN_CONTRACTS_NEEDED.md
defiQUG dbd517b279 Sync workspace: config, docs, scripts, CI, operator rules, and submodule pointers.
- Update dbis_core, cross-chain-pmm-lps, explorer-monorepo, metamask-integration, pr-workspace/chains
- Omit embedded publish git dirs and empty placeholders from index

Made-with: Cursor
2026-04-12 06:12:20 -07:00

8.4 KiB
Raw Blame History

DEX, Liquidity Pools, and Cross-Chain Contracts — Whats Deployed vs Needed

Purpose: Answer what contracts (and code) are needed beyond current deployments for full Dodo PMM, Uniswap, cross-chain liquidity pools, multi-token multi-chain routing, and atomic swaps. Also clarify TransactionMirror deployment status.

Related: ADDRESS_MATRIX_AND_STATUS | CONTRACTS_TO_DEPLOY | CONTRACT_DEPLOYMENT_RUNBOOK | PLACEHOLDERS_AND_TBD | OPERATOR_OPTIONAL_CHECKLIST §6


1. TransactionMirror — Deployment Status

Chain Status Address Notes
Ethereum Mainnet Deployed 0x4CF42c4F1dBa748601b8938be3E7ABD732E87cE9 Receives mirrored Chain 138 transactions from the Transaction Mirroring Service. Frontend-dapp uses this address. Etherscan verification may still be pending (see docs/06-besu/TRANSACTIONMIRROR_VERIFICATION_STATUS.md).
Chain 138 Deployed 0x7131F887DBEEb2e44c1Ed267D2A68b5b83285afc Live on Chain 138. Set TRANSACTION_MIRROR_ADDRESS in smom-dbis-138/.env for services that consume it.

Conclusion: TransactionMirror is deployed on both Ethereum Mainnet and Chain 138.


2. Currently Deployed (Relevant to DEX / Routing / Cross-Chain)

  • Chain 138: CCIP bridges (CCIPWETH9/10), UniversalCCIPBridge, BridgeOrchestrator, AlltraAdapter, Lockbox138 (trustless), PaymentChannelManager, GenericStateChannelManager, AddressMapper, MirrorManager, Vault/Reserve system, MerchantSettlementRegistry, WithdrawalEscrow, phased core, CREATE2 deterministic set, DODOPMMIntegration (0x86ADA6Ef91A3B450F89f2b751e93B1b7A3218895) and DODOPMMProvider (0x3f729632E9553EBacCdE2e9b4c8F2B285b014F2e) on the canonical official DODO V2 DVM-backed stack. See CONTRACT_ADDRESSES_REFERENCE and ADDRESS_MATRIX_AND_STATUS.
  • alltra-lifi-settlement: MerchantSettlementRegistry, WithdrawalEscrow (Chain 138).

3. Contracts and Code Still Needed for Full DEX / Liquidity / Routing

3.1 Dodo PMM

Item Location Status Whats needed
DODOPMMIntegration smom-dbis-138/contracts/dex/DODOPMMIntegration.sol Deployed (Chain 138: 0x86ADA6Ef91A3B450F89f2b751e93B1b7A3218895) Canonical official DODO V2 DVM-backed integration. See PMM_DEX_ROUTING_STATUS, DODO_PMM_INTEGRATION.
DODOPMMProvider smom-dbis-138/contracts/liquidity/providers/DODOPMMProvider.sol Deployed (Chain 138: 0x3f729632E9553EBacCdE2e9b4c8F2B285b014F2e) Canonical provider with the three public stable pools registered.
Test test/dex/DODOPMMIntegration.t.sol.bak Renamed to .bak Restore/fix and re-enable when DODO integration is active (mockCall ambiguity was reason for .bak).

3.2 Uniswap / Balancer / EnhancedSwapRouter

Item Location Status Whats needed
EnhancedSwapRouterV2 + venue adapters smom-dbis-138/contracts/bridge/trustless/EnhancedSwapRouterV2.sol and contracts/bridge/trustless/adapters/ Live on Chain 138 Router-v2 plus executor adapters are deployed, and pilot-compatible Uniswap_v3, Balancer, Curve_3, and 1inch venues are funded and planner-visible. Keep bash scripts/verify/check-chain138-pilot-dex-venues.sh green after venue/publication changes.
Uniswap/Curve services alltra-lifi-settlement/src/payments/uniswap/uniswap.service.ts, curve.service.ts Stubs Service-layer adoption remains optional even though the pilot-compatible Chain 138 venue layer is live. See TEZOS_CCIP_REMAINING_ITEMS §8.

3.3 Full Trustless Bridge Stack (Cross-Chain Liquidity / Atomic Swaps)

Lockbox138 is deployed on Chain 138. The rest of the trustless stack is not deployed (placeholders in config when needed):

Contract Script Purpose
InboxETH script/bridge/trustless/DeployTrustlessBridge.s.sol (or DeployCompleteSystem) Inbox for cross-chain messages
BondManager same Bond management
ChallengeManager same Fraud proofs / challenges
LiquidityPoolETH same Liquidity pool for bridge
SwapRouter contracts/bridge/trustless/SwapRouter.sol Swap routing
SwapBridgeSwapCoordinator / BridgeSwapCoordinator DeploySwapBridgeSwapCoordinator.s.sol, etc. Coordinates swap + bridge for atomic flows
MULTISIG (config) Admin / relayer multisig

See ADDRESS_MATRIX_AND_STATUS §4: “INBOX_ETH, BOND_MANAGER, CHALLENGE_MANAGER, LIQUIDITY_POOL, SWAP_ROUTER, BRIDGE_SWAP_COORDINATOR, MULTISIG — still placeholders in config when needed.”

3.4 Multi-Token Multi-Chain Routing (Off-Chain / Services)

Component Location Status Whats needed
LiFi alltra-lifi-settlement Used Route building; ensure 138/651940/42793 supported in chains config.
Jumper alltra-lifi-settlement Stub Implement real API when Jumper supports 138, 651940, 42793. See TEZOS_CCIP_REMAINING_ITEMS §4.
Quote service smom-dbis-138 orchestration FABRIC_CHAIN_ID=999 placeholder Set real Fabric chain ID when Fabric is live.
Token Aggregation API smom-dbis-138/services/token-aggregation Deployed Serves canonical tokens and report endpoints; DEX factory config (Uniswap V2/V3, DODO) per chain when pools exist.

3.5 Other Contracts (Optional / When Needed)

  • PaymentChannelManager / GenericStateChannelManager: Deployed on Chain 138.
  • Trustless bridge (mainnet side): Deploy from script/bridge/trustless/ for mainnet; document addresses per chain.
  • eMoney / smart accounts: script/emoney/, script/smart-accounts/ — deploy when those features are required.

4. Summary Table — “Whats Needed” for Full Capability

Capability Deployed Still needed
Cross-chain bridge (CCIP) CCIP WETH9/10, UniversalCCIPBridge, AlltraAdapter
TransactionMirror Mainnet (0x4CF42...); optional on 138 Chain 138: run deploy script if needed; Mainnet: confirm Etherscan verification
Dodo PMM liquidity Canonical official DODO V2 DVM-backed integration/provider deployed; three stable pools funded Decide legacy XAU/private pool posture; keep router-v2 venue verification current
Uniswap/Balancer/Curve/1inch swaps Pilot-compatible venues live on Chain 138 and wired into router-v2 Upstream-native protocol deployments remain optional future work; current live path is the funded Chain 138 pilot venue layer. For the Uniswap-native replacement track, use CHAIN138_UNISWAP_V3_UPSTREAM_NATIVE_RUNBOOK and bash scripts/verify/check-chain138-uniswap-v3-upstream-native-readiness.sh.
Full trustless atomic swap Lockbox138 InboxETH, BondManager, ChallengeManager, LiquidityPoolETH, SwapRouter, BridgeSwapCoordinator, MULTISIG
Multi-chain routing LiFi (and config) Jumper API when supported; Curve/Uniswap stubs when pools exist; quote service Fabric chainId

5. Commands and References

  • Deploy TransactionMirror (Chain 138): ./scripts/deployment/deploy-transaction-mirror-chain138.sh (then set TRANSACTION_MIRROR_ADDRESS in .env). See CONTRACT_DEPLOYMENT_RUNBOOK § TransactionMirror.
  • Router-v2 / venue verification: bash scripts/verify/check-chain138-pilot-dex-venues.sh — proves the funded pilot-compatible Uniswap_v3, Balancer, Curve_3, and 1inch venues are bytecode-present, funded, and publicly routable on Chain 138.
  • On-chain check (88 addresses): ./scripts/verify/check-contracts-on-chain-138.sh [RPC_URL] — current canonical count includes TransactionMirror, the canonical stable PMM stack, ISO20022Router, the cross-chain flash trio, the deployed GRU USD V2 addresses, router-v2 execution stack, the upstream-native Uniswap v3 stack, and the remaining funded pilot-compatible venue layer.