Is there anyway to do simple laravel notification - laravel

Is there anyway to make laravel notification in a simple way? I need to do notification function for my complaint handling system where the system should notify the user if complaint exist in their account which should be User Id.

You can make a pusher like system with redis, node.js and socket.io
You have a tutorial in Medium

Related

How to send notification to specific user in Expo/Laravel

I have an Expo app with a Laravel backend and I want to send notifications to the app. But the condition is that only a specific user can receive it.
I installed the Following library Exponent Notifications
I've Installed expo-notifications as well
But I don't know How it works, How I can listen to the notification channel and How to send Notification from backend.
With Expo you don't get to pick the push notification service according to you, you can try Firebase Cloud messaging or One Signal, but I don't think you can do it only by your Laravel Backend

fastest way to send notification to all user laravel

I am building an app in laravel where I send a mail notification to all users once a new channel I create. So far I am using
$users=User::all();
\Illuminate\Support\Facades\Notification::send($users,new NewChannel($channel));
To send a notification to all users. Is there any package or way that would make the process faster? It is already taking years just with 5 users
You can look into queues to make the request more responsive, though it will take the same time to process the mails but it will happen in background. Another approach would be to use a third party service like sendGrid to take away the processing from your end.

Laravel notification facebook driver get fb_messenger_user_id

I want to give users the ability to get notifications via the facebook messenger. However, I don't really know how to get the fb_messenger_user_id from a user.
I can get a personalized ID for the chat if a user starts chatting with my bot, but with this, I can't really verify which user that is. Is there something I've overseen? Something like a button similar to the "login with facebook" button?
Also, as far as I understand the docs, I am only allowed to send messages in a time frame of 24h after the last message from the user.
Can someone tell me how to use the facebook notifications properly?
As a side note: I am planning to implement botman into my existing app. I don't know how much this affects the notifications.

is it possible to notify all users using Laravel notification with pusher?

Is it possible to create/send notification(s) to all users when there is new announcement.
I want all users to be notified using the database notification.
Since most of the tutorials I have seen are all email notification, is this possible? Please attach links or any idea on how I could implement this.
Literally in the documentation:
Alternatively, you may send notifications via the Notification facade.
This is useful primarily when you need to send a notification to
multiple notifiable entities such as a collection of users. To send
notifications using the facade, pass all of the notifiable entities
and the notification instance to the send method:
Notification::send($users, new InvoicePaid($invoice));
So yes, you can send to all user by getting them from the database and sending a notification using the facade.
For example:
Notification::send(User::all(), new InvoicePaid($invoice));

How to add a dynamic results section to Laravel

I made a laravel app which uses an index method that delivers a collection of the client's available appointments (think hairdresser) to the page (as an api), which I then display using vue/vuetify.
The client is saying they would like the appointments on the page to be dynamic/live eg if someone books an appointment, then all other logged in users will see that appointment disappear from the list on their screen.
I have no idea how I would do this, although I have had one idea - I somehow incorporate node/non-blocking on the server, like a chat room, but only for this part of the app.
Or is there a way to do this with laravel/nginx?
Thanks in advance - I don't know what to search for!
I believe you are looking for Broadcasting (Documentation Link). You would need to:
Configure your broadcasting driver (you could give pusher a try for quick setup and tinkering)
Configure your Laravel backend to dispatch a new event whenever a new appointment is made, (e.g. event(new AppointmentCreated($appointment)) where AppointmentCreated implements the ShouldBroadcast interface. You can combine this with Model Events
Update your frontend to receive your broadcast (Check Laravel Echo). Once you receive a broadcast, update the UI to mark this appointment as unavailable i.e, make it disappear

Resources