Skip to content

A transaction payload is the payload for a given transaction context and messages. For Cosmos, the payload can be signed in Amino or Sign Direct format, so the…

Defined in: packages/bitbadgesjs-sdk/src/transactions/messages/base.ts:125

A transaction payload is the payload for a given transaction context and messages. For Cosmos, the payload can be signed in Amino or Sign Direct format, so the payload.signDirect and payload.legacyAmino are the payloads to sign.

If evmAddress is provided in TxContext, the payload will also include evmTx field with EVM transaction details.

Properties

eip712?

optional eip712?: EIP712TypedData

Defined in: packages/bitbadgesjs-sdk/src/transactions/messages/base.ts:171

EIP-712 typed-data payload ({ domain, types, primaryType, message }) for the same Cosmos messages, ready to sign with eth_signTypedData_v4 (MetaMask / Privy / Coinbase Smart Wallet) or our own hashTypedData. Present when sender is provided. Compatible with the Cosmos EVM ante handler's EIP-712 verification path.


evmTx?

optional evmTx?: object

Defined in: packages/bitbadgesjs-sdk/src/transactions/messages/base.ts:154

Optional EVM transaction details. Present when evmAddress is provided in TxContext and messages are supported.

data

data: string

Encoded function call data (ready to send in a transaction)

functionName

functionName: string

Function name (for debugging/logging)

to

to: string

Precompile contract address (0x1001 for tokenization, 0x1002 for gamm, 0x1003 for sendmanager)

value

value: string

Transaction value (always "0" for precompiles)


legacyAmino

legacyAmino: object

Defined in: packages/bitbadgesjs-sdk/src/transactions/messages/base.ts:141

Cosmos Legacy Amino payload. Present when sender is provided in TxContext.

authInfo

authInfo: AuthInfo

body

body: TxBody

hashAlgorithm

hashAlgorithm: SignHashAlgorithm

signBytes

signBytes: string

Base64 digest of the amino JSON sign doc. Same hash rule as signDirect.signBytes.

signDocBytes

signDocBytes: Uint8Array

Raw amino JSON bytes that were hashed into signBytes.


signDirect

signDirect: object

Defined in: packages/bitbadgesjs-sdk/src/transactions/messages/base.ts:127

Cosmos Sign Direct payload. Present when sender is provided in TxContext.

authInfo

authInfo: AuthInfo

body

body: TxBody

hashAlgorithm

hashAlgorithm: SignHashAlgorithm

signBytes

signBytes: string

Base64 digest of the protobuf SignDoc. Already hashed — sign these 32 bytes directly. hashAlgorithm names the hash, and it matches the pubkey type in authInfo (sha256 for cosmos secp256k1, keccak256 for ethsecp256k1).

signDocBytes

signDocBytes: Uint8Array

Raw protobuf SignDoc bytes that were hashed into signBytes.

Edit this page on GitHub