diff --git a/docs/content/developer/stardust/claiming.mdx b/docs/content/developer/stardust/claiming.mdx index c97db73b75d..4c8b8384552 100644 --- a/docs/content/developer/stardust/claiming.mdx +++ b/docs/content/developer/stardust/claiming.mdx @@ -3,16 +3,15 @@ title: Claiming Stardust Assets description: Describes how to access the migrated assets and tokens --- - - Explains the resulting migrated state for simple coins (exchanges) - - Demonstrates through examples for each output type the resulting move objects - - Explains what commands need to be called in a PTB to claim the assets - - Describes transaction sponsorship from iota addresses for shimmer claiming +As detailed in the [Stardust Move Models](move-models.mdx), Stardust assets are represented as Move objects within the ledger. Claiming these assets involves enabling original owners to utilize a [Programmable Transaction Block](../iota-101/transactions/ptb/prog-txn-blocks.mdx) to "unlock" assets such as IOTA, Shimmer, custom [`Coin`](../../references/framework/iota-framework/coin.mdx#resource-coin)s, or even `Alias` and `Nft` objects. -## IOTA tokens automatic migration +This process takes advantage of Move's unique features to ensure that assets are transferred and unlocked securely and efficiently to their rightful owners. ## Output types to Move Objects +Stardust assets come in the form of Outputs and each Output can be of a different type. For understanding how Outputs have been transformed into Move Objects based on their types, please refer to the [Stardust Move Models](move-models.mdx#summary) page. In here, one or more claiming examples for each Output type will be shown. + ## Examples of Stardust asset claim transactions diff --git a/docs/content/developer/stardust/claiming/alias.mdx b/docs/content/developer/stardust/claiming/alias.mdx index bcafaae7c14..1601b298e23 100644 --- a/docs/content/developer/stardust/claiming/alias.mdx +++ b/docs/content/developer/stardust/claiming/alias.mdx @@ -4,7 +4,7 @@ An address can own `AliasOutput` objects only if before the migration it was set as the Alias Governor Address. In this case, the `AliasOutput` object is an owned object in the ledger and its owner is the Governor address. -Such address can be directly controlled by a user or by another object (either an `Alias` or `Nft` object). For the latter use case, check the [`Claiming an Output unlockable by an Alias/Nft Address`](address-uc.mdx) example. +Such address can be directly controlled by a user or by another object (either an `Alias` or `Nft` object). For the latter use case, check the [`Claiming an Output unlockable by an Alias/Nft Address`](address-unlock-condition.mdx) example. ## Claim of an Alias Output diff --git a/docs/content/developer/stardust/move-models.mdx b/docs/content/developer/stardust/move-models.mdx index 4d909294bb7..2b3a59879f6 100644 --- a/docs/content/developer/stardust/move-models.mdx +++ b/docs/content/developer/stardust/move-models.mdx @@ -7,6 +7,19 @@ description: Describes how stardust assets are represented in the object-based M This document describes what move models the Stardust UTXOs are migrated to in the Move-based ledger in IOTA Rebased. First, the Stardust Move Package is discussed that emulates the legacy UTXO models in object-based move. + ## Summary + +| Stardust Output (UTXO) | Move Container or Migrated Object | Encapsulated Move Assets Inside the Container | +|--------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| Basic Output with IOTA/SMR only | [`Coin`](../../references/framework/iota-framework/coin.mdx#resource-coin) | ready to be used, no need to extract any assets | +| Basic Output with IOTA/SMR and native tokens | [`Coin`](../../references/framework/iota-framework/coin.mdx#resource-coin) and one or more [`Coin`](../../references/framework/iota-framework/coin.mdx#resource-coin) | ready to be used, no need to extract any assets | +| Basic Output with unlock conditions or features | [`BasicOutput`](../../references/framework/stardust/basic_output#resource-basicoutput) | [`Balance`](../../references/framework/iota-framework/balance#struct-balance), [`Bag`](../../references/framework/iota-framework/bag#resource-bag) of `Balance` key-ed by `"NATIVE_TOKEN"` | +| Alias Output | [`AliasOutput`](../../references/framework/iota-framework/balance#struct-balance), [`Bag`](../../references/framework/iota-framework/bag#resource-bag) of `Balance` key-ed by `"NATIVE_TOKEN"`, [`Alias`](../../references/framework/stardust/alias#resource-alias) object | +| Nft Output | [`NftOutput`](../../references/framework/iota-framework/balance#struct-balance), [`Bag`](../../references/framework/iota-framework/bag#resource-bag) of `Balance` key-ed by `"NATIVE_TOKEN"`, [`Nft`](../../references/framework/stardust/nft#resource-nft) object | +| Foundry Output | Migrated to a Move Package with [template](https://github.com/iotaledger/iota/blob/develop/crates/iota-genesis-builder/src/stardust/native_token/package_template/sources/native_token_template.move) and [`CoinManager`](../../references/framework/iota-framework/coin_manager). Base tokens of the output are sent to the controlling alias as `Coin` objects. | - | +| [Vested Rewards From the Stardust Upgrade](https://github.com/iotaledger/new_supply) | [`Timelock>`](../../references/framework/iota-framework/timelock.mdx#resource-timelock) objects. | - | + + ## Design Principles - The migration to IOTA Rebased aims to move away from the Stardust-based ledger concepts and transform assets into their pure @@ -518,18 +531,3 @@ public fun extract_assets(output: nft_output::NftOutput, ctx: &mut tx_cont - The caller has to decide what address to send the `Nft` object to. - The `NftOutput` container is destroyed in the process. - ## Summary - - -| Stardust Output (UTXO) | Move Container or Migrated Object | Encapsulated Move Assets Inside the Container | -|--------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| Basic Output with IOTA/SMR only | [`Coin`](../../references/framework/iota-framework/coin.mdx#resource-coin) | ready to be used, no need to extract any assets | -| Basic Output with IOTA/SMR and native tokens | [`Coin`](../../references/framework/iota-framework/coin.mdx#resource-coin) and one or more [`Coin`](../../references/framework/iota-framework/coin.mdx#resource-coin) | ready to be used, no need to extract any assets | -| Basic Output with unlock conditions or features | [`BasicOutput`](../../references/framework/stardust/basic_output#resource-basicoutput) | [`Balance`](../../references/framework/iota-framework/balance#struct-balance), [`Bag`](../../references/framework/iota-framework/bag#resource-bag) of `Balance` key-ed by `"NATIVE_TOKEN"` | -| Alias Output | [`AliasOutput`](../../references/framework/iota-framework/balance#struct-balance), [`Bag`](../../references/framework/iota-framework/bag#resource-bag) of `Balance` key-ed by `"NATIVE_TOKEN"`, [`Alias`](../../references/framework/stardust/alias#resource-alias) object | -| Nft Output | [`NftOutput`](../../references/framework/iota-framework/balance#struct-balance), [`Bag`](../../references/framework/iota-framework/bag#resource-bag) of `Balance` key-ed by `"NATIVE_TOKEN"`, [`Nft`](../../references/framework/stardust/nft#resource-nft) object | -| Foundry Output | Migrated to a Move Package with [template](https://github.com/iotaledger/iota/blob/develop/crates/iota-genesis-builder/src/stardust/native_token/package_template/sources/native_token_template.move) and [`CoinManager`](../../references/framework/iota-framework/coin_manager). Base tokens of the output are sent to the controlling alias as `Coin` objects. | - | -| [Vested Rewards From the Stardust Upgrade](https://github.com/iotaledger/new_supply) | [`Timelock>`](../../references/framework/iota-framework/timelock.mdx#resource-timelock) objects. | - | - - -