Name Price24H (%)
Bitcoin (BTC)
Ethereum (ETH)
Cardano (ADA)
Timeswap: Decentralized Lending Without Oracles

Timeswap: Decentralized Lending Without Oracles

Written By: Ian Lee

Edited By: Charmyn Ho

An Overview

  • In this series, we take a look at the latest news, developments and innovations within the ever-changing decentralized finance (DeFi) space. We will dive deep into the nitty gritty details to better understand how protocols within the DeFi space work, the problems plaguing the ecosystem, as well as how builders intend to overcome them.

  • This week, we dive into Timeswap, a decentralized lending protocol with a novel twist. Read on as we take a look at its architecture, tokenomics, and protocol performance. 


In the month of October 2022, six exploits and/or hacks occurred across DeFi, resulting in over $700 million stolen. Two of these exploits were done via a price oracle attack, which involves oracle manipulation to extract funds from a protocol. The Mango Markets exploit drew a lot of attention as the attacker, Avraham Eisenberg, made no effort to obscure his identity and instead justified the exploit as a “profitable trading strategy”. These exploits have shown that protocols depending on price oracles are at risk of similar exploits, especially if liquidity is thin and attackers have sufficient capital to perform the exploit. 

Enter Timeswap. 

What is Timeswap?

Timeswap launched its V1 protocol in March 2022 as a decentralized money market protocol on Polygon. Since then, the protocol has originated over $1.1 million in loans and has seen over 6,000 unique users. The protocol allows borrowers to take out overcollateralized loans from liquidity provided by lenders and liquidity providers. 

Team and Backers

Timeswap was founded by Ricsson Ngo, Harshita Singh, and Ameeth Devadas. Ngo has a masters degree in applied financial mathematics, and is the brains behind the protocol while Singh and Devadas both have management experience in various industries. The rest of the core team are based in India, covering multiple disciplines such as design, development, and legal. 

In October 2021, Timeswap successfully raised a seed round (amount undisclosed) led by Multicoin Capital, with participation from Mechanism Capital and Defiance Capital. The protocol is also advised by Sandeep Nailwal and Jaynti Kanami, Co-founders of Polygon

How Timeswap Works

Timeswap introduces a novel 3 variable constant product automated market maker (AMM) system that allows users to lend and borrow assets without the need for oracles or liquidators (more on this later). Unlike most DeFi lending protocols which revolve around two key participants, i.e. lenders and borrowers, the Timeswap protocol has three key participants: 

  1. Lenders — Supply Token A to Liquidity Pool X in return for interest. 

  2. Borrowers — Supply Token B as collateral to the Liquidity Pool X to borrow Token A at fixed interest and maturity.

  3. Liquidity Providers — Supply an equal dollar amount of Token A and Token B to Liquidity Pool X, acting as market makers and making both lending and borrowing actions at the same time, incentivized by earning the spread between borrowers and lenders. 

3-Variable AMM 

Source: Timeswap

Drawing inspiration from Uniswap’s constant product (X * Y = K) pools, — Timeswap uses a novel 3-variable constant product equation, X * Y * Z = K, where: 

  • X = Principal Pool; a virtual pool equal to both the amount of assets deposited by lenders and the amount that can be borrowed.

  • Y = Interest Rate Pool; a virtual pool that determines the interest rate per second of the pool.

  • Z = Collateral Factor Pool; a virtual pool that determines the collateral needed to be locked by borrowers. Used to calculate the expected average loan value at time of transaction. 

  • K = Invariance Constant product

There are two additional pools:

  • C = Collateral Locked Pool; equal to the amount of collateral assets locked in the pool by borrowers

  • A = Asset Pool; equal to the amount of assets locked in the pool supplied by lenders plus debt paid by borrowers

Here’s how it would play out: 


Source: Timeswap

Simply put, the constant product, k, remains constant whilst the three variables can increase or decrease depending on which variables are adjusted. For example, when a user lends (adds) assets to the Principal Pool (X), the interest rate (Y) and amount of collateral a borrower needs to lock (Z) reduces. 

Lenders provide assets to liquidity pools for a fixed maturity in exchange for interest as well as tokens that represent their share of the pool and amount of insurance should the borrower default. Note that depending on the amount of default occurring in a particular pool, insurance may not be sufficient to make lenders whole. Thus, lenders should choose how much risk they want to undertake before supplying assets to the pool. 


Source: Timeswap

Borrowers borrow tokens at fixed interest rates and fixed maturity, locking in a minimum amount of collateral assets as determined by the AMM. When borrowers borrow (remove) assets from the Principal Pool (X), the interest rate (Y) and amount of collateral a borrower needs to lock (Z) increases. 

Since loans have a fixed maturity, borrowers do not need to worry about getting liquidated due to the price movement of their collateral assets — which also means that the protocol does not need to depend on price oracles. Should borrowers default after maturity, their collateral is distributed to lenders based on their insurance token holdings. 

Liquidity Providers

Liquidity providers act as market makers of the liquidity pools, earning a spread while facilitating transactions between lenders and borrowers and earning transaction fees in the process. Liquidity providers can also use their Timeswap LP tokens in other protocols for more yield farming on other protocols. Whilst the protocol could technically function without liquidity providers, this opens the door for more yield opportunities and strategies for users with different risk appetites. 

Recent Developments

On August 31, 2022, Timeswap announced its V2 protocol, which will bring about some changes to its borrowing and lending architecture, based on observations from the performance of their V1 protocol: 

  1. Lenders will soon be able to exit the pool anytime they want, instead of waiting till maturity of their lending position. Doing so results in some slippage, due to the fixed-term nature of the protocol. 

  2. Should borrowers repay their loan before maturity, the repaid assets will now be added back into the AMM, enabling them to be lent out again. This leads to increased capital efficiency for the protocol as well as for borrowers, since they only have to pay interest for the duration of their loan. 

  3. A new ERC-1155 token implementation will be used to represent positions of both lenders and borrowers, which allows for (1) to be possible, since in V1, borrowing positions were represented by ERC-721 tokens while lending positions were ERC-20, which meant that lenders and LPs could not exit the pool natively before maturity. 

  4. In V2, pools will become bidirectional, allowing lenders and borrowers to lend/borrow assets on either side of the pool. In V1, lenders could only lend token A and borrowers could only borrow token B from a Token A/Token B pool. 

  5. Lenders and borrowers will no longer be able to choose the collateralization ratio of a position. This provides a measure of safety for the protocol, as positions will always be overcollateralized. Thus, the AMM variables will be dictated by market supply and demand instead. The team also indicated that this allows the protocol to be “5x more efficient” than in V1. 

Final Thoughts

In terms of performance, Timeswap has originated over $1.1 million in loans and has seen over 6,000 unique users on its protocol since its launch in March 2022. As of the time of writing, Timeswap has around $160k in TVL, putting them in 13th place amongst other lending protocols on Polygon, significantly behind industry leaders such as Aave ($310 million), 0vix ($4.6 million), and dForce ($3.5 million). 

Unlike its competitors, however, Timeswap does not rely on price oracles due to its unique AMM architecture and fixed maturity loans. Although this reduces the risk of oracle exploits and results in higher yields for lenders on its protocol, lenders also take on a significantly higher risk of borrowers defaulting on their loans. The lack of token incentives also puts Timeswap at a disadvantage, which is made evident by their comparatively low TVL and loan originations. Although this may change in the future with the introduction of a protocol token, the team has yet to reveal news with regards to a launch of a token any time soon. 

While the impending launch of its V2 protocol does introduce some interesting changes to the protocol’s design, only time will tell if these changes can positively affect its performance. Thus, we look forward to seeing these changes and developments taking place. 

Disclosure: Members of Bybit may be invested in some or all of the tokens and projects mentioned within the following article. This statement discloses any conflict of interest and is not a recommendation to purchase any token or participate in any of the mentioned ecosystems. This content is purely for educational purposes only, and should not in any way be construed as investment advice. Please exercise caution and practice your own due diligence if you are planning to partake in any of these projects in any way. The views expressed in this article are that of the author(s) and do not represent the views of Bybit.

Source: Bybit Blog


Sign up to receive awesome content in your inbox, every day.

We don’t spam!


Cryptocurrency news, blockchain news, markets news, cryptocurrency analysis, cryptocurrencies prices.