Skip to content

Commit a0bcc5f

Browse files
committed
Add doc in book
1 parent fc1e148 commit a0bcc5f

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

book/src/api-lighthouse.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -775,6 +775,28 @@ Caveats:
775775
This is because the state *prior* to the `start_epoch` needs to be loaded from the database, and
776776
loading a state on a boundary is most efficient.
777777

778+
## `/lighthouse/supply/{state_root}`
779+
780+
Returns the sum of all validator balances for a given state root.
781+
782+
```bash
783+
curl -X GET "http://localhost:5052/lighthouse/supply/0x7e76880eb67bbdc86250aa578958e9d0675e64e714337855204fb5abaaf82c2b" -H "accept: application/json" | jq
784+
```
785+
786+
```json
787+
{
788+
"data": [
789+
674144000000000,
790+
false,
791+
true
792+
]
793+
}
794+
```
795+
796+
The two boolean flags in the response are respectively:
797+
* `execution_optimism`: whether the response was computed using optimistically synced data
798+
* `finalized`: whether the response was computed over finalized dasta
799+
778800
## `/lighthouse/logs`
779801

780802
This is a Server Side Event subscription endpoint. This allows a user to read

0 commit comments

Comments
 (0)