Appearance
engine_forkchoiceUpdatedV4
not served
Updates the forkchoice state
Not served yet
Cinder does not serve this method. Planned for v1.1. Comes with the Amsterdam fork. Until then the node answers -38005 (Unsupported fork).
For consensus clients only
The consensus client calls this method on the authenticated Engine API port, with the JWT secret. Applications and wallets do not call it.
INFO
This page is generated from the specification. The text comes from the OpenRPC description of the method.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
Forkchoice state | object | yes | Forkchoice state object V1 |
Payload attributes | object | no | Payload attributes object V4 |
Custody columns | 16 hex encoded bytes or null | no |
Returns
object: Response object
Errors
| Code | Message |
|---|---|
| -38002 | Invalid forkchoice state |
| -38003 | Invalid payload attributes |
| -32602 | Invalid params |
| -38005 | Unsupported fork |
| -38006 | Too deep reorg |
Specification
The official specification: engine_forkchoiceUpdatedV4 in ethereum/execution-apis.
Schema (OpenRPC)
Parameter Forkchoice state: object
json
{
"properties": {
"finalizedBlockHash": {
"pattern": "^0x[0-9a-f]{64}$",
"title": "Finalized block hash",
"type": "string"
},
"headBlockHash": {
"pattern": "^0x[0-9a-f]{64}$",
"title": "Head block hash",
"type": "string"
},
"safeBlockHash": {
"pattern": "^0x[0-9a-f]{64}$",
"title": "Safe block hash",
"type": "string"
}
},
"required": [
"headBlockHash",
"safeBlockHash",
"finalizedBlockHash"
],
"title": "Forkchoice state object V1",
"type": "object"
}Parameter Payload attributes: object
json
{
"properties": {
"parentBeaconBlockRoot": {
"pattern": "^0x[0-9a-f]{64}$",
"title": "Parent beacon block root",
"type": "string"
},
"prevRandao": {
"pattern": "^0x[0-9a-f]{64}$",
"title": "Previous randao value",
"type": "string"
},
"slotNumber": {
"pattern": "^0x(0|[1-9a-f][0-9a-f]{0,15})$",
"title": "Slot number",
"type": "string"
},
"suggestedFeeRecipient": {
"pattern": "^0x[0-9a-fA-F]{40}$",
"title": "Suggested fee recipient",
"type": "string"
},
"targetGasLimit": {
"pattern": "^0x(0|[1-9a-f][0-9a-f]{0,15})$",
"title": "Target gas limit",
"type": "string"
},
"timestamp": {
"pattern": "^0x(0|[1-9a-f][0-9a-f]{0,15})$",
"title": "Timestamp",
"type": "string"
},
"withdrawals": {
"items": {
"properties": {
"address": {
"pattern": "^0x[0-9a-fA-F]{40}$",
"title": "Withdrawal address",
"type": "string"
},
"amount": {
"pattern": "^0x(0|[1-9a-f][0-9a-f]{0,15})$",
"title": "Withdrawal amount",
"type": "string"
},
"index": {
"pattern": "^0x(0|[1-9a-f][0-9a-f]{0,15})$",
"title": "Withdrawal index",
"type": "string"
},
"validatorIndex": {
"pattern": "^0x(0|[1-9a-f][0-9a-f]{0,15})$",
"title": "Validator index",
"type": "string"
}
},
"required": [
"index",
"validatorIndex",
"address",
"amount"
],
"title": "Withdrawal object V1",
"type": "object"
},
"title": "Withdrawals",
"type": "array"
}
},
"required": [
"timestamp",
"prevRandao",
"suggestedFeeRecipient",
"withdrawals",
"parentBeaconBlockRoot",
"slotNumber",
"targetGasLimit"
],
"title": "Payload attributes object V4",
"type": "object"
}Parameter Custody columns: 16 hex encoded bytes or null
json
{
"oneOf": [
{
"pattern": "^0x[0-9a-f]{32}$",
"title": "16 hex encoded bytes",
"type": "string"
},
{
"type": "null"
}
]
}Result: object
json
{
"properties": {
"payloadId": {
"pattern": "^0x[0-9a-f]{16}$",
"title": "Payload id",
"type": "string"
},
"payloadStatus": {
"properties": {
"latestValidHash": {
"pattern": "^0x[0-9a-f]{64}$",
"title": "The hash of the most recent valid block",
"type": "string"
},
"status": {
"description": "Set of possible values is restricted to VALID, INVALID, SYNCING",
"enum": [
"VALID",
"INVALID",
"SYNCING"
],
"title": "Payload validation status",
"type": "string"
},
"validationError": {
"title": "Validation error message",
"type": "string"
}
},
"required": [
"status"
],
"title": "Payload status",
"type": "object"
}
},
"required": [
"payloadStatus"
],
"title": "Forkchoice updated response",
"type": "object"
}