LogoLogo
WalletsEcosystemStart BuildingJoin the Community
  • Welcome to IoTeX 2.0
    • 💡Why IoTeX
    • 🪙Tokenomics
      • IOTX Utility in IoTeX 2.0
      • IOTX Emission, Deflation, and Re-Staking
    • 📖Whitepaper
    • ⚡Get Started
  • DePIN Infra Modules (DIM)
    • DIMs Overview
    • [IoTeX L1] DePIN Blockchain
      • Core Concepts
        • Consensus Mechanism
        • Voters and Delegates
        • Ethereum Virtual Machine
        • Accounts & Identities
        • Blockchain Actions
        • ERC20 and NFT Tokens
        • Smart Contracts
        • Interoperability
        • Governance
      • The IOTX Token
        • IOTX Token Exchange Support
        • Different Formats of the IOTX Token
        • IOTX Token Contracts
      • Wallets
        • Supported Wallet Apps
          • ioPay Mobile
          • IoTeX Web Wallet
          • OKX Wallet
          • Rabby Wallet
          • Metamask Desktop
          • Ledger Nano S & X
            • Use Ledger with Metamask
            • Use Ledger with Rabby Walet
            • Use Ledger with IoTeX Hub Portal
            • Migrate to the Ethereum Ledger App
          • IoTeX Desktop Wallet
          • 👩‍💻IoTeX HD Derivation Path
        • Buy IOTX Tokens
        • Execute Transactions
          • Transfer IOTX Tokens
          • Transfer ERC20 Tokens
          • Interact with Dapps
          • Explore transactions
        • Migrate Assets to a different wallet
      • Staking & Governance
        • About IoTeX Staking
        • IoTeX Staking Guide
          • Native staking
          • Staking as NFT
        • Join the Governance
          • Marshall DAO
          • Improvement Proposals
      • Exchange Integration
      • 👨‍💻Deploy Dapps on IoTeX
    • [ioID] DePIN Identities
      • ioID Specification
      • Overview of ioID
      • Registering Identities
      • 👩‍💻Integration Guide
        • Register a DePIN Project
        • Bind your Device NFT
        • Reserve Device ioIDs
        • Query Project Status
        • Register a Device
        • ioID Smart contracts quick reference
    • [W3bstream] DePIN Verification
      • Overview of W3bstream
      • Multi-Prover Architecture
      • 👨‍💻Build with W3bstream
        • Get Started
          • Sequencer Options
        • Build the Prover Code
          • Risc Zero
          • Halo2
          • zkWASM
        • Deploy to W3bstream
          • Create the Project File
          • W3bstream Outputs
          • Deploying Projects
          • Interacting with Projects
        • On-chain integration
          • Verify Risc0 Proofs
          • Verify Halo2 Proofs
          • Verify zkWASM profs
        • Sending Messages
      • 👩‍💻Node Operators
        • Configure a ZK Prover Node
        • Register your Node
    • [ioID-SDK] Hardware SDK
      • ioID-SDK Overview
      • Layered Architecture
      • Compatibility
      • Current Development Status
    • [MSP] Modular Security Pool
    • Third-Party DIMs
      • Data Sequencer Infras
      • Data Availability Infras
      • 👨‍💻W3bstream Tasks
  • Ecosystem
    • Assets on IoTeX
      • Mainstream Assets
      • IOTX and Derivatives
      • DePIN Tokens
      • MEME Coins
    • iotube Bridge
    • iotexscan Explorer
    • Ecosystem Apps
      • DePINScan
      • mimo DEX
      • ecosystem.iotex.io
    • "Powered by IoTeX" Devices
      • Pebble Tracker
        • Quick Start
        • Device Registration
        • Online Firmware Update
        • USB Firmware Update
        • Migrating to Pebble v2.0
          • 1.0 Device Registration
        • Tech Specs
        • Network Selection
        • Pebble Configuration
        • Query Pebble Data
        • Troubleshooting
        • Firmware Development
          • Hardware Setup
          • Build the Firmware
          • Flash the firmware
      • SenseCAP Indicator
      • UCam Home Camera
  • Builders
    • IoTeX Developer Portal
    • Dev Chat on Discord
    • Web3 Development
      • RPC Endpoints
      • Set up your Environment
      • Get Testnet IOTX Tokens
      • ioctl CLI
        • Installation
        • Create Accounts
        • Blockchain interaction
          • ioctl command reference
      • Chain Indexing
        • The Graph
        • SubQuery
        • IoTeX Analytics API
      • IoTeXscan API
      • Deterministic Deployment
      • Account Abstraction
        • Components of AA
        • 👩‍💻Creating new Accounts
        • 👨‍💻P256Account Example
      • Blob Transactions (EIP-4844)
      • Multicall3
      • EVM Precompiled Contracts
    • Building DePINs
      • ioID Step by Step Tutorial
        • Integrate ioID in the Device Firmware
        • Integrate ioID in your cloud
      • Decentralized WiFi Connectivity (DeWi)
        • Project Specification
        • The choice of Hardware
        • The Data API Service
        • DePIN Incentives Contract
    • Building DeFi
      • Deploy Tokens
        • Deploy an ERC20 Token
        • Deploy an NFT Token
      • Price Oracles
        • Chainlink Relayer
        • SupraOracles
      • Integrate IoTeX Staking
      • Liquid staking Dapps
    • Launch Dapps on IoTeX
      • Submit Tokens to the IoTeX Ecosystem
      • Submit tokens to the iotube bridge
      • Verify Smart Contracts
      • Audit your Contracts
      • Submit your Dapp to Portals
      • Useful tools
    • Node Operators
      • Fastblocks (Node as a Service)
      • Setup an IoTeX RPC Node
      • Run a Delegate Node
      • Rosetta API
    • Reference Docs
      • ioctl client
        • Accounts
        • HD Wallets
        • Aliases
        • Actions
        • Queries
        • Smart Contracts
        • Staking & Voting
        • Tokens
        • ioID Identities
        • W3bstream
        • Decentralized Identifiers (DID)
        • JWT Auth Tokens
      • Native IoTeX Development
        • IoTeX gRPC API
        • Account Cryptography
        • Address Conversion
        • Create Accounts
        • Estimate Gas Price
        • Make IOTX Transfers
        • Manage ERC20 Tokens
        • Smart Contract Interactions
        • ioPay Desktop
        • DID JWT Tokens
        • Calling any RPC method
      • Embedded Blockchain Clients
        • Arduino IDE
        • Linux Systems
        • PlatformIO
        • Examples
        • Tutorials
  • Participate
    • Crypto's Got Talent (CGT)
      • IoTeX x Polygon DePIN Grant
    • Governance
      • IoTeX Improvement Proposals
      • The Marshall DAO
    • Join the Community
    • Get in Touch
Powered by GitBook
LogoLogo

This documentation portal is currently undergoing updates to align with the IoTeX 2.0 Whitepaper release. Information provided here may be incomplete, or out-of-date. Please use this portal for preliminary reference only, and check out the official IoTeX 2.0 Whitepaper for updated information.

  • .

2025 | IoTeX

On this page
  • A closer Look at the W3bstream Project File
  • Explanation
  • Create a configuration for your project
  • Risc Zero provers
  • Halo2 Provers
  • zkWASM Provers

Was this helpful?

Export as PDF
  1. DePIN Infra Modules (DIM)
  2. [W3bstream] DePIN Verification
  3. Build with W3bstream
  4. Deploy to W3bstream

Create the Project File

A closer Look at the W3bstream Project File

The W3bstream project file includes all the necessary code and configurations for a W3bstream node to correctly serve your DePIN project with data computation and on-chain proof submission. When deploying a W3bstream project you are in fact deploying a project file and linking it to your Project ID in the W3bstream contracts.

Below is an example of a W3bstream project file:

{
  "defaultVersion": "0.1",
  "versions": [
    {
      "vmType": "risc0",
      "output": {
        "type": "stdout",
        "ethereum": {
          "chainEndpoint": "https://babel-api.testnet.iotex.io",
          "contractAddress": "0xDea7f9b692cb90a2DF1860189BcAc428500c44f1",
          "receiverContract": "0x22D5B41b28E7f9739a3D0C984737174cC7e554dF",
          "contractMethod": "submitProof",
          "contractAbiJSON": "[{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"seal\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"imageId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"postStateDigest\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"journal\",\"type\":\"bytes\"}],\"name\":\"submitProof\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]"
        }
      },
      "version": "0.1",
      "code": "789cecb3bc5acda85509c609e9..."
    }
  ]
}

Explanation

The W3bstream project file is in fact an array of configurations. Each configuration in the array allows you to define different settings for various provers and outputs, enabling flexibility in how W3bstream handles proofs and integrates with other components.

  • defaultVersion: The default version of the configuration to be used.

  • versions: An array of all available W3bstream configurations for the project. Each configuration includes:

    • vmType: The type of prover (e.g., halo2, risc0, zkwasm, with more types in the future).

    • output: Defines where the proof should be written.

    • version: The version number of this configuration.

    • code: The actual code of the prover if it's a ZK prover. Zlib compressed and hex encoded.

Create a configuration for your project

A W3bstream project file with a valid configuration can be easily generated using the ioctl CLI for various types of provers. After generation, the configuration can be manually finalized by adding receiver contract details, version numbers, and other necessary information.

Risc Zero provers

To generate a W3bstream project file for a Risc Zero prover using a Postgres database as the Data Availability (DA) Layer, use the following ioctl command:

ioctl ws project config \
    -t "risc0" \
    -s "postgres://test_user:test_passwd@localhost:5432/test?sslmode=disable" \
    -i "methods.rs" \
    -o "20000" \
    -e "{\"image_id\":\"RANGE_ID\", \"elf\":\"RANGE_ELF\"}"

Make sure to:

  • Configure DA Layer Credentials: Ensure the Postgres database credentials are correct.

  • Customize Project File Name: Change the project file name (e.g., 10001) as needed.

  • Match image_id and elf Fields: Ensure the image_id and elf fields in the command match the values in your methods.rs file.

Halo2 Provers

For a Halo2 prover, use the command below:

ioctl ws project config \
    -t "halo2" \
    -s "postgres://test_user:test_passwd@localhost:5432/test?sslmode=disable" \
    -i "pkg/halo2_simple_circuit_bg.wasm" \
    -c "20001"

zkWASM Provers

For a zkWASM prover, use the command below:

ioctl ws project config \
    -t "zkwasm" \
    -s "postgres://test_user:test_passwd@localhost:5432/test?sslmode=disable" \
    -i "zkwasm_demo.wasm" \
    -c "20002"

PreviousDeploy to W3bstreamNextW3bstream Outputs

Last updated 10 months ago

Was this helpful?

Customize File Paths: Set the path to your methods.rs file .

👨‍💻
appropriately