1
0
mirror of https://github.com/oceanprotocol/docs.git synced 2024-11-26 19:49:26 +01:00
docs/developers/ocean.js
2023-06-13 13:41:12 +00:00
..
cod-asset.md GITBOOK-486: oceanjs c2d 2023-06-12 11:58:58 +00:00
configuration.md GITBOOK-340: more Ocean.js updates 2023-06-09 13:10:40 +00:00
consume-asset.md GITBOOK-486: oceanjs c2d 2023-06-12 11:58:58 +00:00
creating-datanft.md GITBOOK-340: more Ocean.js updates 2023-06-09 13:10:40 +00:00
mint-datatoken.md GITBOOK-233: ocean.js section 2023-05-26 11:50:44 +00:00
publish.md GITBOOK-492: Update the Metadata page 2023-06-13 13:41:12 +00:00
README.md GITBOOK-340: more Ocean.js updates 2023-06-09 13:10:40 +00:00
remove-asset.md GITBOOK-340: more Ocean.js updates 2023-06-09 13:10:40 +00:00
update-metadata.md GITBOOK-340: more Ocean.js updates 2023-06-09 13:10:40 +00:00

description
JavaScript library to privately & securely publish, exchange, and consume data.

Ocean.js

With ocean.js, you can:

  • Publish data services: downloadable files or compute-to-data. Create an ERC721 data NFT for each service, and ERC20 datatoken for access (1.0 datatokens to access).
  • Sell datatokens for a fixed price. Sell data NFTs.
  • Transfer data NFTs & datatokens.

Ocean.js is part of the Ocean Protocol toolset.

{% embed url="https://www.youtube.com/watch?v=lqGXPkPUCqI" %} Introducing Ocean.JS {% endembed %}

The Ocean.js library adopts the module architectural pattern, ensuring clear separation and organization of code units. Utilizing ES6 modules simplifies the process by allowing you to import only the necessary module for your specific task.

Our module structure follows this format:

  • Types
  • Config
  • Contracts
  • Services
  • Utils

When working with a particular module, you will need to provide different parameters. To instantiate classes from the contracts module, you must pass objects such as Signer, which represents the wallet instance, or the contract address you wish to utilize, depending on the scenario. As for the services modules, you will need to provide the provider URI or metadata cache URI.