User-Generated Non-Custodial Bitcoin Wallets (Users Manage Their Own Keys)

Bitnob provides Bitcoin blockchain infrastructure for businesses that want to build fully non-custodial wallets.

In this model:

Users generate and control their own private keys.

All transaction signing happens on user devices.

Bitnob provides address monitoring, transaction broadcasting, fee estimation, and blockchain queries.

Bitnob never touches private keys, unsigned transactions, or funds.

Core Concepts

ConceptDescription
Self-CustodyUsers fully control their wallets and private keys.
Bitnob’s RoleBackend Bitcoin infrastructure (broadcasting, fee estimation, monitoring). No keys. No custody.
Signing TransactionsMust happen locally on the user’s device.
Address Types SupportedLegacy (P2PKH), Nested SegWit (P2SH), Native SegWit (P2WPKH), Taproot (P2TR).

Developer Responsibilities

Generate Bitcoin wallets securely (BIP32, BIP39, BIP44 recommended).

Build full key management and signing flows into your app.

Query balances, broadcast transactions, and monitor addresses using Bitnob APIs.

Never send private keys or seed phrases over the network.

Key APIs Provided by Bitnob

ActionMethodEndpoint
Watch addressPOST/api/v1/noncustodial/bitcoin/address/watch
Watch multiple addressesPOST/api/v1/noncustodial/bitcoin/address/watch/bulk
Broadcast signed transactionPOST/api/v1/noncustodial/bitcoin/transaction/broadcast
Batch broadcast transactionsPOST/api/v1/noncustodial/bitcoin/transaction/batch/broadcast
Estimate feesGET/api/v1/noncustodial/bitcoin/fees/estimate
Fetch address balanceGET/api/v1/noncustodial/bitcoin/address/balance
Fetch address transactionsGET/api/v1/noncustodial/bitcoin/address/transactions

Putting It All Together

This section walks through how you can build a real Bitcoin non-custodial wallet using Bitnob RPCs.

1.

Step 1: Wallet Generation (Onboarding New User)

Use BDK (or bitcoinjs-lib) on the client device.

Generate a new BIP39 seed phrase.

Derive master private and public keys.

Generate the first Bitcoin address (SegWit or Taproot recommended).

Offer the user a backup flow for the seed phrase.

Example: Mobile app using BDK-Swift (iOS) or BDK-Kotlin (Android). Bitcoin address displayed as QR code.

2.

Step 2: Display Wallet Dashboard

Query address balances using Bitnob API.

Display recent transaction history from Bitnob.

Update balances automatically via webhook listening or scheduled polling.

3.

Step 3: Receiving Bitcoin

Show fresh address (or rotate automatically after each payment).

Monitor address with Bitnob's webhook service.

Detect inbound payments and confirmations.

4.

Step 4: Sending Bitcoin

Fetch UTXOs if needed.

Use BDK or bitcoinjs-lib to build a transaction (inputs, outputs).

Estimate fees dynamically with Bitnob's fee API.

Sign transaction locally using the user's private key.

Push signed transaction to Bitnob /transaction/broadcast.

5.

Step 5: Wallet Operations

Periodically rotate addresses to preserve privacy.

Allow users to label transactions internally.

Show mempool status for pending transactions.

Support Replace-By-Fee (RBF) for speeding up transactions later (optional advanced feature).


Real-World Sample Implementation Outline

ComponentTools/LibrariesPurpose
Key GenerationBDK (Swift, Kotlin, Rust) / bitcoinjs-libSecure private key and address generation
Transaction BuildingBDK, bitcoinjs-libAssemble and sign transactions on device
Blockchain InterfaceBitnob APIsFetch balances, broadcast transactions, monitor addresses
WebhooksBitnob WebhooksReal-time transaction notifications
Backup & RecoveryManual seed backup, optional cloud backup (encrypted)Protect against device loss

Key Benefits of This Model

You control the user experience 100%.

Your users retain their privacy and custody.

You avoid needing to run and maintain Bitcoin full nodes.

You can scale globally with minimal blockchain overhead.

You are ready for advanced Bitcoin features like Taproot, Schnorr signatures, and Miniscript when needed.

Example Full System Flow Diagram

Example Full System Flow Diagram

Use BDK or similar libraries for secure wallet building — avoid reinventing cryptography.

Use Bitnob purely for node-level services — blockchain broadcast, monitoring, fee suggestion.

Prioritize user education on backups, security, and transaction confirmations.

Building non-custodial wallets is challenging — but with Bitnob's backend + open-source Bitcoin SDKs like BDK , it becomes achievable even for small teams.