Blockstream / Blockstream/esplora

Expose chainwork in block API responses

Open
#651 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
1.3k
Forks
514
Avg merge
1d 10h
Merged PRs (30d)
16

Description

Bitcoin Core exposes the cumulative chainwork for each block via the getblock RPC. This value is the canonical measure used to compare competing chains and determine the active chain.

It would be useful if Esplora included a chainwork field in /block/:hash responses. This would allow clients to compare competing branches, analyze reorgs, and display cumulative proof of work without having to recompute it from every block's bits value.

Since chainwork is already maintained by Bitcoin Core, this would be an additive, backward-compatible API enhancement.

Contributor guide

No contributing guide indexed for this repository

Research direction

Trace the implementation of the /block/:hash endpoint and how its block data is obtained from Bitcoin Core. Confirm where the existing response is assembled and how chainwork is represented by the upstream getblock RPC. Done means block responses include a chainwork field while retaining the current response fields and behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
api, backend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.