Skip to content

All the blockchain related codes of Frak.id

License

Notifications You must be signed in to change notification settings

frak-id/frak-id-blockchain

Repository files navigation

frak-logo

Frak.id

Project license

solidity - v0.8.117

Test smart contracts

SafetinErc20 SafetinEcosystem MythXBadge

This repo contains the smart contract for the Frak.id plateform.

It uses hardhat for deployment and upgrades, and foundry for unit test.

Our Vision

Our vision is to give Creators the rightful place they deserve in society. The value has to be shared equally between those who create, those who fund and those who consume content. By empowering all these people to govern and to be rewarded for the value they create, whether that be through work, investment or engagement, the Frak ecosystem believes that Web3 is the ideal way to make that happens.

Installation

To install and build with Hardhat :

# Install
git clone https://github.com/frak-id/frak-id-blockchain.git
cd frak-id-blockchain/
pnpm i
# Build
pnpm run build
# Test
pnpm run test
forge test

To install with Foundry:

# Install
git clone https://github.com/frak-id/frak-id-blockchain.git
cd frak-id-blockchain/
# Build
forge build

Contracts

minter
├─ Minter"Mint new content, mint fraktions of content and increase fraktions supply"
├─ badges
│  ├─ FractionCostBadges"Small contract that store the cost badges of each fraktions"
reward
├─ Rewarder"Reward the user content consumption, from contentIds and CCU's"
├─ badges
│  ├─ ContentBadges"Small contract storing the badges for each content's"
│  ├─ ListenerBadges"Small contract storing the badges for each listener's"
├─ pool
│  ├─ ContentPool"Pool that split reward gain for each content between each investor's"
│  ├─ ReferralPool"Pool that split reward gain by each listener to each one of his referrer"
tokens
├─ FraktionTransferCallback"Callback interface for the transfer of content fraktions"
├─ FraktionTokens"ERC1155 storing all of our fraktions"
├─ FrakTokenL1"FrkToken on the ETH chain (for bridge purpose only)"
├─ FrakTokenL2"FrkToken on the Polygon chain"
wallets
├─ MultiVestingWallets"Contract that handle the vestings of multiple user's"
├─ VestingWalletFactory"Helping us with the creation of vestings following some defined criteria (initial drop, cliff etc)"
utils
├─ FrakRoles"All the roles we use in our contracts"
├─ FrakMath"Some math utils, to create fraktionId, or extract contentId from fraktionId."
├─ FrakAccessControlUpgradeable"Base access control contract used by every contract"
├─ MintingAccessControlUpgradeable"Reviewed access control contract, with more options for the minting part (so for token's and minter)"
├─ PushPullReward"Abtract contract that implement basic Push/Pull reward (we store reward amount, then the user withdraw it), helping us gain some gas"

Status

Contract name Status Audited Deployment
FrakToken Finalized 1 Proxy
FraktionTokens Finalized 2 Proxy
VestingWalletFactory Finalized 2 Proxy
MultiVestingWallets Finalized 2 Proxy
Minter Finalized 2 Proxy
Rewarder Finalized 2 Proxy
ContentPool Finalized 2 Proxy
ReferralPool Finalized 2 Proxy

Keep in touch

Home page

FAQ page

Medium Badge

Twitter Badge

Footnotes

  1. Safetin - ERC20

  2. Safetin - Complete 2 3 4 5 6 7