# GenLayer Documentation > GenLayer is the first Intelligent Blockchain — a DLT capable of nondeterministic operations through dynamic consensus, enabling smart contracts ("Intelligent Contracts", written in Python) to natively access the Internet, call LLMs, and make subjective decisions. Consensus over nondeterministic results is reached through Optimistic Democracy and the Equivalence Principle. Instructions for AI agents and LLMs: - Every page below links to its raw markdown version. You can also append `.md` to any docs URL (e.g. https://docs.genlayer.com/developers/intelligent-contracts/introduction.md). - The complete documentation in a single file: https://docs.genlayer.com/llms-full.txt (omits the per-command CLI pages). Section-scoped bundles: https://docs.genlayer.com/understand-genlayer-protocol/llms-full.txt, https://docs.genlayer.com/developers/llms-full.txt, https://docs.genlayer.com/validators/llms-full.txt, https://docs.genlayer.com/api-references/llms-full.txt (includes the full CLI command reference). - To build Intelligent Contracts or run a validator with AI assistance, install the GenLayer Skills plugin for Claude Code: https://skills.genlayer.com/ - Key entry points: "What is GenLayer" for concepts, "Your First Contract" for development, "Setup Guide" for validators, "GenLayerJS" for dApps. ## Overview - [The Adjudication Layer for the Agentic Economy](https://docs.genlayer.com/index.md): GenLayer is the adjudication layer for the agentic economy: decentralized AI-validator consensus for contracts that require judgment, not just code. ## Discover the Protocol - [Discover the GenLayer protocol](https://docs.genlayer.com/understand-genlayer-protocol.md): Understand GenLayer architecture, Intelligent Contract execution, Optimistic Democracy, transactions, and protocol economics. - [What is GenLayer?](https://docs.genlayer.com/understand-genlayer-protocol/what-is-genlayer.md): GenLayer is an intelligent blockchain for applications that need consensus on subjective, web-connected decisions. - [How GenLayer works](https://docs.genlayer.com/understand-genlayer-protocol/optimistic-democracy-how-genlayer-works.md): Follow an Intelligent Contract transaction through GenLayer Chain, GenVM execution, validator consensus, appeals, and finality. - [Use cases](https://docs.genlayer.com/understand-genlayer-protocol/typical-use-cases.md): Explore use cases where GenLayer can resolve shared outcomes from natural language, public evidence, and subjective criteria. - [Core concepts](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts.md): Explore GenLayer architecture, execution, consensus, transactions, accounts, and protocol economics. - [GenLayer Chain integration](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/rollup-integration.md): Learn how GenLayer Chain, its consensus contracts, validator nodes, GenVM, and Ethereum settlement fit together. - [Accounts and addresses](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/accounts-and-addresses.md): Understand GenLayer EOAs, EVM contracts, Intelligent Contracts, Ghost contracts, addresses, and transaction queues. - [GenVM](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/genvm.md): GenVM is GenLayer's WebAssembly sandbox for deterministic and non-deterministic Intelligent Contract execution. - [Non-deterministic operations](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/non-deterministic-operations-handling.md): Learn how GenLayer contains variable web and LLM outputs and reaches consensus on their meaning. - [LLM integration](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/large-language-model-llm-integration.md): Learn how Intelligent Contracts use LLMs and how validators assess model-generated results. - [Web access](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/web-data-access.md): Learn how Intelligent Contracts retrieve web content and validate time-varying external data without a single oracle. - [Validators and roles](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/validators-and-validator-roles.md): Learn how GenLayer selects activators, leaders, and committee validators for each Intelligent Contract transaction. - [Optimistic Democracy](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy.md): Optimistic Democracy coordinates leader proposals, validator votes, appeals, and finality for Intelligent Contracts. - [Equivalence Principle](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy/equivalence-principle.md): The Equivalence Principle lets validators accept non-identical outputs when they satisfy an Intelligent Contract's validation rule. - [Appeals](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy/appeal-process.md): Learn how validator appeals and leader appeals challenge GenLayer consensus decisions. - [Deterministic Violations & Tribunals](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy/deterministic-violations-and-tribunals.md): How Consensus v0.6 records deterministic disagreement, freezes a tribunal electorate, and applies judicial restrictions and slashing. - [Protocol Randomness](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy/protocol-randomness.md): How Consensus v0.6 advances per-recipient randomness with ECVRF proofs and uses it for validator selection. - [Finality](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy/finality.md): Learn when a GenLayer Intelligent Contract transaction becomes final and how the appeal window affects application state. - [Staking](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy/staking.md): Learn how validator self-stake, delegation, selection weight, epochs, and validator keys work in GenLayer. - [Slashing and validator penalties](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy/slashing.md): Learn how GenLayer handles validator idleness, failure to reveal, deterministic violations, quarantine, bans, and stake penalties. - [Unstaking](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/optimistic-democracy/unstaking.md): Learn how GenLayer validator and delegator exits move through epoch processing and the unbonding period. - [Transactions](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/transactions.md): Understand the EVM submission and protocol transaction that make up an Intelligent Contract call in GenLayer. - [Transaction types](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/transactions/types-of-transactions.md): Distinguish ordinary EVM transactions from Intelligent Contract deployments, calls, and messages in GenLayer. - [Transaction execution](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/transactions/transaction-execution.md): Follow a GenLayer transaction through activation, leader execution, commit-reveal voting, appeals, and finalization. - [Transaction statuses](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/transactions/transaction-statuses.md): Reference all GenLayer Intelligent Contract transaction statuses and their numeric codes. - [Encoding, signing, and submission](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/transactions/transaction-encoding-serialization-and-signing.md): Learn how an Intelligent Contract request becomes signed EVM calldata and a GenLayer consensus transaction. - [Economic model](https://docs.genlayer.com/understand-genlayer-protocol/core-concepts/economic-model.md): Learn how GenLayer fees, appeal bonds, staking rewards, and penalties fund consensus and align participants. ## Build on GenLayer - [Getting Started with GenLayer](https://docs.genlayer.com/developers.md): Start building on GenLayer: write Intelligent Contracts in Python, develop dApps with the JS and Python SDKs, and deploy to Studio, testnet, or localnet. - [Networks](https://docs.genlayer.com/developers/networks.md): GenLayer network environments and connection details: testnet, Studio, and localnet RPC endpoints, chain IDs, and wallet configuration. - [Consensus v0.6 Migration](https://docs.genlayer.com/developers/consensus-v06-migration.md): Migrate applications and tooling to the Consensus v0.6 and Studio v0.123 release family. - [Introduction to Intelligent Contracts](https://docs.genlayer.com/developers/intelligent-contracts/introduction.md): Intelligent Contracts are Python smart contracts on GenLayer that access the web and call LLMs natively, enabling judgment-based decisions on-chain. - [When to Use GenLayer](https://docs.genlayer.com/developers/intelligent-contracts/when-to-use-genlayer.md): GenLayer use cases: decide when to use Intelligent Contracts for on-chain judgment, evidence, and neutral consensus. - [Intelligent Contract Features](https://docs.genlayer.com/developers/intelligent-contracts/features.md): Intelligent Contract Features lists deterministic and non-deterministic capabilities for GenLayer Intelligent Contracts. - [Storage Quick Reference](https://docs.genlayer.com/developers/intelligent-contracts/features/storage.md): Quick reference for GenVM storage types: primitives, collections, and custom classes. - [Error Handling](https://docs.genlayer.com/developers/intelligent-contracts/features/error-handling.md): Error Handling in GenVM explains unrecoverable exits, UserError, VMError, propagation, result types, and consensus patterns. - [Upgradability](https://docs.genlayer.com/developers/intelligent-contracts/features/upgradability.md): Upgradability in GenVM controls Intelligent Contract code changes with Root Slot upgraders and locked storage slots - [Value Transfers](https://docs.genlayer.com/developers/intelligent-contracts/features/value-transfers.md): Value transfers in Intelligent Contracts: receive, send, and read GEN balances with payable methods and messages - [Transaction Context](https://docs.genlayer.com/developers/intelligent-contracts/features/transaction-context.md): Transaction Context exposes GenVM transaction metadata, caller addresses, GEN value, chain ID, and deterministic timestamps. - [Messages](https://docs.genlayer.com/developers/intelligent-contracts/features/messages.md): Messages in GenLayer define transactions, internal IC calls, external chain-layer calls, ghost contracts, and message context. - [Interacting with Intelligent Contracts](https://docs.genlayer.com/developers/intelligent-contracts/features/interacting-with-intelligent-contracts.md): Interacting with Intelligent Contracts: get references, call view methods, emit messages, and deploy child contracts. - [Interacting with EVM Contracts](https://docs.genlayer.com/developers/intelligent-contracts/features/interacting-with-evm-contracts.md): EVM contract interaction in GenLayer: define interfaces, read balances, call views, and emit finality messages. - [Special Methods](https://docs.genlayer.com/developers/intelligent-contracts/features/special-methods.md): Special Methods in Intelligent Contracts define GenVM fallback and receive handlers for unmatched calls and value transfers. - [Vector Store](https://docs.genlayer.com/developers/intelligent-contracts/features/vector-storage.md): Vector Store in GenLayer stores embeddings, computes similarity, manages metadata, and supports CRUD in Intelligent Contracts. - [Debugging Contract Code](https://docs.genlayer.com/developers/intelligent-contracts/features/debugging.md): Debug Intelligent Contract code with print statements and runtime traces in the GenVM. - [Random](https://docs.genlayer.com/developers/intelligent-contracts/features/random.md): Random in Intelligent Contracts uses seeded randomness to avoid nondeterministic disagreement or leader trust. - [Non-determinism](https://docs.genlayer.com/developers/intelligent-contracts/features/non-determinism.md): Non-determinism in Intelligent Contracts: when to use nondet blocks and how GenVM consensus validates variable outputs - [Calling LLMs](https://docs.genlayer.com/developers/intelligent-contracts/features/calling-llms.md): Calling LLMs in Intelligent Contracts with exec_prompt, JSON responses, image inputs, validation, parsing, and error handling - [Image Processing](https://docs.genlayer.com/developers/intelligent-contracts/features/image-processing.md): Image Processing in Intelligent Contracts sends images to vision-capable LLMs for visual analysis. - [Web Access](https://docs.genlayer.com/developers/intelligent-contracts/features/web-access.md): Web Access in Intelligent Contracts covers HTTP requests, page rendering, screenshots, errors, and consensus-safe web data. - [Development Setup](https://docs.genlayer.com/developers/intelligent-contracts/tooling-setup.md): Install and configure the GenLayer development tools: the GenLayer CLI, GenLayer Studio, and the testing suite. - [Your First Contract](https://docs.genlayer.com/developers/intelligent-contracts/first-contract.md): Step-by-step tutorial to write, deploy, and test your first GenLayer Intelligent Contract in Python. - [Address Type](https://docs.genlayer.com/developers/intelligent-contracts/types/address.md): Address Type covers 20-byte blockchain addresses in Intelligent Contracts, including users, contracts, and interactions - [Primitive Types](https://docs.genlayer.com/developers/intelligent-contracts/types/primitive.md): Primitive Types in GenVM cover sized integers, strings, bytes, booleans, conversions, and storage range checks. - [Collection Types](https://docs.genlayer.com/developers/intelligent-contracts/types/collections.md): Collection Types in GenVM define storage-compatible DynArray and TreeMap structures for Intelligent Contracts. - [Dataclasses](https://docs.genlayer.com/developers/intelligent-contracts/types/dataclasses.md): Dataclasses define structured storage-compatible data types for GenLayer Intelligent Contracts using @allow_storage. - [Persisting data on the blockchain](https://docs.genlayer.com/developers/intelligent-contracts/storage.md): How Intelligent Contracts persist data on the blockchain: storage rules, allowed types, and patterns for GenVM storage. - [Your First **Intelligent** Contract](https://docs.genlayer.com/developers/intelligent-contracts/first-intelligent-contract.md): Your First Intelligent Contract shows how to use non-deterministic blocks, web rendering, and strict_eq in GenLayer. - [The Equivalence Principle](https://docs.genlayer.com/developers/intelligent-contracts/equivalence-principle.md): Equivalence Principle explains how GenLayer validators reach consensus on non-deterministic Intelligent Contract outputs. - [Debugging Intelligent Contracts in GenLayer Studio](https://docs.genlayer.com/developers/intelligent-contracts/debugging.md): Debug Intelligent Contracts interactively in GenLayer Studio: deploy, send transactions, validate behavior, and inspect node logs. - [Testing Intelligent Contracts](https://docs.genlayer.com/developers/intelligent-contracts/testing.md): Test Intelligent Contracts with the pytest-based GenLayer Testing Suite (genlayer-test): direct mode and integration mode. - [Deploying Intelligent Contracts](https://docs.genlayer.com/developers/intelligent-contracts/deploying.md): Deploy Intelligent Contracts with the CLI or GenLayerJS, including v0.6 fee estimation, network selection, and outcome verification. - [Deployment Methods](https://docs.genlayer.com/developers/intelligent-contracts/deploying/deployment-methods.md): Deployment Methods explains CLI direct deployment and deploy scripts for GenLayer Intelligent Contracts. - [Network Configuration](https://docs.genlayer.com/developers/intelligent-contracts/deploying/network-configuration.md): Choose and configure Localnet, Studionet, the Studio development preview, or Bradbury. - [CLI Deployment](https://docs.genlayer.com/developers/intelligent-contracts/deploying/cli-deployment.md): CLI Deployment explains how to deploy GenLayer Intelligent Contracts with genlayer deploy, RPC targets, and constructor args. - [Deploy Scripts](https://docs.genlayer.com/developers/intelligent-contracts/deploying/deploy-scripts.md): Create ordered, fee-aware TypeScript deploy scripts for Intelligent Contracts. - [Prompt & Data Techniques](https://docs.genlayer.com/developers/intelligent-contracts/crafting-prompts.md): Prompt and data techniques for Intelligent Contracts: JSON outputs, stable web data, and grounded LLM judgments - [Prompt Injection](https://docs.genlayer.com/developers/intelligent-contracts/security-and-best-practices/prompt-injection.md): Prompt injection in Intelligent Contracts: risks from manipulated AI prompts and input/output controls to mitigate them - [Storage Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/storage.md): Storage Contract example shows a Python Intelligent Contract that stores, reads, and updates a string value. - [UserStorage Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/user-storage.md): UserStorage Contract stores and retrieves per-user string values by account address in a GenLayer Intelligent Contract. - [LlmHelloWorld Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/llm-hello-world.md): LlmHelloWorld is the simplest Intelligent Contract LLM example: the leader generates a salute and validators judge it against criteria. - [LlmHelloWorldNonComparative Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/llm-hello-world-non-comparative.md): LlmHelloWorldNonComparative shows non-comparative Equivalence Principle prompting in a Python Intelligent Contract. - [Wizard of Coin Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/wizard-of-coin.md): Wizard of Coin Contract shows a GenLayer Intelligent Contract that uses an LLM and Equivalence Principle to decide coin ownership. - [FetchWebContent Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/fetch-web-content.md): FetchWebContent Contract shows how an Intelligent Contract fetches web content, stores it, and reaches node agreement. - [FetchGitHubProfile Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/fetch-github-profile.md): FetchGitHubProfile Contract shows how a GenLayer Intelligent Contract fetches GitHub profiles and stores agreed content. - [GitHubProfilesRepositories Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/github-profile-projects.md): GitHubProfilesRepositories contract fetches GitHub profiles, counts repositories, and stores high-contributor handles. - [GitHubProfilesSummaries Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/github-profile-summary.md): GitHubProfilesSummaries Intelligent Contract fetches GitHub profiles and stores AI-generated summaries using equivalence principles. - [Prediction Market Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/prediction.md): Prediction Market Contract example shows how an Intelligent Contract resolves football outcomes with web data and the Equivalence Principle. - [LogIndexer Contract](https://docs.genlayer.com/developers/intelligent-contracts/examples/vector-store-log-indexer.md): LogIndexer Contract demonstrates VecDB log storage, CRUD operations, and vector similarity search in GenVM. - [GenLayer CLI](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-cli.md): GenLayer CLI installs, initializes, and runs GenLayer Studio locally for development, simulation, and testing. - [GenLayer Studio](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio.md): Use hosted or local GenLayer Studio to develop, deploy, and inspect Intelligent Contracts. - [Load Your Contract](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/loading-contract.md): GenLayer Studio contract loading: add an Intelligent Contract file, open it, and prepare it to run and deploy. - [Deploy Contracts](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/deploying-contract.md): GenLayer Studio contract deployment: set constructor parameters, detect inputs, and deploy an Intelligent Contract. - [Current Intelligent Contract State](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/contract-state.md): Current Intelligent Contract State explains how to view read methods in GenLayer Studio and verify deployed contract variables. - [Execute Transactions](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/execute-transaction.md): GenLayer Studio transaction execution covers running Intelligent Contract write methods and viewing results. - [Monitoring Node Logs](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/monitoring-node-logs.md): Node Logs in GenLayer Studio show real-time transaction, deployment, execution, validator, and consensus events. - [Accessing and Configuring Validators](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/validators.md): GenLayer Studio validators manage consensus roles, default validator setup, and configuration for Intelligent Contracts. - [Inference Providers](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/providers.md): Inference Providers in GenLayer Studio configure validator models, provider settings, custom plugins, and defaults. - [Limitations of the GenLayer Studio](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/limitations.md): GenLayer Studio limitations covering gasless testing, EVM parity gaps, web access constraints, and live-network validation. - [Resetting the GenLayer Studio](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/reset-the-studio.md): GenLayer Studio reset clears storage, state, memory, and contract examples so developers can start from a clean workspace. - [Troubleshooting](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/troubleshooting.md): GenLayer Studio troubleshooting steps for loading issues, port conflicts, Docker problems, display issues, and startup errors - [Development Tips](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/development-tips.md): GenLayer Studio development tips explain validator setup, typed inputs, deployment, debugging, and transaction inspection. - [Adding LLM Provider Plugins](https://docs.genlayer.com/developers/intelligent-contracts/tools/genlayer-studio/advanced-features/custom-plugins.md): Adding LLM Provider Plugins explains how to integrate custom LLM providers into GenLayer Studio. - [💡 Build With GenLayer](https://docs.genlayer.com/developers/intelligent-contracts/ideas.md): GenLayer Intelligent Contract ideas for web-aware, API-driven, LLM-powered blockchain applications. - [Architecture Overview of Decentralized Applications Using GenLayer](https://docs.genlayer.com/developers/decentralized-applications/architecture-overview.md): GenLayer DApp architecture covers frontend, GenLayerJS, Optimistic Democracy, GenVM, and Ghost Contracts. - [DApp Development Workflow with GenLayer](https://docs.genlayer.com/developers/decentralized-applications/dapp-development-workflow.md): DApp Development Workflow with GenLayer covers Studio, local testing, deployment workflow, and GenLayerJS frontend integration. - [GenLayerJS SDK](https://docs.genlayer.com/developers/decentralized-applications/genlayer-js.md): GenLayerJS SDK covers TypeScript tools for building DApps on GenLayer with clients, transactions, events, and Viem. - [Querying a Transaction](https://docs.genlayer.com/developers/decentralized-applications/querying-a-transaction.md): Read, track, and interpret GenLayer transaction state with the v2 lifecycle APIs. - [Reading from Intelligent Contracts](https://docs.genlayer.com/developers/decentralized-applications/reading-data.md): Read Intelligent Contract state at the latest final or latest non-final snapshot with GenLayerJS. - [Writing to Intelligent Contracts](https://docs.genlayer.com/developers/decentralized-applications/writing-data.md): Estimate, submit, and verify fee-funded writes to Intelligent Contracts with GenLayerJS. - [Fees and Transaction Policy](https://docs.genlayer.com/developers/decentralized-applications/fees-and-transaction-kit.md): Use measured transaction policies to fund consensus, execution, messages, appeals, and rotations safely. - [Transaction Kit Integration](https://docs.genlayer.com/developers/decentralized-applications/transaction-kit-integration.md): Add GenLayer fee review, wallet submission, and transaction tracking to React, Vue, or headless apps. - [Fee Profiling and Estimation](https://docs.genlayer.com/developers/decentralized-applications/fee-profiling-and-estimation.md): Generate test-backed fee profiles and use them with GenLayerJS, GenLayerPy, the CLI, and Transaction Kit. - [Fee Outcomes and Debugging](https://docs.genlayer.com/developers/decentralized-applications/fee-outcomes-and-debugging.md): Interpret GenLayer transaction outcomes, fee refunds, gasless Studio behavior, and fee-related failures. - [Developer NFT Rewards](https://docs.genlayer.com/developers/decentralized-applications/developer-nft-rewards.md): Developer NFT Rewards explains how GenLayer credits contract deployers with a share of transaction fees and epoch inflation, and how to read and claim those rewards with GenLayerJS. - [Testing Contracts in GenLayer Studio](https://docs.genlayer.com/developers/decentralized-applications/testing.md): Test contracts and dApps interactively using GenLayer Studio and the local development environment. - [GenLayer Project Boilerplate](https://docs.genlayer.com/developers/decentralized-applications/project-boilerplate.md): GenLayer Project Boilerplate shows how to build a DApp with Intelligent Contracts, Vue.js, GenLayerJS, and tests. - [Error & Revert Reference](https://docs.genlayer.com/developers/error-reference.md): A reference catalog of the GenLayer consensus protocol's custom Solidity errors: each error's 4-byte selector, its meaning, and the common cause or fix, organized by area, plus common encoding pitfalls. - [Staking Contract Guide](https://docs.genlayer.com/developers/staking-guide.md): Staking Contract Guide covers direct Solidity interactions for GenLayer validator and delegator staking operations. ## Run a Validator - [Setting Up Your GenLayer Validator](https://docs.genlayer.com/validators/setup-guide.md): Complete guide to running a GenLayer validator node: system requirements, installation, configuration, staking, and node operation. - [Monitoring & Telemetry](https://docs.genlayer.com/validators/monitoring.md): Validator monitoring and telemetry covers Prometheus metrics, health checks, and resource tracking for GenLayer validators. - [Network Keeper Roles](https://docs.genlayer.com/validators/network-keeper-roles.md): Network keeper roles are the permissionless GenLayer functions anyone can call to keep the network live — inflation relay, epoch advancement, validator priming, appeals, finalization, and cleanup — with their triggers, rewards, and risks. - [System Requirements](https://docs.genlayer.com/validators/system-requirements.md): System Requirements list initial hardware and software recommendations for running a GenLayer validator node. - [GenVM Configuration](https://docs.genlayer.com/validators/genvm-configuration.md): GenVM Configuration explains how validators configure LLM providers, model routing, web access, hot reloads, and costs. - [Greybox LLM Strategy — Validator Setup Guide](https://docs.genlayer.com/validators/greybox-setup.md): Switch your GenLayer node from the default auto-generated provider chain to a curated, operator-controlled fallback chain via OpenRouter. - [Validator Upgrade Guide](https://docs.genlayer.com/validators/upgrade.md): Validator Upgrade Guide explains GenLayer validator breaking and non-breaking upgrades, database handling, and downtime expectations. - [Changelog](https://docs.genlayer.com/validators/changelog.md): v0.6 is a breaking release. It runs only against the v0.6 consensus contracts (release tag v0.6-rc-1), and all validators upgrade together: receipt hashes,… ## API References - [API References](https://docs.genlayer.com/api-references.md): Reference documentation for GenLayer tools: the GenLayer CLI, GenLayerJS and GenLayerPY SDKs, the testing framework, the node JSON-RPC API, and the GenVM linter. - [GenLayer CLI](https://docs.genlayer.com/api-references/genlayer-cli.md): The GenLayer CLI is designed to streamline the setup and local execution of the GenLayer simulator. This tool automates the process of downloading and… - [init](https://docs.genlayer.com/api-references/genlayer-cli/environment/init.md): Initialize the GenLayer Environment - [up](https://docs.genlayer.com/api-references/genlayer-cli/environment/up.md): Starts GenLayer's simulator - [stop](https://docs.genlayer.com/api-references/genlayer-cli/environment/stop.md): Stop all running localnet services. - [new](https://docs.genlayer.com/api-references/genlayer-cli/environment/new.md): Create a new GenLayer project using the default template - [update](https://docs.genlayer.com/api-references/genlayer-cli/environment/update.md): Update resources like models or configurations - [update ollama](https://docs.genlayer.com/api-references/genlayer-cli/environment/update/ollama.md): Manage Ollama models (update or remove) - [deploy](https://docs.genlayer.com/api-references/genlayer-cli/contracts/deploy.md): Deploy intelligent contracts - [call](https://docs.genlayer.com/api-references/genlayer-cli/contracts/call.md): Call a contract method without sending a transaction or changing the state - [write](https://docs.genlayer.com/api-references/genlayer-cli/contracts/write.md): Sends a transaction to a contract method that modifies the state - [schema](https://docs.genlayer.com/api-references/genlayer-cli/contracts/schema.md): Get the schema for a deployed contract - [code](https://docs.genlayer.com/api-references/genlayer-cli/contracts/code.md): Get the source for a deployed contract - [receipt](https://docs.genlayer.com/api-references/genlayer-cli/transactions/receipt.md): Get transaction receipt by hash - [trace](https://docs.genlayer.com/api-references/genlayer-cli/transactions/trace.md): Get execution trace for a transaction (return data, stdout, stderr, GenVM logs) - [appeal](https://docs.genlayer.com/api-references/genlayer-cli/transactions/appeal.md): Appeal a transaction by its hash. The CLI binds the active decision and uses the schedule-extending appeal path; if --bond is omitted it reads the… - [appeal-bond](https://docs.genlayer.com/api-references/genlayer-cli/transactions/appeal-bond.md): Show the full appeal charge required for a transaction. The historical command name is retained for compatibility; the returned value includes the bond and… - [config](https://docs.genlayer.com/api-references/genlayer-cli/configuration/config.md): Manage CLI configuration, including the default network - [config get](https://docs.genlayer.com/api-references/genlayer-cli/configuration/config/get.md): Get the current configuration - [config reset](https://docs.genlayer.com/api-references/genlayer-cli/configuration/config/reset.md): Reset a configuration value to its default - [config set](https://docs.genlayer.com/api-references/genlayer-cli/configuration/config/set.md): Set a configuration value - [network](https://docs.genlayer.com/api-references/genlayer-cli/configuration/network.md): Network configuration - [network info](https://docs.genlayer.com/api-references/genlayer-cli/configuration/network/info.md): Show current network configuration and contract addresses - [network list](https://docs.genlayer.com/api-references/genlayer-cli/configuration/network/list.md): List available networks - [network set](https://docs.genlayer.com/api-references/genlayer-cli/configuration/network/set.md): Set the network to use - [account](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account.md): Manage your accounts (address, balance, keys) - [account create](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/create.md): Create a new account with encrypted keystore - [account export](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/export.md): Export an account to a keystore file (web3/geth/foundry compatible) - [account import](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/import.md): Import an account from a private key or keystore file - [account list](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/list.md): $ genlayer account list [options] - [account lock](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/lock.md): Lock account by removing private key from OS keychain - [account remove](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/remove.md): $ genlayer account remove [options] - [account send](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/send.md): Send GEN to an address - [account show](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/show.md): Show account details (address, balance) - [account unlock](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/unlock.md): Unlock account by caching private key in OS keychain - [account use](https://docs.genlayer.com/api-references/genlayer-cli/accounts/account/use.md): Set the active account - [staking](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking.md): Staking operations for validators and delegators - [staking active-validators](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/active-validators.md): List all active validators - [staking banned-validators](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/banned-validators.md): List all banned validators - [staking delegation-info](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/delegation-info.md): Get delegation info for a delegator with a validator - [staking delegator-claim](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/delegator-claim.md): Claim delegator withdrawals after unbonding period - [staking delegator-exit](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/delegator-exit.md): Exit as a delegator by withdrawing shares from a validator - [staking delegator-join](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/delegator-join.md): Join as a delegator by staking with a validator - [staking epoch-info](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/epoch-info.md): Get current epoch and staking parameters - [staking prime-all](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/prime-all.md): Prime all validators that need priming - [staking quarantined-validators](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/quarantined-validators.md): List all quarantined validators - [staking set-identity](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/set-identity.md): Set validator identity metadata (moniker, website, socials, etc.) - [staking set-operator](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/set-operator.md): Change the operator address for a validator wallet - [staking validator-claim](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/validator-claim.md): Claim validator withdrawals after unbonding period - [staking validator-deposit](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/validator-deposit.md): Make an additional deposit to a validator wallet - [staking validator-exit](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/validator-exit.md): Exit as a validator by withdrawing shares - [staking validator-history](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/validator-history.md): Show slash and reward history for a validator (default: last 10 epochs) - [staking validator-info](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/validator-info.md): Get information about a validator - [staking validator-join](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/validator-join.md): Join as a validator by staking tokens - [staking validator-prime](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/validator-prime.md): Prime a validator to prepare their stake record for the next epoch - [staking validators](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/validators.md): Show validator set with stake, status, and voting power - [staking wizard](https://docs.genlayer.com/api-references/genlayer-cli/staking/staking/wizard.md): Interactive wizard to become a validator - [localnet](https://docs.genlayer.com/api-references/genlayer-cli/localnet/localnet.md): Manage localnet operations - [localnet validators count](https://docs.genlayer.com/api-references/genlayer-cli/localnet/localnet/validators/count.md): Count all validators - [localnet validators create-random](https://docs.genlayer.com/api-references/genlayer-cli/localnet/localnet/validators/create-random.md): Create random validators - [localnet validators create](https://docs.genlayer.com/api-references/genlayer-cli/localnet/localnet/validators/create.md): Create a new validator - [localnet validators delete](https://docs.genlayer.com/api-references/genlayer-cli/localnet/localnet/validators/delete.md): Delete a specific validator or all validators - [localnet validators get](https://docs.genlayer.com/api-references/genlayer-cli/localnet/localnet/validators/get.md): Retrieve details of a specific validator or all validators - [localnet validators update](https://docs.genlayer.com/api-references/genlayer-cli/localnet/localnet/validators/update.md): Update a validator's details - [localnet validators](https://docs.genlayer.com/api-references/genlayer-cli/localnet/localnet/validators.md): Manage localnet validators operations - [finalize](https://docs.genlayer.com/api-references/genlayer-cli/finalize.md): Finalize a transaction that is ready to be finalized (public call) - [finalize-batch](https://docs.genlayer.com/api-references/genlayer-cli/finalize-batch.md): Finalize a batch of idle transactions in a single call (public call) - [GenLayerJS](https://docs.genlayer.com/api-references/genlayer-js.md): Create GenLayer JavaScript clients, estimate and submit fee-funded transactions, wait for outcomes, and appeal decisions. - [Contract Methods](https://docs.genlayer.com/api-references/genlayer-js/contracts.md): Methods for deploying, reading, writing, and simulating GenLayer intelligent contracts. - [Transaction Methods](https://docs.genlayer.com/api-references/genlayer-js/transactions.md): Methods for fetching transactions, waiting for receipts, estimating gas, and debugging execution traces. - [Staking Methods](https://docs.genlayer.com/api-references/genlayer-js/staking.md): Methods for validator and delegator staking operations, epoch queries, and network status. - [GenLayerPY](https://docs.genlayer.com/api-references/genlayer-py.md): Use the GenLayer Python SDK for fee-funded transactions, lifecycle reads, appeals, and contract interaction. - [GenLayerPY SDK API Reference](https://docs.genlayer.com/api-references/genlayer-py/api.md): Auto-generated from source docstrings. - [GenLayer Testing Suite](https://docs.genlayer.com/api-references/genlayer-test.md): A pytest-based testing framework for GenLayer intelligent contracts. Built on top of genlayer-py. - [Integration Testing](https://docs.genlayer.com/api-references/genlayer-test/integration.md): Test contracts against a running GenLayer network (localnet, studionet, or testnet). - [Direct Mode Testing](https://docs.genlayer.com/api-references/genlayer-test/direct.md): Run contracts directly in Python without a network. Provides Foundry-style cheatcodes for fast test execution. - [glsim — Local GenLayer Network](https://docs.genlayer.com/api-references/genlayer-test/glsim.md): A lightweight single-process GenLayer network that runs contracts via direct mode. Supports real LLM and web calls without Docker or WASM. - [GenLayer Node API](https://docs.genlayer.com/api-references/genlayer-node.md): The GenLayer Node provides a JSON-RPC API for interacting with it. This API allows you to execute contract calls, retrieve transaction information, and perform… - [gen_call](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_call.md): Executes a new message call immediately without creating a transaction on the blockchain. This method supports read operations, write operations, and contract… - [gen_getContractSchema](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_getContractSchema.md): Retrieve the schema/interface of a GenLayer contract to understand its available methods and properties. - [Get latest decided state](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_getContractState.md): Retrieves the current state of a GenLayer intelligent contract at a specific block height and transaction status. - [Get latest decided code](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_getContractCode.md): Retrieves the code of a deployed GenLayer intelligent contract at a specific block height and transaction status. - [gen_getTransactionReceipt](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_getTransactionReceipt.md): Retrieves the transaction receipt for a given transaction ID. This endpoint is a proxy to the underlying consensus layer's getTransactionAllData function,… - [gen_getTransactionStatus](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_getTransactionStatus.md): Returns the transaction's current materialized consensus status. This is the lightweight polling surface: it does not project deadlines or turn protocol… - [gen_getTransactionLifecycle](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_getTransactionLifecycle.md): Returns one advanced protocol lifecycle snapshot for a transaction. This endpoint is intended for explorers, operator tooling, and debugging; ordinary… - [gen_syncing](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_syncing.md): Returns the GenVM sync status, indicating how far the node's local GenVM state is behind the chain tip. - [gen_estimateGas](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_estimateGas.md): Reserved for estimating gas for a GenLayer transaction. Not implemented — the method is registered and reachable, but every call returns an error. - [gen_getLogs](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_getLogs.md): Queries GenLayer contract-emitted events, mirroring ethgetLogs semantics under the gen namespace. Events are produced by intelligent contracts (gl.chain.Event… - [Latest round](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_getTransactionData.md): Retrieves the on-chain transaction data for one round together with the contract execution outputs (returnData, leaderPublicData) recovered from the node's… - [gen_protocolVersion](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_protocolVersion.md): Reserved for reporting the GenLayer protocol version. Not implemented — the method is registered and reachable, but every call returns an error. - [gen_subscribe](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_subscribe.md): Opens a subscription to a stream of GenLayer consensus events over the node's inbound WebSocket endpoint. Notifications are pushed as they occur, removing the… - [gen_unsubscribe](https://docs.genlayer.com/api-references/genlayer-node/gen/gen_unsubscribe.md): Cancels a subscription previously opened with gensubscribe. The node stops sending notifications for that subscription and releases the resources backing it. - [gen_dbg_ping](https://docs.genlayer.com/api-references/genlayer-node/debug/gen_dbg_ping.md): Simple connectivity test method that returns a "pong" response. - [gen_dbg_trie](https://docs.genlayer.com/api-references/genlayer-node/debug/gen_dbg_trie.md): Get trie information for debugging node internal DB state. - [gen_dbg_traceTransaction](https://docs.genlayer.com/api-references/genlayer-node/debug/gen_dbg_traceTransaction.md): Retrieves the full execution trace for a transaction, including the return data, stdout/stderr, GenVM logs, and the exact error if execution failed. - [balance](https://docs.genlayer.com/api-references/genlayer-node/ops/balance.md): Returns the configured operator's account balance in multiple formats including hexadecimal, wei, and GEN units. - [health](https://docs.genlayer.com/api-references/genlayer-node/ops/health.md): Returns the node's operational status and the typed condition catalog that explains it. - [HELP genlayer_node_cpu_usage_percent Current CPU usage percentage (0-100)](https://docs.genlayer.com/api-references/genlayer-node/ops/metrics.md): Exposes Prometheus-compatible metrics for monitoring node performance and health. - [snapshot](https://docs.genlayer.com/api-references/genlayer-node/ops/snapshot.md): Produces a consistent snapshot of the node's state at the current block. Two modes selected by the request body: stream the snapshot back as a gzipped tar… - [genvm-linter](https://docs.genlayer.com/api-references/genlayer-linter.md): Fast validation and schema extraction for GenLayer intelligent contracts. ## FAQ - [FAQ](https://docs.genlayer.com/FAQ.md): Frequently asked questions about GenLayer: Intelligent Contracts, Optimistic Democracy consensus, validators, the GenVM, and how to start building. ## Optional - [GenLayer Labs](https://docs.genlayer.com/partners/genlayerlabs.md): GenLayer Labs is an AI research lab and core GenLayer developer focused on AI-enhanced blockchain networks. - [Heurist](https://docs.genlayer.com/partners/heurist.md): Heurist provides decentralized AI model APIs and free credits for GenLayer Intelligent Contract developers. - [io.net](https://docs.genlayer.com/partners/ionet.md): io.net partnership gives GenLayer developers access to io.intelligence open-source AI models via one API. - [Comput3](https://docs.genlayer.com/partners/comput3.md): Comput3 provides GenLayer Validators with decentralized AI inference APIs for Intelligent Contracts. - [Using Chutes with GenLayer Validators](https://docs.genlayer.com/partners/chutes.md): Chutes for GenLayer validators: API setup, model inference, authentication, discounts, and GPU-free AI workloads. - [LibertAI](https://docs.genlayer.com/partners/libertai.md): LibertAI provides GenLayer developers confidential open-source model access through one unified API endpoint. - [Morpheus](https://docs.genlayer.com/partners/morpheus.md): Morpheus provides decentralized LLM inference for GenLayer Intelligent Contract validators via an OpenAI-compatible API.