Pedrojok01 / loyalty_contracts

Loyalty programs on-chain: Easily generate loyalty programs, distribute memberships, emit vouchers and keep track of your best customers!

Repository from Github https://github.comPedrojok01/loyalty_contractsRepository from Github https://github.comPedrojok01/loyalty_contracts

Loyalty - Smart Contracts

Stargazers Issues MIT License

Description

Initial Smart Contracts draft associated with the Loyalty project. Not to be used for production (yet!).

Compile:

Make sure to uncomment the following line in hardhat.config.js:

solidity: {
    settings: {
        viaIR: true,
    },
  },

then run:

yarn compile

Test:

yarn test

Slither-analyzer:

Slither is a Solidity static analysis framework written in Python 3. It runs a suite of vulnerability detectors, prints visual information about contract details, and provides an API to easily write custom analyses. Slither enables developers to find vulnerabilities, enhance their code comprehension, and quickly prototype custom analyses.

yarn slither

Coverage:

Make sure to comment the following line in hardhat.config.js:

solidity: {
    settings: {
       // viaIR: true,
    },
  },

then run:

yarn cover

Deploy:

yarn deploy

Left To Add:

  • Credits features
  • Limit number of promotions per tier (override exisiting promo)
  • Limit airdrop size per tier
  • Add interface support for Subscriptions
  • Add URI per vouchers in Redeemable?
  • Finish Non-Expirable & Collectibles promotions
  • Add Marketing / Referral / Partnerships features (array/mapping of promo/program?)

About

Loyalty programs on-chain: Easily generate loyalty programs, distribute memberships, emit vouchers and keep track of your best customers!

License:Other


Languages

Language:TypeScript 55.1%Language:Solidity 44.7%Language:JavaScript 0.2%