Architecture overview
Push Notification is a web3 alert protocol that enables wallet addresses to send and receive notifications, offering a secure and privacy-focused and transparent alternative to traditional notification services.. By leveraging blockchain technology, users can communicate directly via their wallet addresses without personal identifiers like phone numbers, email addresses, etc.
Designed for mainstream adoption, Push Notification serves as a protocol that any dApp, web3 wallet, or backend can integrate to provide their users with notification capabilities.
Since Push Protocol started with decentralized notifications, every chat message sent on the protocol has a notification built in. Whenever a message is sent to an address, the receiving address will receive a notification along with the message but only if they have accepted your chat request.
Unlike traditional notification / alert services that require users to provide their information to sign up, like their email, phone number, or any other personal data about the user, Push Notification requires no personal information whatsoever to start receiving / sending notifications on the protocol.
- All the user needs is a wallet address.
- All the notifications are stored either on Push Nodes, IPFS or onchain depending on the storage choosed by the client and are signed.
- When sending a notification to an address, it is sent through Push Nodes.
Push Nodes are a network of nodes, where each node can have a different role in the network that is responsible for validating each notification and chat message between addresses.
Their main task is to validate that:
- the notification payload is following the corresponding payload standard,
- the sender is a valid channel or delegator and can actually send the notification, and signature validation,
- if the payload is valid, the Push Nodes will process the notification and send it to the delivery nodes for pushing the alerts to the clients.
Spam prevention
Spam prevention has always been one of our major priorities.
There are countless examples of users spamming others with fake giveaways, random messages, or unwanted notifications.
For notifications, the core protocol itself adopts a user-centric approach. This means that all the notifications are opt-in or opt-out based.
This means that users shall only receive notifications from protocols they opt in to. Users can fine-tune which notifications they see the value of and only opt-in for them while every other notification shall land in the user's spam box.
Sending notifications
The core protocol allows to create channels which acts as services that can send notifications to any wallet address. The channels can also send notifications on alias chains using an alias address of the specific chain. If the wallet address is a subscriber, notifications lands in the inbox, otherwise in spam box.
Decentralization
Push Notifications are sent between addresses via the Push Nodes. Push Nodes are the nodes responsible for validating notification and chat payload and for dispatching notifications to addresses. Push Nodes can have different roles in this Communication Network.
The vision for Push Protocol is for the Push Nodes to be run by the community and to get rewarded by contributing to the network's decentralization. As of today, Push Nodes are run by Push Protocol, but the team is working on decentralizing the nodes.
Although the Push Nodes are run by Push Protocol, users can always verify that the chat messages and notifications haven’t been tampered with and that they have indeed been sent by the correct address. Users can always verify this by the Verification Proof.
Verification Proof
Verification Proof is a property that is sent along with the notifications and chats messages to help the network validate the sender, the chain from which the notification (or message) is sent, and the content of the notification (or message) along with any other validation that might be required.
For notifications, the verification proofs differ based on the platform from which they are sent. i.e., Smart contracts verification proof can be validated on-chain, and smart contract-based notifications will usually carry transaction hash proofs while off-chain/gasless notifications usually carry EIP-712 proofs, though they are capable of carrying smart contract verification proof as well, which makes it composable.
Push Notification SDK
With the SDK, it will be easy for developers to integrate notifications into their dapps. The use cases are endless:
- Alerts for gas price changes.
- Notifications for token price changes.
- New Governance Proposals of DAO
- Loan Liquidation Alert
- Any other cool, crazy feature you can think of
Alright. Now that you have a clear picture of the Push Notification and its SDK, let's dive in and try to integrate the push notification into your application.