diff --git a/docs/developers/build/_category_.json b/docs/developers/build/_category_.json new file mode 100644 index 000000000..9a5f049da --- /dev/null +++ b/docs/developers/build/_category_.json @@ -0,0 +1,8 @@ +{ + "label": "Build", + "position": 2, + "collapsed": false, + "link": { + "type": "generated-index" + } +} diff --git a/docs/developers/build/configuring-flint-for-devs.mdx b/docs/developers/build/configuring-flint-for-devs.mdx new file mode 100644 index 000000000..f0cdb0f63 --- /dev/null +++ b/docs/developers/build/configuring-flint-for-devs.mdx @@ -0,0 +1,28 @@ +--- +sidebar_label: "Configuring Flint Wallet" +sidebar_position: 1 +--- + +import puzzleIcon from "@site/static/img/puzzle-icon.png"; + +# Configuring Flint Wallet + +Flint Wallet is a Chrome extension that serves as a go-to light wallet for DeFi and NFTs. The current version of Flint allows users to create a Cardano Testnet wallet and enable "Milkomeda mode" to send transactions to the Milkomeda C1 sidechain. + +Install Flint Wallet by visiting the following link while using Chrome browser and clicking the “Add to Chrome” button: [Install Flint Wallet](https://chrome.google.com/webstore/detail/flint/hnhobjmcibchnmglfbldbfabcgaknlkj)​ + +After installing, click the Extensions icon at the top right of the Chrome window and select **Flint Wallet**. Within the Flint window, proceed past the initial warning screen, click “**Let’s Begin**”, choose your language, click “**I agree**”, and when you arrive at the screen shown below, click the “**Testnet**” button. + +:::info +To use real ADA on the mainnet version of Milkomeda C1, click "Mainnet" to create a mainnet Cardano wallet instead. +::: + +![Select tesnet network](/img/flint-select-testnet.png) + +Next, click “**Confirm**”, “**Create a new wallet**”, and write down a copy of your recovery phrase. + +Confirm the recovery phrase at the next screen, set a wallet password, and click “**Create my wallet**”. For now you can select “**Skip**” at the App Passcode screen, and then click “**Finish**”. You should now have a Cardano Testnet wallet, as shown: + +![Flint home screen](/img/flint-home-screen.png) + +Next, we will access the Cardano Testnet faucet to obtain some test ADA. diff --git a/docs/developers/build/frameworks/_category_.json b/docs/developers/build/frameworks/_category_.json new file mode 100644 index 000000000..d75116efc --- /dev/null +++ b/docs/developers/build/frameworks/_category_.json @@ -0,0 +1,7 @@ +{ + "label": "Development Frameworks", + "position": 1, + "link": { + "type": "generated-index" + } +} diff --git a/docs/developers/build/frameworks/apeworx.mdx b/docs/developers/build/frameworks/apeworx.mdx new file mode 100644 index 000000000..6ea9c4f0d --- /dev/null +++ b/docs/developers/build/frameworks/apeworx.mdx @@ -0,0 +1,62 @@ + +# ApeworX + +Plugins are core to ApeworX’s architecture and to add a new network, it has to be bundled into a plugin. Luckily, dcspark has developed a plugin (ape-milkomeda) to allow Apeworx to connect to A1 and C1, mainnet and testnet. + +Download is available at… + +Steps +Install the ape-milkomeda plugin to have the milkomeda chains available in the ApeworX network list. + +Either download the repo and install from source: + +``` +git glone https://github.com/dcspark/ape-milkomeda +cd ape-milkomeda +pip install . +``` + +or install from the pypi repository (I have finished plugin but it’s only on my pc): + +``` +pip install ape-milkomeda +``` + + +Initialize an ape project in an empty folder: + +``` +ape init +``` + +Copy the WinnerDraw.sol to the contracts folder. +Compile the contract: + +``` +ape compile +``` + +Import your account to ApeworX account list: + +``` +ape accounts import +``` + +(you will be prompted for the private key and a passphrase to encrypt it) + + +Create a file names deploy.py in the scripts folder: + +``` +from ape import project, accounts + +def main(): + signer = accounts.load('test') + winnerDraw = signer.deploy(project.WinnerDraw) +``` + +Run the deployment script on C1 testnet: + +``` +ape run deploy --network milkomeda:c1-testnet +``` diff --git a/docs/developers/build/frameworks/brownie.mdx b/docs/developers/build/frameworks/brownie.mdx new file mode 100644 index 000000000..cb12004db --- /dev/null +++ b/docs/developers/build/frameworks/brownie.mdx @@ -0,0 +1,56 @@ +# Brownie + +Brownie is currently in maintenance mode and ApeworX should be it’s successor, but in any case we will lease here the steps to set it up. + +Steps +Initialize a brownie project in an empty folder: + +``` +brownie init +``` + +Copy the WinnerDraw.sol to the contracts folder. +Compile the contract: + +``` +brownie compile +``` + +Add the Milkomeda C1 testnet list of networks in brownie: + +``` +brownie networks add Milkomeda milkomeda-cardano-testnet chainid=200101 explorer=https://explorer-devnet-cardano-evm.c1.milkomeda.com host=https://rpc-devnet-cardano-evm.c1.milkomeda.com name="Milkomeda C1 Testnet" +``` + + +Create a file named brownie-config.yml in the root of the project with the following content: + +``` +dotenv: .env +wallets: + - dummy: ${PRIVATE_KEY} +``` + +Create a file named .env with the private key of the funded account: + +``` +PRIVATE_KEY= +``` + + +Create a file named deploy.py in the scripts folder: + +``` +from brownie import WinnerDraw, accounts, config + +def main(): + signer = accounts.add(config['wallets'][0]['dummy']) + WinnerDraw.deploy({"from": signer}) +``` + + +Run the deployment script on C1 testnet: + +``` +brownie run scripts/deploy.py --network milkomeda-cardano-testnet +``` \ No newline at end of file diff --git a/docs/developers/build/frameworks/forge.mdx b/docs/developers/build/frameworks/forge.mdx new file mode 100644 index 000000000..4de13e5ef --- /dev/null +++ b/docs/developers/build/frameworks/forge.mdx @@ -0,0 +1,29 @@ +# Forge + +Initialize an ape project in an empty folder: + +```bash +forge init . +``` + + +Compile the contract: + +```bash +forge build +``` + +Create a file named .env with the private key of the funded account: + +``` +PRIVATE_KEY= +``` + +Run the deployment script on C1 testnet: + +```bash +source .env +forge create --legacy --rpc-url https://rpc-devnet-cardano-evm.c1.milkomeda.com --private-key $PRIVATE_KEY src/WinnerDraw.sol:WinnerDraw +``` + +(Notice the -–legacy is necessary since milkomeda chains have not yet implemented EIP-1559) diff --git a/docs/developers/build/frameworks/hardhat.mdx b/docs/developers/build/frameworks/hardhat.mdx new file mode 100644 index 000000000..6724b106f --- /dev/null +++ b/docs/developers/build/frameworks/hardhat.mdx @@ -0,0 +1,92 @@ +--- +sidebar_position: 1 +description: This description will override the default. +--- + + +# Hardhat + +Initialize a Hardhat project in an empty folder: + +```bash +yarn init +yarn add --dev hardhat +npx hardhat +``` + + +Create a contract in the contracts folder + +Compile the contract: + +```bash +npx hardhat compile +``` + + +Edit hardhat.config.js to add the desired Milkomeda chain and your funded test account: + + +import Tabs from '@theme/Tabs'; +import TabItem from '@theme/TabItem'; + + + + +``` +require("@nomicfoundation/hardhat-toolbox"); + +const TESTNET_API_KEY = ""; + +/** @type import('hardhat/config').HardhatUserConfig */ +module.exports = { + solidity: "0.8.17", + networks: { + c1_testnet: { + url: `https://rpc-devnet-cardano-evm.c1.milkomeda.com`, + accounts: [TESTNET_API_KEY] + } + } +}; +``` + + + + + This is a banana 🍌 + + + This is an orange 🍊 + + + This is a banana 🍌 + + + + + + + +Create a file named deploy.js in the scripts folder: + +``` +const hre = require("hardhat"); + +async function main() { + const WinnerDraw = await hre.ethers.getContractFactory("WinnerDraw"); + const winnerDraw = await WinnerDraw.deploy(); + await winnerDraw.deployed(); + console.log(`WinnerDraw contract deployed to ${winnerDraw.address}`); +} + +main().catch((error) => { + console.error(error); + process.exitCode = 1; +}); +``` + +Run the deployment script on C1 testnet: + +``` +npx hardhat run scripts/deploy.js --network c1_testnet +``` diff --git a/docs/developers/build/frameworks/truffle.mdx b/docs/developers/build/frameworks/truffle.mdx new file mode 100644 index 000000000..e0b5b7150 --- /dev/null +++ b/docs/developers/build/frameworks/truffle.mdx @@ -0,0 +1,4 @@ + +# Truffle + +... \ No newline at end of file diff --git a/docs/developers/build/obtaining-test-ada.mdx b/docs/developers/build/obtaining-test-ada.mdx new file mode 100644 index 000000000..8c8768bd2 --- /dev/null +++ b/docs/developers/build/obtaining-test-ada.mdx @@ -0,0 +1,32 @@ +--- +sidebar_label: "Obtaining Test ADA" +sidebar_position: 2 +--- + +# Obtaining Test ADA + +Now we’re ready to get some test ADA from the Cardano testnet faucet. + +:::info + +If you will be using real ADA on the mainnet version of Milkomeda C1, skip this step and proceed to the [next page](./configuring-metamask-for-devs) + +::: + +Within the Flint Wallet window, click "**Receive**". At the Receive window, click "**Copy Address**" to copy your Cardano Testnet wallet address to the clipboard, and then click "**Testnet faucet (tADA)**" at the bottom of the screen, as shown. + +![](/img/flint-copy-tada-receive-address.png)​ + +This will take you to the following link: [Cardano Testnet Faucet](https://testnets.cardano.org/en/testnets/cardano/tools/faucet/)​ + +Here, select "tAda" from the dropdown menu and paste your Cardano testnet wallet address into the "Address" field. You can leave the "API Key" field blank. + +![](/img/cardano-testnet-faucet.png) + +Complete the Captcha and click "**Request funds**". + +After waiting a few minutes (usually 5 minutes or less), you should be able to see some tADA in your Cardano Testnet wallet. + +![](/img/flint-confirm-tada-balance.png) + +Next we will set up MetaMask and get an address on the Milkomeda C1 sidechain. diff --git a/docs/developers/build/wallet-integration.mdx b/docs/developers/build/wallet-integration.mdx new file mode 100644 index 000000000..dff2cbf9b --- /dev/null +++ b/docs/developers/build/wallet-integration.mdx @@ -0,0 +1,215 @@ +--- +sidebar_label: "Wallet Integration" +sidebar_position: 7 +--- + +import Tabs from "@theme/Tabs"; +import TabItem from "@theme/TabItem"; + +# Wallet integration + +Learn how to integrate your web3 wallet or other dApp with Milkomeda + +## Start building the future of decentralized finances + +The following article helps to get to know the _**milkomeda-js-sdk package**_ allowing developers to integrate web3 wallet on Milkomeda Sidechain. + +## Integrate Wallet with Milkomeda protocol + +**1. Download _milkomeda-js-sdk package_** + +Here you can find the [milkomeda-js-sdk package](https://www.npmjs.com/package/@dcspark/milkomeda-js-sdk). This is a package that hosts static configurations of Milkomeda deployments. + +:::info + +This is useful to avoid having each project integrate Milkomeda hard-coding static configurations. + +::: + +**2. Install _milkomeda-js-sdk_ package** + +To install the package using **npm**: + +```shell +npm i @dcspark/milkomeda-js-sdk +``` + +To install the package using **yarn**: + +```shell +yarn add @dcspark/milkomeda-js-sdk +``` + +**3. Import the package into your project** + +Using **import:** + +```js +import { generateMilkomedaMetadata, milkomedaNetworks } from "@dcspark/milkomeda-js-sdk"; +``` + +Using **require:** + +```js +const milkomedaJsSdk = require("@dcspark/milkomeda-js-sdk"); +``` + +## Learn more about _milkomeda-js-sdk_ package + +_Milkomeda-js-sdk_ is a package that hosts static configurations of Milkomeda deployments. This is useful to avoid having each project integrate Milkomeda hard-coding static configurations. + +| Parameter | Description | +| -------------------------- | ------------------------------------------------------------------------------------------------------------------- | +| _isMainnet_ | boolean informing if the specific network configuration is mainnet (e.g. Cardano) or not, | +| _mainchain_ | consists of mainchain information such as protocol and its id, | +| _sidechain_ | consists of sidechain information such as protocol name (e.g. MilkomedaC1) and sidechain id, | +| _backendEndpoint_ | provides URL value for the service, which exposes additional information about a specific version of the sidechain, | +| _protocolMagic_ | introduces protocol magic compatible with appropriate Milkomeda network, | +| _timeIntervalForAddressMs_ | a time interval of a possible address change defined in milliseconds, | +| _sidechainContract_ | address of the sidechain contract to which any client can connect. | + +#### Example of the exposed payload + +Below you can find an example of the exposed payload of one of the Milkomeda Networks (devnet) + +```json +{ + [NETWORK_NAME]: { + isMainnet: false, + name: NETWORK_NAME, + mainchain: { + protocol: ProtocolNames.cardanoProtocol, + id: toChainId({ + networkId: registry.Testnet.NetworkId, + networkMagic: registry.Testnet.NetworkMagic + }) + }, + sidechain: { protocol: ProtocolNames.evmProtocol, id: 200101 }, + backendEndpoint: BackendEndpoints.devnet, + protocolMagic: ProtocolMagic.devnet, + timeIntervalForAddressMs: 86400000, + sidechainContract: "0x000000000000000000000000000000000000BbBB" + }, +} +``` + +Additionally, the package introduces helper types and a function that helps to create proper metadata for Milkomeda transactions. + +```shell +# Milkomeda metadata generator +generateMilkomedaMetadata( + address, # address is EVM address + protocolMagic # protocol magic for specific network +) +``` + +The metadata of a transaction consists of two parameters - **protocol magic & EVM address**. Exemplary metadata for **testnet** transaction is as follows: + +```json +{ + 87: "devnet.cardano-evm.c1" + 88: "0xEVM_TESTNET_ADDRESS" +} +``` + +#### Example of generating Milkomeda metadata for transaction + +```js +generateMilkomedaMetadata("0x000…", milkomedaNetworks["c1-devnet"].protocolMagic); +``` + +:::info +Remember to replace "0x000..." with your EVM address +::: + +### Milkomeda REST API + +Except for the _Milkomeda-js-sdk_ package, we have introduced a REST API that allows to fetch more data regarding the Milkomeda Sidechain itself. + +:::info +In this example, we use the Flint Wallet integration example for a better explanation +::: + +Base url for REST API is given as the **backendEndpoint** parameter using _milkomeda-js-sdk_. You can take it out from the package using the following code: + + + + +``` +milkomedaNetworks["c1-devnet"].backendEndpoint +``` + +:::info +Result: [https://allowlist.flint-wallet.com](https://allowlist.flint-wallet.com) +::: + +When you have the base URL included in your code, you can use one of the following endpoint: + +- **Stargate address** ([V1/stargate](https://allowlist.flint-wallet.com/v1/stargate)) + + + + + +``` +milkomedaNetworks["c1-mainnet"].backendEndpoint +``` + +:::info +Result: [https://allowlist-mainnet.flint-wallet.com](https://allowlist-mainnet.flint-wallet.com) + +If you want to integrate your Wallet with Milkomeda Mainnet, you need to use another 2 endpoints, to get EVM addresses allowed on the network. The purpose of this [microservice](https://github.com/dcSpark/allowedlist-service/) is to provide a list of addresses that are allowed to use the bridge in Milkomeda. +::: + +When you have the base URL included in your code, you can use one of the following endpoints: + +- **Stargate address** ([/V1/stargate](https://allowlist-mainnet.flint-wallet.com/v1/stargate)) +- **fullAllowedList** ([/v1/fullAllowedList](https://allowlist-mainnet.flint-wallet.com/v1/fullAllowedList)) + +Returns array of EVM addresses allowed in the mainnet + +```json +{ + "allowList": ["0x...", "0x..."] +} +``` + +- **isAddress=0x** ([/v1/isAddressAllowed?address=0x](https://allowlist-mainnet.flint-wallet.com/v1/isAddressAllowed?address=0x)) + +Returns a boolean value, which informs if the provided address is allowed on the restricted mainnet or not. + + + + + +Using Milkomeda REST API stargate endpoint you can get the same properties of the payload for both devnet and mainnet. Below you can find an example payload for devnet: + +```json +{ + "current_address": "addr_test1wz6lvjg3anml96vl22mls5vae3x2cgaqwy2ewp5gj3fcxdcw652wz", + "ttl_expiry": 1646438400000, + "ada": { + "minLovelace": "3000000", + "fromADAFeeLovelace": "500000", + "toADAFeeGWei": "500000" + }, + "assets": [ + { + "idCardano": "b4004c2f3edfdd2016d0fead9b927064f345534b000000000000000000000000", + "idMilkomeda": "9c223e1dAf6184672E982d9AA560D9FD1d09A01B", + "minCNTInt": "1", + "minGWei": "1000000000" + } + … + ] +} +``` + +#### If you have any additional questions regarding this article and Milkomeda integration go to [https://www.milkomeda.com/support](https://www.milkomeda.com/support) or visit our [discord server](https://discord.gg/4GSwPJpF) and don’t hesitate to ask us. diff --git a/docs/developers/build/wrapping-assets-for-devs.mdx b/docs/developers/build/wrapping-assets-for-devs.mdx new file mode 100644 index 000000000..1609f2403 --- /dev/null +++ b/docs/developers/build/wrapping-assets-for-devs.mdx @@ -0,0 +1,45 @@ +--- +sidebar_label: "Wrapping Assets" +sidebar_position: 4 +--- + +# Wrapping Assets + +Open the Flint Wallet window and click "**Send**". At the next screen, enable the "**Milkomeda mode**" toggle, paste your Milkomeda C1 wallet address into the "**Milkomeda Ethereum Address**" field, and enter the amount to send (300 Test ADA in this example). Click "**Continue**". + +![](/img/flint-wrap-tada.png) + +At the confirmation screen, enter your wallet password and click "**Send**". + +![](/img/flint-wrap-tada-confirm.png) + +The transfer will require 10 confirmations, which should take approximately **5** minutes. Once the transaction is confirmed, the transferred MilkTADA should be visible in your Milkomeda Cardano Testnet wallet in MetaMask. + +:::info A note on transaction fees + +For transactions that take place solely on the Milkomeda C1 sidechain, you only pay the standard Milkomeda network transaction fee set by the block producers. + +However, transactions that involve wrapping, i.e., moving assets between Cardano and the Milkomeda C1 sidechain, require payment of transactions fees for both Cardano and Milkomeda since one transaction is required on each chain. + +For example, sending assets from Cardano to Milkomeda C1 requires one transaction on Cardano to lock your assets and another transaction on Milkomeda C1 to issue the wrapped assets to you. + +When sending a transaction of this type in Flint Wallet, you can expand the "Network Fee" item to see a "Base Fee" (i.e., the Cardano transaction fee) and a "Milkomeda Fee". Note that the "Milkomeda Fee" for these transactions will be slightly higher than the standard transaction fee on Milkomeda since you are also paying the block producers for their role in wrapping your assets. + +::: + +Now that we have successfully wrapped Test ADA into MilkTADA for use on the Milkomeda Cardano Testnet sidechain, the next step is to deploy a sample smart contract. + +:::caution MilkTADA and Wrapped Test ADA + +As we have seen, MilkTADA is the base asset used for paying fees and gas on the Milkomeda Cardano Testnet sidechain. When you move Test ADA to Milkomeda, you receive MilkTADA. + +"Wrapped Test ADA" (wTADA) is a separate ERC20 token that functions the same as WETH on Ethereum. + +The contract address for wTADA can be found below. Note that although you can send milkTADA to this address to wrap it, you **shouldn't** send wTADA to this address to unwrap it but rather interact with it using the right method in the smart-contract. wTADA contract address: 0x65a51E52eCD17B641f8F0D1d56a6c9738951FDC9 + +If using the Cardano mainnet, find the wADA contract address below. + +**Do not directly** send wADA to this address. For now, you will need to use a DEX to unwrap wADA (or interact directly with the smart contract). + +wADA contract address: 0xAE83571000aF4499798d1e3b0fA0070EB3A3E3F9 +::: diff --git a/docs/developers/get_started/_category_.json b/docs/developers/get_started/_category_.json new file mode 100644 index 000000000..8062f600e --- /dev/null +++ b/docs/developers/get_started/_category_.json @@ -0,0 +1,8 @@ +{ + "label": "Get Started", + "position": 1, + "link": { + "type": "generated-index", + "description": "Here are the articles in this section:" + } +} diff --git a/docs/developers/get_started/evm_explorer.mdx b/docs/developers/get_started/evm_explorer.mdx new file mode 100644 index 000000000..8c0e26b3a --- /dev/null +++ b/docs/developers/get_started/evm_explorer.mdx @@ -0,0 +1,7 @@ +--- +sidebar_position: 3 +--- + +# EVM Explorer + +fdsfd \ No newline at end of file diff --git a/docs/developers/get_started/milkomeda_bridge_overview.mdx b/docs/developers/get_started/milkomeda_bridge_overview.mdx new file mode 100644 index 000000000..02defc37c --- /dev/null +++ b/docs/developers/get_started/milkomeda_bridge_overview.mdx @@ -0,0 +1,6 @@ +--- +sidebar_position: 4 +--- + + +# Milkomeda Bridge overview \ No newline at end of file diff --git a/docs/developers/get_started/milkomeda_vs_ethereum.mdx b/docs/developers/get_started/milkomeda_vs_ethereum.mdx new file mode 100644 index 000000000..16626fdac --- /dev/null +++ b/docs/developers/get_started/milkomeda_vs_ethereum.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 2 +--- + +# Milkomeda vs Ethereum diff --git a/docs/developers/get_started/networks.mdx b/docs/developers/get_started/networks.mdx new file mode 100644 index 000000000..5bcdf134a --- /dev/null +++ b/docs/developers/get_started/networks.mdx @@ -0,0 +1,7 @@ +--- +sidebar_position: 1 +--- + +# Networks + +fdsfd \ No newline at end of file diff --git a/docs/developers/get_started/permissionless_bridge.mdx b/docs/developers/get_started/permissionless_bridge.mdx new file mode 100644 index 000000000..3fc4e6692 --- /dev/null +++ b/docs/developers/get_started/permissionless_bridge.mdx @@ -0,0 +1,6 @@ +--- +sidebar_position: 6 +--- + + +# Milkomeda Permissionless Bridge \ No newline at end of file diff --git a/docs/developers/get_started/public_endpoints.mdx b/docs/developers/get_started/public_endpoints.mdx new file mode 100644 index 000000000..a60ef588b --- /dev/null +++ b/docs/developers/get_started/public_endpoints.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 5 +--- + +# Public Endpoints \ No newline at end of file diff --git a/docs/programs/grants.mdx b/docs/programs/grants.mdx new file mode 100644 index 000000000..a344af6be --- /dev/null +++ b/docs/programs/grants.mdx @@ -0,0 +1,5 @@ +# Grant Proposals + +Milkomeda delivers rollup technologies to leading Layer 1 ecosystems by offering the most popular smart contracting language, Solidity, while enhancing inter-blockchain interoperability, user experience, and developer traction all at the Layer 2 level. + +sdassfa \ No newline at end of file diff --git a/docs/programs/hackathons.mdx b/docs/programs/hackathons.mdx new file mode 100644 index 000000000..9f38e5ee0 --- /dev/null +++ b/docs/programs/hackathons.mdx @@ -0,0 +1,3 @@ +# Hackathons + +... \ No newline at end of file diff --git a/docs/programs/incubator.mdx b/docs/programs/incubator.mdx new file mode 100644 index 000000000..5b1e8a541 --- /dev/null +++ b/docs/programs/incubator.mdx @@ -0,0 +1,3 @@ +# Incubator + +... \ No newline at end of file diff --git a/docs/use_milkomeda/cardano-bridge-supported-native-assets.mdx b/docs/use_milkomeda/cardano-bridge-supported-native-assets.mdx new file mode 100644 index 000000000..6df365385 --- /dev/null +++ b/docs/use_milkomeda/cardano-bridge-supported-native-assets.mdx @@ -0,0 +1,43 @@ +--- +title: "Cardano Bridge Supported Native Assets" +sidebar_position: 5 +--- + +import nativeAssetUnwrapping from "@site/static/img/select-asset-unwrapping.png"; + +# Cardano Bridge Supported Native Assets + +This section presents all native tokens supported by the Milkomeda Bridge to Cardano. To wrap and unwrap any supported native asset follow the _step-by-step_ tutorial presented in [For End Users](./) section by replacing `milkADA` with any token from the table below. + +:::info +Please, remember that the specific native asset must be added to Milkomeda Token Registry before it can be used in any of the wrapping or unwrapping operations. Hence, the list is finite and allows only for specific native tokens. +::: + +List of supported Milkomeda Native Assets: + +| Token name | Token Ticker | Contract Address Details | Token Type | +| --------------------------------------------------- | ------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------- | +| [GeroWallet](https://gerowallet.io/) | GERO | [0xeA55e366Eb0f4cFAAf8d83dC1fC7286F11b5b1cb](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0xeA55e366Eb0f4cFAAf8d83dC1fC7286F11b5b1cb/transactions) | ERC-20 | +| [Charli3](https://charli3.io/) | C3 | [0xdE482b84360c248C0d7260826a8B06a5A837235d](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0xdE482b84360c248C0d7260826a8B06a5A837235d/transactions) | ERC-20 | +| [CARD.STARTER](https://www.cardstarter.io/) | CARDS | [0xa350679eaFDb5836da9A796fF721a1fd8415c75F](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0xa350679eaFDb5836da9A796fF721a1fd8415c75F/transactions) | ERC-20 | +| [Occam](https://occam.fi/) | OCX | [0xf0c73E6287867bAa4F865A17EE711ec989c78AC0](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0xf0c73E6287867bAa4F865A17EE711ec989c78AC0/transactions) | ERC-20 | +| [IAGON](https://iagon.com/) | IAG | [0x658b95858457549cFC0af513b1b902aB0F6E6946](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x658b95858457549cFC0af513b1b902aB0F6E6946/transactions) | ERC-20 | +| [HOOSKY](https://hosky.io/) | HOOSKY | [0x13fe17701861b769d58f44c2cEBd918886d3D205](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x13fe17701861b769d58f44c2cEBd918886d3D205/transactions) | ERC-20 | +| [MUESLISWAP MILK](https://muesliswap.com/) | MILK | [0x386e685B5cBAa7bC06e3Dd2eEcDC56105076e4Fa](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x386e685B5cBAa7bC06e3Dd2eEcDC56105076e4Fa/transactions) | ERC-20 | +| [World Mobile Token](https://worldmobiletoken.com/) | WMT | [0x4D5C63c07463EFa5bb26EE0A6D8C39dd0e3DaBD9](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x4D5C63c07463EFa5bb26EE0A6D8C39dd0e3DaBD9/transactions) | ERC-20 | +| [Blueshift](https://blueshift.fi/) | BLUES | [0x8c008BBA2Dd56b99f4A6aB276bE3a478cB075F0C](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x8c008BBA2Dd56b99f4A6aB276bE3a478cB075F0C/transactions) | ERC-20 | +| [SundaeSWAP](https://sundaeswap.finance/) | SUNDAE | [0x771cc58a257a458b0A7C74382eA1C4EF856B80a8](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x771cc58a257a458b0A7C74382eA1C4EF856B80a8/transactions) | ERC-20 | +| [WETH(Nomad)](https://app.nomad.xyz/) | WETH | [0x5950F9B6EF36f3127Ea66799e64D0ea1f5fdb9D1](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x5950F9B6EF36f3127Ea66799e64D0ea1f5fdb9D1/transactions) | ERC-20 | +| [WBTC(Nomad)](https://app.nomad.xyz/) | WBTC | [0x48AEB7584BA26D3791f06fBA360dB435B3d7A174](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x48AEB7584BA26D3791f06fBA360dB435B3d7A174/transactions) | ERC-20 | +| [Tether USD(Nomad)](https://app.nomad.xyz/) | USDT | [0xab58DA63DFDd6B97EAaB3C94165Ef6f43d951fb2](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0xab58DA63DFDd6B97EAaB3C94165Ef6f43d951fb2/transactions) | ERC-20 | +| [USD Coin(Nomad)](https://app.nomad.xyz/) | USDC | [0x5a955FDdF055F2dE3281d99718f5f1531744B102](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0x5a955FDdF055F2dE3281d99718f5f1531744B102/transactions) | ERC-20 | +| [Wing Riders Token](https://www.wingriders.com/) | WRT | [0xAA761861322Ca1cB8c0aCEB1471B3B5AF81de5A6](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/address/0xAA761861322Ca1cB8c0aCEB1471B3B5AF81de5A6/transactions) | ERC-20 | + +When using [Milkomeda Cardano Unwrap Bridge](https://cardano-bridge.milkomeda.com/bridge) for _unwrapping_ a specific native asset, select it from the drop-down list as shown below: + +Select native asset for unwrapping + +:::info +After selecting a desired native asset, you can always check its description (e.g. _The utility token powering the +MuesliSwap ecosystem_ when choosing the MILK token) +::: diff --git a/docs/use_milkomeda/configuring-flint-wallet.mdx b/docs/use_milkomeda/configuring-flint-wallet.mdx new file mode 100644 index 000000000..2c5afc2c0 --- /dev/null +++ b/docs/use_milkomeda/configuring-flint-wallet.mdx @@ -0,0 +1,27 @@ +--- +sidebar_position: 1 +--- + +import puzzleIcon from "@site/static/img/puzzle-icon.png"; + +# Configuring Flint Wallet + +Flint Wallet is a Chrome extension that serves as a convenient go-to light wallet for DeFi and NFTs. The current +version of Flint allows users to enable "Milkomeda mode" to send transactions to the Milkomeda C1 sidechain. Install +Flint Wallet by visiting the following link while using Chrome browser and clicking the “Add to Chrome” button: +[Install Flint Wallet](https://chrome.google.com/webstore/detail/flint/hnhobjmcibchnmglfbldbfabcgaknlkj) + +After installing, click the "puzzle piece" icon +at the top right of the Chrome window to access your extensions. Select **Flint**. Within the Flint Wallet window, proceed past the initial warning screen, click “**Let’s Begin**”, choose your language, click “**I agree**”, and when you arrive at the screen shown below, click the “**Mainnet**” button. + +![Pick a network](/img/pick-a-network.png) + +Next, click “**Confirm**”, “**Create a new wallet**”, and write down a copy of your recovery phrase. + +Confirm the recovery phrase at the next screen, set a wallet password, and click “**Create my wallet**”. For now you can select “**Skip**” at the App Passcode screen, and then click “**Finish**”. You should now have a Cardano wallet, as shown: + +![Create flint wallet](/img/create-cardano-wallet.png) + +Note that to proceed further you will need to fund your wallet with some ADA. Refer to the "[Get Help](../../get-help)" section at the end of this document if you require assistance or encounter trouble at this stage. + +Next, we will configure MetaMask to connect to the Milkomeda C1 sidechain. diff --git a/docs/use_milkomeda/configuring-metamask.mdx b/docs/use_milkomeda/configuring-metamask.mdx new file mode 100644 index 000000000..9a7b8f5a3 --- /dev/null +++ b/docs/use_milkomeda/configuring-metamask.mdx @@ -0,0 +1,41 @@ +--- +title: "Configuring Metamask" +sidebar_position: 2 +--- + +import puzzleIcon from "@site/static/img/puzzle-icon.png"; + +# Configuring MetaMask + +The next step is to obtain an address on the Milkomeda C1 sidechain where we can receive our MilkADA. For now, we recommend using MetaMask for this step. + +First, install [MetaMask for Chrome](https://chrome.google.com/webstore/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn). Then, click the Chrome Extensions icon and select MetaMask. Within the MetaMask window, click "**Get Started**" and then "**Create a Wallet**". Set a wallet password and click through the rest of the setup screens. When finished, you should have a new empty wallet as shown below. Select the network dropdown at the top right of the MetaMask screen. + +
+ + ![MetaMask wallet](/img/metamask-wallet.png) + +
+ + +From the dropdown list, select “**Add Network**” and enter the following: + +> Network Name: Milkomeda Cardano (C1) +> +>

New RPC URL: https://rpc-mainnet-cardano-evm.c1.milkomeda.com

+> +> Chain ID: 2001 +> +> Currency Symbol (Optional): MilkADA +> +>

Block Explorer URL (Optional): https://explorer-mainnet-cardano-evm.c1.milkomeda.com

+ +Click “**Save**”, and you should now see "**Milkomeda Cardano (C1)**" in the network dropdown. Copy your C1 wallet address to the clipboard by clicking on the account name, as shown. + +
+ +![Copy Address in MetaMask](/img/copy-address-metamask.png) + +
+ +Now we are ready to return to Flint Wallet and send our ADA to be converted to MilkADA. diff --git a/docs/use_milkomeda/index.mdx b/docs/use_milkomeda/index.mdx new file mode 100644 index 000000000..cb4b1cc02 --- /dev/null +++ b/docs/use_milkomeda/index.mdx @@ -0,0 +1,13 @@ +--- +sidebar_label: "Moving Assets" +sidebar_position: 1 +--- + +import milkomedaBanner from "@site/static/img/milkomeda-banner.png"; + +# Moving Assets + + + +**Milkomeda** is a groundbreaking new protocol that brings EVM capabilities to non-EVM blockchains. As development progresses, Milkomeda will expand to offer L2 solutions (rollups) for several major blockchains including Cardano, Solana, and Algorand. Currently we have an EVM-based sidechain connected to Cardano - Milkomeda C1 and EVM-based Rollup connected to Algorand - Milkomeda A1. + diff --git a/docs/use_milkomeda/obtaining-milkada.mdx b/docs/use_milkomeda/obtaining-milkada.mdx new file mode 100644 index 000000000..8b71b0c8e --- /dev/null +++ b/docs/use_milkomeda/obtaining-milkada.mdx @@ -0,0 +1,38 @@ +--- +title: "Obtaining MilkADA" +sidebar_position: 3 +--- + +# Obtaining MilkADA + +Open the Flint Wallet window and click "**Send**". At the next screen, enable the "**Milkomeda mode**" toggle, paste the Milkomeda C1 wallet address currently in the clipboard into the "**Milkomeda Ethereum Address**" field, and enter the amount to send (1 ADA in this example). Then click "**Continue**". + +![Wrapping ADA in flint wallet](/img/wrapping-send-flint.png) + +At the confirmation screen, enter your wallet password and click "**Send**". + +![Wrapping ADA](/img/wrapping-ada-send.png) + +The transfer will require 10 confirmations, which should take approximately **5** minutes. Once the transaction is confirmed, the transferred MilkADA should be visible in your C1 wallet in MetaMask. + +:::info A note on transaction fees +For transactions that take place solely on the Milkomeda C1 sidechain, you only pay the standard Milkomeda network transaction fee set by the block producers. + +However, transactions that involve wrapping, i.e., moving assets between Cardano and the Milkomeda C1 sidechain, require payment of transactions fees for both Cardano and Milkomeda since one transaction is required on each chain. + +For example, sending assets from Cardano to Milkomeda C1 requires one transaction on Cardano to lock your assets and another transaction on Milkomeda C1 to issue the wrapped assets to you. + +When sending a transaction of this type in Flint Wallet, you can expand the "Network Fee" item to see a "Base Fee" (i.e., the Cardano transaction fee) and a "Milkomeda Fee". Note that the "Milkomeda Fee" for these transactions will be slightly higher than the standard transaction fee on Milkomeda since you are also paying the block producers for their role in wrapping your assets. +::: + +Now you have successfully wrapped your ADA into MilkADA for use on the Milkomeda C1 sidechain. + +:::caution About "MilkADA" vs. "Wrapped ADA"' +MilkADA is the base asset on the Milkomeda C1 sidechain. When you move ADA to Milkomeda, you receive MilkADA. + +Apart from MilkADA, there is another token called "Wrapped ADA" or WADA. Wrapped ADA is an ERC20 token that functions the same as WETH on Ethereum. Be careful not to get these confused! +::: + +:::info +To check the available list of tokens that can be wrapped, go to [**Cardano Bridge Supported Native Assets**](./cardano-bridge-supported-native-assets) section. +::: diff --git a/docs/use_milkomeda/unwrapping-assets.mdx b/docs/use_milkomeda/unwrapping-assets.mdx new file mode 100644 index 000000000..4235debdf --- /dev/null +++ b/docs/use_milkomeda/unwrapping-assets.mdx @@ -0,0 +1,106 @@ +--- +title: "Unwrapping Assets" +sidebar_position: 4 +--- + +import tokenSelection from "@site/static/img/token-selection.png"; +import blockchainConfirmation from "@site/static/img/blockchain-confirmation.png"; +import addressBar from "@site/static/img/address-bar-link.png"; +import searchBox from "@site/static/img/search-box-blockscout.png"; + +# Unwrapping Assets +When it comes to unwrapping assets in the Milkomeda Cardano Sidechain (C1) ecosystem, there are two main options: using the [Flint Wallet](https://flint-wallet.com/) or the [Milkomeda Cardano Unwrap Bridge](https://cardano-bridge.milkomeda.com/bridge). In this tutorial, we'll guide you through both options so you can choose the one that works best for you. + +## Flint Wallet +To perform the asset unwrapping, use the **SEND** function on the wallet screen. + +![Flint Homescreen](/img/flint-home-screen.png) + +To begin, toggle on the **Milkomeda Mode (Beta)** and choose Milkomeda C1 asset from the token select dropdown. Next, input the recipient's Cardano address in the designated box, followed by the desired amount. Lastly, click on the **CONTINUE** button to proceed to the confirmation screen. + +![Flint Input](/img/unwrappingflintinput.png) + +The confirmation screen provides an opportunity to review critical details, including the "from" and "to" addresses, as well as the network fee. It's worth noting that the total fee comprises both the base fee and Milkomeda fee since the transaction occurs on both the Milkomeda C1 chain and Cardano. Take a moment to double-check the information before proceeding. + +![Confirm Transaction](/img/unwrapping-confirm-transaction.png) + +After entering the wallet spending password and pressing the **SEND** button, the transaction(s) will be sent. + + +![Transaction Submitted](/img/unwrapping-transaction-submitted.png) + +If you need more information, there are two ways to access it. You can follow the link on the confirmation screen to view the transaction on Blockscount explorer or navigate to the "Activity" section in the footer to find the transaction on the list. Clicking on the transaction will provide two links, one for viewing the transaction on the Milkomeda chain explorer and the other for Cardano. + + +![Transaction List](/img/unwrapping-transaction-list.png) + + +## Milkomeda Cardano Unwrap Bridge + +To move assets from Milkomeda C1 sidechain back to Cardano, you can also use the Milkomeda Cardano Unwrap Bridge. Follow the steps below to unwrap milkADA and receive ADA in your Cardano mainnet wallet. + +First, access the [Milkomeda Cardano Unwrap Bridge](https://cardano-bridge.milkomeda.com/bridge) and connect your MetaMask wallet. + +![Connect metamask](/img/connect-metamask.png) + +![Connect Wallet](/img/connect-wallet.png) + +_Click_ "Next" + +![Connect Milkomeda network](/img/connect-milkomeda.png) + +_Connect to the Milkomeda C1 Sidechain_ + +:::caution +Remember to select the appropriate network in your wallet.
+Only connect with sites you trust. Make sure the website URL is as follows: https://cardano-bridge.milkomeda.com +::: + +Next, enter the amount of milkADA to unwrap or click the arrow to select a different asset to unwrap, and paste your Cardano wallet address in the "To" field. Then, click the "Next Step" button. + + + +Sign the transaction for unwrapping the assets in MetaMask by clicking "Confirm". + +![Confirm Metamask](/img/confirm-metamask.png) + +Next, wait for blockchain confirmation. + +Blockchain confirmation + +:::info + +You can check the transaction details in [Cardanoscan](https://cardanoscan.io) explorer for more information. + +::: + +At this stage, the address bar of your browser will contain some information about the unwrapping transaction. An example is shown in the figure below. + +Address bar link + +The meaning of each of these elements in the address bar is as follows: + +- The EVM unwrapping transaction ID +- The unwrapped token amount +- The name of the token being unwrapped + +To look up more detailed information about the unwrapping transaction, go to [Milkomeda Blockscout explorer](https://explorer-mainnet-cardano-evm.c1.milkomeda.com/) and paste the EVM unwrapping transaction ID into the search box, as shown below. + +Search box in Blockscout + + + Look up the example transaction + + +The unwrapping process is now complete. After waiting for the necessary transaction confirmations, you should see the unwrapped asset in your Cardano Mainnet wallet. + +![Flint transactions page](/img/flint-transactions.png) + +:::info +To check the available list of tokens that can be unwrapped, go to [**Cardano Bridge Supported Native Assets**](https://bridge-explorer.milkomeda.com/cardano-mainnet/tokens) tab in Bridge Explorer. +::: diff --git a/src/pages/home.mdx b/src/pages/home.mdx new file mode 100644 index 000000000..1144e8bb1 --- /dev/null +++ b/src/pages/home.mdx @@ -0,0 +1,9 @@ +--- +title: my hello page title +description: my hello page description +hide_table_of_contents: true +--- + +# Hello + +How are you? \ No newline at end of file