Skip to Content
LearnTransaction Overview

Transactions

Transactions are essential on the Sei blockchain for any state updates, including token transfers, account linking, and smart contract execution. While creating an account doesn’t require a transaction, associating an account with blockchain actions does.

Each transaction is signed with the sender’s private key to verify authenticity and ownership. For more on private keys, see HD Paths and Coin Types.

Transaction Types

Since Sei supports both EVM and Cosmos SDK transactions, there are different transaction types based on the execution environment. The following sections provide an overview of Cosmos and EVM transactions on Sei.

EVM Transactions

The Sei blockchain supports Ethereum Virtual Machine (EVM) transactions, allowing compatibility with Ethereum-based tools and contracts.

from

the address of the sender, that will be signing the transaction. This will be an externally-owned account as contract accounts cannot send transactions.

to

the receiving address (if an externally-owned account, the transaction will transfer value. If a contract account, the transaction will execute the contract code)

signature

the identifier of the sender. This is generated when the senders private key signs the transaction and confirms the sender has authorized this transaction

nonce

a sequentially incrementing counter which indicates the transaction number from the account

data

The input data for contract execution. For simple transfers, this is usually empty.

value

amount of SEI (ETH) to transfer from sender to recipient (denominated in WEI, where 1SEI equals 1e+18wei)

gasLimit

the maximum amount of gas units that can be consumed by the transaction. The EVM specifies the units of gas required by each computational step

maxPriorityFeePerGas

the maximum price of the consumed gas to be included as a tip to the validator

maxFeePerGas

the maximum fee per unit of gas willing to be paid for the transaction (inclusive of baseFeePerGas and maxPriorityFeePerGas)

Cosmos Transactions

Cosmos transactions are used for interacting with Cosmos based RPC’s and tooling. They consist of the body, auth info, and signatures.

Signing Cosmos Transactions

Cosmos transactions on the Sei blockchain follow the standard Cosmos SDK format. They include various types of messages that can be included in the transaction body.

Using the seid CLI, you can use the --generate-only flag to generate an unsigned transaction in JSON format. The transaction can then be signed and broadcasted to the network.

Assuming you have an unsigned JSON transaction file, you can sign it using the seid tx sign command. The signed transaction will be in JSON format and can be broadcasted to the network.

seid tx sign unsigned_tx.json --chain-id my-test-chain --keyring-backend test --from $SIGNER_ADDRESS

Last updated on