CrossFi Transaction Messages Reference
This comprehensive guide describes all possible fields for transaction messages supported by CrossFi Chain. The platform integrates multiple modules from Cosmos SDK, Ethermint, and CrossFi-specific implementations.
Overview
CrossFi Chain supports multiple transaction message types across different modules:
- Cosmos Base: Fundamental coin operations
- Cosmos SDK Modules: Authz, Bank, Distribution, Gov, Feegrant, Staking, Slashing, Vesting
- Ethermint EVM: Ethereum-compatible transactions
- CrossFi Modules: Native CrossFi functionality
Total message types covered: 35+
Each message type includes:
- Complete parameter descriptions
- Field types and constraints
- Usage examples
- Failure conditions
Table of Contents
🏦 Core Modules
🏛️ Governance & Staking
🌐 Advanced Features
Cosmos Base
cosmos.base.v1beta1.Coin
The fundamental coin structure used across all modules for representing token amounts.
| Parameter | Type | Description |
|---|---|---|
denom | string | Token denomination (e.g., mpx, xfi). Must match registered denominations. |
amount | string | Token amount as string representing integer (e.g., 1000000). Must be non-negative. |
Usage Context:
- Used in
MsgSend,MsgMultiSendfor transfers - Used in
MsgDepositfor governance deposits - Used in staking operations for delegation amounts
Example:
{
"denom": "mpx",
"amount": "1000000"
}
Authz Module
Authorization module allows one account (granter) to authorize another account (grantee) to execute certain actions on their behalf.
cosmos.authz.v1beta1.MsgGrant
Grants authorization from granter to grantee for specific message types.
| Parameter | Type | Description |
|---|---|---|
granter | string | Address of the account granting permission (e.g., mx1x7...). |
grantee | string | Address of the account receiving permission (e.g., mx1y2...). |
grant | cosmos.authz.v1beta1.Grant | Grant object containing authorization details and expiration. |
Grant Structure:
| Parameter | Type | Description |
|---|---|---|
authorization | google.protobuf.Any | Authorization type (GenericAuthorization, SendAuthorization, etc.). |
expiration | google.protobuf.Timestamp | Optional expiration time in UTC format (e.g., 2025-12-31T23:59:59Z). |
Authorization Types:
-
GenericAuthorization
- Provides unlimited permission for specified message type
- msg: string - Full message type URL (e.g.,
/cosmos.bank.v1beta1.MsgSend)
-
SendAuthorization
- Allows grantee to send coins with spending limits
- spend_limit: repeated Coin - Maximum coins that can be sent
- allow_list: repeated string - Optional list of allowed recipient addresses
-
StakeAuthorization
- Permits staking operations with validator restrictions
- validators: repeated string - List of validator addresses
- authorization_type: AuthorizationType - Type of staking action (DELEGATE, UNDELEGATE, REDELEGATE)
cosmos.authz.v1beta1.MsgRevoke
Revokes previously granted authorization for specific message type.
| Parameter | Type | Description |
|---|---|---|
granter | string | Address of account revoking permission. |
grantee | string | Address of account losing permission. |
msg_type_url | string | Message type URL to revoke (e.g., /cosmos.bank.v1beta1.MsgSend). |
cosmos.authz.v1beta1.MsgExec
Executes messages on behalf of granter using granted authorizations.
| Parameter | Type | Description |
|---|---|---|
grantee | string | Address of account executing messages. |
msgs | repeated google.protobuf.Any | List of messages to execute (e.g., MsgSend). |
Bank Module
The bank module handles token transfers and balance management.
cosmos.bank.v1beta1.MsgSend
Transfers coins from one address to another.
| Parameter | Type | Description |
|---|---|---|
from_address | string (cosmos.AddressString) | Sender address (e.g., mx1x7...). |
to_address | string (cosmos.AddressString) | Recipient address (e.g., mx1y2...). |
amount | repeated cosmos.base.v1beta1.Coin | Coins to transfer. Cannot be null. |
Example:
{
"from_address": "mx1x7...sender",
"to_address": "mx1y2...recipient",
"amount": [{"denom": "mpx", "amount": "1000000"}]
}
Failure Conditions:
- Insufficient balance in sender account
- Recipient address is blacklisted
- Invalid coin denomination
cosmos.bank.v1beta1.MsgMultiSend
Sends coins from one or multiple inputs to multiple outputs.
| Parameter | Type | Description |
|---|---|---|
inputs | repeated Input | Input sources. Cannot be null. |
outputs | repeated Output | Output destinations. |
Input Structure:
| Parameter | Type | Description |
|---|---|---|
address | string | Sender address. |
coins | repeated cosmos.base.v1beta1.Coin | Coins to send. |
Output Structure:
| Parameter | Type | Description |
|---|---|---|
address | string | Recipient address. |
coins | repeated cosmos.base.v1beta1.Coin | Coins to receive. |
Example:
{
"inputs": [
{
"address": "mx1x7...sender",
"coins": [{"denom": "mpx", "amount": "2000000"}]
}
],
"outputs": [
{
"address": "mx1y2...recipient1",
"coins": [{"denom": "mpx", "amount": "1000000"}]
},
{
"address": "mx1z3...recipient2",
"coins": [{"denom": "mpx", "amount": "1000000"}]
}
]
}
Distribution Module
Manages reward distribution between validators and delegators.
cosmos.distribution.v1beta1.MsgFundCommunityPool
Funds the community pool directly from an account.
| Parameter | Type | Description |
|---|---|---|
amount | repeated cosmos.base.v1beta1.Coin | Coins to transfer to community pool. |
depositor | string | Bech32 address funding the pool (e.g., mx1x7...). |
cosmos.distribution.v1beta1.MsgSetWithdrawAddress
Sets a different address for reward withdrawals.
| Parameter | Type | Description |
|---|---|---|
delegator_address | string | Bech32 address of delegator setting withdraw address. |
withdraw_address | string | Bech32 address where rewards will be sent. Cannot be module address. |
cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward
Withdraws accumulated rewards from a specific validator.
| Parameter | Type | Description |
|---|---|---|
delegator_address | string | Bech32 address of delegator withdrawing rewards. |
validator_address | string | Bech32 address of validator (e.g., mxvaloper1z3...). |
cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission
Allows validator to withdraw accumulated commission.
| Parameter | Type | Description |
|---|---|---|
validator_address | string | Bech32 address of validator (e.g., mxvaloper1z3...). |
Gov Module
Governance module enables on-chain proposals and voting.
cosmos.gov.v1.MsgDeposit
Deposits coins into a proposal to help it reach voting period.
| Parameter | Type | Description |
|---|---|---|
proposal_id | uint64 | Unique proposal identifier. |
depositor | string | Bech32 address making deposit (e.g., mx1x7...). |
amount | repeated Coin | Deposit amount. |
cosmos.gov.v1.MsgSubmitProposal
Creates a new governance proposal.
| Parameter | Type | Description |
|---|---|---|
messages | repeated Any | Messages to execute if proposal passes. |
initial_deposit | repeated Coin | Initial deposit for proposal. |
proposer | string | Bech32 address of proposer (e.g., mx1x7...). |
metadata | string | Optional metadata for proposal. |
title | string | Proposal title. |
summary | string | Brief proposal description. |
cosmos.gov.v1.MsgVote
Casts a vote on a proposal.
| Parameter | Type | Description |
|---|---|---|
proposal_id | uint64 | Proposal identifier. |
voter | string | Bech32 address of voter (e.g., mx1x7...). |
option | VoteOption | Vote choice: YES, ABSTAIN, NO, NO_WITH_VETO. |
metadata | string | Optional vote metadata. |
cosmos.gov.v1.MsgVoteWeighted
Casts weighted votes across multiple options.
| Parameter | Type | Description |
|---|---|---|
proposal_id | uint64 | Proposal identifier. |
voter | string | Bech32 address of voter. |
options | repeated WeightedVoteOption | Vote options with weights. |
metadata | string | Optional metadata. |
WeightedVoteOption:
| Parameter | Type | Description |
|---|---|---|
option | VoteOption | Vote choice. |
weight | string | Vote weight as decimal (e.g., "0.5"). Sum must equal 1. |
Feegrant Module
Allows accounts to pay transaction fees on behalf of others.
cosmos.feegrant.v1beta1.MsgGrantAllowance
Grants fee allowance from granter to grantee.
| Parameter | Type | Description |
|---|---|---|
granter | string | Address providing fee allowance (e.g., mx1x7...). |
grantee | string | Address receiving fee allowance (e.g., mx1y2...). |
allowance | google.protobuf.Any | Fee allowance type (BasicAllowance, PeriodicAllowance). |
Allowance Types:
-
BasicAllowance - Simple spending limit allowance:
- spend_limit: repeated Coin - Maximum fee amount
- expiration: Timestamp - Optional expiration time
-
PeriodicAllowance - Allowance that resets periodically:
- basic: BasicAllowance - Base allowance
- period: Duration - Reset period
- period_spend_limit: repeated Coin - Per-period limit
cosmos.feegrant.v1beta1.MsgRevokeAllowance
Revokes previously granted fee allowance.
| Parameter | Type | Description |
|---|---|---|
granter | string | Address revoking allowance (e.g., mx1x7...). |
grantee | string | Address losing allowance (e.g., mx1y2...). |
Staking Module
Implements Proof-of-Stake consensus mechanism.
cosmos.staking.v1beta1.MsgBeginRedelegate
Redelegates tokens from one validator to another.
| Parameter | Type | Description |
|---|---|---|
delegator_address | string | Delegator address (e.g., mx1x7...). |
validator_src_address | string | Source validator (e.g., mxvaloper1y2...). |
validator_dst_address | string | Destination validator (e.g., mxvaloper1z3...). |
amount | cosmos.base.v1beta1.Coin | Amount to redelegate. |
cosmos.staking.v1beta1.MsgCreateValidator
Creates a new validator.
| Parameter | Type | Description |
|---|---|---|
description | cosmos.staking.v1beta1.Description | Validator description. |
commission | cosmos.staking.v1beta1.CommissionRates | Commission rates. |
min_self_delegation | string | Minimum self-delegation in mpx. |
delegator_address | string | Delegator creating validator (e.g., mx1x7...). |
validator_address | string | Validator address (e.g., mxvaloper1y2...). |
pubkey | google.protobuf.Any | Validator public key. |
value | cosmos.base.v1beta1.Coin | Initial stake amount. |
Description Structure:
| Parameter | Type | Description |
|---|---|---|
moniker | string | Validator name. |
identity | string | Optional identity (e.g., Keybase ID). |
website | string | Validator website. |
security_contact | string | Security contact email. |
details | string | Additional validator details. |
CommissionRates Structure:
| Parameter | Type | Description |
|---|---|---|
rate | string | Current commission rate (e.g., "0.1" for 10%). |
max_rate | string | Maximum commission rate (e.g., "0.2"). |
max_change_rate | string | Maximum daily commission change (e.g., "0.01"). |
cosmos.staking.v1beta1.MsgDelegate
Delegates tokens to a validator.
| Parameter | Type | Description |
|---|---|---|
delegator_address | string | Delegator address (e.g., mx1x7...). |
validator_address | string | Validator address (e.g., mxvaloper1y2...). |
amount | cosmos.base.v1beta1.Coin | Amount to delegate. |
cosmos.staking.v1beta1.MsgEditValidator
Updates validator description and commission.
| Parameter | Type | Description |
|---|---|---|
description | cosmos.staking.v1beta1.Description | Updated validator description. |
validator_address | string | Validator address (e.g., mxvaloper1y2...). |
commission_rate | string | New commission rate (optional). |
min_self_delegation | string | New minimum self-delegation (optional). |
cosmos.staking.v1beta1.MsgUndelegate
Undelegates tokens from a validator.
| Parameter | Type | Description |
|---|---|---|
delegator_address | string | Delegator address (e.g., mx1x7...). |
validator_address | string | Validator address (e.g., mxvaloper1y2...). |
amount | cosmos.base.v1beta1.Coin | Amount to undelegate. |
Slashing Module
cosmos.slashing.v1beta1.MsgUnjail
Unjails a previously jailed validator.
| Parameter | Type | Description |
|---|---|---|
validator_addr | string | Validator address to unjail. |
Requirements:
- Validator must exist and be jailed
- Jail period must have expired
- Validator must have self-delegation > 0
- Validator must not be tombstoned
Vesting Module
cosmos.vesting.v1beta1.MsgCreateVestingAccount
Creates a vesting account with locked tokens.
| Parameter | Type | Description |
|---|---|---|
from_address | string | Address creating vesting account. |
to_address | string | New vesting account address (uninitialized). |
amount | repeated cosmos.base.v1beta1.Coin | Tokens to vest. |
end_time | int64 | UNIX timestamp when vesting ends. |
delayed | bool | true=delayed vesting, false=continuous. |
Vesting Types:
-
Delayed Vesting - All tokens unlock at once when
end_timeis reached:- Tokens remain fully locked until end time
- Suitable for cliff vesting scenarios
- Simple unlock mechanism
-
Continuous Vesting - Tokens unlock linearly from creation time to
end_time:- Gradual token release over time
- Proportional unlocking
- Suitable for employee vesting
Ethermint EVM Module
Ethereum Virtual Machine compatibility layer.
ethermint.evm.v1.MsgEthereumTx
Wraps Ethereum transaction for Cosmos execution.
| Parameter | Type | Description |
|---|---|---|
data | google.protobuf.Any | Transaction data (LegacyTx, AccessListTx, DynamicFeeTx). |
size | double | Cached transaction size (deprecated). |
hash | string | Transaction hash in hex format. |
from | string | Sender address in Ethereum format. |
ethermint.evm.v1.LegacyTx
Legacy Ethereum transaction format (pre-EIP-1559).
| Parameter | Type | Description |
|---|---|---|
nonce | uint64 | Account sequence number. |
gas_price | string | Gas price in wei as string. |
gas | uint64 | Gas limit for transaction. |
to | string | Recipient address (empty for contract creation). |
value | string | Amount to transfer in wei. |
data | bytes | Transaction data or contract code. |
v | bytes | Signature recovery parameter. |
r | bytes | Signature parameter r. |
s | bytes | Signature parameter s. |
ethermint.evm.v1.AccessListTx
EIP-2930 transaction with access list optimization.
| Parameter | Type | Description |
|---|---|---|
chain_id | string | Ethereum chain ID. |
nonce | uint64 | Account sequence number. |
gas_price | string | Gas price in wei. |
gas | uint64 | Gas limit. |
to | string | Recipient address. |
value | string | Transfer amount in wei. |
data | bytes | Transaction data. |
accesses | repeated AccessTuple | Access list for gas optimization. |
v | bytes | Signature v parameter. |
r | bytes | Signature r parameter. |
s | bytes | Signature s parameter. |
AccessTuple Structure:
| Parameter | Type | Description |
|---|---|---|
address | string | Contract address to access. |
storage_keys | repeated string | Storage keys to access in hex format. |
ethermint.evm.v1.DynamicFeeTx
EIP-1559 transaction with dynamic fees.
| Parameter | Type | Description |
|---|---|---|
chain_id | string | Ethereum chain ID. |
nonce | uint64 | Account sequence number. |
gas_tip_cap | string | Maximum priority fee per gas in wei. |
gas_fee_cap | string | Maximum fee per gas in wei. |
gas | uint64 | Gas limit. |
to | string | Recipient address. |
value | string | Transfer amount in wei. |
data | bytes | Transaction data. |
accesses | repeated AccessTuple | Access list. |
v | bytes | Signature v parameter. |
r | bytes | Signature r parameter. |
s | bytes | Signature s parameter. |
CrossFi Modules
CrossFi-specific functionality.
crossfi.erc20.v1.MsgConvertCoin
Converts native Cosmos coins to ERC20 tokens.
| Parameter | Type | Description |
|---|---|---|
coin | cosmos.base.v1beta1.Coin | Native coin to convert. |
receiver | string | ERC20 token recipient address. |
sender | string | Native coin sender address. |
crossfi.treasury.MsgMint
Mints new tokens in CrossFi treasury.
| Parameter | Type | Description |
|---|---|---|
creator | string | Bech32 address authorized to mint tokens. |
amount | Coin | Amount and denomination to mint. |
Requirements:
- Creator must have minting permissions
- Amount must be positive
- Denomination must be supported
crossfi.treasury.MsgBurn
Burns tokens from circulation.
| Parameter | Type | Description |
|---|---|---|
creator | string | Bech32 address initiating burn. |
amount | Coin | Amount and denomination to burn. |
Requirements:
- Creator must own sufficient tokens
- Amount must be positive
- Burn operation is irreversible
Usage Examples
Basic Transfer
Simple token transfer using MsgSend:
{
"@type": "/cosmos.bank.v1beta1.MsgSend",
"from_address": "mx1x7...sender",
"to_address": "mx1y2...recipient",
"amount": [
{
"denom": "mpx",
"amount": "1000000"
}
]
}
Governance Vote
Voting on a governance proposal:
{
"@type": "/cosmos.gov.v1.MsgVote",
"proposal_id": "1",
"voter": "mx1x7...voter",
"option": "VOTE_OPTION_YES",
"metadata": "Supporting this proposal"
}
Staking Delegation
Delegating tokens to a validator:
{
"@type": "/cosmos.staking.v1beta1.MsgDelegate",
"delegator_address": "mx1x7...delegator",
"validator_address": "mxvaloper1y2...validator",
"amount": {
"denom": "mpx",
"amount": "5000000"
}
}
Error Handling
Common failure scenarios and their causes:
Ensure addresses use correct Bech32 format:
- Account addresses: Start with
mx - Validator addresses: Start with
mxvaloper - Ethereum addresses: Start with
0x(40 hex characters)
Account lacks sufficient balance for:
- Transaction amount plus fees
- Minimum delegation requirements
- Gas costs for EVM transactions
Use supported denominations:
- mpx: Micro MPX (1 MPX = 1,000,000 mpx)
- xfi: CrossFi native token
- IBC denominations:
ibc/[hash]
For authz module operations:
- Ensure grant exists between granter and grantee
- Check grant has not expired
- Verify message type matches granted authorization
For staking operations:
- Verify validator address format (
mxvaloper...) - Ensure validator is not jailed or tombstoned
- Check validator exists in active or unbonding set
Additional Resources
📚 Documentation
🔗 External Resources
This reference covers all major transaction message types supported by CrossFi Chain. For the latest updates and additional message types, refer to the XFI Scan API documentation or explore transactions directly on XFI Scan.