Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding Soroban to Stellar Fundamentals #269

Merged
merged 52 commits into from
Dec 22, 2023
Merged
Show file tree
Hide file tree
Changes from 42 commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
13e2fb9
Networks
briwylde08 Nov 13, 2023
1cc0123
formatting
briwylde08 Nov 14, 2023
b4ad710
update ledger section
briwylde08 Nov 14, 2023
98678ce
update asset section
briwylde08 Nov 14, 2023
2eafb8d
Merge branch 'main' into soroban-in-stellar-fundamentals
ElliotFriend Dec 1, 2023
1e639f3
adding details to Soroban operations
ElliotFriend Dec 1, 2023
d6f0b4c
markdown linting for the list-of-operations page
ElliotFriend Dec 1, 2023
9a66b74
update Lumens section to include smart contract data
briwylde08 Dec 4, 2023
2430999
network additions to include Futurenet
briwylde08 Dec 4, 2023
83c7ae7
edit to accounts page
briwylde08 Dec 4, 2023
3e96657
quick addition to Assets section
briwylde08 Dec 4, 2023
5fd0cf6
starting on the stack
briwylde08 Dec 4, 2023
6458dfb
update RPC for Futurenet
briwylde08 Dec 5, 2023
b030f1b
updating stellar stack to include Soroban components
briwylde08 Dec 5, 2023
9976cf0
starting on operations and transactions
briwylde08 Dec 5, 2023
df507f6
updated stack image
briwylde08 Dec 7, 2023
79cab8d
update ledger
briwylde08 Dec 7, 2023
2b89ace
other network edits
briwylde08 Dec 7, 2023
dbc1074
more on operations & transactions
briwylde08 Dec 8, 2023
ea534e8
docs: first stab at a "contract" data structure page... meh
ElliotFriend Dec 8, 2023
8b0967f
Merge branch 'soroban-in-stellar-fundamentals' of github.com:stellar/…
ElliotFriend Dec 8, 2023
5389cd4
added bit about resource limitations
briwylde08 Dec 8, 2023
3733137
Merge branch 'soroban-in-stellar-fundamentals' of https://github.com/…
briwylde08 Dec 8, 2023
a5b5537
small copy tweaks
briwylde08 Dec 18, 2023
43f54df
Update docs/fundamentals-and-concepts/lumens.mdx
briwylde08 Dec 19, 2023
7bd323d
Update docs/fundamentals-and-concepts/networks.mdx
briwylde08 Dec 19, 2023
caa5c5d
Update docs/fundamentals-and-concepts/networks.mdx
briwylde08 Dec 19, 2023
6fc1967
Update docs/fundamentals-and-concepts/list-of-operations.mdx
ElliotFriend Dec 19, 2023
9e1ae49
docs: swap persistent/instance storage add note about abstraction
ElliotFriend Dec 19, 2023
0a63ab5
note the `extendTo` parameter is an absolute seq number, not relative
ElliotFriend Dec 19, 2023
42ba811
add redirect for networks page
ElliotFriend Dec 19, 2023
9792f94
docs: add description of "soroban" in "smart contracts" page
ElliotFriend Dec 19, 2023
d770404
Update docs/fundamentals-and-concepts/lumens.mdx
briwylde08 Dec 20, 2023
0a67aec
Update docs/fundamentals-and-concepts/lumens.mdx
briwylde08 Dec 20, 2023
8affa15
Update docs/fundamentals-and-concepts/stellar-data-structures/assets.mdx
briwylde08 Dec 20, 2023
9c49ce1
Update docs/fundamentals-and-concepts/stellar-data-structures/operati…
briwylde08 Dec 20, 2023
09a9b18
Update docs/fundamentals-and-concepts/stellar-data-structures/operati…
briwylde08 Dec 20, 2023
284c033
Update docs/fundamentals-and-concepts/transaction-lifecycle.mdx
briwylde08 Dec 20, 2023
3bbbfd9
fix link for state archival, include bit about instance storage
ElliotFriend Dec 20, 2023
e0d9c83
update networks
briwylde08 Dec 20, 2023
bd51ff2
Merge branch 'soroban-in-stellar-fundamentals' of https://github.com/…
briwylde08 Dec 20, 2023
34a2f75
transaction lifecycle disclaimer
briwylde08 Dec 20, 2023
c01c869
Update docs/fundamentals-and-concepts/lumens.mdx
briwylde08 Dec 22, 2023
59fdfd7
Update docs/fundamentals-and-concepts/networks.mdx
briwylde08 Dec 22, 2023
71f173f
Update docs/fundamentals-and-concepts/networks.mdx
briwylde08 Dec 22, 2023
3023e09
Update docs/fundamentals-and-concepts/stellar-data-structures/contrac…
briwylde08 Dec 22, 2023
aa803f7
Update docs/fundamentals-and-concepts/stellar-data-structures/contrac…
briwylde08 Dec 22, 2023
cc1c73a
rent and asset edits
briwylde08 Dec 22, 2023
7352c25
Merge branch 'soroban-in-stellar-fundamentals' of https://github.com/…
briwylde08 Dec 22, 2023
a02cd71
Update docs/fundamentals-and-concepts/stellar-stack.mdx
briwylde08 Dec 22, 2023
330d552
formatting
briwylde08 Dec 22, 2023
1f7e7d7
Update docs/fundamentals-and-concepts/stellar-stack.mdx
briwylde08 Dec 22, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion api/horizon/introduction/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Horizon is a [RESTful API](https://en.wikipedia.org/wiki/Representational_state_
The Stellar Development Foundation (SDF) runs two instances of Horizon:

- [https://horizon.stellar.org/](https://horizon.stellar.org/) for interacting with the public network
- [https://horizon-testnet.stellar.org/](https://horizon-testnet.stellar.org/) for interacting with the [testnet](/docs/fundamentals-and-concepts/testnet-and-pubnet)
- [https://horizon-testnet.stellar.org/](https://horizon-testnet.stellar.org/) for interacting with the [testnet](/docs/fundamentals-and-concepts/networks)

<MethodTable title="API Reference Sections">

Expand Down
58 changes: 55 additions & 3 deletions docs/fundamentals-and-concepts/list-of-operations.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -685,20 +685,56 @@ Note that Soroban transactions can only contain one operation per transaction.

Learn more in the [Soroban docs](https://soroban.stellar.org/docs/fundamentals-and-concepts/invoking-contracts-with-transactions#invokehostfunctionop).

## Bump Footprint Expiration
**Threshold**: Medium
**Result**: `InvokeHostFunctionResult`
**Parameters**:

| Parameters | Type | Description |
| --- | --- | --- |
| Host Function | HostFunction | The host function to invoke |
| Auth | Soroban Authorization Entry | Per-address authorizations for this host function. |

**Possible errors**:

| Error | Code | Description |
| --- | --- | --- |
| INVOKE_HOST_FUNCTION_MALFORMED | -1 | One or more of the inputs to the operation was malformed. |
| INVOKE_HOST_FUNCTION_TRAPPED | -2 | The function invocation trapped in the Soroban runtime. |
| INVOKE_HOST_FUNCTION_RESOURCE_LIMIT_EXCEEDED | -3 | The function invocation could not complete within the currently configured resource constraints of the network. |
| INVOKE_HOST_FUNCTION_ENTRY_ARCHIVED | -4 | A ledger entry required for this function's footprint is in an archived state, and must be restored. |
| INVOKE_HOST_FUNCTION_INSUFFICIENT_REFUNDABLE_FEE | -5 | The refundable Soroban fee provided was not sufficient to pay for the compute resources required by this function invocation. |

## Extend Footprint TTL

:::info

Soroban is currently live on Testnet, so this operation is only usable on Testnet.

:::

Bump the expiration ledger of entries for Soroban smart contracts with the `BumpFootprintExpirationOp`.
Extend the time to live (TTL) of entries for Soroban smart contracts with the `ExtendFootprintTTLOp`. This operation extends the TTL of the entries specified in the `readOnly` footprint of the transaction so that they will live at least until the `extendTo` ledger sequence number is reached.

Note that Soroban transactions can only contain one operation per transaction.

Learn more in the [Soroban docs](https://soroban.stellar.org/docs/fundamentals-and-concepts/state-expiration#bumpfootprintexpirationop).

**Threshold**: Medium
**Result**: `ExtendFootprintTTLResult`
**Parameters**:

| Parameters | Type | Description |
| --- | --- | --- |
| Ext | ExtensionPoint | Reserved for later use. |
| Extend To | integer | The ledger sequence number the entries will live until. |

**Possible errors**:

| Error | Code | Description |
| --- | --- | --- |
| EXTEND_FOOTPRINT_TTL_MALFORMED | -1 | One or more of the inputs to the operation was malformed. |
| EXTEND_FOOTPRINT_TTL_RESOURCE_LIMIT_EXCEEDED | -2 | The TTL extension could not be completed within the currently configured resource constraints of the network. |
| EXTEND_FOOTPRINT_TTL_INSUFFICIENT_REFUNDABLE_FEE | -3 | The refundable Soroban fee provided was not sufficient to pay for TTL extension of the specified ledger entries. |

## Restore Footprint

:::info
Expand All @@ -707,8 +743,24 @@ Soroban is currently live on Testnet, so this operation is only usable on Testne

:::

Make expired Soroban smart contract entries accessible again by restoring them with `RestoreFootprintOp`.
Make archived Soroban smart contract entries accessible again by restoring them with `RestoreFootprintOp`. This operation restores the archived entries specified in the `readWrite` footprint.

Note that Soroban transactions can only contain one operation per transaction.

Learn more in the [Soroban docs](https://soroban.stellar.org/docs/fundamentals-and-concepts/state-expiration#restorefootprintop).

**Threshold**: Medium
**Result**: `RestoreFootprintResult`
**Parameters**:

| Parameters | Type | Description |
| ---------- | -------------- | ----------------------- |
| Ext | ExtensionPoint | Reserved for later use. |

**Possible errors**:

| Error | Code | Description |
| --- | --- | --- |
| RESTORE_FOOTPRINT_MALFORMED | -1 | One or more of the inputs to the operation was malformed. |
| RESTORE_FOOTPRINT_RESOURCE_LIMIT_EXCEEDED | -2 | The archive restoration could not be completed within the currently configured resource constraints of the network. |
| RESTORE_FOOTPRINT_INSUFFICIENT_REFUNDABLE_FEE | -3 | The refundable Soroban fee provided was not sufficient to pay for archive restoration of the specified ledger entries. |
10 changes: 8 additions & 2 deletions docs/fundamentals-and-concepts/lumens.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,28 @@ title: Lumens (XLM)
sidebar_position: 60
---

Lumens (XLM) are the native currency of the Stellar network. The lumen is the only token that doesn’t require an issuer or trustline, and it pays all transaction fees and covers minimum balances on the network.
Lumens (XLM) are the native currency of the Stellar network. The lumen is the only token that doesn’t require an issuer or trustline, and it is used to pay all transaction fees, rent, and covers minimum balances on the network.
briwylde08 marked this conversation as resolved.
Show resolved Hide resolved
briwylde08 marked this conversation as resolved.
Show resolved Hide resolved

To read up on the basics of lumens, head over to our Stellar Learn site: [Stellar Learn: Lumens](https://www.stellar.org/lumens)

## Transaction fees

Stellar requires a small fee for all transactions to prevent ledger spam and prioritize transactions during surge pricing. Transaction fees are paid in lumens.

To learn about fees on Stellar, see our [Fees, Surge Pricing, and Fee Strategies Encyclopedia Entry](../encyclopedia/fees-surge-pricing-fee-strategies)
To learn about fees on Stellar, see our [Fees, Surge Pricing, and Fee Strategies Encyclopedia Entry](../encyclopedia/fees-surge-pricing-fee-strategies).

Smart contract transactions on Stellar employ a different fee structure based on an inclusion fee and resource consumption (which includes [rent](#rent)). Read more in the [Fees and Metering section](https://soroban.stellar.org/docs/fundamentals-and-concepts/fees-and-metering) in the Soroban docs.

## Base reserves

A unit of measurement used to calculate an account’s minimum balance. One base reserve is currently 0.5 XLM.

Validators can vote to change the base reserve, but that’s uncommon and should only happen every few years.

## Rent
briwylde08 marked this conversation as resolved.
Show resolved Hide resolved
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion: move the Rent section after the Minimum balance section. That way, you define base reserves, then talk about where base reserves are used, then talk about where they are not used, which I think is easier to follow.


Smart contract data does not require any base reserves in order to live on the ledger, so every smart contract entry must pay rent instead. The rent charged for an entry to exist on the ledger is based on how big the entry is and how long the it should be live on the ledger before being archived. There are different rent requirements for each storage type `Persistent`, `Temporary`, and `Instance`, which you can read about in the [Fees and Metering section](https://soroban.stellar.org/docs/fundamentals-and-concepts/fees-and-metering#refundable-resources) of the Soroban docs.

## Minimum balance

Stellar accounts must maintain a minimum balance to exist, which is calculated using the base reserve. An account must always maintain a minimum balance of two base reserves (currently 1 XLM). Every subentry after that requires an additional base reserve (currently 0.5 XLM) and increases the account’s minimum balance. Subentries include trustlines (for both traditional assets and pool shares), offers, signers, and data entries. An account cannot have more than 1,000 subentries.
Expand Down
103 changes: 103 additions & 0 deletions docs/fundamentals-and-concepts/networks.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
---
title: Networks
sidebar_position: 30
---

Stellar has three networks: the public network (Mainnet, also called Pubnet or the Public Network), the test network (Testnet), and a dev network (Futurenet). Mainnet is the main network used by applications in production. It connects to real financial rails and requires XLM to cover minimum balances, transaction fees, and rent. The Testnet is a smaller, free-to-use network maintained by SDF that functions like the Mainnet but doesn’t connect to real money. It has a built-in testnet XLM faucet (called Friendbot), and it's the best place for developers to test their applications. Futurenet is a dev network you can use to test more bleeding edge features that also has access to its own Friendbot.
briwylde08 marked this conversation as resolved.
Show resolved Hide resolved
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Stellar has three networks: the public network (Mainnet, also called Pubnet or the Public Network), the test network (Testnet), and a dev network (Futurenet). Mainnet is the main network used by applications in production. It connects to real financial rails and requires XLM to cover minimum balances, transaction fees, and rent. The Testnet is a smaller, free-to-use network maintained by SDF that functions like the Mainnet but doesn’t connect to real money. It has a built-in testnet XLM faucet (called Friendbot), and it's the best place for developers to test their applications. Futurenet is a dev network you can use to test more bleeding edge features that also has access to its own Friendbot.
Stellar has three networks: the public network (Mainnet, also called Pubnet or the Public Network), the test network (Testnet), and a dev network (Futurenet). Mainnet is the main network used by applications in production. It connects to real financial rails and requires XLM to cover minimum balances, transaction fees, and rent. The Testnet is a smaller, free-to-use network maintained by SDF that functions like the Mainnet but doesn’t connect to real money. It has a built-in testnet XLM faucet (called Friendbot), and it is reset on a regular cadence, so it is the best place for developers to test their applications when they need a stable test environment that mirrors Mainnet functionality. Futurenet is a dev network you can use to test more bleeding edge features that also has access to its own Friendbot. It is reset whenever a reset is necessary to upgrade software, so it's not as predictable as Testnet, but it is where new features may be deployed before they are implemented in stable releases for devs that want to experiment early.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe add a bit more color to help devs choose between Futurenet and Testnet?


## Stats: Mainnet versus Testnet versus Futurenet

### Mainnet

- Validator nodes are run by the public
- SDF offers a free [Horizon instance](https://horizon.stellar.org/) to interact with the Mainnet with a limited set of history, or you can [run your own](https://developers.stellar.org/docs/run-api-server)
briwylde08 marked this conversation as resolved.
Show resolved Hide resolved
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- SDF offers a free [Horizon instance](https://horizon.stellar.org/) to interact with the Mainnet with a limited set of history, or you can [run your own](https://developers.stellar.org/docs/run-api-server)
- SDF offers a free [Horizon instance](https://horizon.stellar.org/) to interact with the Mainnet with a limited set of history, or you can [run your own](https://developers.stellar.org/docs/run-api-server), or use one offered by an infrastructure provider.

- You need to fund your account with XLM from another account
- Mainnet is limited to 1,000 operations per ledger and will be limited to a maximum of 30 smart contract transactions per ledger (the precise amount of smart contract txs per ledger can vary greatly depending on transaction [resource limits](https://soroban.stellar.org/docs/fundamentals-and-concepts/fees-and-metering#resource-limits))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Mainnet is limited to 1,000 operations per ledger and will be limited to a maximum of 30 smart contract transactions per ledger (the precise amount of smart contract txs per ledger can vary greatly depending on transaction [resource limits](https://soroban.stellar.org/docs/fundamentals-and-concepts/fees-and-metering#resource-limits))
- Mainnet is limited to 1,000 operations per ledger and will be limited to somewhere around 30 smart contract transactions per ledger when the phased rollout of Protocol 20 is complete in Q1 2024 (the precise amount of smart contract txs per ledger can vary greatly depending on transaction [resource limits](https://soroban.stellar.org/docs/fundamentals-and-concepts/fees-and-metering#resource-limits))

- See more detailed smart contract network settings in the section on [Fees and Metering](https://soroban.stellar.org/docs/fundamentals-and-concepts/fees-and-metering) in the Soroban docs
- No publicly available RPC, see RPC service providers [here](https://soroban.stellar.org/docs/reference/rpc-list)

### Testnet

- SDF runs three core validator nodes
- SDF offers a free [Horizon instance](https://horizon-testnet.stellar.org/) you can use to interact with the Testnet
- Friendbot is a faucet you can use for free Testnet XLM
- Testnet is limited to 100 operations per ledger and one smart contract transaction per ledger
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is one smart contract transaction per ledger accurate? Just want to verify that's the case before we enshrine it in the docs.

- SDF offers free RPC endpoints, more information [here](https://soroban.stellar.org/docs/reference/rpc-list#sdf-futurenet-and-testnet-only)

### Futurenet

- SDF runs core validator nodes
- SDF offers a free [Horizon instance](https://horizon-futurenet.stellar.org) you can use to interact with the Futurenet
- Friendbot is a faucet you can use for free Futurenet XLM
- Futurenet is limited to 100 operations per ledger and one smart contract transaction per ledger
- SDF offers free RPC endpoints, more information [here](https://soroban.stellar.org/docs/reference/rpc-list#sdf-futurenet-and-testnet-only)

## Friendbot

Friendbot is a bot that funds accounts with fake XLM on Testnet or Futurenet. You can request XLM from Friendbot using the Stellar Laboratory or with various SDKs. Requests to Friendbot are rate limited, so use it wisely. Friendbot provides 10,000 fake XLM when funding a new account.

If you are creating multiple accounts, you can fund your first account with Friendbot and then use that first account to fund your subsequent accounts using the Create Account operation.

## Testnet and Futurenet data reset

Testnet and Futurenet are reset periodically to the genesis ledger to declutter the network, remove spam, reduce the time needed to catch up on the latest ledger, and help maintain the system. Resets clear all ledger entries (accounts, trustlines, offers, smart contract data, etc.), transactions, and historical data from Stellar Core, Horizon, and the Soroban RPC- which is why developers should not rely on the persistence of accounts or the state of any balances when using Testnet or Futurenet.

Futurenet resets are on a less regular cadence than Testnet resets and don't have a set schedule.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Futurenet resets are on a less regular cadence than Testnet resets and don't have a set schedule.
Futurenet resets happen when necessary, and often with very little warning. Testnet resets happen once per quarter on a set schedule.


Testnet resets happen once per quarter at 17:00 UTC and are announced at least two weeks in advance on the [Stellar Dashboard](http://dashboard.stellar.org/) and through several developer community channels. Here are the 2023 dates:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Testnet resets happen once per quarter at 17:00 UTC and are announced at least two weeks in advance on the [Stellar Dashboard](http://dashboard.stellar.org/) and through several developer community channels. Here are the 2023 dates:
Testnet resets happen once per quarter at 17:00 UTC and are announced at least two weeks in advance on the [Stellar Dashboard](http://dashboard.stellar.org/) and through several developer community channels. Here are the 2024 dates:


March 15, 2023
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
March 15, 2023
March 13, 2024

June 14, 2023
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
June 14, 2023
June 12, 2024

~~September 13, 2023~~ Note: this reset was skipped due to its proximity to the Protocol 20 Testnet upgrade.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
~~September 13, 2023~~ Note: this reset was skipped due to its proximity to the Protocol 20 Testnet upgrade.
September 11, 2024

December 18, 2023
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
December 18, 2023
December 11, 2024


If you run a Testnet or Futurenet Horizon instance, you need to re-join and re-sync to the network after a reset. Check out how to do that here: [Testnet Reset](https://github.com/stellar/packages/blob/master/docs/testnet-reset.md).

## Test data automation

It is recommended that you have testing infrastructure that can repopulate the Testnet and Futurenet with useful data after a reset. This will make testing more reliable and will help you scale your testing infrastructure to a private network if you choose to do so. For example, you may want to:

- Generate issuers of assets for testing the development of a wallet;
- Generate orders on the order book (both current and historical) for testing the development of a trading client;
- Recreate liquidity pools;
- Redeploy smart contracts.

If you maintain an application, you should think about creating a data set that is representative enough to test your primary use cases, and allow for robust testing even when Testnet or Futurenet are not available.

A script can automate this entire process by creating an account with Friendbot and submitting a set of transactions that are predefined as a part of your testing infrastructure.

## What Testnet and Futurenet should and should not be used for

### Testnet and Futurenet are good for

- Creating test accounts (with funding from Friendbot);
- Developing applications and contracts and exploring tutorials on Stellar without the potential to lose any assets;
- Testing existing applications against new releases or release candidates of Stellar Core, Horizon, and the Soroban RPC;
- Performing data analysis on a smaller, non-trivial data set compared to the Mainnet.

### Testnet and Futurenet are bad for

- Load and stress testing;
- High availability test infrastructure- SDF does not guarantee Testnet availability;
- Long-term storage of data on the network since the network resets periodically;
- A testing infrastructure that requires more control over the test environment, such as:
- The ability to control the data reset frequency;
- The need to secure private or sensitive data (before launching on the Mainnet). You can always run your own test network for use cases that don’t work well with SDF’s Testnet.

## Moving your project from Testnet or Futurenet to production

Mainnet, Testnet, and Futurenet each have their own unique passphrase, which is used to validate signatures on a given transaction.

The current passphrases for the Stellar Mainnet, Testnet, and Futurenet are:

**Mainnet (Pubnet)**: `Public Global Stellar Network ; September 2015`

**Testnet**: `Test SDF Network ; September 2015`

**Futurenet**: `Test SDF Future Network ; October 2022`

For applications that don’t rely on the state of the network (such as specific accounts needing to exist), you move to production by changing the network passphrase and ensuring your Horizon instance is connected to Mainnet.

If you’ve been running a Stellar Core or Horizon instance against the Testnet and want to switch to production, changing the passphrase will require both respective databases to be completely reinitialized. If you run your own RPC on Testnet or Futurenet, you may want to use an RPC service when you move to Mainnet. Check out the RPC service providers [here](https://soroban.stellar.org/docs/reference/rpc-list).

To learn more about network passphrases, see our [Network Passphrase Encyclopedia Entry](../encyclopedia/network-passphrases)
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Account data is stored in subentries, each of which increases an account’s min
- Trustlines (includes traditional assets and pool shares)
- Offers
- Additional signers
- Data entries
- Data entries (includes data made with the `manageData` operation, not smart contract ledger entries)

## Trustlines

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ Accounts on the Stellar network can be used to track, hold, and transfer any typ

Assets on Stellar have two identifying characteristics: the asset code and the issuer. Since more than one organization can issue a credit representing the same asset, asset codes often overlap (for example, multiple companies offer a USD token on Stellar). Assets are uniquely identified by the combination of their asset code and issuer.

Stellar assets differ from smart contract tokens, which you can read about in the [Tokens section](https://soroban.stellar.org/docs/reference/interfaces/token-interface) in the Soroban docs.
briwylde08 marked this conversation as resolved.
Show resolved Hide resolved

## Asset components

### Asset code
Expand All @@ -25,6 +27,12 @@ There is no dedicated operation to create an asset on Stellar. Instead, assets a

The public key of the issuing account is linked on the ledger to the asset. Responsibility for and control over an asset resides with the issuing account. Since settings are stored at the account level on the ledger, the issuing account is where you use set_options operations to link to meta-information about an asset and set authorization flags.

## Wrapping Stellar assets

Assets issued on the Stellar network can be used in smart contracts with the Stellar Asset Contract (SAC), which is an implementation of [CAP-46-6: Smart Contract Standardized Asset](https://github.com/stellar/stellar-protocol/blob/master/core/cap-0046-06.md). The SAC allows users to use their Stellar account and trustline balances in Soroban and is a primary intersection where smart contracts interact with the rest of the Stellar network.

Learn more in the [SAC section in the Soroban docs](https://soroban.stellar.org/docs/advanced-tutorials/stellar-asset-contract).

## Representation

In Horizon, assets are represented in a JSON object:
Expand Down
Loading