.Net Pushover client (https://pushover.net), available as a NuGet package.
This library is not written or supported by Superblock (the creators of Pushover).
- 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 theApplicationKey
. - 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:
- Pushing messages (including HTML, supplementary URL's, notification sounds etc.)
- User/Group verification
- Receipts and Callbacks (including cancelling retries)
- User key migration
- Assigning licenses
- Open Client API
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.
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.