stellar / stellar-protocol

Developer discussion about possible changes to the protocol.
525 stars 303 forks source link

Credit based asset classes #422

Closed ChrisCates closed 3 years ago

ChrisCates commented 5 years ago

Description

Stellar currently allows assets to be sent or received via a debit-based system. An account can issue tokens to other accounts and these accounts can then transfer those tokens accordingly.

However, with a credit-based system. An issuer of a token can allow certain accounts to lend the token. This means, that they don't necessarily need to physically hold the token and are issuing tokens on credit. While this implementation could, in theory, be implemented by just issuing a separate asset that is "credit" based on the original asset.

Key features

Credit based lending system

Interest

Example

An issuer lends an account 100 gold tokens. The issuer has set an interest rate of 1% in XLM tokens every 100 blocks. After every 100 blocks are mined. The borrower owes the lender 1 XLM.

Collateral

Example

An issuer lends an account 100 gold tokens. The issuer requires collateral of 100 XLM tokens in exchange. The borrower must give 100 XLM tokens to receive the gold tokens. Once the borrower returns the gold tokens. They receive their 100 XLM tokens back.

Maturity

Issuers must allow assets to expire. And the asset issued can become worthless or illiquid after a certain period or date.

Example

An issuer lends an account 100 gold tokens. These gold tokens expire after 100 blocks. The account may trade the gold tokens any way they like, but, after 100 blocks. The gold tokens no longer hold value to the issuer.

Key Use Cases

Credit-based asset classes enable developers to use Stellar for additional use cases. This includes:

Note that there is additional scope required to make sure Options and Futures can function appropriately as an asset on Stellar. But a credit system acts as a foundation.

github-actions[bot] commented 3 years ago

This issue is stale because it has been open for 30 days with no activity. It will be closed in 5 days unless the stale label is removed, or a comment is posted.