LogoLogo
GithubAPIsJoin Research & DevelopmentWebsite
  • Openmesh
    • Openmesh Overview
    • Litepaper
      • Litepaper Link
      • Decentralisation Compromised
      • The Openmesh Solution
      • Principals & Governance
      • Openmesh's 10 Commandments
      • Core Innovation & Breakthroughs
      • Openmesh's Journey
      • Importance of Defining Web3
      • Investor Roadmap
      • Go To Market Milestones
      • OPEN Tokenomics
      • Governance & Transparency
      • Openmesh DAO
    • Openmesh Expansion Program
      • How to whitelist
      • How to perform asset transfer
      • Openmesh Expansion Program (OEP)
    • Project FAQs
    • Important Links
    • Getting Started Guides
    • App Templates
    • Use Cases
    • Advanced Templates
  • Products
    • Xnode
      • Xnode DVM
      • Xnode Studio
      • Link to Xnode Studio
      • XnodeOS
      • Basic Getting Started Guides
        • Buying your DVM from Opensea
        • Connecting your Web3 Wallet & Creating a Login Session
        • Redeeming Your DVM
        • Select Template via App Store
        • Deploy to DVM or Bare Metal
        • Monitoring Your Deployments
      • Template Deployment Guides
        • Deploy a Chainlink Data Dashboard
        • Deploying a Minecraft Server
      • Use-Case Deployment Guides
        • Deploying Ollama + Open WebUI App
      • Advanced Deployment Guides
        • Xnode NextJS Base Template
    • Xnode One
    • Openmesh Cloud
      • Openmesh Core
        • Openmesh Core - Github
      • Decentralized Service Mesh Protocol (DSMP)
      • Openmesh API
      • Pythia
    • Integrations
      • Chainlink CCIP
  • Open Source Initiatives
    • Contributions
    • OpenR&D
      • Open R&D Link
      • Vision
      • Problem Statement & Innovation
      • Task progression
      • Supported Chains
      • Glossary
      • Contact Us
      • Verified Contributors
        • OVC DAO
        • Departments
          • Dispute Department
          • Expert Department
      • Getting Started
        • Creating Tasks
          • Create a Task
            • Connect Wallet
          • Accept an application
          • Review a submission
          • Additional management
        • Perform Tasks
          • Apply to task
            • Edit Profile
          • Take a task
          • Create a submission
          • Dispute Resolution
      • FAQs
      • OpenR&D Smart Contracts
        • Tasks
        • Escrow
        • Task Drafts
Powered by GitBook
On this page
  • Initialize
  • Transfer
  • Auto-generated documentation
  1. Open Source Initiatives
  2. OpenR&D
  3. OpenR&D Smart Contracts

Escrow

Initialize

Code

```solidity
function __Escrow_init() external {
    if (owner != address(0)) {
        revert AlreadyInitialized();
    }

    owner = msg.sender;
}
```

Transfer

Inputs

Token: IERC20 (address); the ERC20 contract to transfer tokens of.

To: address; the address to transfer tokens to.

Amount: uint256; the amount of tokens to transfer.

Code

```solidity
function transfer(IERC20 token, address to, uint256 amount) external {
    if (msg.sender != owner) {
        revert NotOwner();
    }

    token.transfer(to, amount);
}
```

Last updated 7 months ago

Auto-generated documentation