Push Notification Api

부분 유료
분류별 TeamsDevBot | 업데이트됨 a month ago | Advertising
Health Check

N/A

README


> ~~## How to setup frontend web app too which your visitors will subscribe?
~~


- [ ] **Steps**

1. Add SW.js file to your public folder.
2. Add these code in header app.
`<script>
        navigator.serviceWorker.register("sw.js");

        function enableNotif() {
            Notification.requestPermission().then((permission)=> {
                if (permission === 'granted') {
                    // get service worker
                    navigator.serviceWorker.ready.then((sw)=> {
                        // subscribe
                        sw.pushManager.subscribe({
                            userVisibleOnly: true,
                            applicationServerKey: "these code will generate for you"
                        }).then((subscription)=> {
                            console.log(JSON.stringify(subscription));
                         
                        });
                    });
                }
            });
        }
    </script>`







팔로워: 0
API 생성자 :
Rapid account: Teams Dev Bot
TeamsDevBot
teamsdevbot
Rate API에 로그인
등급: 5 - 투표: 1