pull down to refresh

Building Lendasat on ARK - Introducing DLC VTXOs

At Lendasat we are building p2p, instant Bitcoin-collateralized loans using regular Lightning payments.
The key requirements we have given ourselves are the following:
  • As simple as paying a Lightning invoice.
  • Self-custodial.
  • Bitcoin only.
Doing this on-chain would be prohibitively expensive and inefficient, so we evaluated the following L2 solutions.
ARKFedimintLightningDLC Channels
Smart contractsNoYesNoYes
Liquidity requirementsMediumLowHighHigh
CustodySelf-custodialFederationSelf-custodialSelf-custodial
Online requirementsEvery 2 weeksn/aEvery dayEvery day
None of the solutions considered fit our requirements on their own, but we quickly got very excited about the idea of lifting DLCs onto ARK, thus combining the benefits of ARK (reduced liquidity requirements) and DLCs (smart contracts).
As mentioned before, the use case we are focusing on is collateralized loans. In short, the user journey would look something like this:
  1. Borrower gets a Lightning invoice e.g. from Bitrefill.
  2. Borrower shares the invoice with Lendasat; borrower gets a collateral invoice from Lendasat.
  3. Borrower pays the collateral invoice and in turn a lender pays the Bitrefill invoice.
In the background, the loan collateral is locked up in a DLC VTXO, the new construct we present here.
Before we continue, we’d like you to know that the rest of this post assumes some knowledge of DLCs and ARK. Also, keep in mind that everything you read here is still work in progress, so take it with a grain of salt.

How to take a loan

To take a loan, the borrower first lifts bitcoin to Ark via a Lightning payment, for an amount that will cover the required collateral.
Once the borrower has their own VTXO, they can work with the lender to set up the DLC VTXO. The DLC VTXO is a virtual multisig output that will be owned by lender and borrower. Before signing the transaction that creates the DLC VTXO, both parties collaborate to presign a bunch of CETs spending from the DLC VTXO, like we do for regular DLCs.
One key difference is that the lender CET outputs do not pay directly to a lender-owned address, but to a HTLC locked with the same r_hash from the borrower’s invoice. If the lender pays the borrower’s invoice and learns the preimage, they will be able to claim their CET outputs. Otherwise, the borrower will be able to claim the funds after a timeout.

How to repay a loan

While both parties can unilaterally close the loan contract on-chain, it’s always preferable to collaborate. In the cooperative scenario, lender and borrower forfeit their claim on the collateral locked up in the DLC VTXO under the condition that Lendasat pays them back: the loan plus interest to the lender, and the collateral to the borrower.
We need to ensure that the exchange of ownership is atomic, so the DLC forfeit transaction is constructed in such a way that Lendasat can only claim the funds with knowledge of the preimages to the Lightning payments to borrower and lender.

Outro

This is what we’ve got for today. There is certainly a lot to be done to make this happen, but we are excited about it and hope you are too.
Let us know what you think and check us out at https://www.lendasat.com if you want support us and learn more about the tech and the use case.
“Don’t sell your Bitcoin!”
Lendososhi Satamoto
13 sats \ 1 reply \ @grayruby 9 Jul
What's the collateral requirement?
reply
That will depend on the LTV ratio. For example for a LTV ratio of 50% you'd have to put up a btc collateral worth of 150$ for a $75 loan.
reply
I am sorry for probably a stupid question, does it mean that I can borrow sats while giving a collateral in sats? Why would I do that and why not simply pay that invoice directly? Who earns what?
reply
I assume for tax purposes, though I doubt its going to fly
reply
Say you want to purchase something, but don't want to sell your bitcoin. And you expect bitcoin to rise in value.
Using a lending platform allows you to use that bitcoin as collateral to get funds now. Do the purchase of the thing.
Then once bitcoin value goes higher, you pay off the loan with the bitcoin in the collateral. Or you pay back the borrowed amount with other funds. Effectively using smaller percentage of bitcoin or none at all for the original purchase.
You also avoid capital gains tax on such a scenario. As when you get the borrowed funds, it doesn't hit capital gains.
reply
Well, I understand borrowing/lending principle. But thats when fiat is involved. Here, I understand, I borrow sats for sats... This is what I dont get.
reply
So this works for just sats too. Nothing stops a loan utilizing collateral as same as borrowed. Though it tends to be less efficient, you can still do so.
Interesting part is that you may use this better when market is losing value. So you pay off by buying into bitcoin when value depreciates and you still don't sell your original bitcoin.
reply
Just to clarify, as it might be confusing from your comment.
Using a collateralized loan on your Bitcoin makes sense when you think that the btc/usd price is going to appreciate in the next months, years. (if you are bullish). Because you will have to pay back your dollar loan at the market price at a later point in time.
Let's say today the btc price is at $65K, and you want to buy a new pair of shoes for $81. Today you'd have to pay ~125K sats for that. Assume the bitcoin price would appreciate to $100K you'd only have to pay ~85K sats.
With lendasat you can take a loan on the $81 and pay back $81 when the btc price is right.
reply
Right, that's what I stated originally when speaking of different collateral to debt.
But when loan is the same debt as collateral, the relationship is reverse. So if you take a loan for bitcoin and get bitcoin back, you would use this for when market is in a downturn.
That said, lendasat site doesn't seem to indicate what you receive is a synthetic dollar using DLC instead of direct sats itself. Or maybe just wasn't clear to myself. 😅
reply
You do not receive a synthetic dollar.
Your Lightning invoice is paid instantly with Bitcoin, and you pay back later with Bitcoin, but in dollar terms.
reply
Understood. Then what would be the base denomination representation of the DLC dollar?
An inverse derivative locked contract like stablesats and what kollider built before is what I thought would be the base representation. Which means it would be a synthetic dollar.
Do you have any documentation explaining this portion of the contract and how you are attributing the derivative to make dollar representation?
So this works for just sats too.
How so? If bitcoin appreciates in value, both debt and collateral increase in value cancelling each other.
Unless you borrow and repay some USD-denominated amount of bitcoin. That would make more sense. And it is probably something like it, since we have an oracle in the system.
reply
Unless you borrow and repay some USD-denominated amount of bitcoin. That would make more sense. And it is probably something like it, since we have an oracle in the system.
Yes, this is how it works. The loan you take is USD-denominated meaning the exact sats amount will vary.
reply
We are all here to learn. No stupid questions. If someone says it’s a dumb question then he can provide a response
reply
That's right!
reply
Thanks for the information. Let me first grow my sats. I'll ask you then. I've just bookmarked it.
reply
Do you see any use case for this? Can you hint or explain? Because I have no idea how can this service be useful no matter how many sats do you own...
reply
Juraj Bednár wrote about that topic already. I can recommend to look up his work on "How to harness the value of Bitcoin without having to sell it"
The principle idea though is very simple. Today the bitcoin price is at $65,000. So if you wanted to buy a new chair for $780 you'd have to pay ~1,2M sats. Now, if the btc price would appreciate to $90,000, you'd only pay ~866K sats.
With lendasat you can buy the new chair today, and pay back later. e.g. when the price is right for you. e.g. at $90,000. You'd only have to pay back 866K sats + interest for the loan and would get back your original collateral.
reply
This would work if you as a service denominate the loan in USD and not in sats. Right? Otherwise, it works vice-versa and I would overpay that chair a lot.
reply
You lock your bitcoins as collateral, and we pay your invoice!
You then repay us in bitcoins, but based on the USD price of your item at the time of repayment!
reply
Are you familiar with Ledn?
reply
Thanks for sharing, we didn't know ledn before, but from a quick look at it, it seems to be a custodial solution from which you can get a dollar loan within 24 hours.
The idea of lendasat is to directly pay your lightning invoices and thus give you an instant collateralized loan. So the loan would be issued within seconds not hours.
Furthermore, lendasat is designed to be non-custodial, meaning that you have a unilateral out if there is a dispute. We achieve that by making use of DLCs and a price oracle. see also https://www.lendasat.com
This is a Bitcoin-only product, so no fiat or stable coin involved.
reply