Add method to fetch a block's events to the RPC

This commit is contained in:
Luke Parker
2025-11-13 04:50:54 -05:00
parent 367a5769e8
commit 509bd58f4e
10 changed files with 324 additions and 70 deletions

View File

@@ -505,6 +505,9 @@ sp_api::impl_runtime_apis! {
}
impl crate::SeraiApi<Block> for Runtime {
fn events() -> Vec<Vec<u8>> {
Core::events()
}
fn validators(network: NetworkId) -> Vec<serai_abi::primitives::crypto::Public> {
// Returning the latest-decided, not latest and active, means the active set
// may fail to peer find if there isn't sufficient overlap. If a large amount reboot,