All packages
onememe-hood

onememe-hood

timedbase
v0.1.0/0 downloads/Repository

Package ref

onememe-hood@v0.1.0

Run package

CLI

Run map_locker_events from the command line.

substreams run onememe-hood@v0.1.0 map_locker_events -e robinhood --start-block -1
Authenticate by running substreams auth or directly on thegraph.market (see docs).

README

onememe-hood

Indexes OneCoinLocker (token/LP locking) and the Spark launchpad (SparkLauncher, SparkLocker, and per-launch SparkToken clones) on Robinhood Chain.

Overview

onememe-hood decodes every on-chain event from three fixed-address contracts — OneCoinLocker, and SparkLauncher / SparkLocker (the Spark launchpad, from OneMEMELaunchpad-Core) — plus every ERC-20/ownership event emitted by the SparkToken clones that SparkLauncher deploys per launch. Output is raw typed protobuf events; no sink is wired up, so downstream consumers (a service, a custom sink, another Substreams package) decide what to do with the data.

Each SparkToken is an EIP-1167 minimal-proxy clone deployed at launch time — its address isn't known until the TokenLaunched event fires. store_spark_tokens acts as the dynamic-data-source registry (the Substreams equivalent of a subgraph template): it records every launched token address, and map_spark_token_events consults it to recognize which logs belong to a Spark-launched token.

Modules

ModuleKindOutput TypeDescription
index_eventsblockIndexproto:sf.substreams.index.v1.KeysPer-block evt_addr:<address> keys, shared by the three fixed-address contract modules
map_locker_eventsmapproto:onememe.hood.v1.LockerEventsOneCoinLocker: LockCreated, LockEdited, LockDescriptionChanged, Withdrawn, LockExtended, LockTransferred, LockRenounced, FeeUpdated, TwapUpdated, FeesCollected
map_spark_launcher_eventsmapproto:onememe.hood.v1.SparkLauncherEventsSparkLauncher: TokenLaunched, DexAdded, DexDisabled, QuoteTokenAdded, QuoteTokenDisabled, LaunchFeeWalletSet, LaunchFeeSet, MarketCapRefSet, ETHRescued, ERC20Rescued
store_spark_tokensstoreproto:onememe.hood.v1.SparkTokenInfoRegistry of every SparkToken clone address ever launched (dynamic data source)
map_spark_locker_eventsmapproto:onememe.hood.v1.SparkLockerEventsSparkLocker: PositionRegistered, FeesClaimed, LauncherSet, PlatformWalletSet, CharityWalletSet, FeeBpsUpdated, OwnershipTransferred
index_spark_token_eventsblockIndexproto:sf.substreams.index.v1.KeysEmits spark_token:hit on blocks containing a log from any known SparkToken clone
map_spark_token_eventsmapproto:onememe.hood.v1.SparkTokenEventsTransfer, Approval, OwnershipTransferred, MetaURISet from any SparkToken clone

Prerequisites

  • substreams CLI installed
  • Authenticated: substreams auth
  • A Firehose/Substreams endpoint for robinhood (not StreamingFast-hosted by default — supply your own with -e)

Quick Start

substreams build

# OneCoinLocker events, from its deployment block
substreams run -e <robinhood-endpoint> \
  substreams.yaml map_locker_events \
  -s 1063824 -t +1000

# SparkLauncher events (includes TokenLaunched)
substreams run -e <robinhood-endpoint> \
  substreams.yaml map_spark_launcher_events \
  -s 1059274 -t +1000

# SparkToken clone events (Transfer/Approval/etc. from launched tokens)
substreams run -e <robinhood-endpoint> \
  substreams.yaml map_spark_token_events \
  -s 1059274 -t +1000

Default contract addresses are baked into substreams.yaml under params:. Override at runtime with -p <module>=0x... to point a module at a different deployment — note that blockFilter block-skipping stays pinned to the addresses hardcoded in the manifest unless you edit it too (see the comment in substreams.yaml).

References

Modules

Execution graph

7 modules
mapMain

map_locker_events

Decodes every OneCoinLocker event: LockCreated, LockEdited, LockDescriptionChanged, Withdrawn, LockExtended, LockTransferred, LockRenounced, FeeUpdated, TwapUpdated, FeesCollected.

from #1063824
blockIndex

index_events

Emits `evt_addr:<lowercase address>` for every log in the block. Shared by all three fixed-address contract modules below.

from #1051351

Output

sf.substreams.index.v1.Keys

blockIndex

index_spark_token_events

Emits a single `spark_token:hit` key on any block containing a log from an address present in store_spark_tokens. Because the address set grows at runtime, this indexes presence rather than a specific address (which a static blockFilter query can't express).

from #1059274

Output

sf.substreams.index.v1.Keys

map

map_spark_launcher_events

Decodes every SparkLauncher event, including TokenLaunched -- the event that announces each new SparkToken clone address, consumed by store_spark_tokens below to grow the dynamic token registry.

from #1059274
store

store_spark_tokens

Registry of every SparkToken clone address ever launched, keyed by lowercase hex token address. Written once per token (immutable), so this is the dynamic-data-source equivalent of a subgraph template: it lets map_spark_token_events recognize logs from addresses that only became known at runtime.

from #1059274

Update policy

set_if_not_exists