Device to Device Push Notifications

how to push notification from device to other device , i don’t talk about firebase cloud function
i want when user do some action to notify the other user
my back end not firebase so i want solution to use it inside my application
how to programmatly send notification from device to other device by code in side my app

thanks

any solution please … ?