|
6 | 6 | label:
|
7 | 7 | - XRP
|
8 | 8 | - Tokens
|
| 9 | + - MPTs |
9 | 10 | ---
|
10 | 11 | # Currency Formats
|
11 | 12 |
|
12 |
| -The XRP Ledger has two kinds of digital asset: XRP and [tokens](../../../concepts/tokens/index.md). Both types have high precision, although their formats are different. |
| 13 | +The XRP Ledger has three kinds of digital asset: XRP, [tokens](../../../concepts/tokens/index.md), and [Multi-purpose Tokens (MPTs)](../../../concepts/tokens/fungible-tokens/multi-purpose-tokens.md). All three types have high precision, although their formats are different. |
| 14 | + |
| 15 | +_(Requires the [MPToken amendment][] {% not-enabled /%})_ |
13 | 16 |
|
14 | 17 | ## Comparison
|
15 | 18 |
|
16 |
| -The following table summarizes some of the differences between XRP and tokens in the XRP Ledger: |
| 19 | +The following table summarizes some of the differences XRP, tokens, and MPTs in the XRP Ledger: |
17 | 20 |
|
18 |
| -| XRP | Tokens | |
19 |
| -|:---------------------------------------------------------|:------------------| |
20 |
| -| Has no issuer. | Always issued by an XRP Ledger account. | |
21 |
| -| Specified as a string. | Specified as an object. | |
22 |
| -| Tracked in [accounts](../ledger-data/ledger-entry-types/accountroot.md). | Tracked in [trust lines](../ledger-data/ledger-entry-types/ripplestate.md). | |
23 |
| -| Can never be created; can only be destroyed. | Can be issued or redeemed freely. | |
24 |
| -| Minimum value: `0`. (Cannot be negative.) | Minimum value: `-9999999999999999e80`. Minimum nonzero absolute value: `1000000000000000e-96`. |
25 |
| -| Maximum value `100000000000` (10<sup>11</sup>) XRP. That's `100000000000000000` (10<sup>17</sup>) "drops". | Maximum value `9999999999999999e80`. | |
| 21 | +| XRP | Tokens | MPTs | |
| 22 | +|:---------------------------------------------------------|:------------------|:---------------------| |
| 23 | +| Has no issuer. | Always issued by an XRP Ledger account. | Always issued by an XRP Ledger account. | |
| 24 | +| Specified as a string. | Specified as an object. | Specified as an object. | |
| 25 | +| Tracked in [accounts](../ledger-data/ledger-entry-types/accountroot.md). | Tracked in [trust lines](../ledger-data/ledger-entry-types/ripplestate.md). | Tracked in holder's account. | |
| 26 | +| Can never be created; can only be destroyed. | Can be issued or redeemed freely. | Can be issued or redeemed freely. | |
| 27 | +| Minimum value: `0`. (Cannot be negative.) | Minimum value: `-9999999999999999e80`. Minimum nonzero absolute value: `1000000000000000e-96`. | Minimum value: `0`. (Cannot be negative.) | |
| 28 | +| Maximum value `100000000000` (10<sup>11</sup>) XRP. That's `100000000000000000` (10<sup>17</sup>) "drops". | Maximum value `9999999999999999e80`. | Maximum value `0x7FFFFFFFFFFFFFFF`. | |
26 | 29 | | Precise to the nearest "drop" (0.000001 XRP) | 15 decimal digits of precision. |
|
27 |
| -| Can't be [frozen](../../../concepts/tokens/fungible-tokens/freezes.md). | The issuer can [freeze](../../../concepts/tokens/fungible-tokens/freezes.md) balances. | |
28 |
| -| No transfer fees; XRP-to-XRP payments are always direct. | Can take indirect [paths](../../../concepts/tokens/fungible-tokens/paths.md) with each issuer charging a percentage [transfer fee](../../../concepts/tokens/transfer-fees.md). | |
29 |
| -| Can be used in [Payment Channels](../../../concepts/payment-types/payment-channels.md) and [Escrow](../../../concepts/payment-types/escrow.md). | Not compatible with Payment Channels or Escrow. | |
| 30 | +| Can't be [frozen](../../../concepts/tokens/fungible-tokens/freezes.md). | The issuer can [freeze](../../../concepts/tokens/fungible-tokens/freezes.md) balances. | The issuer can lock balances individually and globally. | |
| 31 | +| No transfer fees; XRP-to-XRP payments are always direct. | Can take indirect [paths](../../../concepts/tokens/fungible-tokens/paths.md) with each issuer charging a percentage [transfer fee](../../../concepts/tokens/transfer-fees.md). | Can charge a transfer fee for secondary sales of the token. | |
| 32 | +| Can be used in [Payment Channels](../../../concepts/payment-types/payment-channels.md) and [Escrow](../../../concepts/payment-types/escrow.md). | Not compatible with Payment Channels or Escrow. | Not compatible with Payment Channels. Can be used for escrow. | |
30 | 33 |
|
31 |
| -For more information, see [What is XRP?](../../../introduction/what-is-xrp.md) and [Tokens](../../../concepts/tokens/index.md). |
| 34 | +See [What is XRP?](../../../introduction/what-is-xrp.md), [Tokens](../../../concepts/tokens/index.md), and [Multi-purpose Tokens](../../../concepts/tokens/fungible-tokens/multi-purpose-tokens.md). |
32 | 35 |
|
33 | 36 | ## Specifying Currency Amounts
|
34 | 37 |
|
35 | 38 | Use the appropriate format for the type of currency you want to specify:
|
36 | 39 |
|
37 | 40 | - [XRP Amounts](#xrp-amounts)
|
38 | 41 | - [Token Amounts](#token-amounts)
|
| 42 | +- [MPT Amounts](#mpt-amounts) |
39 | 43 |
|
40 | 44 | ### XRP Amounts
|
41 | 45 |
|
@@ -72,6 +76,16 @@ For example, to represent $153.75 US dollars issued by account `r9cZA1mLK5R5Am25
|
72 | 76 | "issuer": "r9cZA1mLK5R5Am25ArfXFmqgNwjZgnfk59"
|
73 | 77 | }
|
74 | 78 | ```
|
| 79 | +### MPT Amounts |
| 80 | + |
| 81 | +Specify the amount of MPTs using the `MPTAmount` field. For example, to specify 1 million units of an MPT you would specify: |
| 82 | + |
| 83 | +```json |
| 84 | +{ |
| 85 | + "MPTAmount": "1000000" |
| 86 | +} |
| 87 | +``` |
| 88 | + |
75 | 89 |
|
76 | 90 | ### Specifying Without Amounts
|
77 | 91 |
|
@@ -111,6 +125,10 @@ When sending token amounts in the XRP Ledger's peer-to-peer network, servers [se
|
111 | 125 |
|
112 | 126 | {% admonition type="success" name="Tip" %}For tokens that should not be divisible at all, see [Non-Fungible Tokens (NFTs)](../../../concepts/tokens/nfts/index.md).{% /admonition %}
|
113 | 127 |
|
| 128 | +## MPT Precision |
| 129 | + |
| 130 | + |
| 131 | + |
114 | 132 | ## Currency Codes
|
115 | 133 | [Currency Code]: #currency-codes
|
116 | 134 |
|
|
0 commit comments