@roketus/loyalty-js-sdk 4.35.0

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.
Files changed (480) hide show
  1. package/README.md +8 -0
  2. package/dist/cjs/IContainerRegistry.d.ts +7 -0
  3. package/dist/cjs/api/analytics/createEvent.d.ts +2 -0
  4. package/dist/cjs/api/analytics/getActiveUsersData.d.ts +2 -0
  5. package/dist/cjs/api/analytics/getCardConversionStats.d.ts +2 -0
  6. package/dist/cjs/api/analytics/getGeneralCardsData.d.ts +2 -0
  7. package/dist/cjs/api/analytics/getIssuedCardsStats.d.ts +2 -0
  8. package/dist/cjs/api/analytics/getMyNotificationStats.d.ts +2 -0
  9. package/dist/cjs/api/analytics/getPointsAddedStats.d.ts +2 -0
  10. package/dist/cjs/api/analytics/getPointsData.d.ts +2 -0
  11. package/dist/cjs/api/analytics/getPointsUsedStats.d.ts +2 -0
  12. package/dist/cjs/api/analytics/getPurchasesStats.d.ts +2 -0
  13. package/dist/cjs/api/analytics/getUniquePurchasesStats.d.ts +2 -0
  14. package/dist/cjs/api/analytics/getUserCompositionStats.d.ts +2 -0
  15. package/dist/cjs/api/analytics/utils.d.ts +1 -0
  16. package/dist/cjs/api/auth/getJWTByApiKey.d.ts +2 -0
  17. package/dist/cjs/api/auth/getUserData.d.ts +2 -0
  18. package/dist/cjs/api/auth/signInByPhone.d.ts +2 -0
  19. package/dist/cjs/api/auth/validatePhoneOtp.d.ts +2 -0
  20. package/dist/cjs/api/campaign/createCampaign.d.ts +2 -0
  21. package/dist/cjs/api/campaign/createEmailTemplate.d.ts +16 -0
  22. package/dist/cjs/api/campaign/createPassPushTemplate.d.ts +15 -0
  23. package/dist/cjs/api/campaign/createSMSTemplate.d.ts +14 -0
  24. package/dist/cjs/api/campaign/createWebPushTemplate.d.ts +15 -0
  25. package/dist/cjs/api/campaign/deleteTemplate.d.ts +2 -0
  26. package/dist/cjs/api/campaign/deleteTemplateFromCampaign.d.ts +2 -0
  27. package/dist/cjs/api/campaign/getCampaignById.d.ts +2 -0
  28. package/dist/cjs/api/campaign/getMyCampaign.d.ts +2 -0
  29. package/dist/cjs/api/campaign/getMyCohorts.d.ts +2 -0
  30. package/dist/cjs/api/campaign/getMyTemplates.d.ts +2 -0
  31. package/dist/cjs/api/campaign/getTemplateById.d.ts +2 -0
  32. package/dist/cjs/api/campaign/runCampaign.d.ts +2 -0
  33. package/dist/cjs/api/campaign/setCohortToCampaign.d.ts +2 -0
  34. package/dist/cjs/api/campaign/setTemplateToCampaign.d.ts +2 -0
  35. package/dist/cjs/api/campaign/setTemplatesToCampaign.d.ts +2 -0
  36. package/dist/cjs/api/campaign/updateEmailTemplate.d.ts +2 -0
  37. package/dist/cjs/api/campaign/updatePassPushTemplate.d.ts +2 -0
  38. package/dist/cjs/api/campaign/updateSMSTemplate.d.ts +2 -0
  39. package/dist/cjs/api/campaign/updateWebPushTemplate.d.ts +2 -0
  40. package/dist/cjs/api/card/addPoints.d.ts +2 -0
  41. package/dist/cjs/api/card/addReserve.d.ts +2 -0
  42. package/dist/cjs/api/card/createAnonymousCard.d.ts +2 -0
  43. package/dist/cjs/api/card/downloadAndroidCard.d.ts +2 -0
  44. package/dist/cjs/api/card/downloadAnonymousCard.d.ts +2 -0
  45. package/dist/cjs/api/card/downloadCardFromPromise.d.ts +4 -0
  46. package/dist/cjs/api/card/downloadIOSCard.d.ts +2 -0
  47. package/dist/cjs/api/card/getBalanceHistory.d.ts +3 -0
  48. package/dist/cjs/api/card/getBonuses.d.ts +2 -0
  49. package/dist/cjs/api/card/getReferral.d.ts +2 -0
  50. package/dist/cjs/api/card/getUserCard.d.ts +2 -0
  51. package/dist/cjs/api/card/restoreCard.d.ts +2 -0
  52. package/dist/cjs/api/card/setTypeCard.d.ts +2 -0
  53. package/dist/cjs/api/card/spendPoints.d.ts +2 -0
  54. package/dist/cjs/api/card/updateCard.d.ts +2 -0
  55. package/dist/cjs/api/card/updateDiscountPercent.d.ts +2 -0
  56. package/dist/cjs/api/cardManagement/createCard.d.ts +2 -0
  57. package/dist/cjs/api/cardManagement/deactivateCard.d.ts +2 -0
  58. package/dist/cjs/api/cardManagement/issueCard.d.ts +2 -0
  59. package/dist/cjs/api/cardManagement/listCards.d.ts +2 -0
  60. package/dist/cjs/api/cardManagement/resultSerializer.d.ts +1 -0
  61. package/dist/cjs/api/cardManagement/updateCustomParams.d.ts +2 -0
  62. package/dist/cjs/api/cardManagement/updateExpirationDate.d.ts +2 -0
  63. package/dist/cjs/api/excludes/createExclude.d.ts +2 -0
  64. package/dist/cjs/api/excludes/deleteExclude.d.ts +2 -0
  65. package/dist/cjs/api/excludes/getExclude.d.ts +2 -0
  66. package/dist/cjs/api/excludes/listExcludes.d.ts +2 -0
  67. package/dist/cjs/api/excludes/resultSerializer.d.ts +1 -0
  68. package/dist/cjs/api/excludes/updateExclude.d.ts +2 -0
  69. package/dist/cjs/api/issuer/authByPassToken.d.ts +2 -0
  70. package/dist/cjs/api/issuer/authByToken.d.ts +2 -0
  71. package/dist/cjs/api/issuer/createIssuer.d.ts +2 -0
  72. package/dist/cjs/api/issuer/dispatchCustomEvent.d.ts +2 -0
  73. package/dist/cjs/api/issuer/getCardBonuses.d.ts +13 -0
  74. package/dist/cjs/api/issuer/getCardById.d.ts +2 -0
  75. package/dist/cjs/api/issuer/getCardByPhone.d.ts +2 -0
  76. package/dist/cjs/api/issuer/getCardSpends.d.ts +2 -0
  77. package/dist/cjs/api/issuer/getIssuer.d.ts +2 -0
  78. package/dist/cjs/api/issuer/refreshApiKey.d.ts +2 -0
  79. package/dist/cjs/api/issuer/sendNotificationToCards.d.ts +2 -0
  80. package/dist/cjs/api/issuer/sendPushNotification.d.ts +3 -0
  81. package/dist/cjs/api/issuer/sendToAllIssuerCards.d.ts +2 -0
  82. package/dist/cjs/api/issuer/setCardName.d.ts +2 -0
  83. package/dist/cjs/api/issuer/setSettings.d.ts +2 -0
  84. package/dist/cjs/api/logger/logDebug.d.ts +2 -0
  85. package/dist/cjs/api/logger/logError.d.ts +2 -0
  86. package/dist/cjs/api/logger/logInfo.d.ts +2 -0
  87. package/dist/cjs/api/logger/setup.d.ts +3 -0
  88. package/dist/cjs/api/notification/listEmailTemplates.d.ts +2 -0
  89. package/dist/cjs/api/notification/sendCompanyEmailByEvent.d.ts +2 -0
  90. package/dist/cjs/api/notification/sendCompanySmsByEvent.d.ts +2 -0
  91. package/dist/cjs/api/notification/sendEmailByEvent.d.ts +2 -0
  92. package/dist/cjs/api/notification/subscribeToNotifications.d.ts +2 -0
  93. package/dist/cjs/api/order/closeOrder.d.ts +2 -0
  94. package/dist/cjs/api/order/openOrder.d.ts +2 -0
  95. package/dist/cjs/api/order/resultSerializer.d.ts +1 -0
  96. package/dist/cjs/api/products/categoryResultSerializer.d.ts +1 -0
  97. package/dist/cjs/api/products/getCategoryById.d.ts +2 -0
  98. package/dist/cjs/api/products/getProductById.d.ts +2 -0
  99. package/dist/cjs/api/products/productResultSerializer.d.ts +1 -0
  100. package/dist/cjs/api/products/searchCategories.d.ts +2 -0
  101. package/dist/cjs/api/products/searchProducts.d.ts +2 -0
  102. package/dist/cjs/api/promocode/archivePromocode.d.ts +2 -0
  103. package/dist/cjs/api/promocode/createPromocode.d.ts +2 -0
  104. package/dist/cjs/api/promocode/getPromocodeById.d.ts +2 -0
  105. package/dist/cjs/api/promocode/listPromocodes.d.ts +2 -0
  106. package/dist/cjs/api/promocode/resultSerializer.d.ts +1 -0
  107. package/dist/cjs/api/promocode/unarchivePromocode.d.ts +2 -0
  108. package/dist/cjs/api/promocode/updatePromocode.d.ts +2 -0
  109. package/dist/cjs/api/promocode/usePromocode.d.ts +2 -0
  110. package/dist/cjs/api/referralProgram/archiveRefProgram.d.ts +2 -0
  111. package/dist/cjs/api/referralProgram/createRefProgram.d.ts +2 -0
  112. package/dist/cjs/api/referralProgram/getRefProgram.d.ts +2 -0
  113. package/dist/cjs/api/referralProgram/getRefProgramStats.d.ts +2 -0
  114. package/dist/cjs/api/referralProgram/influencers/addInfluencer.d.ts +2 -0
  115. package/dist/cjs/api/referralProgram/influencers/deleteInfluencer.d.ts +2 -0
  116. package/dist/cjs/api/referralProgram/influencers/getInfluencer.d.ts +2 -0
  117. package/dist/cjs/api/referralProgram/influencers/getStatsByInfluencer.d.ts +2 -0
  118. package/dist/cjs/api/referralProgram/influencers/listInfluencers.d.ts +2 -0
  119. package/dist/cjs/api/referralProgram/influencers/resultSerializer.d.ts +1 -0
  120. package/dist/cjs/api/referralProgram/influencers/updateInfluencer.d.ts +2 -0
  121. package/dist/cjs/api/referralProgram/listRefPrograms.d.ts +2 -0
  122. package/dist/cjs/api/referralProgram/resultSerializer.d.ts +1 -0
  123. package/dist/cjs/api/referralProgram/unarchiveRefProgram.d.ts +2 -0
  124. package/dist/cjs/api/referralProgram/updateRefProgram.d.ts +2 -0
  125. package/dist/cjs/api/shortLink/createLink.d.ts +2 -0
  126. package/dist/cjs/api/shortLink/deleteLink.d.ts +2 -0
  127. package/dist/cjs/api/shortLink/editLink.d.ts +2 -0
  128. package/dist/cjs/api/shortLink/listLinks.d.ts +2 -0
  129. package/dist/cjs/api/shortLink/resultSerializer.d.ts +1 -0
  130. package/dist/cjs/api/shortLink/viewLink.d.ts +2 -0
  131. package/dist/cjs/api/shortLink/wait.d.ts +1 -0
  132. package/dist/cjs/api/shortLinkAction/createLinkAction.d.ts +2 -0
  133. package/dist/cjs/api/shortLinkAction/deleteLinkAction.d.ts +2 -0
  134. package/dist/cjs/api/shortLinkAction/editLinkAction.d.ts +2 -0
  135. package/dist/cjs/api/signup/acceptTerms.d.ts +2 -0
  136. package/dist/cjs/api/signup/activateEmail.d.ts +2 -0
  137. package/dist/cjs/api/signup/activatePhone.d.ts +2 -0
  138. package/dist/cjs/api/signup/resendActivationCode.d.ts +2 -0
  139. package/dist/cjs/api/signup/setBirthdate.d.ts +2 -0
  140. package/dist/cjs/api/signup/setEmail.d.ts +2 -0
  141. package/dist/cjs/api/signup/setEmailWithoutActivation.d.ts +2 -0
  142. package/dist/cjs/api/signup/setPhone.d.ts +2 -0
  143. package/dist/cjs/api/signup/setProfile.d.ts +2 -0
  144. package/dist/cjs/api/signup/skipEmail.d.ts +2 -0
  145. package/dist/cjs/api/signup/skipEmailActivation.d.ts +2 -0
  146. package/dist/cjs/api/signup/skipProfile.d.ts +2 -0
  147. package/dist/cjs/api/telemetry/send.d.ts +2 -0
  148. package/dist/cjs/api/tiers/getAllTiers.d.ts +2 -0
  149. package/dist/cjs/api/tiers/getTiersByCard.d.ts +2 -0
  150. package/dist/cjs/api/tiers/setTierByCard.d.ts +2 -0
  151. package/dist/cjs/api/transactions/getTransactionsByCard.d.ts +2 -0
  152. package/dist/cjs/api/url/getShortLink.d.ts +2 -0
  153. package/dist/cjs/api/user/changeEmail.d.ts +2 -0
  154. package/dist/cjs/api/user/changePhone.d.ts +2 -0
  155. package/dist/cjs/api/user/changeProfileData.d.ts +2 -0
  156. package/dist/cjs/api/user/createUser.d.ts +2 -0
  157. package/dist/cjs/api/user/getProfile.d.ts +2 -0
  158. package/dist/cjs/api/user/updateProfileByIssuer.d.ts +2 -0
  159. package/dist/cjs/api/user/validateNewPhoneOtp.d.ts +2 -0
  160. package/dist/cjs/clients/anonymousUserClient.d.ts +2 -0
  161. package/dist/cjs/clients/anonymousUserClientWithIssuer.d.ts +2 -0
  162. package/dist/cjs/clients/issuerClient.d.ts +1 -0
  163. package/dist/cjs/clients/setIssuer.d.ts +3 -0
  164. package/dist/cjs/clients/setIssuerToken.d.ts +2 -0
  165. package/dist/cjs/clients/setUserToken.d.ts +2 -0
  166. package/dist/cjs/clients/timeout.d.ts +1 -0
  167. package/dist/cjs/clients/url.d.ts +1 -0
  168. package/dist/cjs/clients/userClient.d.ts +1 -0
  169. package/dist/cjs/diContainer/container.d.ts +7 -0
  170. package/dist/cjs/diContainer/initializeDependencies.d.ts +1 -0
  171. package/dist/cjs/index.d.ts +59 -0
  172. package/dist/cjs/index.js +1 -0
  173. package/dist/cjs/interfaces/IRequestWithCancel.d.ts +4 -0
  174. package/dist/cjs/interfaces/IRequestWithCancelAndData.d.ts +5 -0
  175. package/dist/cjs/interfaces/ISDK.d.ts +232 -0
  176. package/dist/cjs/interfaces/I_Deserialized_Response_DTO.d.ts +5 -0
  177. package/dist/cjs/interfaces/I_JSON_API_ResponseDTO.d.ts +14 -0
  178. package/dist/cjs/interfaces/JsonApiRequestDTO.d.ts +5 -0
  179. package/dist/cjs/interfaces/analyticsInterfaces.d.ts +86 -0
  180. package/dist/cjs/interfaces/authInterfaces.d.ts +39 -0
  181. package/dist/cjs/interfaces/campaigns/campaignInterfaces.d.ts +174 -0
  182. package/dist/cjs/interfaces/campaigns/common.d.ts +74 -0
  183. package/dist/cjs/interfaces/campaigns/getByID.d.ts +9 -0
  184. package/dist/cjs/interfaces/campaigns/getMyCampaigns.d.ts +8 -0
  185. package/dist/cjs/interfaces/campaigns/index.d.ts +4 -0
  186. package/dist/cjs/interfaces/card/IGetBonuses.d.ts +7 -0
  187. package/dist/cjs/interfaces/cardInterfaces.d.ts +128 -0
  188. package/dist/cjs/interfaces/cardManagement/ICard.d.ts +27 -0
  189. package/dist/cjs/interfaces/cardManagement/cardManagementInterfaces.d.ts +67 -0
  190. package/dist/cjs/interfaces/common/CurrencyCodeEnum.d.ts +5 -0
  191. package/dist/cjs/interfaces/common/NotificationChannelEnum.d.ts +6 -0
  192. package/dist/cjs/interfaces/common/index.d.ts +2 -0
  193. package/dist/cjs/interfaces/excludes/excludeInterfaces.d.ts +43 -0
  194. package/dist/cjs/interfaces/excludes/listExcludesInterfaces.d.ts +10 -0
  195. package/dist/cjs/interfaces/issuer/IGetCardBonuses.d.ts +23 -0
  196. package/dist/cjs/interfaces/issuer/IGetCardSpends.d.ts +15 -0
  197. package/dist/cjs/interfaces/issuerInterface.d.ts +195 -0
  198. package/dist/cjs/interfaces/json.d.ts +5 -0
  199. package/dist/cjs/interfaces/loggerInterface.d.ts +19 -0
  200. package/dist/cjs/interfaces/notifications/IGetMyNotificationStats.d.ts +11 -0
  201. package/dist/cjs/interfaces/order/orderInterfaces.d.ts +101 -0
  202. package/dist/cjs/interfaces/products/TGetGroupById.d.ts +4 -0
  203. package/dist/cjs/interfaces/products/TGetProductById.d.ts +4 -0
  204. package/dist/cjs/interfaces/products/categoryInterfaces.d.ts +11 -0
  205. package/dist/cjs/interfaces/products/listCategoriesInterfaces.d.ts +13 -0
  206. package/dist/cjs/interfaces/products/listProductsInterfaces.d.ts +13 -0
  207. package/dist/cjs/interfaces/products/productInterfaces.d.ts +39 -0
  208. package/dist/cjs/interfaces/products/productSearchInterfaces.d.ts +4 -0
  209. package/dist/cjs/interfaces/promoCodes/ICreatePromocodePayload.d.ts +15 -0
  210. package/dist/cjs/interfaces/promoCodes/IPromocode.d.ts +30 -0
  211. package/dist/cjs/interfaces/promoCodes/IUpdatePromocodePayload.d.ts +14 -0
  212. package/dist/cjs/interfaces/promoCodes/promocodeInterfaces.d.ts +27 -0
  213. package/dist/cjs/interfaces/referralProgram/ICreateRefProgramPayload.d.ts +12 -0
  214. package/dist/cjs/interfaces/referralProgram/IInfluencerPayload.d.ts +7 -0
  215. package/dist/cjs/interfaces/referralProgram/IRefProgramInfluencer.d.ts +12 -0
  216. package/dist/cjs/interfaces/referralProgram/IRefProgramStats.d.ts +19 -0
  217. package/dist/cjs/interfaces/referralProgram/IReferralProgram.d.ts +51 -0
  218. package/dist/cjs/interfaces/referralProgram/IUpdateRefProgramPayload.d.ts +9 -0
  219. package/dist/cjs/interfaces/referralProgram/influencerInterfaces.d.ts +35 -0
  220. package/dist/cjs/interfaces/referralProgram/referralProgramInterfaces.d.ts +45 -0
  221. package/dist/cjs/interfaces/requestFilterInterfaces.d.ts +29 -0
  222. package/dist/cjs/interfaces/shortLinkActionInterface.d.ts +146 -0
  223. package/dist/cjs/interfaces/shortLinkInterface.d.ts +92 -0
  224. package/dist/cjs/interfaces/signupInterface.d.ts +56 -0
  225. package/dist/cjs/interfaces/telemetryInterfaces.d.ts +8 -0
  226. package/dist/cjs/interfaces/tiers/IGetAllTiers.d.ts +41 -0
  227. package/dist/cjs/interfaces/tiers/IGetTiersByCard.d.ts +22 -0
  228. package/dist/cjs/interfaces/tiers/ISetTierByCard.d.ts +16 -0
  229. package/dist/cjs/interfaces/transactions/IGetTransactionsByCard.d.ts +19 -0
  230. package/dist/cjs/interfaces/urlInterfaces.d.ts +19 -0
  231. package/dist/cjs/interfaces/user/IUser.d.ts +20 -0
  232. package/dist/cjs/interfaces/user/IUserCreate.d.ts +22 -0
  233. package/dist/cjs/interfaces/user/IUserUpdate.d.ts +7 -0
  234. package/dist/cjs/interfaces/user/userInterfaces.d.ts +86 -0
  235. package/dist/cjs/interfaces/user/userNotificationsInterfaces.d.ts +34 -0
  236. package/dist/cjs/sdk.d.ts +2 -0
  237. package/dist/cjs/testUtils.d.ts +2 -0
  238. package/dist/cjs/utils/toFilterQueryParams.d.ts +9 -0
  239. package/dist/cjs/utils/toIsoString.d.ts +1 -0
  240. package/dist/cjs/utils/toPagination.d.ts +3 -0
  241. package/dist/esm5/IContainerRegistry.d.ts +7 -0
  242. package/dist/esm5/api/analytics/createEvent.d.ts +2 -0
  243. package/dist/esm5/api/analytics/getActiveUsersData.d.ts +2 -0
  244. package/dist/esm5/api/analytics/getCardConversionStats.d.ts +2 -0
  245. package/dist/esm5/api/analytics/getGeneralCardsData.d.ts +2 -0
  246. package/dist/esm5/api/analytics/getIssuedCardsStats.d.ts +2 -0
  247. package/dist/esm5/api/analytics/getMyNotificationStats.d.ts +2 -0
  248. package/dist/esm5/api/analytics/getPointsAddedStats.d.ts +2 -0
  249. package/dist/esm5/api/analytics/getPointsData.d.ts +2 -0
  250. package/dist/esm5/api/analytics/getPointsUsedStats.d.ts +2 -0
  251. package/dist/esm5/api/analytics/getPurchasesStats.d.ts +2 -0
  252. package/dist/esm5/api/analytics/getUniquePurchasesStats.d.ts +2 -0
  253. package/dist/esm5/api/analytics/getUserCompositionStats.d.ts +2 -0
  254. package/dist/esm5/api/analytics/utils.d.ts +1 -0
  255. package/dist/esm5/api/auth/getJWTByApiKey.d.ts +2 -0
  256. package/dist/esm5/api/auth/getUserData.d.ts +2 -0
  257. package/dist/esm5/api/auth/signInByPhone.d.ts +2 -0
  258. package/dist/esm5/api/auth/validatePhoneOtp.d.ts +2 -0
  259. package/dist/esm5/api/campaign/createCampaign.d.ts +2 -0
  260. package/dist/esm5/api/campaign/createEmailTemplate.d.ts +16 -0
  261. package/dist/esm5/api/campaign/createPassPushTemplate.d.ts +15 -0
  262. package/dist/esm5/api/campaign/createSMSTemplate.d.ts +14 -0
  263. package/dist/esm5/api/campaign/createWebPushTemplate.d.ts +15 -0
  264. package/dist/esm5/api/campaign/deleteTemplate.d.ts +2 -0
  265. package/dist/esm5/api/campaign/deleteTemplateFromCampaign.d.ts +2 -0
  266. package/dist/esm5/api/campaign/getCampaignById.d.ts +2 -0
  267. package/dist/esm5/api/campaign/getMyCampaign.d.ts +2 -0
  268. package/dist/esm5/api/campaign/getMyCohorts.d.ts +2 -0
  269. package/dist/esm5/api/campaign/getMyTemplates.d.ts +2 -0
  270. package/dist/esm5/api/campaign/getTemplateById.d.ts +2 -0
  271. package/dist/esm5/api/campaign/runCampaign.d.ts +2 -0
  272. package/dist/esm5/api/campaign/setCohortToCampaign.d.ts +2 -0
  273. package/dist/esm5/api/campaign/setTemplateToCampaign.d.ts +2 -0
  274. package/dist/esm5/api/campaign/setTemplatesToCampaign.d.ts +2 -0
  275. package/dist/esm5/api/campaign/updateEmailTemplate.d.ts +2 -0
  276. package/dist/esm5/api/campaign/updatePassPushTemplate.d.ts +2 -0
  277. package/dist/esm5/api/campaign/updateSMSTemplate.d.ts +2 -0
  278. package/dist/esm5/api/campaign/updateWebPushTemplate.d.ts +2 -0
  279. package/dist/esm5/api/card/addPoints.d.ts +2 -0
  280. package/dist/esm5/api/card/addReserve.d.ts +2 -0
  281. package/dist/esm5/api/card/createAnonymousCard.d.ts +2 -0
  282. package/dist/esm5/api/card/downloadAndroidCard.d.ts +2 -0
  283. package/dist/esm5/api/card/downloadAnonymousCard.d.ts +2 -0
  284. package/dist/esm5/api/card/downloadCardFromPromise.d.ts +4 -0
  285. package/dist/esm5/api/card/downloadIOSCard.d.ts +2 -0
  286. package/dist/esm5/api/card/getBalanceHistory.d.ts +3 -0
  287. package/dist/esm5/api/card/getBonuses.d.ts +2 -0
  288. package/dist/esm5/api/card/getReferral.d.ts +2 -0
  289. package/dist/esm5/api/card/getUserCard.d.ts +2 -0
  290. package/dist/esm5/api/card/restoreCard.d.ts +2 -0
  291. package/dist/esm5/api/card/setTypeCard.d.ts +2 -0
  292. package/dist/esm5/api/card/spendPoints.d.ts +2 -0
  293. package/dist/esm5/api/card/updateCard.d.ts +2 -0
  294. package/dist/esm5/api/card/updateDiscountPercent.d.ts +2 -0
  295. package/dist/esm5/api/cardManagement/createCard.d.ts +2 -0
  296. package/dist/esm5/api/cardManagement/deactivateCard.d.ts +2 -0
  297. package/dist/esm5/api/cardManagement/issueCard.d.ts +2 -0
  298. package/dist/esm5/api/cardManagement/listCards.d.ts +2 -0
  299. package/dist/esm5/api/cardManagement/resultSerializer.d.ts +1 -0
  300. package/dist/esm5/api/cardManagement/updateCustomParams.d.ts +2 -0
  301. package/dist/esm5/api/cardManagement/updateExpirationDate.d.ts +2 -0
  302. package/dist/esm5/api/excludes/createExclude.d.ts +2 -0
  303. package/dist/esm5/api/excludes/deleteExclude.d.ts +2 -0
  304. package/dist/esm5/api/excludes/getExclude.d.ts +2 -0
  305. package/dist/esm5/api/excludes/listExcludes.d.ts +2 -0
  306. package/dist/esm5/api/excludes/resultSerializer.d.ts +1 -0
  307. package/dist/esm5/api/excludes/updateExclude.d.ts +2 -0
  308. package/dist/esm5/api/issuer/authByPassToken.d.ts +2 -0
  309. package/dist/esm5/api/issuer/authByToken.d.ts +2 -0
  310. package/dist/esm5/api/issuer/createIssuer.d.ts +2 -0
  311. package/dist/esm5/api/issuer/dispatchCustomEvent.d.ts +2 -0
  312. package/dist/esm5/api/issuer/getCardBonuses.d.ts +13 -0
  313. package/dist/esm5/api/issuer/getCardById.d.ts +2 -0
  314. package/dist/esm5/api/issuer/getCardByPhone.d.ts +2 -0
  315. package/dist/esm5/api/issuer/getCardSpends.d.ts +2 -0
  316. package/dist/esm5/api/issuer/getIssuer.d.ts +2 -0
  317. package/dist/esm5/api/issuer/refreshApiKey.d.ts +2 -0
  318. package/dist/esm5/api/issuer/sendNotificationToCards.d.ts +2 -0
  319. package/dist/esm5/api/issuer/sendPushNotification.d.ts +3 -0
  320. package/dist/esm5/api/issuer/sendToAllIssuerCards.d.ts +2 -0
  321. package/dist/esm5/api/issuer/setCardName.d.ts +2 -0
  322. package/dist/esm5/api/issuer/setSettings.d.ts +2 -0
  323. package/dist/esm5/api/logger/logDebug.d.ts +2 -0
  324. package/dist/esm5/api/logger/logError.d.ts +2 -0
  325. package/dist/esm5/api/logger/logInfo.d.ts +2 -0
  326. package/dist/esm5/api/logger/setup.d.ts +3 -0
  327. package/dist/esm5/api/notification/listEmailTemplates.d.ts +2 -0
  328. package/dist/esm5/api/notification/sendCompanyEmailByEvent.d.ts +2 -0
  329. package/dist/esm5/api/notification/sendCompanySmsByEvent.d.ts +2 -0
  330. package/dist/esm5/api/notification/sendEmailByEvent.d.ts +2 -0
  331. package/dist/esm5/api/notification/subscribeToNotifications.d.ts +2 -0
  332. package/dist/esm5/api/order/closeOrder.d.ts +2 -0
  333. package/dist/esm5/api/order/openOrder.d.ts +2 -0
  334. package/dist/esm5/api/order/resultSerializer.d.ts +1 -0
  335. package/dist/esm5/api/products/categoryResultSerializer.d.ts +1 -0
  336. package/dist/esm5/api/products/getCategoryById.d.ts +2 -0
  337. package/dist/esm5/api/products/getProductById.d.ts +2 -0
  338. package/dist/esm5/api/products/productResultSerializer.d.ts +1 -0
  339. package/dist/esm5/api/products/searchCategories.d.ts +2 -0
  340. package/dist/esm5/api/products/searchProducts.d.ts +2 -0
  341. package/dist/esm5/api/promocode/archivePromocode.d.ts +2 -0
  342. package/dist/esm5/api/promocode/createPromocode.d.ts +2 -0
  343. package/dist/esm5/api/promocode/getPromocodeById.d.ts +2 -0
  344. package/dist/esm5/api/promocode/listPromocodes.d.ts +2 -0
  345. package/dist/esm5/api/promocode/resultSerializer.d.ts +1 -0
  346. package/dist/esm5/api/promocode/unarchivePromocode.d.ts +2 -0
  347. package/dist/esm5/api/promocode/updatePromocode.d.ts +2 -0
  348. package/dist/esm5/api/promocode/usePromocode.d.ts +2 -0
  349. package/dist/esm5/api/referralProgram/archiveRefProgram.d.ts +2 -0
  350. package/dist/esm5/api/referralProgram/createRefProgram.d.ts +2 -0
  351. package/dist/esm5/api/referralProgram/getRefProgram.d.ts +2 -0
  352. package/dist/esm5/api/referralProgram/getRefProgramStats.d.ts +2 -0
  353. package/dist/esm5/api/referralProgram/influencers/addInfluencer.d.ts +2 -0
  354. package/dist/esm5/api/referralProgram/influencers/deleteInfluencer.d.ts +2 -0
  355. package/dist/esm5/api/referralProgram/influencers/getInfluencer.d.ts +2 -0
  356. package/dist/esm5/api/referralProgram/influencers/getStatsByInfluencer.d.ts +2 -0
  357. package/dist/esm5/api/referralProgram/influencers/listInfluencers.d.ts +2 -0
  358. package/dist/esm5/api/referralProgram/influencers/resultSerializer.d.ts +1 -0
  359. package/dist/esm5/api/referralProgram/influencers/updateInfluencer.d.ts +2 -0
  360. package/dist/esm5/api/referralProgram/listRefPrograms.d.ts +2 -0
  361. package/dist/esm5/api/referralProgram/resultSerializer.d.ts +1 -0
  362. package/dist/esm5/api/referralProgram/unarchiveRefProgram.d.ts +2 -0
  363. package/dist/esm5/api/referralProgram/updateRefProgram.d.ts +2 -0
  364. package/dist/esm5/api/shortLink/createLink.d.ts +2 -0
  365. package/dist/esm5/api/shortLink/deleteLink.d.ts +2 -0
  366. package/dist/esm5/api/shortLink/editLink.d.ts +2 -0
  367. package/dist/esm5/api/shortLink/listLinks.d.ts +2 -0
  368. package/dist/esm5/api/shortLink/resultSerializer.d.ts +1 -0
  369. package/dist/esm5/api/shortLink/viewLink.d.ts +2 -0
  370. package/dist/esm5/api/shortLink/wait.d.ts +1 -0
  371. package/dist/esm5/api/shortLinkAction/createLinkAction.d.ts +2 -0
  372. package/dist/esm5/api/shortLinkAction/deleteLinkAction.d.ts +2 -0
  373. package/dist/esm5/api/shortLinkAction/editLinkAction.d.ts +2 -0
  374. package/dist/esm5/api/signup/acceptTerms.d.ts +2 -0
  375. package/dist/esm5/api/signup/activateEmail.d.ts +2 -0
  376. package/dist/esm5/api/signup/activatePhone.d.ts +2 -0
  377. package/dist/esm5/api/signup/resendActivationCode.d.ts +2 -0
  378. package/dist/esm5/api/signup/setBirthdate.d.ts +2 -0
  379. package/dist/esm5/api/signup/setEmail.d.ts +2 -0
  380. package/dist/esm5/api/signup/setEmailWithoutActivation.d.ts +2 -0
  381. package/dist/esm5/api/signup/setPhone.d.ts +2 -0
  382. package/dist/esm5/api/signup/setProfile.d.ts +2 -0
  383. package/dist/esm5/api/signup/skipEmail.d.ts +2 -0
  384. package/dist/esm5/api/signup/skipEmailActivation.d.ts +2 -0
  385. package/dist/esm5/api/signup/skipProfile.d.ts +2 -0
  386. package/dist/esm5/api/telemetry/send.d.ts +2 -0
  387. package/dist/esm5/api/tiers/getAllTiers.d.ts +2 -0
  388. package/dist/esm5/api/tiers/getTiersByCard.d.ts +2 -0
  389. package/dist/esm5/api/tiers/setTierByCard.d.ts +2 -0
  390. package/dist/esm5/api/transactions/getTransactionsByCard.d.ts +2 -0
  391. package/dist/esm5/api/url/getShortLink.d.ts +2 -0
  392. package/dist/esm5/api/user/changeEmail.d.ts +2 -0
  393. package/dist/esm5/api/user/changePhone.d.ts +2 -0
  394. package/dist/esm5/api/user/changeProfileData.d.ts +2 -0
  395. package/dist/esm5/api/user/createUser.d.ts +2 -0
  396. package/dist/esm5/api/user/getProfile.d.ts +2 -0
  397. package/dist/esm5/api/user/updateProfileByIssuer.d.ts +2 -0
  398. package/dist/esm5/api/user/validateNewPhoneOtp.d.ts +2 -0
  399. package/dist/esm5/clients/anonymousUserClient.d.ts +2 -0
  400. package/dist/esm5/clients/anonymousUserClientWithIssuer.d.ts +2 -0
  401. package/dist/esm5/clients/issuerClient.d.ts +1 -0
  402. package/dist/esm5/clients/setIssuer.d.ts +3 -0
  403. package/dist/esm5/clients/setIssuerToken.d.ts +2 -0
  404. package/dist/esm5/clients/setUserToken.d.ts +2 -0
  405. package/dist/esm5/clients/timeout.d.ts +1 -0
  406. package/dist/esm5/clients/url.d.ts +1 -0
  407. package/dist/esm5/clients/userClient.d.ts +1 -0
  408. package/dist/esm5/diContainer/container.d.ts +7 -0
  409. package/dist/esm5/diContainer/initializeDependencies.d.ts +1 -0
  410. package/dist/esm5/index.d.ts +59 -0
  411. package/dist/esm5/index.js +1 -0
  412. package/dist/esm5/interfaces/IRequestWithCancel.d.ts +4 -0
  413. package/dist/esm5/interfaces/IRequestWithCancelAndData.d.ts +5 -0
  414. package/dist/esm5/interfaces/ISDK.d.ts +232 -0
  415. package/dist/esm5/interfaces/I_Deserialized_Response_DTO.d.ts +5 -0
  416. package/dist/esm5/interfaces/I_JSON_API_ResponseDTO.d.ts +14 -0
  417. package/dist/esm5/interfaces/JsonApiRequestDTO.d.ts +5 -0
  418. package/dist/esm5/interfaces/analyticsInterfaces.d.ts +86 -0
  419. package/dist/esm5/interfaces/authInterfaces.d.ts +39 -0
  420. package/dist/esm5/interfaces/campaigns/campaignInterfaces.d.ts +174 -0
  421. package/dist/esm5/interfaces/campaigns/common.d.ts +74 -0
  422. package/dist/esm5/interfaces/campaigns/getByID.d.ts +9 -0
  423. package/dist/esm5/interfaces/campaigns/getMyCampaigns.d.ts +8 -0
  424. package/dist/esm5/interfaces/campaigns/index.d.ts +4 -0
  425. package/dist/esm5/interfaces/card/IGetBonuses.d.ts +7 -0
  426. package/dist/esm5/interfaces/cardInterfaces.d.ts +128 -0
  427. package/dist/esm5/interfaces/cardManagement/ICard.d.ts +27 -0
  428. package/dist/esm5/interfaces/cardManagement/cardManagementInterfaces.d.ts +67 -0
  429. package/dist/esm5/interfaces/common/CurrencyCodeEnum.d.ts +5 -0
  430. package/dist/esm5/interfaces/common/NotificationChannelEnum.d.ts +6 -0
  431. package/dist/esm5/interfaces/common/index.d.ts +2 -0
  432. package/dist/esm5/interfaces/excludes/excludeInterfaces.d.ts +43 -0
  433. package/dist/esm5/interfaces/excludes/listExcludesInterfaces.d.ts +10 -0
  434. package/dist/esm5/interfaces/issuer/IGetCardBonuses.d.ts +23 -0
  435. package/dist/esm5/interfaces/issuer/IGetCardSpends.d.ts +15 -0
  436. package/dist/esm5/interfaces/issuerInterface.d.ts +195 -0
  437. package/dist/esm5/interfaces/json.d.ts +5 -0
  438. package/dist/esm5/interfaces/loggerInterface.d.ts +19 -0
  439. package/dist/esm5/interfaces/notifications/IGetMyNotificationStats.d.ts +11 -0
  440. package/dist/esm5/interfaces/order/orderInterfaces.d.ts +101 -0
  441. package/dist/esm5/interfaces/products/TGetGroupById.d.ts +4 -0
  442. package/dist/esm5/interfaces/products/TGetProductById.d.ts +4 -0
  443. package/dist/esm5/interfaces/products/categoryInterfaces.d.ts +11 -0
  444. package/dist/esm5/interfaces/products/listCategoriesInterfaces.d.ts +13 -0
  445. package/dist/esm5/interfaces/products/listProductsInterfaces.d.ts +13 -0
  446. package/dist/esm5/interfaces/products/productInterfaces.d.ts +39 -0
  447. package/dist/esm5/interfaces/products/productSearchInterfaces.d.ts +4 -0
  448. package/dist/esm5/interfaces/promoCodes/ICreatePromocodePayload.d.ts +15 -0
  449. package/dist/esm5/interfaces/promoCodes/IPromocode.d.ts +30 -0
  450. package/dist/esm5/interfaces/promoCodes/IUpdatePromocodePayload.d.ts +14 -0
  451. package/dist/esm5/interfaces/promoCodes/promocodeInterfaces.d.ts +27 -0
  452. package/dist/esm5/interfaces/referralProgram/ICreateRefProgramPayload.d.ts +12 -0
  453. package/dist/esm5/interfaces/referralProgram/IInfluencerPayload.d.ts +7 -0
  454. package/dist/esm5/interfaces/referralProgram/IRefProgramInfluencer.d.ts +12 -0
  455. package/dist/esm5/interfaces/referralProgram/IRefProgramStats.d.ts +19 -0
  456. package/dist/esm5/interfaces/referralProgram/IReferralProgram.d.ts +51 -0
  457. package/dist/esm5/interfaces/referralProgram/IUpdateRefProgramPayload.d.ts +9 -0
  458. package/dist/esm5/interfaces/referralProgram/influencerInterfaces.d.ts +35 -0
  459. package/dist/esm5/interfaces/referralProgram/referralProgramInterfaces.d.ts +45 -0
  460. package/dist/esm5/interfaces/requestFilterInterfaces.d.ts +29 -0
  461. package/dist/esm5/interfaces/shortLinkActionInterface.d.ts +146 -0
  462. package/dist/esm5/interfaces/shortLinkInterface.d.ts +92 -0
  463. package/dist/esm5/interfaces/signupInterface.d.ts +56 -0
  464. package/dist/esm5/interfaces/telemetryInterfaces.d.ts +8 -0
  465. package/dist/esm5/interfaces/tiers/IGetAllTiers.d.ts +41 -0
  466. package/dist/esm5/interfaces/tiers/IGetTiersByCard.d.ts +22 -0
  467. package/dist/esm5/interfaces/tiers/ISetTierByCard.d.ts +16 -0
  468. package/dist/esm5/interfaces/transactions/IGetTransactionsByCard.d.ts +19 -0
  469. package/dist/esm5/interfaces/urlInterfaces.d.ts +19 -0
  470. package/dist/esm5/interfaces/user/IUser.d.ts +20 -0
  471. package/dist/esm5/interfaces/user/IUserCreate.d.ts +22 -0
  472. package/dist/esm5/interfaces/user/IUserUpdate.d.ts +7 -0
  473. package/dist/esm5/interfaces/user/userInterfaces.d.ts +86 -0
  474. package/dist/esm5/interfaces/user/userNotificationsInterfaces.d.ts +34 -0
  475. package/dist/esm5/sdk.d.ts +2 -0
  476. package/dist/esm5/testUtils.d.ts +2 -0
  477. package/dist/esm5/utils/toFilterQueryParams.d.ts +9 -0
  478. package/dist/esm5/utils/toIsoString.d.ts +1 -0
  479. package/dist/esm5/utils/toPagination.d.ts +3 -0
  480. package/package.json +60 -0
@@ -0,0 +1,39 @@
1
+ import { IHTTPClientResponse } from '@roketus/web-toolkit';
2
+ import { ActivationResponseDTO } from './signupInterface';
3
+ export interface IGetUserTokenByIssuerAPIKey {
4
+ (apiKey: string): Promise<string>;
5
+ }
6
+ export interface IGetUserData {
7
+ (): Promise<getUserDataResponseDTO>;
8
+ }
9
+ export interface ISignInByPhone {
10
+ (phoneNumber: string): Promise<CreateAnonymousCardResponseDTO>;
11
+ }
12
+ export interface IValidatePhoneOtp {
13
+ (phoneNumber: string, code: number): Promise<IHTTPClientResponse<ActivationResponseDTO>>;
14
+ }
15
+ interface getUserDataResponseDTO {
16
+ createdAt: string;
17
+ email: string;
18
+ emailVerified: boolean;
19
+ phone: string;
20
+ phoneVerified: boolean;
21
+ }
22
+ interface CreateAnonymousCardResponseDTO {
23
+ data: [
24
+ {
25
+ id: string;
26
+ type: 'card';
27
+ attributes: {
28
+ android_card_file_link: string;
29
+ card_number: string;
30
+ created_at: number;
31
+ ios_card_file_link: string;
32
+ issuer: string;
33
+ };
34
+ relationships: Record<string, unknown>;
35
+ }
36
+ ];
37
+ included: [];
38
+ }
39
+ export {};
@@ -0,0 +1,174 @@
1
+ import { IHTTPClientResponse } from '@roketus/web-toolkit';
2
+ import { ICampaignEmailAttributes, ICampaignJSONAPIDTO, ICampaignPassPushAttributes, ICampaignSMSAttributes, ICampaignWebPushAttributes } from './common';
3
+ export interface ICreateCampaign {
4
+ ({ name }: {
5
+ name: string;
6
+ }): Promise<IHTTPClientResponse<CreateCampaignResponseDTO>>;
7
+ }
8
+ export interface ISetCohortToCampaign {
9
+ ({ campaignId, cohortId }: {
10
+ campaignId: string;
11
+ cohortId: string;
12
+ }): Promise<IHTTPClientResponse<SetCohortToCampaignResponseDTO>>;
13
+ }
14
+ export interface ISetTemplateToCampaign {
15
+ ({ campaignId, templateId }: {
16
+ campaignId: string;
17
+ templateId: string;
18
+ }): Promise<IHTTPClientResponse<SetTemplateToCampaignResponseDTO>>;
19
+ }
20
+ export interface ISetTemplatesToCampaign {
21
+ ({ campaignId, templateIds }: {
22
+ campaignId: string;
23
+ templateIds: string[];
24
+ }): Promise<IHTTPClientResponse<SetTemplateToCampaignResponseDTO>>;
25
+ }
26
+ export interface IDeleteTemplateFromCampaign {
27
+ ({ campaignId, templateId }: {
28
+ campaignId: string;
29
+ templateId: string;
30
+ }): Promise<IHTTPClientResponse<DeleteTemplateFromCampaignResponseDTO>>;
31
+ }
32
+ export interface IRunCampaign {
33
+ ({ campaignId }: {
34
+ campaignId: string;
35
+ }): Promise<IHTTPClientResponse<void>>;
36
+ }
37
+ export interface IGetMyCohorts {
38
+ (): Promise<IHTTPClientResponse<GetMyCohortsResponseDTO>>;
39
+ }
40
+ export interface ICreateSMSTemplate {
41
+ (payload: {
42
+ name: string;
43
+ message: string;
44
+ }): Promise<IHTTPClientResponse<CreateTemplateResponseDTO>>;
45
+ }
46
+ export interface ICreateWebPushTemplate {
47
+ (payload: {
48
+ name: string;
49
+ title: string;
50
+ message: string;
51
+ }): Promise<IHTTPClientResponse<CreateTemplateResponseDTO>>;
52
+ }
53
+ export interface ICreatePassPushTemplate {
54
+ (payload: {
55
+ name: string;
56
+ title: string;
57
+ message: string;
58
+ }): Promise<IHTTPClientResponse<CreateTemplateResponseDTO>>;
59
+ }
60
+ export interface ICreateEmailTemplate {
61
+ (payload: {
62
+ name: string;
63
+ text: string;
64
+ subject: string;
65
+ body: string;
66
+ }): Promise<IHTTPClientResponse<CreateTemplateResponseDTO>>;
67
+ }
68
+ export interface IGetMyTemplates {
69
+ (): Promise<IHTTPClientResponse<GetMyTemplatesResponseDTO>>;
70
+ }
71
+ export interface IGetTemplateById {
72
+ ({ templateId }: {
73
+ templateId: string;
74
+ }): Promise<IHTTPClientResponse<GetTemplateByIdResponseDTO>>;
75
+ }
76
+ export interface IUpdateEmailTemplate {
77
+ (payload: {
78
+ templateId: string;
79
+ name: string;
80
+ subject: string;
81
+ body: string;
82
+ text: string;
83
+ }): Promise<IHTTPClientResponse<void>>;
84
+ }
85
+ export interface IUpdateSMSTemplate {
86
+ (payload: {
87
+ templateId: string;
88
+ name: string;
89
+ message: string;
90
+ }): Promise<IHTTPClientResponse<void>>;
91
+ }
92
+ export interface IUpdateWebPushTemplate {
93
+ (payload: {
94
+ templateId: string;
95
+ name: string;
96
+ message: string;
97
+ title: string;
98
+ }): Promise<IHTTPClientResponse<void>>;
99
+ }
100
+ export interface IUpdatePassPushTemplate {
101
+ (payload: {
102
+ templateId: string;
103
+ name: string;
104
+ message: string;
105
+ title: string;
106
+ }): Promise<IHTTPClientResponse<void>>;
107
+ }
108
+ export interface IDeleteTemplate {
109
+ ({ templateId }: {
110
+ templateId: string;
111
+ }): Promise<IHTTPClientResponse<void>>;
112
+ }
113
+ export interface ICampaignCohortDTO {
114
+ id: string;
115
+ type: 'cohort';
116
+ attributes: {
117
+ count_of_users: number;
118
+ external_id: string;
119
+ last_updated: number;
120
+ name: string;
121
+ };
122
+ relationships: Record<string, unknown>;
123
+ }
124
+ interface IBaseCampaignTemplateDTO<R> {
125
+ id: string;
126
+ type: 'template';
127
+ attributes: {
128
+ channel: string;
129
+ defaultVars?: Record<string, string>;
130
+ event: string;
131
+ name: string;
132
+ requiredVar?: string[];
133
+ template: R;
134
+ };
135
+ relationships: Record<string, unknown>;
136
+ }
137
+ export declare type ICampaignSMSTemplateDTO = IBaseCampaignTemplateDTO<ICampaignSMSAttributes>;
138
+ export declare type ICampaignEmailTemplateDTO = IBaseCampaignTemplateDTO<ICampaignEmailAttributes>;
139
+ export declare type ICampaignPassPushTemplateDTO = IBaseCampaignTemplateDTO<ICampaignPassPushAttributes>;
140
+ export declare type ICampaignWebPushTemplateDTO = IBaseCampaignTemplateDTO<ICampaignWebPushAttributes>;
141
+ export declare type ICampaignTemplateDTO = ICampaignSMSTemplateDTO | ICampaignEmailTemplateDTO | ICampaignPassPushTemplateDTO | ICampaignWebPushTemplateDTO;
142
+ interface CreateCampaignResponseDTO {
143
+ data: ICampaignJSONAPIDTO[];
144
+ included: [];
145
+ }
146
+ interface SetCohortToCampaignResponseDTO {
147
+ data: ICampaignJSONAPIDTO[];
148
+ included: ICampaignCohortDTO[];
149
+ }
150
+ interface SetTemplateToCampaignResponseDTO {
151
+ data: ICampaignJSONAPIDTO[];
152
+ included: (ICampaignCohortDTO | ICampaignTemplateDTO)[];
153
+ }
154
+ interface DeleteTemplateFromCampaignResponseDTO {
155
+ data: ICampaignJSONAPIDTO[];
156
+ included: (ICampaignCohortDTO | ICampaignTemplateDTO)[];
157
+ }
158
+ interface GetMyCohortsResponseDTO {
159
+ data: ICampaignCohortDTO[];
160
+ included: [];
161
+ }
162
+ interface CreateTemplateResponseDTO {
163
+ data: ICampaignTemplateDTO[];
164
+ included: [];
165
+ }
166
+ interface GetMyTemplatesResponseDTO {
167
+ data: ICampaignTemplateDTO[];
168
+ included: [];
169
+ }
170
+ interface GetTemplateByIdResponseDTO {
171
+ data: ICampaignTemplateDTO[];
172
+ included: [];
173
+ }
174
+ export {};
@@ -0,0 +1,74 @@
1
+ export declare type ISO8601Date = string;
2
+ export declare type ICampaignChannel = 'email' | 'sms' | 'webPush' | 'passPush';
3
+ export interface ICampaignChannelData {
4
+ email?: string;
5
+ sms?: string;
6
+ webPush?: string;
7
+ passPush?: string;
8
+ }
9
+ export interface IUsersOperatingSystemsData {
10
+ android?: string;
11
+ ios?: string;
12
+ undefined?: string;
13
+ }
14
+ export interface ICampaignRun {
15
+ id: string;
16
+ count_of_users_to_send: number;
17
+ created_at: ISO8601Date;
18
+ failed: ICampaignChannelData | null;
19
+ planned: ICampaignChannelData | null;
20
+ run_at: ISO8601Date;
21
+ state: 'planned' | 'failed' | 'waitingStats' | 'completed';
22
+ success: ICampaignChannelData | null;
23
+ os: IUsersOperatingSystemsData | null;
24
+ }
25
+ export interface ICampaignCohort {
26
+ id: string;
27
+ count_of_users: number;
28
+ external_id: string;
29
+ last_updated: ISO8601Date;
30
+ name: string;
31
+ }
32
+ export declare type ICampaignSMSAttributes = {
33
+ msg: string;
34
+ };
35
+ export declare type ICampaignEmailAttributes = {
36
+ html: string;
37
+ subject: string;
38
+ text: string;
39
+ };
40
+ export declare type ICampaignPassPushAttributes = {
41
+ msg: string;
42
+ title: string;
43
+ };
44
+ export declare type ICampaignWebPushAttributes = {
45
+ msg: string;
46
+ title: string;
47
+ };
48
+ export declare type ICampaignAnyAttributes = ICampaignSMSAttributes | ICampaignEmailAttributes | ICampaignPassPushAttributes | ICampaignWebPushAttributes;
49
+ export interface ICampaignTemplate<R = ICampaignAnyAttributes> {
50
+ id: string;
51
+ channel: ICampaignChannel;
52
+ defaultVars: Record<string, string>;
53
+ event: 'campaign';
54
+ name: string;
55
+ requiredVar: string[];
56
+ template: R;
57
+ }
58
+ export interface ICampaignJSONAPIDTO {
59
+ id: string;
60
+ type: 'campaign';
61
+ attributes: {
62
+ created_at: number;
63
+ name: string;
64
+ };
65
+ relationships: Record<string, unknown>;
66
+ }
67
+ export interface CampaignByID {
68
+ id: string;
69
+ created_at: ISO8601Date;
70
+ name: string;
71
+ campaign_run: ICampaignRun[];
72
+ cohort: ICampaignCohort[];
73
+ template: ICampaignTemplate[];
74
+ }
@@ -0,0 +1,9 @@
1
+ import { IRequestWithCancelAndData } from '../IRequestWithCancelAndData';
2
+ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
3
+ import { CampaignByID } from './common';
4
+ export interface IGetCampaignById {
5
+ ({ campaignId }: {
6
+ campaignId: string;
7
+ }): IRequestWithCancelAndData<GetCampaignByIdResponseDTO, I_JSON_API_Response_Many>;
8
+ }
9
+ export declare type GetCampaignByIdResponseDTO = CampaignByID[];
@@ -0,0 +1,8 @@
1
+ import { ICampaignCohortDTO, ICampaignTemplateDTO } from './campaignInterfaces';
2
+ import { CampaignByID, ICampaignJSONAPIDTO } from './common';
3
+ import { IRequestWithCancelAndData } from '../IRequestWithCancelAndData';
4
+ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
5
+ export interface IGetMyCampaign {
6
+ (): IRequestWithCancelAndData<GetMyCampaignsResponseDTO, I_JSON_API_Response_Many<ICampaignJSONAPIDTO, ICampaignCohortDTO | ICampaignTemplateDTO>>;
7
+ }
8
+ export declare type GetMyCampaignsResponseDTO = CampaignByID[];
@@ -0,0 +1,4 @@
1
+ export * from './common';
2
+ export * from './getByID';
3
+ export * from './campaignInterfaces';
4
+ export * from './getMyCampaigns';
@@ -0,0 +1,7 @@
1
+ import { IGetCardBonusesResponseDTO } from '../issuer/IGetCardBonuses';
2
+ import { IRequestWithCancelAndData } from '../IRequestWithCancelAndData';
3
+ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
4
+ export declare type IGetBonusesResponseDTO = IGetCardBonusesResponseDTO;
5
+ export interface IGetBonuses {
6
+ (): IRequestWithCancelAndData<IGetBonusesResponseDTO, I_JSON_API_Response_Many>;
7
+ }
@@ -0,0 +1,128 @@
1
+ import { IHTTPClientResponse } from '@roketus/web-toolkit';
2
+ import { JsonApiRequestDTO } from './JsonApiRequestDTO';
3
+ export interface IAddPoints {
4
+ ({ cardNumber, description, amount }: {
5
+ cardNumber: string;
6
+ description: string;
7
+ amount: number;
8
+ }): Promise<IHTTPClientResponse<void>>;
9
+ }
10
+ export interface IAddReserve {
11
+ ({ amount }: {
12
+ amount: number;
13
+ }): Promise<IHTTPClientResponse<void>>;
14
+ }
15
+ export interface ICreateAnonymousUserCard {
16
+ (logoText?: string): Promise<{
17
+ cardNumber: string;
18
+ androidCardDownloadLink: string;
19
+ iosCardDownloadLink: string;
20
+ cardJwt: string;
21
+ }>;
22
+ }
23
+ export interface IGetAndroidCardDownloadLink {
24
+ (): Promise<string>;
25
+ }
26
+ export interface IDownloadIOSCard {
27
+ (): Promise<void>;
28
+ }
29
+ export interface IGetBalanceHistory {
30
+ (): Promise<IHTTPClientResponse<GetBalanceHistoryResponseDTO>>;
31
+ }
32
+ export interface IGetCardBalanceHistory {
33
+ ({ cardNumber }: {
34
+ cardNumber: string;
35
+ }): Promise<IHTTPClientResponse<GetBalanceHistoryResponseDTO>>;
36
+ }
37
+ export interface IGetReferral {
38
+ (): Promise<IHTTPClientResponse<GetReferralResponseDTO>>;
39
+ }
40
+ export interface IGetUserCard {
41
+ (): Promise<IHTTPClientResponse<GetUserCardResponseDTO>>;
42
+ }
43
+ export interface IRestoreCard {
44
+ (): Promise<unknown>;
45
+ }
46
+ export interface ISetTypeCard {
47
+ ({ cardNumber, type }: {
48
+ cardNumber: string;
49
+ type: string;
50
+ }): Promise<unknown>;
51
+ }
52
+ export interface ISpendPoints {
53
+ ({ cardNumber, description, amount }: {
54
+ cardNumber: string;
55
+ description: string;
56
+ amount: number;
57
+ }): Promise<IHTTPClientResponse<void>>;
58
+ }
59
+ export interface IUpdateCard {
60
+ ({ cardNumber, data }: {
61
+ cardNumber: string;
62
+ data: {
63
+ bonus?: string;
64
+ first_name?: string;
65
+ last_name?: string;
66
+ };
67
+ type?: string;
68
+ }): Promise<IHTTPClientResponse<void>>;
69
+ }
70
+ export interface IUpdateDiscountPercent {
71
+ ({ discountPercent, cardNumber }: {
72
+ cardNumber: string;
73
+ discountPercent: number;
74
+ }): Promise<unknown>;
75
+ }
76
+ export interface IDownloadAnonymousCard {
77
+ (issuer: string, referral_id?: string): Promise<unknown>;
78
+ }
79
+ export declare type DownloadAnonymousCardRequestDTO = JsonApiRequestDTO<{
80
+ issuer: string;
81
+ referral_id: string;
82
+ }>;
83
+ export interface GetBalanceHistoryResponseDTO {
84
+ data: [
85
+ {
86
+ id: string;
87
+ type: 'history';
88
+ attributes: {
89
+ Amount: number;
90
+ Balance: number;
91
+ CreatedAt: number;
92
+ Description: string;
93
+ };
94
+ relationships: Record<string, unknown>;
95
+ }
96
+ ];
97
+ included: [];
98
+ }
99
+ interface GetReferralResponseDTO {
100
+ data: [
101
+ {
102
+ id: string;
103
+ type: 'referral';
104
+ attributes: {
105
+ refId: string;
106
+ };
107
+ }
108
+ ];
109
+ included: [];
110
+ }
111
+ interface GetUserCardResponseDTO {
112
+ data: [
113
+ {
114
+ id: string;
115
+ type: 'card';
116
+ attributes: {
117
+ CardNumber: string;
118
+ CreatedAt: number;
119
+ BonusPercent: number;
120
+ Issuer: string;
121
+ Serial: string;
122
+ ValidTill: number;
123
+ };
124
+ }
125
+ ];
126
+ included: [];
127
+ }
128
+ export {};
@@ -0,0 +1,27 @@
1
+ import { IUser } from "../user/IUser";
2
+ export interface ICardCustomParam {
3
+ pass_key: string;
4
+ value: string;
5
+ label: string;
6
+ }
7
+ export interface ICard {
8
+ id: string;
9
+ issuer: string;
10
+ pass_id: number;
11
+ serial: string;
12
+ card_number: string;
13
+ card_type: string;
14
+ user: IUser;
15
+ custom_params: ICardCustomParam[];
16
+ user_state: string;
17
+ currency: string;
18
+ status: string;
19
+ level: string;
20
+ created_at: number;
21
+ valid_till: number;
22
+ template_id: number;
23
+ current_balance: number;
24
+ bonus_percent: number;
25
+ cumulative_result: {};
26
+ purchase_discount_percent: number;
27
+ }
@@ -0,0 +1,67 @@
1
+ import { IListFiltersPayload } from '../requestFilterInterfaces';
2
+ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
3
+ import { I_Deserialized_List_Response_DTO } from '../I_Deserialized_Response_DTO';
4
+ import { ICard, ICardCustomParam } from './ICard';
5
+ export interface ICardPayload {
6
+ first_name: string;
7
+ last_name: string;
8
+ phone: string;
9
+ email?: string;
10
+ expiration_date?: number;
11
+ custom_params?: ICardCustomParam[];
12
+ }
13
+ export interface CardRequestDTO {
14
+ data: {
15
+ attributes: ICardPayload;
16
+ };
17
+ }
18
+ export interface CardExpDateRequestDTO {
19
+ data: {
20
+ attributes: {
21
+ expiration_date: number | null;
22
+ };
23
+ };
24
+ }
25
+ export interface CardCustomParamsRequestDTO {
26
+ data: {
27
+ attributes: ICardCustomParam[];
28
+ };
29
+ }
30
+ export interface CardResponseDTO {
31
+ id: string;
32
+ type: string;
33
+ attributes: {
34
+ android_card_file_link: string;
35
+ card_number: string;
36
+ card_jwt: string;
37
+ created_at: number;
38
+ ios_card_file_link: string;
39
+ issuer: string;
40
+ };
41
+ }
42
+ export declare type CardJsonApiResponseDTO = I_JSON_API_Response_Many<CardResponseDTO>;
43
+ export interface ICreateCard {
44
+ (payload: ICardPayload): Promise<ICard>;
45
+ }
46
+ export interface UpdateCardResponseDTO {
47
+ data: 'ok';
48
+ }
49
+ export interface IUpdateCardExpirationDate {
50
+ (id: string, data: {
51
+ expiration_date: number | null;
52
+ }): Promise<void>;
53
+ }
54
+ export interface IUpdateCardCustomParams {
55
+ (id: string, data: ICardCustomParam[]): Promise<void>;
56
+ }
57
+ export interface IIssueCard {
58
+ (id: string): Promise<void>;
59
+ }
60
+ export interface IDeactivateCard {
61
+ (id: string): Promise<void>;
62
+ }
63
+ export interface IListCards {
64
+ (params: IListFiltersPayload): Promise<IListCardsResponse>;
65
+ }
66
+ export declare type ListCardsResponseDTO = I_JSON_API_Response_Many<CardResponseDTO>;
67
+ export declare type IListCardsResponse = I_Deserialized_List_Response_DTO<ICard>;
@@ -0,0 +1,5 @@
1
+ export declare enum CurrencyCode {
2
+ UAH = "UAH",
3
+ USD = "USD",
4
+ EUR = "EUR"
5
+ }
@@ -0,0 +1,6 @@
1
+ export declare enum NotificationChannel {
2
+ Email = "email",
3
+ Sms = "sms",
4
+ WebPush = "webPush",
5
+ PassPush = "passPush"
6
+ }
@@ -0,0 +1,2 @@
1
+ export * from './NotificationChannelEnum';
2
+ export * from './CurrencyCodeEnum';
@@ -0,0 +1,43 @@
1
+ import { I_JSON_API_Response_Single } from '../I_JSON_API_ResponseDTO';
2
+ import { EProductSearchType } from '../products/productSearchInterfaces';
3
+ export declare enum EExcludeType {
4
+ CASHBACK = "cashback",
5
+ BONUS_PAYMENT = "bonus_payment"
6
+ }
7
+ export interface IExcludePayload {
8
+ exclude_type: EExcludeType[];
9
+ exclude_param: EProductSearchType;
10
+ exclude_ids: string[];
11
+ description?: string;
12
+ }
13
+ export interface IExcludePayloadDTO {
14
+ data: {
15
+ attributes: IExcludePayload;
16
+ };
17
+ }
18
+ export interface IExcludeResponseAttributes {
19
+ creation_date: string;
20
+ description: string;
21
+ exclude_type: EExcludeType[];
22
+ param_type: EProductSearchType;
23
+ status: string;
24
+ }
25
+ export declare type TExcludeResponseDTO = I_JSON_API_Response_Single<IExcludeResponseAttributes>;
26
+ export interface IExcludeProduct {
27
+ id: string;
28
+ title: string;
29
+ }
30
+ export interface IExclude {
31
+ id: string;
32
+ creation_date: string;
33
+ description: string;
34
+ exclude_type: EExcludeType[];
35
+ param_type: EProductSearchType;
36
+ status: string;
37
+ group?: IExcludeProduct[];
38
+ product?: IExcludeProduct[];
39
+ }
40
+ export declare type TCreateExclude = (payload: IExcludePayload) => Promise<IExclude>;
41
+ export declare type TUpdateExclude = (id: string, payload: IExcludePayload) => Promise<IExclude>;
42
+ export declare type TGetExclude = (id: string) => Promise<IExclude>;
43
+ export declare type TDeleteExclude = (id: string) => Promise<void>;
@@ -0,0 +1,10 @@
1
+ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
2
+ import { IPaginationData } from '../requestFilterInterfaces';
3
+ import { IListFiltersPayload } from '../requestFilterInterfaces';
4
+ import { IExclude, IExcludeResponseAttributes } from './excludeInterfaces';
5
+ export declare type TListExcludesResponseDTO = I_JSON_API_Response_Many<IExcludeResponseAttributes>;
6
+ export interface IListExcludesResponse {
7
+ data: IExclude[];
8
+ meta: IPaginationData;
9
+ }
10
+ export declare type TListExcludes = (params: IListFiltersPayload) => Promise<IListExcludesResponse>;
@@ -0,0 +1,23 @@
1
+ import { IRequestWithCancelAndData } from '../IRequestWithCancelAndData';
2
+ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
3
+ export interface IGetCardBonuses {
4
+ (cardNumber: string): IRequestWithCancelAndData<IGetCardBonusesResponseDTO, I_JSON_API_Response_Many>;
5
+ }
6
+ export interface IGetCardBonus {
7
+ Date?: string;
8
+ Amount?: number;
9
+ }
10
+ export interface IGetCardBonusesResponseDTO {
11
+ activeWithDates: IGetCardBonus[];
12
+ inactiveWithDates: IGetCardBonus[];
13
+ totalActive: {
14
+ USD?: number;
15
+ UAH?: number;
16
+ EUR?: number;
17
+ };
18
+ totalInactive: {
19
+ USD?: number;
20
+ UAH?: number;
21
+ EUR?: number;
22
+ };
23
+ }
@@ -0,0 +1,15 @@
1
+ import { IRequestWithCancelAndData } from '../IRequestWithCancelAndData';
2
+ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
3
+ export interface IGetCardSpends {
4
+ (cardNumber: string): IRequestWithCancelAndData<IGetCardSpendsResponseDTO, IGetCardSpendsJSONAPIResponseDTO>;
5
+ }
6
+ export interface IGetCardSpendsAttributes {
7
+ id: string;
8
+ amount: string;
9
+ created: string;
10
+ currency: string;
11
+ description: string;
12
+ spendID: string;
13
+ }
14
+ export declare type IGetCardSpendsResponseDTO = IGetCardSpendsAttributes[];
15
+ export declare type IGetCardSpendsJSONAPIResponseDTO = I_JSON_API_Response_Many<IGetCardSpendsAttributes>;