I'm sending messages to several iOS Apps via
FCM by using their HTTP protocol API,
and I need a list of message records including the payload, sent time, and platform like what I could monitor in the Firebase Notification Console.
It seems that messages sent via HTTP API wouldn't be recorded and shown in the console (only those sent manually in the console would).
I haven't found any API documents related to those messaging events/log fetching.
Is there a way to fetch this kind of message information from FCM?
As of August 2018, stats for messages sent using the FCM API are now visible from the console. From the Cloud Messaging section, click on the Reports tab. From there, you will be able to filter by message type (notification, data, and all)
It would seem that the Impressions and Opens are still only available for messages sent using the console. But Sends for sure now counts the messages sent using the FCM API.
Reference: https://firebase.googleblog.com/2018/08/in-app-messaging-crashlytics.html
Update: The FCM Diagnostics page has been disabled since last year.
If you have a Play Dev Console account and if your app is in at least Alpha Testing, you can make use of the Diagnostics and Statistics page. However, if you're looking for an API, there is currently no API available for it.
Otherwise, I think most of the details you need (like the payload and time sent) can be logged from your app server alone.
And just to support what you already mentioned in your post, as stated by #FrankvanPuffelen here:
The Firebase Notifications charts only show analytics for messages that were sent using the Firebase Notifications panel.
There is currently no public API to send Notifications to audiences. The web interface in the console is the only way to send them.
There is currently no API to feed your own FCM messages into the Firebase Notifications analytics panels.
If you want to fetch data on push notification client side you could use the BigQuery exports of Analytics data.
Here is a list of events, as you can see there are several events on notifications, including notification_open and notification_send.
Unfortunately notification_send seems to be available only for Android apps. I don't know why since the Firebase GUI console Message Delivery Report does contain iOS sends as well.
Related
The Azure Communication Service Github repo says that the service has the capability to "Send and Receive SMS messages",
But I only see "Send" functions in both Microsoft Docs (https://learn.microsoft.com/en-us/rest/api/communication/sms) and the Python SDK Github repo (https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/communication/azure-communication-sms).
I don't see anything about RECEIVING SMS on the ACS roadmap either.
How is this done using the ACS Python SDK?
ACS already supports receiving messages through Event Grid. In summary you need to register to the SMS Received event, and you should receive Event Grid events each time linked number receive a message.
For more information you can check SMS FAQ and our QuickStart sample here Quickstart: Handle SMS and delivery report events
When you set up the Event Grid you can configure it to forward the notification to a Web Hook for example and in this way, you can notify your application about the incoming message.
I'm able to push messages from Python backend (which is on a VM instance) to topic & see messages on Pub/sub topic. But there is no code for pulling data from topic using angular. I want to pull that data & show it to Angular UI. Could you please help me with this?
With PubSub, there are 2 subscriptions mode that imply 2 kind of authentication:
Push Subscription, where the sender (PubSub subscription) need to be authenticated to push the message to a secure endpoint
Pull Subscription, where the client need to be authenticated to be able to get the messages.
So, in your case, you need to authenticate your Angular app on PubSub Pull Subscription to be able to read the messages. You have 2 solutions:
Either you generate a service account key file and you put it in your static code. It's obviously a stupid idea, because you share publicly a secret, and thus it's like if there is no security!
Or, because the previous solution is like having no security, you can make the pull subscription public. Grant allUsers as PubSub Subscriber.
It will work, but there is a design issue: anyone will be able to subscribe to your Pull subscription, and because the messages aren't duplicated between the subscriber, you will potentially loose messages.
A better solution could be to serve an endpoint in streaming, with Cloud Run for example, to authenticate your user on the Cloud Run endpoint, and to stream the messages from PubSub pull subscription through Cloud Run streaming connexion.
Like this, you add a security layer, something like a proxy.
Currently I am working on a Schoolproject and I need to send a Notification to a self written Xamarin Forms App from my API. It all runs on a local network and the App can already communicate with the Api, now i want my api to send a notification to my phone if a specific event turns true. How do I do this? (Oh and I am using Python flask for my API, if u need this Information)
Use Push notification for it. As soon as there is a need to call
mobile app from web server send a push notification. Handle the push
notification on application side to make a call to web api as soon as
it receives the push notification with specific payload.
Use Web Sockets if server events are too frequent.
I'm using Facebook Graph API with Python. I'm able to request some basic information about my own profile such as birthday and location with:
events = graph.request('me?fields=location,birthday')
I was wondering is it possible to also request all the messages we sent through Facebook Messenger?
No, that is not possible.
API access to user messages has been removed long ago.
Only page conversations can be accessed via API.
I have an Android app to which I send push notifications via firebase. Now I am making a Django app that will run on my server. I wanted to send the notification to my app using that django app. I started testing the firebase admin SDK for python. I was learning from here. I implemented the example code given by the documentation which you can see here and it works on the test android app. The problem is that I need the registration tokens of the devices to send a notification which I have not collected. Or I can send a notification to a topic but the problem is that the app users have not subscribed to topics. I previously used firebase console to send the notifications. I used this option while sending notifications:
Using this option, I sent the notification to all the users of my app. How can I do this with the admin sdk? I want to send notification to all the users of the app. I also tried py-fcm to do this but could not find success. It has the same problem. (If the problem can not be solved using the admin sdk, tell some other library or method to use)
you can not send to all devices in your Firebase panel.
you should use "Topic" or "Group" for sending to multiple devices.
You can use the "not" operation by excluding a non-existing topic.
!('TopicA' in topics)
With this expression, any app instances that are not subscribed to TopicA, including app instances that are not subscribed to any topic, receive the message. If you make sure that none of your users subscribe to "TopicA", you are essentially sending the message to all of your users.