Skip to content

BcnBitcoinOnly/next-unused-address-ts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

next-unused-address-ts

HTTP server that returns the next unused Bitcoin address for a descriptor wallet. Queries Electrum servers to scan for used addresses, then returns the first unused one.

Supports multiple Electrum servers with automatic failover.

Setup

cp .env.example .env
# Edit .env with your descriptor and preferred servers
npm install

Usage

npm run dev
curl http://localhost:8080/address

Configuration

Variable Description Default
DESCRIPTOR Bitcoin output descriptor (required)
ELECTRUM_SERVERS Comma-separated host:port:protocol list (required). Protocol defaults to ssl if omitted.
NETWORK bitcoin or testnet bitcoin
GAP_LIMIT Address gap limit for scanning 20
BIND_ADDRESS HTTP bind address 127.0.0.1
LISTENING_PORT HTTP port 8080

About

A Typescript copy cat of https://github.com/BcnBitcoinOnly/next-unused-address

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors