Use a finalized Ethereum block as a reporting cutoff
Two reads of the latest block can give a report two different end dates on chain. Pin the report to a finalized block and keep its identity with the output.
Capture the checkpoint
POST the following body to an Ethereum mainnet execution RPC endpoint. The second argument asks for transaction hashes in the block response, which keeps it smaller than returning full transactions.
{"jsonrpc":"2.0","id":1,"method":"eth_getBlockByNumber","params":["finalized",false]}
Capture number, hash and timestamp from result along with the chain ID. The timestamp is the time of the block. Record the wall-clock time of your request separately if the report needs to show when the data was collected.
Use the captured number on every page
For a report ending at a hypothetical height 0x1200010, use that literal height as the upper bound on log queries and as the block parameter for account reads. Repeated use of the tag finalized can pick up a newer checkpoint during the same job. When reproducing the report on another endpoint, fetch the saved height and compare the block hash before interpreting differences in balances.
Handle a stalled checkpoint
If finality stops advancing, an otherwise responsive endpoint may keep returning the previous checkpoint. Display its age and retain that cutoff or defer the job according to your reporting rules. If the endpoint returns an unsupported-tag error, surface the error. Falling back silently to latest changes the meaning of the report. ethereum.org Ethereum proof-of-stake finality