The source code of CoreID Name Domain Contracts.
This repo doubles as an npm package with the compiled JSON contracts
import {
CNS,
BaseRegistrarImplementation,
Web3RegistrarController,
PublicResolver,
ReverseRegistrar,
NameWrapper,
} from '@web3identity/cns-contracts'
// Registry
import '@web3identity/cns-contracts/contracts/cns/CNS.sol';
If your environment does not have compiler, you can access to the raw hardhat artifacts files at node_modules/@web3identity/cns-contracts/artifacts/contracts/${modName}/${contractName}.sol/${contractName}.json
The Registry contract is same with ENSRegistry.sol
.
yarn
npm run build
cp .env.example .env
Then edit .env
file. Set PRIVATE_KEY
to your private key.