Quickstart
BlockDB exposes only gRPC services. This quickstart drives them directly withgrpcurl and JSON — no SDK required. gRPC reflection is enabled, so grpcurl discovers the schema itself.
0. Prerequisites
- A running BlockDB instance (default service address
localhost:19002). grpcurlinstalled.
blockdb.v1.TableReadService, blockdb.v1.BlockReadService, and the other services.
Step 1 — Write to a regular table
UseTableWriteService/UpsertRows. Every Value is a JSON object holding the one field you set (stringValue, intValue, doubleValue, boolValue).
Writes are asynchronous. The returned
jobId does not mean the data is already committed.Step 2 — Read a row
Step 3 — Write to a Block State Table
For on-chain state, useBlockWriteService/UpsertBlock with a block anchor (the example table token.token.eth is a Block State table):
Step 4 — Read state at a block height
Anchor the read withcurrentBlock; BlockDB injects height ≤ target height:
Step 5 — Subscribe to block write events
BlockSubscribeService/Subscribe is a server-streaming call. It stays open and streams an event per block write:
Next steps
- API overview — full reference with proto, JSON, and grpcurl for every method.
- Read and write data — the same operations through the
blockdb-pySDK. - Write architecture — batch writes and the asynchronous model.
- High-concurrency compute with BlockX