project screenshot 1
project screenshot 2
project screenshot 3

ClearSign DeFi

ERC-7730 files for 13 DeFi protocols - making smart contract transactions readable 🔍

ClearSign DeFi

Created At

ETHGlobal Cannes

Project Description

ClearSign DeFi is a comprehensive implementation of the ERC-7730 standard that transforms how users interact with DeFi protocols by making smart contract transactions human-readable and secure.

The project addresses a critical problem in DeFi: users often sign transactions without understanding what they're approving, leading to security vulnerabilities and poor user experience. Our solution provides ERC-7730 JSON files for 13 major DeFi protocols, enabling wallets to display clear, understandable information instead of raw transaction data.

Key Features:

  • 13 Major Protocols : Uniswap V2/V3, Aave V3, Compound V3, Curve, Balancer V2, 1inch, SushiSwap, PancakeSwap, Lido, Yearn, Convex, and MakerDAO
  • 60+ Smart Contract Functions : Comprehensive coverage of swaps, lending, staking, and liquidity operations
  • Multi-Chain Support : Ethereum, Polygon, Arbitrum, Optimism, BSC, and Fantom
  • Developer Tools : Automated validation, testing framework, and documentation
  • Security Focus : Clear transaction details help users avoid malicious approvals

Impact: This project directly improves DeFi security and accessibility by making complex transactions understandable to everyday users, potentially preventing millions in losses from unclear transaction signing.

How it's Made

Core Technologies:

  • ERC-7730 Standard : Official Ethereum standard for structured data display
  • Node.js & AJV : JSON Schema validation using the official ERC-7730 schema
  • JSONPath : For precise data extraction from transaction parameters
  • Multi-chain Architecture : Support for 6+ blockchain networks Technical Implementation:
  1. Schema Validation Pipeline : Built a robust validation system that fetches the official ERC-7730 schema from ethereum.org and validates all JSON files using AJV with custom configurations to handle schema reference issues.

  2. Smart Contract Analysis : Analyzed 13 major DeFi protocols to identify the most commonly used functions and their parameter structures, creating comprehensive field mappings for human-readable display.

  3. JSONPath Integration : Implemented sophisticated path expressions (e.g., $.path[0] , $.path[-1] ) to extract token addresses, amounts, and other critical data from complex transaction structures.

  4. Format Standardization : Standardized field formats across all protocols:

    • addressName : ENS-compatible address display
    • amount : Token amounts with proper decimal handling
    • date : Timestamp formatting with encoding parameters
    • raw : Direct value display for complex data Notable Technical Achievements:
  • Multi-Protocol Standardization : Created a unified approach for handling different DeFi protocol patterns while maintaining protocol-specific functionality.
  • Automated Validation : Built a comprehensive validation system that checks JSON syntax, schema compliance, and field format correctness across all 13 protocols.

Development Workflow:

  • Used pnpm for efficient package management
  • Implemented automated testing with pnpm run validate
  • Created modular file structure for easy protocol addition
  • Built comprehensive documentation and examples

Challenges Overcome:

  • Resolved complex schema reference issues in the ERC-7730 validation
  • Standardized diverse DeFi protocol patterns into consistent formats
  • Handled multi-chain deployment addresses and contract variations
  • Created human-readable labels for complex DeFi operations

This project represents a significant step toward making DeFi more accessible and secure for mainstream adoption by providing the infrastructure needed for clear transaction signing across the ecosystem.

background image mobile

Join the mailing list

Get the latest news and updates