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

Donation Referral #68

Open
vibern0 opened this issue Feb 17, 2022 · 4 comments
Open

Donation Referral #68

vibern0 opened this issue Feb 17, 2022 · 4 comments

Comments

@vibern0
Copy link

vibern0 commented Feb 17, 2022

The Problem

People make donations, but they don’t currently have a way to share that (unless sharing the explorer URL) and they also don’t have an incentive to make others donate.

The Solution We Are Looking For

Donation Referrals. It would simply be a referral link (eg: https://impactmarket.com/?donation=true&referral=0xfa521384f3e13970fb&msg=4). All that must be trustless (verifiable on-chain). This is achievable using signatures. So when a user makes a donation, in the end, wou<ld sign a message to share as a referral link. That message should contain only the epoch number where the user donated. The signature is a hashed string that can then be used to verify on-chain by whom it was signed.

Because signatures don’t expire, each referral link should be usable only X times.
For each donation made using the referral link, both the person who donated and the person who created the referral will be considered as if they have donated Y$ more for each Z$ donated.

Example:

Lets consider, for each $10 donated, both users get another $0.10 and a referral link can only be used twice.
Bob donates $20 and shares a referral link
Alice donates $12 using the referral and is considered has $12.10 for rewards
Maria donates $5 using the referral link, does not get extra, and does not subtract the number of usages of the referral link
Amir donates $21 using the referral and is considered has $21.20 for rewards
Yolanda donates $11 using the referral, but it has expired and does not get extra rewards

This only requires changes on donate and donateToCommunity methods on DonationMinerImplementation contract.

Requirements

  • Fork impactMarket repository and start working based on it (not from scratch)
  • Open a PR once finished (or during development in draft mode)
  • Tests (because it changes a existing contract, make sure you test migrations)

Definition Of Done

  • Number of usage of a referral link must be editable (through DAO proposal)
  • Donate to the treasury or community using referral and get extra rewards
  • A referral link should work considering a past epochs (not only current epoch)
  • All Tested

Milestones

  • Donation Miner Implementation contract changes (with tests)
@yasharpm
Copy link

Can Bob donate using his own referral link?
Can others who used the referral link, have a new referral link for their donation?

How much is the bounty?

@vibern0
Copy link
Author

vibern0 commented Apr 13, 2022

Hi @yasharpm

Can Bob donate using his own referral link?

Shouldn't be possible.

Can others who used the referral link, have a new referral link for their donation?

Do you mean, donating using a referral link and getting a referral link? Haven't thought of it. I'd say yes. The goal is o incentivize donations.

How much is the bounty?

Haven't decided anything. If you are interested, I can think of something and we can have a chat.

@yasharpm
Copy link

yasharpm commented Apr 13, 2022

Hi @obernardovieira

Do you mean, donating using a referral link and getting a referral link?

Yes

If you are interested, I can think of something and we can have a chat.

I am interested! It's interesting to me on multiple levels. Would be nice to have a chat to understand the requirement as well as possible to avoid wasted time.

@vibern0
Copy link
Author

vibern0 commented May 18, 2022

Can you please reach out to me on twitter or telegram @yasharpm? I use the same handle. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants