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

Update Network Information #1541

Merged
merged 17 commits into from
May 27, 2024
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
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
3 changes: 3 additions & 0 deletions docs/build/_partials/_metamask_buttons.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';

<Tabs groupId='network'>
<TabItem value='iota' label='IOTA EVM'>
<AddToMetaMaskButton {...Networks['iota']}/>
</TabItem>
<TabItem value='iota_testnet' label='IOTA EVM Testnet'>
<AddToMetaMaskButton {...Networks['iota_testnet']}/>
</TabItem>
Expand Down
12 changes: 12 additions & 0 deletions docs/build/getting-started/networks-endpoints.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,18 @@ This network runs under a [Coordinator PoA scheme](/learn/protocols/coordinator/

<NetworkInfo.L1 {...Networks['iota']}/>

### IOTA EVM

[IOTA EVM](https://explorer.evm.iota.org) is the L2 EVM running on top of the IOTA network.

<AddToMetaMaskButton {...Networks['iota']} />

<NetworkInfo.Evm {...Networks['iota']}/>

#### Additional Info

<NetworkInfo.EvmCustom {...Networks['iota']}/>

## IOTA Testnet

[The IOTA Testnet](https://explorer.iota.org/iota-testnet) acts as a test bed for builders without any real world value.
Expand Down
14 changes: 12 additions & 2 deletions docs/build/getting-started/sidebars.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,16 @@ module.exports = {
type: 'link',
href: 'https://explorer.shimmer.network',
},
{
label: 'IOTA EVM Explorer',
type: 'link',
href: 'https://explorer.evm.iota.org',
},
{
label: 'IOTA EVM Toolkit',
type: 'link',
href: 'https://evm-toolkit.evm.iotaledger.net/',
},
{
label: 'Shimmer EVM Explorer',
type: 'link',
Expand All @@ -51,12 +61,12 @@ module.exports = {
href: 'https://evm-toolkit.evm.shimmer.network/',
},
{
label: 'Shimmer EVM Testnet Toolkit & Faucet',
label: 'EVM Testnet Toolkit & Faucet',
type: 'link',
href: 'https://evm-toolkit.evm.testnet.shimmer.network/',
},
{
label: 'Oracles for Shimmer EVM',
label: 'Oracles for IOTA EVM and ShimmerEVM',
type: 'doc',
id: 'oracles',
},
Expand Down
5 changes: 2 additions & 3 deletions docs/build/iota-sandbox/docs/welcome.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,9 @@ It is not for creating production-ready networks.

:::

:::tip Public Testnet
:::tip Testnet

If possible,
you should use the [public testnet](https://wiki.iota.org/build/networks-endpoints/#public-testnet)
If possible, you should use one of the testnets(/build/networks-endpoints)
where you can experiment with confidence and community support.

:::

This file was deleted.

23 changes: 19 additions & 4 deletions docs/build/isc/v1.0.0-rc.6/docs/_partials/_hardhat_config.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,21 @@ import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';

<Tabs groupId='network'>
<TabItem value='iota_testnet' label='IOTA EVM Testnet'>

<CodeBlock language="js">
{`
networks: {
'iotaevm-testnet': {
url: '${Networks['iota_testnet'].evm.rpcUrls[0]}',
chainId: ${parseInt(Networks['iota_testnet'].evm.chainId)},
accounts: [YOUR PRIVATE KEY],
},
}
`}
</CodeBlock>

</TabItem>
<TabItem value='shimmer_testnet' label='ShimmerEVM Testnet'>

<CodeBlock language="js">
Expand All @@ -19,14 +34,14 @@ networks: {
</CodeBlock>

</TabItem>
<TabItem value='iota_testnet' label='IOTA EVM Testnet'>
<TabItem value='iota' label='IOTA EVM'>

<CodeBlock language="js">
{`
networks: {
'iotaevm-testnet': {
url: '${Networks['iota_testnet'].evm.rpcUrls[0]}',
chainId: ${parseInt(Networks['iota_testnet'].evm.chainId)},
'iotaevm': {
url: '${Networks['iota'].evm.rpcUrls[0]}',
chainId: ${parseInt(Networks['iota'].evm.chainId)},
accounts: [YOUR PRIVATE KEY],
},
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ Here are some of the most important properties and limitations of EVM support in

There is no guaranteed _block time_. A new EVM "block" will be created only when an ISC block is created, and ISC does
not enforce an average block time. This means that block times are variable; a new block will be created as soon as needed.
The average block time on [ShimmerEVM](/build/networks-endpoints#shimmerevm) is 2.8 seconds.
The average block time on [IOTA EVM](/build/networks-endpoints#iotaevm) and [ShimmerEVM](/build/networks-endpoints#shimmerevm)
is 2.8 seconds.

### The Magic Contract

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
import EVMCompatibility from '../_admonitions/_EVM_compatibility.md'
import NetworkWarning from '../_admonitions/_network_warning.md'

# Supported Virtual Machines & Languages

<NetworkWarning/>

The current release of IOTA Smart Contracts has support for [EVM/Solidity](#evmsolidity-based-smart-contracts) smart
contracts, as well as experimental [Wasm](#wasm-vm-for-isc) smart contracts, providing compatibility with
existing smart contracts and tooling from other EVM based chains like Ethereum. This allows us to offer the existing
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ tags:
- mainnet
- shimmer
- devnet
- public testnet
- EVM Testnet
- reference
- Endpoints
---
Expand Down Expand Up @@ -35,6 +35,69 @@ The other values (network name and currency symbol) can be whatever value you li

:::

## IOTA EVM

[IOTA EVM](https://explorer.evm.iota.org) is the L2 EVM running on top of the IOTA network.

<AddToMetaMaskButton {...Networks['iota']} />

<NetworkInfo.Evm {...Networks['iota']}/>

### Additional Info

<NetworkInfo.EvmCustom {...Networks['iota']}/>

## IOTA EVM Testnet

<AddToMetaMaskButton {...Networks['iota_testnet']} />

[The IOTA EVM Testnet](https://explorer.evm.testnet.iotaledger.net/) runs as a layer 2 on top
of the [IOTA Testnet](/build/networks-endpoints#iota-testnet). This network uses ISC to facilitate

:::info

This network is subject to occasional resets (no data retention) which are usually announced with a one-week grace period.

:::

<NetworkInfo.Evm {...Networks['iota_testnet']} />

:::note

The other values (network name and currency symbol) can be whatever value you like.

:::

### Additional Info

<NetworkInfo.EvmCustom {...Networks['iota_testnet']}/>

## ShimmerEVM Testnet

<AddToMetaMaskButton {...Networks['shimmer_testnet']} />

[The ShimmerEVM Testnet](https://explorer.evm.testnet.shimmer.network/) runs as a layer 2 on top
of the [Shimmer Testnet](/build/networks-endpoints#shimmer-testnet). This network uses ISC to facilitate
an Ethereum Virtual Machine and has an enshrined bridge to layer 1.

:::info

This network is subject to occasional resets (no data retention) which are usually announced with a one-week grace period.

:::

<NetworkInfo.Evm {...Networks['shimmer_testnet']} />

:::note

The other values (network name and currency symbol) can be whatever value you like.

:::

### Additional Info

<NetworkInfo.EvmCustom {...Networks['shimmer_testnet']}/>

## ShimmerEVM

[ShimmerEVM](https://explorer.evm.shimmer.network/) is the L2 EVM running on top of the Shimmer network.
Expand All @@ -43,6 +106,10 @@ The other values (network name and currency symbol) can be whatever value you li

<NetworkInfo.Evm {...Networks['shimmer']} />

### Additional Info

<NetworkInfo.EvmCustom {...Networks['shimmer']}/>

## ShimmerEVM Testnet

<AddToMetaMaskButton {...Networks['shimmer_testnet']} />
Expand All @@ -65,8 +132,12 @@ The other values (network name and currency symbol) can be whatever value you li

:::

### Additional Info

<NetworkInfo.EvmCustom {...Networks['shimmer_testnet']}/>

## Core Contracts

[ShimmerEVM](#shimmerEVM) and the testnet networks have 7
[IOTA EVM](#IOTAEVM), [ShimmerEVM](#shimmerEVM) and the testnet networks have 7
[core contracts](../reference/core-contracts/overview.md) deployed, as well as the
[Magic Contract](../reference/magic-contract/introduction.md).
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
description: This guide will help you quickly get started with the [Public Testnet](/build/networks-endpoints/#public-testnet)
description: This guide will help you quickly get started with the EVM Testnets
image: /img/logo/WASP_logo_dark.png
tags:
- quickstart
Expand Down Expand Up @@ -71,7 +71,7 @@ The simulated bridged tokens are currently only available on the ShimmerEVM Test

You can now use your testnet tokens and simulated bridged tokens to deploy and interact with smart contracts on the testnets. Utilize popular development tools and frameworks, such as [Hardhat](https://hardhat.org/), or [Remix](https://remix.ethereum.org/), to build, test, and deploy your smart contracts.

## Explore the Public Testnet
## Explore the EVM Testnet

Visit the corresponding Testnet Block Explorer to monitor the chain, track transactions, and explore deployed smart contracts.

Expand Down
9 changes: 7 additions & 2 deletions docs/build/isc/v1.0.0-rc.6/docs/getting-started/tools.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ directly with an IOTA Smart Contracts chain running EVM as long as you take a co

1. Please make sure you use the correct JSON-RPC endpoint URL in your tooling for your chain. If you're running your own chain, you can find the JSON-RPC
endpoint URL in the Wasp dashboard (`[URL]/wasp/dashboard` when using `node-docker-setup`).
2. Please ensure you use the correct `Chain ID` configured while starting the JSON-RPC service. If you did not explicitly define this while starting the service, the default Chain ID will be <ChainId url='https://json-rpc.evm.shimmer.network'/>
2. Please ensure you use the correct `Chain ID` configured while starting the JSON-RPC service. If you did not explicitly define this while starting the service, the default Chain ID will be <ChainId url='https://json-rpc.evm.iotaledger.net'/>
for IOTA EVM, <ChainId url='https://json-rpc.evm.shimmer.network'/>
for ShimmerEVM or <ChainId url='https://json-rpc.evm.testnet.shimmer.network' /> for the EVM Testnet.
3. Fees are handled on the IOTA Smart Contracts chain level, not the EVM level. The chain will reject any requests with a different gas price than specified by the chain.

Expand All @@ -55,7 +56,11 @@ To use your EVM chain with MetaMask, simply open up MetaMask and click on the ne
the bottom of this list, you will see the option `Add network`. On the new page you will see a list of popular network with the option `Add a network manually`.
For example this would be the configs to add our different [EVM chains](/build/networks-endpoints):

<Tabs groupId='network'>
<Tabs>
<TabItem value='iotaEVM' label='IOTA EVM'>
<AddToMetaMaskButton {...Networks['iota']}/>
<NetworkInfo.Evm {...Networks['iota']}/>
</TabItem>
<TabItem value='iotaEVMTestnet' label='IOTA EVM Testnet'>
<AddToMetaMaskButton {...Networks['iota_testnet']}/>
<NetworkInfo.Evm {...Networks['iota_testnet']}/>
Expand Down
5 changes: 3 additions & 2 deletions docs/build/isc/v1.0.0-rc.6/docs/how-tos/ERC20.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,9 @@ Once you have deployed your contract, you can add your new custom token to your

1. Open Metamask, and click on the transaction that created the contract. From there, you can simply click
on `View on block explorer` to visit the transaction details. Alternatively, you can copy the transaction ID and
visit the [ShimmerEVM Explorer](https://explorer.evm.testnet.shimmer.network/)
or [ShimmerEVM Testnet Explorer](https://explorer.evm.testnet.shimmer.network/) and use the search bar to find transaction.
visit the [IOTA EVM Explorer](https://explorer.evm.iota.org),
[ShimmerEVM Explorer](https://explorer.evm.testnet.shimmer.network/)
or [EVM Testnet Explorer](https://explorer.evm.testnet.shimmer.network/) and use the search bar to find transaction.

!['View on block explorer](/img/evm/how-tos/ERC20/metamask-get-transaction-or-go-to-block-explorer.png)

Expand Down
18 changes: 10 additions & 8 deletions docs/build/isc/v1.0.0-rc.6/docs/how-tos/ERC721.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ your smart contracts.

## Create the Smart Contract

The following is an example NFT Smart Contract called "ShimmerEVMSampleNFT".
The following is an example NFT Smart Contract called "IotaEVMSampleNFT".

```solidity
// SPDX-License-Identifier: MIT
Expand All @@ -51,11 +51,11 @@ pragma solidity ^0.8.20;
import "@openzeppelin/[email protected]/token/ERC721/ERC721.sol";
import "@openzeppelin/[email protected]/access/Ownable.sol";

contract ShimmerEVMSampleNFT is ERC721, Ownable {
contract IotaEVMSampleNFT is ERC721, Ownable {
uint256 private _nextTokenId;

constructor(address initialOwner)
ERC721("ShimmerEVMSampleNFT", "SSNFT")
ERC721("IotaEVMSampleNFT", "SSNFT")
Ownable(initialOwner)
{}

Expand All @@ -73,9 +73,9 @@ contract ShimmerEVMSampleNFT is ERC721, Ownable {
As you can see above, the contract uses standard methods for the most part. You should pay attention to the following:

- `pragma solidity ^0.8.20;`: This line means the contract uses solidity compiler version `0.8.20` or above.
- `contract ShimmerEVMSampleNFT is ERC721, ERC721URIStorage, Ownable`: This line defines the contract's name, and what
- `contract IotaEVMSampleNFT is ERC721, ERC721URIStorage, Ownable`: This line defines the contract's name, and what
other contracts it implements.
- `ERC721("ShimmerEVMSampleNFT", "SNFT") {}`: This line defines the token name and symbol. You can name it
- `ERC721("IotaEVMSampleNFT", "SNFT") {}`: This line defines the token name and symbol. You can name it
whatever you want. We recommend using the same name for the token and the contract.
- `return "https://example.com/nft/";`: You should define the base URI of your NFTs. That means the URL you provide here
will be used for all your tokens. Since this contract uses auto-incremental token IDs, your token URI will look
Expand All @@ -101,7 +101,7 @@ directly.

:::note Set the Initial Owner

Before you can deploy this contract, you will need to set the `Initial Owner` address; this can be your own ShimmerEVM address.
Before you can deploy this contract, you will need to set the `Initial Owner` address; this can be your own IOTA EVM address.

!["Set the initial owner" img.png](/img/evm/how-tos/ERC721/set-initial-owner.png)

Expand All @@ -115,13 +115,15 @@ So far, you have [created](#create-the-smart-contract) and deployed the contract
To do, you should:

1. Open the contract (listed under `Deployed Contracts`).
2. Insert your target ShimmerEVM in beside the `safeMint` button and then click the button.
2. Insert your target IOTA EVM in beside the `safeMint` button and then click the button.

![Safe mint](/img/evm/how-tos/ERC721/safe-mint.png)

3. Confirm the transaction on Metamask.

![Confirm in metamask](/img/evm/how-tos/ERC721/confirm-in-metamask.png)

If you visit your address in the [ShimmerEVM Explorer](https://explorer.evm.testnet.shimmer.network/) or [ShimmerEVM Testnet Explorer](https://explorer.evm.testnet.shimmer.network/)
If you visit your address in the visit the [IOTA EVM Explorer](https://explorer.evm.iota.org),
[ShimmerEVM Explorer](https://explorer.evm.testnet.shimmer.network/) or [EVM Testnet Explorer](https://explorer.evm.testnet.shimmer.network/)
you should see your NFTs listed under `Tokens`.

Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import AboutAccounts from '../../../_admonitions/_about-accounts.md';

:::info

ShimmerEVM has 18 decimal places, while Shimmer has 6. This means that any decimals beyond the 6th will be ignored by Shimmer, even though you can see them on ShimmerEVM. Please keep this in mind while sending your tokens to L1.
IOTA EVM and ShimmerEVM have 18 decimal places, while IOTA and Shimmer have 6. This means that any decimals beyond the 6th will be ignored by IOTA and Shimmer, even though you can see them on IOTA EVM and ShimmerEVM. Please keep this in mind while sending your tokens to L1.

:::

Expand Down
Loading
Loading