use serde::{Deserialize, Serialize};
use serde_json::Value;
use std::collections::HashMap;

#[derive(Serialize, Deserialize)]
#[serde(tag = "kind")]
pub enum WireValue {
    Text { value: String },
    Count { value: u64 },
}

#[derive(Serialize, Deserialize)]
pub enum Status {
    Ready,
    Pending,
}

#[derive(Serialize, Deserialize)]
pub enum ConfigMode {
    Fast,
    Safe,
}

#[derive(Deserialize)]
#[serde(deny_unknown_fields)]
pub struct RequestConfig {
    pub mode: ConfigMode,
    pub extras: HashMap<String, Value>,
    pub status: Status,
}