diff --git a/docs/public-networks/get-started/connect/mainnet.md b/docs/public-networks/get-started/connect/mainnet.md index 70ac72b8b2a..9d5e96242ce 100644 --- a/docs/public-networks/get-started/connect/mainnet.md +++ b/docs/public-networks/get-started/connect/mainnet.md @@ -51,6 +51,7 @@ besu \ --rpc-ws-host=0.0.0.0 \ --host-allowlist=,127.0.0.1,localhost \ --engine-host-allowlist=,127.0.0.1,localhost \ + --engine-rpc-enabled \ --engine-jwt-secret= ``` @@ -74,6 +75,8 @@ Also, in the command: service. - [`--rpc-ws-host`](../../reference/cli/options.md#rpc-ws-host) is set to `0.0.0.0` to allow remote RPC connections. +- [`--engine-rpc-enabled`](../../reference/cli/options.md#engine-rpc-enabled) enables the + [Engine API](../../reference/engine-api/index.md). You can modify the option values and add other [command line options](../../reference/cli/options.md) as needed. diff --git a/docs/public-networks/get-started/connect/testnet.md b/docs/public-networks/get-started/connect/testnet.md index e5efe551611..1d77ffd2535 100644 --- a/docs/public-networks/get-started/connect/testnet.md +++ b/docs/public-networks/get-started/connect/testnet.md @@ -54,6 +54,7 @@ Run the following command or specify the options in a --rpc-ws-host=0.0.0.0 \ --host-allowlist="*" \ --engine-host-allowlist="*" \ + --engine-rpc-enabled \ --engine-jwt-secret= ``` @@ -69,6 +70,7 @@ Run the following command or specify the options in a --rpc-ws-host=0.0.0.0 \ --host-allowlist="*" \ --engine-host-allowlist="*" \ + --engine-rpc-enabled \ --engine-jwt-secret= ``` diff --git a/docs/public-networks/how-to/use-engine-api.md b/docs/public-networks/how-to/use-engine-api.md index 6f81039fb4d..c0f5b9bd494 100644 --- a/docs/public-networks/how-to/use-engine-api.md +++ b/docs/public-networks/how-to/use-engine-api.md @@ -12,6 +12,7 @@ These API methods are a separate subsection of the [JSON-RPC API](../how-to/use- To configure the Engine API: +- [Enable the Engine API](#enable-the-engine-api) (it's disabled by default). - [Enable the JSON-RPC API](use-besu-api/index.md#enable-api-access). Ensure the [`ETH` method is enabled](use-besu-api/json-rpc.md#api-methods-enabled-by-default) (it's enabled by default). - Specify the [service ports](#service-ports). @@ -20,9 +21,18 @@ To configure the Engine API: !!! example "Example Engine API configuration" ```bash - besu --rpc-http-enabled --engine-rpc-port=8551 --engine-host-allowlist=localhost,127.0.0.1 --engine-jwt-secret=jwt.hex + besu --engine-rpc-enabled --rpc-http-enabled --engine-rpc-port=8551 --engine-host-allowlist=localhost,127.0.0.1 --engine-jwt-secret=jwt.hex ``` +### Enable the Engine API + +Enable the Engine API with the [`--engine-rpc-enabled`](../reference/cli/options.md#engine-rpc-enabled) CLI option. + +!!! note + + The `--engine-rpc-enabled` CLI option enables the Engine API even if no consensus client + configuration exists. + ### Service ports To specify the port the Engine API service listens on for HTTP and WebSocket, use the diff --git a/docs/public-networks/reference/cli/options.md b/docs/public-networks/reference/cli/options.md index d8307a603b7..c4d3ef4ff0e 100644 --- a/docs/public-networks/reference/cli/options.md +++ b/docs/public-networks/reference/cli/options.md @@ -580,6 +580,35 @@ Contents of file must be at least 32 hex-encoded bytes and not begin with `0x`. May be a relative or absolute path. See an [example of how to generate this](../../get-started/connect/mainnet.md#1-generate-the-shared-secret). +### `engine-rpc-enabled` + +=== "Syntax" + + ```bash + --engine-rpc-enabled[= + ``` + +=== "Example" + + ```bash + --engine-rpc-enabled + ``` + +=== "Environment variable" + + ```bash + BESU_ENGINE_RPC_ENABLED=true + ``` + +=== "Configuration file" + + ```bash + engine-rpc-enabled=true + ``` + +Enables or disables the [Engine API](../engine-api/index.md). +The default is `false`. + ### `engine-rpc-port` === "Syntax" diff --git a/docs/public-networks/reference/engine-api/index.md b/docs/public-networks/reference/engine-api/index.md index 43c9afc13cb..545eb8672fb 100644 --- a/docs/public-networks/reference/engine-api/index.md +++ b/docs/public-networks/reference/engine-api/index.md @@ -9,6 +9,10 @@ communicate with each other using the Engine API. When running Besu as an execution client, [use these API calls](../../how-to/use-engine-api.md) to communicate with a consensus client. +!!! important + + Ensure you enable the Engine API methods with the [`--engine-rpc-enabled`](../cli/options.md#engine-rpc-enabled) CLI option. + See the [Ethereum Engine API specification](https://github.com/ethereum/execution-apis/blob/0b965fb714ccd3faa3c939fdce1726e56679cdec/src/engine/specification.md) for more information. ## Methods diff --git a/docs/public-networks/tutorials/besu-teku-mainnet.md b/docs/public-networks/tutorials/besu-teku-mainnet.md index 168a90dbeb0..e38e8342343 100644 --- a/docs/public-networks/tutorials/besu-teku-mainnet.md +++ b/docs/public-networks/tutorials/besu-teku-mainnet.md @@ -44,6 +44,7 @@ besu \ --rpc-ws-host="0.0.0.0" \ --host-allowlist=,127.0.0.1,localhost \ --engine-host-allowlist=,127.0.0.1,localhost \ + --engine-rpc-enabled \ --engine-jwt-secret= ``` @@ -66,6 +67,8 @@ Also, in the command: service. - [`--rpc-ws-host`](../reference/cli/options.md#rpc-ws-host) is set to `0.0.0.0` to allow remote RPC connections. +- [`--engine-rpc-enabled`](../reference/cli/options.md#engine-rpc-enabled) enables the + [Engine API](../reference/engine-api/index.md). You can modify the option values and add other [command line options](../reference/cli/options.md) as needed. diff --git a/docs/public-networks/tutorials/besu-teku-testnet.md b/docs/public-networks/tutorials/besu-teku-testnet.md index 03b280ec962..1c92ce88888 100644 --- a/docs/public-networks/tutorials/besu-teku-testnet.md +++ b/docs/public-networks/tutorials/besu-teku-testnet.md @@ -54,6 +54,7 @@ Run the following command or specify the options in a [configuration file](../ho --rpc-ws-host=0.0.0.0 \ --host-allowlist="*" \ --engine-host-allowlist="*" \ + --engine-rpc-enabled \ --engine-jwt-secret= ``` @@ -69,6 +70,7 @@ Run the following command or specify the options in a [configuration file](../ho --rpc-ws-host=0.0.0.0 \ --host-allowlist="*" \ --engine-host-allowlist="*" \ + --engine-rpc-enabled \ --engine-jwt-secret= ```