Packages

@ckb-ccc/utxo-global

Connect UTXO Global Wallet to CKB — multi-chain signing (CKB, Bitcoin, Dogecoin) through a unified Signer interface.

Edit on GitHub

@ckb-ccc/utxo-global integrates UTXO Global into CCC, providing Signer implementations for CKB, Bitcoin, and Dogecoin. UTXO Global is a multi-chain browser extension wallet that supports native CKB transaction signing as well as cross-chain signing from BTC and DOGE.

If you're using @ckb-ccc/connector-react or @ckb-ccc/ccc, UTXO Global is already included — no separate installation needed.

Installation

@ckb-ccc/utxo-global npm version@ckb-ccc/utxo-global npm downloads per week
npm install @ckb-ccc/utxo-global
yarn add @ckb-ccc/utxo-global
pnpm add @ckb-ccc/utxo-global

Dependencies:

PackageDescription
@ckb-ccc/coreBase types — Signer, Client, Transaction, and more

Architecture

@ckb-ccc/utxo-global provides three separate signers from a single provider injection at window.utxoGlobal:

Entry point: getUtxoGlobalSigners

getUtxoGlobalSigners(client, preferredNetworks?) checks for window.utxoGlobal and returns a SignerInfo[] array with all three signers — or an empty array if the wallet isn't available:

Supported signer types

Signer ClassBase TypeChainSignerType
SignerCkbccc.SignerCKBCKB
SignerBtcccc.SignerBtcBitcoinBTC
SignerDogeccc.SignerDogeDogecoinDoge

CKB signer

SignerCkb provides native CKB signing — no cross-chain address derivation needed. It calls signTransaction() on the provider directly.

BTC and Doge signers

SignerBtc and SignerDoge extend their respective cross-chain base classes. They derive CKB addresses from Bitcoin/Dogecoin public keys and sign CKB transaction witnesses using the respective chain's signing scheme.

Account change detection

All three signers implement onReplaced():

  • Listens for "accountsChanged" — user switched account
  • Listens for "networkChanged" — user switched network

When either fires, the application callback is invoked and listeners are cleaned up.

Provider interface

All three sub-providers (ckbSigner, bitcoinSigner, dogeSigner) share the same interface:

MethodDescription
requestAccounts()Prompt user to connect and return accounts
getAccount()Get connected accounts
getPublicKey()Get address and public key pairs
connect()Establish connection
isConnected()Check connection status
signMessage(msg, address)Sign a message
signTransaction(tx)Sign a full CKB transaction (CKB signer only)
getNetwork()Get current network
switchNetwork(network)Switch network

Integration pattern

@ckb-ccc/utxo-global follows the same integration contract as every other wallet package in CCC:

  • Factory functiongetUtxoGlobalSigners returns a SignerInfo[] array.
  • Provider detection — checks for window.utxoGlobal before creating signers.
  • Graceful degradation — returns an empty array when the wallet is unavailable.

References

On this page