unsafe_mergeCoins

Constructs a BCS-encoded transaction block that merges the balance of coin_to_merge into primary_coin. This transaction must be signed and then submitted using a separate execute call. The gas object must be owned by the signer.

⚠ This endpoint is only available with Blast access.

Path parameters

apiKeystringRequired

Request

This endpoint expects an object.
signerstringRequired
The transaction signer's Sui address.
primary_coinstringRequired
The coin object to merge into. This coin will remain after the transaction.
coin_to_mergestringRequired

The coin object to be merged. It will be destroyed and its balance added to primary_coin.

gas_budgetstringRequired
The gas budget for the transaction. The transaction fails if gas used exceeds this.
gasstringOptional

The gas object to be used. If omitted, the node will auto-select one from the signer’s owned coins.

Response

The unsigned transaction block that merges coins.
gaslist of objects or null

The gas object(s) selected for this transaction.

inputObjectslist of objects or null
List of objects the transaction references.
txBytesstring or null

Base64-encoded BCS transaction data, ready for signing.