dimanche 25 mars 2018

Push Notification in android

I want to send a push notification using one signal in Android .

I want to collect the data from a textfield and send it to all the users. Please help me.

Code:
    String msg = edittextmessage.getText().toString().trim();      String strJsonBody = "{"          + "\"app_id\": \"myonesignalid\","          + "\"included_segments\": [\"Participant\"],"          + "\"data\": {\"foo\": \"bar\"},"          + "\"contents\": {'en': \\\"\"+ msg +\"\\\"}"          + "}";  


from Android Authority Forums https://ift.tt/2G624Vj
via IFTTT

Aucun commentaire:

Enregistrer un commentaire