-
Notifications
You must be signed in to change notification settings - Fork 64
sendTransaction
AxVultis edited this page Nov 12, 2022
·
7 revisions
The sendTransaction method allows you to send transaction to one or several addresses. Also, it allows you to use a payment_id for a transaction to a single address.
JSON-RPC
{
"jsonrpc": "2.0",
"id": 19,
"method": "sendTransaction",
"params": {
"anonymity": 5,
"fee": 1000,
"unlockTime": 0,
"addresses": [
"ccx7ZR5167Z9AburnDZ3Wu8712yejVd78TCFZKWn1gTidA1hJfwsVWUYLaAhRjv4qwMBzwGakB6VeGWfV9ZZvkAu8j2ehPA3Sv"
],
"transfers": [
{
"amount": 20000000,
"address": "ccx7BtV8DUGNZHxW3k9o2kSzAbwSm33sFMRiR1FRDy2wNuWh5bkFvKeYLaAhRjv4qwMBzwGakB6VeGWfV9ZZvkAu8j2ej6aF7R"
},
{
"amount": 20000000,
"address": "ccx7V4GWENfe7A38kWpj9EHJ1qHpaztsNNX8x44Kgo6dHKbDwkM6DMnYLaAhRjv4qwMBzwGakB6VeGWfV9ZZvkAu8j2edna4U6"
},
{
"amount": 20000000,
"address": "ccx7eDWHZTgTZy7gbNL3vPgMiv9CZ1ckaCEQRiBkQmXVGQxAXVXVPunYLaAhRjv4qwMBzwGakB6VeGWfV9ZZvkAu8j2eg6ijCG"
}
],
"changeAddress": "ccx7dehAGh837bfSfo18wJ1WzeCUWnzv3D23hvR8npyhHxoa6E3WXqNgTfHaWbAYRPdUhEXXEeKeEG7okKGHA8CZ3onHHofFDJ"
}
}
Request Details:
Argument | Mandatory | Description | Format |
---|---|---|---|
addresses | No | Array of strings, where each string is an address to take the funds from | array of strings |
transfers | Yes | Contains (see table below) | array |
fee | Yes | Transaction fee. The fee in Conceal is fixed at .001 CCX. This parameter should be specified in minimal available CCX units. For example, if your fee is .001 CCX, you should pass it as 1000 | int |
unlockTime | No | Height of the block until which transaction is going to be locked for spending | int |
anonymity | Yes | Privacy level (a discrete number from 1 to infinity). Level 5 is recommended | int |
extra | No | String of variable length. Can contain A-Z, 0-9 characters | string |
paymentId | No | payment_id | string |
changeAddress | No | Valid and existing in this container, it will receive the change of the transaction | string |
Transfer Details:
Argument | Mandatory | Description | Format |
---|---|---|---|
address | Yes | Destination address | string |
amount | Yes | Amount to transfer | int |
message | No | string |
Note: if container contains only 1 address, changeAddress field can be left empty and the change is going to be sent to this address
Note: if addresses field contains only 1 address, changeAddress can be left empty and the change is going to be sent to this address
Note: in the rest of the cases, changeAddress field is mandatory and must contain an address.
JSON-RPC
{
"jsonrpc": "2.0",
"id": 19,
"result": {
"transactionHash": "135876e51774bcd93f52c03019d986af2edabcec73bc30239a900b329ff6d914"
}
}
Response Details:
Argument | Description | Format |
---|---|---|
transactionHash | Hash of the sent transaction | string |
© 2018-2023 Conceal Network. All rights reserved.
- Conceal API Reference
- General Methods
- Private Key Methods
- Wallet Address Methods
- Deposit Methods
- Transaction Methods
- Delayed Transaction Methods
- Wallet Export Methods