The Read Contract Tab enables users to access and query the contract's read-only functions to fetch data directly from the blockchain. These functions are used to retrieve information without making any changes to the blockchain, meaning no tokens or gas fees are required.
FR 11.007.1a: Wallet Connection
Allows users to securely connect their wallet to the interface. Although read-only functions don’t require gas or tokens, wallet integration ensures secure and authenticated interactions with the contract.
FR 11.007.1b: Contract Information
Public Functions: Displays a list of all publicly accessible read functions within the contract. These functions provide data such as balances, token details, or contract status.
Expandable Functions: Each function is listed with its name (e.g., _verifyTransfer). Users can expand any function to view input fields or directly execute a query to retrieve outputs.
Inputs and Outputs: Some functions may require input parameters (e.g., wallet addresses) to fetch specific data. The output provides the requested information in real time.
The Contract Tab provides detailed technical information about a smart contract, enabling users to analyze its functionality, verify its integrity, and explore its components. This tab is divided into the following sections:
FR 11.007a: Compiler Details This section displays information about the contract’s compilation and verification process:
Verification Status: Indicates whether the contract is partially or fully verified.
Contract Name: The identifier for the contract (e.g., TICS).
Compiler Version: Specifies the Solidity compiler version used for the contract (e.g., v0.8.20).
Optimization Enabled: States whether optimization was applied during compilation (e.g., False).
Optimization Runs: The number of optimization runs performed (e.g., 200).
Verified At: The date and time when the contract was verified (e.g., 23rd Jul 2024, 15:29:17).
FR 11.007b: Compiler Messages Displays warnings, errors, or recommendations generated during the compilation process:
Examples include missing SPDX license identifier warnings, unused declarations, or best practice suggestions.
Helps developers understand potential issues or areas for improvement in the code.
FR 11.007c: Contract Source Code Shows the Solidity source code of the contract:
Developers can review the code to understand its logic, methods, and structure.
Includes key elements such as imports, state variables, functions, and event definitions.
Helps users verify the contract’s functionality and compliance with coding standards.
FR 11.007d: Contract ABI The ABI (Application Binary Interface) defines how external applications or users can interact with the contract:
Lists available functions, their names, and input/output parameters.
Includes definitions for events triggered by the contract.
Provides the necessary interface for wallets, dApps, and other integrations.
FR 11.007e: Contract Creation Code Displays the bytecode used to deploy the contract:
Useful for developers, auditors, and validators who want to verify the contract’s deployment data.
Ensures that the contract was deployed as intended without tampering or errors.
The Write Contract Tab allows users to perform state-changing actions on a smart contract, such as transferring tokens, updating settings, or triggering specific operations. These interactions modify the blockchain's state and require wallet authorization.
FR 11.007.2a: Wallet Connection
Users must connect their wallet to execute write functions. This ensures secure interactions, allows authentication and facilitates the payment of gas fees required for the transaction.
FR 11.007.2b: Contract Information
Callable Functions: The tab lists all available write functions within the smart contract (e.g., batchTransferETH). These methods enable users to make changes to the blockchain's data.
Expandable Functions: Clicking on a function name expands it to reveal input fields and options for user interaction.
Input Fields: Each function displays the required inputs (e.g., wallet addresses, token amounts) that users must provide to execute the operation.
FR 11.007.c: Executing Transactions
Execute Button: Once all input fields are completed, users can click the Execute button to initiate the transaction. This will prompt the connected wallet for confirmation.
Gas Fees: Executing write functions incurs gas fees. The estimated fee is displayed in the wallet confirmation screen, ensuring users are aware of the cost before approving the transaction.