#notifications

pushover

A wrapper for the Pushover API

4 releases (breaking)

0.4.0 Apr 30, 2022
0.3.0 Feb 6, 2018
0.2.0 Aug 30, 2017
0.1.0 Aug 27, 2017

#45 in #notification

Download history 11/week @ 2024-08-29 17/week @ 2024-09-19 19/week @ 2024-09-26 1/week @ 2024-10-03 2/week @ 2024-10-10 1/week @ 2024-10-31 18/week @ 2024-11-07 7/week @ 2024-11-14 9/week @ 2024-11-21 5/week @ 2024-11-28 14/week @ 2024-12-05 45/week @ 2024-12-12

73 downloads per month
Used in chirp-pushover

MIT license

66KB
2K SLoC

Pushover

Build Status License Crates.io Docs.rs

A Rust wrapper for the Pushover API (https://pushover.net/api).

Installation

Usage

Add the following to Cargo.toml:

[dependencies]
pushover = "0.4.0"

Synchronous example:


use pushover::API;
use pushover::requests::message::SendMessage;

fn send_message() {
    let api = API::new();

    let msg = SendMessage::new("token", "user_key", "hello");

    let response = api.send(&msg);
    println!("{:?}", response.expect("Error sending message"));
}

Asynchronous example:


use pushover::API;
use pushover::requests::message::SendMessage;

async fn send_message() {
    let api = API::new();

    let msg = SendMessage::new("token", "user_key", "hello");
    let response = api.send_async(&msg).await;

    println!("{:?}", response.expect("Error sending message"));
}

Dependencies

~12–21MB
~309K SLoC