Warning 🚧 (WIP), this crate is undering develop, api may be changed.
wx-sdk
is a WeChat SDK written in Rust.First, please refer to this page to provide these values: token
, EncodingAESKey
,EncodingMode
.
```rust
use wx_sdk::wechat::{ServerConfig, EncodingMode};
let config = ServerConfig::new(token, EncodingMode::Plain);
let sdk = WxSdk::newwithdefaulttokenclient("appid", "appsecret", config);
Then, you can use the sdk functions, like get current menu info:
rust
let mpsdk = WxSdk::mp(&sdk);
let menu = mpsdk.menu().getcurrentselfmenu_info().await;
```
There're mp
, pay
, wxa
features gates, we have only implemented the mp
feature now. Please check FEATURES.md
Issue reports and Pull Requests are always welcome!
wx-sdk is available under the MIT License