Advanced Wallets - Consolidate Unspents

post/api/v1/{coin}/advancedwallet/{walletId}/consolidateunspents

Builds, signs, and sends a transaction to consolidate unspents all in 1 call. Consolidating unspents is only for UTXO-based assets.

Retrieves the private key from KMS using the provided public key, then signs and broadcasts the transaction.

Use this endpoint only with advanced wallets. For other wallet types, use Consolidate unspents (simple).

Path Parameters

  • walletIdstringRequired
  • coinstringRequired

Request Body

pubkey string required
Public key of the key used for signing multisig transactions
source string required
The key to use for signing the transaction
Allowed values: user backup
feeRate number
Custom fee rate (in base units) per kilobyte
maxFeeRate number
Maximum fee rate (in base units) per kilobyte
maxFeePercentage number
Maximum fee percentage
feeTxConfirmTarget number
Fee transaction confirmation target
bulk boolean
Enable bulk processing
minValueOne of
Minimum value for unspents
maxValueOne of
Maximum value for unspents
minHeight number
Minimum block height
minConfirms number
Minimum confirmations required
enforceMinConfirmsForChange boolean
Enforce minimum confirmations for change outputs
limit number
Limit the number of unspents to process
numUnspentsToMake number
Number of unspents to make
targetAddress string
Target address for consolidation

200 Response

tx string required
txid string required

400 Response

error string required
The error name
details string required
Error details

404 Response

error string required
The error name
details string required
Error details

409 Response

error string required
The error name
details string required
Error details

422 Response

error string required
The error name
details string required
Error details

500 Response

error string required
The error name
details string required
Error details

501 Response

error string required
The error name
details string required
Error details