Skip to content
This repository has been archived by the owner on Jun 23, 2022. It is now read-only.

RobThree/NPushOver

Repository files navigation

Logo NPushOver

.Net Pushover client (https://pushover.net), available as a NuGet package.

This library is not written or supported by Superblock (the creators of Pushover).

Quick start:

  • Register your application, set its name (and optionally upload an icon) and get an API token in return (referred to as ApplicationKey in NPushover).
  • Create an instance of the Pushover class and provide it with the ApplicationKey.
  • You're all set to send your first message!
var po = new Pushover("[APPLICATIONKEY-HERE]");

// Quick message:
var msg = Message.Create("Hello world!");
var sendtask = po.SendMessageAsync(msg, "[RECIPIENT-ID-HERE]");

The Message class contains several convenience-methods to quickly create a Message; however you can also simply instantiate your own:

var po = new Pushover("[APPLICATIONKEY-HERE]");

// Quick message:
var msg = new Message(Sounds.Siren)
{
    Title = "The roof!",
    Body = "The roof is on fire!",
    Priority = Priority.Emergency,
    RetryOptions = new RetryOptions
    {
        RetryEvery = TimeSpan.FromSeconds(30),
        RetryPeriod = TimeSpan.FromHours(3)
    },
    SupplementaryUrl = new SupplementaryURL
    {
        Uri = new Uri("http://robiii.me"),
        Title = "Awesome dude!"
    },
};
var sendtask = po.SendMessageAsync(msg, "[RECIPIENT-ID-HERE]");

All REST methods found in the Pushover API are available in this library. We support:

NPushover also has support for reading rate-limiting information returned by Pushover which should make it easy to find out in time when you're about to run out of messages.

Documentation

NPushover is well documented in code, comes with a helpfile (or Sandcastle helpfile builder project if you want to build it yourself). NPushover is built with Pushover's API documentation at hand. Though some names/properties may sometimes deviate a bit to make things more consistent within the API itself and/or to .Net conventions, you should be able to get around in NPushover quickly.

As more and more unittests are created, usage of specifics should be found easily in those unittests too.

Build status NuGet version

About

Full fledged, async, .Net Pushover client

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages