Cobo Argus
(EN)
(EN)
  • Announcements
    • Cobo Argus V2 is Here! Supercharge Your DeFi Investments Today
  • Product Documentation
    • Account and Organization
      • Sign Up
        • Sign Up Using Web3 Wallet
        • Sign Up Using Email Address
      • Create Organization
        • Invite Team Member
        • Join Organization
      • Manage Account
        • Log In
        • Add Wallet Addresses for Logins
        • Add Email Address
        • Set Up 2FA
      • Manage Wallet Settings
    • Safe & Cobo Safe
      • Create Safe Wallet
      • Import Safe Wallet to Cobo Argus
      • Create & Enable Cobo Safe Module
      • Add Address
        • Team Members
        • Admin
    • Role-Based Access Controls
      • Authorization
        • Strategy Marketplace
        • Authorization Workflow
          • Modify Authorization
          • Remove Authorization
      • DeFi Operations (Delegated Members)
        • View Roles & DeFi Permissions
        • Complete DeFi Operations
      • Customized DeFi Permissions
        • Create Safe Role & DeFi Permissions
        • Delegate Role to Members
        • Complete Multisig Transaction
    • DeFi Bots
      • Strategy Bots
        • Farming Bots
        • Withdrawal Bots
      • Customized Bots
      • Webhook
        • Configuring Webhooks
        • How to connect Argus and Chainbot Webhook
        • Set up a webhook to monitor contract upgrades.
    • Token Approval
      • View Token Approval
      • Revoke Token Approval
      • Batch-Revoke Token Approval
      • Update Token Approval
    • What's New
  • Tutorials
    • Curve-Convex Authorization & DeFi Bots
    • Farming Bots-Equilibria Finance (EQB)
    • Farming Bots & Withdrawal Bots-BendDAO
    • Rabby Wallet
    • Customized Bots-DAI
    • How to Manage Automated Leverage on Cobo Argus
    • Cobo Argus Claiming Bot automatically claims Pendle minings rewards!
  • Cobo Safe Technical Documentation
    • Cobo Account
      • Cobo Safe Account
      • Cobo Smart Account
      • Send Transactions
    • Role Manager
    • Authorizer
      • Authorizer Example
      • BaseACL
      • Other Authorizers
    • Cobo Argus
      • Workflow
    • Security Audit
    • Deployed Smart Contracts
Powered by GitBook
On this page
  1. Cobo Safe Technical Documentation
  2. Cobo Account

Cobo Smart Account

Cobo Smart Account is a simple smart contract wallet for storing digital assets and sending transactions.

The Account Address of a Cobo Smart Account will be the address of the underlying smart contract.

Cobo Smart Account sends transactions using call and delegatecall as follows:

contract CoboSmartAccount is BaseAccount {
    /// @dev Perform a call directly from the contract itself.
    function _executeTransaction(
        TransactionData memory transaction
    ) internal override returns (TransactionResult memory result) {
        address to = transaction.to;
        uint256 value = transaction.value;
        bytes memory data = transaction.data;
        if (transaction.flag.isDelegateCall()) {
            // Ignore value here as we are doing delegatecall.
            (result.success, result.data) = address(to).delegatecall(data);
        } else {
            (result.success, result.data) = address(to).call{value: value}(data);
        }
    }

    /// @dev The contract itself.
    function _getAccountAddress() internal view override returns (address account) {
        return (address(this));
    }
}
PreviousCobo Safe AccountNextSend Transactions

Last updated 1 year ago