Skip to content

MPTokenIssuance

[Source]

An MPTokenIssuance entry represents a single MPT issuance and holds data associated with the issuance itself. You can create an MPTokenIssuance using an MPTokenIssuanceCreate transaction, and can delete it with an MPTokenIssuanceDestroy transaction.

Requires the MPTokensV1 amendment. Loading...

Example MPTokenIssuance JSON

{
    "LedgerEntryType": "MPTokenIssuance",
    "Flags": 131072,
    "Issuer": "rsA2LpzuawewSBQXkiju3YQTMzW13pAAdW",
    "AssetScale": 2,
    "MaximumAmount": "100000000",
    "OutstandingAmount": "100",
    "TransferFee": 50000,
    "MPTokenMetadata": "7B227469636B6572223A20225442494C4C222C20226E616D65223A2022542D42696C6C205969656C6420546F6B656E222C202264657363223A202241207969656C642D62656172696E6720737461626C65636F696E206261636B65642062792073686F72742D7465726D20552E532E205472656173757269657320616E64206D6F6E6579206D61726B657420696E737472756D656E74732E222C202269636F6E223A202268747470733A2F2F6578616D706C652E6F72672F7462696C6C2D69636F6E2E706E67222C202261737365745F636C617373223A2022727761222C202261737365745F737562636C617373223A20227472656173757279222C20226973737565725F6E616D65223A20224578616D706C65205969656C6420436F2E222C202275726C73223A205B7B2275726C223A202268747470733A2F2F6578616D706C657969656C642E636F2F7462696C6C222C202274797065223A202277656273697465222C20227469746C65223A202250726F647563742050616765227D2C207B2275726C223A202268747470733A2F2F6578616D706C657969656C642E636F2F646F6373222C202274797065223A2022646F6373222C20227469746C65223A20225969656C6420546F6B656E20446F6373227D5D2C20226164646974696F6E616C5F696E666F223A207B22696E7465726573745F72617465223A2022352E303025222C2022696E7465726573745F74797065223A20227661726961626C65222C20227969656C645F736F75726365223A2022552E532E2054726561737572792042696C6C73222C20226D617475726974795F64617465223A2022323034352D30362D3330222C20226375736970223A2022393132373936525830227D7D",
    "OwnerNode": "74"
}
Tip

By convention, the metadata should decode to JSON data describing what the MPT represents. The XLS-89 specification defines a recommended format for metadata. The above MPTokenMetadata field encodes the sample JSON from the spec, as a UTF-8 string with minimal whitespace.

MPTokenIssuance Fields

In addition to the common fields, MPTokenIssuance entries have the following fields:

Field NameJSON TypeInternal TypeRequired?Description
AssetScaleNumberUInt8YesWhere to put the decimal place when displaying amounts of this MPT. More formally, the asset scale is a non-negative integer (0, 1, 2, …) such that one standard unit equals 10^(-scale) of a corresponding fractional unit. For example, if a US Dollar Stablecoin has an asset scale of 2, then 1 unit of that MPT would equal 0.01 US Dollars. This indicates to how many decimal places the MPT can be subdivided. The default is 0, meaning that the MPT cannot be divided into smaller than 1 unit.
AuditorEncryptionKeyStringBlobNoA 33-byte compressed ElGamal public key for an optional on-chain auditor.

Requires the ConfidentialTransfer amendment. Loading...

ConfidentialOutstandingAmountNumberUInt64NoThe total amount of this token that is currently held in confidential balances.

Requires the ConfidentialTransfer amendment. Loading...

DomainIDString - HashUInt256NoThe ledger entry ID of a permissioned domain that grants access to the MPT. This field is always mutable.

Requires the SingleAssetVault amendment. Loading...

ImmutableFlagsNumberUInt32NoIndicates which fields and flags are immutable for this MPT issuance. Any field or flag not represented here remains mutable. See MPTokenIssuance Immutable Flags.

Requires the DynamicMPT amendment. Loading...

IssuerString - AddressAccountIDYesThe address of the account that controls both the issuance amounts and characteristics of a particular fungible token.
IssuerEncryptionKeyStringBlobNoA 33-byte compressed ElGamal public key for the issuer.

Requires the ConfidentialTransfer amendment. Loading...

LockedAmountString - NumberUInt64NoThe amount of tokens currently locked up (for example, in escrow). This amount is already included in the OutstandingAmount.

Requires the TokenEscrow amendment. Loading...

MaximumAmountString - NumberUInt64NoThe maximum number of MPTs that can exist at one time. If omitted, the maximum is currently limited to 263-1.
MPTokenMetadataString - HexadecimalBlobNoArbitrary metadata about this issuance, in hex format. The limit for this field is 1024 bytes.

This field is mutable by default, but can be made immutable.

Requires the DynamicMPT amendment. Loading...

OutstandingAmountString - NumberUInt64YesThe total amount of MPTs of this issuance currently in circulation. This value increases when the issuer sends MPTs to a non-issuer, and decreases whenever the issuer receives MPTs.
OwnerNodeString - HexadecimalUInt64YesA hint indicating which page of the owner directory links to this entry, in case the directory consists of multiple pages.
PreviousTxnIDString - HexadecimalUInt256YesThe identifying hash of the transaction that most recently modified this entry.
PreviousTxnLgrSeqNumberUInt32YesThe index of the ledger that contains the transaction that most recently modified this object.
SequenceNumberUInt32YesThe Sequence (or Ticket) number of the transaction that created this issuance. This helps to uniquely identify the issuance and distinguish it from any other later MPT issuances created by this account.
TransferFeeNumberUInt16YesThis value specifies the fee, in tenths of a basis point, charged by the issuer for secondary sales of the token, if such sales are allowed at all. Valid values for this field are between 0 and 50,000 inclusive. A value of 1 is equivalent to 1/10 of a basis point or 0.001%, allowing transfer rates between 0% and 50%. A TransferFee of 50,000 corresponds to 50%. The default value for this field is 0. Any decimals in the transfer fee are rounded down. The fee can be rounded down to zero if the payment is small. Issuers should make sure that their MPT's AssetScale is large enough.

This field is mutable by default, but can be made immutable.

Requires the DynamicMPT amendment. Loading...

MPTokenIssuance Flags

Flags are properties or other options associated with the MPTokenIssuance entry. Except for lsfMPTLocked, which the issuer can lock or unlock at any time with an MPTokenIssuanceSet transaction, these are capability flags. You can enable a capability flag during the MPTokenIssuanceCreate transaction, or later with MPTokenIssuanceSet, but enabling one can't be undone.

To fix a flag's state permanently, you can declare it immutable. See MPTokenIssuance Immutable Flags.

Requires the DynamicMPT amendment. Loading...

Flag NameFlag ValueDescription
lsfMPTLocked0x00000001If set, indicates that all balances are locked.
lsfMPTCanLock0x00000002If set, indicates that the issuer can lock an individual balance or all balances of this MPT. If not set, the MPT cannot be locked in any way.
lsfMPTRequireAuth0x00000004If set, indicates that individual holders must be authorized. This enables issuers to limit who can hold their assets.
lsfMPTCanEscrow0x00000008If set, indicates that individual holders can place their balances into an escrow.
lsfMPTCanTrade0x00000010If set, indicates that individual holders can trade their balances using the XRP Ledger DEX or AMM.
lsfMPTCanTransfer0x00000020If set, indicates that tokens held by non-issuers can be transferred to other accounts. If not set, indicates that tokens held by non-issuers cannot be transferred except back to the issuer; this enables use cases such as store credit.
lsfMPTCanClawback0x00000040If set, indicates that the issuer may use the Clawback transaction to claw back value from individual holders.
lsfMPTCanHoldConfidentialBalance0x00000080If enabled, indicates that confidential transfers and conversions are enabled for this token issuance.

Requires the ConfidentialTransfer amendment. Loading...

MPTokenIssuance Immutable Flags

Requires the DynamicMPT amendment. Loading...

The following flags are stored in the ImmutableFlags field, which is separate from the Flags field of the MPTokenIssuance ledger entry. Each flag indicates that the corresponding field or MPT issuance flag is immutable.

Flag NameHex ValueDecimal ValueDescription
lsifMPTCanLock0x000000022If enabled, the Can Lock flag, which gives the issuer the power to lock and unlock holders' balances, cannot be changed.
lsifMPTRequireAuth0x000000044If enabled, the Require Auth flag, which indicates that individual holders must be authorized, cannot be changed.
lsifMPTCanEscrow0x000000088If enabled, the Can Escrow flag, which indicates that the token can be placed in escrow, cannot be changed.
lsifMPTCanTrade0x0000001016If enabled, the Can Trade flag, which indicates that individual holders can trade their balances using the XRP Ledger DEX or AMM, cannot be changed.
lsifMPTCanTransfer0x0000002032If enabled, the Can Transfer flag, which indicates that tokens held by non-issuers can be transferred to other accounts, cannot be changed.
lsifMPTCanClawback0x0000004064If enabled, the Can Clawback flag, which indicates that the issuer can claw back value from individual holders, cannot be changed.
lsifMPTCanHoldConfidentialBalance0x00000080128If enabled, the Can Hold Confidential Balance flag, which indicates that confidential transfers and conversions are enabled for this token issuance, cannot be changed.

Requires the ConfidentialTransfer amendment. Loading...

lsifMPTMetadata0x0001000065536If enabled, the MPTokenMetadata field cannot be modified.
lsifMPTTransferFee0x00020000131072If enabled, the TransferFee field cannot be modified.

MPTokenIssuanceID

The ID of an MPTokenIssuance entry is the SHA-512Half of the following values, concatenated in order:

  • The MPTokenIssuance space key (0x007E).
  • The transaction sequence number.
  • The AccountID of the issuer.

The MPTokenIssuanceID is a 192-bit integer, concatenated in order:

  • The transaction sequence number.
  • The AccountID of the issuer.

See Also