Introducing SwaySwap and SwayLend

Introducing SwaySwap and SwayLend

Fuel is the fastest modular execution layer blockchain with its smart contract based on the UTXO model for execution. Even though Fuel mainnet is not yet live, developers have started building cool applications on it. An example of these apps are SwaySwap and SwayLend, two projects built on the Fuel network.

Testing the Dapps

This article is a concise explanation that aims to give a user an edge in understanding how to navigate through two new Dapps built on the Fuel blockchain network - SwaySwap and SwayLend.

SwaySwap is a super fast DEX built on the Fuel network. An application like SwaySwap exists to help people exchange their cryptocurrencies easily without having to go through ineffective and expensive ways of owning a particular cryptocurrency.

SwayLend is a DApp built by a team of blockchain developers with the Twitter handle https://twitter.com/swaygangsters/. They have a high blockchain engineering expertise and have been contributing actively to the growth of the smart contract language used on Fuel network called SwayLang.

Setting up Fuel Wallet

To use SwaySwap, you need to create a wallet. The official link for SwaySwap is fuellabs.github.io/swayswap. Click on “Launch APP” as shown on the homepage. After clicking on the link, you’d need to quickly set up a wallet for connecting to applications built on Fuel such as SwaySwap.

Step 1: Click on Create Wallet

Step 2: To add some testnet ETH tokens to your wallet, confirm that you are not a robot and click on “Give me ETH”.

A wallet creation success message will be displayed if all steps were followed rightly.

Swapping Tokens using SwaySwap

SwaySwap was built by the contributors of Fuel blockchain to show the excellence of the new network. SwaySwap is an avenue for users to easily exchange different tokens. It makes token exchange available for anyone trying to use the lending protocol. From the example below, the wallet only had ETH in it when it was connected to SwaySwap but because of the Swap, I was able to exchange it easily for Dai.

To swap tokens, input the values you want in the box and click on “Swap”.

Depositing in Liquidity Pools (Pool Feature)

Liquidity Pools in crypto are the combination of users' cryptocurrencies deposited into locked smart contracts to enable decentralized financial activities. Liquidity pools are one of the building blocks of decentralized finance (commonly called DeFi). With this mechanism, developers can build decentralized exchanges, lending and borrowing protocols and different applications that deal with users’ funds.

SwaySwap has a POOL section where users can input their liquidity. One of the advantages of depositing tokens in a pool like SwaySwap’s is to earn passively on your crypto assets. Liquidity providers earn a share of the trading fees paid by those who use the liquidity pools for swapping tokens or borrowing.

Since you do not have any funds in the pool, the app displays the page below.

To add your tokens to the pool, click on Add Liquidity and input the amount you want to deposit into the liquidity pool. (Make sure you have loaded your wallet with some testnet tokens as I did with Ether and Dai for mine). Click on Add Liquidity to finalize the transaction.

Now that you have deposited tokens in the pool, you can see the information regarding your holdings in the liquidity pool. (To understand more about liquidity pools and their advantages and disadvantages check the link at the bottom of the article).

This is a brief overview of what you should expect on SwaySwap and how to use the platform.

After you have finished setting up and swapping with SwaySwap, let's proceed to the SwayLend protocol so that we can test out the sweet lending protocol.

The official link is: https://swaylend.com/

Testing SwayLend: Account Dashboard

SwayLend provides you with a rich and easy-to-use interface for monitoring your portfolio. A list of the major tokens currently available is displayed for you in this dashboard. More tokens will be added as time goes on.

Supplying ETH and BTC

To lend, you need to deposit some tokens you hold so that the SwayLend protocol will have your loan's collateral in place. It is used to recover whatever loan you have taken in case you were unable to repay.

Some ETH and BTC were deposited from my wallet into the protocol through the faucet.

Now that the portfolio has a balance of > $12,000 worth of assets, we can take out loans against it.

Borrowing with Collateral

To borrow, click on the borrow button at the right side of the dashboard and input the amount you want to borrow. Please note that the token to receive is denoted USDC.

There is a total amount possible to borrow. You can only borrow a significant amount of the value of your collateral’s worth and not the total. This measure is taken to prevent SwayLend from incurring bad debt.

In the Explorer

Once you perform an activity that is stored on-chain, that particular action can be reviewed on the Fuel explorer. The fuel network explorer is built to help you check if your transaction was successful or failed, the fees paid and more information that shows the validity of what was done in the transaction.

For those with technical knowledge, you can also retrieve the script byte code of the deployed smart contract.

Understanding Pools: https://priest.hashnode.dev/introducing-poolshark-protocol

Thanks for reading. Please follow us at https://twitter.com/gasprotocol for more educational content for the Fuel ecosystem.
(Cover Image Source: https://twitter.com/fuellabs_/status/1622642521858768907?s=20&t=du0tvDB4mEd0VMy03xt46Q)