This page uses machine translation from English, which may contain errors or unclear language. For the most accurate information, please see the original English version. Some content may be in the original English due to frequent updates. Help us improve this page's translation by joining our effort on Crowdin. (Crowdin translation page, Contributing guide)
Implementing Transactions
This guide provides a comprehensive overview of implementing transactions on the Kaia network, covering various transaction types, encoding, signing, and network interaction.
Kaia Transaction Components
Kaia transactions generally include the following components:
Components | Description |
---|---|
from | The sender's address. Required for most Kaia transaction types due to the decoupling of key pairs and addresses. |
to | The account address that will receive the transferred value. |
value | The amount of KAIA in kei to be transferred. |
input | Data attached to the transaction, used for transaction execution. |
v , r , s | The cryptographic signature generated by the sender to let the receiver obtain the sender's address. |
nonce | A value used to uniquely identify a sender’s transaction. If two transactions with the same nonce are generated by a sender, only one is executed. |
gas | The maximum amount of transaction fee the transaction is allowed to use. |
gasPrice | A multiplier to get how much the sender will pay in tokens. The amount of tokens the sender will pay is calculated via gas * gasPrice . For example, the sender will pay 10 KAIA for a transaction fee if gas is 10 and gasPrice is 10^18. Unit of KAIA is described here. |