You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
You can see my Pull request for the PSP55 token here: #55.
The idea comes from the tokenized debt tokens that were introduced by Aave. These types of tokens possess a negative value in contrast to PSP22 tokens. The PSP55 standard is very similar to the PSP22 standard. Their storage is identical and they pose the same methods, as they both are fungible tokens. However. there is a VERY IMPORTANT difference between the two. Let me illustrate it in the following example:
Alice possesses PSP22 WDOT and she wants to transfer it to Bob. She can do that with no Bob allowance as she will transfer value to Bob. On the other hand, when Bob wants to transfer WDOT from Alice, he needs Alice's allowance. He needs it as he wants to take value from Alice for himself.
Alice possesses PSP55 SDOT which represents Alice's obligation to pay a debt she has taken in WDOT and which is collateralized by some asset in the loaner X contract. She wants to transfer this obligation to Bob who is also using X contract and possesses collateral there. This time when Alice transfers tokens she transfers NEGATIVE value to Bob, in other words, she transfers value from Bob to herself. Thus she needs allowance from Bob. On the other hand, when Bob transfers SDOT from Alice to himself, he is transferring negative value to himself, or in other words, he is transferring value to Alice.
Concluding, the only difference between PSP22 and PSP55 is the allowance requirement during transfer. For PSP22 transfers caller needs allowance from the user he is transferring !FROM!.
For PSP55 caller needs the allowance from the user he is transferring !TO!.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello,
You can see my Pull request for the PSP55 token here: #55.
The idea comes from the tokenized debt tokens that were introduced by Aave. These types of tokens possess a negative value in contrast to PSP22 tokens. The PSP55 standard is very similar to the PSP22 standard. Their storage is identical and they pose the same methods, as they both are fungible tokens. However. there is a VERY IMPORTANT difference between the two. Let me illustrate it in the following example:
Alice possesses PSP22 WDOT and she wants to transfer it to Bob. She can do that with no Bob allowance as she will transfer value to Bob. On the other hand, when Bob wants to transfer WDOT from Alice, he needs Alice's allowance. He needs it as he wants to take value from Alice for himself.
Alice possesses PSP55 SDOT which represents Alice's obligation to pay a debt she has taken in WDOT and which is collateralized by some asset in the loaner X contract. She wants to transfer this obligation to Bob who is also using X contract and possesses collateral there. This time when Alice transfers tokens she transfers NEGATIVE value to Bob, in other words, she transfers value from Bob to herself. Thus she needs allowance from Bob. On the other hand, when Bob transfers SDOT from Alice to himself, he is transferring negative value to himself, or in other words, he is transferring value to Alice.
Concluding, the only difference between PSP22 and PSP55 is the allowance requirement during transfer. For PSP22 transfers caller needs allowance from the user he is transferring !FROM!.
For PSP55 caller needs the allowance from the user he is transferring !TO!.
Beta Was this translation helpful? Give feedback.
All reactions