@metamask-previews/notification-services-controller 0.0.0-preview-b09c2ed
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/LICENSE +20 -0
- package/README.md +15 -0
- package/dist/NotificationServicesController/NotificationServicesController.js +18 -0
- package/dist/NotificationServicesController/NotificationServicesController.js.map +1 -0
- package/dist/NotificationServicesController/NotificationServicesController.mjs +18 -0
- package/dist/NotificationServicesController/NotificationServicesController.mjs.map +1 -0
- package/dist/NotificationServicesController/constants/constants.js +10 -0
- package/dist/NotificationServicesController/constants/constants.js.map +1 -0
- package/dist/NotificationServicesController/constants/constants.mjs +10 -0
- package/dist/NotificationServicesController/constants/constants.mjs.map +1 -0
- package/dist/NotificationServicesController/constants/index.js +27 -0
- package/dist/NotificationServicesController/constants/index.js.map +1 -0
- package/dist/NotificationServicesController/constants/index.mjs +27 -0
- package/dist/NotificationServicesController/constants/index.mjs.map +1 -0
- package/dist/NotificationServicesController/constants/notification-schema.js +20 -0
- package/dist/NotificationServicesController/constants/notification-schema.js.map +1 -0
- package/dist/NotificationServicesController/constants/notification-schema.mjs +20 -0
- package/dist/NotificationServicesController/constants/notification-schema.mjs.map +1 -0
- package/dist/NotificationServicesController/index.js +44 -0
- package/dist/NotificationServicesController/index.js.map +1 -0
- package/dist/NotificationServicesController/index.mjs +44 -0
- package/dist/NotificationServicesController/index.mjs.map +1 -0
- package/dist/NotificationServicesController/processors/index.js +22 -0
- package/dist/NotificationServicesController/processors/index.js.map +1 -0
- package/dist/NotificationServicesController/processors/index.mjs +22 -0
- package/dist/NotificationServicesController/processors/index.mjs.map +1 -0
- package/dist/NotificationServicesController/processors/process-feature-announcement.js +10 -0
- package/dist/NotificationServicesController/processors/process-feature-announcement.js.map +1 -0
- package/dist/NotificationServicesController/processors/process-feature-announcement.mjs +10 -0
- package/dist/NotificationServicesController/processors/process-feature-announcement.mjs.map +1 -0
- package/dist/NotificationServicesController/processors/process-notifications.js +13 -0
- package/dist/NotificationServicesController/processors/process-notifications.js.map +1 -0
- package/dist/NotificationServicesController/processors/process-notifications.mjs +13 -0
- package/dist/NotificationServicesController/processors/process-notifications.mjs.map +1 -0
- package/dist/NotificationServicesController/processors/process-onchain-notifications.js +8 -0
- package/dist/NotificationServicesController/processors/process-onchain-notifications.js.map +1 -0
- package/dist/NotificationServicesController/processors/process-onchain-notifications.mjs +8 -0
- package/dist/NotificationServicesController/processors/process-onchain-notifications.mjs.map +1 -0
- package/dist/NotificationServicesController/services/feature-announcements.js +14 -0
- package/dist/NotificationServicesController/services/feature-announcements.js.map +1 -0
- package/dist/NotificationServicesController/services/feature-announcements.mjs +14 -0
- package/dist/NotificationServicesController/services/feature-announcements.mjs.map +1 -0
- package/dist/NotificationServicesController/services/onchain-notifications.js +29 -0
- package/dist/NotificationServicesController/services/onchain-notifications.js.map +1 -0
- package/dist/NotificationServicesController/services/onchain-notifications.mjs +29 -0
- package/dist/NotificationServicesController/services/onchain-notifications.mjs.map +1 -0
- package/dist/NotificationServicesController/types/feature-announcement/feature-announcement.js +2 -0
- package/dist/NotificationServicesController/types/feature-announcement/feature-announcement.js.map +1 -0
- package/dist/NotificationServicesController/types/feature-announcement/feature-announcement.mjs +2 -0
- package/dist/NotificationServicesController/types/feature-announcement/feature-announcement.mjs.map +1 -0
- package/dist/NotificationServicesController/types/feature-announcement/index.js +5 -0
- package/dist/NotificationServicesController/types/feature-announcement/index.js.map +1 -0
- package/dist/NotificationServicesController/types/feature-announcement/index.mjs +5 -0
- package/dist/NotificationServicesController/types/feature-announcement/index.mjs.map +1 -0
- package/dist/NotificationServicesController/types/feature-announcement/type-feature-announcement.js +2 -0
- package/dist/NotificationServicesController/types/feature-announcement/type-feature-announcement.js.map +1 -0
- package/dist/NotificationServicesController/types/feature-announcement/type-feature-announcement.mjs +2 -0
- package/dist/NotificationServicesController/types/feature-announcement/type-feature-announcement.mjs.map +1 -0
- package/dist/NotificationServicesController/types/feature-announcement/type-links.js +2 -0
- package/dist/NotificationServicesController/types/feature-announcement/type-links.js.map +1 -0
- package/dist/NotificationServicesController/types/feature-announcement/type-links.mjs +2 -0
- package/dist/NotificationServicesController/types/feature-announcement/type-links.mjs.map +1 -0
- package/dist/NotificationServicesController/types/index.js +12 -0
- package/dist/NotificationServicesController/types/index.js.map +1 -0
- package/dist/NotificationServicesController/types/index.mjs +12 -0
- package/dist/NotificationServicesController/types/index.mjs.map +1 -0
- package/dist/NotificationServicesController/types/notification/index.js +3 -0
- package/dist/NotificationServicesController/types/notification/index.js.map +1 -0
- package/dist/NotificationServicesController/types/notification/index.mjs +3 -0
- package/dist/NotificationServicesController/types/notification/index.mjs.map +1 -0
- package/dist/NotificationServicesController/types/notification/notification.js +2 -0
- package/dist/NotificationServicesController/types/notification/notification.js.map +1 -0
- package/dist/NotificationServicesController/types/notification/notification.mjs +2 -0
- package/dist/NotificationServicesController/types/notification/notification.mjs.map +1 -0
- package/dist/NotificationServicesController/types/on-chain-notification/index.js +3 -0
- package/dist/NotificationServicesController/types/on-chain-notification/index.js.map +1 -0
- package/dist/NotificationServicesController/types/on-chain-notification/index.mjs +3 -0
- package/dist/NotificationServicesController/types/on-chain-notification/index.mjs.map +1 -0
- package/dist/NotificationServicesController/types/on-chain-notification/on-chain-notification.js +2 -0
- package/dist/NotificationServicesController/types/on-chain-notification/on-chain-notification.js.map +1 -0
- package/dist/NotificationServicesController/types/on-chain-notification/on-chain-notification.mjs +2 -0
- package/dist/NotificationServicesController/types/on-chain-notification/on-chain-notification.mjs.map +1 -0
- package/dist/NotificationServicesController/types/on-chain-notification/schema.js +1 -0
- package/dist/NotificationServicesController/types/on-chain-notification/schema.js.map +1 -0
- package/dist/NotificationServicesController/types/on-chain-notification/schema.mjs +1 -0
- package/dist/NotificationServicesController/types/on-chain-notification/schema.mjs.map +1 -0
- package/dist/NotificationServicesController/types/type-utils.js +1 -0
- package/dist/NotificationServicesController/types/type-utils.js.map +1 -0
- package/dist/NotificationServicesController/types/type-utils.mjs +1 -0
- package/dist/NotificationServicesController/types/type-utils.mjs.map +1 -0
- package/dist/NotificationServicesController/types/user-storage/index.js +3 -0
- package/dist/NotificationServicesController/types/user-storage/index.js.map +1 -0
- package/dist/NotificationServicesController/types/user-storage/index.mjs +3 -0
- package/dist/NotificationServicesController/types/user-storage/index.mjs.map +1 -0
- package/dist/NotificationServicesController/types/user-storage/user-storage.js +2 -0
- package/dist/NotificationServicesController/types/user-storage/user-storage.js.map +1 -0
- package/dist/NotificationServicesController/types/user-storage/user-storage.mjs +2 -0
- package/dist/NotificationServicesController/types/user-storage/user-storage.mjs.map +1 -0
- package/dist/NotificationServicesController/utils/utils.js +32 -0
- package/dist/NotificationServicesController/utils/utils.js.map +1 -0
- package/dist/NotificationServicesController/utils/utils.mjs +32 -0
- package/dist/NotificationServicesController/utils/utils.mjs.map +1 -0
- package/dist/NotificationServicesPushController/NotificationServicesPushController.js +34 -0
- package/dist/NotificationServicesPushController/NotificationServicesPushController.js.map +1 -0
- package/dist/NotificationServicesPushController/NotificationServicesPushController.mjs +34 -0
- package/dist/NotificationServicesPushController/NotificationServicesPushController.mjs.map +1 -0
- package/dist/NotificationServicesPushController/constants.js +26 -0
- package/dist/NotificationServicesPushController/constants.js.map +1 -0
- package/dist/NotificationServicesPushController/constants.mjs +26 -0
- package/dist/NotificationServicesPushController/constants.mjs.map +1 -0
- package/dist/NotificationServicesPushController/index.js +49 -0
- package/dist/NotificationServicesPushController/index.js.map +1 -0
- package/dist/NotificationServicesPushController/index.mjs +49 -0
- package/dist/NotificationServicesPushController/index.mjs.map +1 -0
- package/dist/NotificationServicesPushController/services/endpoints.js +8 -0
- package/dist/NotificationServicesPushController/services/endpoints.js.map +1 -0
- package/dist/NotificationServicesPushController/services/endpoints.mjs +8 -0
- package/dist/NotificationServicesPushController/services/endpoints.mjs.map +1 -0
- package/dist/NotificationServicesPushController/services/push/index.js +1 -0
- package/dist/NotificationServicesPushController/services/push/index.js.map +1 -0
- package/dist/NotificationServicesPushController/services/push/index.mjs +1 -0
- package/dist/NotificationServicesPushController/services/push/index.mjs.map +1 -0
- package/dist/NotificationServicesPushController/services/push/push-web.js +37 -0
- package/dist/NotificationServicesPushController/services/push/push-web.js.map +1 -0
- package/dist/NotificationServicesPushController/services/push/push-web.mjs +37 -0
- package/dist/NotificationServicesPushController/services/push/push-web.mjs.map +1 -0
- package/dist/NotificationServicesPushController/services/services.js +43 -0
- package/dist/NotificationServicesPushController/services/services.js.map +1 -0
- package/dist/NotificationServicesPushController/services/services.mjs +43 -0
- package/dist/NotificationServicesPushController/services/services.mjs.map +1 -0
- package/dist/NotificationServicesPushController/types/firebase.js +2 -0
- package/dist/NotificationServicesPushController/types/firebase.js.map +1 -0
- package/dist/NotificationServicesPushController/types/firebase.mjs +2 -0
- package/dist/NotificationServicesPushController/types/firebase.mjs.map +1 -0
- package/dist/NotificationServicesPushController/types/index.js +3 -0
- package/dist/NotificationServicesPushController/types/index.js.map +1 -0
- package/dist/NotificationServicesPushController/types/index.mjs +3 -0
- package/dist/NotificationServicesPushController/types/index.mjs.map +1 -0
- package/dist/NotificationServicesPushController/utils/get-notification-data.js +14 -0
- package/dist/NotificationServicesPushController/utils/get-notification-data.js.map +1 -0
- package/dist/NotificationServicesPushController/utils/get-notification-data.mjs +14 -0
- package/dist/NotificationServicesPushController/utils/get-notification-data.mjs.map +1 -0
- package/dist/NotificationServicesPushController/utils/get-notification-message.js +36 -0
- package/dist/NotificationServicesPushController/utils/get-notification-message.js.map +1 -0
- package/dist/NotificationServicesPushController/utils/get-notification-message.mjs +36 -0
- package/dist/NotificationServicesPushController/utils/get-notification-message.mjs.map +1 -0
- package/dist/NotificationServicesPushController/utils/index.js +46 -0
- package/dist/NotificationServicesPushController/utils/index.js.map +1 -0
- package/dist/NotificationServicesPushController/utils/index.mjs +46 -0
- package/dist/NotificationServicesPushController/utils/index.mjs.map +1 -0
- package/dist/chunk-232HZSEV.js +7 -0
- package/dist/chunk-232HZSEV.js.map +1 -0
- package/dist/chunk-26CCETCM.mjs +70 -0
- package/dist/chunk-26CCETCM.mjs.map +1 -0
- package/dist/chunk-3F4M3OUO.mjs +119 -0
- package/dist/chunk-3F4M3OUO.mjs.map +1 -0
- package/dist/chunk-3ZS2HAEG.js +1 -0
- package/dist/chunk-3ZS2HAEG.js.map +1 -0
- package/dist/chunk-4BTNTREI.mjs +1 -0
- package/dist/chunk-4BTNTREI.mjs.map +1 -0
- package/dist/chunk-4QXAPVW3.mjs +1 -0
- package/dist/chunk-4QXAPVW3.mjs.map +1 -0
- package/dist/chunk-52CALMRA.js +28 -0
- package/dist/chunk-52CALMRA.js.map +1 -0
- package/dist/chunk-52NKJDI2.mjs +93 -0
- package/dist/chunk-52NKJDI2.mjs.map +1 -0
- package/dist/chunk-5OYPOYXZ.mjs +802 -0
- package/dist/chunk-5OYPOYXZ.mjs.map +1 -0
- package/dist/chunk-5WWCWQCE.js +214 -0
- package/dist/chunk-5WWCWQCE.js.map +1 -0
- package/dist/chunk-6B5FOWRH.js +119 -0
- package/dist/chunk-6B5FOWRH.js.map +1 -0
- package/dist/chunk-6ZDVTRRT.mjs +9 -0
- package/dist/chunk-6ZDVTRRT.mjs.map +1 -0
- package/dist/chunk-7LWR54U7.js +7 -0
- package/dist/chunk-7LWR54U7.js.map +1 -0
- package/dist/chunk-7RM3YNTD.mjs +1 -0
- package/dist/chunk-7RM3YNTD.mjs.map +1 -0
- package/dist/chunk-A2RPVX47.mjs +1 -0
- package/dist/chunk-A2RPVX47.mjs.map +1 -0
- package/dist/chunk-B25TJ7KS.js +8 -0
- package/dist/chunk-B25TJ7KS.js.map +1 -0
- package/dist/chunk-B4ECJJ5C.mjs +7 -0
- package/dist/chunk-B4ECJJ5C.mjs.map +1 -0
- package/dist/chunk-BONB66A2.mjs +14 -0
- package/dist/chunk-BONB66A2.mjs.map +1 -0
- package/dist/chunk-CQ6CGSKZ.js +35 -0
- package/dist/chunk-CQ6CGSKZ.js.map +1 -0
- package/dist/chunk-D42BBXBM.mjs +28 -0
- package/dist/chunk-D42BBXBM.mjs.map +1 -0
- package/dist/chunk-DMH4NSLF.js +1 -0
- package/dist/chunk-DMH4NSLF.js.map +1 -0
- package/dist/chunk-DNTK4U5M.js +4300 -0
- package/dist/chunk-DNTK4U5M.js.map +1 -0
- package/dist/chunk-DY4ELDRQ.js +176 -0
- package/dist/chunk-DY4ELDRQ.js.map +1 -0
- package/dist/chunk-EJ52BDLB.js +55 -0
- package/dist/chunk-EJ52BDLB.js.map +1 -0
- package/dist/chunk-EQWVJX6K.mjs +91 -0
- package/dist/chunk-EQWVJX6K.mjs.map +1 -0
- package/dist/chunk-FFQNSBPU.js +31 -0
- package/dist/chunk-FFQNSBPU.js.map +1 -0
- package/dist/chunk-G52DNXFH.mjs +1 -0
- package/dist/chunk-G52DNXFH.mjs.map +1 -0
- package/dist/chunk-GETQWOTI.js +1 -0
- package/dist/chunk-GETQWOTI.js.map +1 -0
- package/dist/chunk-GFAESVZA.js +48 -0
- package/dist/chunk-GFAESVZA.js.map +1 -0
- package/dist/chunk-HPUQYDVC.js +1 -0
- package/dist/chunk-HPUQYDVC.js.map +1 -0
- package/dist/chunk-IDO4JFV5.mjs +1 -0
- package/dist/chunk-IDO4JFV5.mjs.map +1 -0
- package/dist/chunk-IKWNHNJQ.mjs +8 -0
- package/dist/chunk-IKWNHNJQ.mjs.map +1 -0
- package/dist/chunk-IOMDG67D.mjs +7 -0
- package/dist/chunk-IOMDG67D.mjs.map +1 -0
- package/dist/chunk-IPI7BAW3.js +1 -0
- package/dist/chunk-IPI7BAW3.js.map +1 -0
- package/dist/chunk-JLHFZ2UG.mjs +31 -0
- package/dist/chunk-JLHFZ2UG.mjs.map +1 -0
- package/dist/chunk-JQ7WKFCI.mjs +1 -0
- package/dist/chunk-JQ7WKFCI.mjs.map +1 -0
- package/dist/chunk-KTQP5UDT.mjs +4300 -0
- package/dist/chunk-KTQP5UDT.mjs.map +1 -0
- package/dist/chunk-LYEXYTOI.js +14 -0
- package/dist/chunk-LYEXYTOI.js.map +1 -0
- package/dist/chunk-NJBJIZLR.js +93 -0
- package/dist/chunk-NJBJIZLR.js.map +1 -0
- package/dist/chunk-NMLYB3XT.js +149 -0
- package/dist/chunk-NMLYB3XT.js.map +1 -0
- package/dist/chunk-ODI2BTKS.mjs +55 -0
- package/dist/chunk-ODI2BTKS.mjs.map +1 -0
- package/dist/chunk-OUPWMPLU.mjs +214 -0
- package/dist/chunk-OUPWMPLU.mjs.map +1 -0
- package/dist/chunk-PGMXFZ6Y.js +207 -0
- package/dist/chunk-PGMXFZ6Y.js.map +1 -0
- package/dist/chunk-PIZCE3JD.js +243 -0
- package/dist/chunk-PIZCE3JD.js.map +1 -0
- package/dist/chunk-PNCS6GEX.mjs +1 -0
- package/dist/chunk-PNCS6GEX.mjs.map +1 -0
- package/dist/chunk-PROWNV4M.js +1 -0
- package/dist/chunk-PROWNV4M.js.map +1 -0
- package/dist/chunk-QB5IFRLA.mjs +1 -0
- package/dist/chunk-QB5IFRLA.mjs.map +1 -0
- package/dist/chunk-QTK2RMF7.mjs +29 -0
- package/dist/chunk-QTK2RMF7.mjs.map +1 -0
- package/dist/chunk-RAUV5UV4.mjs +1 -0
- package/dist/chunk-RAUV5UV4.mjs.map +1 -0
- package/dist/chunk-RQWUD2FB.mjs +48 -0
- package/dist/chunk-RQWUD2FB.mjs.map +1 -0
- package/dist/chunk-SMKJEA45.mjs +243 -0
- package/dist/chunk-SMKJEA45.mjs.map +1 -0
- package/dist/chunk-SSWX2N73.mjs +207 -0
- package/dist/chunk-SSWX2N73.mjs.map +1 -0
- package/dist/chunk-TLX5QQK5.js +9 -0
- package/dist/chunk-TLX5QQK5.js.map +1 -0
- package/dist/chunk-TT56I53C.mjs +149 -0
- package/dist/chunk-TT56I53C.mjs.map +1 -0
- package/dist/chunk-U74Q3BRP.mjs +1 -0
- package/dist/chunk-U74Q3BRP.mjs.map +1 -0
- package/dist/chunk-UIRZIKC3.mjs +187 -0
- package/dist/chunk-UIRZIKC3.mjs.map +1 -0
- package/dist/chunk-UPVIT75F.js +29 -0
- package/dist/chunk-UPVIT75F.js.map +1 -0
- package/dist/chunk-V46WVGWN.js +70 -0
- package/dist/chunk-V46WVGWN.js.map +1 -0
- package/dist/chunk-V5HMYDWE.js +1 -0
- package/dist/chunk-V5HMYDWE.js.map +1 -0
- package/dist/chunk-VC6J62JI.mjs +176 -0
- package/dist/chunk-VC6J62JI.mjs.map +1 -0
- package/dist/chunk-VE4DTN4R.mjs +35 -0
- package/dist/chunk-VE4DTN4R.mjs.map +1 -0
- package/dist/chunk-VOZ7Y2OO.js +187 -0
- package/dist/chunk-VOZ7Y2OO.js.map +1 -0
- package/dist/chunk-WRYFIWNK.js +1 -0
- package/dist/chunk-WRYFIWNK.js.map +1 -0
- package/dist/chunk-XNBTOK6G.js +802 -0
- package/dist/chunk-XNBTOK6G.js.map +1 -0
- package/dist/chunk-XZEVRYUE.js +1 -0
- package/dist/chunk-XZEVRYUE.js.map +1 -0
- package/dist/chunk-ZBNBZN5H.js +1 -0
- package/dist/chunk-ZBNBZN5H.js.map +1 -0
- package/dist/chunk-ZMNXLHAC.js +91 -0
- package/dist/chunk-ZMNXLHAC.js.map +1 -0
- package/dist/chunk-ZV3DFBO4.js +1 -0
- package/dist/chunk-ZV3DFBO4.js.map +1 -0
- package/dist/index.js +43 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +43 -0
- package/dist/index.mjs.map +1 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -0
- package/dist/types/NotificationServicesController/NotificationServicesController.d.ts +222 -0
- package/dist/types/NotificationServicesController/NotificationServicesController.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/__fixtures__/index.d.ts +7 -0
- package/dist/types/NotificationServicesController/__fixtures__/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/__fixtures__/mock-feature-announcements.d.ts +15 -0
- package/dist/types/NotificationServicesController/__fixtures__/mock-feature-announcements.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/__fixtures__/mock-notification-trigger.d.ts +9 -0
- package/dist/types/NotificationServicesController/__fixtures__/mock-notification-trigger.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/__fixtures__/mock-notification-user-storage.d.ts +35 -0
- package/dist/types/NotificationServicesController/__fixtures__/mock-notification-user-storage.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/__fixtures__/mock-raw-notifications.d.ts +82 -0
- package/dist/types/NotificationServicesController/__fixtures__/mock-raw-notifications.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/__fixtures__/mockResponses.d.ts +28 -0
- package/dist/types/NotificationServicesController/__fixtures__/mockResponses.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/__fixtures__/mockServices.d.ts +12 -0
- package/dist/types/NotificationServicesController/__fixtures__/mockServices.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/__fixtures__/test-utils.d.ts +14 -0
- package/dist/types/NotificationServicesController/__fixtures__/test-utils.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/constants/constants.d.ts +3 -0
- package/dist/types/NotificationServicesController/constants/constants.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/constants/index.d.ts +3 -0
- package/dist/types/NotificationServicesController/constants/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/constants/notification-schema.d.ts +42 -0
- package/dist/types/NotificationServicesController/constants/notification-schema.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/index.d.ts +6 -0
- package/dist/types/NotificationServicesController/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/processors/index.d.ts +4 -0
- package/dist/types/NotificationServicesController/processors/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/processors/process-feature-announcement.d.ts +19 -0
- package/dist/types/NotificationServicesController/processors/process-feature-announcement.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/processors/process-notifications.d.ts +19 -0
- package/dist/types/NotificationServicesController/processors/process-notifications.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/processors/process-onchain-notifications.d.ts +10 -0
- package/dist/types/NotificationServicesController/processors/process-onchain-notifications.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/services/feature-announcements.d.ts +28 -0
- package/dist/types/NotificationServicesController/services/feature-announcements.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/services/onchain-notifications.d.ts +62 -0
- package/dist/types/NotificationServicesController/services/onchain-notifications.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/feature-announcement/feature-announcement.d.ts +30 -0
- package/dist/types/NotificationServicesController/types/feature-announcement/feature-announcement.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/feature-announcement/index.d.ts +4 -0
- package/dist/types/NotificationServicesController/types/feature-announcement/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/feature-announcement/type-feature-announcement.d.ts +38 -0
- package/dist/types/NotificationServicesController/types/feature-announcement/type-feature-announcement.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/feature-announcement/type-links.d.ts +24 -0
- package/dist/types/NotificationServicesController/types/feature-announcement/type-links.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/index.d.ts +5 -0
- package/dist/types/NotificationServicesController/types/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/notification/index.d.ts +2 -0
- package/dist/types/NotificationServicesController/types/notification/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/notification/notification.d.ts +25 -0
- package/dist/types/NotificationServicesController/types/notification/notification.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/on-chain-notification/index.d.ts +2 -0
- package/dist/types/NotificationServicesController/types/on-chain-notification/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/on-chain-notification/on-chain-notification.d.ts +42 -0
- package/dist/types/NotificationServicesController/types/on-chain-notification/on-chain-notification.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/on-chain-notification/schema.d.ts +283 -0
- package/dist/types/NotificationServicesController/types/on-chain-notification/schema.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/type-utils.d.ts +7 -0
- package/dist/types/NotificationServicesController/types/type-utils.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/user-storage/index.d.ts +2 -0
- package/dist/types/NotificationServicesController/types/user-storage/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/types/user-storage/user-storage.d.ts +26 -0
- package/dist/types/NotificationServicesController/types/user-storage/user-storage.d.ts.map +1 -0
- package/dist/types/NotificationServicesController/utils/utils.d.ts +144 -0
- package/dist/types/NotificationServicesController/utils/utils.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/NotificationServicesPushController.d.ts +103 -0
- package/dist/types/NotificationServicesPushController/NotificationServicesPushController.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/__fixtures__/index.d.ts +3 -0
- package/dist/types/NotificationServicesPushController/__fixtures__/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/__fixtures__/mockResponse.d.ts +43 -0
- package/dist/types/NotificationServicesPushController/__fixtures__/mockResponse.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/__fixtures__/mockServices.d.ts +9 -0
- package/dist/types/NotificationServicesPushController/__fixtures__/mockServices.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/constants.d.ts +11 -0
- package/dist/types/NotificationServicesPushController/constants.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/index.d.ts +5 -0
- package/dist/types/NotificationServicesPushController/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/services/endpoints.d.ts +2 -0
- package/dist/types/NotificationServicesPushController/services/endpoints.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/services/push/index.d.ts +6 -0
- package/dist/types/NotificationServicesPushController/services/push/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/services/push/push-web.d.ts +32 -0
- package/dist/types/NotificationServicesPushController/services/push/push-web.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/services/services.d.ts +95 -0
- package/dist/types/NotificationServicesPushController/services/services.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/types/firebase.d.ts +53 -0
- package/dist/types/NotificationServicesPushController/types/firebase.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/types/index.d.ts +2 -0
- package/dist/types/NotificationServicesPushController/types/index.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/utils/get-notification-data.d.ts +42 -0
- package/dist/types/NotificationServicesPushController/utils/get-notification-data.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/utils/get-notification-message.d.ts +67 -0
- package/dist/types/NotificationServicesPushController/utils/get-notification-message.d.ts.map +1 -0
- package/dist/types/NotificationServicesPushController/utils/index.d.ts +3 -0
- package/dist/types/NotificationServicesPushController/utils/index.d.ts.map +1 -0
- package/dist/types/index.d.ts +3 -0
- package/dist/types/index.d.ts.map +1 -0
- package/package.json +80 -0
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import type { Entry, Asset } from 'contentful';
|
|
2
|
+
import type { TypeFeatureAnnouncement } from '../types/feature-announcement/type-feature-announcement';
|
|
3
|
+
import type { INotification } from '../types/notification/notification';
|
|
4
|
+
export declare const FEATURE_ANNOUNCEMENT_API: string;
|
|
5
|
+
export declare const FEATURE_ANNOUNCEMENT_URL: string;
|
|
6
|
+
type Env = {
|
|
7
|
+
spaceId: string;
|
|
8
|
+
accessToken: string;
|
|
9
|
+
platform: string;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* Contentful API Response Shape
|
|
13
|
+
*/
|
|
14
|
+
export type ContentfulResult = {
|
|
15
|
+
includes?: {
|
|
16
|
+
Entry?: Entry[];
|
|
17
|
+
Asset?: Asset[];
|
|
18
|
+
};
|
|
19
|
+
items?: TypeFeatureAnnouncement[];
|
|
20
|
+
};
|
|
21
|
+
/**
|
|
22
|
+
* Gets Feature Announcement from our services
|
|
23
|
+
* @param env - environment for feature announcements
|
|
24
|
+
* @returns Raw Feature Announcements
|
|
25
|
+
*/
|
|
26
|
+
export declare function getFeatureAnnouncementNotifications(env: Env): Promise<INotification[]>;
|
|
27
|
+
export {};
|
|
28
|
+
//# sourceMappingURL=feature-announcements.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"feature-announcements.d.ts","sourceRoot":"","sources":["../../../../src/NotificationServicesController/services/feature-announcements.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AAM/C,OAAO,KAAK,EAEV,uBAAuB,EACxB,MAAM,yDAAyD,CAAC;AAEjE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AAKxE,eAAO,MAAM,wBAAwB,QAAsF,CAAC;AAC5H,eAAO,MAAM,wBAAwB,QAAqJ,CAAC;AAE3L,KAAK,GAAG,GAAG;IACT,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,CAAC,EAAE;QAET,KAAK,CAAC,EAAE,KAAK,EAAE,CAAC;QAEhB,KAAK,CAAC,EAAE,KAAK,EAAE,CAAC;KACjB,CAAC;IACF,KAAK,CAAC,EAAE,uBAAuB,EAAE,CAAC;CACnC,CAAC;AA4FF;;;;GAIG;AACH,wBAAsB,mCAAmC,CACvD,GAAG,EAAE,GAAG,GACP,OAAO,CAAC,aAAa,EAAE,CAAC,CAO1B"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import type { OnChainRawNotification } from '../types/on-chain-notification/on-chain-notification';
|
|
2
|
+
import type { UserStorage } from '../types/user-storage/user-storage';
|
|
3
|
+
export type NotificationTrigger = {
|
|
4
|
+
id: string;
|
|
5
|
+
chainId: string;
|
|
6
|
+
kind: string;
|
|
7
|
+
address: string;
|
|
8
|
+
};
|
|
9
|
+
export declare const TRIGGER_API = "https://trigger.api.cx.metamask.io";
|
|
10
|
+
export declare const NOTIFICATION_API = "https://notification.api.cx.metamask.io";
|
|
11
|
+
export declare const TRIGGER_API_BATCH_ENDPOINT: string;
|
|
12
|
+
export declare const NOTIFICATION_API_LIST_ENDPOINT: string;
|
|
13
|
+
export declare const NOTIFICATION_API_LIST_ENDPOINT_PAGE_QUERY: (page: number) => string;
|
|
14
|
+
export declare const NOTIFICATION_API_MARK_ALL_AS_READ_ENDPOINT: string;
|
|
15
|
+
/**
|
|
16
|
+
* Creates on-chain triggers based on the provided notification triggers.
|
|
17
|
+
* This method generates a unique token for each trigger using the trigger ID and storage key,
|
|
18
|
+
* proving ownership of the trigger being updated. It then makes an API call to create these triggers.
|
|
19
|
+
* Upon successful creation, it updates the userStorage to reflect the new trigger status.
|
|
20
|
+
*
|
|
21
|
+
* @param userStorage - The user's storage object where triggers and their statuses are stored.
|
|
22
|
+
* @param storageKey - A key used along with the trigger ID to generate a unique token for each trigger.
|
|
23
|
+
* @param bearerToken - The JSON Web Token used for authentication in the API call.
|
|
24
|
+
* @param triggers - An array of notification triggers to be created. Each trigger includes an ID, chain ID, kind, and address.
|
|
25
|
+
* @returns A promise that resolves to void. Throws an error if the API call fails or if there's an issue creating the triggers.
|
|
26
|
+
*/
|
|
27
|
+
export declare function createOnChainTriggers(userStorage: UserStorage, storageKey: string, bearerToken: string, triggers: NotificationTrigger[]): Promise<void>;
|
|
28
|
+
/**
|
|
29
|
+
* Deletes on-chain triggers based on the provided UUIDs.
|
|
30
|
+
* This method generates a unique token for each trigger using the UUID and storage key,
|
|
31
|
+
* proving ownership of the trigger being deleted. It then makes an API call to delete these triggers.
|
|
32
|
+
* Upon successful deletion, it updates the userStorage to remove the deleted trigger statuses.
|
|
33
|
+
*
|
|
34
|
+
* @param userStorage - The user's storage object where triggers and their statuses are stored.
|
|
35
|
+
* @param storageKey - A key used along with the UUID to generate a unique token for each trigger.
|
|
36
|
+
* @param bearerToken - The JSON Web Token used for authentication in the API call.
|
|
37
|
+
* @param uuids - An array of UUIDs representing the triggers to be deleted.
|
|
38
|
+
* @returns A promise that resolves to the updated UserStorage object. Throws an error if the API call fails or if there's an issue deleting the triggers.
|
|
39
|
+
*/
|
|
40
|
+
export declare function deleteOnChainTriggers(userStorage: UserStorage, storageKey: string, bearerToken: string, uuids: string[]): Promise<UserStorage>;
|
|
41
|
+
/**
|
|
42
|
+
* Fetches on-chain notifications for the given user storage and BearerToken.
|
|
43
|
+
* This method iterates through the userStorage to find enabled triggers and fetches notifications for those triggers.
|
|
44
|
+
* It makes paginated API calls to the notifications service, transforming and aggregating the notifications into a single array.
|
|
45
|
+
* The process stops either when all pages have been fetched or when a page has less than 100 notifications, indicating the end of the data.
|
|
46
|
+
*
|
|
47
|
+
* @param userStorage - The user's storage object containing trigger information.
|
|
48
|
+
* @param bearerToken - The JSON Web Token used for authentication in the API call.
|
|
49
|
+
* @returns A promise that resolves to an array of OnChainRawNotification objects. If no triggers are enabled or an error occurs, it may return an empty array.
|
|
50
|
+
*/
|
|
51
|
+
export declare function getOnChainNotifications(userStorage: UserStorage, bearerToken: string): Promise<OnChainRawNotification[]>;
|
|
52
|
+
/**
|
|
53
|
+
* Marks the specified notifications as read.
|
|
54
|
+
* This method sends a POST request to the notifications service to mark the provided notification IDs as read.
|
|
55
|
+
* If the operation is successful, it completes without error. If the operation fails, it throws an error with details.
|
|
56
|
+
*
|
|
57
|
+
* @param bearerToken - The JSON Web Token used for authentication in the API call.
|
|
58
|
+
* @param notificationIds - An array of notification IDs to be marked as read.
|
|
59
|
+
* @returns A promise that resolves to void. The promise will reject if there's an error during the API call or if the response status is not 200.
|
|
60
|
+
*/
|
|
61
|
+
export declare function markNotificationsAsRead(bearerToken: string, notificationIds: string[]): Promise<void>;
|
|
62
|
+
//# sourceMappingURL=onchain-notifications.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"onchain-notifications.d.ts","sourceRoot":"","sources":["../../../../src/NotificationServicesController/services/onchain-notifications.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,sBAAsB,EAA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eFeatureAnnouncement } from './type-feature-announcement';
|
|
3
|
+
export type FeatureAnnouncementRawNotificationData = Omit<TypeFeatureAnnouncement['fields'], 'image' | 'longDescription' | 'extensionLink' | 'link' | 'action'> & {
|
|
4
|
+
longDescription: string;
|
|
5
|
+
image: {
|
|
6
|
+
title?: string;
|
|
7
|
+
description?: string;
|
|
8
|
+
url: string;
|
|
9
|
+
};
|
|
10
|
+
link?: {
|
|
11
|
+
linkText: string;
|
|
12
|
+
linkUrl: string;
|
|
13
|
+
isExternal: boolean;
|
|
14
|
+
};
|
|
15
|
+
action?: {
|
|
16
|
+
actionText: string;
|
|
17
|
+
actionUrl: string;
|
|
18
|
+
isExternal: boolean;
|
|
19
|
+
};
|
|
20
|
+
extensionLink?: {
|
|
21
|
+
extensionLinkText: string;
|
|
22
|
+
extensionLinkRoute: string;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
export type FeatureAnnouncementRawNotification = {
|
|
26
|
+
type: TRIGGER_TYPES.FEATURES_ANNOUNCEMENT;
|
|
27
|
+
createdAt: string;
|
|
28
|
+
data: FeatureAnnouncementRawNotificationData;
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=feature-announcement.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"feature-announcement.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/feature-announcement/feature-announcement.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACzE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AAE3E,MAAM,MAAM,sCAAsC,GAAG,IAAI,CACvD,uBAAuB,CAAC,QAAQ,CAAC,EACjC,OAAO,GAAG,iBAAiB,GAAG,eAAe,GAAG,MAAM,GAAG,QAAQ,CAClE,GAAG;IACF,eAAe,EAAE,MAAM,CAAC;IACxB,KAAK,EAAE;QACL,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,GAAG,EAAE,MAAM,CAAC;KACb,CAAC;IAGF,IAAI,CAAC,EAAE;QACL,QAAQ,EAAE,MAAM,CAAC;QACjB,OAAO,EAAE,MAAM,CAAC;QAChB,UAAU,EAAE,OAAO,CAAC;KACrB,CAAC;IACF,MAAM,CAAC,EAAE;QACP,UAAU,EAAE,MAAM,CAAC;QACnB,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,OAAO,CAAC;KACrB,CAAC;IAGF,aAAa,CAAC,EAAE;QACd,iBAAiB,EAAE,MAAM,CAAC;QAC1B,kBAAkB,EAAE,MAAM,CAAC;KAC5B,CAAC;CACH,CAAC;AAEF,MAAM,MAAM,kCAAkC,GAAG;IAC/C,IAAI,EAAE,aAAa,CAAC,qBAAqB,CAAC;IAC1C,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,sCAAsC,CAAC;CAC9C,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/feature-announcement/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,cAAc,CAAC;AAC7B,cAAc,6BAA6B,CAAC"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import type { Entry, EntryFieldTypes } from 'contentful';
|
|
2
|
+
import type { TypeExtensionLinkFields, TypeLinkFields, TypeActionFields } from './type-links';
|
|
3
|
+
export type ImageFields = {
|
|
4
|
+
fields: {
|
|
5
|
+
title?: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
file?: {
|
|
8
|
+
url: string;
|
|
9
|
+
fileName: string;
|
|
10
|
+
contentType: string;
|
|
11
|
+
details: {
|
|
12
|
+
size: number;
|
|
13
|
+
image?: {
|
|
14
|
+
width: number;
|
|
15
|
+
height: number;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
contentTypeId: 'Image';
|
|
21
|
+
};
|
|
22
|
+
export type TypeFeatureAnnouncementFields = {
|
|
23
|
+
fields: {
|
|
24
|
+
title: EntryFieldTypes.Text;
|
|
25
|
+
id: EntryFieldTypes.Symbol;
|
|
26
|
+
category: EntryFieldTypes.Text;
|
|
27
|
+
shortDescription: EntryFieldTypes.Text;
|
|
28
|
+
image: EntryFieldTypes.EntryLink<ImageFields>;
|
|
29
|
+
longDescription: EntryFieldTypes.RichText;
|
|
30
|
+
link?: EntryFieldTypes.EntryLink<TypeLinkFields>;
|
|
31
|
+
action?: EntryFieldTypes.EntryLink<TypeActionFields>;
|
|
32
|
+
extensionLink?: EntryFieldTypes.EntryLink<TypeExtensionLinkFields>;
|
|
33
|
+
clients?: EntryFieldTypes.Text<'extension' | 'mobile' | 'portfolio'>;
|
|
34
|
+
};
|
|
35
|
+
contentTypeId: 'productAnnouncement';
|
|
36
|
+
};
|
|
37
|
+
export type TypeFeatureAnnouncement = Entry<TypeFeatureAnnouncementFields, 'WITHOUT_UNRESOLVABLE_LINKS'>;
|
|
38
|
+
//# sourceMappingURL=type-feature-announcement.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"type-feature-announcement.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/feature-announcement/type-feature-announcement.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAEzD,OAAO,KAAK,EACV,uBAAuB,EACvB,cAAc,EACd,gBAAgB,EACjB,MAAM,cAAc,CAAC;AAEtB,MAAM,MAAM,WAAW,GAAG;IACxB,MAAM,EAAE;QACN,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,IAAI,CAAC,EAAE;YACL,GAAG,EAAE,MAAM,CAAC;YACZ,QAAQ,EAAE,MAAM,CAAC;YACjB,WAAW,EAAE,MAAM,CAAC;YACpB,OAAO,EAAE;gBACP,IAAI,EAAE,MAAM,CAAC;gBACb,KAAK,CAAC,EAAE;oBACN,KAAK,EAAE,MAAM,CAAC;oBACd,MAAM,EAAE,MAAM,CAAC;iBAChB,CAAC;aACH,CAAC;SACH,CAAC;KACH,CAAC;IACF,aAAa,EAAE,OAAO,CAAC;CACxB,CAAC;AAEF,MAAM,MAAM,6BAA6B,GAAG;IAC1C,MAAM,EAAE;QACN,KAAK,EAAE,eAAe,CAAC,IAAI,CAAC;QAC5B,EAAE,EAAE,eAAe,CAAC,MAAM,CAAC;QAC3B,QAAQ,EAAE,eAAe,CAAC,IAAI,CAAC;QAC/B,gBAAgB,EAAE,eAAe,CAAC,IAAI,CAAC;QACvC,KAAK,EAAE,eAAe,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC;QAC9C,eAAe,EAAE,eAAe,CAAC,QAAQ,CAAC;QAG1C,IAAI,CAAC,EAAE,eAAe,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC;QACjD,MAAM,CAAC,EAAE,eAAe,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAC;QAGrD,aAAa,CAAC,EAAE,eAAe,CAAC,SAAS,CAAC,uBAAuB,CAAC,CAAC;QACnE,OAAO,CAAC,EAAE,eAAe,CAAC,IAAI,CAAC,WAAW,GAAG,QAAQ,GAAG,WAAW,CAAC,CAAC;KACtE,CAAC;IACF,aAAa,EAAE,qBAAqB,CAAC;CACtC,CAAC;AAEF,MAAM,MAAM,uBAAuB,GAAG,KAAK,CACzC,6BAA6B,EAC7B,4BAA4B,CAC7B,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export type TypeExtensionLinkFields = {
|
|
2
|
+
fields: {
|
|
3
|
+
extensionLinkText: string;
|
|
4
|
+
extensionLinkRoute: string;
|
|
5
|
+
};
|
|
6
|
+
contentTypeId: 'extensionLink';
|
|
7
|
+
};
|
|
8
|
+
export type TypeLinkFields = {
|
|
9
|
+
fields: {
|
|
10
|
+
linkText: string;
|
|
11
|
+
linkUrl: string;
|
|
12
|
+
isExternal: boolean;
|
|
13
|
+
};
|
|
14
|
+
contentTypeId: 'link';
|
|
15
|
+
};
|
|
16
|
+
export type TypeActionFields = {
|
|
17
|
+
fields: {
|
|
18
|
+
actionText: string;
|
|
19
|
+
actionUrl: string;
|
|
20
|
+
isExternal: boolean;
|
|
21
|
+
};
|
|
22
|
+
contentTypeId: 'action';
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=type-links.d.ts.map
|
package/dist/types/NotificationServicesController/types/feature-announcement/type-links.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"type-links.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/feature-announcement/type-links.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,uBAAuB,GAAG;IACpC,MAAM,EAAE;QACN,iBAAiB,EAAE,MAAM,CAAC;QAC1B,kBAAkB,EAAE,MAAM,CAAC;KAC5B,CAAC;IACF,aAAa,EAAE,eAAe,CAAC;CAChC,CAAC;AAGF,MAAM,MAAM,cAAc,GAAG;IAC3B,MAAM,EAAE;QACN,QAAQ,EAAE,MAAM,CAAC;QACjB,OAAO,EAAE,MAAM,CAAC;QAChB,UAAU,EAAE,OAAO,CAAC;KACrB,CAAC;IACF,aAAa,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,MAAM,EAAE;QACN,UAAU,EAAE,MAAM,CAAC;QACnB,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,OAAO,CAAC;KACrB,CAAC;IACF,aAAa,EAAE,QAAQ,CAAC;CACzB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/NotificationServicesController/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,yBAAyB,CAAC;AACxC,cAAc,gBAAgB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/notification/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type { FeatureAnnouncementRawNotification } from '../feature-announcement/feature-announcement';
|
|
2
|
+
import type { OnChainRawNotification } from '../on-chain-notification/on-chain-notification';
|
|
3
|
+
import type { Compute } from '../type-utils';
|
|
4
|
+
export type NotificationUnion = FeatureAnnouncementRawNotification | OnChainRawNotification;
|
|
5
|
+
/**
|
|
6
|
+
* The shape of a "generic" notification.
|
|
7
|
+
* Other than the fields listed below, tt will also contain:
|
|
8
|
+
* - `type` field (declared in the Raw shapes)
|
|
9
|
+
* - `data` field (declared in the Raw shapes)
|
|
10
|
+
*/
|
|
11
|
+
export type INotification = Compute<NotificationUnion & {
|
|
12
|
+
id: string;
|
|
13
|
+
createdAt: string;
|
|
14
|
+
isRead: boolean;
|
|
15
|
+
}>;
|
|
16
|
+
export type NFT = {
|
|
17
|
+
token_id: string;
|
|
18
|
+
image: string;
|
|
19
|
+
collection?: {
|
|
20
|
+
name: string;
|
|
21
|
+
image: string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
export type MarkAsReadNotificationsParam = Pick<INotification, 'id' | 'type' | 'isRead'>[];
|
|
25
|
+
//# sourceMappingURL=notification.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/notification/notification.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kCAAkC,EAAE,MAAM,8CAA8C,CAAC;AACvG,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gDAAgD,CAAC;AAC7F,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAE7C,MAAM,MAAM,iBAAiB,GACzB,kCAAkC,GAClC,sBAAsB,CAAC;AAE3B;;;;;GAKG;AACH,MAAM,MAAM,aAAa,GAAG,OAAO,CACjC,iBAAiB,GAAG;IAClB,EAAE,EAAE,MAAM,CAAC;IACX,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,OAAO,CAAC;CACjB,CACF,CAAC;AAGF,MAAM,MAAM,GAAG,GAAG;IAEhB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE;QACX,IAAI,EAAE,MAAM,CAAC;QACb,KAAK,EAAE,MAAM,CAAC;KACf,CAAC;CACH,CAAC;AAEF,MAAM,MAAM,4BAA4B,GAAG,IAAI,CAC7C,aAAa,EACb,IAAI,GAAG,MAAM,GAAG,QAAQ,CACzB,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/on-chain-notification/index.ts"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import type { TRIGGER_TYPES } from '../../constants/notification-schema';
|
|
2
|
+
import type { Compute } from '../type-utils';
|
|
3
|
+
import type { components } from './schema';
|
|
4
|
+
export type Data_MetamaskSwapCompleted = components['schemas']['Data_MetamaskSwapCompleted'];
|
|
5
|
+
export type Data_LidoStakeReadyToBeWithdrawn = components['schemas']['Data_LidoStakeReadyToBeWithdrawn'];
|
|
6
|
+
export type Data_LidoStakeCompleted = components['schemas']['Data_LidoStakeCompleted'];
|
|
7
|
+
export type Data_LidoWithdrawalRequested = components['schemas']['Data_LidoWithdrawalRequested'];
|
|
8
|
+
export type Data_LidoWithdrawalCompleted = components['schemas']['Data_LidoWithdrawalCompleted'];
|
|
9
|
+
export type Data_RocketPoolStakeCompleted = components['schemas']['Data_RocketPoolStakeCompleted'];
|
|
10
|
+
export type Data_RocketPoolUnstakeCompleted = components['schemas']['Data_RocketPoolUnstakeCompleted'];
|
|
11
|
+
export type Data_ETHSent = components['schemas']['Data_ETHSent'];
|
|
12
|
+
export type Data_ETHReceived = components['schemas']['Data_ETHReceived'];
|
|
13
|
+
export type Data_ERC20Sent = components['schemas']['Data_ERC20Sent'];
|
|
14
|
+
export type Data_ERC20Received = components['schemas']['Data_ERC20Received'];
|
|
15
|
+
export type Data_ERC721Sent = components['schemas']['Data_ERC721Sent'];
|
|
16
|
+
export type Data_ERC721Received = components['schemas']['Data_ERC721Received'];
|
|
17
|
+
type Notification = components['schemas']['Notification'];
|
|
18
|
+
type NotificationDataKinds = NonNullable<Notification['data']>['kind'];
|
|
19
|
+
type ConvertToEnum<Kind> = {
|
|
20
|
+
[K in TRIGGER_TYPES]: Kind extends `${K}` ? K : never;
|
|
21
|
+
}[TRIGGER_TYPES];
|
|
22
|
+
/**
|
|
23
|
+
* Type-Computation.
|
|
24
|
+
* 1. Adds a `type` field to the notification, it converts the schema type into the ENUM we use.
|
|
25
|
+
* 2. It ensures that the `data` field is the correct Notification data for this `type`
|
|
26
|
+
* - The `Compute` utility merges the intersections (`&`) for a prettier type.
|
|
27
|
+
*/
|
|
28
|
+
export type OnChainRawNotification = {
|
|
29
|
+
[K in NotificationDataKinds]: Compute<Omit<Notification, 'data'> & {
|
|
30
|
+
type: ConvertToEnum<K>;
|
|
31
|
+
data: Extract<Notification['data'], {
|
|
32
|
+
kind: K;
|
|
33
|
+
}>;
|
|
34
|
+
}>;
|
|
35
|
+
}[NotificationDataKinds];
|
|
36
|
+
export type OnChainRawNotificationsWithNetworkFields = Extract<OnChainRawNotification, {
|
|
37
|
+
data: {
|
|
38
|
+
network_fee: unknown;
|
|
39
|
+
};
|
|
40
|
+
}>;
|
|
41
|
+
export {};
|
|
42
|
+
//# sourceMappingURL=on-chain-notification.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"on-chain-notification.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/on-chain-notification/on-chain-notification.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACzE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAE3C,MAAM,MAAM,0BAA0B,GACpC,UAAU,CAAC,SAAS,CAAC,CAAC,4BAA4B,CAAC,CAAC;AACtD,MAAM,MAAM,gCAAgC,GAC1C,UAAU,CAAC,SAAS,CAAC,CAAC,kCAAkC,CAAC,CAAC;AAC5D,MAAM,MAAM,uBAAuB,GACjC,UAAU,CAAC,SAAS,CAAC,CAAC,yBAAyB,CAAC,CAAC;AACnD,MAAM,MAAM,4BAA4B,GACtC,UAAU,CAAC,SAAS,CAAC,CAAC,8BAA8B,CAAC,CAAC;AACxD,MAAM,MAAM,4BAA4B,GACtC,UAAU,CAAC,SAAS,CAAC,CAAC,8BAA8B,CAAC,CAAC;AACxD,MAAM,MAAM,6BAA6B,GACvC,UAAU,CAAC,SAAS,CAAC,CAAC,+BAA+B,CAAC,CAAC;AACzD,MAAM,MAAM,+BAA+B,GACzC,UAAU,CAAC,SAAS,CAAC,CAAC,iCAAiC,CAAC,CAAC;AAC3D,MAAM,MAAM,YAAY,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,cAAc,CAAC,CAAC;AACjE,MAAM,MAAM,gBAAgB,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,kBAAkB,CAAC,CAAC;AACzE,MAAM,MAAM,cAAc,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,gBAAgB,CAAC,CAAC;AACrE,MAAM,MAAM,kBAAkB,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,oBAAoB,CAAC,CAAC;AAC7E,MAAM,MAAM,eAAe,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,iBAAiB,CAAC,CAAC;AACvE,MAAM,MAAM,mBAAmB,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,qBAAqB,CAAC,CAAC;AAE/E,KAAK,YAAY,GAAG,UAAU,CAAC,SAAS,CAAC,CAAC,cAAc,CAAC,CAAC;AAC1D,KAAK,qBAAqB,GAAG,WAAW,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;AACvE,KAAK,aAAa,CAAC,IAAI,IAAI;KACxB,CAAC,IAAI,aAAa,GAAG,IAAI,SAAS,GAAG,CAAC,EAAE,GAAG,CAAC,GAAG,KAAK;CACtD,CAAC,aAAa,CAAC,CAAC;AAEjB;;;;;GAKG;AACH,MAAM,MAAM,sBAAsB,GAAG;KAClC,CAAC,IAAI,qBAAqB,GAAG,OAAO,CACnC,IAAI,CAAC,YAAY,EAAE,MAAM,CAAC,GAAG;QAC3B,IAAI,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;QACvB,IAAI,EAAE,OAAO,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE;YAAE,IAAI,EAAE,CAAC,CAAA;SAAE,CAAC,CAAC;KAClD,CACF;CACF,CAAC,qBAAqB,CAAC,CAAC;AAEzB,MAAM,MAAM,wCAAwC,GAAG,OAAO,CAC5D,sBAAsB,EACtB;IAAE,IAAI,EAAE;QAAE,WAAW,EAAE,OAAO,CAAA;KAAE,CAAA;CAAE,CACnC,CAAC"}
|
|
@@ -0,0 +1,283 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by openapi-typescript.
|
|
3
|
+
* Do not make direct changes to the file.
|
|
4
|
+
* Script: `npx openapi-typescript <PATH TO NOTIFICATION API SPEC> -o ./schema.d.ts`
|
|
5
|
+
*/
|
|
6
|
+
export type paths = {
|
|
7
|
+
'/api/v1/notifications': {
|
|
8
|
+
/** List all notifications ordered by most recent */
|
|
9
|
+
post: {
|
|
10
|
+
parameters: {
|
|
11
|
+
query?: {
|
|
12
|
+
/** @description Page number for pagination */
|
|
13
|
+
page?: number;
|
|
14
|
+
/** @description Number of notifications per page for pagination */
|
|
15
|
+
per_page?: number;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
requestBody?: {
|
|
19
|
+
content: {
|
|
20
|
+
'application/json': {
|
|
21
|
+
trigger_ids: string[];
|
|
22
|
+
chain_ids?: number[];
|
|
23
|
+
kinds?: string[];
|
|
24
|
+
unread?: boolean;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
responses: {
|
|
29
|
+
/** @description Successfully fetched a list of notifications */
|
|
30
|
+
200: {
|
|
31
|
+
content: {
|
|
32
|
+
'application/json': components['schemas']['Notification'][];
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
'/api/v1/notifications/mark-as-read': {
|
|
39
|
+
/** Mark notifications as read */
|
|
40
|
+
post: {
|
|
41
|
+
requestBody: {
|
|
42
|
+
content: {
|
|
43
|
+
'application/json': {
|
|
44
|
+
ids?: string[];
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
responses: {
|
|
49
|
+
/** @description Successfully marked notifications as read */
|
|
50
|
+
200: {
|
|
51
|
+
content: never;
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
};
|
|
56
|
+
};
|
|
57
|
+
export type webhooks = Record<string, never>;
|
|
58
|
+
export type components = {
|
|
59
|
+
schemas: {
|
|
60
|
+
Notification: {
|
|
61
|
+
/** Format: uuid */
|
|
62
|
+
id: string;
|
|
63
|
+
/** Format: uuid */
|
|
64
|
+
trigger_id: string;
|
|
65
|
+
/** @example 1 */
|
|
66
|
+
chain_id: number;
|
|
67
|
+
/** @example 17485840 */
|
|
68
|
+
block_number: number;
|
|
69
|
+
block_timestamp: string;
|
|
70
|
+
/**
|
|
71
|
+
* Format: address
|
|
72
|
+
*
|
|
73
|
+
* @example 0x881D40237659C251811CEC9c364ef91dC08D300C
|
|
74
|
+
*/
|
|
75
|
+
tx_hash: string;
|
|
76
|
+
/** @example false */
|
|
77
|
+
unread: boolean;
|
|
78
|
+
/** Format: date-time */
|
|
79
|
+
created_at: string;
|
|
80
|
+
/** Format: address */
|
|
81
|
+
address: string;
|
|
82
|
+
data?: components['schemas']['Data_MetamaskSwapCompleted'] | components['schemas']['Data_LidoStakeReadyToBeWithdrawn'] | components['schemas']['Data_LidoStakeCompleted'] | components['schemas']['Data_LidoWithdrawalRequested'] | components['schemas']['Data_LidoWithdrawalCompleted'] | components['schemas']['Data_RocketPoolStakeCompleted'] | components['schemas']['Data_RocketPoolUnstakeCompleted'] | components['schemas']['Data_ETHSent'] | components['schemas']['Data_ETHReceived'] | components['schemas']['Data_ERC20Sent'] | components['schemas']['Data_ERC20Received'] | components['schemas']['Data_ERC721Sent'] | components['schemas']['Data_ERC721Received'] | components['schemas']['Data_ERC1155Sent'] | components['schemas']['Data_ERC1155Received'];
|
|
83
|
+
};
|
|
84
|
+
Data_MetamaskSwapCompleted: {
|
|
85
|
+
/** @enum {string} */
|
|
86
|
+
kind: 'metamask_swap_completed';
|
|
87
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
88
|
+
/** Format: decimal */
|
|
89
|
+
rate: string;
|
|
90
|
+
token_in: components['schemas']['Token'];
|
|
91
|
+
token_out: components['schemas']['Token'];
|
|
92
|
+
};
|
|
93
|
+
Data_LidoStakeCompleted: {
|
|
94
|
+
/** @enum {string} */
|
|
95
|
+
kind: 'lido_stake_completed';
|
|
96
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
97
|
+
stake_in: components['schemas']['Stake'];
|
|
98
|
+
stake_out: components['schemas']['Stake'];
|
|
99
|
+
};
|
|
100
|
+
Data_LidoWithdrawalRequested: {
|
|
101
|
+
/** @enum {string} */
|
|
102
|
+
kind: 'lido_withdrawal_requested';
|
|
103
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
104
|
+
stake_in: components['schemas']['Stake'];
|
|
105
|
+
stake_out: components['schemas']['Stake'];
|
|
106
|
+
};
|
|
107
|
+
Data_LidoStakeReadyToBeWithdrawn: {
|
|
108
|
+
/** @enum {string} */
|
|
109
|
+
kind: 'lido_stake_ready_to_be_withdrawn';
|
|
110
|
+
/** Format: decimal */
|
|
111
|
+
request_id: string;
|
|
112
|
+
staked_eth: components['schemas']['Stake'];
|
|
113
|
+
};
|
|
114
|
+
Data_LidoWithdrawalCompleted: {
|
|
115
|
+
/** @enum {string} */
|
|
116
|
+
kind: 'lido_withdrawal_completed';
|
|
117
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
118
|
+
stake_in: components['schemas']['Stake'];
|
|
119
|
+
stake_out: components['schemas']['Stake'];
|
|
120
|
+
};
|
|
121
|
+
Data_RocketPoolStakeCompleted: {
|
|
122
|
+
/** @enum {string} */
|
|
123
|
+
kind: 'rocketpool_stake_completed';
|
|
124
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
125
|
+
stake_in: components['schemas']['Stake'];
|
|
126
|
+
stake_out: components['schemas']['Stake'];
|
|
127
|
+
};
|
|
128
|
+
Data_RocketPoolUnstakeCompleted: {
|
|
129
|
+
/** @enum {string} */
|
|
130
|
+
kind: 'rocketpool_unstake_completed';
|
|
131
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
132
|
+
stake_in: components['schemas']['Stake'];
|
|
133
|
+
stake_out: components['schemas']['Stake'];
|
|
134
|
+
};
|
|
135
|
+
Data_ETHSent: {
|
|
136
|
+
/** @enum {string} */
|
|
137
|
+
kind: 'eth_sent';
|
|
138
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
139
|
+
/** Format: address */
|
|
140
|
+
from: string;
|
|
141
|
+
/** Format: address */
|
|
142
|
+
to: string;
|
|
143
|
+
amount: {
|
|
144
|
+
/** Format: decimal */
|
|
145
|
+
usd: string;
|
|
146
|
+
/** Format: decimal */
|
|
147
|
+
eth: string;
|
|
148
|
+
};
|
|
149
|
+
};
|
|
150
|
+
Data_ETHReceived: {
|
|
151
|
+
/** @enum {string} */
|
|
152
|
+
kind: 'eth_received';
|
|
153
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
154
|
+
/** Format: address */
|
|
155
|
+
from: string;
|
|
156
|
+
/** Format: address */
|
|
157
|
+
to: string;
|
|
158
|
+
amount: {
|
|
159
|
+
/** Format: decimal */
|
|
160
|
+
usd: string;
|
|
161
|
+
/** Format: decimal */
|
|
162
|
+
eth: string;
|
|
163
|
+
};
|
|
164
|
+
};
|
|
165
|
+
Data_ERC20Sent: {
|
|
166
|
+
/** @enum {string} */
|
|
167
|
+
kind: 'erc20_sent';
|
|
168
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
169
|
+
/** Format: address */
|
|
170
|
+
from: string;
|
|
171
|
+
/** Format: address */
|
|
172
|
+
to: string;
|
|
173
|
+
token: components['schemas']['Token'];
|
|
174
|
+
};
|
|
175
|
+
Data_ERC20Received: {
|
|
176
|
+
/** @enum {string} */
|
|
177
|
+
kind: 'erc20_received';
|
|
178
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
179
|
+
/** Format: address */
|
|
180
|
+
from: string;
|
|
181
|
+
/** Format: address */
|
|
182
|
+
to: string;
|
|
183
|
+
token: components['schemas']['Token'];
|
|
184
|
+
};
|
|
185
|
+
Data_ERC721Sent: {
|
|
186
|
+
/** @enum {string} */
|
|
187
|
+
kind: 'erc721_sent';
|
|
188
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
189
|
+
/** Format: address */
|
|
190
|
+
from: string;
|
|
191
|
+
/** Format: address */
|
|
192
|
+
to: string;
|
|
193
|
+
nft: components['schemas']['NFT'];
|
|
194
|
+
};
|
|
195
|
+
Data_ERC721Received: {
|
|
196
|
+
/** @enum {string} */
|
|
197
|
+
kind: 'erc721_received';
|
|
198
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
199
|
+
/** Format: address */
|
|
200
|
+
from: string;
|
|
201
|
+
/** Format: address */
|
|
202
|
+
to: string;
|
|
203
|
+
nft: components['schemas']['NFT'];
|
|
204
|
+
};
|
|
205
|
+
Data_ERC1155Sent: {
|
|
206
|
+
/** @enum {string} */
|
|
207
|
+
kind: 'erc1155_sent';
|
|
208
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
209
|
+
/** Format: address */
|
|
210
|
+
from: string;
|
|
211
|
+
/** Format: address */
|
|
212
|
+
to: string;
|
|
213
|
+
nft?: components['schemas']['NFT'];
|
|
214
|
+
};
|
|
215
|
+
Data_ERC1155Received: {
|
|
216
|
+
/** @enum {string} */
|
|
217
|
+
kind: 'erc1155_received';
|
|
218
|
+
network_fee: components['schemas']['NetworkFee'];
|
|
219
|
+
/** Format: address */
|
|
220
|
+
from: string;
|
|
221
|
+
/** Format: address */
|
|
222
|
+
to: string;
|
|
223
|
+
nft?: components['schemas']['NFT'];
|
|
224
|
+
};
|
|
225
|
+
NetworkFee: {
|
|
226
|
+
/** Format: decimal */
|
|
227
|
+
gas_price: string;
|
|
228
|
+
/** Format: decimal */
|
|
229
|
+
native_token_price_in_usd: string;
|
|
230
|
+
};
|
|
231
|
+
Token: {
|
|
232
|
+
/** Format: address */
|
|
233
|
+
address: string;
|
|
234
|
+
symbol: string;
|
|
235
|
+
name: string;
|
|
236
|
+
/** Format: decimal */
|
|
237
|
+
amount: string;
|
|
238
|
+
/** Format: int32 */
|
|
239
|
+
decimals: string;
|
|
240
|
+
/** Format: uri */
|
|
241
|
+
image: string;
|
|
242
|
+
/** Format: decimal */
|
|
243
|
+
usd: string;
|
|
244
|
+
};
|
|
245
|
+
NFT: {
|
|
246
|
+
name: string;
|
|
247
|
+
token_id: string;
|
|
248
|
+
/** Format: uri */
|
|
249
|
+
image: string;
|
|
250
|
+
collection: {
|
|
251
|
+
/** Format: address */
|
|
252
|
+
address: string;
|
|
253
|
+
name: string;
|
|
254
|
+
symbol: string;
|
|
255
|
+
/** Format: uri */
|
|
256
|
+
image: string;
|
|
257
|
+
};
|
|
258
|
+
};
|
|
259
|
+
Stake: {
|
|
260
|
+
/** Format: address */
|
|
261
|
+
address: string;
|
|
262
|
+
symbol: string;
|
|
263
|
+
name: string;
|
|
264
|
+
/** Format: decimal */
|
|
265
|
+
amount: string;
|
|
266
|
+
/** Format: int32 */
|
|
267
|
+
decimals: string;
|
|
268
|
+
/** Format: uri */
|
|
269
|
+
image: string;
|
|
270
|
+
/** Format: decimal */
|
|
271
|
+
usd: string;
|
|
272
|
+
};
|
|
273
|
+
};
|
|
274
|
+
responses: never;
|
|
275
|
+
parameters: never;
|
|
276
|
+
requestBodies: never;
|
|
277
|
+
headers: never;
|
|
278
|
+
pathItems: never;
|
|
279
|
+
};
|
|
280
|
+
export type $defs = Record<string, never>;
|
|
281
|
+
export type external = Record<string, never>;
|
|
282
|
+
export type operations = Record<string, never>;
|
|
283
|
+
//# sourceMappingURL=schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../../src/NotificationServicesController/types/on-chain-notification/schema.ts"],"names":[],"mappings":"AACA;;;;GAIG;AAEH,MAAM,MAAM,KAAK,GAAG;IAClB,uBAAuB,EAAE;QACvB,oDAAoD;QACpD,IAAI,EAAE;YACJ,UAAU,EAAE;gBACV,KAAK,CAAC,EAAE;oBACN,8CAA8C;oBAC9C,IAAI,CAAC,EAAE,MAAM,CAAC;oBACd,mEAAmE;oBACnE,QAAQ,CAAC,EAAE,MAAM,CAAC;iBACnB,CAAC;aACH,CAAC;YACF,WAAW,CAAC,EAAE;gBACZ,OAAO,EAAE;oBACP,kBAAkB,EAAE;wBAClB,WAAW,EAAE,MAAM,EAAE,CAAC;wBACtB,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;wBACrB,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;wBACjB,MAAM,CAAC,EAAE,OAAO,CAAC;qBAClB,CAAC;iBACH,CAAC;aACH,CAAC;YACF,SAAS,EAAE;gBACT,gEAAgE;gBAChE,GAAG,EAAE;oBAC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AAC;AAEF,MAAM,MAAM,KAAK,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;AAE1C,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;AAE7C,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"type-utils.d.ts","sourceRoot":"","sources":["../../../../src/NotificationServicesController/types/type-utils.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,MAAM,OAAO,CAAC,IAAI,IAAI,IAAI,SAAS,IAAI,GACzC;KAAG,CAAC,IAAI,MAAM,IAAI,GAAG,IAAI,CAAC,CAAC,CAAC;CAAE,GAC9B,KAAK,CAAC"}
|