PCL Precompile Address
The fixed, on-chain address for interacting with the Programmable Compliance Layer.
The PCL is implemented as a precompiled contract, which means it has a special, hardcoded address within the Maroo protocol. This address, 0x1000000000000000000000000000000000000005, is the single entry point for all interactions with the PCL, such as registering policies or simulating transactions. Using a precompile makes these operations highly efficient and a native part of the blockchain's execution environment.
Constant Address
The PCL precompile address is constant and unchanging across all Maroo networks (mainnet, testnets). It is defined as
PCL_PRECOMPILED_ADDRESS = 0x1000000000000000000000000000000000000005. Developers should use this constant address when creating contract instances to interact with the PCL.Solidity Interface
To interact with the PCL from a Solidity smart contract, you should import the
IPcl interface. The provided IPcl.sol file includes a convenient constant PCL_CONTRACT which is an instance of the interface already pointing to the correct precompile address. You can simply call functions on this constant: PCL_CONTRACT.runOnPcl(...).Client-Side Interaction
When using libraries like Ethers.js or Web3.js, you will use the precompile address as the contract address when initializing a contract object. You will need the ABI of the
IPcl interface and the address 0x1000000000000000000000000000000000000005 to make calls to the PCL from a frontend or backend application.