brk_types 0.3.0-alpha.3

Structs used throughout BRK
Documentation
use schemars::JsonSchema;
use serde::{Deserialize, Serialize};

use crate::PoolSlug;

/// Mining pool identification for a block
#[derive(Debug, Clone, Serialize, Deserialize, JsonSchema)]
#[serde(rename_all = "camelCase")]
pub struct BlockPool {
    /// Unique pool identifier
    pub id: u8,

    /// Pool name
    pub name: String,

    /// URL-friendly pool identifier
    pub slug: PoolSlug,

    /// Alternative miner names (if identified)
    pub miner_names: Option<String>,
}