An improved CosmosJS library

Chung Dao
Oraichain
Published in
4 min readMay 7, 2021

--

For low-cost cross-platform development and easy communication with Cosmos blockchains. Github repository: https://github.com/oraichain/cosmosjs

Oraichain’s mission is to build a comprehensive ecosystem that supports developers in all aspects of building innovative products with Blockchain and AI technologies. This means providing more than AI Oracle services and Marketplace access. We recently launched Oraichain Studio to aid in the creation of smart contracts on the Oraichain Mainnet. We are excited to share our newest development and introduce our improved version of CosmosJS library, an open source library that helps building cross-platform applications as well as easily interact with Oraichain and other Cosmos-based blockchains with the revolutionary Stargate upgrade.

Ready at Cosmos and development road

The latest upgrade of Cøsmos network to Stargate on 18 February 2021 is considered a revolutionary upgrade to all Cosmos-based blockchains due to the realization — for the first time — of the Interblockchain communication protocol (IBC), efficient data structuring with Protocol Buffers (aka, ‘Protobuf’), automatic upgrade, and many more functionalities.

In step with the ambition of the Cøsmos team, Oraichain had also adapted and implemented all those great features on Oraichain Mainnet, which went live only six days after Stargate . Oraichain Mainnet utilizes the secured WASM for executing smart contracts, speeds up data communication with Protobuf, optimizes blockchain upgrade with automatic/transparent upgrade. Since Mainnet, Oraichain has been strengthening its ecosystems and infrastructure for Blockchain and AI services. Oraichain is already bridging to Ethereum and very ready to communicate with other blockchains on Cøsmos too.

Today, we would like to introduce a useful library that Oraichain proudly maintains to be compatible with Stargate upgrade and provide cross-platform development: CosmosJS library.

Link to the Github repository: https://github.com/oraichain/cosmosjs

Improved CosmosJS — Easy communication with Blockchains, Cross-platform development

Original CosmosJS library existed on Cosmostation and similar on Cosmos Hub, but they are no longer maintained to be compatible with the latest Stargate upgrade of Cøsmos.

Oraichain has forked the Cosmostation’s library into our own repository and improved it further:

  • Being compatible with Stargate for Cosmos SDK
  • Integrating Protobuf
  • Equipping it with cross-platform deployment (i.e., build once and run everywhere on Web, Mobile and CLI)

Our CosmosJS library allows developers to communicate with Oraichain, and eventually Cøsmos-based blockchains through various kinds of transaction messages using Javascript language, which is indeed much easier than through command line interface (CLI) with Go programming language. Application developers who are mostly experienced with Javascript will surely enjoy this utility, freeing them from the constraints of terminal commands.

Another advantage of Oraichain’s CosmosJS is that you can build code once and have multiple applications across different platforms including Web browser, Mobile (Android and iOS) and CLI. This is indeed a unique point of our library.

Our first development with the improved CosmosJS: ORAI Wallet

Using our CosmosJS library, Oraichain has developed an ORAI Wallet application that can run as a Web application and Mobile application (both Android and iOS). The details of this application is soon to be released. In the meantime, we are calling for beta testing participants for ORAI Wallet.

The call information can be found here:

https://link.medium.com/Cm5Iq5QC2fb

Final note: a sweet bonus

For those developers who want to contribute to Oraichain’s CosmosJS, please notice that we have also implemented an Auto-completion feature using TypeScript for the library! Happy coding :)

About Oraichain

Oraichain is the world’s first AI-powered oracle and ecosystem for blockchains. Oraichain data oracle platform aggregates and connects Artificial Intelligence APIs to smart contracts and regular applications. Founded by Dr. Chung Dao, Oraichain’s mission is to be the portal between AI and blockchain technologies, serving as a foundational layer for the creation of a new generation of smart contracts and Dapps leveraging AI.

Unlike regular oracles using raw data, Oraichain’s AI oracle uniquely uses AI APIs to process and create data on-the-fly via virtual machines on smart contracts. Data quality, reliability and security are enhanced by using test cases, which help to avoid intermediaries, increase trust and open up unprecedented application functionalities.

Beyond data oracles, Oraichain interconnects Artificial Intelligence and Blockchain technologies. With AI as the cornerstone, the Oraichain ecosystem contains an AI marketplace, a Data & Request Hub, Publisher Service, Training Service, and Dapp Hosting.

Oraichain network provides the infrastructure and consensus mechanisms for Blockchain and AI training. These interconnected ecosystems accelerate the development of Web3, DeFi, enterprise and academia applications. yAI.finance is the first use case of Oraichain, a DeFi platform using unique AI-based features and strategies. aiRight brings AI NFT creation and copyright generation to blockchain. Oraichain AI Marketplace offers AI products and APIs with the goal of becoming the one-stop-shop for Artificial Intelligence services.

Website | Whitepaper | Twitter | GitHub | Telegram | Facebook | LinkedIn | Youtube | Medium | Media kit

--

--