WDK logoWDK documentation

Wallet Spark Overview

Overview of the @tetherto/wdk-wallet-spark module

A simple and secure package to manage BIP-32 wallets for the Spark blockchain. This package provides a clean API for creating, managing, and interacting with Spark wallets using BIP-39 seed phrases, BIP-44 derivation paths, and the Spark SDK for Bitcoin layer 2 functionality including Lightning Network integration.

Features

  • Spark Blockchain Support: Full integration with the Spark Bitcoin layer 2 network
  • Lightning Network Integration: Create and pay Lightning Network invoices directly
  • Spark Invoices: Create and pay Spark invoices for receiving sats and tokens directly on the Spark network
  • Token Transfers: Transfer tokens to other Spark addresses
  • Bitcoin Layer 1 Bridge: Deposit and withdraw Bitcoin between layer 1 and Spark
  • Static Deposit Addresses: Reusable deposit addresses for Bitcoin layer 1 deposits
  • Deposit Refunds: Refund static deposits back to Bitcoin addresses
  • Withdrawal Fee Quotes: Get fee quotes before withdrawing funds
  • BIP-44 Derivation Paths: Support for standard BIP-44 derivation paths with Spark-specific coin type (998)
  • BIP-39 Seed Phrase Support: Generate and validate BIP-39 mnemonic seed phrases
  • Multi-Account Management: Create and manage multiple accounts from a single seed phrase
  • Single-Use Deposit Addresses: Generate unique deposit addresses for Bitcoin layer 1 deposits
  • Fee-Free Transactions: Spark transactions are fee-free on the layer 2 network
  • Transaction History: Complete transaction history with incoming/outgoing transfers
  • Message Signing: Sign and verify messages using Spark identity keys
  • Memory Safety: Secure private key management with automatic memory cleanup
  • TypeScript Support: Full TypeScript definitions included
  • Network Support: Support for Spark mainnet and regtest networks

Supported Networks

This package supports the following Spark networks:

  • Spark Mainnet: Production Spark network
  • Spark Regtest: Local Spark network for testing

Regtest Faucet

You can obtain test funds for your Regtest environment from the Lightspark Regtest Faucet.

Next Steps


Need Help?

On this page