Crescent Network: A Cosmos SDK based chain that built the entire ecosystem with Cosmos SDK modules

What is Crescent Network?

Crescent Network is a Cosmos SDK based chain that builds an entire ecosystem using Cosmos SDK modules. Unlike other chains that use smart contract technology to build DeFi applications, Crescent Network only uses the Cosmos SDK modules to build its DeFi applications.

Cosmos SDK modules are embedded into the chain on the genesis block. This is different from smart contracts, which are created on top of the blockchain after the chain has launched. Since the SDK is embedded into the chain, these modules are very optimized, lightweight, and fast compared to smart contract alternatives. Moreover, Cosmos SDK modules also enable Inter-Blockchain Communication(IBC)  integrations into these modules, which then enables interoperability between Cosmos based chains.

What is Cosmos SDK?

The Cosmos SDK is an open-source framework for building secure blockchain applications on top of Tendermint. Tendermint is the underlying mechanism of the Cosmos SDK which controls the consensus mechanism. Developers can choose either Proof-of-Stake (PoS) or Proof-of-Authority (PoA) consensus for their blockchains.

Any developer can fork the Cosmos SDK from GitHub and start modifying the core logic or adding new modules to start developing a new blockchain. This makes the Cosmos SDK a perfect boilerplate for developing an application-specific blockchain on Tendermint.

What is a Cosmos SDK module?

The Cosmos SDK lets developers build applications embedded in the blockchain without modifying elements of the core logic like the consensus model. The Cosmos SDK modules allow developers to put in place the business logic of their applications like smart contracts on EVM chains. The difference is that it’s embedded permanently into the blockchain on the genesis block which makes them fully immutable.

Another feature that developers can use on Cosmos SDK modules is that these modules can be composed together. Different modules communicate with each other via IBC, which is also a module that is responsible for cross-chain interoperability. Cosmos SDK modules can interact with the IBC module to enable cross-chain communication.

There are several components in the Cosmos SDK modules:

  • Messages and Queries where both define the input of the module.
  • Keepers are responsible for defining module implementation and connecting other modules.
  • Invariants are responsible for checking whether the state of the chain is valid.
  • Module Genesis defines the initial state and actions that execute when the chain has launched for the first time.
  • Module Interfaces defines an interface for CLI and wallets such as Keplr to interact with the module.

By default, a Cosmos SDK based chain consists of auth, authz, bank, capability, crisis, distribution, epoching, evidence, feegrant, genutil, gov, group, mint, nft, params, simulation, slashing, staking, and upgrade modules. Developers are free to add or remove these modules when building a chain.

Crescent chain comes with 5 modules that define the possible actions in the https://app.crescent.network/. Claim, farming, liquidity, liquidstaking, and mint are the modules involved.

Here is  a comprehensive tutorial on developing Cosmos SDK modules.

What is IBC?

Inter Blockchain Communication (IBC) is a protocol for sending messages across chains. Currently, in 2022,  the majority of IBC-supported chains implement Tendermint as their infrastructure. Cosmos SDK and Axelar are also implemented on Tendermint.

Amongst the many use cases for IBC, one is to bridge a token from one chain to another. But IBC is not only for token bridging; IBC can pass arbitrary messages cross-chain. This means a module in a chain can interact with a compatible module in another chain.  CosmWasm module enables smart contracts for Cosmos SDK based chains. These smart contracts can communicate with each other using the IBC protocol. Message passing between smart contracts on different chains enables many use cases, such as NFT bridging, cross-chain yield aggregator, cross-chain NFT marketplace, and many more.

Bridging tokens from other Cosmos chains to Crescent Network

To bridge tokens from other Cosmos chains to Crescent Network, for example, ATOM, IBC transfers tokens from your wallet on another chain to your wallet on Crescent Network.

You can follow the instructions here for making IBC transfers with Keplr wallet.

Bridging tokens from EVM chains to Crescent Network

You can use Axelar Satellite to bridge tokens from EVM chains to Crescent Network. This is possible as Axelar has its consensus mechanism that lets validators pick bridge transactions from supported EVM chains and validate them. Once validated, an Axelar wrapped token is minted on the Axelar chain which is based on Tendermint. Finally, Axelar can use IBC to transfer these tokens from the Axelar chain to the Crescent Network.

Axelar supports multiple EVM chains, including Ethereum, Binance Smart Chain, Polygon, Avalanche, Fantom, and Moonbeam.

Bridged tokens from Axelar always have “.axl” as their suffix to show that this token is an Axelar wrapped token.

Crescent Network Applications

Currently, Crescent Network has one core application that is divided into 6 modules:

Swap

This feature lets users swap their tokens for another token. For example, you can swap 100 bCRE for 26.66 USDC.axl. This is done by an Automated Market Maker (AMM) mechanism where a liquidity pool is needed.

Yield Farming

This feature lets users provide a liquidity pair (Deposit), withdraw a liquidity pair (Withdraw), stake into a pool (Farm), unstake from a pool (Unfarm) and harvest the farming reward (Claim). This is done by liquidity and farming modules on the Cresent Network.

Staking

This feature lets users stake CRE and receive bCRE, or unstake bCRE and receive back CRE. bCRE is an interest-bearing token that receives the validator yield. This feature is done by the liquidstaking module to allow users to delegate their CRE without losing access to their fund completely, thus improving capital efficiency.

Governance

This feature lets users vote on governance proposals using their CRE. This is done by the gov module, which is a native module in the Cosmos SDK.

Portfolio

This feature lets users view their entire portfolio on the crescent network on one page. This is developed by using an indexer to automatically index every block of the chain and insert formatted data into the database. This data will be queried and displayed in the Portfolio user interface.

Airdrop

This feature rewards early adopters, and allows them to claim their airdrop rewards. Airdrop distribution information can be fround on this DEXdrop Breakdown. This is done by the claim module implemented on the Cresent Network.

Crescent Network Custom Cosmos SDK modules

Crescent Network consists of five custom Cosmos SDK modules:

Liquidity

The liquidity module implements a decentralized exchange (DEX) that serves liquidity providing and coin trading functions. Anyone can create a liquidity pool with a pair of coins, provide liquidity by depositing reserve coins into the liquidity pool, and trade coins using the liquidity pool.

Farming

The farming module allows users to stake their liquidity pair into a predefined pool to earn the farming reward. This module is also responsible for calculating and distributing the farming reward.

Liquidstaking

The liquidstaking module allows users to delegate their CRE to the validators and earn bCRE back as a staking ticket. bCRE is required to claim back the original CRE.

Claim

The claim module is responsible for distributing CRE to the early adopters that are eligible for the airdrop.

Mint

Unlike the mint module in the Cosmos SDK that allows for a flexible (dynamic) inflation rate determined by market demand targeting a particular bonded-stake ratio, this mint module is customized to use a constant inflation rate. The module mints in relative to the block time with the predefined inflation schedule in params.

You can find the implementation of each module on the Crescent Network Github page.

How to develop on Crescent Network

Currently, developers cannot build their  DApps on the Crescent Network directly. However, developers can build a new Cosmos SDK-based chain that has a custom module to interact with the modules in Crescent Network using IBC. The developed module must have a compatible interface with the pairing module in the Crescent Network.

Conclusion

The Crescent Network is a Cosmos SDK-based chain that builds an entire ecosystem with Cosmos SDK modules. The Crescent Network consists of five custom Cosmos SDK modules, including liquidity, farming, liquidstaking, claim, and mint. These modules work together to form the only core DApps of the Crescent Network. Other Tendermint-based chains can communicate with Crescent Network using the IBC protocol. Users can transfer funds from other Tendermint-based chains using IBC transfer and from EVM-based chains using Axelar Satellite. External developers building DApps integrating with Crescent Network are required to build a new Cosmos SDK-based chain with a compatible IBC interface.

  • Understand how secure cross-chain is with trust model. Learn how different cross-chain use different trust assumptions.

    Continue reading
  • Learn how low gas fees EVM chain Polygon works, and understand its ecosystem.

    Continue reading
  • How can we explain the popularity of Layer-2 blockchains and the number of developers choosing to build a dApp on Layer-2 platforms? The answer is one word: scalability.

    Continue reading
  • Understand how secure cross-chain is with trust model. Learn how different cross-chain use different trust assumptions.

    Continue reading
  • Learn how low gas fees EVM chain Polygon works, and understand its ecosystem.

    Continue reading