Build a transaction with many outputs without sending. Will not include signatures.
POST/wallet/tx-proposal
Build a transaction with many outputs without sending. Will not include signatures.
Request
Header Parameters
Defines the key of the wallet on which the request will be executed.
- application/json
Body
required
Data to create the transaction
Array [
]
Array [
]
outputs
object[]
required
Outputs to create the transaction.
Destination address of the output. Required if P2PKH or P2SH.
The value parameter must be an integer with the value in cents, i.e., 123 means 1.23 HTR. Required if P2PKH or P2SH.
Token id of the output. If not sent, HTR will be chosen.
Type of output script. Required if data script and expected to be "data".
Data string of the data script output. Required if it's a data script output.
inputs
object[]
Inputs to create the transaction.
Hash of the transaction being spent in this input. Used if not type query.
Index of the output being spent in this input. Used if not type query.
Type of input object. Can be 'query' only for now.
Maximum number of utxos to filter in the query. Optional query parameter when using type query.
Token uid to filter utxos in the query. Optional query parameter when using type query.
Address to filter utxos in the query. Optional query parameter when using type query.
Filter only utxos with value smaller than this. Optional query parameter when using type query.
Filter only utxos with value bigger than this. Optional query parameter when using type query.
Optional address to send the change amount.
Responses
- 200
Send a transaction with many outputs
- application/json
- Schema
- error
- success
- wallet-not-ready
- no-wallet-id
- invalid-wallet-id
Schema
any
Insuficient amount of tokens
{
"success": false,
"error": "Token HTR: Insufficient amount of tokens"
}
Success
{
"success": true,
"txHex": "0123abc...",
"dataToSignHash": "0123abc..."
}
Wallet is not ready yet
{
"success": false,
"message": "Wallet is not ready.",
"state": 1
}
No wallet id parameter
{
"success": false,
"message": "Parameter 'wallet-id' is required."
}
Wallet id parameter is invalid
{
"success": false,
"message": "Invalid wallet-id parameter."
}