Skip to content

Commit

Permalink
Merge pull request #534 from centrifuge/feat/cfg-base-docs
Browse files Browse the repository at this point in the history
feat: add base CFG info for docs
  • Loading branch information
0x4Graham authored Aug 23, 2024
2 parents 6991283 + caa3131 commit 4e42f52
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 18 deletions.
2 changes: 2 additions & 0 deletions docs/getting-started/token-summary/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ Centrifuge can be bridged 1:1 to Ethereum, where it can be used with decentraliz

Centrifuge on Ethereum is an ERC20 token. [You can find the token contract for CFG on Ethereum here](https://etherscan.io/token/0xc221b7e65ffc80de234bbb6667abdd46593d34f0).

Centrifuge on Base is an ERC20 token. [You can find the token contract for CFG on Base here](https://https://basescan.org/token/0x2b51E2Ec9551F9B87B321f63b805871f1c81ba97).

## Tokenomics, block explorer, and token supply endpoints

[You can find the block explorer for the CFG token here](https://centrifuge.subscan.io/), to see accounts, transactions, and statistics about CFG and Centrifuge Chain.
Expand Down
48 changes: 30 additions & 18 deletions docs/user/cfg-bridge/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,29 +2,17 @@
id: cfg-bridge
order: 5
title: CFG (Centrifuge) to CFG (Ethereum)
contributors: <Lucas Vogelsang:[email protected]>
contributors: <Lucas Vogelsang:[email protected]>, <Graham Nelson:[email protected]>
redirect_from:
- /use/cfg-bridge
- /use/cfg-bridge/
---

# CFG (Centrifuge) {'\<\>'} CFG (Ethereum)
# CFG (Centrifuge) {'\<\>'} CFG (Ethereum) {'\<\>'} CFG (Base)

The **CFG** token lives natively on Centrifuge Chain but can be bridged to Ethereum and used as an ERC20 token. The ERC20 Token is also called **CFG** on Ethereum and has the address `0xc221b7E65FfC80DE234bbB6667aBDd46593D34F0` on Ethereum mainnet.
The **CFG** token lives natively on Centrifuge Chain but can be bridged to Ethereum and used as an ERC20 token, Once on Ethereum, CFG can then be transferred to Base. The ERC20 Token is also called **CFG** on Ethereum and Base has the address `0xc221b7E65FfC80DE234bbB6667aBDd46593D34F0` on Ethereum mainnet and `0x2b51E2Ec9551F9B87B321f63b805871f1c81ba97` on Base mainnet.

## About the bridge

The bridge used by Centrifuge is a trusted relayer bridge. This means a set of relayers are trusted with relaying messages between Ethereum and Centrifuge chain. When assets are moved between the chains, these relayers pick up the message on Centrifuge Chain and trigger a transaction in Ethereum or vice versa. The bridge is built by [ChainSafe](https://chainsafe.io) in collaboration with Celo, Aragon and ETH Classic. [Read ChainSafe's announcement](https://medium.com/chainsafe-systems/chainsafe-building-chainbridge-49d51ff2e0a2) to learn more about the bridge.

## Bridge Fees

The CFG (Centrifuge) {'\<\>'} CFG (Ethereum) bridge relies on a set of relayers to submit transactions to Ethereum and Centrifuge Chain about the events happening on the other chain. Because these transactions can be very costly at high gas prices, the bridge must charge high enough fees that it will be able to pay for its fees even during times of very high gas prices. For this reason, the fee to go from Centrifuge Chain to Ethereum is relatively high whereas to bridge tokens from Ethereum to Centrifuge chain is cheaper (only the gas fees in gwei on Ethereum have to be paid).

Please note that the CFG (Centrifuge){'\<\>'} CFG (Ethereum) bridging fee costs 100 CFG tokens.

In addition, because Centrifuge Chain does not have any insight into gas prices on Ethereum, there is no way to charge the actual gas spent. The bridge fees are constant and can be changed at any time by the council and are shown to you before you bridge any tokens. There are ways to improve the performance of this in future iterations (batching of transactions, signature aggregation etc.).

## How are CFG on Centrifuge Chain & CFG on Ethereum different?
## How are CFG on Centrifuge Chain & CFG on Ethereum/Base different?

Each CFG (Ethereum) is backed by one CFG (Centrifuge) locked up in the bridge account on Centrifuge Chain when moved over to Ethereum. You can move between Ethereum and Centrifuge at any time without any restrictions.

Expand All @@ -33,12 +21,24 @@ Using **CFG on Centrifuge Chain** allows you to:
- Participate in governance
- Pay for fees on Centrifuge Chain

Using **CFG on Ethereum** allows you:
Using **CFG on Ethereum/Base** allows you:

- To interact with DeFi apps that support ERC20 tokens
- Use it within Ethereum and hold it in your Ethereum wallet.

## Using the bridge
# About the bridge (Centrifuge -> Ethereum)

The bridge used by Centrifuge is a trusted relayer bridge. This means a set of relayers are trusted with relaying messages between Ethereum and Centrifuge chain. When assets are moved between the chains, these relayers pick up the message on Centrifuge Chain and trigger a transaction in Ethereum or vice versa. The bridge is built by [ChainSafe](https://chainsafe.io) in collaboration with Celo, Aragon and ETH Classic. [Read ChainSafe's announcement](https://medium.com/chainsafe-systems/chainsafe-building-chainbridge-49d51ff2e0a2) to learn more about the bridge.

## Bridge Fees

The CFG (Centrifuge) {'\<\>'} CFG (Ethereum) bridge relies on a set of relayers to submit transactions to Ethereum and Centrifuge Chain about the events happening on the other chain. Because these transactions can be very costly at high gas prices, the bridge must charge high enough fees that it will be able to pay for its fees even during times of very high gas prices. For this reason, the fee to go from Centrifuge Chain to Ethereum is relatively high whereas to bridge tokens from Ethereum to Centrifuge chain is cheaper (only the gas fees in gwei on Ethereum have to be paid).

Please note that the CFG (Centrifuge){'\<\>'} CFG (Ethereum) bridging fee costs 100 CFG tokens.

In addition, because Centrifuge Chain does not have any insight into gas prices on Ethereum, there is no way to charge the actual gas spent. The bridge fees are constant and can be changed at any time by the council and are shown to you before you bridge any tokens. There are ways to improve the performance of this in future iterations (batching of transactions, signature aggregation etc.).

## Using the bridge (Centrifuge to Ethereum)

A hosted bridge UI is available at https://bridge.centrifuge.io Navigate over there and you will be presented with two options: **Get CFG on Centrifuge** to move ERC20 CFG to Centrifuge Chain and **Get CFG on Ethereum** to move native CFG to Ethereum. Select which way you would like to use the bridge and the UI will ask you to connect your wallet (either via MetaMask for Ethereum or the Polkadot.js Browser Extension).

Expand All @@ -55,3 +55,15 @@ Click on **Start Transfer** and then confirm the transfer:
The bridge relayers now submit your transfer request on chain. After enough confirmations have passed, you will receive the tokens on your target chain (an average transfer takes about 15 minutes. In case of higher traffic in both networks, it can take a little bit longer).

![Pending transfer](./images/bridge_in_transit.png)

# About the bridge (Ethereum -> Base)

The bridge used by Centrifuge for CFG transfer from Ethereum -> Base leverages Axelar’s interchain service, a decentralized and secure cross-chain communication network, to facilitate seamless transfers between Ethereum and the Base chain. When assets are moved between these chains, Axelar’s network of validators securely relays messages. For instance, when an asset is transferred from Ethereum to Base, Axelar validators detect the transaction on Ethereum and trigger the corresponding transaction on Base, or vice versa. This ensures a trustless, scalable, and efficient bridging solution. Axelar’s interchain service is widely adopted across multiple blockchain ecosystems, making it a reliable choice for cross-chain interoperability. [Learn more about Axelar’s interchain service.](https://www.axelar.network/its)

The setup makes use of the [Mint/Burn Token Manager](https://github.com/axelarnetwork/interchain-token-service/blob/main/contracts/token-manager/TokenManager.sol). Therefore, when transferring CFG from Ethereum to Base, the specified amount is burned on Ethereum and then minted on Base after Axelar's secure cross-chain communication process has completed.

## Using the bridge (Ethereum to Base)

To transfer CFG from Ethereum to Base, you are required to use [Squid Router](https://app.squidrouter.com/).

Squid operates as a cross-chain router, enabling single-click actions such as token swaps, purchases, deposits, and staking across different blockchains. Squid integrates with Axelar’s infrastructure to provide a secure and efficient cross-chain experience.

0 comments on commit 4e42f52

Please sign in to comment.