https://github.com/turquoisespace/notification-box
Android app to send personalized push notifications, using GCP
https://github.com/turquoisespace/notification-box
android api apk curl gcp postman push-notifications
Last synced: 2 months ago
JSON representation
Android app to send personalized push notifications, using GCP
- Host: GitHub
- URL: https://github.com/turquoisespace/notification-box
- Owner: TurquoiseSpace
- Created: 2021-06-07T08:18:31.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2023-06-18T08:18:21.000Z (about 3 years ago)
- Last Synced: 2025-03-15T04:26:48.374Z (over 1 year ago)
- Topics: android, api, apk, curl, gcp, postman, push-notifications
- Language: Java
- Homepage:
- Size: 10.9 MB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Notification Box #

## Description ##
`notification-box` is available for android, and published exclusively on github
send custom push notifications to yourself
can be used to send and receive `push notfications` of events / appointments / reminders / alerts,
or for any other purpose you can think of
## Releases ##
* Stable
[notification-box-0.0.3](https://github.com/TurquoiseSpace/notification-box/releases/download/0.0.3/notification-box-0.0.3.apk)
* Tag / Tree
[0.0.3](https://github.com/TurquoiseSpace/notification-box/tree/3ee8745ecdce381bc0b3ec68f57d79e4927ada21)
## Repository ##
* Browse
https://github.com/TurquoiseSpace/notification-box
* Download ZIP
https://github.com/TurquoiseSpace/notification-box/archive/refs/heads/master.zip
## Clone ##
* HTTPS
```git clone https://github.com/TurquoiseSpace/notification-box.git```
* SSH
```git clone git@github.com:TurquoiseSpace/notification-box.git```
* GitHub CLI
```gh repo clone TurquoiseSpace/notification-box```
## Usage Instructions ##
#### Notification Box - Android App - Initial / One Time Setup ####
1) download the apk,
directly onto your mobile device,
or,
onto your laptop / desktop, then copy it onto your mobile device
2) in your android mobile device, go to settings and enable `allow installing apps from external sources`
3) install the apk, in your mobile device

4) open the app with name `Firebase Cloud Messaging`, having a green Android bot icon

5) click on the "LOG TOKEN" button,
it will generate the `FCM Registration Token`,
this is a client specific token, which would be used to send the push notifications to this particular android device client app,
and is supposed to look something like this
```cuo0-PvyQkO-lL5XsqHDAk:APA91bEmCznZGGnD-huqBrbNBhzyzUgkvMyFQoVJSDf4zYbuUGrghUT0DMSz3eVV2I7tINGJWw88qqS3Mx0rGVzVnRQpqqKbDqKvmEnN9z3aSRPUK4f1JTNoZ7JZ2rA_AFTCSjUhmRhn```
indeed it will, be different / unique for you

6) click on the "COPY TOKEN" button

7) from your mobile, open an email client whichever you use, like gmail or any other email service, in app or browser,
and send yourself this token, on email,
so you can access / use it later, from your laptop or desktop

#### Sending Push Notification - Postman ####
1) on your desktop or laptop, open your email, in which you had shared your `FCM Registration Token`,
and copy that token

2) open Postman, and paste this FCM registration token in the `raw` `JSON` Request Body, as the value of `to` attribute,
the request body would look something like this
```
{
"to" : "cuo0-PvyQkO-lL5XsqHDAk:APA91bEmCznZGGnD-huqBrbNBhzyzUgkvMyFQoVJSDf4zYbuUGrghUT0DMSz3eVV2I7tINGJWw88qqS3Mx0rGVzVnRQpqqKbDqKvmEnN9z3aSRPUK4f1JTNoZ7JZ2rA_AFTCSjUhmRhn",
"data" : {
"title" : "testing",
"message" : "Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.",
"json_key" : "json_value",
"array" : [
"hola",
"amigos",
"and",
"senoritas"
],
"object" : {
"inner_json_key" : "inner_json_value"
}
}
}
```

3) in the request url, copy paste the below
```https://fcm.googleapis.com/fcm/send```
4) set the HTTP Method as
```POST```
5) in the Request Headers, copy paste the following header
```Authorization:key=AAAAucpu21Y:APA91bEYxJ6XGquZzAxqJnyUYeSwi7ocOWO4iJwi676vXnRXrDn-TazsJmESzQHHv5Dx2OO3HFOk5moxzpvEPCMCv3UA5ZopDnVFBK6lOeE1qWQugDVabmN229DAXd3G7tdul7mmlYpF```

where the header name is `Authorization` and the header value is `key=AAAAucpu21Y:APA91bEYxJ6XGquZzAxqJnyUYeSwi7ocOWO4iJwi676vXnRXrDn-TazsJmESzQHHv5Dx2OO3HFOk5moxzpvEPCMCv3UA5ZopDnVFBK6lOeE1qWQugDVabmN229DAXd3G7tdul7mmlYpF`
the value of this header contains the `API Access Key` of this project which is registered with the `Google Cloud Platform`

6) click on `Send` button,
check the response status, must be `200 OK`,
also check the response body for `success` count as `1`

7) Voila !
You should have received the Push Notification in your Android Client
#### Receiving Push Notification - Notification Box - Android App ####
1) actual push notification

2) view the current and all the pervious push notifications, which are persisted, from the android client database,
by clicking on a push notification which has arrived,
or,
by clicking on the bell icon on the home / main screen of the `notification-box` app

when no push notifications are persent in the app database client

## Reference Links ##
https://console.cloud.google.com/
https://guides.github.com/features/mastering-markdown/
## Git Commands ##
* List All Tags (Local)
```git show-ref --tags```
* List All Tags (Remote)
```git ls-remote --tags origin```
* Delete Tag (Local)
```git tag -d ```
```git tag -d 0.0.9```
* Delete Tag (Remote)
```git push origin :```
```git push origin :0.0.9```
* Create Tag (Local)
```git tag ```
```git tag 0.0.9```
* Create Tag (Remote)
```git push origin ```
```git push origin 0.0.9```
## Contact Info ##
notification-box@googlegroups.com
Feel free to drop us an email