Skip to content

Commit

Permalink
eth/catalyst: implement exchangeCapabilities method (ethereum#26555)
Browse files Browse the repository at this point in the history
  • Loading branch information
MariusVanDerWijden authored and shekhirin committed Jun 6, 2023
1 parent bfd030b commit ee5f3ef
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions eth/catalyst/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,17 @@ const (
beaconUpdateWarnFrequency = 5 * time.Minute
)

// All methods provided over the engine endpoint.
var caps = []string{
"engine_forkchoiceUpdatedV1",
"engine_forkchoiceUpdatedV2",
"engine_exchangeTransitionConfigurationV1",
"engine_getPayloadV1",
"engine_getPayloadV2",
"engine_newPayloadV1",
"engine_newPayloadV2",
}

type ConsensusAPI struct {
eth *eth.Ethereum

Expand Down Expand Up @@ -732,3 +743,8 @@ func (api *ConsensusAPI) heartbeat() {
}
}
}

// ExchangeCapabilities returns the current methods provided by this node.
func (api *ConsensusAPI) ExchangeCapabilities([]string) []string {
return caps
}

0 comments on commit ee5f3ef

Please sign in to comment.