PushNotification_dotNET 1.1.0

Install-Package PushNotification_dotNET -Version 1.1.0
dotnet add package PushNotification_dotNET --version 1.1.0
<PackageReference Include="PushNotification_dotNET" Version="1.1.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add PushNotification_dotNET --version 1.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: PushNotification_dotNET, 1.1.0"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install PushNotification_dotNET as a Cake Addin
#addin nuget:?package=PushNotification_dotNET&version=1.1.0

// Install PushNotification_dotNET as a Cake Tool
#tool nuget:?package=PushNotification_dotNET&version=1.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

#DOCS PushNotification is a framework for Notification .NET applications. Handle Push Notifications. Across iOS, Android and UWP from a single API.

Supported platforms:

  • .NET Framework 3.5, 4, 4.5, 4.6 & 4.7
  • .NET Standard 1.3+ and 2.0+;
  • .NET Framework 4 client profile
  • Xamarin Android, Xamarin iOS
  • UWP
  • Windows Phone 8
  • Silverlight 4 and 5
  • Mono 4

Example: class Program { private static readonly PushNotification Notification = PushNotification.GetPushNotification();

static void Main(string[] args)
{
	Notification.Config.YOUR_FCM_SERVER_API_KEY = "AIzaSyAlGYEvGdTGOR1qSbJ1t35-DJbB7u0FMJ0";
	Notification.Config.YOUR_FCM_SENDER_ID = "";

	SendNotification();

	SendCustomNotification();

	Console.ReadLine();
}

public static void SendNotification()
{
	string fcmDeviceId = "fqVLhCOtiz8:APA91bGEyCjgWkTFCdJVeIldTTAyUF2eu36zf0_rE9cCFlMn7-MiMviGKTcvGfIb0TKmWJKbDdJGbz4Qw3sQv5EG5GduDyM7uoddsTpYXjdYfAOt0Sv7NVLBoBIyB4_nPR0PkrR5LJYB";
	string title = "Test Miky";
	string message = "My Message";

	string sResponseFromServer = Notification.SendNotification(fcmDeviceId, title, message);
	Console.WriteLine(sResponseFromServer);
}

public static void SendCustomNotification()
{
	string fcmDeviceId = "fqVLhCOtiz8:APA91bGEyCjgWkTFCdJVeIldTTAyUF2eu36zf0_rE9cCFlMn7-MiMviGKTcvGfIb0TKmWJKbDdJGbz4Qw3sQv5EG5GduDyM7uoddsTpYXjdYfAOt0Sv7NVLBoBIyB4_nPR0PkrR5LJYB";
	string _title = "Test Miky";
	string _message = "My Message";

	var data = new
	{
		to = fcmDeviceId, // Uncoment this if you want to test for single device
		priority = "high",
		content_available = true,
		notification = new
		{
			title = _title,
			body = _message,
			//icon="myicon"
			badge = 1,
			sound = "default"
		}
	};

	string sResponseFromServer = Notification.SendNotification(fcmDeviceId, data);
	Console.WriteLine(sResponseFromServer);
}

}

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.1.0 177 10/27/2021
1.0.0 787 1/17/2019

Awesome application PushNotification utility.