diff --git a/docs/_snippets/common-links.md b/docs/_snippets/common-links.md index f207a6b4b6..4beabe57ca 100644 --- a/docs/_snippets/common-links.md +++ b/docs/_snippets/common-links.md @@ -187,6 +187,7 @@ [LedgerHashesエントリ]: /docs/references/protocol/ledger-data/ledger-entry-types/ledgerhashes.md [LedgerHashesオブジェクト]: /docs/references/protocol/ledger-data/ledger-entry-types/ledgerhashes.md [Marker]: /docs/references/http-websocket-apis/api-conventions/markers-and-pagination.md +[MPToken amendment]: /resources/known-amendments.md#mptokensv1 [MultiSign amendment]: /resources/known-amendments.md#multisign [MultiSignReserve amendment]: /resources/known-amendments.md#multisignreserve [MultiSignReserveの修正]: /resources/known-amendments.md#multisignreserve diff --git a/docs/concepts/tokens/fungible-tokens/multi-purpose-tokens.md b/docs/concepts/tokens/fungible-tokens/multi-purpose-tokens.md index b667acec54..ba35763dee 100644 --- a/docs/concepts/tokens/fungible-tokens/multi-purpose-tokens.md +++ b/docs/concepts/tokens/fungible-tokens/multi-purpose-tokens.md @@ -8,7 +8,7 @@ status: not_enabled --- # Multi-purpose Tokens -{% partial file="/docs/_snippets/mpts-disclaimer.md" /%} +_(Requires the [MPToken amendment][] {% not-enabled /%})_ Multi-purpose tokens (MPTs) are a more compact and flexible type of fungible token. @@ -62,3 +62,5 @@ MPTs are intended to be complementary to IOUs. While there might be use cases w - [MPTokenIssuanceCreate](../../../references/protocol/transactions/types/mptokenissuancecreate.md) - [MPTokenIssuanceDestroy](../../../references/protocol/transactions/types/mptokenissuancedestroy.md) - [MPTokenIssuanceSet](../../../references/protocol/transactions/types/mptokenissuanceset.md) + +{% raw-partial file="/docs/_snippets/common-links.md" /%} diff --git a/docs/references/http-websocket-apis/public-api-methods/clio-methods/mpt_holders.md b/docs/references/http-websocket-apis/public-api-methods/clio-methods/mpt_holders.md index bb62bb4a0d..9d60f3d212 100644 --- a/docs/references/http-websocket-apis/public-api-methods/clio-methods/mpt_holders.md +++ b/docs/references/http-websocket-apis/public-api-methods/clio-methods/mpt_holders.md @@ -7,7 +7,7 @@ labels: # mpt_holders -{% partial file="/docs/_snippets/mpts-disclaimer.md" /%} +_(Requires the [MPToken amendment][] {% not-enabled /%})_ For a given `MPTokenIssuanceID` and ledger sequence, `mpt_holders` returns all holders of that MPT and their balance. This method likely returns very large data sets, so you should expect to implement paging via the `marker` field. This API is only available using Clio, not rippled. @@ -154,3 +154,5 @@ Example of an `account_objects` response: } } ``` + +{% raw-partial file="/docs/_snippets/common-links.md" /%} diff --git a/docs/references/http-websocket-apis/public-api-methods/ledger-methods/ledger_entry.md b/docs/references/http-websocket-apis/public-api-methods/ledger-methods/ledger_entry.md index 1215c5e145..cfdd373e43 100644 --- a/docs/references/http-websocket-apis/public-api-methods/ledger-methods/ledger_entry.md +++ b/docs/references/http-websocket-apis/public-api-methods/ledger-methods/ledger_entry.md @@ -923,7 +923,9 @@ An example of a successful response: {% /tabs %} -### Get MPT Issuance Object +### Get MPT Issuance Object + +_(Requires the [MPToken amendment][] {% not-enabled /%})_ Return an `MPTokenIssuance` object. @@ -963,7 +965,9 @@ rippled json ledger_entry '{ "mpt_issuance": "000004C463C52827307480341125DA0577 [Try it! >](/resources/dev-tools/websocket-api-tool#ledger_entry-mpt_issuance) -### Get MPToken Object +### Get MPToken Object + +_(Requires the [MPToken amendment][] {% not-enabled /%})_ Return an `MPToken` object. diff --git a/docs/references/protocol/ledger-data/ledger-entry-types/mptoken.md b/docs/references/protocol/ledger-data/ledger-entry-types/mptoken.md index 6dcf029352..d8dc12fe6e 100644 --- a/docs/references/protocol/ledger-data/ledger-entry-types/mptoken.md +++ b/docs/references/protocol/ledger-data/ledger-entry-types/mptoken.md @@ -5,7 +5,7 @@ labels: --- # MPToken -{% partial file="/docs/_snippets/mpts-disclaimer.md" /%} +_(Requires the [MPToken amendment][] {% not-enabled /%})_ The `MPToken` object represents a number of tokens held by an account that is not the token issuer. MPTs are acquired via ordinary payment or DEX transactions, and can optionally be redeemed or exchanged using these same types of transactions. The object key of the MPToken is derived from hashing the space key, the holder's address, and the `MPTokenIssuanceID`. @@ -58,7 +58,7 @@ Flags are properties or other options associated with the `MPToken` object. | `lsfMPTAuthorized` | `0x00000002` | (Only applicable for allow-listing) If set, indicates that the issuer has authorized the holder for the MPT. This flag can be set using a `MPTokenAuthorize` transaction; it can also be "un-set" using a `MPTokenAuthorize` transaction specifying the `tfMPTUnauthorize` flag. | - +{% include '_snippets/rippled_versions.md' %} +{% raw-partial file="/docs/_snippets/common-links.md" /%} diff --git a/docs/references/protocol/ledger-data/ledger-entry-types/mptokenissuance.md b/docs/references/protocol/ledger-data/ledger-entry-types/mptokenissuance.md index 9cc75b454e..c799f7ad3f 100644 --- a/docs/references/protocol/ledger-data/ledger-entry-types/mptokenissuance.md +++ b/docs/references/protocol/ledger-data/ledger-entry-types/mptokenissuance.md @@ -5,7 +5,7 @@ labels: --- # MPTokenIssuance -{% partial file="/docs/_snippets/mpts-disclaimer.md" /%} +_(Requires the [MPToken amendment][] {% not-enabled /%})_ The `MPTokenIssuance` object represents a single MPT issuance and holds data associated with the issuance itself. Token issuances are created using the `MPTokenIssuanceCreate` transaction and can be destroyed by the `MPTokenIssuanceDestroy` transaction. @@ -90,9 +90,7 @@ Flags are properties or other options associated with the `MPToken` object. Exce | `lsfMPTCanTransfer` | `0x00000020` | If 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. | | `lsfMPTCanClawback` | `0x00000040` | If set, indicates that the issuer may use the `Clawback` transaction to claw back value from individual holders. | - - - +{% include '_snippets/rippled_versions.md' %} +{% raw-partial file="/docs/_snippets/common-links.md" /%} diff --git a/docs/references/protocol/transactions/metadata.md b/docs/references/protocol/transactions/metadata.md index 548d8b1ebf..e1552289fb 100644 --- a/docs/references/protocol/transactions/metadata.md +++ b/docs/references/protocol/transactions/metadata.md @@ -256,6 +256,8 @@ Transactions (`tx` and `account_tx`) involving NFTs can contain the following fi | `offer_id` | String | Shows the `OfferID`of a new `NFTokenOffer` in a response from a `NFTokenCreateOffer` transaction. | ## MPT Fields +_(Requires the [MPToken amendment][] {% not-enabled /%})_ + ### Synthetic mpt_issuance_id field `MPTokenIssuanceID` is an identifier that allows you to specify an `MPTokenIssuance` in RPCs. The server adds a synthetically parsed `mpt_issuance_id` field to API responses to avoid the need for client-side parsing of the `MPTokenIssuanceID`. diff --git a/docs/references/protocol/transactions/types/clawback.md b/docs/references/protocol/transactions/types/clawback.md index d3ce6d3eba..7438208a0e 100644 --- a/docs/references/protocol/transactions/types/clawback.md +++ b/docs/references/protocol/transactions/types/clawback.md @@ -35,13 +35,14 @@ Clawback is disabled by default. To use clawback, you must send an [AccountSet t | Field | JSON Type | [Internal Type][] | Description | |:-------------------|:----------|:------------------|:------------------| | `Amount` | [Currency Amount][] | Amount |Indicates the amount being clawed back, as well as the counterparty from which the amount is being clawed back. The quantity to claw back, in the `value` sub-field, must not be zero. If this is more than the current balance, the transaction claws back the entire balance. The sub-field `issuer` within `Amount` represents the token holder's account ID, rather than the issuer's.| -| `Holder` | string | AccountID | (Optional) Specifies the holder's address from which to claw back. The holder must already own an `MPToken` object with a non-zero balance. | +| `Holder` | string | AccountID | (Optional) Specifies the holder's address from which to claw back. The holder must already own an `MPToken` object with a non-zero balance. _(Requires the [MPToken amendment][] {% not-enabled /%})_ | {% admonition type="info" name="Note" %}For an IOU (trust line) in the XRP Ledger, the party that created a token is called the _issuer_, but trust lines are bidirectional and, under some configurations, both sides can be seen as the issuer. In this transaction, the token issuer's address is in the `Account` field, and the token holder's address is in the `Amount` field's `issuer` sub-field.{% /admonition %} {% admonition type="info" name="Note" %}To claw back funds from an MPT holder, the issuer must have specified that the MPT allows clawback by setting the `tfMPTCanClawback` flag when creating the MPT using the `MPTokenIssuanceCreate` transaction. Assuming an MPT was created with this flag set, clawbacks are allowed using the `Clawback` transaction.{% /admonition %} + ## Error Cases Besides errors that can occur for all transactions, {% $frontmatter.seo.title %} transactions can result in the following [transaction result codes](../transaction-results/index.md): @@ -51,6 +52,6 @@ Besides errors that can occur for all transactions, {% $frontmatter.seo.title %} | `temDISABLED` | Occurs if the [Clawback amendment](/resources/known-amendments.md#clawback) is not enabled. | | `temBAD_AMOUNT` | Occurs if the holder's balance is 0. It is not an error if the amount exceeds the holder's balance; in that case, the maximum available balance is clawed back. Also occurs if the counterparty listed in `Amount` is the same as the `Account` issuing this transaction. | | `tecNO_LINE` | Occurs there is no trust line with the counterparty or that trust line's balance is 0. | -| `tecNO_PERMISSION` | Occurs if you attempt to set `lsfAllowTrustlineClawback` while `lsfNoFreeze` is set. Also occurs, conversely, if you try to set `lsfNoFreeze` while `lsfAllowTrustLineClawback` is set. | +| `tecNO_PERMISSION` | Occurs if you attempt to set `lsfAllowTrustlineClawback` while `lsfNoFreeze` is set. Also occurs, conversely, if you try to set `lsfNoFreeze` while `lsfAllowTrustLineClawback` is set. | {% raw-partial file="/docs/_snippets/common-links.md" /%} diff --git a/docs/references/protocol/transactions/types/mptokenauthorize.md b/docs/references/protocol/transactions/types/mptokenauthorize.md index 6b84b3c84d..b190e7ab4f 100644 --- a/docs/references/protocol/transactions/types/mptokenauthorize.md +++ b/docs/references/protocol/transactions/types/mptokenauthorize.md @@ -9,7 +9,7 @@ labels: # MPTokenAuthorize [[Source]](https://github.com/XRPLF/rippled/blob/master/src/xrpld/app/tx/detail/MPTokenAuthorize.cpp "Source") -{% partial file="/docs/_snippets/mpts-disclaimer.md" /%} +_(Requires the [MPToken amendment][] {% not-enabled /%})_ This transaction enables an account to hold an amount of a particular MPT issuance. When applied successfully, it creates a new `MPToken` object with an initial zero balance, owned by the holder account. @@ -32,4 +32,6 @@ Transactions of the MPTokenAuthorize type support additional values in the Flags | Flag Name | Hex Value | Decimal Value | Description | |:-------------------|:-------------|:--------------|:------------------------------| -| `tfMPTUnauthorize` | `0x00000001` | 1 | If set, and transaction is submitted by a holder, it indicates that the holder no longer wants to hold the `MPToken`, which will be deleted as a result. If the holder's `MPToken` has a non-zero balance while trying to set this flag, the transaction fails. On the other hand, if set, and transaction is submitted by an issuer, it would mean that the issuer wants to unauthorize the holder (only applicable for allow-listing), which would unset the `lsfMPTAuthorized` flag on the `MPToken`. | \ No newline at end of file +| `tfMPTUnauthorize` | `0x00000001` | 1 | If set, and transaction is submitted by a holder, it indicates that the holder no longer wants to hold the `MPToken`, which will be deleted as a result. If the holder's `MPToken` has a non-zero balance while trying to set this flag, the transaction fails. On the other hand, if set, and transaction is submitted by an issuer, it would mean that the issuer wants to unauthorize the holder (only applicable for allow-listing), which would unset the `lsfMPTAuthorized` flag on the `MPToken`. | + +{% raw-partial file="/docs/_snippets/common-links.md" /%} \ No newline at end of file diff --git a/docs/references/protocol/transactions/types/mptokenissuancecreate.md b/docs/references/protocol/transactions/types/mptokenissuancecreate.md index 5ae2d14965..2b53bafa02 100644 --- a/docs/references/protocol/transactions/types/mptokenissuancecreate.md +++ b/docs/references/protocol/transactions/types/mptokenissuancecreate.md @@ -9,7 +9,7 @@ labels: # MPTokenIssuanceCreate [[Source]](https://github.com/XRPLF/rippled/blob/master/src/xrpld/app/tx/detail/MPTokenIssuanceCreate.cpp "Source") -{% partial file="/docs/_snippets/mpts-disclaimer.md" /%} +_(Requires the [MPToken amendment][] {% not-enabled /%})_ The `MPTokenIssuanceCreate` transaction creates an MPTokenIssuance object and adds it to the relevant directory node of the creator account. This transaction is the only opportunity an issuer has to specify any token fields that are defined as immutable (for example, MPT Flags). @@ -61,3 +61,4 @@ Transactions of the MPTokenIssuanceCreate type support additional values in the | `tfMPTCanTransfer` | `0x00000020` | `32` | If set, indicates that tokens can be transferred to other accounts that are not the issuer. | | `tfMPTCanClawback` | `0x00000040` | `64` | If set, indicates that the issuer can use the Clawback transaction to claw back value from individual holders. | +{% raw-partial file="/docs/_snippets/common-links.md" /%} diff --git a/docs/references/protocol/transactions/types/mptokenissuancedestroy.md b/docs/references/protocol/transactions/types/mptokenissuancedestroy.md index 941bf89b96..27c623bba0 100644 --- a/docs/references/protocol/transactions/types/mptokenissuancedestroy.md +++ b/docs/references/protocol/transactions/types/mptokenissuancedestroy.md @@ -7,7 +7,7 @@ labels: --- # MPTokenIssuanceDestroy -{% partial file="/docs/_snippets/mpts-disclaimer.md" /%} +_(Requires the [MPToken amendment][] {% not-enabled /%})_ The `MPTokenIssuanceDestroy` transaction is used to remove an `MPTokenIssuance` object from the directory node in which it is being held, effectively removing the token from the ledger ("destroying" it). @@ -31,3 +31,5 @@ If this operation succeeds, the corresponding `MPTokenIssuance` is removed and t |:--------------------|:--------------------|:------------------|:-------------------| | `TransactionType` | string | UInt16 | Indicates the new transaction type MPTokenIssuanceDestroy. | | `MPTokenIssuanceID` | string | UInt192 | Identifies the `MPTokenIssuance` object to be removed by the transaction. | + +{% raw-partial file="/docs/_snippets/common-links.md" /%} diff --git a/docs/references/protocol/transactions/types/mptokenissuanceset.md b/docs/references/protocol/transactions/types/mptokenissuanceset.md index 4c511a26eb..cfe95bfc66 100644 --- a/docs/references/protocol/transactions/types/mptokenissuanceset.md +++ b/docs/references/protocol/transactions/types/mptokenissuanceset.md @@ -7,7 +7,7 @@ labels: --- # MPTokenIssuanceSet -{% partial file="/docs/_snippets/mpts-disclaimer.md" /%} +_(Requires the [MPToken amendment][] {% not-enabled /%})_ Use this transaction to update a mutable property for a Multi-purpose Token. @@ -41,3 +41,5 @@ Transactions of the `MPTokenIssuanceSet` type support additional values in the ` |:-------------------|:-------------|:--------------|:------------------------------| | `tfMPTLock` | `0x00000001` | 1 | If set, indicates that all MPT balances for this asset should be locked. | | `tfMPTUnlock` | `0x00000002` | 2 | If set, indicates that all MPT balances for this asset should be unlocked. | + +{% raw-partial file="/docs/_snippets/common-links.md" /%} diff --git a/docs/references/protocol/transactions/types/payment.md b/docs/references/protocol/transactions/types/payment.md index 2db2262cfd..3031234902 100644 --- a/docs/references/protocol/transactions/types/payment.md +++ b/docs/references/protocol/transactions/types/payment.md @@ -141,6 +141,8 @@ In the above example with a ¥95/$15 offer and a ¥5/$2 offer, the situation is ## MPT Payments +_(Requires the [MPToken amendment][] {% not-enabled /%})_ + When you send a payment using MPTs, the _Amount_ field requires only the `mpt_issuance_id` and the `value`. The `MPTokenIssuanceID` is used to uniquely identify the MPT for the transaction. Version 1 MPTokens only support direct MPT payment between accounts. They cannot be traded in the decentralized exchange.