Skip to content

Commit

Permalink
eth/catalyst: implement exchangeCapabilities method (#26555)
Browse files Browse the repository at this point in the history
  • Loading branch information
MariusVanDerWijden committed Jan 27, 2023
1 parent 245cff0 commit 2fecac6
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 2fecac6

Please sign in to comment.