154 lines
4.3 KiB
Markdown
154 lines
4.3 KiB
Markdown
|
|
# Registration Commands - Complete All Integrations
|
||
|
|
|
||
|
|
**Date**: 2025-12-24
|
||
|
|
**Purpose**: Register all deployed contracts in their respective registries
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Contract Addresses
|
||
|
|
|
||
|
|
```bash
|
||
|
|
COMPLIANCE_REGISTRY=0xf52504A9c0DAFB0a35dEE0129D6991AA27E734c8
|
||
|
|
COMPLIANT_USDT=0xFe6023265F3893C4cc98CE5Fe7ACBd79DB9cbB2D
|
||
|
|
COMPLIANT_USDC=0x044032f30393c60138445061c941e2FB15fb0af2
|
||
|
|
TOKEN_REGISTRY=0x73EC4EbcA52EdfCf0A12746F3dFE5a9b7d6835d0
|
||
|
|
FEE_COLLECTOR=0x50f249f1841e9958659e4cb10F24CD3cD25d0606
|
||
|
|
```
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Step 1: Register in ComplianceRegistry
|
||
|
|
|
||
|
|
```bash
|
||
|
|
cd /home/intlc/projects/proxmox/smom-dbis-138
|
||
|
|
source .env
|
||
|
|
|
||
|
|
# Register CompliantUSDT
|
||
|
|
cast send 0xf52504A9c0DAFB0a35dEE0129D6991AA27E734c8 \
|
||
|
|
"registerContract(address)" \
|
||
|
|
0xFe6023265F3893C4cc98CE5Fe7ACBd79DB9cbB2D \
|
||
|
|
--rpc-url $RPC_URL \
|
||
|
|
--private-key $PRIVATE_KEY \
|
||
|
|
--legacy \
|
||
|
|
--gas-price 20000000000
|
||
|
|
|
||
|
|
# Register CompliantUSDC
|
||
|
|
cast send 0xf52504A9c0DAFB0a35dEE0129D6991AA27E734c8 \
|
||
|
|
"registerContract(address)" \
|
||
|
|
0x044032f30393c60138445061c941e2FB15fb0af2 \
|
||
|
|
--rpc-url $RPC_URL \
|
||
|
|
--private-key $PRIVATE_KEY \
|
||
|
|
--legacy \
|
||
|
|
--gas-price 20000000000
|
||
|
|
```
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Step 2: Register in TokenRegistry
|
||
|
|
|
||
|
|
```bash
|
||
|
|
cd /home/intlc/projects/proxmox/smom-dbis-138
|
||
|
|
source .env
|
||
|
|
|
||
|
|
# Register CompliantUSDT
|
||
|
|
cast send 0x73EC4EbcA52EdfCf0A12746F3dFE5a9b7d6835d0 \
|
||
|
|
"registerToken(address,string,string,uint8,bool,address)" \
|
||
|
|
0xFe6023265F3893C4cc98CE5Fe7ACBd79DB9cbB2D \
|
||
|
|
"Tether USD (Compliant)" \
|
||
|
|
"cUSDT" \
|
||
|
|
6 \
|
||
|
|
false \
|
||
|
|
0x0000000000000000000000000000000000000000 \
|
||
|
|
--rpc-url $RPC_URL \
|
||
|
|
--private-key $PRIVATE_KEY \
|
||
|
|
--legacy \
|
||
|
|
--gas-price 20000000000
|
||
|
|
|
||
|
|
# Register CompliantUSDC
|
||
|
|
cast send 0x73EC4EbcA52EdfCf0A12746F3dFE5a9b7d6835d0 \
|
||
|
|
"registerToken(address,string,string,uint8,bool,address)" \
|
||
|
|
0x044032f30393c60138445061c941e2FB15fb0af2 \
|
||
|
|
"USD Coin (Compliant)" \
|
||
|
|
"cUSDC" \
|
||
|
|
6 \
|
||
|
|
false \
|
||
|
|
0x0000000000000000000000000000000000000000 \
|
||
|
|
--rpc-url $RPC_URL \
|
||
|
|
--private-key $PRIVATE_KEY \
|
||
|
|
--legacy \
|
||
|
|
--gas-price 20000000000
|
||
|
|
```
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## Step 3: Verify Registrations
|
||
|
|
|
||
|
|
```bash
|
||
|
|
cd /home/intlc/projects/proxmox/smom-dbis-138
|
||
|
|
source .env
|
||
|
|
|
||
|
|
# Verify ComplianceRegistry registrations
|
||
|
|
cast call 0xf52504A9c0DAFB0a35dEE0129D6991AA27E734c8 \
|
||
|
|
"isContractRegistered(address)" \
|
||
|
|
0xFe6023265F3893C4cc98CE5Fe7ACBd79DB9cbB2D \
|
||
|
|
--rpc-url $RPC_URL
|
||
|
|
|
||
|
|
cast call 0xf52504A9c0DAFB0a35dEE0129D6991AA27E734c8 \
|
||
|
|
"isContractRegistered(address)" \
|
||
|
|
0x044032f30393c60138445061c941e2FB15fb0af2 \
|
||
|
|
--rpc-url $RPC_URL
|
||
|
|
|
||
|
|
# Verify TokenRegistry registrations
|
||
|
|
cast call 0x73EC4EbcA52EdfCf0A12746F3dFE5a9b7d6835d0 \
|
||
|
|
"isTokenRegistered(address)" \
|
||
|
|
0xFe6023265F3893C4cc98CE5Fe7ACBd79DB9cbB2D \
|
||
|
|
--rpc-url $RPC_URL
|
||
|
|
|
||
|
|
cast call 0x73EC4EbcA52EdfCf0A12746F3dFE5a9b7d6835d0 \
|
||
|
|
"isTokenRegistered(address)" \
|
||
|
|
0x044032f30393c60138445061c941e2FB15fb0af2 \
|
||
|
|
--rpc-url $RPC_URL
|
||
|
|
```
|
||
|
|
|
||
|
|
All should return `true` if registrations were successful.
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
## All-in-One Registration Script
|
||
|
|
|
||
|
|
```bash
|
||
|
|
cd /home/intlc/projects/proxmox/smom-dbis-138
|
||
|
|
source .env
|
||
|
|
|
||
|
|
# Set addresses
|
||
|
|
COMPLIANCE_REGISTRY=0xf52504A9c0DAFB0a35dEE0129D6991AA27E734c8
|
||
|
|
COMPLIANT_USDT=0xFe6023265F3893C4cc98CE5Fe7ACBd79DB9cbB2D
|
||
|
|
COMPLIANT_USDC=0x044032f30393c60138445061c941e2FB15fb0af2
|
||
|
|
TOKEN_REGISTRY=0x73EC4EbcA52EdfCf0A12746F3dFE5a9b7d6835d0
|
||
|
|
|
||
|
|
echo "Registering CompliantUSDT in ComplianceRegistry..."
|
||
|
|
cast send $COMPLIANCE_REGISTRY "registerContract(address)" $COMPLIANT_USDT \
|
||
|
|
--rpc-url $RPC_URL --private-key $PRIVATE_KEY --legacy --gas-price 20000000000
|
||
|
|
|
||
|
|
echo "Registering CompliantUSDC in ComplianceRegistry..."
|
||
|
|
cast send $COMPLIANCE_REGISTRY "registerContract(address)" $COMPLIANT_USDC \
|
||
|
|
--rpc-url $RPC_URL --private-key $PRIVATE_KEY --legacy --gas-price 20000000000
|
||
|
|
|
||
|
|
echo "Registering CompliantUSDT in TokenRegistry..."
|
||
|
|
cast send $TOKEN_REGISTRY "registerToken(address,string,string,uint8,bool,address)" \
|
||
|
|
$COMPLIANT_USDT "Tether USD (Compliant)" "cUSDT" 6 false 0x0000000000000000000000000000000000000000 \
|
||
|
|
--rpc-url $RPC_URL --private-key $PRIVATE_KEY --legacy --gas-price 20000000000
|
||
|
|
|
||
|
|
echo "Registering CompliantUSDC in TokenRegistry..."
|
||
|
|
cast send $TOKEN_REGISTRY "registerToken(address,string,string,uint8,bool,address)" \
|
||
|
|
$COMPLIANT_USDC "USD Coin (Compliant)" "cUSDC" 6 false 0x0000000000000000000000000000000000000000 \
|
||
|
|
--rpc-url $RPC_URL --private-key $PRIVATE_KEY --legacy --gas-price 20000000000
|
||
|
|
|
||
|
|
echo "✅ All registrations complete!"
|
||
|
|
```
|
||
|
|
|
||
|
|
---
|
||
|
|
|
||
|
|
**Last Updated**: 2025-12-24
|
||
|
|
|