Posts

Showing posts with the label #pushNotification

Push Notifications in .NET MAUI: A Comprehensive Guide

Image
Please, support my blog by clicking on our sponsors ad! IF you need this project DM me on whatsaap "9724784544" What are Push Notifications? Push notifications are messages sent directly to a user's mobile device from a server, even when the app is not actively being used. They are a crucial part of mobile app development, enabling real-time communication with users. Notifications can inform users about new content, updates, reminders, or other important information, thus enhancing user engagement and retention. Watch video to understand code: Implementing Push Notifications in Android and iOS using .NET MAUI In this blog, we'll explore how to implement push notifications in a .NET MAUI application for both Android and iOS platforms. We'll start by setting up a Firebase account, configuring the necessary dependencies, and writing the required code for Android and iOS.  Setting Up a Firebase Account Go to Firebase Console: Navigate to the Firebase ...

Continuation: Enhancing Push Notifications in Flutter Using Firebase

Image
Enhancing Push Notifications in Flutter  In the previous blog post , we covered the fundamental steps to integrate push notifications into a Flutter app using Firebase Cloud Messaging (FCM). In this continuation, we'll explore how to open a specific page when the user clicks on a notification, thereby enhancing the user experience and providing contextual information. Let's dive into the code changes required to handle notifications effectively: Updating firebase_api.dart import 'package:firebase_messaging/firebase_messaging.dart'; import 'package:pushnotification/Page/notification_screen.dart'; import 'package:pushnotification/main.dart'; class FirebaseApi { final _firebaseMessaging = FirebaseMessaging.instance; void handleMessage(RemoteMessage? message) { if (message == null) return; navigatorKey.currentState?.pushNamed(NotificationScreen.route, arguments: message); } Future<void> handleBackgroundMessage(RemoteMessage mes...

Implementing Push Notifications in Flutter Using Firebase

Image
Please, support my blog by clicking on our sponsors ad! Unlocking the Power of Push Notifications in Flutter with Firebase Cloud Push notifications are an essential aspect of modern mobile applications, allowing developers to engage users even when they are not actively using the app. In Flutter, integrating push notifications can be efficiently done through Firebase Cloud Messaging (FCM). In this tutorial, we'll walk through the steps to set up push notifications in a Flutter app using Firebase and also open specific page when user tap on notification . Follow steps to create push notification in both project. Create Project in  https://console.firebase.google.com/ Create Project for push notification After Creating Project add app for both IOS and Android Project. Create app in project For Both IOS and Android project add Package name. Package name should be same as your package name in Android and Project. Click on Register App Download Google Service json. If you...

How to send Firebase Push Notification through API

Image
  Please, support my blog by clicking on our sponsors ad! In this blog  we learn how to send push notification. Now we will see how to send Notification using API. Create Server Key in Console firebase Call following API to send push notification URL:  https://fcm.googleapis.com/fcm/send Method: POST Headers: Authorization: key=server key (you can get it from firebase console) Content-Type: application/json Body { "to" : "FCM Token goes here", "notification" : { "body" : "New Lesson Added 1", "title": "Lokesh" } } Hope you understand this, Please share your feedback and enjoy coding.