Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allows the users to give their tag away #225

Closed
RiccardoM opened this issue Jul 14, 2020 · 5 comments · Fixed by #271
Closed

Allows the users to give their tag away #225

RiccardoM opened this issue Jul 14, 2020 · 5 comments · Fixed by #271
Assignees
Labels
kind/new-feature Propose the addition of a new feature that does not yet exist status/specification This feature is currently in the specification process x/profiles Module that allows to create and manage decentralized social profiles
Milestone

Comments

@RiccardoM
Copy link
Contributor

Feature description

Currently when the user creates a profile, his DTag is selected once initially and then it can never change. However, I think there might be some cases in which two users might agree on a DTag exchange, or one user might want to give away his DTag to another user.

An example could be a user registering the DTag microsoft initially, and then wanting to sell that DTag to the real Microsoft company later.

Implementation proposal

In order to implement this possibility, I think we can simply create a new message type, named maybe something like MsgTransferDTag formed as follows:

type MsgTransferDTag struct {
  CurrentOwner  sdk.AccAddress `json:"current_owner" yaml:"current_owner"`
  ReceivingUser sdk.AccAddress `json:"receiving_user" yaml:"receiving_user"`
}

Thsi message, when handled, would simply take the current DTag of the CurrentOwner and transfer it to the ReceivingUser. Also, if the ReceivingUser already has a DTag, such DTag will be transfered to the CurrentOwner, de-facto creating a mechanism by which two users can exchange their tags.

What do you guys think about this? @kwunyeung @bragaz

@RiccardoM RiccardoM added kind/new-feature Propose the addition of a new feature that does not yet exist status/specification This feature is currently in the specification process x/profiles Module that allows to create and manage decentralized social profiles labels Jul 14, 2020
@kwunyeung
Copy link
Contributor

This is a nice initiative which the DTag can become an exchangeable asset. One issue would be if a DTag is mentioned in a post content in the future but not only as addresses in media tagging? We need to handle that to reduce confusion and avoid linking to wrong profile.

@RiccardoM
Copy link
Contributor Author

@kwunyeung I've talked about tagging inside #226. I'll move the discussion there

@leobragaz
Copy link
Contributor

This would be a nice feature for DSM usage.
I'm wondering if we need an additional price field into the message that would be the dtag's price that users have decided off-chain (in the case that a user is selling his dtag to another).

@RiccardoM
Copy link
Contributor Author

RiccardoM commented Jul 15, 2020

I'm wondering if we need an additional price field into the message that would be the dtag's price that users have decided off-chain (in the case that a user is selling his dtag to another).

I've thought about this as well, but then decided to not include it inside the proposal just to make sure users can also exchange DTags without having to pay. Also, I thought that if a user wants to sell something to another user, he can simply ask the latter to send him some tokens with a simple MsgSend.

One other thing that comes to my mind right now is that we need a double-way confirmation for this kind of operation. If Alice wants to send her DTag to Bob, since Bob would send Alice his own, he needs to confirm this. So, aside from the proposed MsgTransferDTag message, we should also have a MsgAcceptDTagTransfer to make sure everything goes smoothly and both of the users agree on the exchange.

This double-way confirmation could also allow for expansion, such as including a payment:

  1. Alice sends a MsgExchangeDTag message to Bob.
  2. Bob wants some money for it, so he asks Alice to send him a MsgSend message with the amount.
  3. Once Bob receives the money, he sends a MsgAcceptDTagTransfer to confirm the operation.

Probably, this could also be further expanded in the future once we have smart contracting to make so that the selling of DTags has a super parts actor (the smart contract) that decides when to effectively exchange the DTags.

@leobragaz
Copy link
Contributor

Probably using cosmwasm in future a smart contract could handle the whole process.
Btw using these two steps seems the best solution now.

@RiccardoM RiccardoM added this to the v0.12.0 milestone Aug 31, 2020
@leobragaz leobragaz self-assigned this Sep 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/new-feature Propose the addition of a new feature that does not yet exist status/specification This feature is currently in the specification process x/profiles Module that allows to create and manage decentralized social profiles
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants