Capx
Search…
Capx Liquid
A decentralized platform allowing token creators, developers and token holders to create a "Smart Vesting Contract" to hold their ERC-20 Tokens for a specific period of time and provide them with a wrapped ERC-20 Token derived on the locked token.

Requirements

Truffle v5.4.12:

Truffle is a world-class development environment, testing framework, and asset pipeline for blockchains using the Ethereum Virtual Machine (EVM)

@truffle/hdwallet-provider ^1.5.0

HD Wallet-enabled Web3 provider. Use it to sign transactions for addresses derived from a 12 or 24-word mnemonic.

Node.js v16.13.0:

As an asynchronous event-driven JavaScript runtime, Node.js is designed to build scalable network applications.
@openzeppelin/contracts-upgradeable ^4.3.1
@openzeppelin/truffle-upgrades ^1.9.1
OpenZeppelin provides security products to build, automate, and operate decentralized applications. OpenZeppelin Contracts helps you minimize risk by using battle-tested libraries of smart contracts for Ethereum and other blockchains. It includes the most used implementations of ERC standards.

Smart Contracts

The current implementation of Capx liquid Architecture
Capx Architecture

Controller Contract

It will enable multiple parties to enter into a smart contract agreement and set specific payment parameters, i.e., vesting schedules for a project. It is responsible for the minting & burning of derivative tokens corresponding to various vesting times of a project while maintaining a lock for the project tokens. Each derivative is an ERC-20 Token. Only the controller can mint & burn the derivative tokens corresponding to a project.

Factory Contract

The recent network load on Ethereum has caused large and small teams to rethink and optimize their solidity and contract deployment architecture.
The Factory Contract uses EIP-1167 Minimal Proxy to deploy a minimal standalone contract that inherits all of the logic of a more significant deployed contract (in our case, ERC-20 Smart Contract). It creates ERC-20 Token clones (derivatives) from the model ERC-20 Smart Contract.

Model ERC20 Contract

A Model ERC20 token contract keeps track of fungible tokens, i.e., anyone token is precisely equal to any other token. No tokens have special rights or behavior associated with them. It makes the medium of exchange currency, voting rights, and staking more accessible.
It serves as the model contract for the Factory contract to create clones.

Code Repository

Graph

The Graph is an indexing protocol for querying networks like Ethereum and IPFS. Anyone can build and publish open APIs, called subgraphs, making data easily accessible.
Example query to fetch all the allocations made to an investor.
projects {
projectOwnerAddress
projectName
projectTokenAddress
projectTokenTicker
projectTokenDecimal
derivatives{
id
unlockTime
totalSupply
wrappedTokenTicker
holders (
where : {address_contains:"${account_address}", tokenAmount_gt: 0}
) {
tokenAmount
address
}
}
}
Copy link
On this page
Requirements
Truffle v5.4.12:
Node.js v16.13.0:
OpenZeppelin
Smart Contracts
Controller Contract
Factory Contract
Model ERC20 Contract
Code Repository
GitHub Repository
Graph