lark-channel 0.4.0

Lark/Feishu Channel SDK for Rust
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use serde::{Deserialize, Serialize};
use serde_json::Value;

#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub struct Card {
    pub schema: String,
    pub body: Value,
}

impl Card {
    pub fn raw(body: Value) -> Self {
        Self {
            schema: "2.0".to_owned(),
            body,
        }
    }
}