Greenfield platform for SFLUV account-abstraction payments:
backend/: ERC-4337 sponsorship gateway + UserOperation submission servicemobile/: Expo React Native wallet for QR-first send/receive
- Backend: runnable, now supports paymaster-specific EntryPoint routing (legacy + new routes in one service).
- Mobile: supports Privy OAuth login + embedded signer, and uses the legacy Citizen Wallet smart-account stack only.
- Privy login (
google) and embedded wallet signer path. - Legacy Citizen Wallet smart-account derivation from the owner EOA.
- Auto-discovery across legacy smart-account indexes for the signed-in owner.
- In-app wallet chooser when more than one legacy smart wallet is discovered.
- UserOperation lifecycle: build -> sponsor -> sign -> submit -> receipt poll.
- QR send/receive flow using EIP-681 format.
- Amount input in whole SFLUV (converts to token decimals internally).
- Transaction confirmation pop-up with transaction hash.
- Saved contacts (local persistence) and quick recipient autofill.
- Clipboard copy button for receive address.
Backend:
cd backend
cp chains.example.json chains.json
set -a; source .env; set +a
go run ./cmd/server -config ./chains.jsonMobile:
cd mobile
npm install
npx expo start --host tunnel --clearUse this when a teammate wants to run the mobile wallet on a real phone with Expo Go.
- Prepare local config files:
cd backend
cp chains.example.json chains.json
cd ../mobile
cp .env.example .env- Fill in the required local values. These are required for testing but are intentionally not committed:
- Privy mobile app id and client id
- Google Maps API key and map id
- backend host values reachable from the phone
- If the phone is using Expo Go against a local shared backend, do not leave backend URLs on
localhost. Replace them with your laptop's LAN IP or another phone-reachable host:
EXPO_PUBLIC_APP_BACKEND_URL=http://<your-lan-ip>:8080EXPO_PUBLIC_LEGACY_BACKEND_URL=http://<your-lan-ip>:8088only if you are intentionally overriding the hosted Citizen Wallet engine
- Start services in order:
cd backend
set -a; source .env; set +a
go run ./cmd/server -config ./chains.json
cd ../mobile
npm install
npx expo start --host tunnel --clear- Open the tunnel URL in Expo Go and sign in with Privy.
Note: Privy integration may require a development build on some environments, but the current setup is intended to work in Expo Go for team testing.
Detailed checklist:
docs/TESTING_WITH_EXPO_GO.md
- Do not commit secret files (
backend/.env,mobile/.envare gitignored). - Do not commit
backend/chains.json; create it locally frombackend/chains.example.json. - Treat all
EXPO_PUBLIC_*variables as public in client bundles. - This repo documents which values are required for testing, but it does not include live private keys, sponsor keys, Expo tokens, or Privy secrets.