Add post attestation v2 endpoint logic to attestation service

This commit is contained in:
Eitan Seri-Levi
2024-12-13 21:51:35 +07:00
parent 366bed3a41
commit 68292ad9dd
3 changed files with 134 additions and 73 deletions

View File

@@ -30,6 +30,7 @@ pub use reqwest::{StatusCode, Url};
pub use sensitive_url::{SensitiveError, SensitiveUrl};
use serde::{de::DeserializeOwned, Serialize};
use ssz::Encode;
use types::attestation::SingleAttestation;
use std::fmt;
use std::future::Future;
use std::path::PathBuf;
@@ -1316,7 +1317,7 @@ impl BeaconNodeHttpClient {
/// `POST v2/beacon/pool/attestations`
pub async fn post_beacon_pool_attestations_v2<E: EthSpec>(
&self,
attestations: &[Attestation<E>],
attestations: &[SingleAttestation],
fork_name: ForkName,
) -> Result<(), Error> {
let mut path = self.eth_path(V2)?;