Skip to content

Latest commit

 

History

History
12 lines (8 loc) · 1.02 KB

transaction-broadcaster.md

File metadata and controls

12 lines (8 loc) · 1.02 KB

Transaction Broadcaster

In the examples included in this documentation, you will see all the steps required to interact with the chain, from deriving a public key from a private key, creating messages to query the chain or creating orders, to creating and broadcasting transactions to the chain. Before going to the examples of all the possible actions it is important to state that you can avoid implementing yourself all the steps to create and configure correctly a transaction.

If you are not interested in defining all the low level aspects you can use the component called MsgBroadcasterWithPk. To use the broadcaster you just need to create an instance of MsgBroadcasterWithPk, and once all the messages to be included in the transaction have been created, use the broadcast method, passing the messages as a parameter.

The broadcaster will take care of:

  • Calculating the gas fee to pay for the transaction,
  • Create the transaction and configure it,
  • Sign the transaction,
  • Broadcast it to the chain