Convert Figma logo to code with AI

BlueWallet logoLndHub

Wrapper for Lightning Network Daemon. It provides separate accounts for end-users

1,005
355
1,005
71

Top Related Projects

Zap Wallet - Cross platform Lightning Network wallet focused on user experience and ease of use ⚡️

Quick Overview

LndHub is a Lightning Network hub that allows users to connect to the Lightning Network and manage their Bitcoin Lightning Network funds. It provides a user-friendly interface and API for interacting with the Lightning Network.

Pros

  • Simplified Lightning Network Access: LndHub abstracts the complexity of the Lightning Network, making it easier for users to interact with and manage their funds.
  • User-Friendly Interface: The project provides a web-based interface that allows users to view their balances, send and receive payments, and manage their Lightning Network channels.
  • API Integration: LndHub offers a comprehensive API that enables developers to integrate Lightning Network functionality into their applications.
  • Open-Source: The project is open-source, allowing for community contributions and transparency.

Cons

  • Centralization: As a hub, LndHub introduces a level of centralization, which may be a concern for some users who prefer a more decentralized approach.
  • Dependency on Third-Party: Users are dependent on the LndHub service, which could potentially introduce reliability and security concerns.
  • Limited Customization: The user interface and functionality of LndHub may be limited compared to running a full Lightning Network node.
  • Potential Privacy Concerns: The centralized nature of LndHub may raise privacy concerns, as the service provider could potentially have visibility into user transactions.

Getting Started

To get started with LndHub, follow these steps:

  1. Visit the LndHub website (https://lndhub.io/) and create an account.
  2. Deposit Bitcoin into your LndHub wallet by sending funds to the provided Bitcoin address.
  3. Once the funds are received, you can start using the LndHub interface to manage your Lightning Network channels and make payments.
  4. Alternatively, you can use the LndHub API to integrate Lightning Network functionality into your own applications. The API documentation is available on the LndHub website.

Competitor Comparisons

Zap Wallet - Cross platform Lightning Network wallet focused on user experience and ease of use ⚡️

Pros of Zap Desktop

  • Zap Desktop provides a user-friendly and intuitive interface for managing Lightning Network (LN) transactions.
  • It supports a wide range of features, including sending and receiving payments, managing channels, and monitoring the network.
  • Zap Desktop is open-source and actively maintained, with a large and engaged community.

Cons of Zap Desktop

  • Zap Desktop may have a steeper learning curve compared to BlueWallet/LndHub, especially for users new to the Lightning Network.
  • The application can be resource-intensive, particularly on older or less powerful devices.
  • Zap Desktop may not offer the same level of mobile integration and accessibility as BlueWallet/LndHub.

Code Comparison

Here's a brief code comparison between the two projects:

BlueWallet/LndHub

const express = require('express');
const app = express();
const lnd = require('./lnd');

app.get('/balance', async (req, res) => {
  try {
    const balance = await lnd.getBalance();
    res.json(balance);
  } catch (err) {
    res.status(500).json({ error: err.message });
  }
});

LN-Zap/zap-desktop

import React, { useState, useEffect } from 'react';
import { useSelector, useDispatch } from 'react-redux';
import { fetchChannels } from './actions';

const ChannelsPage = () => {
  const dispatch = useDispatch();
  const channels = useSelector(state => state.channels);

  useEffect(() => {
    dispatch(fetchChannels());
  }, [dispatch]);

  return (
    <div>
      {channels.map(channel => (
        <div key={channel.id}>{channel.remotePubkey}</div>
      ))}
    </div>
  );
};

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

LndHub

Wrapper for Lightning Network Daemon (lnd). It provides separate accounts with minimum trust for end users.

INSTALLATION

You can use those guides or follow instructions below:

git clone git@github.com:BlueWallet/LndHub.git
cd LndHub
npm i

Install bitcoind, lnd, and redis. Edit LndHub's config.js to set it up correctly. Copy the files admin.macaroon (for Bitcoin mainnet, usually stored in ~/.lnd/data/chain/bitcoin/mainnet/admin.macaroon) and tls.cert (usually stored in ~/.lnd/tls.cert) into the root folder of LndHub.

LndHub expects LND's wallet to be unlocked, if not — it will attempt to unlock it with the password stored in config.lnd.password. Don't forget to configure disk-persistence for redis (e.g., you may want to set appendonly to yes in redis.conf (see http://redis.io/topics/persistence for more information).

If you have no bitcoind instance, for example if you use neutrino, or you have no bitcoind wallet, for example if you use LND for wallet managment, you can remove the bitcoind settings from config.js. Please note that this feature is limited to Bitcoin, so you can't use it if you use any other cryptocurrency with LND (e.g., Litecoin).

Deploy to Heroku

Add config vars :

  • CONFIG : json serialized config object
  • MACAROON: hex-encoded admin.macaroon
  • TLSCERT: hex-encoded tls.cert

Run in docker

LndHub is available on Docker Hub as bluewalletorganization/lndhub. Please note that this requires a separate instance of redis and LND and optionally, bitcoind. You can also view Umbrel's implementation using docker-compose here.

Reference client implementation

Can be used in ReactNative or Nodejs environment

Tests

Acceptance tests are in https://github.com/BlueWallet/BlueWallet/blob/master/tests/integration/lightning-custodian-wallet.test.js

image

Responsible disclosure

Found critical bugs/vulnerabilities? Please email them to bluewallet@bluewallet.io Thanks!