Skip to main content

Source Code

View the RWAToken.sol source code
UpgradabilityThis contract uses the UUPSUpgradeable pattern and inherits from ERC20Upgradeable, OwnableUpgradeable, and PausableUpgradeable.

Methods

Initialization function for the upgradeable contract. It sets token parameters, the custody wallet, the USDT reference contract, and the compliance manager.
string
required
Token name
string
required
Token symbol
address
required
Initial owner
address
required
Custody wallet
address
required
USDT contract address
address
required
Compliance manager address
Configures sale parameters, including token price and purchase limits.
uint256
required
Token price in USDT
uint256
required
Minimum purchase amount in USDT
uint256
required
Maximum purchase amount in USDT
Configures the sale start and end time constraints without changing the sale’s active status.
uint256
required
Start timestamp
uint256
required
End timestamp
Activates token sales. Sale time constraints are enforced during minting.
Pauses an ongoing token sale.
Sets the earliest timestamp at which tokens become transferable (0 means unlocked).
uint256
required
Unlock timestamp
Emergency unlock mechanism that immediately allows token transfers.
Emergency function that pauses all token transfers.
Resumes all token transfers.
Updates the custody wallet address that receives raised funds.
address
required
New custody wallet address
Recovers unsold tokens from the sale and mints them to the custody wallet.
Recovers any ERC20 tokens that were accidentally sent to this contract.
address
required
Token contract address to recover
Executes a forced token transfer for compliance or recovery purposes.
address
required
Sender address
address
required
Recipient address
uint256
required
Transfer amount
string
required
Reason for the transfer
Updates legal and valuation information for the underlying real-world asset.
string
required
Metadata URI
uint256
required
Valuation
Purchases tokens with USDT during an active sale and verifies the user’s compliance signature.
uint256
required
Amount of USDT paid
bytes
required
Compliance signature payload
uint256
required
Signature expiration time
Owner-only function that burns tokens from a specific address for compliance or recovery purposes.
address
required
Address whose tokens will be burned
uint256
required
Amount to burn
Returns the remaining number of tokens available for sale.
uint256
Remaining number of tokens available for sale
Calculates how many tokens can be minted for a given USDT amount.
uint256
required
USDT amount
uint256
Equivalent token amount
Calculates the USDT amount required for a given token amount.
uint256
required
Token amount
uint256
Required USDT amount