origin-js icon indicating copy to clipboard operation
origin-js copied to clipboard

Tool for vesting employee token grants

Open cuongdo opened this issue 7 years ago • 4 comments

At a minimum, this tool would need to:

  • Transfer tokens to a set of Ethereum address(es) for each employee, respecting each grant's vesting cliff and schedule
  • Help preserve privacy of each grantholder
  • Some sort of logging or way of reporting / verifying vesting-related actions
  • A dry run mode to show operations without actually performing them, as a sanity check

This could be implemented as a command-line JS tool that uses an input JSON file that contains grant information. The input file would be maintained by @joshfraser and/or @matthewliu to start.

cuongdo avatar Aug 01 '18 01:08 cuongdo

I've sketched out what I'm thinking:

vesting contract

The contract I have so far is here: https://github.com/OriginProtocol/origin-js/blob/cuongdo/token_vesting/contracts/contracts/token/TokenVesting.sol

Some tests are here: https://github.com/OriginProtocol/origin-js/blob/cuongdo/token_vesting/contracts/test/TestTokenVesting.js

cuongdo avatar Aug 28 '18 19:08 cuongdo

@nick @joshfraser any comments?

cuongdo avatar Aug 28 '18 19:08 cuongdo

This looks right to me. We may want to consider processing all the distributions on the same day of the month for added privacy, but that's an ongoing fight I'm having with @matthewliu.

It sounds like we'll need to keep a hot wallet on the server that is running the cron job to cover gas. Not a big deal given the amount at stake.

joshfraser avatar Aug 29 '18 00:08 joshfraser

Update: we've had some discussions, but nothing conclusive yet. Will continue to explore ideas but will postpone further implementation until mainnet launch is further along.

cuongdo avatar Aug 30 '18 00:08 cuongdo