pushover_api 0.1.0

A Rust library to interact with the Pushover.net API.
Documentation

A Rust library to interact with the Pushover.net API.

Note

This library is woefully incomplete and primarily built on a "want to have" basis. If you find yourself missing something from the Pushover API and want it implemented, please create an issue for it (or email me at me@bauke.xyz).

Examples

To send just a message to a user, you can use the convenience send_simple_message function.

use pushover_api::send_simple_message;

send_simple_message("application token", "user key", "Message").unwrap();

To send a more complex message, create a Message and send() it.

use pushover_api::Message;

let message = Message {
token: "application token".to_string(),
user: "user key".to_string(),
message: "Message".to_string(),
title: Some("Title".to_string()),
url: Some("https://example.com".to_string()),
..Message::default()
};

let response = message.send().unwrap();
dbg!(response);