@roketus/loyalty-js-sdk 5.4.0 → 5.4.2

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 (87) hide show
  1. package/README.dev.md +29 -0
  2. package/README.md +4 -6
  3. package/dist/cjs/api/issuer/getCardBonuses.d.ts +1 -4
  4. package/dist/cjs/index.js +1 -1
  5. package/dist/cjs/interfaces/IRequestWithCancelAndData.d.ts +1 -1
  6. package/dist/cjs/interfaces/analyticsInterfaces.d.ts +6 -6
  7. package/dist/cjs/interfaces/campaigns/ICampaignAction.d.ts +1 -1
  8. package/dist/cjs/interfaces/campaigns/campaignInterfaces.d.ts +3 -3
  9. package/dist/cjs/interfaces/campaigns/campaignPayloads.d.ts +4 -4
  10. package/dist/cjs/interfaces/card/IGetBonuses.d.ts +1 -1
  11. package/dist/cjs/interfaces/cardInterfaces.d.ts +1 -1
  12. package/dist/cjs/interfaces/cardManagement/cardManagementInterfaces.d.ts +3 -3
  13. package/dist/cjs/interfaces/cohorts/ICohort.d.ts +1 -1
  14. package/dist/cjs/interfaces/cohorts/cohortsInterfaces.d.ts +7 -7
  15. package/dist/cjs/interfaces/excludes/excludeInterfaces.d.ts +5 -5
  16. package/dist/cjs/interfaces/excludes/listExcludesInterfaces.d.ts +2 -2
  17. package/dist/cjs/interfaces/issuer/IGetCardSpends.d.ts +2 -2
  18. package/dist/cjs/interfaces/issuer/issuerInterface.d.ts +3 -3
  19. package/dist/cjs/interfaces/json.d.ts +2 -2
  20. package/dist/cjs/interfaces/order/orderInterfaces.d.ts +10 -10
  21. package/dist/cjs/interfaces/products/TGetGroupById.d.ts +2 -2
  22. package/dist/cjs/interfaces/products/TGetProductById.d.ts +2 -2
  23. package/dist/cjs/interfaces/products/categoryInterfaces.d.ts +1 -1
  24. package/dist/cjs/interfaces/products/listCategoriesInterfaces.d.ts +2 -2
  25. package/dist/cjs/interfaces/products/listProductsInterfaces.d.ts +2 -2
  26. package/dist/cjs/interfaces/products/productInterfaces.d.ts +1 -1
  27. package/dist/cjs/interfaces/promoCodes/promocodeInterfaces.d.ts +10 -10
  28. package/dist/cjs/interfaces/referralProgram/ICreateRefProgramPayload.d.ts +1 -1
  29. package/dist/cjs/interfaces/referralProgram/IReferralProgram.d.ts +1 -1
  30. package/dist/cjs/interfaces/referralProgram/influencerInterfaces.d.ts +4 -4
  31. package/dist/cjs/interfaces/referralProgram/referralProgramInterfaces.d.ts +4 -4
  32. package/dist/cjs/interfaces/rewardProgram/IProgramRule.d.ts +4 -4
  33. package/dist/cjs/interfaces/rewardProgram/programRulesInterfaces.d.ts +1 -1
  34. package/dist/cjs/interfaces/rewardProgram/rewardProgramInterfaces.d.ts +1 -1
  35. package/dist/cjs/interfaces/rewardProgram/tierInterfaces.d.ts +1 -1
  36. package/dist/cjs/interfaces/shortLinkActionInterface.d.ts +12 -12
  37. package/dist/cjs/interfaces/shortLinkInterface.d.ts +1 -1
  38. package/dist/cjs/interfaces/tiers/IGetTiersByCard.d.ts +1 -1
  39. package/dist/cjs/interfaces/transactions/IGetTransactionsByCard.d.ts +1 -1
  40. package/dist/cjs/interfaces/urlInterfaces.d.ts +1 -1
  41. package/dist/cjs/interfaces/user/IUser.d.ts +1 -0
  42. package/dist/cjs/interfaces/user/IUserCreate.d.ts +1 -1
  43. package/dist/cjs/interfaces/user/userNotificationsInterfaces.d.ts +1 -1
  44. package/dist/cjs/utils/toFilterQueryParams.d.ts +2 -2
  45. package/dist/esm5/api/issuer/getCardBonuses.d.ts +1 -4
  46. package/dist/esm5/index.js +1 -1
  47. package/dist/esm5/interfaces/IRequestWithCancelAndData.d.ts +1 -1
  48. package/dist/esm5/interfaces/analyticsInterfaces.d.ts +6 -6
  49. package/dist/esm5/interfaces/campaigns/ICampaignAction.d.ts +1 -1
  50. package/dist/esm5/interfaces/campaigns/campaignInterfaces.d.ts +3 -3
  51. package/dist/esm5/interfaces/campaigns/campaignPayloads.d.ts +4 -4
  52. package/dist/esm5/interfaces/card/IGetBonuses.d.ts +1 -1
  53. package/dist/esm5/interfaces/cardInterfaces.d.ts +1 -1
  54. package/dist/esm5/interfaces/cardManagement/cardManagementInterfaces.d.ts +3 -3
  55. package/dist/esm5/interfaces/cohorts/ICohort.d.ts +1 -1
  56. package/dist/esm5/interfaces/cohorts/cohortsInterfaces.d.ts +7 -7
  57. package/dist/esm5/interfaces/excludes/excludeInterfaces.d.ts +5 -5
  58. package/dist/esm5/interfaces/excludes/listExcludesInterfaces.d.ts +2 -2
  59. package/dist/esm5/interfaces/issuer/IGetCardSpends.d.ts +2 -2
  60. package/dist/esm5/interfaces/issuer/issuerInterface.d.ts +3 -3
  61. package/dist/esm5/interfaces/json.d.ts +2 -2
  62. package/dist/esm5/interfaces/order/orderInterfaces.d.ts +10 -10
  63. package/dist/esm5/interfaces/products/TGetGroupById.d.ts +2 -2
  64. package/dist/esm5/interfaces/products/TGetProductById.d.ts +2 -2
  65. package/dist/esm5/interfaces/products/categoryInterfaces.d.ts +1 -1
  66. package/dist/esm5/interfaces/products/listCategoriesInterfaces.d.ts +2 -2
  67. package/dist/esm5/interfaces/products/listProductsInterfaces.d.ts +2 -2
  68. package/dist/esm5/interfaces/products/productInterfaces.d.ts +1 -1
  69. package/dist/esm5/interfaces/promoCodes/promocodeInterfaces.d.ts +10 -10
  70. package/dist/esm5/interfaces/referralProgram/ICreateRefProgramPayload.d.ts +1 -1
  71. package/dist/esm5/interfaces/referralProgram/IReferralProgram.d.ts +1 -1
  72. package/dist/esm5/interfaces/referralProgram/influencerInterfaces.d.ts +4 -4
  73. package/dist/esm5/interfaces/referralProgram/referralProgramInterfaces.d.ts +4 -4
  74. package/dist/esm5/interfaces/rewardProgram/IProgramRule.d.ts +4 -4
  75. package/dist/esm5/interfaces/rewardProgram/programRulesInterfaces.d.ts +1 -1
  76. package/dist/esm5/interfaces/rewardProgram/rewardProgramInterfaces.d.ts +1 -1
  77. package/dist/esm5/interfaces/rewardProgram/tierInterfaces.d.ts +1 -1
  78. package/dist/esm5/interfaces/shortLinkActionInterface.d.ts +12 -12
  79. package/dist/esm5/interfaces/shortLinkInterface.d.ts +1 -1
  80. package/dist/esm5/interfaces/tiers/IGetTiersByCard.d.ts +1 -1
  81. package/dist/esm5/interfaces/transactions/IGetTransactionsByCard.d.ts +1 -1
  82. package/dist/esm5/interfaces/urlInterfaces.d.ts +1 -1
  83. package/dist/esm5/interfaces/user/IUser.d.ts +1 -0
  84. package/dist/esm5/interfaces/user/IUserCreate.d.ts +1 -1
  85. package/dist/esm5/interfaces/user/userNotificationsInterfaces.d.ts +1 -1
  86. package/dist/esm5/utils/toFilterQueryParams.d.ts +2 -2
  87. package/package.json +5 -4
@@ -3,24 +3,24 @@ import { IListFiltersPayload, IPaginationData } from '../requestFilterInterfaces
3
3
  import { ICohort } from './ICohort';
4
4
  import { ICreateCohortPayload } from './ICreateCohortPayload';
5
5
  import { IUpdateCohortPayload } from './IUpdateCohortPayload';
6
- export declare type TCohortResponseDTO = I_JSON_API_Response_Many<ICohort>;
6
+ export type TCohortResponseDTO = I_JSON_API_Response_Many<ICohort>;
7
7
  export interface IListCohortsResponse {
8
8
  data: ICohort[];
9
9
  meta: IPaginationData;
10
10
  }
11
- export declare type TListCohorts = (params: IListFiltersPayload) => Promise<IListCohortsResponse>;
12
- export declare type TGetCohortById = (id: string) => Promise<ICohort>;
13
- export declare type TUseCohort = (id: string) => Promise<void>;
11
+ export type TListCohorts = (params: IListFiltersPayload) => Promise<IListCohortsResponse>;
12
+ export type TGetCohortById = (id: string) => Promise<ICohort>;
13
+ export type TUseCohort = (id: string) => Promise<void>;
14
14
  export interface ICreateCohortRequestDTO {
15
15
  data: {
16
16
  attributes: ICreateCohortPayload;
17
17
  };
18
18
  }
19
- export declare type TCreateCohort = (payload: ICreateCohortPayload) => Promise<ICohort>;
19
+ export type TCreateCohort = (payload: ICreateCohortPayload) => Promise<ICohort>;
20
20
  export interface IUpdateCohortRequestDTO {
21
21
  data: {
22
22
  attributes: IUpdateCohortPayload;
23
23
  };
24
24
  }
25
- export declare type TUpdateCohort = (id: string, payload: IUpdateCohortPayload) => Promise<void>;
26
- export declare type TDeleteCohort = (id: string) => Promise<void>;
25
+ export type TUpdateCohort = (id: string, payload: IUpdateCohortPayload) => Promise<void>;
26
+ export type TDeleteCohort = (id: string) => Promise<void>;
@@ -22,7 +22,7 @@ export interface IExcludeResponseAttributes {
22
22
  param_type: EProductSearchType;
23
23
  status: string;
24
24
  }
25
- export declare type TExcludeResponseDTO = I_JSON_API_Response_Single<IExcludeResponseAttributes>;
25
+ export type TExcludeResponseDTO = I_JSON_API_Response_Single<IExcludeResponseAttributes>;
26
26
  export interface IExcludeProduct {
27
27
  id: string;
28
28
  title: string;
@@ -37,7 +37,7 @@ export interface IExclude {
37
37
  group?: IExcludeProduct[];
38
38
  product?: IExcludeProduct[];
39
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>;
40
+ export type TCreateExclude = (payload: IExcludePayload) => Promise<IExclude>;
41
+ export type TUpdateExclude = (id: string, payload: IExcludePayload) => Promise<IExclude>;
42
+ export type TGetExclude = (id: string) => Promise<IExclude>;
43
+ export type TDeleteExclude = (id: string) => Promise<void>;
@@ -2,9 +2,9 @@ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
2
2
  import { IPaginationData } from '../requestFilterInterfaces';
3
3
  import { IListFiltersPayload } from '../requestFilterInterfaces';
4
4
  import { IExclude, IExcludeResponseAttributes } from './excludeInterfaces';
5
- export declare type TListExcludesResponseDTO = I_JSON_API_Response_Many<IExcludeResponseAttributes>;
5
+ export type TListExcludesResponseDTO = I_JSON_API_Response_Many<IExcludeResponseAttributes>;
6
6
  export interface IListExcludesResponse {
7
7
  data: IExclude[];
8
8
  meta: IPaginationData;
9
9
  }
10
- export declare type TListExcludes = (params: IListFiltersPayload) => Promise<IListExcludesResponse>;
10
+ export type TListExcludes = (params: IListFiltersPayload) => Promise<IListExcludesResponse>;
@@ -11,5 +11,5 @@ export interface IGetCardSpendsAttributes {
11
11
  description: string;
12
12
  spendID: string;
13
13
  }
14
- export declare type IGetCardSpendsResponseDTO = IGetCardSpendsAttributes[];
15
- export declare type IGetCardSpendsJSONAPIResponseDTO = I_JSON_API_Response_Many<IGetCardSpendsAttributes>;
14
+ export type IGetCardSpendsResponseDTO = IGetCardSpendsAttributes[];
15
+ export type IGetCardSpendsJSONAPIResponseDTO = I_JSON_API_Response_Many<IGetCardSpendsAttributes>;
@@ -53,18 +53,18 @@ export interface ISetCardName {
53
53
  export interface IGetSettings {
54
54
  (): Promise<IIssuerSettings>;
55
55
  }
56
- export declare type TSettingsResponseDTO = I_JSON_API_Response_Many<IIssuerSettings>;
56
+ export type TSettingsResponseDTO = I_JSON_API_Response_Many<IIssuerSettings>;
57
57
  export interface ISetSettings {
58
58
  (payload: ISetIssuerSettingsPayload): Promise<IIssuerSettings>;
59
59
  }
60
60
  export interface ISetIssuerToken {
61
61
  (token: string): void;
62
62
  }
63
- export declare type IGetCardByPhoneResponseDTO = IGetCardByIdResponseDTO;
63
+ export type IGetCardByPhoneResponseDTO = IGetCardByIdResponseDTO;
64
64
  export interface IGetCardByPhone {
65
65
  (phoneNumber: string): IRequestWithCancelAndData<IGetCardByPhoneResponseDTO, I_JSON_API_Response_Many>;
66
66
  }
67
- export declare type GatewayType = 'sms' | 'email' | 'iosPush' | 'androidPush' | 'passPush' | 'webPush';
67
+ export type GatewayType = 'sms' | 'email' | 'iosPush' | 'androidPush' | 'passPush' | 'webPush';
68
68
  interface CreateIssuerResponseDTO {
69
69
  data: [
70
70
  {
@@ -1,5 +1,5 @@
1
- export declare type JSONValue = string | number | boolean | JSONObject | JSONArray;
1
+ export type JSONValue = string | number | boolean | JSONObject | JSONArray;
2
2
  export interface JSONObject {
3
3
  [x: string]: JSONValue;
4
4
  }
5
- export declare type JSONArray = Array<JSONValue>;
5
+ export type JSONArray = Array<JSONValue>;
@@ -48,25 +48,25 @@ export interface IOrder extends IOrderAttributes {
48
48
  receipt?: IOrderReceipt;
49
49
  consumer?: IOrderConsumer;
50
50
  }
51
- declare type ConsumerCredentialType = 'consumer_id' | 'card_number' | 'phone';
52
- export declare type TCouponDiscountPayload = {
51
+ type ConsumerCredentialType = 'consumer_id' | 'card_number' | 'phone';
52
+ export type TCouponDiscountPayload = {
53
53
  type: EOrderDiscountType.COUPON;
54
54
  code: string;
55
55
  };
56
- export declare type TPromoDiscountPayload = {
56
+ export type TPromoDiscountPayload = {
57
57
  type: EOrderDiscountType.USER_PROMO_CODE | EOrderDiscountType.PROMO_CODE;
58
58
  code: string;
59
59
  };
60
- export declare type TBonusDiscountPayload = {
60
+ export type TBonusDiscountPayload = {
61
61
  type: EOrderDiscountType.BONUS;
62
62
  amount: number;
63
63
  apply_method: 'proportionalToItems' | 'toTotalPrice';
64
64
  };
65
- export declare type TPercentageDiscountPayload = {
65
+ export type TPercentageDiscountPayload = {
66
66
  type: EOrderDiscountType.PERCENTAGE;
67
67
  percent: number;
68
68
  };
69
- export declare type TOrderDiscountPayload = TCouponDiscountPayload | TPromoDiscountPayload | TBonusDiscountPayload | TPercentageDiscountPayload;
69
+ export type TOrderDiscountPayload = TCouponDiscountPayload | TPromoDiscountPayload | TBonusDiscountPayload | TPercentageDiscountPayload;
70
70
  export interface IOrderProductPayload {
71
71
  product_id: string;
72
72
  receipt_name: string;
@@ -75,7 +75,7 @@ export interface IOrderProductPayload {
75
75
  unit_of_measure: string;
76
76
  ean_code: string;
77
77
  }
78
- export declare type TOrderConsumerPayload = {
78
+ export type TOrderConsumerPayload = {
79
79
  credential: ConsumerCredentialType;
80
80
  value: string;
81
81
  } | {};
@@ -95,7 +95,7 @@ export interface IOpenOrderPayloadDTO {
95
95
  attributes: IOpenOrderPayload;
96
96
  };
97
97
  }
98
- export declare type TOrderResponseDTO = I_JSON_API_Response_Many<IOrderAttributes>;
99
- export declare type TOpenOrder = (payload: IOpenOrderPayload) => Promise<IOrder>;
100
- export declare type TCloseOrder = (id: string) => Promise<IOrder>;
98
+ export type TOrderResponseDTO = I_JSON_API_Response_Many<IOrderAttributes>;
99
+ export type TOpenOrder = (payload: IOpenOrderPayload) => Promise<IOrder>;
100
+ export type TCloseOrder = (id: string) => Promise<IOrder>;
101
101
  export {};
@@ -1,4 +1,4 @@
1
1
  import { I_JSON_API_Response_Single } from '../I_JSON_API_ResponseDTO';
2
2
  import { ICategory } from './categoryInterfaces';
3
- export declare type TGetCategoryByIdResponseDTO = I_JSON_API_Response_Single<ICategory>;
4
- export declare type TGetCategoryById = (id: string) => Promise<ICategory>;
3
+ export type TGetCategoryByIdResponseDTO = I_JSON_API_Response_Single<ICategory>;
4
+ export type TGetCategoryById = (id: string) => Promise<ICategory>;
@@ -1,4 +1,4 @@
1
1
  import { I_JSON_API_Response_Single } from '../I_JSON_API_ResponseDTO';
2
2
  import { IProduct } from './productInterfaces';
3
- export declare type TGetProductByIdResponseDTO = I_JSON_API_Response_Single<IProduct>;
4
- export declare type TGetProductById = (id: string) => Promise<IProduct>;
3
+ export type TGetProductByIdResponseDTO = I_JSON_API_Response_Single<IProduct>;
4
+ export type TGetProductById = (id: string) => Promise<IProduct>;
@@ -3,7 +3,7 @@ export interface ICategoryResponseAttributes {
3
3
  description: string;
4
4
  title: string;
5
5
  }
6
- export declare type TCategoryResponseDTO = I_JSON_API_Response_Single<ICategoryResponseAttributes>;
6
+ export type TCategoryResponseDTO = I_JSON_API_Response_Single<ICategoryResponseAttributes>;
7
7
  export interface ICategory {
8
8
  id: string;
9
9
  description: string;
@@ -1,12 +1,12 @@
1
1
  import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
2
2
  import { IPaginationData } from '../requestFilterInterfaces';
3
3
  import { ICategory, ICategoryResponseAttributes } from './categoryInterfaces';
4
- export declare type TListCategoriesResponseDTO = I_JSON_API_Response_Many<ICategoryResponseAttributes>;
4
+ export type TListCategoriesResponseDTO = I_JSON_API_Response_Many<ICategoryResponseAttributes>;
5
5
  export interface IListCategoriesResponse {
6
6
  data: ICategory[];
7
7
  meta: IPaginationData;
8
8
  }
9
- export declare type TListCategories = ({ page, pageSize, search, }: {
9
+ export type TListCategories = ({ page, pageSize, search, }: {
10
10
  page?: number;
11
11
  pageSize?: number;
12
12
  search?: string;
@@ -1,12 +1,12 @@
1
1
  import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
2
2
  import { IPaginationData } from '../requestFilterInterfaces';
3
3
  import { IProduct, IProductResponseAttributes } from './productInterfaces';
4
- export declare type TListProductsResponseDTO = I_JSON_API_Response_Many<IProductResponseAttributes>;
4
+ export type TListProductsResponseDTO = I_JSON_API_Response_Many<IProductResponseAttributes>;
5
5
  export interface IListProductsResponse {
6
6
  data: IProduct[];
7
7
  meta: IPaginationData;
8
8
  }
9
- export declare type TListProducts = ({ page, pageSize, search, }: {
9
+ export type TListProducts = ({ page, pageSize, search, }: {
10
10
  page?: number;
11
11
  pageSize?: number;
12
12
  search?: string;
@@ -15,7 +15,7 @@ export interface IProductResponseAttributes {
15
15
  unit_of_measure: string;
16
16
  vendor_code: string;
17
17
  }
18
- export declare type TProductResponseDTO = I_JSON_API_Response_Single<IProductResponseAttributes>;
18
+ export type TProductResponseDTO = I_JSON_API_Response_Single<IProductResponseAttributes>;
19
19
  export interface IProductBrand {
20
20
  id: string;
21
21
  name: string;
@@ -3,27 +3,27 @@ import { IListFiltersPayload, IPaginationData } from '../requestFilterInterfaces
3
3
  import { IPromocode } from './IPromocode';
4
4
  import { ICreatePromocodePayload } from './ICreatePromocodePayload';
5
5
  import { IUpdatePromocodePayload } from './IUpdatePromocodePayload';
6
- export declare type TPromocodeResponseDTO = I_JSON_API_Response_Many<IPromocode>;
6
+ export type TPromocodeResponseDTO = I_JSON_API_Response_Many<IPromocode>;
7
7
  export interface IListPromocodesResponse {
8
8
  data: IPromocode[];
9
9
  meta: IPaginationData;
10
10
  }
11
- export declare type TListPromocodes = (params: IListFiltersPayload) => Promise<IListPromocodesResponse>;
12
- export declare type TGetPromocodeById = (id: string) => Promise<IPromocode>;
13
- export declare type TUsePromocode = (id: string) => Promise<void>;
11
+ export type TListPromocodes = (params: IListFiltersPayload) => Promise<IListPromocodesResponse>;
12
+ export type TGetPromocodeById = (id: string) => Promise<IPromocode>;
13
+ export type TUsePromocode = (id: string) => Promise<void>;
14
14
  export interface ICreatePromocodeRequestDTO {
15
15
  data: {
16
16
  attributes: ICreatePromocodePayload;
17
17
  };
18
18
  }
19
- export declare type TCreatePromocode = (payload: ICreatePromocodePayload) => Promise<IPromocode>;
19
+ export type TCreatePromocode = (payload: ICreatePromocodePayload) => Promise<IPromocode>;
20
20
  export interface IUpdatePromocodeRequestDTO {
21
21
  data: {
22
22
  attributes: IUpdatePromocodePayload;
23
23
  };
24
24
  }
25
- export declare type TUpdatePromocode = (id: string, payload: IUpdatePromocodePayload) => Promise<void>;
26
- export declare type TEnablePromocode = (id: string) => Promise<void>;
27
- export declare type TDisablePromocode = (id: string) => Promise<void>;
28
- export declare type TArchivePromocode = (id: string) => Promise<void>;
29
- export declare type TUnarchivePromocode = (id: string) => Promise<void>;
25
+ export type TUpdatePromocode = (id: string, payload: IUpdatePromocodePayload) => Promise<void>;
26
+ export type TEnablePromocode = (id: string) => Promise<void>;
27
+ export type TDisablePromocode = (id: string) => Promise<void>;
28
+ export type TArchivePromocode = (id: string) => Promise<void>;
29
+ export type TUnarchivePromocode = (id: string) => Promise<void>;
@@ -7,7 +7,7 @@ export interface IRefProgramCouponRewardPayload {
7
7
  type: ERefProgramRewardType.COUPON;
8
8
  promo_code_id: string;
9
9
  }
10
- export declare type IRefProgramRewardPayload = IRefProgramBonusRewardPayload | IRefProgramCouponRewardPayload;
10
+ export type IRefProgramRewardPayload = IRefProgramBonusRewardPayload | IRefProgramCouponRewardPayload;
11
11
  export interface ICreateRefProgramPayload {
12
12
  name: string;
13
13
  description: string;
@@ -30,7 +30,7 @@ export interface IRefProgramCouponReward {
30
30
  } | null;
31
31
  value: number;
32
32
  }
33
- export declare type IRefProgramReward = IRefProgramBonusReward | IRefProgramCouponReward;
33
+ export type IRefProgramReward = IRefProgramBonusReward | IRefProgramCouponReward;
34
34
  export interface IReferralProgram {
35
35
  id: string;
36
36
  name: string;
@@ -3,7 +3,7 @@ import { I_JSON_API_Response_Many, I_JSON_API_Response_Single } from '../I_JSON_
3
3
  import { I_Deserialized_List_Response_DTO } from '../I_Deserialized_Response_DTO';
4
4
  import { IInfluencer, IInfluencerPerfomance } from './IInfluencer';
5
5
  import { ICreateInfluencerPayload, IUpdateInfluencerPayload, IUpdateInfluencerRewardPayload } from './IInfluencerPayload';
6
- export declare type InfluencerResponseDTO = I_JSON_API_Response_Single<IInfluencer>;
6
+ export type InfluencerResponseDTO = I_JSON_API_Response_Single<IInfluencer>;
7
7
  export interface IAddInfluencer {
8
8
  (programId: string, payload: ICreateInfluencerPayload): Promise<IInfluencer>;
9
9
  }
@@ -19,15 +19,15 @@ export interface IUpdateInfluencerReward {
19
19
  export interface IDeleteInfluencer {
20
20
  (programId: string, influencerId: string): Promise<void>;
21
21
  }
22
- export declare type ListInfluencersResponseDTO = I_JSON_API_Response_Many<IInfluencer>;
23
- export declare type IListInfluencersResponse = I_Deserialized_List_Response_DTO<IInfluencer>;
22
+ export type ListInfluencersResponseDTO = I_JSON_API_Response_Many<IInfluencer>;
23
+ export type IListInfluencersResponse = I_Deserialized_List_Response_DTO<IInfluencer>;
24
24
  export interface IListInfluencers {
25
25
  (programId: string, params: IListFiltersPayload): Promise<IListInfluencersResponse>;
26
26
  }
27
27
  export interface IGetInfluencer {
28
28
  (programId: string, influencerId: string): Promise<IInfluencer>;
29
29
  }
30
- export declare type IGetInfluencerPerfomanceResponseDTO = I_JSON_API_Response_Many<IInfluencerPerfomance>;
30
+ export type IGetInfluencerPerfomanceResponseDTO = I_JSON_API_Response_Many<IInfluencerPerfomance>;
31
31
  export interface IGetInfluencerPerfomance {
32
32
  (programId: string, influencerId: string): Promise<IInfluencerPerfomance>;
33
33
  }
@@ -10,7 +10,7 @@ export interface CreateRefProgramRequestDTO {
10
10
  attributes: ICreateRefProgramPayload;
11
11
  };
12
12
  }
13
- export declare type ReferralProgramResponseDTO = I_JSON_API_Response_Many<IReferralProgram>;
13
+ export type ReferralProgramResponseDTO = I_JSON_API_Response_Many<IReferralProgram>;
14
14
  export interface ICreateReferralProgram {
15
15
  (payload: ICreateRefProgramPayload): Promise<IReferralProgram>;
16
16
  }
@@ -37,12 +37,12 @@ export interface IArchiveReferralProgram {
37
37
  export interface IListReferralPrograms {
38
38
  (params: IListFiltersPayload): Promise<IListReferralProgramsResponse>;
39
39
  }
40
- export declare type ListReferralProgramsResponseDTO = I_JSON_API_Response_Many<ReferralProgramResponseDTO>;
41
- export declare type IListReferralProgramsResponse = I_Deserialized_List_Response_DTO<IReferralProgram>;
40
+ export type ListReferralProgramsResponseDTO = I_JSON_API_Response_Many<ReferralProgramResponseDTO>;
41
+ export type IListReferralProgramsResponse = I_Deserialized_List_Response_DTO<IReferralProgram>;
42
42
  export interface IGetReferralProgram {
43
43
  (id: string): Promise<IReferralProgram>;
44
44
  }
45
- export declare type RefProgramAnalyticsResponseDTO = I_JSON_API_Response_Many<IReferralProgramAnalytics>;
45
+ export type RefProgramAnalyticsResponseDTO = I_JSON_API_Response_Many<IReferralProgramAnalytics>;
46
46
  export interface IGetRefProgramAnalytics {
47
47
  (id: string): Promise<IReferralProgramAnalytics>;
48
48
  }
@@ -1,6 +1,6 @@
1
- export declare type TProgramRuleTriggerEventType = 'custom_event' | 'inner_event' | string;
2
- export declare type TProgramRuleTriggerEventName = 'coupon_to_card' | 'order_closed' | 'referral_registered' | 'spent_bonus' | 'remove_bonus' | 'refund_transaction' | 'order_closed_issue_coupon' | string;
3
- export declare type TProgramRuleOutcomeEventType = 'add_transaction' | 'update_card' | 'add_points' | 'add_gift_bonuses' | 'spent_bonus' | 'remove_points' | 'send_notification' | 'refund_transaction' | 'order_closed_issue_coupon' | string;
1
+ export type TProgramRuleTriggerEventType = 'custom_event' | 'inner_event' | string;
2
+ export type TProgramRuleTriggerEventName = 'coupon_to_card' | 'order_closed' | 'referral_registered' | 'spent_bonus' | 'remove_bonus' | 'refund_transaction' | 'order_closed_issue_coupon' | string;
3
+ export type TProgramRuleOutcomeEventType = 'add_transaction' | 'update_card' | 'add_points' | 'add_gift_bonuses' | 'spent_bonus' | 'remove_points' | 'send_notification' | 'refund_transaction' | 'order_closed_issue_coupon' | string;
4
4
  export interface IProgramRulePayloadUserAction {
5
5
  Parameter: string;
6
6
  Value: string;
@@ -18,7 +18,7 @@ export interface IProgramRulePayloadGiftBonuses {
18
18
  description: string;
19
19
  Metadata?: unknown | null;
20
20
  }
21
- export declare type IProgramRuleDefaultPayload = IProgramRulePayloadUserAction | IProgramRulePayloadPoints | IProgramRulePayloadGiftBonuses | IProgramRulePayloadNotification | {
21
+ export type IProgramRuleDefaultPayload = IProgramRulePayloadUserAction | IProgramRulePayloadPoints | IProgramRulePayloadGiftBonuses | IProgramRulePayloadNotification | {
22
22
  [key: string]: any;
23
23
  };
24
24
  export interface IProgramRuleOutcome {
@@ -18,7 +18,7 @@ export interface AddProgramRuleRequestDTO {
18
18
  attributes: IAddProgramRulePayload;
19
19
  };
20
20
  }
21
- export declare type ProgramRuleResponseDTO = I_JSON_API_Response_Many<IProgramRule>;
21
+ export type ProgramRuleResponseDTO = I_JSON_API_Response_Many<IProgramRule>;
22
22
  export interface IAddProgramRule {
23
23
  (programId: string, payload: IAddProgramRulePayload): Promise<AxiosResponse<void>>;
24
24
  }
@@ -10,7 +10,7 @@ export interface CreateRewardProgramRequestDTO {
10
10
  attributes: ICreateRewardProgramPayload;
11
11
  };
12
12
  }
13
- export declare type RewardProgramResponseDTO = I_JSON_API_Response_Many<IRewardProgram>;
13
+ export type RewardProgramResponseDTO = I_JSON_API_Response_Many<IRewardProgram>;
14
14
  export interface ICreateRewardProgram {
15
15
  (payload: ICreateRewardProgramPayload): Promise<IRewardProgram>;
16
16
  }
@@ -26,7 +26,7 @@ export interface CreateTierRequestDTO {
26
26
  attributes: ICreateTierPayload;
27
27
  };
28
28
  }
29
- export declare type TierResponseDTO = I_JSON_API_Response_Many<ITier>;
29
+ export type TierResponseDTO = I_JSON_API_Response_Many<ITier>;
30
30
  export interface ICreateTier {
31
31
  (payload: ICreateTierPayload): Promise<ITier>;
32
32
  }
@@ -1,7 +1,7 @@
1
1
  import { IHTTPClientResponse } from '@roketus/web-toolkit';
2
2
  import { NotificationChannel } from './common/NotificationChannelEnum';
3
3
  import { CurrencyCode } from './common/CurrencyCodeEnum';
4
- export declare type TLinkActionType = 'add_gift_bonuses' | 'card' | 'send_notification' | 'coupon' | 'add_promo_to_user' | 'change_template';
4
+ export type TLinkActionType = 'add_gift_bonuses' | 'card' | 'send_notification' | 'coupon' | 'add_promo_to_user' | 'change_template';
5
5
  interface IBonusPayload {
6
6
  currency_code: CurrencyCode;
7
7
  amount: number;
@@ -21,7 +21,7 @@ interface IAddUserPromoPayload {
21
21
  interface IChangeTemplatePayload {
22
22
  template_id: string;
23
23
  }
24
- declare type NotificationEmailRequest = {
24
+ type NotificationEmailRequest = {
25
25
  template: {
26
26
  subject: string;
27
27
  html?: string;
@@ -29,20 +29,20 @@ declare type NotificationEmailRequest = {
29
29
  };
30
30
  channel: NotificationChannel.Email;
31
31
  };
32
- declare type NotificationSmsRequest = {
32
+ type NotificationSmsRequest = {
33
33
  template: {
34
34
  msg: string;
35
35
  };
36
36
  channel: NotificationChannel.Sms;
37
37
  };
38
- declare type NotificationWepPassPushRequest = {
38
+ type NotificationWepPassPushRequest = {
39
39
  template: {
40
40
  msg: string;
41
41
  title: string;
42
42
  };
43
43
  channel: NotificationChannel.WebPush | NotificationChannel.PassPush;
44
44
  };
45
- declare type INotificationPayload = NotificationEmailRequest | NotificationSmsRequest | NotificationWepPassPushRequest;
45
+ type INotificationPayload = NotificationEmailRequest | NotificationSmsRequest | NotificationWepPassPushRequest;
46
46
  interface ILinkActionPayload<T> {
47
47
  type: TLinkActionType;
48
48
  payload: T;
@@ -68,7 +68,7 @@ interface ILinkActionPayloadAddUserPromoResponse {
68
68
  interface ILinkActionPayloadChangeTemplateResponse {
69
69
  TemplateID: string;
70
70
  }
71
- declare type NotificationEmailResponse = {
71
+ type NotificationEmailResponse = {
72
72
  Template: {
73
73
  subject: string;
74
74
  html?: string;
@@ -76,21 +76,21 @@ declare type NotificationEmailResponse = {
76
76
  };
77
77
  Channel: NotificationChannel.Email;
78
78
  };
79
- declare type NotificationSmsResponse = {
79
+ type NotificationSmsResponse = {
80
80
  Template: {
81
81
  msg: string;
82
82
  };
83
83
  Channel: NotificationChannel.Sms;
84
84
  };
85
- declare type NotificationWepPassPushResponse = {
85
+ type NotificationWepPassPushResponse = {
86
86
  Template: {
87
87
  msg: string;
88
88
  title: string;
89
89
  };
90
90
  Channel: NotificationChannel.WebPush | NotificationChannel.PassPush;
91
91
  };
92
- declare type TLinkActionPayloadNotificationResponse = NotificationEmailResponse | NotificationSmsResponse | NotificationWepPassPushResponse;
93
- export declare type TLinkActionPayloadResponse = ILinkActionPayloadBonusResponse | ILinkActionPayloadCardResponse | TLinkActionPayloadNotificationResponse[] | ILinkActionPayloadCouponWithPromoResponse | ILinkActionPayloadAddUserPromoResponse | ILinkActionPayloadChangeTemplateResponse;
92
+ type TLinkActionPayloadNotificationResponse = NotificationEmailResponse | NotificationSmsResponse | NotificationWepPassPushResponse;
93
+ export type TLinkActionPayloadResponse = ILinkActionPayloadBonusResponse | ILinkActionPayloadCardResponse | TLinkActionPayloadNotificationResponse[] | ILinkActionPayloadCouponWithPromoResponse | ILinkActionPayloadAddUserPromoResponse | ILinkActionPayloadChangeTemplateResponse;
94
94
  interface ILinkActionResponse {
95
95
  data: {
96
96
  id: string;
@@ -127,8 +127,8 @@ interface ILinkActionResponse {
127
127
  }
128
128
  ];
129
129
  }
130
- export declare type LinkActionResponseDTO = IHTTPClientResponse<ILinkActionResponse>;
131
- export declare type TLinkActionPayload = ILinkActionPayload<IBonusPayload | ICardPayload | ICouponWithPromoPayload | IAddUserPromoPayload | IChangeTemplatePayload | INotificationPayload[]>;
130
+ export type LinkActionResponseDTO = IHTTPClientResponse<ILinkActionResponse>;
131
+ export type TLinkActionPayload = ILinkActionPayload<IBonusPayload | ICardPayload | ICouponWithPromoPayload | IAddUserPromoPayload | IChangeTemplatePayload | INotificationPayload[]>;
132
132
  export interface LinkActionRequestDTO {
133
133
  data: {
134
134
  attributes: TLinkActionPayload;
@@ -45,7 +45,7 @@ export interface IShortLink {
45
45
  meta: Record<string, string>;
46
46
  action?: IShortLinkAction[];
47
47
  }
48
- export declare type LinkResponseDTO = I_JSON_API_Response_Many<IShortLinkResponseDTO, IShortLinkActionResponseDTO>;
48
+ export type LinkResponseDTO = I_JSON_API_Response_Many<IShortLinkResponseDTO, IShortLinkActionResponseDTO>;
49
49
  export interface ICreateLink {
50
50
  (payload: ICreateLinkPayload): Promise<IShortLink>;
51
51
  }
@@ -3,7 +3,7 @@ import { I_JSON_API_Response_Many } from '../I_JSON_API_ResponseDTO';
3
3
  export interface IGetTiersByCard {
4
4
  (cardNumber: string): IRequestWithCancelAndData<IGetTiersByCardResponseDTO, I_JSON_API_Response_Many<IUserTiersJSONAPIDTO, void>>;
5
5
  }
6
- export declare type IGetTiersByCardResponseDTO = IUserTiersAttributes;
6
+ export type IGetTiersByCardResponseDTO = IUserTiersAttributes;
7
7
  export interface IUserTiersJSONAPIDTO {
8
8
  id: string;
9
9
  type: 'userTier';
@@ -15,5 +15,5 @@ interface Transaction {
15
15
  state: 'expired' | 'activated';
16
16
  transactionID: string;
17
17
  }
18
- export declare type IGetTransactionsByCardResponseDTO = Transaction[];
18
+ export type IGetTransactionsByCardResponseDTO = Transaction[];
19
19
  export {};
@@ -15,5 +15,5 @@ interface GetShortUrlResponseDTO {
15
15
  ];
16
16
  included: [];
17
17
  }
18
- declare type LinkType = 'link';
18
+ type LinkType = 'link';
19
19
  export {};
@@ -6,6 +6,7 @@ export interface IUser {
6
6
  phone: string;
7
7
  email: string;
8
8
  job_title?: string;
9
+ workplace?: string;
9
10
  shops?: string[];
10
11
  ref_id: string;
11
12
  ref_code: string;
@@ -6,7 +6,7 @@ export interface IUserAddress {
6
6
  building?: string;
7
7
  apartment?: string;
8
8
  }
9
- export declare type TUserGender = 'male' | 'female' | 'secret' | 'other';
9
+ export type TUserGender = 'male' | 'female' | 'secret' | 'other';
10
10
  export interface IUserCreate {
11
11
  firstName: string;
12
12
  lastName: string;
@@ -31,4 +31,4 @@ export interface IEmailTemplate {
31
31
  export interface IListEmailTemplatesResponse {
32
32
  data: IEmailTemplate[];
33
33
  }
34
- export declare type TListEmailTemplatesResponseDTO = I_JSON_API_Response_Many<IEmailTemplate>;
34
+ export type TListEmailTemplatesResponseDTO = I_JSON_API_Response_Many<IEmailTemplate>;
@@ -1,9 +1,9 @@
1
1
  import { IListFiltersPayload } from '../interfaces/requestFilterInterfaces';
2
- export declare type TFilterQueryParams = {
2
+ export type TFilterQueryParams = {
3
3
  'page[limit]'?: number;
4
4
  'page[offset]': number;
5
5
  } & {
6
6
  [key: string]: any;
7
7
  };
8
- export declare type TToFilterQueryParams = (params: IListFiltersPayload) => TFilterQueryParams;
8
+ export type TToFilterQueryParams = (params: IListFiltersPayload) => TFilterQueryParams;
9
9
  export declare const toFilterQueryParams: TToFilterQueryParams;
@@ -5,9 +5,6 @@ export declare const commonGetCardBonuses: (client: IHTTPClientInstance, url: st
5
5
  jsonAPI: any;
6
6
  data: any;
7
7
  }>;
8
- abort: {
9
- (reason?: any): void;
10
- (): void;
11
- };
8
+ abort: (reason?: any) => void;
12
9
  };
13
10
  export declare const getCardBonuses: IGetCardBonuses;