-
Notifications
You must be signed in to change notification settings - Fork 200
Add getBlobs endpoint #546
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
+84
−0
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
557d749
Add getBlobs endpoint
nflaig aa3b921
Add changelog entry
nflaig a70801d
Merge branch 'master' into nflaig/get-blobs
nflaig a63410b
Merge branch 'master' into nflaig/get-blobs
nflaig 269b406
Use versioned_hashes instead of indices for filtering
nflaig bcbb342
Update description
nflaig File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,69 @@ | ||
| get: | ||
| operationId: getBlobs | ||
| summary: Get blobs | ||
| description: | | ||
| Retrieves blobs for a given block id. | ||
| Depending on `Accept` header it can be returned either as json or as bytes serialized by SSZ. | ||
|
|
||
| If the `versioned_hashes` parameter is specified, only the blobs for the specified versioned hashes will be returned. Blobs are | ||
| returned as an ordered list matching the order of their corresponding KZG commitments in the block. | ||
|
|
||
| After the Fulu fork, only supernodes (which custody all data columns) are required to return blobs. Clients may implement | ||
| blob reconstruction logic for non-super nodes. | ||
| tags: | ||
| - Beacon | ||
| parameters: | ||
| - name: block_id | ||
| in: path | ||
| required: true | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/parameters/BlockId" | ||
| - name: versioned_hashes | ||
| in: query | ||
| description: Array of versioned hashes for blobs to request for in the specified block. Returns all blobs in the block if not specified. | ||
| required: false | ||
| schema: | ||
| type: array | ||
| uniqueItems: true | ||
| items: | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/schemas/VersionedHash" | ||
| responses: | ||
| "200": | ||
| description: "Successful response" | ||
| content: | ||
| application/json: | ||
| schema: | ||
| title: GetBlobsResponse | ||
| type: object | ||
| required: [execution_optimistic, finalized, data] | ||
| properties: | ||
| execution_optimistic: | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/schemas/ExecutionOptimistic" | ||
| finalized: | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/schemas/Finalized" | ||
| data: | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/schemas/Blobs" | ||
nflaig marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| application/octet-stream: | ||
| schema: | ||
| description: "SSZ serialized `List[Blob, MAX_BLOB_COMMITMENTS_PER_BLOCK]` bytes. Use Accept header to choose this response type" | ||
| "400": | ||
| description: "The block ID supplied could not be parsed" | ||
| content: | ||
| application/json: | ||
| schema: | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/schemas/ErrorMessage" | ||
| example: | ||
| code: 400 | ||
| message: "Invalid block ID: current" | ||
| "404": | ||
| description: "Block not found" | ||
| content: | ||
| application/json: | ||
| schema: | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/schemas/ErrorMessage" | ||
| example: | ||
| code: 404 | ||
| message: "Block not found" | ||
| "406": | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/responses/NotAcceptable" | ||
| "500": | ||
| $ref: "../../../beacon-node-oapi.yaml#/components/responses/InternalError" | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.