Closed mihaisc closed 3 years ago
To further specify this, in docs:
This is not the doc task, that is done after all the other points are done. There will be another task in the docs for what you described. This is just testing, documenting the results and if needed create a quick user guide.
if there is no external bridge tutorial, create one maybe under the Wallets section https://docs.oceanprotocol.com/tutorials/introduction/
I agree, it's a good place to put a bridge guide.
@trentmc @mihaisc The Matic's bridge is really easy to use and very straightforward in terms of steps. However, since the testing is happening on the Mainnet the transfers (from Ethereum to Matic) requires gas (it was around $17, now it's around $22). I didn't take that into consideration yesterday, and I currently don't have any Ocean tokens or Eth to test with. Might be better if someone else does the test cuz otherwise we'll pay double the gas costs just for transferring and testing with an account of my own. Any suggestions on this block?
It's not a huge cost compared to the grand scheme of things. Better that you (@DimitarSD) take care of all.
To proceed, I recommend to talk to @daneklustig or @brucepon about sending you some OCEAN or ETH to test with.
I have sent @DimitarSD 100 OCEAN and 0.055 ETH for testing Here is the ETH transaction - https://etherscan.io/tx/0x480f611215dac0205854c2ae1c3385ea95c30bb44a602aedee3a8f677a8385f6 Here is the OCEAN transaction - https://etherscan.io/tx/0x016aa0093cc80f0d39b7b3fd3e7b1266e48ecd163b74ec17022f11fdb71b2bd9
OCEAN (ETH) -> OCEAN (MATIC)
Ethereum: 1) tx/0xee0b3d5218005e128247d6cee4cb66ad7de156b0c6c1ececd64b78beaa48efd6 2) tx/0x1b26d057cd76daca56f3fead8c1dbb50b4173e26d245c712831f20ebef76cfa4
Matic: 3) tx/0xc606901e4f5e0cd897738f2beb5ab04ac436b86ee5b2e753407a376818c9888e/token-transfers
OCEAN (MATIC) -> OCEAN (ETH): WIP, fees are too high at the moment
Transfering OCEAN (mOCEAN) tokens from one Matic address to another:
1) tx/0x93e6df0a0dd7c4c09ee4a45b9ec400ef1b82b2d1abaa8b430be896a8084487fa/token-transfers
This is the short guide (I wasn't sure where to share the full version). There are images too, but I didn't add them here. I mainly followed the style format from the documentation.
The Matic Network has its own wallet that connects to your account via Metamask (or any of the other supported wallets). Once you open the link, the wallet will ask to log in. Select your preferred way of connecting and confirm the action.
On the main page of the wallet, you can see all tokens you own on the Matic Mannet. To deposit tokens (transfer them from the Ethereum Mainnet) you can either use the “deposit” button for a selected token or use “Move funds to Matic Mainnet”. Both options will redirect you to the bridge interface. In case you chose the second one, use the dropdown and select the token you want to transfer from the Ethereum Mainnet.
Choose the amount to transfer and click the “Transfer” button. Matic’s bridge interface will guide you through the whole process and the different steps that will occur. You’ll need to sign two transactions on the Ethereum Mainnet. The first being the approval for your token to be traded on the Matic’s bridge and the second one being the deposit.
The withdrawing tokens process uses the same bridge interface. The only difference being that the withdraw happens from the Matic to the Ethereum Mainnet.
Again the bridge interface will guide you through the different steps.
For more in dept explanation of the deposit and withdraw actions check this link
While in the first two cases, the transactions are signed on the Ethereum Mainnet, transferring tokens between two Matic addresses happens on the Matic Mainnet. Thus it’s required for you to connect to the Matic network to sign the transactions. You can use the following parameters to set the network in Metamask:
Network Name: Matic Mainnet RPC: https://rpc-mainnet.maticvigil.com/ Chain Id: 137 Currency Symbol: MATIC Block Explorer URL: https://explorer.matic.network/
Note: If you receive a 500 error “Rate limit exceeded” while you’re trying to transfer tokens on the Matic network, don’t worry. That happens because the public RPC provided by Matic has a daily rate limit of 50K hits. Once the daily limit is reset you’ll be able to use the RPC again.
Also, there are a few questions that we’ll need to clear:
This is the short guide (I wasn't sure where to share the full version).
You'll want it in docs.oceanprotocol.com.
Perhaps in https://docs.oceanprotocol.com/concepts/networks/, or in a new page that follows that page, depending on the amount of content.
Should we use Matic or Polygon?
I'd suggest to say both for now. E.g. "Polygon (was Matic)".
rate limit note
We need to fix this rather than just have a note. That is, our users shouldn't run into rate-limit problems.
It appears that we have a path:
In the docs, we have links to where we can purchase OCEAN tokens (on the Ethereum Mainnet). But I got quite confused with Matic Mainnet (or even any future network). We’re going to have one “main” OCEAN token across different chains. Is it going to be possible to purchase mOCEANS (the Matic's version) or all OCEAN tokens will come from the ETH Mainnet?
Is it going to be possible to purchase mOCEANS (the Matic's version) or all OCEAN tokens will come from the ETH Mainnet?
There's nothing stopping people from setting up DEXes and CEXes for mOCEANs.
Being able to buy mOCEAN from an exchange would actually be super useful for Ocean Market users on Matic to avoid high Eth mainnet gas fees.
We should look around to see what's already on Matic, and see if there's a first class DEX out there, and if there is, to make sure mOCEAN can be exchanged for.
If we do this well, we should expect that most new users would never have to touch the Eth mainnet; their full experience would be on Matic.
(Over time we'll want fiat on/off ramps into mOCEAN too.)
Got it! I'll update the docs accordingly.
And one more thing. Not a high priority at the moment, but this section will need an update as we move forward and introducing new exchanges. Currently, it's being used (in the supported networks docs) for providing information for official exchanges to trade OCEAN. We'll need to have similar for mOCEAN or any future equivalent.
Good point. And in fact I think it could become a priority quickly, for the reasons I give in my comment above. I recommend that you create a specific github issue to handle it. That is:
Is there anything preventing the closing of this issue? @DimitarSD
Related to #77 Test bridge to make sure it works for ocean tokens and do a quick documentation for user on how to use it (maybe it already is)
https://wallet.matic.network/
This evolved into a docs update as well :
Also i suggest merging all the docs prs when we have the market actually running on the network