Getting Started

Welcome to Virtual's Developers Portal! Virtual Rollups are a ZK state channel providing a seamless, gasless, and latency free user experience. Let's get started.

Integrate the Virtual Engine for Zero-Gas, Seamless Transactions:

The Virtual Engine is the core of our Company. State channels involve depositing capital into a smart contract, and trading the rights to this locked capital P2P. Because users form a private ledger, there are no gas costs, and finality occurs in milliseconds at the speed of your internet connection.

The Virtual Engine is blockchain's first ZK state channel which combines the powers of ZK (specifically Plonky2 + MuSig proofs) with state channels, which creates dynamic, multi-chain channels that allow your users to experience blockchain without additional cost, delay, or bad experience.

The Virtual Engine SDK can be integrated on any chain. The "catch" of zero-gas and zero-latency is not centralization. The Virtual Labs team is decentral-maximalist. All transactions within the ZK State Channel are P2P, and therefore zero-gas with streamlined UX, but setting up the ZK State Channel to eliminate double-spend does cost gas and blockspace.

Therefore, games and DEXs—dApps with recurring transactions—are prime use cases to benefit from ZK State Channels. This technology cannot be used for one-time swaps, however.

If you're a game or DeFi developer, integrating the Virtual Engine SDK will spin up Virtual Rollups that will save your users valuble time and money, increasing your dApp retention and engagment rates.

Even more, it's free and integrable in under an hour and available on 13 chains.

Integrate and try out now with the Virtual Engine SDK Developer Documentation.

Notice: on October 18th, Ontropy changed its name to Virtual Labs. Please allow some time for the cryptography libraries to be changed as well.

What is a Virtual Rollup and why does it matter?

A Virtual Rollup bundles transactions from multiple users to eliminate gas and latency. As opposed to optimistic or ZK rollups, Virtual Rollups have no nodes, validators, or sequencers. In a Virtual Rollup, these roles are fulfilled by the user. Each user verifies the transactions and orders the proofs. Because we require all users to agree to a transaction, transactions that occur over a Virtual Rollup are unilaterally fault tolerant and more secure than an ordinary blockchain transaction. For a high-level description, see the Virtual Rollups Overview section.

High Level Protocol Description

  • Rollup Initiation and Fund Locking: The protocol begins with the initiation of a rollup session by locking the desired amount of funds in a smart contract. These funds serve as buy-ins for games or the amount necessary for trading operations. Upon successful initiation, the protocol generates a unique Rollup ID, marking the start of a new session, and provides a list of participants.

  • Distributed Key Generation (DKG) Process: Participants involved in the rollup engage in a Distributed Key Generation process off-chain. Ephemeral keys linked to the users’ private key are generated. This step ensures secure and fair distribution of cryptographic keys among the players, essential for maintaining integrity and trust within the session. The DKG process involves the following steps:

    1. Accumulator Setup: A cryptographic accumulator is initialized, which acts as a data structure to efficiently store and verify a set of values.

    2. Accumulator Key Generation: Each participant generates a cryptographic key pair consisting of a private key and a corresponding public key.

    3. Participant Registration: Participants register their public keys with the accumulator, establishing their presence in the rollup session.

    4. BLS Signature Setup: The participants collectively generate a BLS signature key pair using a secure distributed protocol. This involves each participant contributing their private key share without revealing it to others.

  • Session Operations: Within the session, participants perform numerous operations, which can include generating multi-party randomness, placing bets, making game moves, executing trades, and more. These operations are conducted while maintaining the security and integrity of the rollup session. Operations are mostly performed off-chain with the use of the SDK. Fallback mechanisms are implemented on-chain to maintain security in the edge cases.

  • Zero-Knowledge Proofs (ZKPs): Zero-Knowledge Proofs are employed to validate the correctness of computations performed during the session. ZKPs ensure the truthfulness of each operation without revealing the underlying data, providing a layer of privacy while maintaining trust. SDK and the smart contracts implement all necessary ZK proofs in a highly secure and efficient fashion.

  • Balance Updates: As a result of the operations and computations performed during the session, participant balances, scores, states, etc., within the rollup's memory are updated accordingly. These updates reflect the progress and outcomes of the activities within the rollup session.

  • Session Signatures: Each stage of the rollup is authenticated by the signatures of each participant. This additional layer of trust and verification ensures the integrity of the session's progress and outcomes. Configurable BLS signatures are used.

  • Cash-Out Request: When a participant wishes to conclude their participation in the rollup session (known as "checking out"), they must submit a cash-out request. The participants collectively sign this request using a BLS signature method to indicate their agreement with the conclusion of the session. The cash-out request includes final balances, winnings, rewards earned, and any other relevant information from the session.

    1. BLS Signature Generation: Participants utilize a distributed signature technique to generate a BLS signature for the cash-out request. Each member contributes their respective private key share without disclosing it to others. These private key shares are combined using an algorithm to produce a single compact BLS signature.

    2. Signature Verification: The rollup protocol verifies the legitimacy of the cash-out request by checking the BLS signature. This ensures that the cash-out request is authorized and agreed upon by the participants.

  • Fund Unlocking: Finally, the user submits the signed cash-out request to the smart contract.

  • Edge Case Resolution: Protocol implements a number of safeguards to ensure user’s fund safety in case of the Rollup abandonment or other unexpected circumstance. Learn more in the Virtual Rollups Litepaper

That covers the protocol description. Next we walk through how to install the version of the SDK that you need.

Last updated