Integrating blockchain functionality into modern applications has never been more accessible. With the JavaScript Signature SDK, developers can seamlessly implement secure, multi-chain wallet capabilities directly within their web, mobile, or desktop environments. Built with TypeScript and JavaScript, this powerful SDK supports a wide range of cryptographic standards and blockchain protocols, enabling offline private key generation, address creation, transaction assembly, and digital signing โ all without relying on external services.
Whether you're building decentralized applications (dApps), integrating non-custodial wallets, or developing cross-chain solutions, this SDK offers modular, extensible tools tailored for real-world use cases.
Overview
The js-wallet-sdk is a comprehensive wallet development toolkit designed to simplify Web3 integration. It abstracts complex cryptographic operations and chain-specific logic into reusable modules, allowing developers to focus on user experience and application logic.
Key features include:
- Offline key and address generation
- Transaction signing across multiple blockchains
- Support for BIP32, BIP39, ECDSA, and Ed25519 standards
- Modular architecture with per-chain packages
Currently supporting over 20 major blockchains โ from Bitcoin and Ethereum to Solana, Aptos, and Polkadot โ the SDK ensures future-proof scalability as new chains are continuously added.
๐ Discover how to integrate secure wallet functions in minutes
Supported Platforms
As a JavaScript-based SDK, it runs in any environment that supports JS, including:
- Modern web browsers (Chrome, Firefox, Safari, Edge)
- Node.js backends
- React Native and Electron applications
This cross-platform compatibility makes it ideal for full-stack Web3 development, ensuring consistent behavior whether used client-side or server-side.
Installation & Setup
Using NPM (Recommended)
Install the SDK via npm to access the latest stable release:
npm install @okxweb3/crypto-lib
npm install @okxweb3/coin-baseFor chain-specific functionality, install individual modules:
Ethereum Support:
npm install @okxweb3/coin-ethereumBitcoin Support:
npm install @okxweb3/coin-bitcoinEach coin module follows the same installation pattern: @okxweb3/coin-[chain-name].
Local Build (Advanced)
To build from source:
Clone the repository:
git clone https://github.com/okx/js-wallet-sdk.gitNavigate to the project and install dependencies:
cd js-wallet-sdk && npm installRun the build script:
npm run build
This approach is useful for custom modifications or auditing internal logic.
Core Functional Modules
The SDK is structured into modular components that promote clean code separation and efficient bundling.
crypto-lib
Provides foundational cryptographic utilities:
- BIP32 hierarchical deterministic wallet functions
- BIP39 mnemonic phrase generation and seed derivation
- SHA256, Base64, and other encoding/decoding tools
- ECDSA and Ed25519 signature algorithms
These low-level tools power higher-level wallet operations across all supported chains.
coin-base
Serves as the universal interface for all blockchain modules. Common methods include:
getRandomPrivateKey()โ Generate cryptographically secure private keysgetNewAddress()โ Derive public address from private keysignTransaction()โ Sign raw transactions securelyvalidAddress()โ Validate blockchain addresses formatsignMessage()/verifyMessage()โ Sign and verify arbitrary data
This abstraction allows consistent API usage across different blockchains.
Chain-Specific Modules
Each blockchain has its own dedicated package with optimized implementations:
โ coin-ethereum
Supports Ethereum and all EVM-compatible chains like Polygon, Arbitrum, Optimism, and BNB Chain.
Features:
- Full ERC-20 and contract interaction support
- Hardware wallet integration via
getHardWareRawTransaction - Recovery of public key from signature using
ecRecover
โ coin-bitcoin
Supports BTC, BCH, BSV, LTC, DOGE, and testnet variants.
Includes:
- Legacy and SegWit address formats
- Multi-sig transaction support
- Testnet and mainnet compatibility
โ coin-solana
High-performance Solana integration with:
- Fast transaction signing
- Hardware wallet message hashing
- Raw transaction validation
โ coin-cosmos
Supports Cosmos SDK-based chains including Atom, Juno, Osmosis, Terra, and Kava.
Uses standard derivation paths (m/44'/118') for interoperability.
โ coin-aptos, coin-sui, coin-starknet
Next-gen layer-1 chains with growing dApp ecosystems. Each supports core wallet functions like signing transfers, NFT actions, and smart contract calls.
Key Blockchain Support
| Chain Family | Supported Coins | Derivation Path |
|---|---|---|
| Bitcoin | BTC, BCH, BSV, LTC, DOGE | m/44'/0'/0'/0/0 (varies by type) |
| Ethereum | ETH, USDT (ERC20), Polygon, Arbitrum | m/44'/60'/0'/0/0 |
| Cosmos | ATOM, OSMO, JUNO, KAVA | m/44'/118'/0'/0/0 |
| Aptos | APT | m/44'/637'/0'/0/0 |
| SUI | SUI | m/44'/784'/0'/0/0 |
| TRON | TRX | m/44'/195'/0'/0/0 |
| Solana | SOL | m/44'/501'/0'/0/0 |
Full list available in official documentation.
๐ Start building multi-chain apps today โ explore SDK capabilities
Use Cases and Implementation Scenarios
Non-Custodial Wallet Development
Build self-custody wallets where users control their keys. All sensitive operations occur locally in-browser or in-app.
dApp Backend Signing
Securely sign transactions on backend systems without exposing private keys, using encrypted key storage and isolated signing modules.
Cross-Chain Bridges
Enable users to sign transactions on multiple chains using a unified interface powered by modular SDK design.
Hardware Wallet Integration
Leverage hardware-compatible methods like getHardWareSignedTransaction to interface with Ledger or Trezor devices.
Frequently Asked Questions (FAQ)
Q: Can I use this SDK in a production environment?
A: Yes. The SDK is actively maintained and used in enterprise-grade applications. Always follow security best practices when handling private keys.
Q: Is private key data ever sent to external servers?
A: No. All cryptographic operations โ including key generation and signing โ happen locally. The SDK does not transmit sensitive data.
Q: How do I add support for a new blockchain?
A: You can extend the coin-base module or contribute to the open-source repo. Community contributions are welcome.
Q: Does it support testnets?
A: Yes. Most coin modules support both mainnet and testnet configurations through parameterized network selection.
Q: Can I bundle only specific chains to reduce package size?
A: Absolutely. Thanks to its modular design, you can import only the chains your app uses, minimizing bundle impact.
Q: Is TypeScript typing included?
A: Yes. The SDK is written in TypeScript and provides full type definitions for enhanced developer experience.
Testing & Validation
Each module includes a comprehensive test suite located in the /tests directory of its respective package. These tests cover:
- Address derivation accuracy
- Signature correctness against known vectors
- Transaction serialization integrity
Running tests locally ensures your implementation behaves as expected before deployment.
Final Thoughts
The JavaScript Signature SDK empowers developers to build robust, secure, and scalable Web3 applications with minimal friction. With broad chain support, clean modular design, and strong cryptographic foundations, it's an essential tool for anyone entering the decentralized space.
Whether you're launching a wallet app or enhancing an existing platform with blockchain features, this SDK streamlines development while maintaining top-tier security standards.
๐ Unlock advanced Web3 functionality โ start integrating now