Instant crypto payments through chat
Giggle enables Web3 payments through WhatsApp, allowing users to send and receive PYUSD (PayPal's USD-backed digital currency) using simple text commands.
ETHOnline 2025 Submission
Giggle bridges the gap between traditional messaging and decentralized finance by providing:
- Text-based cryptocurrency transactions through WhatsApp
- AI-powered natural language command processing
- Secure delegated signing for scheduled payments
- Real-time transaction confirmations and price feeds
Chat-Native Interface
- No app installation required
- Non-Custodial Wallet Setup
- Works on any device with WhatsApp
- Accessible to 2 billion potential users
- Familiar conversational experience
Non-Custodial Security
- No private keys stored on servers
- User maintains full custody
Digital Currency Support
- PYUSD (PayPal USD) - USD-backed digital currency
- Settlement on Ethereum Sepolia
- Testnet environment for safe testing
- Production-ready architecture
AI-Powered Automation
- Natural language command parsing via OpenAI
- Intent detection for conversational interface
- Flexible command understanding
- Enhanced user experience
Security Controls
- PIN-based transaction authentication
- Secure PIN hashing and storage
- Transaction confirmation workflow
- Balance verification before sending
- Complete audit trail
| Command | Description | Example |
|---|---|---|
help |
Display help information | help |
balance |
Check PYUSD and ETH balance | balance or What's my balance? |
account |
View account details and address | Show my account |
send |
Send PYUSD to phone number | Send $10 to +91234567890 |
request |
Request PYUSD from someone | Request $20 from +91234567890 |
history |
View transaction history | Show transaction history |
set pin |
Set up security PIN (required) | Set PIN 1234 |
confirm |
Confirm pending transaction | confirm or enter your PIN |
cancel |
Cancel pending transaction | cancel |
create coupon |
Create a gift coupon | Create gift coupon $25 or I would like to gift a coupon |
redeem coupon |
Redeem a gift coupon | Redeem coupon ABC123 |
my coupons |
List all your gift coupons | Show my coupons or My coupons |
check coupon |
Check coupon status | Check coupon ABC123 |
| Format | Example | Description |
|---|---|---|
| Phone | +91234567890 |
E.164 formatted phone number |
| Phone | (9123) 456-7890 |
US local format (auto-converted) |
| Symbol | Name | Description |
|---|---|---|
pyusd |
PayPal USD | USD-backed digital currency by PayPal |
| Scenario | Implementation | Benefits |
|---|---|---|
| Cross-border payments | Send PYUSD to international contacts | Lower fees, faster settlement |
| Bill splitting | Request payments from group members | Instant settlement, clear audit trail |
| Allowance payments | Schedule recurring transfers | Automated, reliable delivery |
| Scenario | Implementation | Benefits |
|---|---|---|
| Customer payments | Receive payments via chat | No POS required, instant confirmation |
| Vendor payments | Send scheduled payments to suppliers | Automated cash flow management |
| Payroll | Schedule salary disbursements | Reduced administrative overhead |
┌─────────────────┐
│ WhatsApp │
│ (User) │
└────────┬────────┘
│
▼
┌─────────────────┐
│ Webhook │
│ Interface │
└────────┬────────┘
│
▼
┌─────────────────────────────────────────┐
│ Giggle API Server │
│ │
│ ┌──────────┐ ┌──────────┐ │
│ │ OpenAI │ │ User │ │
│ │ Intent │ │ Service │ │
│ └──────────┘ └──────────┘ │
│ │
│ ┌──────────┐ ┌──────────┐ │
│ │ Wallet │ │ PIN │ │
│ │ Service │ │ Service │ │
│ └──────────┘ └──────────┘ │
└─────────┬───────────────────────────────┘
│
├─────────► Ethereum RPC
├─────────► Blockscout API
└─────────► OpenAI API
- Node.js 22
- npm package manager
- Twilio account (free sandbox available)
- ngrok for local webhook testing
cd giggle
cp .env.example .env
npm installEdit .env with your credentials:
# Twilio Configuration (https://console.twilio.com)
TWILIO_ACCOUNT_SID=your_account_sid
TWILIO_AUTH_TOKEN=your_auth_token
# OpenAI Configuration (required for natural language processing)
OPENAI_API_KEY=your_openai_api_key
# Network Configuration (Ethereum Sepolia)
CHAIN_ID=11155111
RPC_URL=https://ethereum-sepolia-rpc.publicnode.com
CHAIN_NAME=Ethereum Sepolia
PYUSD_ADDRESS=0xCaC524BcA292aaade2DF8A05cC58F0a65B1B3bB9
# Optional Service Configuration
BLOCKSCOUT_API_URL=https://eth-sepolia.blockscout.com/apicd apps/api
npm run tsx scripts/migrate.tsStart the required services:
# Terminal 1: API Server
npm run dev
# Terminal 2: ngrok
ngrok http 3000- Navigate to Twilio Sandbox
- Set "When a message comes in" to:
https://your-ngrok-url.ngrok.io/whatsapp - Save configuration
- Send
join <your-sandbox-code>to +11111111111 - Send
/helpto verify bot functionality
Before sending any transactions, you must set up a security PIN:
Set PIN 1234
Use a 4-6 digit PIN that you'll remember. You'll need it to confirm all transactions.
Your wallet is automatically created when you first interact with the bot. You'll need testnet tokens:
- Ethereum Sepolia ETH: Sepolia Faucet
- Test PYUSD: Deploy test tokens or use existing testnet PYUSD
View your wallet address and balances:
Show my account
or simply:
balance
Send PYUSD to another phone number:
Send $10 to +1234567890
You'll be prompted to confirm by entering your PIN.
After initiating a send, enter your PIN to confirm:
1234
or type:
confirm
Show transaction history
All transactions require PIN confirmation for security:
- PIN Setup: Required before first transaction
- PIN Format: 4-6 digits
- Secure Storage: PINs are hashed using bcrypt
- Transaction Security: Every send requires PIN entry
- Initiate: Send command (e.g., "Send $10 to +1234567890")
- Verify: System checks balance and creates pending transaction
- Confirm: Enter your PIN to confirm
- Execute: Transaction is broadcast to Ethereum Sepolia
- Notify: Both sender and recipient receive confirmation
- Balance verification before transactions
- Gas fee validation
- Automated wallet creation per phone number
- Complete audit logging of all activities
| Component | Technology | Purpose |
|---|---|---|
| Chat Interface | Twilio WhatsApp API | Message handling and delivery |
| Intent Recognition | OpenAI GPT | Natural language command parsing |
| Blockchain | Ethereum Sepolia | Transaction settlement |
| Smart Contract | ERC-20 (PYUSD) | Digital currency transfers |
| Security | bcrypt | PIN hashing and authentication |
| Database | SQLite | User and transaction data |
| Explorer | Blockscout | Transaction verification |
PayPal USD (PYUSD)
- Primary settlement token for all transactions
- Real-world P2P remittance implementation
- Consumer-scale payment UX demonstration
- Lower latency and cost vs. traditional payment rails
OpenAI Integration
- Natural language command interpretation
- Intent detection (send, request, balance, etc.)
- Flexible conversational interface
- Enhanced user experience
Blockscout Integration
- On-chain transaction confirmation delivered to chat
- Transaction explorer links
- Address verification and lookup
Giggle complies with WhatsApp commerce policies:
- Non-custodial architecture (no funds held by service)
- Testnet-only demonstration (no real currency)
- External wallet links (no in-chat commerce)
- Clear testnet warnings and disclosures
Business-initiated messages use approved templates. User-initiated flows maintain compliance by:
- Requiring user to initiate conversation
- Template approval for scheduled notifications
/startcommand to reopen messaging window
- No private key storage
- Minimal PII collection (phone numbers only)
- Comprehensive audit logging
- GDPR-compatible architecture
- WhatsApp Business Account registration
- Message template approval
- Production Twilio phone number
- Mainnet RPC endpoint configuration
- Secure hosting deployment (AWS/GCP/Railway)
- SSL/TLS certificate installation
- Twilio signature verification
- Rate limiting configuration
- Monitoring setup (Sentry, DataDog)
- Legal compliance review
NODE_ENV=production
TWILIO_VERIFY_SIGNATURES=true
ENCRYPTION_KEY=<32-byte-key>
JWT_SECRET=<strong-secret>
RPC_URL=<mainnet-rpc>Railway
railway init
railway upDocker
docker build -t giggle .
docker run -p 3000:3000 giggleServerless (Vercel/Netlify)
- API routes compatible with serverless functions
- Requires persistent PostgreSQL database
This project was developed for ETHOnline 2025. Contributions are welcome.
- Fork the repository
- Create a feature branch
- Commit your changes
- Submit a pull request
MIT License - see LICENSE file for details
TESTNET ONLY - NO REAL FUNDS
This is a proof-of-concept demonstration for ETHOnline 2025. All transactions use testnet tokens with no monetary value. Do not send real funds to testnet addresses.
WhatsApp integration utilizes Twilio Sandbox for development purposes only. Production deployment requires:
- WhatsApp Business Account approval
- Compliance with WhatsApp Business Policy
- Approved message templates
- Appropriate regulatory licensing (jurisdiction-dependent)
This software is provided as-is without warranties. Not financial advice. Use at your own risk.
Built with:
- Twilio - WhatsApp API integration
- OpenAI - Natural language processing and intent detection
- Blockscout - Ethereum block explorer
- Ethereum - Blockchain infrastructure (Sepolia testnet)
- PayPal USD - Digital currency infrastructure
- ethers.js - Ethereum wallet and contract interaction
- Express.js - API server framework
- SQLite - Database for user and transaction data
ETHOnline 2025 Submission
For questions or demo requests, please open an issue on GitHub.