Skip to content

codatta/Reputation-DID

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Reputation-DID

Script

Dependencies

  • nodejs

The recommended way to install node is using Node Version Manager (nvm).

Install nvm using the following command:

curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash

Restart your terminal and verify that nvm is installed:

command -v nvm

Next, use nvm to install node:

nvm install node

To verify that the installation was successful, check the Node version:

node --version

You should see output similar to the following:

v22.7.0

After install the node, you need to install the dependencies:

npm install

Run

Befor run the script you need to run:

mv .env.example .env

Replace PRIVATE_KEY to you own account private key.

Mint a DID

node scripts/main.js mint --name alice.reputation

DID name show ends with .reputation, and one address can only mint one DID.

Query Reputation

node scripts/main.js reputation --name alice.reputation

Stake token to increase reputation

node scripts/main.js stake -t 0x84132803A2519BafCCA883558A67A522795753C5 -a 1000000000000000000000

Currently only the support stake Tether USD and our test token MCK

  • MCK token Address: 0x84132803A2519BafCCA883558A67A522795753C5
  • Tether USD Address: 0x0fF5393387ad2f9f691FD6Fd28e07E3969e27e63

KYC provider

Currently, KYC requires the signature of the KYC provider before it can be added. There is no backend service for KYC service providers, so this scripts does not have an interface call for the time being.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published