-
Notifications
You must be signed in to change notification settings - Fork 201
Add getAggregatedAttestationV2 to support EIP-7549 #447
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
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
d28147c
getAggregatedAttestationV2
ensi321 c6d4425
Address comment
ensi321 8c060ff
Add version header to response
nflaig 823b161
Deprecate v1 api
nflaig 5730060
Update changelog
nflaig 911b4b4
Change ordering of attestation fields
ensi321 510e0e0
Update spec reference
nflaig d00aebf
Merge branch 'master' into eip-7549
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,59 @@ | ||
| get: | ||
| operationId: "getAggregatedAttestationV2" | ||
| summary: "Get aggregated attestation" | ||
| description: | | ||
| Aggregates all attestations matching given attestation data root, slot and committee index. | ||
|
|
||
| A 503 error must be returned if the block identified by the response | ||
| `beacon_block_root` is optimistic (i.e. the aggregated attestation attests | ||
| to a block that has not been fully verified by an execution engine). | ||
|
|
||
| A 404 error must be returned if no attestation is available for the requested | ||
| `attestation_data_root`. | ||
| tags: | ||
| - ValidatorRequiredApi | ||
| - Validator | ||
| parameters: | ||
| - name: attestation_data_root | ||
| in: query | ||
| required: true | ||
| description: "HashTreeRoot of AttestationData that validator wants aggregated" | ||
| schema: | ||
| $ref: '../../beacon-node-oapi.yaml#/components/schemas/Root' | ||
| - name: slot | ||
| in: query | ||
| required: true | ||
| schema: | ||
| $ref: '../../beacon-node-oapi.yaml#/components/schemas/Uint64' | ||
| - name: committee_index | ||
| in: query | ||
| required: true | ||
| schema: | ||
| $ref: '../../beacon-node-oapi.yaml#/components/schemas/Uint64' | ||
| responses: | ||
| "200": | ||
| description: "Returns aggregated `Attestation` object with same `AttestationData` root, slot and committee index." | ||
| headers: | ||
| Eth-Consensus-Version: | ||
| $ref: '../../beacon-node-oapi.yaml#/components/headers/Eth-Consensus-Version' | ||
| content: | ||
| application/json: | ||
| schema: | ||
| title: GetAggregatedAttestationV2Response | ||
| type: object | ||
| required: [version, data] | ||
| properties: | ||
ensi321 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| version: | ||
| type: string | ||
| enum: [phase0, altair, bellatrix, capella, deneb, electra] | ||
| example: "phase0" | ||
| data: | ||
| anyOf: | ||
| - $ref: '../../beacon-node-oapi.yaml#/components/schemas/Attestation' | ||
| - $ref: '../../beacon-node-oapi.yaml#/components/schemas/Electra.Attestation' | ||
| "400": | ||
| $ref: '../../beacon-node-oapi.yaml#/components/responses/InvalidRequest' | ||
| "404": | ||
| $ref: '../../beacon-node-oapi.yaml#/components/responses/NotFound' | ||
| "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
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,18 @@ | ||
| Electra: | ||
| Attestation: | ||
| type: object | ||
| description: "The [`Attestation`](https://github.com/ethereum/consensus-specs/blob/v1.5.0-alpha.3/specs/electra/beacon-chain.md#attestation) object from the CL spec." | ||
| required: [aggregation_bits, data, signature, committee_bits] | ||
| properties: | ||
| aggregation_bits: | ||
| $ref: "../primitive.yaml#/BitList" | ||
| description: "Attester aggregation bits." | ||
| data: | ||
| $ref: "../attestation.yaml#/AttestationData" | ||
nflaig marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| signature: | ||
| $ref: "../primitive.yaml#/Signature" | ||
| description: "BLS aggregate signature." | ||
| committee_bits: | ||
| $ref: "../primitive.yaml#/Bitvector" | ||
| description: "Committee bits." | ||
| example: "0x0000000000000000000000000000000000000000000000000000000000000001" | ||
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.