mwapi 0.7.0

A MediaWiki API client library
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use serde::Deserialize;
use serde_json::Value;
use std::collections::HashMap;

#[derive(Deserialize, Debug)]
pub(crate) struct SimpleResponse {
    pub(crate) upload: SimpleUploadResponse,
}

#[derive(Deserialize, Debug)]
#[serde(tag = "result")]
pub(crate) enum SimpleUploadResponse {
    Warning { warnings: HashMap<String, Value> },
    Success { filename: String },
}