yi3ld is a mobile banking application that brings DeFi yields to everyday checking accounts. Unlike traditional banks that pay 0% interest, yi3ld enables users to earn 3-10% APY on their deposits through automated stablecoin lending on AAVE and Kamino liquidity pools, while maintaining full liquidity, instant withdrawals, and supporting cross-border fiat payments.
$18 trillion sits in U.S. checking accounts earning 0% interest while inflation erodes purchasing power at approximately 3% annually. Traditional savings accounts offer negligible yields, and international transfers remain expensive and slow.
yi3ld combines the convenience of traditional banking with the power of decentralized finance through:
- Earning 3-10% APY on deposits through DeFi protocols
- Instant liquidity with no lock-up periods
- International transfers in 3 seconds via XRP Ledger
- Full transparency with on-chain verification
- Clean, minimalist mobile interface
The application consists of three main layers:
Presentation Layer (React Native)
- Waiting Room for fiat currency storage
- Yielding Accounts for USDC-backed yield generation
- International transfer interface
Backend Layer (Firebase)
- User authentication via phone numbers
- Account metadata and balance tracking
- Transaction history
- Real-time synchronization with blockchain
Blockchain Layer
- Aave V3 for yield generation
- Base Sepolia testnet for low-cost transactions
- USDC stablecoin for deposits
- XRP Ledger for cross-border payments
Deposit to Yield:
- User deposits fiat to Waiting Room (stored in Firebase)
- User transfers to Yielding Account
- System converts to USDC
- Deposits USDC to Aave V3
- User earns APY automatically
- Balance syncs from blockchain every 5 minutes
International Transfer:
- Sender initiates transfer in local currency
- System queries exchange rate
- Executes transfer via XRP Ledger
- Recipient receives in their local currency
- Settlement completes in 3-5 seconds
- React Native with Expo
- TypeScript for type safety
- React Navigation for routing
- Expo Vector Icons for UI elements
- Firebase Authentication (Phone + SMS)
- Cloud Firestore for data storage
- Firebase Storage for encrypted keys
- Ethers.js v6 for Ethereum interactions
- Aave V3 protocol for yield
- Base Sepolia testnet
- USDC stablecoin
- XRP Ledger for cross-border payments
- ethers - Blockchain interactions
- firebase - Backend services
- react-native-get-random-values - Cryptographic polyfill
- @ethersproject/shims - Ethers.js compatibility
- @react-native-async-storage/async-storage - Persistent storage
- expo-firebase-recaptcha - SMS verification
yi3ld/
├── src/
│ ├── components/
│ │ ├── Logo.tsx
│ │ └── WalletInfo.tsx
│ ├── screens/
│ │ ├── auth/
│ │ │ ├── PhoneAuthScreen.tsx
│ │ │ ├── VerifyCodeScreen.tsx
│ │ │ └── ProfileInputScreen.tsx
│ │ └── main/
│ │ ├── DashboardScreen.tsx
│ │ ├── DepositScreen.tsx
│ │ ├── ProfileScreen.tsx
│ │ ├── OpenAccountScreen.tsx
│ │ ├── SendMoneyScreen.tsx
│ │ ├── SendToYieldAccountScreen.tsx
│ │ └── DevFundingScreen.tsx
│ ├── services/
│ │ ├── auth.ts
│ │ ├── accounts.ts
│ │ ├── wallet.ts
│ │ ├── aave.ts
│ │ ├── xrpl.ts
│ │ ├── transfer.ts
│ │ ├── internationalTransfer.ts
│ │ └── yieldTransfer.ts
│ ├── navigation/
│ │ ├── AppNavigator.tsx
│ │ ├── AuthNavigator.tsx
│ │ ├── MainNavigator.tsx
│ │ └── types.ts
│ ├── context/
│ │ └── AuthContext.tsx
│ ├── hooks/
│ │ └── useAuth.ts
│ └── utils/
│ ├── countries.ts
│ ├── yieldPools.ts
│ └── utilFunctions.ts
├── FirebaseConfig.ts
├── App.tsx
├── package.json
└── .env
Users select from three risk-reward profiles
A fiat currency holding account with zero yield that serves as an intermediary between traditional banking and DeFi. Supports USD, GBP, EUR, CAD, MXN, RUB, CNY, BRL, and AED.
Each user receives one Ethereum wallet upon creating their first yielding account. All yielding accounts for that user share the same wallet address, with Firebase tracking logical ownership of funds.
Send money across borders using XRP Ledger technology:
- Settlement time: 3 seconds
- Transaction fee: $0.00001
- Automatic currency conversion
- Transparent exchange rates
Transfer funds directly between yielding accounts. If the recipient does not have a matching account type, the system automatically creates one for them.
Account balances automatically sync with blockchain state:
- On application launch
- Via pull-to-refresh
- Every 5 minutes while app is active
- After completing transactions
Native support for nine currencies with appropriate formatting and symbols. Waiting Room balances display in the user's local currency while yield accounts always display in USD as they are backed by USDC.
users/{userId}
- phoneNumber: string
- firstName: string
- lastName: string
- country: string
- currency: string
- currencySymbol: string
- walletAddress: string (optional)
- encryptedPrivateKey: string (optional)
- walletCreatedAt: timestamp
- createdAt: timestamp
accounts/{accountId}
- userId: string
- name: string
- accountNumber: string
- balance: number
- type: 'checking' | 'savings' | 'waiting-room'
- apy: number (optional)
- poolId: string (optional)
- protocol: string (optional)
- chain: string (optional)
- walletAddress: string (optional)
- initialDeposit: number (optional)
- totalYieldEarned: number (optional)
- lastSynced: timestamp (optional)
- createdAt: timestamp
transactions/{transactionId}
- userId: string
- type: string
- fromAccount: string (optional)
- toAccount: string (optional)
- amount: number
- amountSent: number (optional)
- currencySent: string (optional)
- amountReceived: number (optional)
- currencyReceived: string (optional)
- exchangeRate: number (optional)
- txHash: string (optional)
- xrplTxHash: string (optional)
- blockchain: string (optional)
- status: 'pending' | 'completed' | 'failed'
- error: string (optional)
- timestamp: timestamp
Addresses:
- Pool: 0x07eA79F68B2B3df564D0A34F8e19D9B1e339814b
- USDC: 0x036CbD53842c5426634e7929541eC2318f3dCF7e
- aUSDC: 0xf53B60F4006cab2b3C4688ce41fD5362427A2A66
Primary Functions:
- supply: Deposit USDC to earn yield
- withdraw: Retrieve USDC plus accrued interest
- getReserveData: Query current APY and pool statistics
Base Sepolia gas costs (at typical gas prices):
- USDC approval: approximately $0.00005
- Aave deposit: approximately $0.0002
- Aave withdrawal: approximately $0.00018
- Total round-trip: approximately $0.0004
- Node.js version 18 or higher
- npm package manager
- Expo CLI
- iOS Simulator or Android Emulator
- Alchemy account
- Firebase project with Blaze plan
- Install dependencies
npm install
- Configure environment variables
Create a .env file in the project root with the required variables listed in the Configuration section below.
- Start the development server
npx expo start
- Launch on desired platform
Press 'i' for iOS simulator or 'a' for Android emulator.
Blockchain Infrastructure:
- ALCHEMY_API_KEY
- BASE_SEPOLIA_RPC_URL
- EXPO_PUBLIC_BASE_SEPOLIA_RPC_URL
Smart Contract Addresses:
- EXPO_PUBLIC_AAVE_POOL_ADDRESS
- EXPO_PUBLIC_USDC_ADDRESS
- EXPO_PUBLIC_AUSDC_ADDRESS
Development Wallet (Testnet Only):
- TEST_WALLET_PRIVATE_KEY
- TEST_WALLET_ADDRESS
- EXPO_PUBLIC_TEST_WALLET_PRIVATE_KEY
- EXPO_PUBLIC_TEST_WALLET_ADDRESS
Security:
- WALLET_ENCRYPTION_KEY
- Create Firebase project at console.firebase.google.com
- Enable Phone Authentication
- Upgrade to Blaze plan (required for phone auth)
- Create Firestore database
- Set security rules to allow development access
- Add Firebase config to FirebaseConfig.ts
- Sign up at alchemy.com
- Create new app
- Select Base chain and Base Sepolia network
- Copy API key and RPC URL to .env
Obtain Base Sepolia ETH from:
- coinbase.com/faucets/base-ethereum-sepolia-faucet
Obtain test USDC from:
- staging.aave.com/faucet (select Base Sepolia network)
Test blockchain connection:
node test-connection.js
Fund user wallets:
node fund-user-wallet.js
Test Aave deposit:
node test-aave-deposit.js
Check current APY:
node check-apy.js
Setup XRPL wallet:
node setup-xrpl.js
Dev Funding Screen: Access via Dashboard when running in development mode. Allows one-click funding of yield accounts with test USDC from your development wallet.
Quick Add to Waiting Room: Available in Waiting Room dropdown in development mode. Adds test funds to the waiting room for rapid testing.
When a user creates their first yielding account, the system generates an Ethereum wallet. The wallet address is stored in Firebase along with the encrypted private key. All subsequent yielding accounts for that user share the same wallet.
User funds deposited into yielding accounts are converted to USDC and deposited into Aave V3 lending pools. Interest accrues continuously based on the pool's current supply rate. The system periodically syncs blockchain balances with Firebase to display earned yield.
A background service queries the blockchain every 5 minutes to check actual aToken balances. When the blockchain balance exceeds the Firebase balance, the difference is calculated as earned yield and the Firebase record is updated.
International transfers utilize exchange rates to convert between currencies. The sender's local currency is debited and the recipient's local currency is credited based on current market rates.
When transferring between yield accounts, the system checks if the recipient has a matching account type. If not, a new account of the same type is automatically created for the recipient.
This hackathon prototype uses simplified security measures:
- Private keys encrypted with Base64 and stored in Firebase
- Open Firestore security rules for development
- Testnet environment only
- No insurance or audit coverage
Before deploying with real funds, the following security measures are required:
- Migration to AWS KMS or Google Cloud KMS for key management
- Hardware Security Modules for key storage
- Multi-signature wallets for administrative functions
- Comprehensive smart contract audits
- Bug bounty program
- Insurance coverage for smart contract risks
- Proper Firestore security rules with authentication
- KYC and AML compliance
- Money Transmitter Licenses
Store user profile information including phone number, name, country preference, currency settings, and wallet information.
Track all accounts (waiting room and yielding) with balances, account types, pool assignments, protocol details, and synchronization timestamps.
Record all transfers including type, amounts, currency conversions, blockchain transaction hashes, and status.
The application interacts with Aave V3 deployed on Base Sepolia testnet. Key operations include:
Supply Operation: Deposits USDC into the lending pool, receiving aUSDC tokens in return. These tokens automatically increase in value as interest accrues.
Withdraw Operation: Burns aUSDC tokens to receive the underlying USDC plus all earned interest.
Reserve Data: Queries current supply rates, utilization, and other pool statistics to display accurate APY information to users.
Depositing to Aave requires two blockchain transactions:
- Approving Aave contract to spend USDC (ERC20 approval)
- Calling the supply function to deposit USDC
The approval step is optimized by approving a large amount upfront, avoiding repeated approval transactions.
- Protocol: AAVE USDC V3
- Target APY: 4.2%
- Protocol: Sentora PYUSD
- Target APY: 6.48%
- Protocol: Elemental USDC Turbo
- Target APY: 9.2%
The application supports nine currencies with automatic conversion:
- USD (United States Dollar)
- GBP (British Pound Sterling)
- EUR (Euro)
- CAD (Canadian Dollar)
- MXN (Mexican Peso)
- RUB (Russian Ruble)
- CNY (Chinese Yuan)
- BRL (Brazilian Real)
- AED (UAE Dirham)
Handles Firebase phone authentication, user creation, and session management. Creates user documents with encrypted wallet information.
Manages CRUD operations for both waiting room and yielding accounts. Handles account creation, balance updates, and retrieval.
Generates Ethereum wallets, encrypts private keys, stores wallet information in Firebase, and retrieves wallet instances for transactions.
Interfaces with Aave V3 smart contracts. Includes functions for checking balances, depositing USDC, withdrawing funds, and querying current APY rates.
Manages international transfers and currency conversion. Currently uses mock implementation for demo purposes with architecture ready for production XRP Ledger integration.
Three transfer services handle different transaction types:
- Standard transfers between waiting room and yield accounts
- International transfers with currency conversion
- Peer-to-peer transfers between yield accounts
