The Registry serves as a public on-chain record of all contracts deployed via the DecentSDK and as a point of entry for the Decent Cross-Chain Indexer, which aggregates data across all of the EVM-compatible chains to which the DecentSDK has been deployed. The data is available to be consumed by other indexers, or utilized on-chain by other smart contracts.
To begin we'll import the DecentSDK, chain configurations, and the Registry module.
Then we'll setup our signer (via wagmi/ethers) and create a new instance of the DecentSDK.
// Import SDK, chain configurations, and the Registry module
import { DecentSDK, chain, registry } from "@decent.xyz/sdk";
// Get the signer via wagmi or configure using ethers
// Setup the SDK with the desired chain and signer
const sdk = new DecentSDK(chain.goerli, signer);
Module Methods
query
Query the registry for all deployments by a specified deployer account.
getContract
Get an ethers contract instance of the Registry contract.
query
Query the registry for all deployments by a specified deployer account.
sdk (SDK)
An instance of the DecentSDK, configured with a chain and signer.
address (string)
The address of the deployer account.
getContract
Get an ethers contract instance of the Registry contract.
sdk (SDK)
An instance of the DecentSDK, configured with a chain and signer.