'Creating a TRX raw transaction

I want to create a raw transaction (without signing it) and get its hash in hex format. The official TRON API normally returns a JSON for creating transactions. Does anybody know how to do this?



Solution 1:[1]

You can just call the api with your transaction details abd get transaction back

const data = {
        to_address: toHex(to),
        owner_address: toHex(from),
        amount: amount,
    };
let transaction = await tronWeb.fullNode.request('wallet/createtransaction', data, 'post');

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 user2800040