getAlby / getAlby/go

Implement NFC Tap-to-Pay for Lightning Payments

Open
#426 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
57
Forks
21
Avg merge
2h 9m
Merged PRs (30d)
1

Description

## Summary
Alby Go currently supports QR code-based Lightning payments, which are great for digital interactions but less ideal for in-person transactions (e.g., at merchants). This feature request proposes adding NFC (Near Field Communication) support to enable "tap-to-pay" functionality, allowing users to pay Lightning invoices by tapping their phone against an NFC-enabled terminal or device.

## Motivation
- **User Experience**: Tap-to-pay makes Lightning payments as seamless as traditional contactless cards, reducing friction for everyday use and merchant adoption.
- **Bitcoin Adoption**: Aligns with Summer of Bitcoin goals by making Bitcoin/Lightning more accessible for real-world transactions, bridging the gap between digital and physical commerce.
- **Differentiation**: NFC is rare in open-source Lightning wallets, positioning Alby Go as a leader in mobile payment innovation.
- **Ecosystem Impact**: Enhances NWC compatibility and could inspire similar features in other Alby tools.

## Proposed Implementation
1. **NFC Integration**:
- Use `react-native-nfc-manager` to detect and read/write NFC tags containing BOLT11-encoded Lightning invoices.
- Handle NFC events in the app (e.g., on tag discovery, parse the invoice data).

2. **Payment Flow**:
- Detect NFC tap → Extract and validate invoice (amount, expiry, payee).
- Route to existing send confirmation screen with biometric auth option.
- Provide haptic feedback and UI updates for success/failure.
- Add user preferences (enable/disable NFC in settings).

3. **Security & Compatibility**:
- Ensure no sensitive wallet data is transmitted via NFC (only invoice details).
- Prioritize Android support (iOS NFC is more restricted); test with common terminals/wallets.
- Follow Lightning standards for invoice encoding/decoding.

4. **UI/UX Enhancements**:
- Add NFC toggle in settings screen.
- Update send/receive screens with NFC availability indicators.
- Include onboarding tips (e.g., "Tap your phone to pay").

5. **Testing & Documentation**:
- Unit tests for NFC parsing and invoice validation.
- Integration tests with mock NFC hardware.
- End-to-end tests on physical devices.
- Update README with NFC setup instructions.

## Technical Scope
- **Complexity**: Medium-high (hardware integration, protocol handling, UI updates).
- **Dependencies**: Add `react-native-nfc-manager` and related Expo plugins.
- **Estimated Effort**: 8-12 weeks for a skilled React Native developer.
- **Milestones**: NFC setup → Basic tap detection → Full payment flow → Testing/polish.

## Acceptance Criteria
- Users can tap to pay Lightning invoices via NFC.
- Secure, reliable, and compatible with existing Alby Go features.
- Comprehensive tests and documentation.

This would be a self-contained, impactful feature that advances Alby Go's usability without disrupting core functionality. Happy to discuss implementation details or refinements!

Contributor guide

No contributing guide indexed for this repository

Research direction

No repository files, tests, or entry points are identified in the issue. Start by locating the existing send confirmation flow, settings screens, and test setup, then define the NFC integration and platform scope before implementation; done means NFC invoice payment, security checks, tests, physical-device validation, and README updates are complete.

Written by the indexing model from the issue text.

Assessment

Tech stack
react-native, typescript
Domain
mobile, payments
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.