This section provides information about the architecture design and functionality of ENS2.
ENS2 Architecture using APNS
Architecture Flow Description
- Public-Key Request
- The device requests a public key to encrypt the account credentials.
- The device sends an encrypted payload with credentials and all the necessary information to subscribe and get email notifications.
- Push Subscription
- ENS authenticates with EWS and subscribes for push notifications using a webhook URL. The webhook URL contains the encrypted credentials. The credentials are now kept encrypted on the Exchange server.
- New Email Notification
- Exchange sends notification about the mailbox changes to the provided webhook URL.
- ENS extracts and decrypts the credentials and prepares call to fetch emails.
- Email Fetch
- ENS performs a fetch for the email details (subject and sender) required for providing a notification.
- Push Email
- ENS pushes email details for delivery to all devices belonging to the user through Apple Push Notification Service (APNS).