{"id":19260203,"url":"https://github.com/kulikov-dev/firebase-push","last_synced_at":"2025-04-21T16:31:27.535Z","repository":{"id":74412019,"uuid":"550661258","full_name":"kulikov-dev/firebase-push","owner":"kulikov-dev","description":"Small scripts for working with Firebase Cloud Messaging (FCM) web push notifications","archived":false,"fork":false,"pushed_at":"2022-10-17T18:05:24.000Z","size":30,"stargazers_count":9,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-01T14:22:05.172Z","etag":null,"topics":["fcm-push-notification","firebase","github-pages","javascript","php","web-notifications"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kulikov-dev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-10-13T05:55:06.000Z","updated_at":"2023-10-13T09:34:10.000Z","dependencies_parsed_at":null,"dependency_job_id":"05d644d2-2f4e-4040-b798-f91379be9376","html_url":"https://github.com/kulikov-dev/firebase-push","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kulikov-dev%2Ffirebase-push","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kulikov-dev%2Ffirebase-push/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kulikov-dev%2Ffirebase-push/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kulikov-dev%2Ffirebase-push/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kulikov-dev","download_url":"https://codeload.github.com/kulikov-dev/firebase-push/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250090844,"owners_count":21373266,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fcm-push-notification","firebase","github-pages","javascript","php","web-notifications"],"created_at":"2024-11-09T19:19:20.161Z","updated_at":"2025-04-21T16:31:27.529Z","avatar_url":"https://github.com/kulikov-dev.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"Test Firebase Cloud Messaging\n-----------------------------\n\nSmall scripts for working with Firebase Cloud Messaging (FCM) web push notifications. Based on [quickstart-js](https://github.com/firebase/quickstart-js)\n\n* Clean scripts without excess code. Ready to use;\n* Added opportunity to work and test on [github pages](https://kulikov-dev.github.io/firebase-push/);\n* Added possibility to process click on a notification: open or focus a linked page.\n\nThere are four scripts here:\n* firebase_client.js - which used on a client side for subscription for notifications;\n* firebase-messaging-sw.js - is the ServiceWorker;\n* firebase_webhook.php - which process users token on a server side and save it to storage for future usage;\n* firebase_notifications_sender.php - sample script for sending notifications.\n\nThe best way to test client side is use Postman with sending POST messages with:\n* This auth info: Authorization - Key=your-server-key\n* To this address: https://fcm.googleapis.com/fcm/send \n* With this data (you can send up to 500 user tokens in one message):\n```json\n{\n    \"data\": {\n    \"title\": \"Title\",\n    \"body\": \"Notification message\",\n    \"icon\": \"https://kulikov-dev.github.io/firebase-push/notification_logo.jpg\",\n    \"click_action\": \"https://kulikov-dev.github.io/firebase-push/\"\n  },\n  \"to\": \"user-token-id\" \n}\n```\n* To get 'Server key' you need to enable 'Cloud Messaging API (Legacy)'.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkulikov-dev%2Ffirebase-push","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkulikov-dev%2Ffirebase-push","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkulikov-dev%2Ffirebase-push/lists"}