Skip to content

Lightning Integration

SecureBitChat edited this page Aug 18, 2025 · 1 revision

Lightning Network Integration Guide

Overview

SecureBit.chat integrates Lightning Network for sustainable, privacy-focused communication.

Session Types

Demo Session

  • Duration: 6 minutes
  • Cost: Free
  • Purpose: Testing and evaluation
  • Features: Full functionality

Basic Session

  • Duration: 1 hour
  • Cost: 50 satoshis (~$0.02)
  • Purpose: Regular communication
  • Features: All security features

Premium Session

  • Duration: 6 hours
  • Cost: 200 satoshis (~$0.08)
  • Purpose: Extended communication
  • Features: Priority features + extended duration

🏦 Supported Wallets

WebLN-Compatible Wallets

Wallet WebLN Mobile Desktop Notes
Alby βœ… βœ… βœ… Recommended
Zeus βœ… βœ… βœ… Full support
Wallet of Satoshi βœ… βœ… ❌ Mobile only
Muun ⚠️ βœ… ❌ Limited WebLN
Breez βœ… βœ… ❌ Good mobile support
Strike βœ… βœ… βœ… Full integration

Manual Payment (Fallback)

If WebLN is not available:

  1. Generate Lightning invoice
  2. Pay manually in your wallet
  3. Return to SecureBit.chat
  4. Session activates automatically

πŸ”§ Technical Details

WebLN Integration

// Example WebLN payment flow
if (window.webln) {
  await window.webln.enable();
  const payment = await window.webln.sendPayment(invoice);
}

Payment Flow

  1. User selects session type
  2. System generates Lightning invoice
  3. WebLN wallet processes payment
  4. Payment confirmation received
  5. Session activated immediately

Security Considerations

  • Payments are atomic (all-or-nothing)
  • No payment data stored locally
  • Invoice amounts are fixed and transparent
  • No refund mechanism (by design)

Troubleshooting

Common Issues

  • WebLN not detected: Install compatible wallet
  • Payment fails: Check wallet balance
  • Session doesn't activate: Refresh page and retry
  • Invoice expired: Generate new invoice

Wallet Setup

  1. Install Lightning wallet
  2. Fund wallet with Bitcoin
  3. Enable WebLN in wallet settings
  4. Test with small amounts first
Clone this wiki locally