Takes an unsigned transaction, prompts the user for approval, and returns the signed transaction to the caller.
Params (3)
transactionHex (required)
string
The unsigned transaction in hexadecimal format
β
chainAlias (required)
string
The chain alias for which the transaction is meant
Allowed values: X, P
β
utxos
array[string]
Array of the UTXO IDs consumed by the transaction
β
Result (AvalancheSignTransactionResult)
signedTransactionHex: String
The signed transaction in a hexadecimal format.
signatures: array[object]
signature
string
Signature of the transaction
sigIndices
array[number]
Contains input - signature index pair
Errors:
Code | Message |
-32602 | Missing mandatory param(s) |
-32600 | No active account found |
-32602 | Missing signer address |
-32600 | This account has nothing to sign |
-32000 | Unable to parse transaction data. Unsupported tx type |
-32000 | Expected a signedTx to be returned by the wallet, {value} returned. |
-32000 | Failed to sign [${inputIndex}, ${sigIndex}] |
4001 | User rejected the request. |
For any additional questions, please view our other knowledge base articles or contact a Product Support team member via the chat button. Examples are for illustrative purposes only.