Indexing on Tezos is not a simple matter of scanning blocks for top-level transactions. The protocol's operation model, where a single user-submitted operation can spawn a tree of internal operations, means that the most critical state transitions—such as FA token transfers—are often hidden inside internal transaction results. An indexer that only monitors the top-level transaction operations in a block will completely miss the vast majority of token movements, leading to incorrect balances, missed deposits, and a fundamentally broken view of the chain's state.

Parsing and Indexing Tezos Operations
The Indexer's Core Challenge on Tezos
Why parsing Tezos operations is a non-trivial engineering problem that demands a deep understanding of the protocol's execution model.
The core challenge lies in correctly parsing the metadata field returned by the Tezos RPC for each successful operation. This field contains the internal_operation_results, a recursive structure that reveals the full execution trace. For a data team, the task is to traverse this tree, identify transaction objects where the destination is a known token contract, and decode the Michelson parameters to detect FA1.2 transfer or FA2 transfer entrypoint calls. This process is computationally intensive and requires a robust decoding layer for Michelson data, as the token transfer details (from, to, amount, token_id) are serialized within the parameter bytes.
The operational risk is compounded by chain reorganizations. A naive indexer that simply appends data from new blocks will develop a corrupted database when the chain's head shifts. A production-grade Tezos indexer must implement an event-sourcing pattern, maintaining a continuous stream of block events and providing a mechanism to unwind and re-apply state when a reorg is detected. This requires a precise understanding of Tezos's consensus and fork-choice rule to correctly identify the canonical chain and safely discard orphaned blocks, ensuring that internal operations from a discarded fork do not permanently pollute the application's data store.
Indexing Integration Quick Facts
Operational facts for data teams building or maintaining indexers that parse Tezos operations, internal results, token transfers, and chain reorganizations.
| Area | What changes | Who is affected | Action |
|---|---|---|---|
Operation parsing | Internal operation results must be extracted from transaction receipts, not top-level operations | Indexer developers, data teams, wallet backends | Verify that your indexer recursively processes internal_operation_results to capture all balance effects |
Token transfer detection | FA1.2 and FA2 transfers emit different event structures; FA2 permits batch transfers in a single operation | Exchanges, custodians, DeFi protocols, wallet providers | Audit token transfer parsing logic against the FA1.2 and FA2 standards to ensure no missed or duplicated balance updates |
Chain reorganizations | Tezos chain can undergo reorganizations that invalidate previously indexed blocks | All indexer operators | Implement a reorg-aware ingestion pipeline that can unwind state for at least 2 blocks; test against historical reorg events |
Big map indexing | Big_map_diff in operation receipts provides incremental updates, but full state reconstruction requires careful ordering | Data teams, analytics platforms | Validate that your big_map state reconstruction matches on-chain state at multiple block heights; consider using a framework that handles this natively |
RPC load management | Polling the Tezos node RPC for all operations can cause timeouts and missed data under high load | Infrastructure teams, high-volume indexers | Use chunked RPC queries or a dedicated indexing framework (TzKT, DipDup) instead of raw polling; monitor RPC response times |
Smart rollup data | Smart Rollup inbox and outbox messages are not standard operations and require rollup-node-specific extraction | Rollup developers, bridge operators, rollup asset indexers | Run a dedicated Smart Rollup node to extract rollup-specific data; do not rely solely on L1 operation parsing |
Metadata resolution | TZIP-16 metadata requires executing Michelson views off-chain, which can fail or return inconsistent data | Wallet providers, marketplaces, explorers | Implement a metadata resolution pipeline with caching and fallback logic; verify display consistency across multiple contracts |
The Anatomy of a Tezos Operation Result
A technical breakdown of the operation result structure returned by Tezos RPCs, essential for indexers, exchanges, and custody teams to correctly interpret transaction success, internal state changes, and token transfer events.
Every applied Tezos operation returns a structured result object via the RPC, but the critical data for balance reconciliation and event detection is often nested within internal_operation_results. An operation that appears successful at the top level can contain failed internal transactions, or vice versa, making a superficial status check insufficient for financial applications. Indexers and integration engineers must traverse the full result tree, including metadata.internal_operation_results, to extract the complete set of balance updates, originated contract addresses, and token transfer events triggered by a single external operation.
The result structure varies by operation type. A transaction result contains a status field (applied, failed, backtracked, skipped) and a metadata object. Within metadata, the operation_result provides the immediate outcome (e.g., consumed gas, storage changes, originated contracts), while internal_operation_results is a list of results for operations spawned by the original, such as XTZ transfers from a contract or FA token callbacks. Each internal result has its own source, nonce, result, and parameters fields. For FA1.2 and FA2 token standards, transfer events are not emitted as logs but must be inferred by parsing these internal transaction parameters and their corresponding balance updates in big_map_diff or balance_updates.
A common indexing pitfall is failing to handle backtracked internal operations. When a contract call initiates a chain of internal operations and one fails, the Tezos protocol backtracks preceding internal operations within that chain, marking their status accordingly. An indexer that naively processes all internal operations without filtering by status will record phantom transfers. Teams building custom indexing logic should implement recursive descent into internal_operation_results, filter strictly on applied status, and correlate big_map_diff entries with known FA token ledger paths. Chainscore Labs reviews indexing pipelines to ensure correct handling of backtracked operations, reorg-safe balance computation, and accurate FA1.2/FA2 transfer detection.
Impact by Team Role
Core Responsibility
Your team is directly responsible for the accuracy of the historical state. The primary risk is a silent data corruption that causes a permanent fork in your internal ledger, diverging from the canonical chain.
Action Items
- Reorg Handling: Implement a strict event-sourcing pattern. Your indexer must be able to atomically unwind blocks from the tip of the chain and re-apply new blocks without leaving partial state. Validate this against Tezos testnets where reorgs are more frequent.
- Internal Operation Decoding: Do not rely solely on top-level transaction receipts. You must recursively parse
internal_operation_resultsto capture token transfers and contract origination events. A failure here means missing FA1.2/FA2 transfer data. - Big Map Diffing: For efficient state tracking, use the
big_map_difffrom block receipts instead of re-scanning entire maps. Ensure your parser correctly handlesalloc,update, andremoveactions. - Chainscore Labs Review: We can audit your reorg-handling logic and internal operation parsing to certify that your indexer maintains perfect consistency with the Tezos node.
Core Indexing Workflows and Risks
Parsing and indexing Tezos operations requires handling internal operation results, chain reorganizations, and token standard nuances. These cards map the critical workflows and failure modes that data teams must address.
Internal Operation Result Parsing
A single Tezos operation can spawn multiple internal operations. Indexers must recursively parse internal_operation_results to capture all balance effects, contract originations, and delegations. Missing these leads to incomplete transaction histories and incorrect balance calculations. Chainscore Labs reviews your parsing logic against mainnet edge cases to ensure no internal state changes are dropped.
Chain Reorganization Handling
Tezos chain reorganizations can invalidate blocks that indexers have already processed. A durable indexing architecture must detect reorgs via block hash mismatches and correctly unwind state changes, including big_map diffs and token balance updates. Failure to handle reorgs causes persistent data corruption. We audit your event sourcing and rollback logic to guarantee consistency with the canonical chain.
FA1.2 and FA2 Transfer Detection
Detecting token transfers requires more than scanning top-level transaction parameters. FA1.2 transfer and FA2 transfer entrypoints emit balance updates through internal operation results. Indexers must also interpret FA2 operator permissions and batch transfers correctly. Chainscore Labs validates your token transfer detection against the full FA standard specifications to prevent missed or duplicate transfer events.
Big Map Diff Processing
Tezos nodes provide big_map_diff in operation receipts to show storage changes without fetching entire maps. Indexers must apply these diffs sequentially to reconstruct off-chain state. Incorrect ordering or missing diffs during reorgs leads to corrupted contract storage views. Our review ensures your diff application logic correctly tracks state transitions across blocks and handles reorg unwinds.
RPC Interaction and Rate Limiting
High-load indexers risk overwhelming Tezos RPC nodes with requests for block data, big_map values, and operation receipts. Chunked RPC calls, intelligent caching, and backpressure handling are essential for reliable data extraction. Chainscore Labs assesses your RPC interaction patterns to prevent service degradation and ensure complete data capture under production load.
Indexer Correctness Audit
Indexer bugs can silently produce incorrect data that downstream wallets, exchanges, and analytics tools rely on. A comprehensive audit validates operation parsing, token transfer detection, reorg handling, and state reconstruction logic against mainnet reference data. Chainscore Labs provides a structured review of your indexing pipeline to identify logic errors before they cause user-facing balance discrepancies.
Indexer Correctness Risk Matrix
Common failure modes that cause indexers to report incorrect balances, miss transactions, or corrupt state when parsing Tezos operations. Data teams should validate their indexing logic against each risk area.
| Risk area | Failure mode | Affected systems | Validation step |
|---|---|---|---|
Internal operation results | Indexer reads only top-level operations and misses token transfers, delegations, or contract origination events that occur as internal results of smart contract execution | Wallets, exchanges, custodians, block explorers, tax tools | Verify that your indexer parses internal_operation_results for every successful transaction and matches balance changes against a Tezos node's context |
FA1.2 and FA2 transfer detection | Indexer relies on parameter entrypoint names to detect transfers but misses custom or non-standard entrypoint implementations that still emit valid transfer events per the standard | Wallets, DeFi protocols, NFT marketplaces, compliance tools | Validate transfer detection against known FA1.2 and FA2 contract addresses using balance_of views and cross-reference with a reference indexer like TzKT |
Big map key decoding | Indexer fails to decode complex Michelson big map keys or values, causing token balances or contract state to be silently skipped or misrepresented | Data dashboards, analytics platforms, auditors | Test big map traversal against contracts with nested pair keys, option types, and bytes-encoded metadata. Compare decoded output with octez-client get big map value |
Chain reorganization handling | Indexer does not correctly unwind state when Tezos chain reorganizations occur, leaving stale operations in the database and causing duplicate or phantom balances | All downstream consumers of indexed data | Simulate a 2-block reorg in a test environment and verify that all balances, transaction histories, and contract states revert to the correct pre-reorg state |
Operation ordering within blocks | Indexer processes operations in block order but Tezos applies them in a specific sequence where internal results of earlier operations can affect later operations in the same block | Arbitrage bots, DeFi protocols, high-frequency traders | Validate that your indexer applies operations in the same order as the Tezos protocol. Compare intermediate states after each operation against a node's context at that block level |
Failed operation handling | Indexer records failed operations as successful or ignores them entirely, missing gas consumption, storage fees, or state changes that occur even in reverted transactions | Exchanges, custodians, accounting systems | Verify that failed operations are recorded with correct status, gas consumed, and any storage modifications. Cross-check operation receipts with the block's operation_metadata |
Smart rollup inbox and outbox messages | Indexer tracks L1 operations but does not parse rollup inbox messages or outbox proofs, missing deposits, withdrawals, and rollup state transitions | Rollup bridges, rollup explorers, L2 data teams | Validate that your indexer decodes smart rollup inbox messages from L1 operations and correctly associates outbox proofs with withdrawal completions |
Michelson storage migration after upgrades | Indexer uses hardcoded storage schemas that break after protocol upgrades introduce new Michelson types or change existing storage layouts | Analytics platforms, governance dashboards, auditors | After each protocol upgrade, re-validate storage decoding against a sample of active contracts. Use schema-agnostic traversal for resilience |
Indexer Implementation and Audit Checklist
A structured checklist for data and integration teams to validate the correctness, resilience, and completeness of a Tezos indexer before production deployment. Each item identifies a critical failure mode, explains its operational impact, and specifies the signal or artifact that confirms the issue has been addressed.
What to check: Verify that the indexer correctly parses internal_operation_results from the /chains/main/blocks/<block>/operations RPC response, not just top-level operations.
Why it matters: FA1.2 and FA2 token transfers, as well as many DeFi interactions, are executed as internal operations. An indexer that only parses top-level operations will miss the vast majority of token movements, leading to incorrect balance calculations and missing transaction history for users.
Readiness signal: A test suite that replays a known block containing a contract interaction (e.g., a Dexter swap) and asserts that the specific internal transaction representing the token transfer is present in the indexed data with the correct sender, receiver, and amount.
Canonical Resources
Use these resources to validate Tezos operation parsing, internal operation handling, FA token transfer detection, and reorg-safe indexer design. Teams should verify behavior against the active protocol and the node or indexer version they run.
Looking to build on a specific blockchain?
We build smart contracts, DeFi applications, wallets, tokenization platforms, and blockchain infrastructure across the major ecosystems teams choose today. That includes Ethereum, Arbitrum, Optimism, Polygon, Avalanche, Solana, Sui, Aptos, Hedera, Stellar, and NEAR, with support for additional EVM and non-EVM networks based on your product requirements.
EVM ecosystems
- Ethereum
- Arbitrum
- Optimism
- Polygon
- Avalanche
- Cronos

Non-EVM ecosystems
- Solana
- Sui
- Aptos
- Hedera
- Stellar
- NEAR
Additional ecosystems
- Polkadot
- Cosmos
- TON
- Cardano
- Algorand
- Tempo
Also available for Base, appchains, custom EVM networks, and cross-chain product architecture.
Frequently Asked Questions
Common questions from data teams building Tezos indexers, covering operation parsing, internal results, token transfer detection, and reorg handling.
Tezos token transfers (FA1.2 and FA2) are not represented as distinct top-level operations. They are side-effects of successful contract calls. To detect them, you must:
- Parse the
internal_operation_resultsfield in the operation receipt. - Look for
transactioninternal operations where thedestinationis a known token contract. - Decode the
parametersof that internal transaction to identify the entrypoint (transfer) and its arguments.
Failing to parse internal results means your indexer will miss all token movements. This is the most common source of data loss in Tezos indexers.
Delivering blockchain solutions for 5+ years.
We have partnered with 50+ leading DeFi protocols, NFT ecosystems, and fintech innovators to build secure, scalable, and capital-efficient blockchain products.
Selected Partners & Clients
“I've been working with Chainscore Labs for last 3+ years, they've consistently delivered with strong ownership across multiple projects. The team is reliable and detail-oriented.”
How to get started?
If you're looking for blockchain integration, ChainScore Labs has 5+ years of experience helping teams build and integrate exchanges, wallets, smart contracts, tokenization solutions, and protocol-connected products, we can help you choose the right path, integrate securely, and get to production faster. Our team consists of experienced blockchain developers and architects who can help you with your blockchain integration needs.
Exploration & Strategy
Define your product goals and choose the right blockchain architecture for your use case.
Architecture & Design
Design the smart contracts, tokenomics, and security parameters of your system.
Development & Integration
Build and integrate with wallets, oracles, and front-end dApps for a seamless experience.
Security & Launch
Comprehensive audits followed by a risk-managed mainnet deployment to protect your users.
Discover our
blockchain development services.
We build production-grade blockchain solutions for top-tier projects across DeFi and Web3.
Need a blockchain engineering team?
Send the project context and we will respond with next steps, scope questions, and a practical path to delivery.


