Merge pull request #957 from oceanprotocol/issue-912-market-tutorials

V4 tutorials
This commit is contained in:
Akshay 2022-04-19 17:18:43 +02:00 committed by GitHub
commit 6e771db165
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
46 changed files with 244 additions and 96 deletions

View File

@ -9,7 +9,7 @@ OCEAN token is used for staking, and more. [Here](https://oceanprotocol.com/toke
Ocean Protocol provides tools for developers to _build data markets_, and to _manage data NFTs and datatokens_ for use in DeFi.
**Build Data Markets.** Use Ocean Protocol software tools to build your own data marketplace, by either forking [Ocean Market](https://market.oceanprotocol.com/) code or building up with Ocean components.
**Build Data Markets.** Use Ocean Protocol software tools to build your own data marketplace, by either forking [Ocean Market](https://v4.market.oceanprotocol.com/) code or building up with Ocean components.
**Manage datatokens and data NFTs for use in DeFi.** Use Ocean [JavaScript](https://github.com/oceanprotocol/ocean.js) or [Python](https://github.com/oceanprotocol/ocean.py) drivers to manage data NFTs and datatokens:

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 KiB

After

Width:  |  Height:  |  Size: 190 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 78 KiB

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 166 KiB

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 132 KiB

After

Width:  |  Height:  |  Size: 111 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

After

Width:  |  Height:  |  Size: 41 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 96 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 49 KiB

After

Width:  |  Height:  |  Size: 146 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 85 KiB

After

Width:  |  Height:  |  Size: 50 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 110 KiB

After

Width:  |  Height:  |  Size: 117 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 165 KiB

After

Width:  |  Height:  |  Size: 221 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 137 KiB

After

Width:  |  Height:  |  Size: 183 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 162 KiB

After

Width:  |  Height:  |  Size: 86 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 157 KiB

After

Width:  |  Height:  |  Size: 79 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 157 KiB

After

Width:  |  Height:  |  Size: 147 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 148 KiB

After

Width:  |  Height:  |  Size: 72 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 209 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 200 KiB

After

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 172 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 153 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 164 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 148 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 187 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 168 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 167 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 185 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 185 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 177 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 166 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 177 KiB

After

Width:  |  Height:  |  Size: 223 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 180 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 177 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 158 KiB

View File

@ -0,0 +1,52 @@
---
title: Add liquidity to liquidity pools
description: Tutorial to add liquidity to Ocean pools using Ocean Market
---
## Access marketplace
1. Go to Ocean <a href="https://v4.market.oceanprotocol.com/" target="_blank">Marketplace</a>.
2. Search for the data asset.
The Ocean Marketplace provides features to search the Data/Algorithms by text, and users can also sort the result by published date.
3. Connect wallet.
![connect wallet](images/marketplace/consume-connect-wallet.png 'Connect wallet')
## Tutorial
### Find an asset
Search for the desired asset published on the <a href="https://v4.market.oceanprotocol.com/" target="_blank">Ocean Marketplace</a>.
### Step 1 - Select pool tab
After finding the dataset, select **`POOL`** tab and click on **`ADD LIQUIDITY`**.
![staking part-1](images/marketplace/Staking-1.png 'POOL tab')
### Step 2 - Associated risks
Read carefully the risks associated with this operation.
![staking part-2](images/marketplace/Staking-2.png 'Associated risks')
### Step 3 - Liquidity amount
Enter the amount of OCEAN tokens you want to add. The expected amount of pool shares and percentages for the provided amount will be displayed.
![staking part-3](images/marketplace/Staking-3.png 'Add liquidity amount')
### Step 4 - Transaction: Access to OCEAN tokens
![staking part-4](images/marketplace/Staking-4.png 'Transaction: Approve spend limit')
### Step 5 - Click supply
![staking part-5](images/marketplace/Staking-5.png 'SUPPLY liquidity')
### Step 6 - Transaction: Add liquidty
![staking part-6](images/marketplace/Staking-6.png 'Transaction: Add liquidity')
![staking part-7](images/marketplace/Staking-7.png 'View transaction')

View File

@ -1,16 +0,0 @@
---
title: Consume data asset
description:
---
1. Go to Ocean Marketplace https://market.oceanprotocol.com/
2. Search for the data asset.
The Ocean Marketplace provides features to search the Data/Algorithms by text, and users can also sort the result by published date.
3. Below image shows how to buy a Data asset with static content.
![consume part-1](images/marketplace/consume-1.png 'Consume')
![consume part-2](images/marketplace/consume-2.png 'Consume')
![consume part-3](images/marketplace/consume-3.png 'Consume')
![consume part-4](images/marketplace/consume-4.png 'Consume')
![consume part-5](images/marketplace/consume-5.png 'Consume')
![consume part-6](images/marketplace/consume-6.png 'Consume')

View File

@ -0,0 +1,42 @@
---
title: Download a data asset
description: Tutorial to download assets using Ocean Market
---
## Access marketplace
1. Go to Ocean <a href="https://v4.market.oceanprotocol.com/" target="_blank">Marketplace</a>.
2. Search for the data asset.
The Ocean Marketplace provides features to search the Data/Algorithms by text, and users can also sort the result by published date.
3. Connect wallet.
![connect wallet](images/marketplace/consume-connect-wallet.png 'Connect wallet')
In this tutorial, we will be using the Rinkeby test network.
## Tutorial
### Step 1 - Click buy
The buy button is enabled only if the connected wallet address has enough OCEAN tokens to exchange them with 1 datatoken.
![consume part-1](images/marketplace/consume-1.png 'Buy')
### Step 2 - Allow access to OCEAN token(s)
![consume part-3](images/marketplace/consume-2.png 'Transaction 1: Permissions to access OCEAN tokens')
### Step 3 - Buy a datatoken by exchanging it with OCEAN token(s)
![consume part-4](images/marketplace/consume-3.png 'Transaction 2: Buy datatoken')
### Step 4 - Click download
![consume part-5](images/marketplace/consume-4.png 'Download asset')
### Step 5 - Sign message
After signing the message, the file download will start.
![consume part-6](images/marketplace/consume-5.png 'Sign')

View File

@ -1,9 +1,9 @@
---
title: Ocean Market
description:
description:
---
https://market.oceanprotocol.com/
https://v4.market.oceanprotocol.com/
## Landing page
@ -15,4 +15,4 @@ https://market.oceanprotocol.com/
2. Consumers can purchase access to data, algorithms, compute services.
3. Liquidity providers can stake their Ocean tokens to earn interest on the transactions going through the Liqiuidy pool.
3. Liquidity providers can add their OCEAN tokens to liquidity pools and earn interest on the transactions.

View File

@ -1,70 +1,130 @@
---
title: Publish a Data asset on Ocean Market place.
description:
title: Publish a data asset
description: Tutorial to publish assets using the Ocean Market
---
## What can be published?
Ocean Market provides a convenient interface for individuals as well as organizations to publish their data. Data set can be images, location information, audio, video, sales data, or combinations of all! There is no exhaustive list of what type of data can be published on the Market. Please note that the Ocean Protocol team maintains a purgatory list [here](https://github.com/oceanprotocol/list-purgatory) to block addresses and remove assets for any violations.
Ocean Market provides a convenient interface for individuals and organizations to publish their data. Datasets can be images, location information, audio, video, sales data, or combinations of all! There is no exhaustive list of what type of data can be published on the Market. Please note the Ocean Protocol team maintains a purgatory list [here](https://github.com/oceanprotocol/list-purgatory) to block addresses and remove assets for any violations.
## Tutorial
### Step 1 - Publish data asset
### Connect wallet and navigate to the publish page
1. Go to <a href="https://v4.market.oceanprotocol.com " target="_blank">Ocean Market</a>
1. Go to https://market.oceanprotocol.com
2. Connect wallet.
![connect wallet](images/marketplace/connect-wallet.png 'Connect wallet')
3. Go to publish page.
In this tutorial, we will be using the Rinkeby test network.
![publish page](images/marketplace/publish.png 'Go to publish page')
3. Go to the publish page.
4. Fill the publish form.
![publish page](images/marketplace/publish.png 'Publish page')
![publish form part-1](images/marketplace/publish-form-1.png 'Publish form part-1')
![publish form part-2](images/marketplace/publish-form-2.png 'Publish form part-2')
![publish form part-3](images/marketplace/publish-form-3.png 'Publish form part-3')
### Step 1 - Metadata
5. After clicking submit, approve the transactions in the wallet. Here, you can see Metamask window.
Fill in the metadata.
Deploy a new datatoken contract.
![publish submit part-1](images/marketplace/submit-1.png 'Create datatoken contract')
Contract interaction.
![publish submit part-2](images/marketplace/submit-2.png 'Contract interaction')
_Mandatory fields are marked with <span style="color: red;">\*</span>_
6. Now, after the transactions are completed, the below screen will appear.
- **Asset type**<span style="color: red;">\*</span>
![publish success](images/marketplace/submit-success.png 'Success')
An asset can be a _dataset_ or an _algorithm_. The asset type cannot be changed after publication.
### Step 2 - Create pricing
- **Title**<span style="color: red;">\*</span>
Once the data asset is published, the user(s) can choose the pricing option as per their choice. Only the publisher can set the pricing option and cannot be changed once the publisher selects any one method.
The descriptive name of the asset. This field is editable after the asset publication.
There are 2 options for settings the price of an asset on Ocean Marketplace.
- **Description**<span style="color: red;">\*</span>
Description of the asset. Ocean Marketplace supports plain text and Markdown format for the description field. This field is editable after the asset publication.
- **Author**<span style="color: red;">\*</span>
The author of the asset. The author can be an individual or an organization. This field is editable after the asset publication.
- **Tags**
Tags help the asset to be discoverable. If not provided, the list of tags is empty by default.
![publish part-1](images/marketplace/publish-1.png 'Asset metadata')
### Step 2 - Access details
_Mandatory fields are marked with <span style="color: red;">\*</span>_
- **Access Type**<span style="color: red;">\*</span>
An asset can be a downloadable file or a compute service on which buyers can run their algorithm. Through **download**, buyers will be able to download the dataset. Through **compute**, buyers will be able to use the dataset in a compute-to-data environment.
- **Provider URL**<span style="color: red;">\*</span>
Provider facilitates the asset download to buyers or for computing jobs and much more.
- **File**<span style="color: red;">\*</span>
The direct URL of the dataset to be published. The file needs to be publicly accessible to be downloadable by buyers. If the file is hosted on services like Google Drive, the URL provided needs to point directly to the data asset file. Also, the file needs to have the proper permissions to be downloaded by anybody.
**Provider** encrypts this field before publishing the asset on-chain.
- **Sample file**
An optional field through which publishers provide a sample file of the dataset they want to publish. The buyers can access it before buying the dataset. This field is editable after the asset publication.
**Provider** encrypts this field before publishing the asset on-chain.
- **Timeout**<span style="color: red;">\*</span>
This field specifies how long the buyer can access the dataset after the dataset is purchased. This field is editable after the asset publication.
![publish part-2](images/marketplace/publish-2.png 'Access details')
### Step 3 - Pricing
The publisher needs to choose a pricing option for the asset before publishing the data asset. The pricing schema is not editable after the asset publication.
There are 3 pricing options for asset publication on Ocean Marketplace.
1. Fixed pricing
2. Dynamic pricing (using Balancer pools)
3. Free pricing
#### Create fixed pricing for a data set
With the _fixed pricing_ schema, the publisher sets the price that buyers will pay to download the data asset.
Connect to the Ocean Marketplace with the publisher account and go to the published asset.
With the _free pricing_ schema, the publisher provides an asset that is free to be downloaded by anyone.
If the pricing is not set Marketplace will provide an option to create pricing. Click on the create pricing button as shown below.
![pricing part-1](images/marketplace/pricing-1.png 'Create pricing page')
With the _dynamic pricing_ schema, the publisher sets the asset price and creates a datatoken liquidity pool with an initial amount of OCEAN tokens.
The publisher can also change the **Swap Fee** of the liquidity pool.
Select the pricing type. Here, we are selecting **Fixed** pricing option. Publisher can set the value of datatoken with respect to Ocean Tokens.
For a deep dive into the fee structure, please refer to this [document](https://docs.oceanprotocol.com/tutorials/marketplace-fees/).
![pricing part-1](images/marketplace/pricing-type.png 'Select pricing type')
![publish part-3](images/marketplace/publish-3.png 'Dynamic pricing')
![pricing part-2](images/marketplace/pricing-fixed-2.png 'Mint data tokens')
### Step 4 - Preview
![pricing part-3](images/marketplace/pricing-fixed-3.png 'Transaction')
![publish part-4](images/marketplace/publish-4.png 'Preview')
![pricing part-4](images/marketplace/pricing-fixed-4.png 'Approve spend limit')
### Step 5 - Blockchain transactions
## Video
![publish part-5](images/marketplace/publish-5.png 'Transaction 1 - Allow access to Ocean tokens')
[![IMAGE ALT TEXT HERE](https://img.youtube.com/vi/KiDg0ry6oV4/0.jpg)](https://www.youtube.com/watch?v=KiDg0ry6oV4)
<br />
![publish part-6](images/marketplace/publish-6.png 'Transaction 2 - Deploy data NFT and datatoken')
<br />
![publish part-7](images/marketplace/publish-7.png 'Transaction 3 - Publish DDO')
### Confirmation
Now, the asset is successfully published and available in the Ocean Market.
![publish success](images/marketplace/publish-8.png 'Successful publish')
On the [profile page](https://v4.market.oceanprotocol.com/profile), the publisher has access to all his published assets.
## Other Articles

View File

@ -1,38 +0,0 @@
---
title: Swap and/or Stake Tokens
description:
---
## Swap OCEAN Tokens against datatokens
1. Search for the desired asset published on the [Ocean Marketplace](https://market.oceanprotocol.com/).
2. Select **Trade** option and enter the amount of Ocean tokens you want to swap. The expected amount that the account will receive will be shown with the swap fees information.
![swap part-1](images/marketplace/Swap-1.png 'Select trade')
3. Approve the Contract transaction to Spend the Ocean Tokens.
![swap part-2](images/marketplace/Swap-2.png 'Approve spend limit')
4. Approve the Contract transaction to swap the tokens. After the transaction is completed, you can add the Datatoken address in the wallet to quickly view the balance in the future.
![swap part-3](images/marketplace/Swap-3.png 'Approve swap transation')
## Staking (Adding Liquidity)
1. Search for the desired asset published on the [Ocean Marketplace](https://market.oceanprotocol.com/).
2. Select **Pool** option and click **ADD LIQUIDITY** button.
![staking part-1](images/marketplace/Staking-1.png 'Select Pool option')
3. Enter the amount of **Ocean Tokens** you want to stake.
![staking part-2](images/marketplace/Staking-2.png 'Enter the amount to stake')
4. Approve the contract transaction. Make sure your account has sufficient **ETH** balance.
![staking part-2](images/marketplace/Staking-3.png 'Approve spend transction')
5. Approve the contract transaction. Make sure your account has sufficient **ETH** balance.
![staking part-2](images/marketplace/Staking-4.png 'Approve contract transaction')
6. After the transactions are completed, the below message will be displayed.
![staking part-2](images/marketplace/Staking-5.png 'Success')

View File

@ -0,0 +1,46 @@
---
title: Swap datatokens
description: Tutorial to swap datatokens for OCEAN tokens using Ocean Market
---
## Access marketplace
1. Go to Ocean <a href="https://v4.market.oceanprotocol.com/" target="_blank">Marketplace</a>.
2. Search for the data asset.
The Ocean Marketplace provides features to search the Data/Algorithms by text, and users can also sort the result by published date.
3. Connect wallet.
![connect wallet](images/marketplace/consume-connect-wallet.png 'Connect wallet')
## Tutorial
### Step 1 - Select TRADE tab
After finding the dataset, select the **`TRADE`** tab.
### Step 2 - Associated risks
Read carefully the risks associated with this operation.
![swap part-1](images/marketplace/Swap-1.png 'Associated risks')
### Step 3 - Trade amount
Enter the amount of OCEAN tokens to swap. The datatokens amount to receive is displayed with the swap fees information. The reverse operation(swap datatokens to OCEAN tokens) is also available on the trade tab.
![swap part-2](images/marketplace/Swap-2.png 'Amount of OCEANs to swap')
### Step 4 - Transaction: Access to OCEAN token(s)
![swap part-3](images/marketplace/Swap-3.png 'Transaction: Approve spend limit')
### Step 5 - Click swap
![swap part-4](images/marketplace/Swap-4.png 'Swap tokens')
### Step 6 - Transaction: Swap tokens
![swap part-5](images/marketplace/Swap-5.png 'Transaction: Swap tokens')
![swap part-6](images/marketplace/Swap-6.png 'View transaction')

View File

@ -5,7 +5,7 @@ description:
## About marketplace
Ocean Protocol's [marketplace](https://market.oceanprotocol.com/) provides a web interface for accessing assets published on the chain. By default, assets metadata is pulled from Aquarius, component hosted by Ocean Protocol. To extend the existing features of the marketplace, developers can fork the marketplace.
Ocean Protocol's [marketplace](https://v4.market.oceanprotocol.com/) provides a web interface for accessing assets published on the chain. By default, assets metadata is pulled from Aquarius, component hosted by Ocean Protocol. To extend the existing features of the marketplace, developers can fork the marketplace.
By doing so, developers can:

View File

@ -16,12 +16,14 @@
items:
- title: Introduction
link: /tutorials/marketplace-introduction/
- title: Publishing data asset
- title: Publish
link: /tutorials/marketplace-publish-data-asset/
- title: Consume data asset
link: /tutorials/marketplace-consume-data-asset/
- title: Swap & Stake
link: /tutorials/marketplace-swap-and-stake/
- title: Download
link: /tutorials/marketplace-download-data-asset/
- title: Swap
link: /tutorials/marketplace-swap/
- title: Add liquidity
link: /tutorials/marketplace-add-liquidity/
- group: Bridges
items: