indexing-handler-syntax
OfficialMaster event handler syntax and core indexer API.
Authorenviodev
Version1.0.0
Installs0
System Documentation
What problem does it solve?
Writing and maintaining event handlers for the Polymarket indexer can be error-prone without a consistent syntax and a reliable context API. This section explains how to standardize handler registration, access event data, and perform common tasks safely.
Core Features & Use Cases
- Handler Registration: Register contract events with a clear API that exposes event, context, and chain information.
- Context API: Read and write entities, perform queries, and access runtime information like chainId, isLive, context.log.
- Safe Updates: Use spread updates to ensure immutability while applying changes to entities.
- Runtime Interactions: Leverage indexer runtime API to introspect contracts, chains, and handlers during development.
- Common Pitfalls: Avoid undefined fields, misusing _id suffixes, and unsafe mutations.
Quick Start
Create a new handler using Contract.Event.handler and start the indexer, then validate runtime execution in a test environment.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: indexing-handler-syntax Download link: https://github.com/enviodev/polymarket-v2-indexer/archive/main.zip#indexing-handler-syntax Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.