{"id":18487290,"url":"https://github.com/just1and0/expo-push-notification-helper","last_synced_at":"2025-09-01T13:33:21.872Z","repository":{"id":71453447,"uuid":"168052279","full_name":"just1and0/expo-push-notification-helper","owner":"just1and0","description":"💬🔥This package helps you make expo push notification for React Native  easy to use.","archived":false,"fork":false,"pushed_at":"2020-06-01T01:35:03.000Z","size":35,"stargazers_count":36,"open_issues_count":0,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-27T12:06:36.493Z","etag":null,"topics":["expo","expo-push-notifications","javascript","push-notifications","pushnotifications","reactnative"],"latest_commit_sha":null,"homepage":"https://just1and0.github.io/expo-push-notification-helper/","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/just1and0.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"github":["just1and0"],"patreon":"just1and0","ko_fi":"just1and0"}},"created_at":"2019-01-28T23:02:14.000Z","updated_at":"2024-03-19T01:26:12.000Z","dependencies_parsed_at":"2023-07-17T22:15:06.517Z","dependency_job_id":null,"html_url":"https://github.com/just1and0/expo-push-notification-helper","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just1and0%2Fexpo-push-notification-helper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just1and0%2Fexpo-push-notification-helper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just1and0%2Fexpo-push-notification-helper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/just1and0%2Fexpo-push-notification-helper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/just1and0","download_url":"https://codeload.github.com/just1and0/expo-push-notification-helper/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248684980,"owners_count":21145170,"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":["expo","expo-push-notifications","javascript","push-notifications","pushnotifications","reactnative"],"created_at":"2024-11-06T12:50:22.801Z","updated_at":"2025-04-13T21:42:38.842Z","avatar_url":"https://github.com/just1and0.png","language":"JavaScript","funding_links":["https://github.com/sponsors/just1and0","https://patreon.com/just1and0","https://ko-fi.com/just1and0"],"categories":["JavaScript"],"sub_categories":[],"readme":"# expo-push-notification-helper \n\u003c!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section --\u003e\n[![All Contributors](https://img.shields.io/badge/all_contributors-3-orange.svg?style=flat-square)](#contributors-)\n\u003c!-- ALL-CONTRIBUTORS-BADGE:END --\u003e\n\n\n[![Build Status](https://travis-ci.com/just1and0/object-to-array-convert.svg?branch=master)](https://travis-ci.com/just1and0/expo-push-notification-helper/)\n\n[![Code Quality](https://scrutinizer-ci.com/g/just1and0/expo-push-notification-helper/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/just1and0/expo-push-notification-helper/?branch=master)\n\nThis package helps you make expo push notification for React Native  easy to use.\n\n### Installation\n\nAdd expo-push-notification-helper to your project by executing\n\n```sh\n$  npm install expo-push-notification-helper\nor\n$ yarn add expo-push-notification-helper\n```\nYou're all set!\n \n \n### Usage\n\n##### To initialize expo-push-notification-helper import the \"initnotify\"\n\n```sh\n//import the initnotify into your project\nimport { initnotify } from 'expo-push-notification-helper';\n\n//and then use like so\n         initnotify();\n\n```\n### it's advicable to do this at your top level file.\n\n#####  can also use the callback function. Which returns true on success and false if unsuccessful.\n##### this will also automatically create three channels for your app, \"default\", \"reminders\", \"chat-messages\" .\n\n```sh\n//import the initnotify into your project\nimport { initnotify } from 'expo-push-notification-helper';\n\n//and then use like so\n         initnotify().then((data)=\u003e{\n              if(data){\n                //get token\n              }else{\n                //request for permission\n              }\n         });\n\n```\n\n#\n\n##### To get expo token of device import the \"getToken\"\n###### this must be used in a async/await .\n\n```sh\n//import the getToken into your project\nimport { initnotify, getToken } from 'expo-push-notification-helper';\n\n//and then use like so\n\n      initnotify().then( async(data)=\u003e{\n          if(data){\n                console.log(await getToken());\n            }else{\n              alert('please grant this app notification permission in settings.')\n            }\n       \n        })\n\n\n\n\n```\n#\n\n\n##### To  create a new channel import the \"newChannel\"\n\n```sh\n//import the newChannel into your project \nimport {  newChannel } from 'expo-push-notification-helper';\n\n//and then use like so \n    newChannel(\"GroupMessage\");\n\n```\n##### on default your channel will be created sound being false but you can change that by adding true as a second input\n\n#\n\n\n#### To send push notification import the \"notify\"\n\n```sh\n\n\n//import the notify into your project \nimport { notify } from 'expo-push-notification-helper';\n\n//and then use like so \n      notify(token, \"new message\", \"hello there how are you doing\", \"default\")\n\n```\n\n##### Not you must supply the channel.\"\n\n\n\n\n## Props\n\n#### all expo-push-notification-helper props\n\n| Name | Use | callback | note |\n| ------ | ------ | ------ | ------ |\n| initnotify() | initialize package, this will ask for notification permission. | true, false | this will also automatically create three channels for your app, \"default\", \"reminders\", \"chat-messages\" .|\n| getToken() | get expo token of device | null | must be called in async/await |\n| newChannel(name, isSound) | create new notification channel | true, false | isSound is a boolean |\n| notify( token, title, body, channel ) |  send push notification| null | without providing a channel. channel will be set to default by default |\n\n\n\n# Contributing\nHave a new feature you'd love to add to this project? Make a Send me a pull request! Just follow the [guidelines](https://github.com/just1and0/expo-push-notification-helper/blob/master/contribute.md). Thank you!\n\n\n\n\n### don't forget to star, like and share :)\n\n\n## Licensing\n----\n\nThis project is licensed under MIT license.\n\n## Contributors ✨\n\nThanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --\u003e\n\u003c!-- prettier-ignore-start --\u003e\n\u003c!-- markdownlint-disable --\u003e\n\u003ctable\u003e\n  \u003ctr\u003e\n    \u003ctd align=\"center\"\u003e\u003ca href=\"https://github.com/txvnt\"\u003e\u003cimg src=\"https://avatars0.githubusercontent.com/u/43381969?v=4\" width=\"100px;\" alt=\"\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eTomás Vélez Núñez\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/just1and0/expo-push-notification-helper/commits?author=txvnt\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n    \u003ctd align=\"center\"\u003e\u003ca href=\"http://www.ujjalacharya.com.np\"\u003e\u003cimg src=\"https://avatars3.githubusercontent.com/u/19649166?v=4\" width=\"100px;\" alt=\"\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eUjjal Acharya\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/just1and0/expo-push-notification-helper/commits?author=ujjalacharya\" title=\"Documentation\"\u003e📖\u003c/a\u003e\u003c/td\u003e\n    \u003ctd align=\"center\"\u003e\u003ca href=\"https://linksnest.com/just1and0\"\u003e\u003cimg src=\"https://avatars3.githubusercontent.com/u/17249207?v=4\" width=\"100px;\" alt=\"\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eOluwatobi Shokunbi \u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/just1and0/expo-push-notification-helper/commits?author=just1and0\" title=\"Code\"\u003e💻\u003c/a\u003e \u003ca href=\"https://github.com/just1and0/expo-push-notification-helper/commits?author=just1and0\" title=\"Documentation\"\u003e📖\u003c/a\u003e\u003c/td\u003e\n  \u003c/tr\u003e\n\u003c/table\u003e\n\n\u003c!-- markdownlint-enable --\u003e\n\u003c!-- prettier-ignore-end --\u003e\n\u003c!-- ALL-CONTRIBUTORS-LIST:END --\u003e\n\nThis project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjust1and0%2Fexpo-push-notification-helper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjust1and0%2Fexpo-push-notification-helper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjust1and0%2Fexpo-push-notification-helper/lists"}