Smart Contact

The kurosawa_akira repository is a collection of Cairo smart contracts for our exchange.

Below is an overview of the various modules that make up the LayerAkira contract system. Each module plays a specific role in the functionality of the LayerAkira smart contract.

LayerAkira.cairo

  • Main contract module integrating various components

  • Includes functions for total supply, balance inquiries, Router operations, and trade validations

  • It combines user functions such as deposits, withdrawals, and nonce operations

DepositComponent.cairo

  • Handles deposit functionalities

  • Allows users to deposit tokens into the contract

ExchangeBalanceComponent.cairo

  • Manages our Exchange balance operations

  • Covers total supply, balance inquiries, gas info and fee recipient

NonceComponent.cairo

  • Manages nonce operations

Order.cairo

  • Defines the structure and operations related to orders

  • Includes details on fees, flags, and trade prevention modes (validators)

EcosystemTradeComponent.cairo & RouterTradeComponent.cairo

  • Handle the logic for executing Ecosystem trades and Router trades

WithdrawComponent.cairo

  • Handles withdrawal operations

RouterComponent.cairo

  • Manages routing functionalities

SignerComponent.cairo

  • Responsible for signature verification

FundsTraits.cairo

  • Provides utility functions.

  • Relates to Poseidon hashing and signature checks

Utils

  • Includes utility modules such as erc20.cairo, account.cairo, and SlowModeLogic.cairo

  • Covers ERC20 operations, account management, and trade execution delay logic

Last updated