Parse-server: how to configure one signal for push notification

Created on 30 Mar 2016  Â·  14Comments  Â·  Source: parse-community/parse-server

For implementation related questions or technical support, please refer to the Stack Overflow and Server Fault communities.

Make sure these boxes are checked before submitting your issue -- thanks for reporting issues back to Parse Server!

Environment Setup

Steps to reproduce

Logs/Trace

Most helpful comment

Typically you would send them in database triggers life afterSave on a
post, and you'd control the query and the messaging... You don't create a
blanket sendPush function, you do specific things and validate in your
logic.

On Wednesday, March 30, 2016, Dylan Diamond [email protected]
wrote:

How can we ensure that clients can't call a cloud function that sends a
push by obtaining the client key, since that is public information? If they
track the network requests for an app that calls a push cloud function,
can't someone send spam pushes?

—
You are receiving this because you modified the open/close state.
Reply to this email directly or view it on GitHub
https://github.com/ParsePlatform/parse-server/issues/1278#issuecomment-203618697

All 14 comments

through it will i be able to send client push

like send to those whose object id is 1,2,3,4,

Client push is not a good idea (it is insecure, allows spam)... Use cloud functions and send push from cloud code using the master key.

Can cloud code send push like
ParsePush push = new ParsePush();

        query.whereContainedIn(Constants.KEY_USER_ID, "UIYUI6767FGFsds");

        push.setQuery(query);
        push.setData(obj);
        push.sendInBackground();

to only that specfic person

It's a little different than that, see: https://github.com/ParsePlatform/parse-server/wiki/Push#4-send-push-notifications but you can pass a query for the where value.

is that sending to one person or more according to query is possibe

Yes, you can pass almost any query against the installations.

That means through cloud clode i can send push notification

Of course.

Client pushh too and can u provide me the link for cloud code too and please tell if it will support client push notification

How can we ensure that clients can't call a cloud function that sends a push by obtaining the client key, since that is public information? If they track the network requests for an app that calls a push cloud function, can't someone send spam pushes?

Typically you would send them in database triggers life afterSave on a
post, and you'd control the query and the messaging... You don't create a
blanket sendPush function, you do specific things and validate in your
logic.

On Wednesday, March 30, 2016, Dylan Diamond [email protected]
wrote:

How can we ensure that clients can't call a cloud function that sends a
push by obtaining the client key, since that is public information? If they
track the network requests for an app that calls a push cloud function,
can't someone send spam pushes?

—
You are receiving this because you modified the open/close state.
Reply to this email directly or view it on GitHub
https://github.com/ParsePlatform/parse-server/issues/1278#issuecomment-203618697

Guide for using cloud code for clint push is there any ??

Was this page helpful?
0 / 5 - 0 ratings