Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ There are likely to be descriptions etc outside of the list below, but new query

| Endpoint | [Lighthouse](https://github.com/sigp/lighthouse) | [Lodestar](https://github.com/ChainSafe/lodestar) | [Nimbus](https://github.com/status-im/nimbus-eth2) | [Prysm](https://github.com/prysmaticlabs/prysm) | [Teku](https://github.com/ConsenSys/teku) |
|---------------------------------------------------------------------------------------------------------------------|--------------------------------------------------|---------------------------------------------------|----------------------------------------------------|-------------------------------------------------|-------------------------------------------|
| [#563](https://github.com/ethereum/beacon-APIs/pull/563) `GET /eth/v2/validator/duties/proposer/{epoch}` added | | | | | |
| [#563](https://github.com/ethereum/beacon-APIs/pull/563) `GET /eth/v1/validator/duties/proposer/{epoch}` deprecated | | | | | |

The Following are no longer in the Standard API, removed since the latest version.

Expand Down
72 changes: 72 additions & 0 deletions apis/validator/duties/proposer.v2.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
get:
tags:
- ValidatorRequiredApi
- Validator
summary: "Get block proposers duties"
operationId: "getProposerDutiesV2"
description: "Request beacon node to provide all validators that are scheduled to propose a block in the given epoch.

Duties should only need to be checked once per epoch,
however a chain reorganization could occur that results in a change of duties. For full safety,
you should monitor head events and confirm the dependent root in this response matches. After Fulu,
different checks need to be performed as the dependent root changes due to deterministic proposer lookahead.


Before Fulu:

- event.current_duty_dependent_root when `compute_epoch_at_slot(event.slot) == epoch`

- event.block otherwise

- dependent_root value is `get_block_root_at_slot(state, compute_start_slot_at_epoch(epoch) - 1)`


After Fulu:

- event.previous_duty_dependent_root when `compute_epoch_at_slot(event.slot) == epoch`

- event.block otherwise

- dependent_root value is `get_block_root_at_slot(state, compute_start_slot_at_epoch(epoch - 1) - 1)`


The dependent_root value is the genesis block root in the case of underflow.

Note: not required until Gloas"
parameters:
- name: epoch
in: path
required: true
schema:
$ref: '../../../beacon-node-oapi.yaml#/components/schemas/Uint64'
responses:
"200":
description: Success response
content:
application/json:
schema:
title: GetProposerDutiesResponse
type: object
required: [dependent_root, execution_optimistic, data]
properties:
dependent_root:
$ref: "../../../beacon-node-oapi.yaml#/components/schemas/DependentRoot"
execution_optimistic:
$ref: "../../../beacon-node-oapi.yaml#/components/schemas/ExecutionOptimistic"
data:
type: array
items:
$ref: "../../../beacon-node-oapi.yaml#/components/schemas/ProposerDuty"
"400":
description: "Invalid epoch"
content:
application/json:
schema:
$ref: "../../../beacon-node-oapi.yaml#/components/schemas/ErrorMessage"
example:
code: 400
message: "Invalid epoch: -2"
"500":
$ref: '../../../beacon-node-oapi.yaml#/components/responses/InternalError'
"503":
$ref: '../../../beacon-node-oapi.yaml#/components/responses/CurrentlySyncing'
1 change: 1 addition & 0 deletions apis/validator/duties/proposer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ get:
- ValidatorRequiredApi
- Validator
summary: "Get block proposers duties"
deprecated: true
operationId: "getProposerDuties"
description: "Request beacon node to provide all validators that are scheduled to propose a block in the given epoch.

Expand Down
2 changes: 2 additions & 0 deletions beacon-node-oapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,8 @@ paths:
$ref: "./apis/validator/duties/attester.yaml"
/eth/v1/validator/duties/proposer/{epoch}:
$ref: "./apis/validator/duties/proposer.yaml"
/eth/v2/validator/duties/proposer/{epoch}:
$ref: "./apis/validator/duties/proposer.v2.yaml"
/eth/v1/validator/duties/sync/{epoch}:
$ref: "./apis/validator/duties/sync.yaml"
/eth/v3/validator/blocks/{slot}:
Expand Down
1 change: 1 addition & 0 deletions wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,4 @@ KZGProofs
KZGCommitmentInclusionProof
LMD
fulu
gloas