# @xchainjs/xchain-doge

> Custom Doge client and utilities used by XChain clients

Latest version **2.3.4** (published 2026-11-11) · MIT license · 0 weekly downloads

## Install

```sh
npm install @xchainjs/xchain-doge
pnpm add @xchainjs/xchain-doge
yarn add @xchainjs/xchain-doge
bun add @xchainjs/xchain-doge
```

## Health

**Score 70/100 (B)** — status: active.

Positive: has types; esm support; no vulnerabilities; recently updated; high maintenance score; high quality score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 2.3.4 |
| Published | 2026-11-11 |
| First published | 2022-01-17 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 11 |
| Unpacked size | 71.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 133 |
| Author | XChainJS |
| Maintainers | xchainjsadmin, thorchain_org, _stu, veado, thatstrangeguy, junkai121, sarawut11, thorswap, hodrthemediocre, polaris_9r, thorianite |
| Keywords | Xchain, Doge |

## Links

- npm: https://www.npmjs.com/package/@xchainjs/xchain-doge
- Repository: https://github.com/xchainjs/xchainjs-lib
- Issues: https://github.com/xchainjs/xchainjs-lib/issues
- npm.io page: https://npm.io/package/@xchainjs/xchain-doge

## Dependencies (11)

- [ecpair](https://npm.io/package/ecpair.md) 2.1.0
- [coinselect](https://npm.io/package/coinselect.md) 3.1.13
- [@scure/bip32](https://npm.io/package/@scure/bip32.md) ^1.7.0
- [bitcoinjs-lib](https://npm.io/package/bitcoinjs-lib.md) 6.1.8
- [@ledgerhq/hw-app-btc](https://npm.io/package/@ledgerhq/hw-app-btc.md) ^10.9.0
- [@xchainjs/xchain-util](https://npm.io/package/@xchainjs/xchain-util.md) 2.0.7
- [@xchainjs/xchain-utxo](https://npm.io/package/@xchainjs/xchain-utxo.md) 2.2.10
- [@xchainjs/xchain-client](https://npm.io/package/@xchainjs/xchain-client.md) 2.0.18
- [@xchainjs/xchain-crypto](https://npm.io/package/@xchainjs/xchain-crypto.md) 1.0.8
- [@xchainjs/xchain-utxo-providers](https://npm.io/package/@xchainjs/xchain-utxo-providers.md) 2.1.2
- [@bitcoin-js/tiny-secp256k1-asmjs](https://npm.io/package/@bitcoin-js/tiny-secp256k1-asmjs.md) ^2.2.3

## Recent versions

- 2.3.4 (latest) — 2026-11-11
- 2.3.3 — 2026-10-06
- 2.3.2 — 2026-08-12
- 2.3.1 — 2026-08-06
- 2.3.0 — 2026-07-20
- 2.2.7 — 2026-06-25
- 2.2.6 — 2026-06-16
- 2.2.5 — 2026-06-03
- 2.2.4 — 2026-05-14
- 2.2.3 — 2026-04-15
- 2.2.2 — 2026-03-12
- 2.2.1 — 2026-02-23
- 2.2.0 — 2026-02-20
- 2.1.0 — 2026-02-17
- 2.0.10 — 2026-02-10
- … 65 more at https://npm.io/package/@xchainjs/xchain-doge/versions

## README

# `@xchainjs/xchain-doge`

## Modules

- `client` - Custom client for communicating with Doge using [BIP39](https://github.com/bitcoinjs/bip39) [bitcoinjs-lib](https://github.com/bitcoinjs/bitcoinjs-lib) and [WIF](https://github.com/bitcoinjs/wif)

## Installation

```
yarn add @xchainjs/xchain-doge
```

Following peer dependencies have to be installed into your project. These are not included in `@xchainjs/xchain-doge`.

```
yarn add @xchainjs/xchain-client @xchainjs/xchain-crypto @xchainjs/xchain-util axios bitcoinjs-lib wif
```

## Documentation

### [`xchain doge`](http://docs.xchainjs.org/xchain-client/xchain-doge/)
[`How xchain-doge works`](http://docs.xchainjs.org/xchain-client/xchain-doge/how-it-works.html)\
[`How to use xchain-doge`](http://docs.xchainjs.org/xchain-client/xchain-doge/how-to-use.html)


## Service Providers

This package uses the following service providers:

| Function                    | Service     | Notes                                                                            |
| --------------------------- | ----------- | -------------------------------------------------------------------------------- |
| Balances                    | Sochain     | https://sochain.com/api#get-balance                                              |
| Transaction history         | Sochain     | https://sochain.com/api#get-display-data-address, https://sochain.com/api#get-tx |
| Transaction details by hash | Sochain     | https://sochain.com/api#get-tx                                                   |
| Transaction fees            | BlockCypher | https://api.blockcypher.com/v1/doge/main                                         |
| Transaction broadcast       | BlockCypher | https://api.blockcypher.com/v1/doge/main/txs/push                                |
| Explorer                    | Blockchair  | https://blockchair.com/dogecoin                                                  |

Sochain API rate limits: https://sochain.com/api#rate-limits (300 requests/minute)

BlockCypher API rate limits: https://api.blockcypher.com/v1/doge/main (5 requests/second)

### UtxoOnlineDataProviders

## default providers

Creating a no-arg DOGE Client will default to the following settings:

```typescript
const defaultDogeParams: UtxoClientParams = {
  network: Network.Mainnet,
  phrase: '',
  explorerProviders: blockstreamExplorerProviders,
  dataProviders: [blockcypherDataProviders],
  rootDerivationPaths: {
    [Network.Mainnet]: `m/44'/3'/0'/0/`,
    [Network.Stagenet]: `m/44'/3'/0'/0/`,
    [Network.Testnet]: `m/44'/1'/0'/0/`,
  },
  feeBounds: {
    lower: LOWER_FEE_BOUND,
    upper: UPPER_FEE_BOUND,
  },
}
```

Note: BlockCypher is the default online data provider (to fetch realtime utxos, balances, etc)

## Overriding providers

You can specify own array of providers, whoch will be executed in array-order, to provide automated failover to the subsequent providers if calls to the first providers fail

### example sochain v3, blockcypher backup

```typescript
import { Client, defaultDogeParams, AssetDOGE, SochainDataProviders, blockcypherDataProviders } from '@xchainjs/xchain-doge'
import { SochainNetwork,  SochainProvider } from '@xchainjs/xchain-utxo-providers'
import { Network, UtxoClientParams } from '@xchainjs/xchain-client'

// override with your API key
SochainDataProviders[Network.Mainnet].apiKey = 'YOUR_SOCHAIN_API_KEY'

// or set in env variables so default config can access.
`SOCHAIN_API_KEY={YOUR_BLOCKCYPHER_API_KEY}`
`BLOCKCYPHER_API_KEY={YOUR_SOCHAIN_API_KEY}`
//Default config can access.
process.env.BLOCKCYPHER_API_KEY
process.env.SOCHAIN_API_KEY

//overridde the default init params with your onfig
const initParams: UtxoClientParams = {
  ...defaultDogeParams,
  dataProviders: [SochainDataProviders, BlockcypherDataProviders]// use sochain first and blockcypher as fallback
  phrase: process.env.PHRASE,
}
const DOGEClient = new Client(sochainParams)

```

---
_Source: https://npm.io/package/@xchainjs/xchain-doge · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
