UpdateWitness
POST: http://172.104.51.182:16667/wallet/updatewitness
Edit the URL of the witness's official website.
BODY PARAMS
{
owner_address
string
update_url
string
visible
boolean (Optional)
permission_id
int32 (Optional)
}
Note:
owner address is transaction creator address, in hex string format.
update_url is website url, default hexString
visible: whether the address is in base58check format.
permission_id, whether the address is in base58 format.
Example:
curl --request POST --url http://172.104.51.182:16667/wallet/updatewitness --header 'Accept: application/json' --header 'Content-Type: application/json' --data ' { "owner_address":"WFzFXoQCgUeoApjejKM9B46NgFGHXvUyKz", "update_url":"http://test_create_witness_update.vn", "visible": true }
Input:
{
"owner_address":"WFzFXoQCgUeoApjejKM9B46NgFGHXvUyKz", "update_url":"http://test_create_witness_update.vn",
"visible": true
}
Response:
{
"visible": true, "txID": "ee802f9e179f4ecf29c9a0613a3a900be086ca32dca1ba077ce294125a94dff9", "raw_data": { "contract": [ { "parameter": { "value": { "update_url": "http://test_create_witness_update.vn", "owner_address": "WFzFXoQCgUeoApjejKM9B46NgFGHXvUyKz" }, "type_url": "type.googleapis.com/protocol.WitnessUpdateContract" }, "type": "WitnessUpdateContract" } ], "ref_block_bytes": "e27e", "ref_block_hash": "45338cf38462a0b1", "expiration": 1640068461000, "timestamp": 1640068402623 }, "raw_data_hex": "0a02e27e220845338cf38462a0b140c8e3cadddd2f5a77080812730a32747970652e676f6f676c65617069732e636f6d2f70726f746f636f6c2e5769746e657373557064617465436f6e7472616374123d0a15414203485a535a4072c9fbfaaddfe2a010ad0bcdb06224687474703a2f2f746573745f6372656174655f7769746e6573735f7570646174652e766e70bf9bc7dddd2f"
}
==> Continue you call gettransactionsign API then call broadcasttransaction API
We will the final result: The transaction created success on WEL network.
{
"result": true, "txid": "ee802f9e179f4ecf29c9a0613a3a900be086ca32dca1ba077ce294125a94dff9"
}
Last updated