latestOpenAPI 3.0.32026-08-224982,0272.8 MB

e445c15e5bee

Wallet

Send a half-signed transaction

Send a half-signed transaction to BitGo for final signing (using the BitGo key) and broadcasting.

post/api/v2/{coin}/wallet/{walletId}/tx/send

Path parameters

coinstring required

A cryptocurrency symbol or token ticker symbol

Example:btc

Coin or token identifier (e.g. btc, tbtc, eth)

walletIdstring required
Example:59cd72485007a239fb00282ed480da1f

The wallet ID

Request body

typestring nullable

Required for transactions from MPC wallets. "acceleration" speeds up transactions with a certain nonce by adjusting the gas setting. "accountSet" is for XRP AccountSet transactions. "consolidate" combines multiple UTXO inputs into fewer outputs. "enabletoken" is for SOL. "fanout" splits UTXO inputs into many smaller outputs (UTXO coins only). "stakingLock" and "stakingUnlock" are for Stacks delegations. "transfer" is for native-asset transfers. "trustline" is for Stellar trustline transactions. Possible types include: [acceleration, accountSet, consolidate, enabletoken, fanout, stakingLock, stakingUnlock, transfer, transfertoken, trustline]

For AVAX, possible types include: addValidator, export, and import.

For XRP, possible types include: payment and accountSet. The default is payment.

For STX, type is required.

numBlocksnumber

(BTC only) The number of blocks required to confirm a transaction. You can use numBlocks to estimate the fee rate by targeting confirmation within a given number of blocks. If both feeRate and numBlocks are absent, the transaction defaults to 2 blocks for confirmation.

Note: The maxFeeRate limits the fee rate generated by numBlocks.

feeRatenumber

Custom fee rate (in base units) per kilobyte (or virtual kilobyte). For example, satoshis per kvByte.

If the feeRate is less than the minimum required network fee, then the minimum fee applies. For example, 1000 sat/kvByte, a flat 1000 microAlgos, or a flat 10 drops of xrp. For XRP, the actual fee is usually 4.5 times the open ledger fee.

Note: The feeRate overrides the maxFeeRate and minFeeRate.

maxFeeRatenumber

(BTC only) The maximum fee rate (in base units) per kilobyte (or virtual kilobyte). For example, satoshis per kvByte. The maxFeeRate limits the fee rate generated by both feeMultiplier and numBlocks.

Note: The feeRate overrides the maxFeeRate.

minConfirmsnumber

The unspent selection for the transaction will only consider unspents with at least this many confirmations to be used as inputs. Does not apply to change outputs unless used in combination with enforceMinConfirmsForChange.

enforceMinConfirmsForChangeboolean

When set to true, will enforce minConfirms for change outputs.

gasPricenumber

Custom gas price to be used for sending the transaction. Only for ETH and ERC20 tokens.

gasLimitnumber

Custom gas limit to be used for sending the transaction. Only for ETH and ERC20 tokens.

targetWalletUnspentsnumber

Specifies the minimum count of good-sized unspents to maintain in the wallet. Change splitting ceases when the wallet has targetWalletUnspents good-sized unspents.

Note: Wallets that continuously send a high count of transactions will automatically split large change amounts into multiple good-sized change outputs while they have fewer than targetWalletUnspents good-sized unspents in their unspent pool. Breaking up large unspents helps to reduce the amount of unconfirmed funds in flight in future transactions, and helps to avoid long chains of unconfirmed transactions. This is especially useful for newly funded wallets or recently refilled send-only wallets.

minValuenumber

Ignore unspents smaller than this amount of base units (e.g. satoshis). For doge, only string is allowed.

maxValuenumber

Ignore unspents larger than this amount of base units (e.g. satoshis). For doge, only string is allowed.

sequenceIdstring

A sequenceId is a unique and arbitrary wallet identifier applied to transfers and transactions at creation. It is optional but highly recommended. With a sequenceId you can easily reference transfers and transactions—for example, to safely retry sending. Because the system only confirms one send request per sequenceId (and fails all subsequent attempts), you can retry sending without the risk of double spending. The sequenceId is only visible to users on the wallet and is not shared publicly.

noSplitChangeboolean

Set true to disable automatic change splitting.

Also see: targetWalletUnspents

unspentsstring[]
changeAddressstring

Specifies a custom destination address for the transaction's change output(s)

txFormat'legacy' | 'psbt' | 'psbt-lite'

[UTXO only] Format of the returned transaction hex serialization. legacy for serialized transaction in custom bitcoinjs-lib format. psbt for BIP174 serialized transaction

instantboolean

(DASH only) Specifies whether or not to use Dash's "InstantSend" feature when sending a transaction.

commentstring nullable

An optional memo for the transaction.

destinationChainstring

(AVAXC and AVAXP only) Destination chain for an AVAX import/export transaction. One of [P, C].

sourceChainstring

(AVAXC and AVAXP only) Source chain for an AVAX import/export transaction. One of [P, C].

addressTypestring

DEPRECATED - use changeAddressType. The type of address to create for change. One of p2sh, p2shP2wsh, p2wsh, or p2tr.

startTimestring

Unix timestamp in seconds.nanoseconds format, denoting the start of the validity window. Only for HBAR transactions.

consolidateIdstring

(ALGO/TEZOS only) Consolidation ID of this consolidation transaction.

invoicestring

Lightning invoice to pay. Accepted by the controller but not forwarded to coin-level build code (absent from buildParamsWhitelist) — included here only to match the shape clients actually send.

lastLedgerSequencenumber

(XRP only) Absolute max ledger the transaction should be accepted in, whereafter it will be rejected

ledgerSequenceDeltanumber

(XRP only) Relative ledger height (in relation to the current ledger) that the transaction should be accepted in, whereafter it will be rejected

cpfpTxIdsstring[]
cpfpFeeRatenumber

The desired effective fee rate of the accelerated transaction in base units per kilobyte (e.g. satoshi/kB), the unconfirmed transactions it depends on, and the newly created Child-Pays-For-Parent transaction. Must be higher than the current effective fee rate of the target transaction.

rbfTxIdsstring[]
maxFeenumber

Limits the amount of satoshis that can be used for fees in a Child-Pays-For-Parent (CPFP) transaction. CPFP transactions accelerate the targeted transaction and all of the unconfirmed transactions the targeted transaction depends on. maxFee is required for all CPFP transactions as it allows users to set a safety net that will halt CPFP attempts that exceed the expected cost.

strategystring

Optional unspent selection strategy to use. One of RANDOM, FIFO or BNB.

validFromBlocknumber

Optional block this transaction is valid from

validToBlocknumber

Optional block this transaction is valid until

messageKeystring

Optional parameter that takes a hexadecimal value to set messagekey for an XRP accountSet transaction. Recipients field should be empty when messageKey is set.

txHexstring nullable

The half-signed, serialized transaction hex. Alternative to sending halfSigned.

txRequestIdstring

The transaction request id.

suppressBroadcastboolean

Do not broadcast the transaction after signing.

videoApproversstring[]
isTestTransactionboolean

When true, gates validateTestTransaction() and skips video/liveness verification checks. Passed through buildParamsWhitelist to coin-level build code.

previewPendingTxsboolean

When present, overrides automatic preview of pending transactions during validateAndParseTransaction. Auto-injected by the controller when a pendingApproval exists.

goStakingRequestIdstring

GO Staking request identifier. Validated against wallet type before pipeline entry. Must be present for internal staking requests on trading wallets.

{"stackTrail":"paths:/api/v2/{coin}/wallet/{walletId}/tx/send:post:requestBody:content:application/json:schema:properties:attestation","oasType":"schema","type":"unknown","title":"JSON","description":"WebAuthn attestation payload provided at signing time. Used by the controller for\npost-send non-blocking `verifyAttestation` capture. Not passed through `buildParamsWhitelist`."}

Example request

{
  "messages": [
    {
      "message": "BIP322 test message."
    }
  ],
  "feeRate": 10000,
  "maxFeeRate": 20000,
  "unspents": [
    "12b147dd8b4f73c01f72bdbf5b589eea614f3de609ffdbdac84852d6505cf8a3:1"
  ],
  "changeAddress": "2MvrwRYBAuRtPTiZ5MyKg42Ke55W3fZJfZS",
  "txFormat": "psbt",
  "addressType": "p2sh",
  "changeAddressType": "p2sh",
  "startTime": "1714067129.1020603",
  "consolidateId": "59cd72485007a239fb00282ed480da1f",
  "trustlines": [
    {
      "limit": "2000000",
      "token": "txlm:BST-GBQTIOS3XGHB7LVYGBKQVJGCZ3R4JL5E4CBSWJ5ALIJUHBKS6263644L"
    }
  ],
  "stakingOptions": {
    "validator": "2MvrwRYBAuRtPTiZ5MyKg42Ke55W3fZJfZS"
  },
  "unstakingOptions": {
    "unstakeCpuQuantity": "100 EOS",
    "unstakeNetQuantity": "100 EOS"
  },
  "videoApprovers": [
    "59cd72485007a239fb00282ed480da1f"
  ]
}

Response

OK

txidstring

The transaction's unique identifier.

txstring

The encoded transaction, either base64 for XLM or hex for other coins.

Example response

{
  "transfer": {
    "baseValueString": "2000000",
    "coin": "btc",
    "enterprise": "59cd72485007a239fb00282ed480da1f",
    "organization": "59cd72485007a239fb00282ed480da1f",
    "entries": [
      {
        "address": "2NAUwNgXaoFj2VVnSEvNLGuez8CfdU2UCMZ",
        "valueString": "20000",
        "wallet": "59cd72485007a239fb00282ed480da1f",
        "walletLabel": "My Cold Wallet",
        "token": "omg"
      }
    ],
    "history": [
      {
        "user": "59cd72485007a239fb00282ed480da1f"
      }
    ],
    "id": "59cd72485007a239fb00282ed480da1f",
    "txid": "b8a828b98dbf32d9fd1875cbace9640ceb8c82626716b4a64203fdc79bb46d26",
    "valueString": "2000000",
    "wallet": "59cd72485007a239fb00282ed480da1f"
  },
  "transfers": [
    {
      "baseValueString": "2000000",
      "coin": "btc",
      "enterprise": "59cd72485007a239fb00282ed480da1f",
      "organization": "59cd72485007a239fb00282ed480da1f",
      "entries": [
        {
          "address": "2NAUwNgXaoFj2VVnSEvNLGuez8CfdU2UCMZ",
          "valueString": "20000",
          "wallet": "59cd72485007a239fb00282ed480da1f",
          "walletLabel": "My Cold Wallet",
          "token": "omg"
        }
      ],
      "history": [
        {
          "user": "59cd72485007a239fb00282ed480da1f"
        }
      ],
      "id": "59cd72485007a239fb00282ed480da1f",
      "txid": "b8a828b98dbf32d9fd1875cbace9640ceb8c82626716b4a64203fdc79bb46d26",
      "valueString": "2000000",
      "wallet": "59cd72485007a239fb00282ed480da1f"
    }
  ]
}