Demo application showcasing integration with ZKP2P via the PeerAuth browser extension.
- PeerAuth Extension Integration: Automatically detects if the PeerAuth extension is installed
- Connect & Onramp Flow: Requests user connection and triggers onramp via extension sidebar
- Customizable Parameters: Configure all query parameters for the onramp flow
- Preset Examples: Quick-start with common onramp scenarios
# Install dependencies
npm install
# Start development server
npm run dev
# Build for production
npm run build
# Preview production build
npm run preview
# Type check
npm run typecheck
# Lint
npm run lintThis project is configured for deployment on Vercel. Push to main branch to trigger automatic deployment.
- Check Extension: The app checks if
window.peerexists - Redirect to Install: If not installed, user is directed to Chrome Web Store
- Request Connect: If installed, calls
window.peer.requestConnect() - Trigger Onramp: After connection, calls
window.peer.onramp(queryString)to open the extension sidebar
| Parameter | Description |
|---|---|
| referrer | Your application name |
| referrerLogo | URL to your logo |
| callbackUrl | URL to redirect after completion |
| inputCurrency | Fiat currency (USD, EUR, etc.) |
| inputAmount | Amount in fiat currency |
| paymentPlatform | Payment method (venmo, revolut, etc.) |
| toToken | Target token (format: chainId:tokenAddress) |
| recipientAddress | Destination wallet address |
Visit demo.zkp2p.xyz