diff --git a/packages/xchain-arbitrum/CHANGELOG.md b/packages/xchain-arbitrum/CHANGELOG.md index 78c7bfb20..a979c3a3a 100644 --- a/packages/xchain-arbitrum/CHANGELOG.md +++ b/packages/xchain-arbitrum/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.1.2 (2023-12-11) + +## Update + +- Client and EVM client packages update + # v0.1.1 (2023-11-16) ## Update diff --git a/packages/xchain-arbitrum/package.json b/packages/xchain-arbitrum/package.json index 46295c0b3..0b854609a 100644 --- a/packages/xchain-arbitrum/package.json +++ b/packages/xchain-arbitrum/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-arbitrum", - "version": "0.1.1", + "version": "0.1.2", "description": "Arbitrum EVM client for XChainJS", "keywords": [ "XChain", @@ -35,20 +35,20 @@ "access": "public" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-evm": "^0.4.1", + "@xchainjs/xchain-evm": "^0.4.2", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-evm": "^0.4.1", + "@xchainjs/xchain-evm": "^0.4.2", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" } diff --git a/packages/xchain-avax/CHANGELOG.md b/packages/xchain-avax/CHANGELOG.md index 95bcadfe3..59bc43d12 100644 --- a/packages/xchain-avax/CHANGELOG.md +++ b/packages/xchain-avax/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.4.2 (2023-12-11) + +## Update + +- Client and EVM client packages update + # v0.4.1 (2023-11-16) ## Update diff --git a/packages/xchain-avax/package.json b/packages/xchain-avax/package.json index ff6b66232..b213fcec6 100644 --- a/packages/xchain-avax/package.json +++ b/packages/xchain-avax/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-avax", - "version": "0.4.1", + "version": "0.4.2", "description": "Avax EVM client for XChainJS", "keywords": [ "XChain", @@ -35,20 +35,20 @@ "access": "public" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-evm": "^0.4.1", + "@xchainjs/xchain-evm": "^0.4.2", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-evm": "^0.4.1", + "@xchainjs/xchain-evm": "^0.4.2", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" } diff --git a/packages/xchain-binance/CHANGELOG.md b/packages/xchain-binance/CHANGELOG.md index 33a854d7c..270007068 100644 --- a/packages/xchain-binance/CHANGELOG.md +++ b/packages/xchain-binance/CHANGELOG.md @@ -1,3 +1,9 @@ +# v5.7.7 (2023-12-11) + +## Update + +- Client dependency updated + # v5.7.6 (2023-12-01) ## Update diff --git a/packages/xchain-binance/package.json b/packages/xchain-binance/package.json index 73c8c48a3..6e8ff31b2 100644 --- a/packages/xchain-binance/package.json +++ b/packages/xchain-binance/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-binance", - "version": "5.7.6", + "version": "5.7.7", "description": "Custom Binance client and utilities used by XChainJS clients", "keywords": [ "BNB", @@ -35,7 +35,7 @@ "devDependencies": { "@binance-chain/javascript-sdk": "^4.2.0", "@types/big.js": "^6.1.6", - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1" }, @@ -44,7 +44,7 @@ }, "peerDependencies": { "@binance-chain/javascript-sdk": "^4.2.0", - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1" } diff --git a/packages/xchain-bitcoin/CHANGELOG.md b/packages/xchain-bitcoin/CHANGELOG.md index 01825ca46..f2035bedb 100644 --- a/packages/xchain-bitcoin/CHANGELOG.md +++ b/packages/xchain-bitcoin/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.23.8 (2023-12-11) + +## Update + +- UTXO client package dependency + # v0.23.7 (2023-12-06) ## Add diff --git a/packages/xchain-bitcoin/__tests__/client.test.ts b/packages/xchain-bitcoin/__tests__/client.test.ts index 1570f9cfb..7ae395442 100644 --- a/packages/xchain-bitcoin/__tests__/client.test.ts +++ b/packages/xchain-bitcoin/__tests__/client.test.ts @@ -1,5 +1,6 @@ -import { Network, UtxoClientParams } from '@xchainjs/xchain-client' +import { Network } from '@xchainjs/xchain-client' import { baseAmount } from '@xchainjs/xchain-util' +import { UtxoClientParams } from '@xchainjs/xchain-utxo' import mockBitgoApi from '../__mocks__/bitgo' import mockHaskoinApi from '../__mocks__/haskoin' diff --git a/packages/xchain-bitcoin/package.json b/packages/xchain-bitcoin/package.json index 2b46b8bb1..5fcb45fbb 100644 --- a/packages/xchain-bitcoin/package.json +++ b/packages/xchain-bitcoin/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-bitcoin", - "version": "0.23.7", + "version": "0.23.8", "description": "Custom Bitcoin client and utilities used by XChainJS clients", "keywords": [ "XChain", @@ -35,10 +35,11 @@ "devDependencies": { "@ledgerhq/hw-transport-node-hid": "^6.28.0", "@types/wif": "^2.0.2", - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "axios-mock-adapter": "^1.20.0", "bitcoinjs-lib": "5.2.0", @@ -46,10 +47,11 @@ "wif": "^2.0.6" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "bitcoinjs-lib": "5.2.0", "coinselect": "^3.1.12", @@ -61,4 +63,4 @@ "dependencies": { "@ledgerhq/hw-app-btc": "^10.1.0" } -} +} \ No newline at end of file diff --git a/packages/xchain-bitcoin/src/client.ts b/packages/xchain-bitcoin/src/client.ts index dd536d684..62dc65f3c 100644 --- a/packages/xchain-bitcoin/src/client.ts +++ b/packages/xchain-bitcoin/src/client.ts @@ -1,14 +1,6 @@ -import { - AssetInfo, - FeeRate, - Network, - PreparedTx, - TxParams, - UTXO, - UTXOClient, - UtxoClientParams, -} from '@xchainjs/xchain-client' +import { AssetInfo, FeeRate, Network, TxParams } from '@xchainjs/xchain-client' import { Address } from '@xchainjs/xchain-util' +import { Client as UTXOClient, PreparedTx, UTXO, UtxoClientParams } from '@xchainjs/xchain-utxo' import * as Bitcoin from 'bitcoinjs-lib' import accumulative from 'coinselect/accumulative' diff --git a/packages/xchain-bitcoin/src/clientLedger.ts b/packages/xchain-bitcoin/src/clientLedger.ts index fb4548378..649837118 100644 --- a/packages/xchain-bitcoin/src/clientLedger.ts +++ b/packages/xchain-bitcoin/src/clientLedger.ts @@ -1,7 +1,8 @@ import AppBtc from '@ledgerhq/hw-app-btc' import { Transaction } from '@ledgerhq/hw-app-btc/lib/types' -import { FeeOption, FeeRate, TxHash, TxParams, UTXO, UtxoClientParams } from '@xchainjs/xchain-client' +import { FeeOption, FeeRate, TxHash, TxParams } from '@xchainjs/xchain-client' import { Address } from '@xchainjs/xchain-util' +import { UTXO, UtxoClientParams } from '@xchainjs/xchain-utxo' import * as Bitcoin from 'bitcoinjs-lib' import { Client } from './client' diff --git a/packages/xchain-bitcoin/src/const.ts b/packages/xchain-bitcoin/src/const.ts index 08ecc99b5..d641b81cb 100644 --- a/packages/xchain-bitcoin/src/const.ts +++ b/packages/xchain-bitcoin/src/const.ts @@ -1,4 +1,4 @@ -import { ExplorerProvider, Network, UtxoOnlineDataProviders } from '@xchainjs/xchain-client' +import { ExplorerProvider, Network } from '@xchainjs/xchain-client' import { Asset } from '@xchainjs/xchain-util' import { BitgoProvider, @@ -8,6 +8,7 @@ import { HaskoinProvider, SochainNetwork, SochainProvider, + UtxoOnlineDataProviders, } from '@xchainjs/xchain-utxo-providers' /** diff --git a/packages/xchain-bitcoin/src/utils.ts b/packages/xchain-bitcoin/src/utils.ts index 691b26c09..9ff9a8f72 100644 --- a/packages/xchain-bitcoin/src/utils.ts +++ b/packages/xchain-bitcoin/src/utils.ts @@ -1,5 +1,6 @@ -import { Network, UTXO } from '@xchainjs/xchain-client' +import { Network } from '@xchainjs/xchain-client' import { Address } from '@xchainjs/xchain-util' +import { UTXO } from '@xchainjs/xchain-utxo' import * as Bitcoin from 'bitcoinjs-lib' export const TX_EMPTY_SIZE = 4 + 1 + 1 + 4 //10 diff --git a/packages/xchain-bitcoincash/CHANGELOG.md b/packages/xchain-bitcoincash/CHANGELOG.md index 61e2e7de2..9d5788e9b 100644 --- a/packages/xchain-bitcoincash/CHANGELOG.md +++ b/packages/xchain-bitcoincash/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.17.6 (2023-12-11) + +## Update + +- UTXO client package dependency + # v0.17.5 (2023-11-21) ## Update diff --git a/packages/xchain-bitcoincash/package.json b/packages/xchain-bitcoincash/package.json index 1a04ada99..641173631 100644 --- a/packages/xchain-bitcoincash/package.json +++ b/packages/xchain-bitcoincash/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-bitcoincash", - "version": "0.17.5", + "version": "0.17.6", "description": "Custom bitcoincash client and utilities used by XChainJS clients", "keywords": [ "XChain", @@ -40,10 +40,11 @@ "@psf/bitcoincashjs-lib": "^4.0.3", "@types/bchaddrjs": "0.4.0", "@types/uniqid": "^5.3.1", - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "axios-mock-adapter": "^1.20.0", "bchaddrjs": "^0.5.2", @@ -51,10 +52,11 @@ }, "peerDependencies": { "@psf/bitcoincashjs-lib": "^4.0.3", - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "bchaddrjs": "^0.5.2", "coinselect": "3.1.12" diff --git a/packages/xchain-bitcoincash/src/client.ts b/packages/xchain-bitcoincash/src/client.ts index 3e45bda8c..bf924b249 100644 --- a/packages/xchain-bitcoincash/src/client.ts +++ b/packages/xchain-bitcoincash/src/client.ts @@ -1,18 +1,8 @@ import * as bitcash from '@psf/bitcoincashjs-lib' -import { - AssetInfo, - FeeOption, - FeeRate, - Network, - TxHash, - TxParams, - UTXO, - UTXOClient, - UtxoClientParams, - checkFeeBounds, -} from '@xchainjs/xchain-client' +import { AssetInfo, FeeOption, FeeRate, Network, TxHash, TxParams, checkFeeBounds } from '@xchainjs/xchain-client' import { getSeed } from '@xchainjs/xchain-crypto' import { Address } from '@xchainjs/xchain-util' +import { Client as UTXOClient, UTXO, UtxoClientParams } from '@xchainjs/xchain-utxo' import accumulative from 'coinselect/accumulative' import { diff --git a/packages/xchain-bitcoincash/src/const.ts b/packages/xchain-bitcoincash/src/const.ts index a57dc20a1..27d49f554 100644 --- a/packages/xchain-bitcoincash/src/const.ts +++ b/packages/xchain-bitcoincash/src/const.ts @@ -1,6 +1,11 @@ -import { ExplorerProvider, Network, UtxoOnlineDataProviders } from '@xchainjs/xchain-client' +import { ExplorerProvider, Network } from '@xchainjs/xchain-client' import { Asset } from '@xchainjs/xchain-util' -import { BitgoProvider, HaskoinNetwork, HaskoinProvider } from '@xchainjs/xchain-utxo-providers' +import { + BitgoProvider, + HaskoinNetwork, + HaskoinProvider, + UtxoOnlineDataProviders, +} from '@xchainjs/xchain-utxo-providers' export const LOWER_FEE_BOUND = 1 export const UPPER_FEE_BOUND = 500 diff --git a/packages/xchain-bitcoincash/src/types/client-types.ts b/packages/xchain-bitcoincash/src/types/client-types.ts index 1d43996b2..c2b922350 100644 --- a/packages/xchain-bitcoincash/src/types/client-types.ts +++ b/packages/xchain-bitcoincash/src/types/client-types.ts @@ -1,5 +1,6 @@ -import { Balance, FeeOption, Fees, Network, PreparedTx, TxHash, UTXO as BaseUTXO } from '@xchainjs/xchain-client' +import { Balance, FeeOption, Fees, Network, PreparedTx, TxHash } from '@xchainjs/xchain-client' import { Address } from '@xchainjs/xchain-util' +import { UTXO as BaseUTXO } from '@xchainjs/xchain-utxo' export type FeeRate = number export type FeeRates = Record diff --git a/packages/xchain-bsc/CHANGELOG.md b/packages/xchain-bsc/CHANGELOG.md index a5e35f655..0d1eaa891 100644 --- a/packages/xchain-bsc/CHANGELOG.md +++ b/packages/xchain-bsc/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.4.3 (2023-12-11) + +## Update + +- Client and EVM client packages update + # v0.4.2 (2023-11-21) ## Update diff --git a/packages/xchain-bsc/package.json b/packages/xchain-bsc/package.json index 35438235b..c574aa77b 100644 --- a/packages/xchain-bsc/package.json +++ b/packages/xchain-bsc/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-bsc", - "version": "0.4.2", + "version": "0.4.3", "description": "Binance Smart Chain EVM client for XChainJS", "keywords": [ "XChain", @@ -35,20 +35,20 @@ "access": "public" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-evm": "^0.4.1", + "@xchainjs/xchain-evm": "^0.4.2", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-evm": "^0.4.1", + "@xchainjs/xchain-evm": "^0.4.2", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" } diff --git a/packages/xchain-client/CHANGELOG.md b/packages/xchain-client/CHANGELOG.md index d1cfdef09..d1397de10 100644 --- a/packages/xchain-client/CHANGELOG.md +++ b/packages/xchain-client/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.15.6 (2023-12-11) + +## Update + +- UTXO client removed + # v0.15.5 (2023-12-06) ## Add diff --git a/packages/xchain-client/package.json b/packages/xchain-client/package.json index 22f980f56..6dd9bd992 100644 --- a/packages/xchain-client/package.json +++ b/packages/xchain-client/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-client", - "version": "0.15.5", + "version": "0.15.6", "license": "MIT", "main": "lib/index.js", "module": "lib/index.esm.js", diff --git a/packages/xchain-client/src/index.ts b/packages/xchain-client/src/index.ts index bbe17d4db..68328adf3 100644 --- a/packages/xchain-client/src/index.ts +++ b/packages/xchain-client/src/index.ts @@ -1,7 +1,7 @@ export * from './BaseXChainClient' -export * from './UTXOClient' export * from './types' export * from './feeRates' export * from './fees' export * from './explorer-provider' export * from './provider-types' +export * from './protocols' diff --git a/packages/xchain-client/src/protocols.ts b/packages/xchain-client/src/protocols.ts new file mode 100644 index 000000000..52fea7e2a --- /dev/null +++ b/packages/xchain-client/src/protocols.ts @@ -0,0 +1,3 @@ +export enum Protocol { + THORCHAIN = 1, +} diff --git a/packages/xchain-client/src/provider-types.ts b/packages/xchain-client/src/provider-types.ts index 612f267b6..8221e18b8 100644 --- a/packages/xchain-client/src/provider-types.ts +++ b/packages/xchain-client/src/provider-types.ts @@ -1,20 +1,7 @@ import { Address, Asset } from '@xchainjs/xchain-util' import { ExplorerProvider } from './explorer-provider' -import { Balance, FeeRates, Network, Tx, TxHash, TxHistoryParams, TxsPage } from './types' - -export type Witness = { - value: number - script: Buffer -} -export type UTXO = { - hash: string - index: number - value: number - witnessUtxo?: Witness - txHex?: string - scriptPubKey?: string -} +import { Balance, FeeRates, Network, Tx, TxHistoryParams, TxsPage } from './types' export interface OnlineDataProvider { getBalance(address: Address, assets?: Asset[]): Promise @@ -22,15 +9,9 @@ export interface OnlineDataProvider { getTransactionData(txId: string, assetAddress?: Address): Promise getFeeRates(): Promise } -export interface UtxoOnlineDataProvider extends OnlineDataProvider { - getConfirmedUnspentTxs(address: Address): Promise - getUnspentTxs(address: Address): Promise - broadcastTx(txHex: string): Promise -} export type EvmOnlineDataProvider = OnlineDataProvider export type ExplorerProviders = Record export type OnlineDataProviders = Record -export type UtxoOnlineDataProviders = Record export type EvmOnlineDataProviders = Record diff --git a/packages/xchain-client/src/types.ts b/packages/xchain-client/src/types.ts index b8fe80cc4..f6ed3fa79 100644 --- a/packages/xchain-client/src/types.ts +++ b/packages/xchain-client/src/types.ts @@ -1,7 +1,5 @@ import { Address, Asset, BaseAmount } from '@xchainjs/xchain-util' -import { UTXO } from './provider-types' - export enum Network { Mainnet = 'mainnet', Stagenet = 'stagenet', @@ -104,7 +102,6 @@ export type XChainClientParams = { export type PreparedTx = { rawUnsignedTx: string - utxos?: UTXO[] } export interface XChainClient { diff --git a/packages/xchain-cosmos-sdk/CHANGELOG.md b/packages/xchain-cosmos-sdk/CHANGELOG.md index 0091b2481..68ddff83a 100644 --- a/packages/xchain-cosmos-sdk/CHANGELOG.md +++ b/packages/xchain-cosmos-sdk/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.1.4 (2023-12-11) + +## Update + +- Client dependency updated + # v0.1.3 (2023-11-16) ## Update diff --git a/packages/xchain-cosmos-sdk/package.json b/packages/xchain-cosmos-sdk/package.json index 6e89364e4..74f1f02e2 100644 --- a/packages/xchain-cosmos-sdk/package.json +++ b/packages/xchain-cosmos-sdk/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-cosmos-sdk", - "version": "0.1.3", + "version": "0.1.4", "description": "Genereic Cosmos SDK client for XChainJS", "keywords": [ "XChain", @@ -36,12 +36,12 @@ }, "devDependencies": { "@types/secp256k1": "^4.0.3", - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1" }, @@ -51,4 +51,4 @@ "bip32": "^2.0.6", "secp256k1": "^5.0.0" } -} +} \ No newline at end of file diff --git a/packages/xchain-cosmos/CHANGELOG.md b/packages/xchain-cosmos/CHANGELOG.md index 49b1ffa63..41067eb8f 100644 --- a/packages/xchain-cosmos/CHANGELOG.md +++ b/packages/xchain-cosmos/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.21.8 (2023-12-11) + +## Update + +- Client dependency updated + # v0.21.7 (2023-11-16) ## Update diff --git a/packages/xchain-cosmos/package.json b/packages/xchain-cosmos/package.json index 64f9dc4d3..6e4bc64af 100644 --- a/packages/xchain-cosmos/package.json +++ b/packages/xchain-cosmos/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-cosmos", - "version": "0.21.7", + "version": "0.21.8", "description": "Custom Cosmos client and utilities used by XChainJS clients", "keywords": [ "XChain", @@ -32,7 +32,7 @@ "prepublishOnly": "yarn build" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "@cosmos-client/core": "0.46.1", @@ -43,10 +43,10 @@ "access": "public" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "@cosmos-client/core": "0.46.1", "axios": "^1.3.6" } -} +} \ No newline at end of file diff --git a/packages/xchain-dash/CHANGELOG.md b/packages/xchain-dash/CHANGELOG.md index 98cddac42..632bafc25 100644 --- a/packages/xchain-dash/CHANGELOG.md +++ b/packages/xchain-dash/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.2.7 (2023-12-11) + +## Update + +- UTXO client package dependency + # v0.2.6 (2023-12-06) ## Update diff --git a/packages/xchain-dash/package.json b/packages/xchain-dash/package.json index 4b772b911..318632eaa 100644 --- a/packages/xchain-dash/package.json +++ b/packages/xchain-dash/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-dash", - "version": "0.2.6", + "version": "0.2.7", "description": "Custom Dash client and utilities used by XChainJS clients", "keywords": [ "XChain", @@ -35,10 +35,11 @@ "devDependencies": { "@types/bitcoinjs-lib": "^5.0.0", "@types/wif": "^2.0.2", - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "coinselect": "^3.1.12", "axios": "^1.3.6", "axios-mock-adapter": "^1.20.0", @@ -47,10 +48,11 @@ "wif": "^2.0.6" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "coinselect": "^3.1.12", "axios": "^1.3.6", "bitcoinjs-lib": "^5.2.0", @@ -63,4 +65,4 @@ "dependencies": { "@dashevo/dashcore-lib": "^0.19.41" } -} +} \ No newline at end of file diff --git a/packages/xchain-dash/src/client.ts b/packages/xchain-dash/src/client.ts index 19548324c..0387be524 100644 --- a/packages/xchain-dash/src/client.ts +++ b/packages/xchain-dash/src/client.ts @@ -12,14 +12,12 @@ import { TxParams, TxType, TxsPage, - UTXO, - UTXOClient, - UtxoClientParams, checkFeeBounds, } from '@xchainjs/xchain-client' import { getSeed } from '@xchainjs/xchain-crypto' import * as nodeApi from '@xchainjs/xchain-dash/src/node-api' import { Address, assetAmount, assetToBase, baseAmount } from '@xchainjs/xchain-util' +import { Client as UTXOClient, UTXO, UtxoClientParams } from '@xchainjs/xchain-utxo' import * as Dash from 'bitcoinjs-lib' import { diff --git a/packages/xchain-dash/src/const.ts b/packages/xchain-dash/src/const.ts index 409984e16..78e6b152f 100644 --- a/packages/xchain-dash/src/const.ts +++ b/packages/xchain-dash/src/const.ts @@ -1,6 +1,11 @@ -import { ExplorerProvider, Network, UtxoOnlineDataProviders } from '@xchainjs/xchain-client' +import { ExplorerProvider, Network } from '@xchainjs/xchain-client' import { Asset } from '@xchainjs/xchain-util' -import { BitgoProvider, BlockcypherNetwork, BlockcypherProvider } from '@xchainjs/xchain-utxo-providers/lib' +import { + BitgoProvider, + BlockcypherNetwork, + BlockcypherProvider, + UtxoOnlineDataProviders, +} from '@xchainjs/xchain-utxo-providers' /** * Minimum transaction fee diff --git a/packages/xchain-dash/src/types/client-types.ts b/packages/xchain-dash/src/types/client-types.ts index 99ab9eb6e..1782ac60b 100644 --- a/packages/xchain-dash/src/types/client-types.ts +++ b/packages/xchain-dash/src/types/client-types.ts @@ -1,4 +1,5 @@ -import { PreparedTx, UTXO } from '@xchainjs/xchain-client' +import { PreparedTx } from '@xchainjs/xchain-client' +import { UTXO } from '@xchainjs/xchain-utxo' export type DashPreparedTx = { utxos: UTXO[] diff --git a/packages/xchain-dash/src/utils.ts b/packages/xchain-dash/src/utils.ts index b41d9cfb2..81baf754e 100644 --- a/packages/xchain-dash/src/utils.ts +++ b/packages/xchain-dash/src/utils.ts @@ -3,8 +3,9 @@ import { Address as DashAddress } from '@dashevo/dashcore-lib/typings/Address' import { Script } from '@dashevo/dashcore-lib/typings/script/Script' import { Transaction } from '@dashevo/dashcore-lib/typings/transaction/Transaction' import { Input } from '@dashevo/dashcore-lib/typings/transaction/input/Input' -import { FeeRate, Network, TxParams, UTXO } from '@xchainjs/xchain-client' +import { FeeRate, Network, TxParams } from '@xchainjs/xchain-client' import { Address } from '@xchainjs/xchain-util' +import { UTXO } from '@xchainjs/xchain-utxo' import * as Dash from 'bitcoinjs-lib' import * as coininfo from 'coininfo' import accumulative from 'coinselect/accumulative' diff --git a/packages/xchain-doge/CHANGELOG.md b/packages/xchain-doge/CHANGELOG.md index f18afc83c..b403f6104 100644 --- a/packages/xchain-doge/CHANGELOG.md +++ b/packages/xchain-doge/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.7.8 (2023-12-11) + +## Update + +- UTXO client package dependency + # v0.7.7 (2023-11-21) ## Update diff --git a/packages/xchain-doge/__tests__/client.test.ts b/packages/xchain-doge/__tests__/client.test.ts index ca18bda13..5ed8264d7 100644 --- a/packages/xchain-doge/__tests__/client.test.ts +++ b/packages/xchain-doge/__tests__/client.test.ts @@ -1,5 +1,6 @@ -import { Network, UtxoClientParams } from '@xchainjs/xchain-client' +import { Network } from '@xchainjs/xchain-client' import { baseAmount } from '@xchainjs/xchain-util' +import { UtxoClientParams } from '@xchainjs/xchain-utxo' import mocktxId from '../__mocks__/response/broadcast_tx/broadcast_transaction.json' import mockSochainApi from '../__mocks__/sochain' diff --git a/packages/xchain-doge/package.json b/packages/xchain-doge/package.json index 56d0e0181..bff342bbe 100644 --- a/packages/xchain-doge/package.json +++ b/packages/xchain-doge/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-doge", - "version": "0.7.7", + "version": "0.7.8", "description": "Custom Doge client and utilities used by XChain clients", "keywords": [ "Xchain", @@ -33,10 +33,11 @@ "postversion": "git push --follow-tags" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "@types/wif": "^2.0.2", "axios": "^1.3.6", "axios-mock-adapter": "^1.20.0", @@ -46,10 +47,11 @@ "wif": "^2.0.6" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "bitcoinjs-lib": "5.2.0", "coininfo": "5.1.0", diff --git a/packages/xchain-doge/src/client.ts b/packages/xchain-doge/src/client.ts index 966f201a3..5f686e8a9 100644 --- a/packages/xchain-doge/src/client.ts +++ b/packages/xchain-doge/src/client.ts @@ -6,13 +6,11 @@ import { PreparedTx, TxHash, TxParams, - UTXO, - UTXOClient, - UtxoClientParams, checkFeeBounds, } from '@xchainjs/xchain-client' import { getSeed } from '@xchainjs/xchain-crypto' import { Address } from '@xchainjs/xchain-util' +import { Client as UTXOClient, UTXO, UtxoClientParams } from '@xchainjs/xchain-utxo' import * as Dogecoin from 'bitcoinjs-lib' import accumulative from 'coinselect/accumulative' diff --git a/packages/xchain-doge/src/const.ts b/packages/xchain-doge/src/const.ts index 051ae94d5..4c757277a 100644 --- a/packages/xchain-doge/src/const.ts +++ b/packages/xchain-doge/src/const.ts @@ -1,4 +1,4 @@ -import { ExplorerProvider, Network, UtxoOnlineDataProviders } from '@xchainjs/xchain-client' +import { ExplorerProvider, Network } from '@xchainjs/xchain-client' import { Asset } from '@xchainjs/xchain-util' import { BitgoProvider, @@ -6,6 +6,7 @@ import { BlockcypherProvider, SochainNetwork, SochainProvider, + UtxoOnlineDataProviders, } from '@xchainjs/xchain-utxo-providers' /** * Minimum transaction fee diff --git a/packages/xchain-doge/src/types/ledger.ts b/packages/xchain-doge/src/types/ledger.ts index 5f80c597b..eae115da8 100644 --- a/packages/xchain-doge/src/types/ledger.ts +++ b/packages/xchain-doge/src/types/ledger.ts @@ -1,5 +1,6 @@ -import { FeeRate, Network, TxParams, UTXO } from '@xchainjs/xchain-client' +import { FeeRate, Network, TxParams } from '@xchainjs/xchain-client' import { Address } from '@xchainjs/xchain-util' +import { UTXO } from '@xchainjs/xchain-utxo' export type LedgerTxInfo = { utxos: UTXO[] diff --git a/packages/xchain-ethereum/CHANGELOG.md b/packages/xchain-ethereum/CHANGELOG.md index 9da916cf4..12e633ed5 100644 --- a/packages/xchain-ethereum/CHANGELOG.md +++ b/packages/xchain-ethereum/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.31.2 (2023-12-11) + +## Update + +- Client and EVM client packages update + # v0.31.1 (2023-11-16) ## Update diff --git a/packages/xchain-ethereum/package.json b/packages/xchain-ethereum/package.json index 86b8f0f81..037aee6cd 100644 --- a/packages/xchain-ethereum/package.json +++ b/packages/xchain-ethereum/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-ethereum", - "version": "0.31.1", + "version": "0.31.2", "description": "Ethereum EVM client for XChainJS", "keywords": [ "XChain", @@ -35,20 +35,20 @@ "access": "public" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-evm": "^0.4.1", + "@xchainjs/xchain-evm": "^0.4.2", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-evm": "^0.4.1", + "@xchainjs/xchain-evm": "^0.4.2", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" } diff --git a/packages/xchain-evm-providers/CHANGELOG.md b/packages/xchain-evm-providers/CHANGELOG.md index b2eb8cc14..011329b2c 100644 --- a/packages/xchain-evm-providers/CHANGELOG.md +++ b/packages/xchain-evm-providers/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.1.4 (2023-12-11) + +## Update + +- Client dependency updated + # v0.1.3 (2023-11-16) ## Update diff --git a/packages/xchain-evm-providers/package.json b/packages/xchain-evm-providers/package.json index 3388c84b1..9f7bafe06 100644 --- a/packages/xchain-evm-providers/package.json +++ b/packages/xchain-evm-providers/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-evm-providers", - "version": "0.1.3", + "version": "0.1.4", "license": "MIT", "main": "lib/index.js", "module": "lib/index.esm.js", @@ -27,13 +27,13 @@ "access": "public" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6" diff --git a/packages/xchain-evm/CHANGELOG.md b/packages/xchain-evm/CHANGELOG.md index 456d58b30..daa285592 100644 --- a/packages/xchain-evm/CHANGELOG.md +++ b/packages/xchain-evm/CHANGELOG.md @@ -1,3 +1,10 @@ +# v0.4.2 (2023-12-11) + +## Update + +- Client package version update +- Evm-providers package version updated + # v0.4.1 (2023-11-16) ## Update diff --git a/packages/xchain-evm/package.json b/packages/xchain-evm/package.json index 1abface7c..09aa3756b 100644 --- a/packages/xchain-evm/package.json +++ b/packages/xchain-evm/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-evm", - "version": "0.4.1", + "version": "0.4.2", "description": "Genereic EVM client for XChainJS", "keywords": [ "XChain", @@ -34,15 +34,15 @@ "access": "public" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-evm-providers": "^0.1.3", + "@xchainjs/xchain-evm-providers": "^0.1.4", "axios": "^1.3.6", "ethers": "^5.7.2" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", diff --git a/packages/xchain-evm/src/client.ts b/packages/xchain-evm/src/client.ts index 027c38046..722b28516 100644 --- a/packages/xchain-evm/src/client.ts +++ b/packages/xchain-evm/src/client.ts @@ -11,6 +11,7 @@ import { Fees, Network, PreparedTx, + Protocol, Tx, TxHash, TxHistoryParams, @@ -46,9 +47,6 @@ import { validateAddress, } from './utils' -export enum Protocol { - THORCHAIN = 1, -} /** * Interface for custom EVM client */ diff --git a/packages/xchain-kujira/CHANGELOG.md b/packages/xchain-kujira/CHANGELOG.md index f74abcb3e..ab1bf8a79 100644 --- a/packages/xchain-kujira/CHANGELOG.md +++ b/packages/xchain-kujira/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.1.4 (2023-12-11) + +## Update + +- Client and Cosmos client dependency updated + # v0.1.3 (2023-12-06) ## Update diff --git a/packages/xchain-kujira/package.json b/packages/xchain-kujira/package.json index 4cf08f55b..75342ccc0 100644 --- a/packages/xchain-kujira/package.json +++ b/packages/xchain-kujira/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-kujira", - "version": "0.1.3", + "version": "0.1.4", "description": "Custom Kujira client", "keywords": [ "XChain", @@ -32,16 +32,16 @@ "prepublishOnly": "yarn build" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-util": "^0.13.2", - "@xchainjs/xchain-cosmos-sdk": "^0.1.3" + "@xchainjs/xchain-cosmos-sdk": "^0.1.4" }, "publishConfig": { "access": "public" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-util": "^0.13.2", - "@xchainjs/xchain-cosmos-sdk": "^0.1.3" + "@xchainjs/xchain-cosmos-sdk": "^0.1.4" } } \ No newline at end of file diff --git a/packages/xchain-litecoin/CHANGELOG.md b/packages/xchain-litecoin/CHANGELOG.md index 5f2299d9a..74f401af1 100644 --- a/packages/xchain-litecoin/CHANGELOG.md +++ b/packages/xchain-litecoin/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.13.7 (2023-12-11) + +## Update + +- UTXO client package dependency + # v0.13.6 (2023-11-21) ## Update diff --git a/packages/xchain-litecoin/__tests__/client.test.ts b/packages/xchain-litecoin/__tests__/client.test.ts index e839c8e5b..b368bbdb1 100644 --- a/packages/xchain-litecoin/__tests__/client.test.ts +++ b/packages/xchain-litecoin/__tests__/client.test.ts @@ -1,5 +1,6 @@ -import { Network, UtxoClientParams } from '@xchainjs/xchain-client' +import { Network } from '@xchainjs/xchain-client' import { baseAmount } from '@xchainjs/xchain-util' +import { UtxoClientParams } from '@xchainjs/xchain-utxo' import mockSochainApi from '../__mocks__/sochain' import mockThornodeApi from '../__mocks__/thornode-api' diff --git a/packages/xchain-litecoin/__tests__/utils.test.ts b/packages/xchain-litecoin/__tests__/utils.test.ts index b33d467ea..10a5479e3 100644 --- a/packages/xchain-litecoin/__tests__/utils.test.ts +++ b/packages/xchain-litecoin/__tests__/utils.test.ts @@ -1,4 +1,5 @@ -import { Network, UTXO } from '@xchainjs/xchain-client' +import { Network } from '@xchainjs/xchain-client' +import { UTXO } from '@xchainjs/xchain-utxo' import mockSochainApi from '../__mocks__/sochain' import mockThornodeApi from '../__mocks__/thornode-api' diff --git a/packages/xchain-litecoin/package.json b/packages/xchain-litecoin/package.json index 44112b79a..6aeff149f 100644 --- a/packages/xchain-litecoin/package.json +++ b/packages/xchain-litecoin/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-litecoin", - "version": "0.13.6", + "version": "0.13.7", "description": "Custom Litecoin client and utilities used by XChainJS clients", "keywords": [ "XChain", @@ -34,10 +34,11 @@ }, "devDependencies": { "@types/wif": "^2.0.2", - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "axios-mock-adapter": "^1.20.0", "bitcoinjs-lib": "^5.2.0", @@ -46,10 +47,11 @@ "wif": "^2.0.6" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo": "^0.1.0", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "bitcoinjs-lib": "5.2.0", "coininfo": "^5.1.0", diff --git a/packages/xchain-litecoin/src/client.ts b/packages/xchain-litecoin/src/client.ts index 9ec374cfb..8b7b709bc 100644 --- a/packages/xchain-litecoin/src/client.ts +++ b/packages/xchain-litecoin/src/client.ts @@ -6,13 +6,11 @@ import { PreparedTx, TxHash, TxParams, - UTXO, - UTXOClient, - UtxoClientParams, checkFeeBounds, } from '@xchainjs/xchain-client' import { getSeed } from '@xchainjs/xchain-crypto' import { Address } from '@xchainjs/xchain-util' +import { Client as UTXOClient, UTXO, UtxoClientParams } from '@xchainjs/xchain-utxo' import * as Litecoin from 'bitcoinjs-lib' import accumulative from 'coinselect/accumulative' diff --git a/packages/xchain-litecoin/src/const.ts b/packages/xchain-litecoin/src/const.ts index cb0c6ec9f..680266700 100644 --- a/packages/xchain-litecoin/src/const.ts +++ b/packages/xchain-litecoin/src/const.ts @@ -1,4 +1,4 @@ -import { ExplorerProvider, Network, UtxoOnlineDataProviders } from '@xchainjs/xchain-client' +import { ExplorerProvider, Network } from '@xchainjs/xchain-client' import { Asset } from '@xchainjs/xchain-util' import { BitgoProvider, @@ -6,6 +6,7 @@ import { BlockcypherProvider, SochainNetwork, SochainProvider, + UtxoOnlineDataProviders, } from '@xchainjs/xchain-utxo-providers' /** diff --git a/packages/xchain-litecoin/src/types/ledger.ts b/packages/xchain-litecoin/src/types/ledger.ts index 8d42fc2b4..31ab2e0a4 100644 --- a/packages/xchain-litecoin/src/types/ledger.ts +++ b/packages/xchain-litecoin/src/types/ledger.ts @@ -1,5 +1,6 @@ -import { FeeRate, Network, TxParams, UTXO } from '@xchainjs/xchain-client' +import { FeeRate, Network, TxParams } from '@xchainjs/xchain-client' import { Address } from '@xchainjs/xchain-util' +import { UTXO } from '@xchainjs/xchain-utxo' export type LedgerTxInfo = { utxos: UTXO[] diff --git a/packages/xchain-litecoin/src/utils.ts b/packages/xchain-litecoin/src/utils.ts index 6589935a5..00bdf9f35 100644 --- a/packages/xchain-litecoin/src/utils.ts +++ b/packages/xchain-litecoin/src/utils.ts @@ -1,5 +1,6 @@ -import { Balance, Network, TxHash, UTXO } from '@xchainjs/xchain-client' +import { Balance, Network, TxHash } from '@xchainjs/xchain-client' import { Address, assetAmount, assetToBase } from '@xchainjs/xchain-util' +import { UTXO } from '@xchainjs/xchain-utxo' import * as Litecoin from 'bitcoinjs-lib' import coininfo from 'coininfo' diff --git a/packages/xchain-mayachain-amm/CHANGELOG.md b/packages/xchain-mayachain-amm/CHANGELOG.md index 1f103fa66..506df5be8 100644 --- a/packages/xchain-mayachain-amm/CHANGELOG.md +++ b/packages/xchain-mayachain-amm/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.1.2 (2023-12-11) + +## Update + +- Client dependency updated + # v0.1.1 (2023-12-11) ## Update diff --git a/packages/xchain-mayachain-amm/package.json b/packages/xchain-mayachain-amm/package.json index 8e1b15230..84dac92e1 100644 --- a/packages/xchain-mayachain-amm/package.json +++ b/packages/xchain-mayachain-amm/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-mayachain-amm", - "version": "0.1.1", + "version": "0.1.2", "description": "module that exposes estimating & swapping cryptocurrency assets on mayachain", "keywords": [ "MAYAChain", @@ -38,20 +38,21 @@ "devDependencies": { "@cosmos-client/core": "0.46.1", "@psf/bitcoincashjs-lib": "^4.0.3", - "@xchainjs/xchain-bitcoin": "^0.23.6", - "@xchainjs/xchain-client": "^0.15.4", - "@xchainjs/xchain-cosmos-sdk": "^0.1.3", + "@xchainjs/xchain-bitcoin": "^0.23.8", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-cosmos-sdk": "^0.1.4", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-dash": "^0.2.6", + "@xchainjs/xchain-dash": "^0.2.7", "@xchainjs/xchain-ethereum": "^0.31.1", "@xchainjs/xchain-mayanode": "^0.1.2", - "@xchainjs/xchain-mayachain-query": "^0.1.2", + "@xchainjs/xchain-mayachain-query": "^0.1.3", "@xchainjs/xchain-evm": "^0.4.1", - "@xchainjs/xchain-kujira": "^0.1.3", - "@xchainjs/xchain-mayachain": "^0.2.10", + "@xchainjs/xchain-kujira": "^0.1.4", + "@xchainjs/xchain-mayachain": "^0.2.12", "@xchainjs/xchain-mayamidgard": "^0.1.0", - "@xchainjs/xchain-thorchain": "^0.28.13", + "@xchainjs/xchain-thorchain": "^0.28.15", "@xchainjs/xchain-util": "^0.13.1", + "@xchainjs/xchain-utxo": "^0.1.0", "@xchainjs/xchain-utxo-providers": "^0.2.8", "axios": "^1.3.6", "axios-retry": "^3.2.5", @@ -66,20 +67,21 @@ "peerDependencies": { "@cosmos-client/core": "0.46.1", "@psf/bitcoincashjs-lib": "^4.0.3", - "@xchainjs/xchain-bitcoin": "^0.23.6", - "@xchainjs/xchain-client": "^0.15.4", - "@xchainjs/xchain-cosmos-sdk": "^0.1.3", + "@xchainjs/xchain-bitcoin": "^0.23.8", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-cosmos-sdk": "^0.1.4", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-dash": "^0.2.6", + "@xchainjs/xchain-dash": "^0.2.7", "@xchainjs/xchain-ethereum": "^0.31.1", "@xchainjs/xchain-mayanode": "^0.1.2", - "@xchainjs/xchain-mayachain-query": "^0.1.2", + "@xchainjs/xchain-mayachain-query": "^0.1.3", "@xchainjs/xchain-evm": "^0.4.1", - "@xchainjs/xchain-kujira": "^0.1.3", - "@xchainjs/xchain-mayachain": "^0.2.10", + "@xchainjs/xchain-kujira": "^0.1.4", + "@xchainjs/xchain-mayachain": "^0.2.12", "@xchainjs/xchain-mayamidgard": "^0.1.0", - "@xchainjs/xchain-thorchain": "^0.28.13", + "@xchainjs/xchain-thorchain": "^0.28.15", "@xchainjs/xchain-util": "^0.13.1", + "@xchainjs/xchain-utxo": "^0.1.0", "@xchainjs/xchain-utxo-providers": "^0.2.8", "axios": "^1.3.6", "axios-retry": "^3.2.5", diff --git a/packages/xchain-mayachain-amm/src/wallet.ts b/packages/xchain-mayachain-amm/src/wallet.ts index a0837d944..92ff6f81d 100644 --- a/packages/xchain-mayachain-amm/src/wallet.ts +++ b/packages/xchain-mayachain-amm/src/wallet.ts @@ -1,5 +1,5 @@ import { BTCChain, Client as BtcClient, defaultBTCParams as defaultBtcParams } from '@xchainjs/xchain-bitcoin' -import { Network, TxParams, UtxoClientParams, XChainClient, XChainClientParams } from '@xchainjs/xchain-client' +import { Network, TxParams, XChainClient, XChainClientParams } from '@xchainjs/xchain-client' import { CosmosSdkClientParams } from '@xchainjs/xchain-cosmos-sdk' import { Client as DashClient, DASHChain, defaultDashParams } from '@xchainjs/xchain-dash' import { AssetETH, Client as EthClient, ETHChain, defaultEthParams } from '@xchainjs/xchain-ethereum' @@ -14,6 +14,7 @@ import { } from '@xchainjs/xchain-mayachain' import { Client as ThorClient, THORChain, ThorchainClientParams } from '@xchainjs/xchain-thorchain' import { Asset, BaseAmount, Chain, assetToString, getContractAddressFromAsset } from '@xchainjs/xchain-util' +import { UtxoClientParams } from '@xchainjs/xchain-utxo' import { ethers } from 'ethers' export type NodeUrls = Record diff --git a/packages/xchain-mayachain-query/CHANGELOG.md b/packages/xchain-mayachain-query/CHANGELOG.md index 439b12a2b..0ae965043 100644 --- a/packages/xchain-mayachain-query/CHANGELOG.md +++ b/packages/xchain-mayachain-query/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.1.3 (2023-12-11) + +## Update + +- Client dependency updated + # v0.1.2 (2023-12-11) ## Update diff --git a/packages/xchain-mayachain-query/package.json b/packages/xchain-mayachain-query/package.json index 601718e07..69dafa88e 100644 --- a/packages/xchain-mayachain-query/package.json +++ b/packages/xchain-mayachain-query/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-mayachain-query", - "version": "0.1.2", + "version": "0.1.3", "license": "MIT", "description": "Mayachain query module that is responsible for estimating swap calculations and add/remove liquidity for thorchain", "keywords": [ @@ -33,8 +33,8 @@ "postversion": "git push --follow-tags" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", - "@xchainjs/xchain-mayamidgard-query": "^0.1.1", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-mayamidgard-query": "^0.1.2", "@xchainjs/xchain-mayanode": "^0.1.2", "@xchainjs/xchain-util": "^0.13.0", "axios": "^1.3.6", @@ -42,8 +42,8 @@ "bignumber.js": "^9.0.0" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", - "@xchainjs/xchain-mayamidgard-query": "^0.1.1", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-mayamidgard-query": "^0.1.2", "@xchainjs/xchain-mayanode": "^0.1.2", "@xchainjs/xchain-util": "^0.13.0", "axios": "^1.3.6", diff --git a/packages/xchain-mayachain/CHANGELOG.md b/packages/xchain-mayachain/CHANGELOG.md index 78a1ba672..10a5ec43c 100644 --- a/packages/xchain-mayachain/CHANGELOG.md +++ b/packages/xchain-mayachain/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.2.12 (2023-12-11) + +## Update + +- Client and Cosmos client dependency updated + # v0.2.11 (2023-11-27) ## Update diff --git a/packages/xchain-mayachain/package.json b/packages/xchain-mayachain/package.json index a0ccee40a..467701318 100644 --- a/packages/xchain-mayachain/package.json +++ b/packages/xchain-mayachain/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-mayachain", - "version": "0.2.11", + "version": "0.2.12", "description": "Custom Mayachain client and utilities used by XChainJS clients", "keywords": [ "MAYAChain", @@ -36,8 +36,8 @@ "devDependencies": { "@cosmos-client/core": "0.46.1", "@types/big.js": "^6.1.6", - "@xchainjs/xchain-client": "^0.15.5", - "@xchainjs/xchain-cosmos": "^0.21.7", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-cosmos": "^0.21.8", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", @@ -49,11 +49,11 @@ }, "peerDependencies": { "@cosmos-client/core": "0.46.1", - "@xchainjs/xchain-client": "^0.15.5", - "@xchainjs/xchain-cosmos": "^0.21.7", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-cosmos": "^0.21.8", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", "bech32-buffer": "^0.2.0" } -} +} \ No newline at end of file diff --git a/packages/xchain-mayamidgard-query/CHANGELOG.md b/packages/xchain-mayamidgard-query/CHANGELOG.md index 2bd6d1cc6..f7952740d 100644 --- a/packages/xchain-mayamidgard-query/CHANGELOG.md +++ b/packages/xchain-mayamidgard-query/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.1.2 (2023-12-11) + +## Update + +- Client dependency updated + # v0.1.1 (2023-12-11) ## Update diff --git a/packages/xchain-mayamidgard-query/package.json b/packages/xchain-mayamidgard-query/package.json index 61cdef635..19006ff1c 100644 --- a/packages/xchain-mayamidgard-query/package.json +++ b/packages/xchain-mayamidgard-query/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-mayamidgard-query", - "version": "0.1.1", + "version": "0.1.2", "license": "MIT", "description": "Module that is responsible for get data from Mayachain Midgard API", "keywords": [ @@ -32,7 +32,7 @@ "postversion": "git push --follow-tags" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-mayamidgard": "^0.1.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", @@ -40,7 +40,7 @@ "bignumber.js": "^9.0.0" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-mayamidgard": "^0.1.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", diff --git a/packages/xchain-midgard-query/CHANGELOG.md b/packages/xchain-midgard-query/CHANGELOG.md index 94b670f5d..3396171cb 100644 --- a/packages/xchain-midgard-query/CHANGELOG.md +++ b/packages/xchain-midgard-query/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.1.8 (2023-12-11) + +## Update + +- Client dependency updated + # v0.1.7 (2023-11-21) ## Update diff --git a/packages/xchain-midgard-query/package.json b/packages/xchain-midgard-query/package.json index 1af4abe7f..31f3655f6 100644 --- a/packages/xchain-midgard-query/package.json +++ b/packages/xchain-midgard-query/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-midgard-query", - "version": "0.1.7", + "version": "0.1.8", "license": "MIT", "description": "Module that is responsible for get data from Midgard API", "keywords": [ @@ -32,7 +32,7 @@ "postversion": "git push --follow-tags" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-midgard": "^0.5.2", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", @@ -40,7 +40,7 @@ "bignumber.js": "^9.0.0" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-midgard": "^0.5.2", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", diff --git a/packages/xchain-thorchain-amm/CHANGELOG.md b/packages/xchain-thorchain-amm/CHANGELOG.md index 81126b84e..9d75f673e 100644 --- a/packages/xchain-thorchain-amm/CHANGELOG.md +++ b/packages/xchain-thorchain-amm/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.8.9 (2023-12-11) + +## Update + +- Client dependencies updated + # v0.8.8 (2023-12-08) ## Update diff --git a/packages/xchain-thorchain-amm/package.json b/packages/xchain-thorchain-amm/package.json index 35982cbb1..ff120d030 100644 --- a/packages/xchain-thorchain-amm/package.json +++ b/packages/xchain-thorchain-amm/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-thorchain-amm", - "version": "0.8.8", + "version": "0.8.9", "description": "module that exposes estimating & swappping cryptocurrency assets on thorchain", "keywords": [ "THORChain", @@ -39,25 +39,25 @@ "@binance-chain/javascript-sdk": "^4.2.0", "@cosmos-client/core": "0.46.1", "@psf/bitcoincashjs-lib": "^4.0.3", - "@xchainjs/xchain-avax": "^0.4.1", - "@xchainjs/xchain-binance": "^5.7.6", - "@xchainjs/xchain-bitcoin": "^0.23.7", - "@xchainjs/xchain-bitcoincash": "^0.17.5", - "@xchainjs/xchain-client": "^0.15.5", - "@xchainjs/xchain-cosmos": "^0.21.7", - "@xchainjs/xchain-bsc": "^0.4.2", + "@xchainjs/xchain-avax": "^0.4.2", + "@xchainjs/xchain-binance": "^5.7.7", + "@xchainjs/xchain-bitcoin": "^0.23.8", + "@xchainjs/xchain-bitcoincash": "^0.17.6", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-cosmos": "^0.21.8", + "@xchainjs/xchain-bsc": "^0.4.3", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-doge": "^0.7.7", - "@xchainjs/xchain-ethereum": "^0.31.1", + "@xchainjs/xchain-doge": "^0.7.8", + "@xchainjs/xchain-ethereum": "^0.31.2", "@xchainjs/xchain-thornode": "^0.3.8", "@xchainjs/xchain-thorchain-query": "^0.6.13", - "@xchainjs/xchain-evm": "^0.4.1", - "@xchainjs/xchain-litecoin": "^0.13.6", - "@xchainjs/xchain-mayachain": "^0.2.10", + "@xchainjs/xchain-evm": "^0.4.2", + "@xchainjs/xchain-litecoin": "^0.13.7", + "@xchainjs/xchain-mayachain": "^0.2.12", "@xchainjs/xchain-midgard": "^0.5.2", - "@xchainjs/xchain-thorchain": "^0.28.14", + "@xchainjs/xchain-thorchain": "^0.28.15", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "axios-retry": "^3.2.5", "bchaddrjs": "^0.5.2", @@ -75,25 +75,25 @@ "@binance-chain/javascript-sdk": "^4.2.0", "@cosmos-client/core": "0.46.1", "@psf/bitcoincashjs-lib": "^4.0.3", - "@xchainjs/xchain-avax": "^0.4.1", - "@xchainjs/xchain-binance": "^5.7.6", - "@xchainjs/xchain-bitcoin": "^0.23.7", - "@xchainjs/xchain-bitcoincash": "^0.17.5", - "@xchainjs/xchain-client": "^0.15.5", - "@xchainjs/xchain-cosmos": "^0.21.7", - "@xchainjs/xchain-bsc": "^0.4.2", + "@xchainjs/xchain-avax": "^0.4.2", + "@xchainjs/xchain-binance": "^5.7.7", + "@xchainjs/xchain-bitcoin": "^0.23.8", + "@xchainjs/xchain-bitcoincash": "^0.17.6", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-cosmos": "^0.21.8", + "@xchainjs/xchain-bsc": "^0.4.3", "@xchainjs/xchain-crypto": "^0.3.0", - "@xchainjs/xchain-doge": "^0.7.7", - "@xchainjs/xchain-ethereum": "^0.31.1", + "@xchainjs/xchain-doge": "^0.7.8", + "@xchainjs/xchain-ethereum": "^0.31.2", "@xchainjs/xchain-thornode": "^0.3.8", "@xchainjs/xchain-thorchain-query": "^0.6.13", - "@xchainjs/xchain-evm": "^0.4.1", - "@xchainjs/xchain-litecoin": "^0.13.6", - "@xchainjs/xchain-mayachain": "^0.2.10", + "@xchainjs/xchain-evm": "^0.4.2", + "@xchainjs/xchain-litecoin": "^0.13.7", + "@xchainjs/xchain-mayachain": "^0.2.12", "@xchainjs/xchain-midgard": "^0.5.2", - "@xchainjs/xchain-thorchain": "^0.28.14", + "@xchainjs/xchain-thorchain": "^0.28.15", "@xchainjs/xchain-util": "^0.13.1", - "@xchainjs/xchain-utxo-providers": "^0.2.8", + "@xchainjs/xchain-utxo-providers": "^0.2.9", "axios": "^1.3.6", "axios-retry": "^3.2.5", "bchaddrjs": "^0.5.2", diff --git a/packages/xchain-thorchain-amm/src/utils/evm-helper.ts b/packages/xchain-thorchain-amm/src/utils/evm-helper.ts index a6ea5dfd2..d83e1ba57 100644 --- a/packages/xchain-thorchain-amm/src/utils/evm-helper.ts +++ b/packages/xchain-thorchain-amm/src/utils/evm-helper.ts @@ -1,5 +1,5 @@ -import { TxHash, XChainClient } from '@xchainjs/xchain-client' -import { ApproveParams, Client as EvmClient, MAX_APPROVAL, Protocol, abi } from '@xchainjs/xchain-evm' +import { Protocol, TxHash, XChainClient } from '@xchainjs/xchain-client' +import { ApproveParams, Client as EvmClient, MAX_APPROVAL, abi } from '@xchainjs/xchain-evm' import { ThorchainCache } from '@xchainjs/xchain-thorchain-query' import { Asset, BaseAmount, baseAmount, eqAsset, getContractAddressFromAsset } from '@xchainjs/xchain-util' import { ethers } from 'ethers' diff --git a/packages/xchain-thorchain-amm/src/wallet.ts b/packages/xchain-thorchain-amm/src/wallet.ts index 7ef395afe..5b1e85fde 100644 --- a/packages/xchain-thorchain-amm/src/wallet.ts +++ b/packages/xchain-thorchain-amm/src/wallet.ts @@ -3,15 +3,7 @@ import { BNBChain, Client as BnbClient } from '@xchainjs/xchain-binance' import { BTCChain, Client as BtcClient, defaultBTCParams as defaultBtcParams } from '@xchainjs/xchain-bitcoin' import { BCHChain, Client as BchClient, defaultBchParams } from '@xchainjs/xchain-bitcoincash' import { BSCChain, Client as BscClient, defaultBscParams } from '@xchainjs/xchain-bsc' -import { - FeeOption, - Network, - Protocol, - UTXOClient, - UtxoClientParams, - XChainClient, - XChainClientParams, -} from '@xchainjs/xchain-client' +import { FeeOption, Network, Protocol, XChainClient, XChainClientParams } from '@xchainjs/xchain-client' import { Client as CosmosClient, GAIAChain } from '@xchainjs/xchain-cosmos' import { Client as DogeClient, DOGEChain, defaultDogeParams } from '@xchainjs/xchain-doge' import { Client as EthClient, ETHChain, defaultEthParams } from '@xchainjs/xchain-ethereum' @@ -21,6 +13,7 @@ import { Client as MayaClient, MAYAChain, MayachainClientParams } from '@xchainj import { Client as ThorClient, THORChain, ThorchainClient, ThorchainClientParams } from '@xchainjs/xchain-thorchain' import { CryptoAmount, ThorchainQuery } from '@xchainjs/xchain-thorchain-query' import { Address, Asset, assetFromString } from '@xchainjs/xchain-util' +import { Client as UTXOClient, UtxoClientParams } from '@xchainjs/xchain-utxo' import { AddLiquidity, diff --git a/packages/xchain-thorchain-query/CHANGELOG.md b/packages/xchain-thorchain-query/CHANGELOG.md index a4dd353ab..a02a47505 100644 --- a/packages/xchain-thorchain-query/CHANGELOG.md +++ b/packages/xchain-thorchain-query/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.6.14 (2023-12-03) + +## Update + +- Client and midgard-query dependencies updated + # v0.6.13 (2023-11-28) ## Update diff --git a/packages/xchain-thorchain-query/package.json b/packages/xchain-thorchain-query/package.json index ce2061692..3da18abff 100644 --- a/packages/xchain-thorchain-query/package.json +++ b/packages/xchain-thorchain-query/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-thorchain-query", - "version": "0.6.13", + "version": "0.6.14", "license": "MIT", "description": "Thorchain query module that is resposible for estimating swap calculations and add/remove liquidity for thorchain ", "keywords": [ @@ -33,18 +33,18 @@ "postversion": "git push --follow-tags" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-thornode": "^0.3.8", - "@xchainjs/xchain-midgard-query": "^0.1.6", + "@xchainjs/xchain-midgard-query": "^0.1.8", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", "axios-retry": "^3.2.5", "bignumber.js": "^9.0.0" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-thornode": "^0.3.8", - "@xchainjs/xchain-midgard-query": "^0.1.6", + "@xchainjs/xchain-midgard-query": "^0.1.8", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", "axios-retry": "^3.2.5", diff --git a/packages/xchain-thorchain/CHANGELOG.md b/packages/xchain-thorchain/CHANGELOG.md index 09fae762b..43615db0b 100644 --- a/packages/xchain-thorchain/CHANGELOG.md +++ b/packages/xchain-thorchain/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.28.15 (2023-12-11) + +## Update + +- Client and Cosmos client dependency update + # v0.28.14 (2023-12-07) ## Update diff --git a/packages/xchain-thorchain/package.json b/packages/xchain-thorchain/package.json index 7f1430d5c..5f585bf9d 100644 --- a/packages/xchain-thorchain/package.json +++ b/packages/xchain-thorchain/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-thorchain", - "version": "0.28.14", + "version": "0.28.15", "description": "Custom Thorchain client and utilities used by XChainJS clients", "keywords": [ "THORChain", @@ -36,8 +36,8 @@ "devDependencies": { "@cosmos-client/core": "0.46.1", "@types/big.js": "^6.1.6", - "@xchainjs/xchain-client": "^0.15.5", - "@xchainjs/xchain-cosmos": "^0.21.7", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-cosmos": "^0.21.8", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", @@ -49,8 +49,8 @@ }, "peerDependencies": { "@cosmos-client/core": "0.46.1", - "@xchainjs/xchain-client": "^0.15.5", - "@xchainjs/xchain-cosmos": "^0.21.7", + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-cosmos": "^0.21.8", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6", diff --git a/packages/xchain-utxo-providers/CHANGELOG.md b/packages/xchain-utxo-providers/CHANGELOG.md index 3f4f6ffc8..b1330d2a5 100644 --- a/packages/xchain-utxo-providers/CHANGELOG.md +++ b/packages/xchain-utxo-providers/CHANGELOG.md @@ -1,3 +1,9 @@ +# v0.2.9 (2023-12-01) + +## Update + +- Client package version update + # v0.2.8 (2023-11-21) ## Update diff --git a/packages/xchain-utxo-providers/package.json b/packages/xchain-utxo-providers/package.json index 520811d76..4cb4a20df 100644 --- a/packages/xchain-utxo-providers/package.json +++ b/packages/xchain-utxo-providers/package.json @@ -1,6 +1,6 @@ { "name": "@xchainjs/xchain-utxo-providers", - "version": "0.2.8", + "version": "0.2.9", "license": "MIT", "main": "lib/index.js", "module": "lib/index.esm.js", @@ -27,13 +27,13 @@ "access": "public" }, "devDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6" }, "peerDependencies": { - "@xchainjs/xchain-client": "^0.15.5", + "@xchainjs/xchain-client": "^0.15.6", "@xchainjs/xchain-crypto": "^0.3.0", "@xchainjs/xchain-util": "^0.13.1", "axios": "^1.3.6" diff --git a/packages/xchain-utxo-providers/src/providers/bitgo/bitgo-data-provider.ts b/packages/xchain-utxo-providers/src/providers/bitgo/bitgo-data-provider.ts index a65bbc617..fb4543f42 100644 --- a/packages/xchain-utxo-providers/src/providers/bitgo/bitgo-data-provider.ts +++ b/packages/xchain-utxo-providers/src/providers/bitgo/bitgo-data-provider.ts @@ -1,6 +1,8 @@ -import { Balance, FeeOption, FeeRates, Tx, TxsPage, UTXO, UtxoOnlineDataProvider } from '@xchainjs/xchain-client' +import { Balance, FeeOption, FeeRates, Tx, TxsPage } from '@xchainjs/xchain-client' import { Chain } from '@xchainjs/xchain-util' +import { UTXO, UtxoOnlineDataProvider } from '../types' + import { getFeeEstimate } from './bitgo-api' export interface BitgoConfig { diff --git a/packages/xchain-utxo-providers/src/providers/blockcypher/blockcypher-data-provider.ts b/packages/xchain-utxo-providers/src/providers/blockcypher/blockcypher-data-provider.ts index c7b062677..efcae410d 100644 --- a/packages/xchain-utxo-providers/src/providers/blockcypher/blockcypher-data-provider.ts +++ b/packages/xchain-utxo-providers/src/providers/blockcypher/blockcypher-data-provider.ts @@ -1,18 +1,9 @@ import PromisePool from '@supercharge/promise-pool' -import { - Balance, - FeeOption, - FeeRates, - Tx, - TxHash, - TxHistoryParams, - TxType, - TxsPage, - UTXO, - UtxoOnlineDataProvider, -} from '@xchainjs/xchain-client' +import { Balance, FeeOption, FeeRates, Tx, TxHash, TxHistoryParams, TxType, TxsPage } from '@xchainjs/xchain-client' import { Address, Asset, Chain, baseAmount } from '@xchainjs/xchain-util' +import { UTXO, UtxoOnlineDataProvider } from '../types' + import * as blockcypher from './blockcypher-api' import { BlockcypherNetwork, Transaction } from './blockcypher-api-types' diff --git a/packages/xchain-utxo-providers/src/providers/haskoin/haskoin-data-provider.ts b/packages/xchain-utxo-providers/src/providers/haskoin/haskoin-data-provider.ts index b4d538f1c..7475342e0 100644 --- a/packages/xchain-utxo-providers/src/providers/haskoin/haskoin-data-provider.ts +++ b/packages/xchain-utxo-providers/src/providers/haskoin/haskoin-data-provider.ts @@ -1,16 +1,8 @@ -import { - Balance, - FeeRates, - Tx, - TxHash, - TxHistoryParams, - TxType, - TxsPage, - UTXO, - UtxoOnlineDataProvider, -} from '@xchainjs/xchain-client' +import { Balance, FeeRates, Tx, TxHash, TxHistoryParams, TxType, TxsPage } from '@xchainjs/xchain-client' import { Address, Asset, Chain, baseAmount } from '@xchainjs/xchain-util' +import { UTXO, UtxoOnlineDataProvider } from '../types' + import * as haskoin from './haskoin-api' import { HaskoinNetwork, Transaction, TxUnspent } from './haskoin-api-types' diff --git a/packages/xchain-utxo-providers/src/providers/index.ts b/packages/xchain-utxo-providers/src/providers/index.ts index e85f3b6cc..4e266e045 100644 --- a/packages/xchain-utxo-providers/src/providers/index.ts +++ b/packages/xchain-utxo-providers/src/providers/index.ts @@ -1,6 +1,7 @@ export * from './sochainv3/sochain-api-types' export * from './sochainv3/sochain-api' export * from './sochainv3/sochain-data-provider' +export * from './types' export { AddressDTO, diff --git a/packages/xchain-utxo-providers/src/providers/sochainv3/sochain-data-provider.ts b/packages/xchain-utxo-providers/src/providers/sochainv3/sochain-data-provider.ts index 1899de35d..397e422fa 100644 --- a/packages/xchain-utxo-providers/src/providers/sochainv3/sochain-data-provider.ts +++ b/packages/xchain-utxo-providers/src/providers/sochainv3/sochain-data-provider.ts @@ -1,16 +1,8 @@ -import { - Balance, - FeeRates, - Tx, - TxHash, - TxHistoryParams, - TxType, - TxsPage, - UTXO, - UtxoOnlineDataProvider, -} from '@xchainjs/xchain-client' +import { Balance, FeeRates, Tx, TxHash, TxHistoryParams, TxType, TxsPage } from '@xchainjs/xchain-client' import { Address, Asset, Chain, assetAmount, assetToBase } from '@xchainjs/xchain-util' +import { UTXO, UtxoOnlineDataProvider } from '../types' + import * as sochain from './sochain-api' import { AddressUTXO, SochainNetwork } from './sochain-api-types' diff --git a/packages/xchain-utxo-providers/src/providers/types/index.ts b/packages/xchain-utxo-providers/src/providers/types/index.ts new file mode 100644 index 000000000..9c1a88aae --- /dev/null +++ b/packages/xchain-utxo-providers/src/providers/types/index.ts @@ -0,0 +1,24 @@ +import { Network, OnlineDataProvider, TxHash } from '@xchainjs/xchain-client' +import { Address } from '@xchainjs/xchain-util' + +export type Witness = { + value: number + script: Buffer +} + +export type UTXO = { + hash: string + index: number + value: number + witnessUtxo?: Witness + txHex?: string + scriptPubKey?: string +} + +export interface UtxoOnlineDataProvider extends OnlineDataProvider { + getConfirmedUnspentTxs(address: Address): Promise + getUnspentTxs(address: Address): Promise + broadcastTx(txHex: string): Promise +} + +export type UtxoOnlineDataProviders = Record diff --git a/packages/xchain-utxo/CHANGELOG.md b/packages/xchain-utxo/CHANGELOG.md new file mode 100644 index 000000000..cc16f9711 --- /dev/null +++ b/packages/xchain-utxo/CHANGELOG.md @@ -0,0 +1,5 @@ +# v0.1.0 (2023-12-01) + +## Update + +- First release diff --git a/packages/xchain-utxo/package.json b/packages/xchain-utxo/package.json new file mode 100644 index 000000000..bd077a8fd --- /dev/null +++ b/packages/xchain-utxo/package.json @@ -0,0 +1,49 @@ +{ + "name": "@xchainjs/xchain-utxo", + "version": "0.1.0", + "description": "Genereic UTXO client for XChainJS", + "keywords": [ + "XChain", + "UTXO" + ], + "author": "XChainJS", + "homepage": "https://github.com/xchainjs/xchainjs-lib", + "license": "MIT", + "main": "lib/index.js", + "module": "lib/index.esm.js", + "typings": "lib/index.d.ts", + "directories": { + "lib": "lib", + "test": "__tests__" + }, + "files": [ + "lib" + ], + "repository": { + "type": "git", + "url": "git@github.com:xchainjs/xchainjs-lib.git" + }, + "scripts": { + "clean": "rimraf lib/**", + "build": "yarn clean && rollup -c", + "lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0", + "prepublishOnly": "yarn build" + }, + "publishConfig": { + "access": "public" + }, + "devDependencies": { + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-crypto": "^0.3.0", + "@xchainjs/xchain-util": "^0.13.1", + "@xchainjs/xchain-utxo-providers": "^0.2.9", + "axios": "^1.3.6" + }, + "peerDependencies": { + "@xchainjs/xchain-client": "^0.15.6", + "@xchainjs/xchain-crypto": "^0.3.0", + "@xchainjs/xchain-util": "^0.13.1", + "@xchainjs/xchain-utxo-providers": "^0.2.9", + "axios": "^1.3.6" + } +} \ No newline at end of file diff --git a/packages/xchain-utxo/rollup.config.js b/packages/xchain-utxo/rollup.config.js new file mode 100755 index 000000000..3b9d5b81e --- /dev/null +++ b/packages/xchain-utxo/rollup.config.js @@ -0,0 +1,39 @@ +import commonjs from '@rollup/plugin-commonjs' +import json from '@rollup/plugin-json' +import resolve from '@rollup/plugin-node-resolve' +import external from 'rollup-plugin-peer-deps-external' +import typescript from 'rollup-plugin-typescript2' + +import pkg from './package.json' + +export default { + input: 'src/index.ts', + output: [ + { + file: pkg.main, + format: 'cjs', + exports: 'named', + sourcemap: true, + }, + { + file: pkg.module, + format: 'es', + exports: 'named', + sourcemap: true, + }, + ], + plugins: [ + json(), + external(), + typescript({ + tsconfig: './tsconfig.json', + exclude: '__tests__/**', + }), + resolve({ preferBuiltins: true, browser: true }), + commonjs({ + include: /node_modules/, + exclude: '**/*.json', + }), + ], + external: ['buffer', 'crypto'], +} diff --git a/packages/xchain-client/src/UTXOClient.ts b/packages/xchain-utxo/src/client.ts similarity index 92% rename from packages/xchain-client/src/UTXOClient.ts rename to packages/xchain-utxo/src/client.ts index 5d0eaac2e..26fea7164 100644 --- a/packages/xchain-client/src/UTXOClient.ts +++ b/packages/xchain-utxo/src/client.ts @@ -1,54 +1,35 @@ -import { Address, Asset, Chain, baseAmount } from '@xchainjs/xchain-util' - -import { BaseXChainClient as Client } from './BaseXChainClient' -import { standardFeeRates } from './feeRates' -import { calcFeesAsync } from './fees' -import { ExplorerProviders, UTXO, UtxoOnlineDataProviders } from './provider-types' import { Balance, + BaseXChainClient, + ExplorerProviders, Fee, FeeEstimateOptions, FeeRate, FeeRates, Fees, FeesWithRates, + Protocol, Tx, TxHash, TxHistoryParams, TxsPage, - XChainClientParams, -} from './types' - -export type UtxoClientParams = XChainClientParams & { - explorerProviders: ExplorerProviders - dataProviders: UtxoOnlineDataProviders[] -} + calcFeesAsync, + standardFeeRates, +} from '@xchainjs/xchain-client' +import { Address, Asset, Chain, baseAmount } from '@xchainjs/xchain-util' +import { UTXO, UtxoOnlineDataProviders } from '@xchainjs/xchain-utxo-providers' -export enum Protocol { - THORCHAIN = 1, -} +import { UtxoClientParams } from './types' -export abstract class UTXOClient extends Client { +export abstract class Client extends BaseXChainClient { protected explorerProviders: ExplorerProviders protected dataProviders: UtxoOnlineDataProviders[] - protected abstract compileMemo(memo: string): Buffer - protected abstract getFeeFromUtxos(inputs: UTXO[], feeRate: FeeRate, data: Buffer | null): number - - protected async calcFee(feeRate: FeeRate, options?: FeeEstimateOptions): Promise { - let utxos: UTXO[] = [] - if (options?.sender) { - utxos = await this.scanUTXOs(options.sender, false) - } - const compiledMemo = options?.memo ? this.compileMemo(options.memo) : null - const fee = this.getFeeFromUtxos(utxos, feeRate, compiledMemo) - return baseAmount(fee) - } - /** * Constructor - * Client is initialised with network type + * Client is initialized with network type * + * @param {Chain} chain Chain to instantiate the client with * @param {UtxoClientParams} params */ constructor(chain: Chain, params: UtxoClientParams) { @@ -62,6 +43,16 @@ export abstract class UTXOClient extends Client { this.dataProviders = params.dataProviders } + protected async calcFee(feeRate: FeeRate, options?: FeeEstimateOptions): Promise { + let utxos: UTXO[] = [] + if (options?.sender) { + utxos = await this.scanUTXOs(options.sender, false) + } + const compiledMemo = options?.memo ? this.compileMemo(options.memo) : null + const fee = this.getFeeFromUtxos(utxos, feeRate, compiledMemo) + return baseAmount(fee) + } + /** * Get the explorer url. * @@ -90,6 +81,7 @@ export abstract class UTXOClient extends Client { getExplorerTxUrl(txID: string): string { return this.explorerProviders[this.network].getExplorerTxUrl(txID) } + /** * Get transaction history of a given address with pagination options. * By default it will return the transaction history of the current wallet. @@ -120,9 +112,9 @@ export abstract class UTXOClient extends Client { } /** - * Gets BTC balances of a given address. + * Gets balance of a given address. * - * @param {Address} BTC address to get balances from + * @param {Address} address to get balances from * @param {undefined} Needed for legacy only to be in common with `XChainClient` interface - will be removed by a next version * @param {confirmedOnly} Flag to get balances of confirmed txs only * @@ -142,6 +134,7 @@ export abstract class UTXOClient extends Client { ): Promise { return this.roundRobinGetUnspentTxs(address, confirmedOnly) } + async getFeesWithRates(options?: FeeEstimateOptions): Promise { const rates = await this.getFeeRates() return { @@ -200,6 +193,7 @@ export abstract class UTXOClient extends Client { } throw Error('no provider able to get balance') } + protected async roundRobinGetUnspentTxs(address: Address, confirmed: boolean) { for (const provider of this.dataProviders) { try { @@ -213,6 +207,7 @@ export abstract class UTXOClient extends Client { } throw Error('no provider able to GetUnspentTxs') } + protected async roundRobinGetTransactionData(txid: string) { for (const provider of this.dataProviders) { try { @@ -224,6 +219,7 @@ export abstract class UTXOClient extends Client { } throw Error('no provider able to GetTransactionData') } + protected async roundRobinGetTransactions(params: TxHistoryParams) { for (const provider of this.dataProviders) { try { @@ -235,6 +231,7 @@ export abstract class UTXOClient extends Client { } throw Error('no provider able to GetTransactions') } + protected async roundRobinBroadcastTx(txHex: string) { for (const provider of this.dataProviders) { try { @@ -247,6 +244,8 @@ export abstract class UTXOClient extends Client { throw Error('no provider able to BroadcastTx') } + protected abstract compileMemo(memo: string): Buffer + protected abstract getFeeFromUtxos(inputs: UTXO[], feeRate: FeeRate, data: Buffer | null): number protected async roundRobinGetFeeRates(): Promise { for (const provider of this.dataProviders) { try { diff --git a/packages/xchain-utxo/src/index.ts b/packages/xchain-utxo/src/index.ts new file mode 100644 index 000000000..560141189 --- /dev/null +++ b/packages/xchain-utxo/src/index.ts @@ -0,0 +1,4 @@ +import { Client } from './client' +import { PreparedTx, UTXO, UtxoClientParams, Witness } from './types' + +export { Client, UTXO, UtxoClientParams, Witness, PreparedTx } diff --git a/packages/xchain-utxo/src/types/index.ts b/packages/xchain-utxo/src/types/index.ts new file mode 100644 index 000000000..f041f83f9 --- /dev/null +++ b/packages/xchain-utxo/src/types/index.ts @@ -0,0 +1,3 @@ +import { PreparedTx, UTXO, UtxoClientParams, Witness } from './types' + +export { UTXO, UtxoClientParams, Witness, PreparedTx } diff --git a/packages/xchain-utxo/src/types/types.ts b/packages/xchain-utxo/src/types/types.ts new file mode 100644 index 000000000..244078934 --- /dev/null +++ b/packages/xchain-utxo/src/types/types.ts @@ -0,0 +1,13 @@ +import { ExplorerProviders, PreparedTx as BasePreparedTx, XChainClientParams } from '@xchainjs/xchain-client' +import { UTXO, UtxoOnlineDataProviders, Witness } from '@xchainjs/xchain-utxo-providers' + +export type UtxoClientParams = XChainClientParams & { + explorerProviders: ExplorerProviders + dataProviders: UtxoOnlineDataProviders[] +} + +export type PreparedTx = BasePreparedTx & { + utxos: UTXO[] +} + +export { UTXO, Witness } diff --git a/packages/xchain-utxo/tsconfig.json b/packages/xchain-utxo/tsconfig.json new file mode 100644 index 000000000..e413925d0 --- /dev/null +++ b/packages/xchain-utxo/tsconfig.json @@ -0,0 +1,4 @@ +{ + "extends": "../../tsconfig.json", + "include": [ "src/**/*" ] +}