Mosaic Schemas

Note

The catbuffer schemas repository defines how each transaction type should be serialized. In combination with the catbuffer-generators project, developers can generate builder classes for a given set of programming languages.

Mosaic Definition

MosaicDefinitionTransaction

Announce a MosaicDefinitionTransaction to create a new mosaic.

Version: 0x01

EntityType: 0x414D

Inlines:

Property Type Description
id MosaicId Identifier of the mosaic.
duration BlockDuration Mosaic duration expressed in blocks. If set to 0, the mosaic is non-expiring.
nonce uint32 Random nonce used to generate the mosaic id.
flags MosaicFlag Mosaic flags.
divisibility uint8 Mosaic divisibility.

Mosaic Supply Change

MosaicSupplyChangeTransaction

Announce a supply change transaction to increase or decrease a mosaic’s supply.

Version: 0x01

EntityType: 0x424D

Inlines:

Property Type Description
mosaicId UnresolvedMosaicId Affected mosaic identifier.
delta Amount Amount of supply to increase or decrease.
action MosaicSupplyChangeAction Supply change action.

Mosaic Types

Mosaic

Property Type Description
mosaicId MosaicId Mosaic identifier.
amount Amount Mosaic amount.

UnresolvedMosaic

Property Type Description
mosaicId UnresolvedMosaicId Mosaic identifier. If the most significant bit of byte 0 is set, a namespaceId (alias) is used instead of the real mosaic identifier.
amount Amount Mosaic amount.

MosaicFlags

Enumeration: uint8

Id Description
0x00 No flags present.
0x01 Mosaic supports supply changes even when the mosaic creator owns partial supply.
0x02 Mosaic supports transfers between arbitrary accounts. When not set, the mosaic can only be transferred to/from the mosaic creator.
0x04 Mosaic creator can add rules to restrict which accounts are enabled to send and receive the mosaic.

MosaicSupplyChangeAction

Enumeration: uint8

Id Description
0x00 Decrease.
0x01 Increase.