clrigctl/src/cloudlog.rs

17 lines
362 B
Rust
Raw Normal View History

2023-11-29 15:53:47 +01:00
use serde::Serialize;
use reqwest::Client;
#[derive(Serialize)]
pub struct RadioData {
pub key: String,
pub radio: String,
pub frequency : String,
pub mode: String,
2023-11-29 19:55:17 +01:00
pub power: String,
2023-11-29 15:53:47 +01:00
}
#[tokio::main]
pub async fn upload(url: &str, radio_data: &RadioData) {
2023-11-29 19:55:17 +01:00
let _res = Client::new().post(url).json(&radio_data).send().await.unwrap();
}