mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-19 12:56:12 +00:00
Make API friendly to block explorers (#702)
* Add validator index to duties response * Add `get_state` method to beacon chain * Improve /beacon/validators endpoint * Add validators/all and validators/active endpoints * Start refactor of HTTP docs * Document /beacon/heads endpoint * Remove some unused API endpoints * Improve API docs * Add methods to get all validator duties * Improve docs * Remove dead links * Make tables left-justified * Add /consensus/vote_count endpoint * Add /consensus/individual_votes endpoint * Update formatting * Tidy * Add committees endpoint * Strictly require 0x prefix for serde in BLS * Update docs to have 0x prefix * Fix failing tests * Add unfinished code * Improve testing, fix bugs * Tidy, ensure all beacon endpoints smoke tested * Fix pubkey cache error * Address comments with docs
This commit is contained in:
@@ -6,6 +6,7 @@ extern crate network as client_network;
|
||||
|
||||
mod beacon;
|
||||
pub mod config;
|
||||
mod consensus;
|
||||
mod error;
|
||||
mod helpers;
|
||||
mod metrics;
|
||||
@@ -38,9 +39,12 @@ use tokio::sync::mpsc;
|
||||
use url_query::UrlQuery;
|
||||
|
||||
pub use crate::helpers::parse_pubkey_bytes;
|
||||
pub use beacon::{BlockResponse, HeadResponse, StateResponse};
|
||||
pub use beacon::{
|
||||
BlockResponse, CanonicalHeadResponse, Committee, HeadBeaconBlock, StateResponse,
|
||||
ValidatorRequest, ValidatorResponse,
|
||||
};
|
||||
pub use config::Config;
|
||||
pub use validator::{BulkValidatorDutiesRequest, ValidatorDuty};
|
||||
pub use validator::{ValidatorDutiesRequest, ValidatorDuty};
|
||||
|
||||
pub type BoxFut = Box<dyn Future<Item = Response<Body>, Error = ApiError> + Send>;
|
||||
pub type NetworkChannel = Arc<RwLock<mpsc::UnboundedSender<NetworkMessage>>>;
|
||||
|
||||
Reference in New Issue
Block a user