From 13afb357d9ba83c117181c027ca25bbaaee3f349 Mon Sep 17 00:00:00 2001 From: Matthias Kretschmann Date: Mon, 8 Jul 2019 17:29:12 +0200 Subject: [PATCH] more Pacific fixes --- content/concepts/components.md | 2 +- content/concepts/tools.md | 5 +- content/tutorials/connect-to-networks.md | 36 ++++++------- .../tutorials/get-ether-and-ocean-tokens.md | 32 ++++++++++-- content/tutorials/wallets-and-ocean-tokens.md | 52 +++++++------------ src/components/DocFooter.jsx | 2 +- 6 files changed, 70 insertions(+), 59 deletions(-) diff --git a/content/concepts/components.md b/content/concepts/components.md index 7d9d6e11..69739d40 100644 --- a/content/concepts/components.md +++ b/content/concepts/components.md @@ -78,7 +78,7 @@ An example marketplace/publisher front-end for developers to explore, download, ## Commons Marketplace -An online example marketplace/publisher for consumers to explore, download, and publish open data sets in the [Nile Testnet](/concepts/testnets/#the-nile-testnet). Implemented using [React](https://reactjs.org/) and [squid-js](https://github.com/oceanprotocol/squid-js). +An online example marketplace/publisher for consumers to explore, download, and publish open data sets in the [Pacific Network](/concepts/pacific-network/). Implemented using [React](https://reactjs.org/) and [squid-js](https://github.com/oceanprotocol/squid-js). For more information, see [the blog post about Commons Marketplace](https://blog.oceanprotocol.com/the-commons-data-marketplace-c57a44288314). diff --git a/content/concepts/tools.md b/content/concepts/tools.md index 6c68e97d..4358eeb6 100644 --- a/content/concepts/tools.md +++ b/content/concepts/tools.md @@ -26,6 +26,9 @@ There is an [Ocean Protocol fork of BlockScout](https://github.com/oceanprotocol There are a few Ocean Protocol command-line interfaces (CLIs). All of them were under development at the time of writing, so you may have issues with using them. -- [tuna](https://github.com/oceanprotocol/tuna) can help you use squid-py, squid-js or squid-java from the command line +[tuna](https://github.com/oceanprotocol/tuna) can help you use squid-py, squid-js or squid-java from the command line. + + + - [ocean-cli](https://github.com/bigchaindb-gmbh/ocean-cli) was built using squid-java - [ocean-cli-py](https://github.com/bigchaindb-gmbh/ocean-cli-py) was built using squid-py diff --git a/content/tutorials/connect-to-networks.md b/content/tutorials/connect-to-networks.md index d60f359e..a43a05a5 100644 --- a/content/tutorials/connect-to-networks.md +++ b/content/tutorials/connect-to-networks.md @@ -1,13 +1,24 @@ --- title: Connect to Ocean-Related Networks -description: How to connect to the Kovan testnet, Nile testnet and other Ocean-related networks. +description: How to connect to the Pacific network, Nile testnet and other Ocean-related networks. --- -## Connect to the Kovan Testnet +## Connect to the Pacific Network -Most Ethereum wallets and libraries know how to connect to the [Kovan Testnet](/concepts/testnets/#the-kovan-testnet). In MetaMask, click on the network name then click on "Kovan Test Network" in the drop-down list. +Here are the parameters you might need to connect to the [Pacific Network](/concepts/pacific-network/): -If you're using [Barge](https://github.com/oceanprotocol/barge) to run a local Kovan node, you can connect to that local Kovan node at RPC URL [http://localhost:8545](http://localhost:8545) (called "Localhost 8545" in MetaMask). +| Parameter | Value | +| ------------------ | ---------------------------------------------------------- | +| RPC URL (required) | [https://pacific.oceanprotocol.com][rpc-url] | +| ChainID | `846353` (decimal for MetaMask) or `0xcea11` (hexadecimal) | +| Symbol | Whatever you like, e.g. `PACIFIC ETH` | +| Nickname | Whatever you like, e.g. `Pacific` | + +In MetaMask, click on the network name then click on `Custom RPC` in the drop-down list. Scroll down to the `New Network` section. Enter the above RPC URL. You don't need to add a port number to the end of the RPC URL. Enter the ChainID, Symbol and Nickname if you like. See the [MetaMask docs about how it uses the ChainID](https://metamask.github.io/metamask-docs/Main_Concepts/Sending_Transactions). + +If you're using [Barge](https://github.com/oceanprotocol/barge) to run a local Pacific node, you can connect to that local Pacific node at RPC URL [http://localhost:8545](http://localhost:8545) (called "Localhost 8545" in MetaMask). You can configure that local Pacific node by editing the files in the `barge/networks/pacific/config/` directory. + +[rpc-url]: https://pacific.oceanprotocol.com ## Connect to the Nile Testnet @@ -28,19 +39,8 @@ If you're using [Barge](https://github.com/oceanprotocol/barge) to run a local N When using [Barge](https://github.com/oceanprotocol/barge) to run a purely-local testnet (Spree or Ganache-based), you can connect to a local node at RPC URL [http://localhost:8545](http://localhost:8545) (called "Localhost 8545" in MetaMask). -## Connect to the Pacific Network +## Connect to the Kovan Testnet -Here are the parameters you might need to connect to the [Pacific Network](/concepts/pacific-network/): +Most Ethereum wallets and libraries know how to connect to the [Kovan Testnet](/concepts/testnets/#the-kovan-testnet). In MetaMask, click on the network name then click on "Kovan Test Network" in the drop-down list. -| Parameter | Value | -| ------------------ | ------------------------------------------------------- | -| RPC URL (required) | [https://pacific.oceanprotocol.com][rpc-url] | -| ChainID | `846353` (decimal for MetaMask) or `0xcea11` (hexadecimal) | -| Symbol | Whatever you like, e.g. `PACIFIC ETH` | -| Nickname | Whatever you like, e.g. `Pacific` | - -In MetaMask, click on the network name then click on `Custom RPC` in the drop-down list. Scroll down to the `New Network` section. Enter the above RPC URL. You don't need to add a port number to the end of the RPC URL. Enter the ChainID, Symbol and Nickname if you like. See the [MetaMask docs about how it uses the ChainID](https://metamask.github.io/metamask-docs/Main_Concepts/Sending_Transactions). - -If you're using [Barge](https://github.com/oceanprotocol/barge) to run a local Pacific node, you can connect to that local Pacific node at RPC URL [http://localhost:8545](http://localhost:8545) (called "Localhost 8545" in MetaMask). You can configure that local Pacific node by editing the files in the `barge/networks/pacific/config/` directory. - -[rpc-url]: https://pacific.oceanprotocol.com +If you're using [Barge](https://github.com/oceanprotocol/barge) to run a local Kovan node, you can connect to that local Kovan node at RPC URL [http://localhost:8545](http://localhost:8545) (called "Localhost 8545" in MetaMask). diff --git a/content/tutorials/get-ether-and-ocean-tokens.md b/content/tutorials/get-ether-and-ocean-tokens.md index 6328a64d..e8e33693 100644 --- a/content/tutorials/get-ether-and-ocean-tokens.md +++ b/content/tutorials/get-ether-and-ocean-tokens.md @@ -15,19 +15,33 @@ In MetaMask, be sure to switch from the **Main Ethereum Network** to whatever ne ## Get Ether -### Get Ether for the Kovan Testnet +### Get Ether for the Pacific Network -You can get Kovan Ether (KEth), for the Kovan Testnet, from a Kovan faucet: see [the official list of Kovan faucets](https://github.com/kovan-testnet/faucet). You have to give the faucet your Kovan address (wallet account address). You can get that from MetaMask. It's a string that looks like: +If you're connecting to the Pacific network, you can use the Ocean Faucet. A simple UI for it is deployed as part of the Commons marketplace under: -```text -0xa0A9d7f78bF293514e7cA2789A0Af689eEC99282 +- client: [commons.oceanprotocol.com/faucet](https://commons.oceanprotocol.com/faucet) + +This interface is set up to communicate with the deployed Ocean Faucet Server under: + +- server: [faucet.oceanprotocol.com](https://faucet.oceanprotocol.com) + +You can also communicate with that server directly and get some Nile Ether into `` using the following command: + +```bash +curl --data '{"address": "", "agent": "curl"}' -H "Content-Type: application/json" -X POST https://faucet.oceanprotocol.com/faucet ``` +In the above command you only need to replace `` with your own Ethereum address. + +Check out the [Ocean Faucet Server repository](https://github.com/oceanprotocol/faucet) to learn more about what the server provides. + +The Pacific faucet has a limit of one request every 24 hours for the same Ethereum address. But don't worry, the Ether given is more than enough for interacting with the network. + ### Get Ether for the Nile Testnet If you're connecting to the Nile testnet, you can use the Ocean Faucet. A simple UI for it is deployed as part of the Commons marketplace under: -- client: [commons.oceanprotocol.com/faucet](https://commons.oceanprotocol.com/faucet) +- client: [commons.nile.dev-ocean.com/faucet](https://commons.nile.dev-ocean.com/faucet) This interface is set up to communicate with the deployed Ocean Faucet Server under: @@ -73,6 +87,14 @@ Details about the bootstrapped accounts can be found in [the README.md file in t curl --data '{"address":""}' -H "Content-Type: application/json" -X POST localhost:3001/faucet ``` +### Get Ether for the Kovan Testnet + +You can get Kovan Ether (KEth), for the Kovan Testnet, from a Kovan faucet: see [the official list of Kovan faucets](https://github.com/kovan-testnet/faucet). You have to give the faucet your Kovan address (wallet account address). You can get that from MetaMask. It's a string that looks like: + +```text +0xa0A9d7f78bF293514e7cA2789A0Af689eEC99282 +``` + ## Get Ocean Tokens See the page about [Ocean Tokens](/concepts/ocean-tokens/). diff --git a/content/tutorials/wallets-and-ocean-tokens.md b/content/tutorials/wallets-and-ocean-tokens.md index ffe27c35..4d9f84e1 100644 --- a/content/tutorials/wallets-and-ocean-tokens.md +++ b/content/tutorials/wallets-and-ocean-tokens.md @@ -9,26 +9,24 @@ If you don't see any Ocean Tokens in your crypto wallet software (e.g. MetaMask If you know the URL of a Brizo instance attached to the network you're using, then just go to that URL in your web browser and get the value of `contracts.OceanToken`. +### Ethereum Mainnet + +The Ocean Token contract address in the Ethereum Mainnet is: + +[`0x985dd3D42De1e256d09e1c10F112bCCB8015AD41`](https://etherscan.io/token/0x985dd3d42de1e256d09e1c10f112bccb8015ad41) + +### Pacific Network + +The Ocean Token contract address in the [Pacific Network](/concepts/pacific-network/) is: + +[`0x012578f9381e876A9E2a9111Dfd436FF91A451ae`](https://submarine.oceanprotocol.com/address/0x012578f9381e876a9e2a9111dfd436ff91a451ae/transactions) + ### Kovan or Nile Testnet | Testnet | Ocean Token Contract Address | | ------- | -------------------------------------------- | -| Kovan | `0xB57C4D626548eB8AC0B82b086721516493E2908d` | | Nile | `0x9861Da395d7da984D5E8C712c2EDE44b41F777Ad` | - -If the above addresses are out-of-date, then you can find newer ones in the [keeper-contracts repository on GitHub](https://github.com/oceanprotocol/keeper-contracts): - -1. Click on the "Branch: **develop**" button and switch to the tag of the latest release (e.g. `v0.10.3`). -1. In the `README.md` file, check the address of the OceanToken contract (in Nile or Kovan). -1. Double-check the address by looking in the file named `zos.kovan.json` (for Kovan) or `zos.dev-8995.json` (for Nile). Search for `/OceanToken`. There should be one result and the text around it should look like: - - ```json - "@oceanprotocol/keeper-contracts/OceanToken": [ - { - "address": "0x9861Da395d7da984D5E8C712c2EDE44b41F777Ad", - ``` - - Compare the `"address"` value to the value from the `README.md` file. +| Kovan | `0xB57C4D626548eB8AC0B82b086721516493E2908d` | ### Spree or Ganache-Based Testnet @@ -37,29 +35,17 @@ If you're using [Barge](https://github.com/oceanprotocol/barge) to run a local S - `$HOME/.ocean/keeper-contracts/artifacts/OceanToken.spree.json` for Spree - `$HOME/.ocean/keeper-contracts/artifacts/OceanToken.development.json` for Ganache -### Ethereum Mainnet - -The Ocean Token contract address in the Ethereum Mainnet is: - -`0x985dd3D42De1e256d09e1c10F112bCCB8015AD41` - -### Pacific Network - -The Ocean Token contract address in the [Pacific Network](/concepts/pacific-network/) is: - -`0x012578f9381e876A9E2a9111Dfd436FF91A451ae` - ## Step 2: Teach Your Wallet Software about Ocean Tokens ### MetaMask Instructions 1. Make sure MetaMask is connected to the correct network (Nile, Kovan or whatever). See [the tutorial about how to do that](/tutorials/connect-to-networks/). -1. For the account you want to manage, click the `☰` (hamburger menu icon). -1. Scroll down until the `Add Token` link is visible, then click on it. -1. Click on `Custom Token`. -1. Paste the OceanToken contract address (from Step 1 above) into the "Token Contract Address" field. The other two fields should auto-fill. If they don't then something is wrong. -1. Click `Next`. -1. Click `Add Tokens`. +2. For the account you want to manage, click the `☰` (hamburger menu icon). +3. Scroll down until the `Add Token` link is visible, then click on it. +4. Click on `Custom Token`. +5. Paste the OceanToken contract address (from Step 1 above) into the "Token Contract Address" field. The other two fields should auto-fill. If they don't then something is wrong. +6. Click `Next`. +7. Click `Add Tokens`. MetaMask should now show your Ocean Token (OCEAN) balance, and when you're looking at that, there should be a `Send` button to send Ocean Tokens to others. For help with that, see [the MetaMask docs about how to send tokens](https://metamask.zendesk.com/hc/en-us/articles/360015488931-How-to-Send-Tokens). diff --git a/src/components/DocFooter.jsx b/src/components/DocFooter.jsx index a0ced019..1c9a321a 100644 --- a/src/components/DocFooter.jsx +++ b/src/components/DocFooter.jsx @@ -24,7 +24,7 @@ const DocFooter = ({ post, url, externalName }) => { return (