POSTCreateCommonTransaction

Tron Mainnethttps://tron-mainnet.nodit.io/wallet/createCommonTransaction

Create a transaction for a specified contract type. Put the contract type in contractType and the contract's own parameters in the top-level fields alongside it. It creates transactions for multiple contract types through a single endpoint instead of calling each per-type endpoint.

Request Body
contractTypestringrequired

Contract type of the transaction to create. Use a name defined in Transaction.Contract.ContractType. Example: TransferContract, FreezeBalanceV2Contract, TriggerSmartContract

visibleboolean

Optional. Set to true to format addresses in Base58; set to false for hex format. (Default: false)

Permission_idinteger

Optional. Permission ID used for multi-signature account operations. Defaults to the owner permission (0) if unspecified.

Responses
txIDstring

Transaction ID (hash).

raw_dataobject

The transaction raw_data (contract, ref_block_*, expiration, etc.).

raw_data_hexstring

Hex-encoded protobuf of raw_data.

visibleboolean

Echoes back the visible value given in the request.

X-API-KEY
RequestCU30
cURL
curl -X POST "https://tron-mainnet.nodit.io/wallet/createCommonTransaction" \
  -H "X-API-KEY: {YOUR_API_KEY}" \
  -H "Content-Type: application/json" \
  -d '{
  "contractType": "TransferContract",
  "owner_address": "TUoHaVjx7n5xz8LwPRDckgFrDWhMhuSuJM",
  "to_address": "TPswDDCAWhJAZGdHPidFg5nEf8TkNToDX1",
  "amount": 1,
  "visible": true
}'
Response
Example · 200
{
  "txID": "string",
  "raw_data": {},
  "raw_data_hex": "string",
  "visible": true
}