<div align="center">
<p><h1>zipwhip-rs</h1> </p>
<p><strong>Fast, asynchronous, and safe wrapper around the <a href="https://developers.zipwhip.com/">Zipwhip API</strong></p>
<p>
[](https://actions-badge.atrox.dev/ajmwagar/zipwhip-rs/goto)
[](https://crates.io/crates/zipwhip-rs)
[](https://docs.rs/zipwhip-rs)
[](https://crates.io/crates/zipwhip-rs)
[](https://blog.rust-lang.org/2019/12/19/Rust-1.40.0.html)
[](./LICENSE)
</p>
<h3>
<a href="https://zipwhip.com">Website</a>
<span> | </span>
<a href="https://github.com/ajmwagar/zipwhip-rs/tree/master/examples">Examples</a>
</h3>
</div>
<br>
## Features
- Asynchronous SMS/MMS Client
- Low-Latency, High Throughput [chatbots](https://github.com/ajmwagar/zipwhip-rs/tree/master/examples/chatbot)
- Bulk SMS/MMS functions
- Webhook managment
- Runtime Agnostic (using `std::future::Future`) (`tokio` is only used to run unit tests)
## Send an SMS
```rust
#[tokio::main] // or `async-std`
async fn main() -> Result<(), Box<dyn std::error::Error>> {
// Create API Client
let zw_client = zipwhip_rs::Client::with_key("<zipwhip session key>");
// Send SMS
zw_client.send_sms("+12064517010", "Hello, Zipwhip-rs!").await?;
Ok(())
}
```
## Running tests
`ZIPWHIP_SESSION_KEY=<key> ZIPWHIP_TEST_NUMBER=<phone_number> cargo test`