-
-
Notifications
You must be signed in to change notification settings - Fork 233
feat: migrate notification endpoints to v2 #5945
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: migrate notification endpoints to v2 #5945
Conversation
this slims down the number of API calls we make, and allows our backend to be the source of truth for notifications.
252aac6
to
15d0996
Compare
@metamaskbot publish-preview |
Preview builds have been published. See these instructions for more information about preview builds. Expand for full list of packages and versions.
|
- add API config cache to reduce API calls - ensure push notifications only register active notification acconuts - fetch notifications for active notification accounts - when enabling notifications for a new device, correctly check if we need to register addresses for notifications. - do not clear FCM token as we need it for backend cleanup when re-registering. - make sure our APIs use lowercase addresses (these get hashed on the backend so need to be all same case)
…ification-v2-endpoints
@metamaskbot publish-preview |
Preview builds have been published. See these instructions for more information about preview builds. Expand for full list of packages and versions.
|
@metamaskbot publish-preview |
Preview builds have been published. See these instructions for more information about preview builds. Expand for full list of packages and versions.
|
Closing as we already have a PR open to resolve this :) |
Whoops wrong PR |
now we only fetch notifications for addresses with notifications enabled
…etaMask/core into MMASSETS-888/notification-v2-endpoints
…ification-v2-endpoints
@metamaskbot publish-preview |
Preview builds have been published. See these instructions for more information about preview builds. Expand for full list of packages and versions.
|
…ification-v2-endpoints
Explanation
Reduces the number of API calls by 25-33% (cut 1/4 - 1/3 endpoints).
Removes complex encryption and decryption logic from UserStorage. This took at least 2s on mobile per request!
Enables us to have our notification backend to be the source of truth. We can now extend notifications easily without as much front-end work.
Test Drive PRs:
References
https://consensyssoftware.atlassian.net/browse/MMASSETS-888
Changelog
Checklist