Transfer Transaction

Transfer transactions are used to send mosaics and messages between two accounts.

../_images/transfer-transaction.png

Alice sends 10 symbol.xym to Bob

Recipient

The recipient is the address of the account that receives the TransferTransaction.

It is possible to send mosaics to any valid address, even if the address has not previously participated in any transaction.

Note

If nobody owns the private key of the recipient’s account, the funds are most likely lost forever.

Mosaics

A mosaic could be a token, but it could also be more specialized assets such as reward points, shares of stock, signatures, status flags, votes or even other currencies.

You can send a combination of different mosaics in the same transaction.

Message

In the public network, transfer transactions can hold a message up to 1023 characters in length, making them suitable for timestamping data permanently on the blockchain.

By default, the messages attached are visible by default to all network participants, although the client does not encrypt the message.

Encrypted message

Encrypted messages are only accessible by the sender and the recipient.

Catapult uses Bouncy Castle’s AES block cipher implementation in CBC mode to encrypt and decrypt messages.

Note

You can find under the crypto module how to encode and decode encrypted messages, but we recommend you to use the available SDK public methods instead.

Guides

Transaction schemas

TransferTransaction

Announce a TransferTransaction to send mosaics or messages between two accounts.

Version: 0x01

EntityType: 0x4154

Inlines:

Property Type Description
recipientAddress UnresolvedAddress Transaction recipient.
mosaicsCount uint8 Number of attached mosaics.
messageSize uint16 Size of the attached message.
transferTransactionBody_Reserved1 uint32 Reserved padding to align mosaics on 8-byte boundary.
mosaics array(UnresolvedMosaic, mosaicsCount) Attached mosaics to send.
message array(byte, messageSize) Message type and hexadecimal payload.

MessageType

Enumeration: uint8

Id Description
0x00 Plain message.
0x01 Encrypted message.
0xFE Persistent harvesting delegation.

Continue: Aggregate Transaction.