From 3ab8cd9c9bf95ce670569d7a71b4c6df77abe719 Mon Sep 17 00:00:00 2001 From: Alexandra Tran Date: Fri, 4 Oct 2024 15:44:15 -0700 Subject: [PATCH 1/5] Document engine_getBlobsV1 Signed-off-by: Alexandra Tran --- .../reference/engine-api/index.md | 58 +++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/docs/public-networks/reference/engine-api/index.md b/docs/public-networks/reference/engine-api/index.md index 7ff03ab380a..b382c235a12 100644 --- a/docs/public-networks/reference/engine-api/index.md +++ b/docs/public-networks/reference/engine-api/index.md @@ -224,6 +224,64 @@ curl -X POST --data '{"jsonrpc":"2.0","method":"engine_forkchoiceUpdatedV1","par +### `engine_getBlobsV1` + +Returns the blobs corresponding to the specified blob versioned hashes. + +#### Parameters + +`blobHashes`: *array* of *strings* - Array of blob versioned hashes + +#### Returns + +`engineGetBlobsResultV1`: *array* of *objects* - Array of blob and proof objects + + + + + +```bash +curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014"]],"id":1}' http://127.0.0.1:8550 +``` + + + + + +```json +{ + "jsonrpc": "2.0", + "method": "engine_getPayloadBodiesByHashV1", + "params": [ + [ + "0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014" + ] + ], + "id": 67 +} +``` + + + + + +```json +{ + "jsonrpc": "2.0", + "id": 67, + "result": [ + { + "blob": "0x722662154e6d76b2b2b92e70c0cac3ccf534f9b74eb5b89819ec509083d00a503ae5c198d17634e79059c2cd735491...", + "proof": "0x80c5f2e1eb23939cf3600f61872e3e9964d0acafb440634e530d6139a193b889c56a0c07d737729dbe0626706fc9f25f" + } + ] +} +``` + + + + + ### `engine_getPayloadBodiesByHashV1` Returns the bodies of the execution payloads corresponding to the specified block hashes. From f6869916ac4881f152a2dfd24ca37f8e6e438e88 Mon Sep 17 00:00:00 2001 From: Alexandra Tran Date: Fri, 4 Oct 2024 15:47:44 -0700 Subject: [PATCH 2/5] minor fix Signed-off-by: Alexandra Tran --- docs/public-networks/reference/engine-api/index.md | 2 +- docusaurus.config.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/public-networks/reference/engine-api/index.md b/docs/public-networks/reference/engine-api/index.md index b382c235a12..bf5debc4a10 100644 --- a/docs/public-networks/reference/engine-api/index.md +++ b/docs/public-networks/reference/engine-api/index.md @@ -251,7 +251,7 @@ curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0 ```json { "jsonrpc": "2.0", - "method": "engine_getPayloadBodiesByHashV1", + "method": "engine_getBlobsV1", "params": [ [ "0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014" diff --git a/docusaurus.config.js b/docusaurus.config.js index 4c54b349017..1ac8cd46c87 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -220,7 +220,7 @@ const config = { prism: { theme: lightCodeTheme, darkTheme: darkCodeTheme, - additionalLanguages: ["solidity", "toml", "java"], + additionalLanguages: ["solidity", "toml", "java", "bash"], }, mermaid: { options: { From 57f1c6614019b4ec85a9d4c3bfb5643a869639cf Mon Sep 17 00:00:00 2001 From: Alexandra Carrillo <12214231+alexandratran@users.noreply.github.com> Date: Tue, 8 Oct 2024 21:36:28 -0700 Subject: [PATCH 3/5] Update docs/public-networks/reference/engine-api/index.md Co-authored-by: Stefan Pingel <16143240+pinges@users.noreply.github.com> Signed-off-by: Alexandra Carrillo <12214231+alexandratran@users.noreply.github.com> --- docs/public-networks/reference/engine-api/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/public-networks/reference/engine-api/index.md b/docs/public-networks/reference/engine-api/index.md index bf5debc4a10..367a2baea18 100644 --- a/docs/public-networks/reference/engine-api/index.md +++ b/docs/public-networks/reference/engine-api/index.md @@ -230,7 +230,7 @@ Returns the blobs corresponding to the specified blob versioned hashes. #### Parameters -`blobHashes`: *array* of *strings* - Array of blob versioned hashes +`versionedHashes`: *array* of *strings* - Array of blob versioned hashes #### Returns From f8ee37893d27e524203cfe7c669ec4ff2413b115 Mon Sep 17 00:00:00 2001 From: Alexandra Tran Date: Wed, 9 Oct 2024 10:37:27 -0700 Subject: [PATCH 4/5] address reviewer feedback Signed-off-by: Alexandra Tran --- docs/public-networks/reference/engine-api/index.md | 11 +++++++---- docs/public-networks/reference/engine-api/objects.md | 9 +++++++++ 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/docs/public-networks/reference/engine-api/index.md b/docs/public-networks/reference/engine-api/index.md index 367a2baea18..8cffabbad91 100644 --- a/docs/public-networks/reference/engine-api/index.md +++ b/docs/public-networks/reference/engine-api/index.md @@ -234,14 +234,15 @@ Returns the blobs corresponding to the specified blob versioned hashes. #### Returns -`engineGetBlobsResultV1`: *array* of *objects* - Array of blob and proof objects +`engineGetBlobsResultV1`: *array* of *objects* - Array of [blob and proof objects](objects.md#blob-and-proof-object), +items of which can be `null` ```bash -curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014"]],"id":1}' http://127.0.0.1:8550 +curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014","0x01f3a5c9d8e7b6a4c2d1e0f9b8a7c6d5e4f3a2b1c0d9e8f7b6a5c4d3e2f1a0b9"]],"id":1}' http://127.0.0.1:8550 ``` @@ -254,7 +255,8 @@ curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0 "method": "engine_getBlobsV1", "params": [ [ - "0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014" + "0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014", + "0x01f3a5c9d8e7b6a4c2d1e0f9b8a7c6d5e4f3a2b1c0d9e8f7b6a5c4d3e2f1a0b9" ] ], "id": 67 @@ -273,7 +275,8 @@ curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0 { "blob": "0x722662154e6d76b2b2b92e70c0cac3ccf534f9b74eb5b89819ec509083d00a503ae5c198d17634e79059c2cd735491...", "proof": "0x80c5f2e1eb23939cf3600f61872e3e9964d0acafb440634e530d6139a193b889c56a0c07d737729dbe0626706fc9f25f" - } + }, + null ] } ``` diff --git a/docs/public-networks/reference/engine-api/objects.md b/docs/public-networks/reference/engine-api/objects.md index ecd40054d9f..d8fac3b0137 100644 --- a/docs/public-networks/reference/engine-api/objects.md +++ b/docs/public-networks/reference/engine-api/objects.md @@ -9,6 +9,15 @@ tags: The following objects are parameters for or returned by the [Engine API methods](index.md). +## Blob and proof object + +Returned by [`engine_getBlobsV1`](index.md#engine_getblobsv1). + +| Key | Type | Value | +| --- | :-: | --- | +| `blob` | _Data_, 131072 Bytes | An SSZ-encoded `Blob` as defined in [EIP-4844](https://eips.ethereum.org/EIPS/eip-4844). | +| `proof` | _Data_, 48 Bytes | A `KZGProof` as defined in [EIP-4844](https://eips.ethereum.org/EIPS/eip-4844). | + ## Execution payload object Parameter for [`engine_newPayloadV1`](index.md#engine_newpayloadv1). Returned by [`engine_getPayloadV1`](index.md#engine_getpayloadv1). From f4e26c73438821f2d93b503d701246dbdebcf2f4 Mon Sep 17 00:00:00 2001 From: Alexandra Carrillo <12214231+alexandratran@users.noreply.github.com> Date: Wed, 9 Oct 2024 20:46:21 -0700 Subject: [PATCH 5/5] Apply suggestions from code review Co-authored-by: Stefan Pingel <16143240+pinges@users.noreply.github.com> Signed-off-by: Alexandra Carrillo <12214231+alexandratran@users.noreply.github.com> --- docs/public-networks/reference/engine-api/index.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/public-networks/reference/engine-api/index.md b/docs/public-networks/reference/engine-api/index.md index 8cffabbad91..dc5b7dae74e 100644 --- a/docs/public-networks/reference/engine-api/index.md +++ b/docs/public-networks/reference/engine-api/index.md @@ -242,7 +242,7 @@ items of which can be `null` ```bash -curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014","0x01f3a5c9d8e7b6a4c2d1e0f9b8a7c6d5e4f3a2b1c0d9e8f7b6a5c4d3e2f1a0b9"]],"id":1}' http://127.0.0.1:8550 +curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0x010657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014","0x01f3a5c9d8e7b6a4c2d1e0f9b8a7c6d5e4f3a2b1c0d9e8f7b6a5c4d3e2f1a0b9"]],"id":1}' http://127.0.0.1:8550 ``` @@ -255,7 +255,7 @@ curl -X POST --data '{"jsonrpc":"2.0","method":"engine_getBlobsV1","params":[["0 "method": "engine_getBlobsV1", "params": [ [ - "0x000657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014", + "0x010657f37554c781402a22917dee2f75def7ab966d7b770905398eba3c444014", "0x01f3a5c9d8e7b6a4c2d1e0f9b8a7c6d5e4f3a2b1c0d9e8f7b6a5c4d3e2f1a0b9" ] ],