@bzbs/react-api-client 0.0.4 → 0.0.6

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/dist/index.d.mts CHANGED
@@ -819,144 +819,282 @@ declare class AuthenticateApi extends BaseService {
819
819
  constructor(client: AxiosInstance, baseUrl: string);
820
820
  /**
821
821
  * Performs a device login using the provided device uuid.
822
- * @param appId - Your application id.
823
- * @param uuid - The unique device identifier.
822
+ *
823
+ * @param params - The parameters.
824
+ * @param params.appId - Your application id.
825
+ * @param params.uuid - The unique device identifier.
826
+ * @param params.options - (Optional) Additional params for the request.
824
827
  * @param requestOptions - Optional request options.
825
828
  * @returns A promise that resolves to a ServiceResponse containing the login response.
826
829
  */
827
- deviceLogin(appId: string, uuid: string, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
830
+ deviceLogin(params: {
831
+ appId: string;
832
+ uuid: string;
833
+ options?: {
834
+ [key: string]: any;
835
+ };
836
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
828
837
  /**
829
838
  * Performs a Facebook login using the provided Facebook access token.
839
+ *
840
+ * @param params - The parameters.
830
841
  * @param accessToken - The access token obtained from Facebook.
831
842
  * @param appId - Your application id.
832
843
  * @param uuid - The unique device identifier.
844
+ * @param params.options - (Optional) Additional params for the request.
833
845
  * @param requestOptions - Optional request options.
834
846
  * @returns A promise that resolves to a ServiceResponse containing the login response.
835
847
  */
836
- facebookLogin(accessToken: string, appId: string, uuid: string, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
848
+ facebookLogin(params: {
849
+ accessToken: string;
850
+ appId: string;
851
+ uuid: string;
852
+ options?: {
853
+ [key: string]: any;
854
+ };
855
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
837
856
  /**
838
857
  * Performs a Google login using the provided id token, app id, and uuid.
839
- * @param idToken - The Google id token.
840
- * @param appId - Your application id.
841
- * @param uuid - The unique device identifier.
858
+ *
859
+ * @param params - The parameters.
860
+ * @param params.idToken - The Google id token.
861
+ * @param params.appId - Your application id.
862
+ * @param params.uuid - The unique device identifier.
863
+ * @param params.options - (Optional) Additional params for the request.
842
864
  * @param requestOptions - Optional request options.
843
865
  * @returns A promise that resolves to a ServiceResponse containing the login response.
844
866
  */
845
- googleLogin(idToken: string, appId: string, uuid: string, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
867
+ googleLogin(params: {
868
+ idToken: string;
869
+ appId: string;
870
+ uuid: string;
871
+ options?: {
872
+ [key: string]: any;
873
+ };
874
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
846
875
  /**
847
876
  * Performs a Line login using the provided id token, Line access token and authorization code.
848
- * @param idToken - The Line id token.
849
- * @param lineAccessToken - The Line access token.
850
- * @param authorizationCode - The authorization code.
851
- * @param appId - Your application id.
852
- * @param uuid - The unique device identifier.
853
- * @param requestOptions - Optional request options.
877
+ *
878
+ * @param params - The parameters.
879
+ * @param params.idToken - The Line id token.
880
+ * @param params.lineAccessToken - The Line access token.
881
+ * @param params.authorizationCode - The Line authorization code.
882
+ * @param params.appId - Your application id.
883
+ * @param params.uuid - The unique device identifier.
884
+ * @param params.options - (Optional) Additional params for the request.
854
885
  * @returns A promise that resolves to a ServiceResponse containing the login response.
855
886
  */
856
- lineLogin(idToken: string, lineAccessToken: string, authorizationCode: string, appId: string, uuid: string, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
887
+ lineLogin(params: {
888
+ idToken: string;
889
+ lineAccessToken: string;
890
+ authorizationCode: string;
891
+ appId: string;
892
+ uuid: string;
893
+ options?: {
894
+ [key: string]: any;
895
+ };
896
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
857
897
  /**
858
898
  * Performs an Apple login using the provided id token and Apple refresh token.
859
- * @param idToken - The Apple id token.
860
- * @param refreshToken - The Apple access token.
861
- * @param appId - Your application id.
862
- * @param uuid - The unique device identifier.
899
+ *
900
+ * @param params - The parameters.
901
+ * @param params.idToken - The Apple id token.
902
+ * @param params.refreshToken - The Apple refresh token.
903
+ * @param params.appId - Your application id.
904
+ * @param params.uuid - The unique device identifier.
905
+ * @param params.options - (Optional) Additional params for the request.
863
906
  * @param requestOptions - Optional request options.
864
907
  * @returns A promise that resolves to a ServiceResponse containing the login response.
865
908
  */
866
- appleLogin(idToken: string, refreshToken: string, appId: string, uuid: string, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
909
+ appleLogin(params: {
910
+ idToken: string;
911
+ refreshToken: string;
912
+ appId: string;
913
+ uuid: string;
914
+ options?: {
915
+ [key: string]: any;
916
+ };
917
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
867
918
  /**
868
- * Authenticates a user using a username and password.
919
+ * Performs a username and password login using the provided username and password.
869
920
  *
870
- * @param username - The username of the user.
871
- * @param password - The password of the user.
872
- * @param uuid - The unique device identifier.
873
- * @param appId - Your application id.
874
- * @param requestOptions - Optional request options.
921
+ * @param params - The parameters.
922
+ * @param params.username - The username of the user.
923
+ * @param params.password - The password of the user.
924
+ * @param params.uuid - The unique device identifier.
925
+ * @param params.appId - Your application id.
926
+ * @param params.options - (Optional) Additional params for the request.
875
927
  * @returns A promise that resolves to a ServiceResponse containing the login response.
876
928
  */
877
- usernamePasswordLogin(username: string, password: string, uuid: string, appId: string, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
929
+ usernamePasswordLogin(params: {
930
+ username: string;
931
+ password: string;
932
+ uuid: string;
933
+ appId: string;
934
+ options?: {
935
+ [key: string]: any;
936
+ };
937
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<LoginResponse>>;
878
938
  /**
879
- * Logs out the user with the specified UUID.
880
- * @param uuid - The unique device identifier.
939
+ * Performs a logout for the user.
940
+ *
941
+ * @param params - The parameters.
942
+ * @param params.uuid - The unique device identifier.
943
+ * @param params.options - (Optional) Additional params for the request.
881
944
  * @param requestOptions - Optional request options.
882
- * @returns A promise that resolves to a ServiceResponse containing the logout result.
945
+ * @returns A promise that resolves to a ServiceResponse containing the logout response.
883
946
  */
884
- logout(uuid: string, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
947
+ logout(params: {
948
+ uuid: string;
949
+ options?: {
950
+ [key: string]: any;
951
+ };
952
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
885
953
  /**
886
- * Sends a forget password request to the server.
954
+ * Sends a forget password request to the user.
887
955
  *
888
- * @param contact - The contact information for the user (email or contact number).
889
- * @param type - The type of contact information provided ('email' or 'contact_number').
956
+ * @param params - The parameters.
957
+ * @param params.contact - The contact information for the user (email or contact number).
958
+ * @param params.type - The type of contact information.
959
+ * @param params.options - (Optional) Additional params for the request.
890
960
  * @param requestOptions - Optional request options.
891
961
  * @returns A promise that resolves to a ServiceResponse containing the forget password response.
892
962
  */
893
- forgetPassword(contact: string, type: 'email' | 'contact_number', requestOptions?: RequestOptions): Promise<ServiceResponse<ForgetPasswordResponse>>;
963
+ forgetPassword(params: {
964
+ contact: string;
965
+ type: 'email' | 'contact_number';
966
+ options?: {
967
+ [key: string]: any;
968
+ };
969
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ForgetPasswordResponse>>;
894
970
  /**
895
971
  * Resets the password for a user.
896
972
  *
897
- * @param contact - The contact information for the user (email or contact number).
898
- * @param refCode - The reference code for password reset.
899
- * @param newPassword - The new password to set.
900
- * @param otp - (Optional) The one-time password.
973
+ * @param params - The parameters.
974
+ * @param params.contact - The contact information for the user (email or contact number).
975
+ * @param params.refCode - The reference code for password reset.
976
+ * @param params.newPassword - The new password to set.
977
+ * @param params.otp - (Optional) The one-time password.
978
+ * @param params.options - (Optional) Additional params for the request.
901
979
  * @param requestOptions - (Optional) Additional options for the request.
902
980
  * @returns A promise that resolves to a ServiceResponse containing the status response.
903
981
  */
904
- resetPassword(contact: string, refCode: string, newPassword: string, otp?: string, requestOptions?: RequestOptions): Promise<ServiceResponse<StatusResponse>>;
982
+ resetPassword(params: {
983
+ contact: string;
984
+ refCode: string;
985
+ newPassword: string;
986
+ otp?: string;
987
+ options?: {
988
+ [key: string]: any;
989
+ };
990
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<StatusResponse>>;
905
991
  /**
906
- * Send an OTP (One-Time Password) to the user for authentication.
992
+ * Sends an OTP (One-Time Password) to the user for authentication.
907
993
  *
908
- * @param uuid - The unique device identifier.
909
- * @param appId - Your application id.
910
- * @param contactNumber - The contact number of the user.
911
- * @param channel - (Optional) The channel through which the OTP should be sent.
994
+ * @param params - The parameters.
995
+ * @param params.uuid - The unique device identifier.
996
+ * @param params.appId - Your application id.
997
+ * @param params.contactNumber - The contact number for the user.
998
+ * @param params.channel - (Optional) The channel to use for OTP delivery.
999
+ * @param params.options - (Optional) Additional params for the request.
912
1000
  * @param requestOptions - (Optional) Additional options for the request.
913
1001
  * @returns A promise that resolves to a ServiceResponse containing the OTP response.
914
1002
  */
915
- getOtp(uuid: string, appId: string, contactNumber: string, channel?: string, requestOptions?: RequestOptions): Promise<ServiceResponse<OtpResponse>>;
1003
+ getOtp(params: {
1004
+ uuid: string;
1005
+ appId: string;
1006
+ contactNumber: string;
1007
+ channel?: string;
1008
+ options?: {
1009
+ [key: string]: any;
1010
+ };
1011
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<OtpResponse>>;
916
1012
  /**
917
- * Confirms the OTP (One-Time Password) for authentication.
1013
+ * Confirm the OTP (One-Time Password) for authentication.
918
1014
  *
919
- * @param otp - The OTP to be confirmed.
920
- * @param refCode - The reference code for the OTP.
921
- * @param contactNumber - The contact number associated with the OTP.
922
- * @param requestOptions - Optional request options.
923
- * @returns A promise that resolves to a ServiceResponse containing the confirmation response.
1015
+ * @param params - The parameters.
1016
+ * @param params.otp - The OTP to confirm.
1017
+ * @param params.refCode - The reference code for the OTP.
1018
+ * @param params.contactNumber - The contact number for the user.
1019
+ * @param params.options - (Optional) Additional params for the request.
1020
+ * @param requestOptions - (Optional) Additional options for the request.
1021
+ * @returns A promise that resolves to a ServiceResponse containing the confirm OTP response.
924
1022
  */
925
- confirmOtp(otp: string, refCode: string, contactNumber: string, requestOptions?: RequestOptions): Promise<ServiceResponse<ConfirmOtpResponse>>;
1023
+ confirmOtp(params: {
1024
+ otp: string;
1025
+ refCode: string;
1026
+ contactNumber: string;
1027
+ options?: {
1028
+ [key: string]: any;
1029
+ };
1030
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ConfirmOtpResponse>>;
926
1031
  /**
927
- * Validates the OTP (One-Time Password) for a given app and contact number.
928
- * @param appId - Your application id.
929
- * @param otp - The OTP to validate.
930
- * @param refCode - The reference code.
931
- * @param contactNumber - The contact number.
932
- * @param use - A boolean indicating whether the OTP should be used.
933
- * @param channel - (Optional) The channel to use for OTP validation.
1032
+ * Validate the OTP (One-Time Password) for authentication.
1033
+ *
1034
+ * @param params - The parameters.
1035
+ * @param params.appId - Your application id.
1036
+ * @param params.otp - The OTP to validate.
1037
+ * @param params.refCode - The reference code for the OTP.
1038
+ * @param params.contactNumber - The contact number for the user.
1039
+ * @param params.use - Whether to use the OTP after validation.
1040
+ * @param params.channel - (Optional) The channel to use for OTP delivery.
1041
+ * @param params.options - (Optional) Additional params for the request.
934
1042
  * @param requestOptions - (Optional) Additional options for the request.
935
- * @returns A promise that resolves to a ServiceResponse containing the validation result.
1043
+ * @returns A promise that resolves to a ServiceResponse containing the validate OTP response.
936
1044
  */
937
- validateOtp(appId: string, otp: string, refCode: string, contactNumber: string, use: boolean, channel?: string, requestOptions?: RequestOptions): Promise<ServiceResponse<ValidateOtpResponse>>;
1045
+ validateOtp(params: {
1046
+ appId: string;
1047
+ otp: string;
1048
+ refCode: string;
1049
+ contactNumber: string;
1050
+ use: boolean;
1051
+ channel?: string;
1052
+ options?: {
1053
+ [key: string]: any;
1054
+ };
1055
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ValidateOtpResponse>>;
938
1056
  /**
939
1057
  * Retrieve a new token and update the current device token.
940
1058
  *
941
- * @param uuid - The unique device identifier.
942
- * @param appId - Your application id.
943
- * @param clientVersion - The version of the client.
944
- * @param deviceToken - The token of the device.
945
- * @param requestOptions - The options for the request.
1059
+ * @param params - The parameters.
1060
+ * @param params.uuid - The unique device identifier.
1061
+ * @param params.appId - Your application id.
1062
+ * @param params.clientVersion - The version of the client.
1063
+ * @param params.deviceToken - The token of the device.
1064
+ * @param params.options - (Optional) Additional params for the request.
1065
+ * @param requestOptions - (Optional) Additional options for the request.
946
1066
  * @returns A promise that resolves to a ServiceResponse containing the resume response.
947
1067
  */
948
- resume(uuid: string, appId: string, clientVersion?: string, deviceToken?: string, requestOptions?: RequestOptions): Promise<ServiceResponse<ResumeResponse>>;
1068
+ resume(params: {
1069
+ uuid: string;
1070
+ appId: string;
1071
+ clientVersion?: string;
1072
+ deviceToken?: string;
1073
+ options?: {
1074
+ [key: string]: any;
1075
+ };
1076
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ResumeResponse>>;
949
1077
  /**
950
1078
  * Update the device token for push notification.
951
1079
  *
952
- * @param uuid - The unique device identifier.
953
- * @param appId - Your application id.
954
- * @param clientVersion - The version of the client.
955
- * @param deviceToken - The token of the device.
956
- * @param requestOptions - The options for the request.
1080
+ * @param params - The parameters.
1081
+ * @param params.uuid - The unique device identifier.
1082
+ * @param params.appId - Your application id.
1083
+ * @param params.clientVersion - The version of the client.
1084
+ * @param params.deviceToken - The token of the device.
1085
+ * @param params.options - (Optional) Additional params for the request.
1086
+ * @param requestOptions - (Optional) Additional options for the request.
957
1087
  * @returns A promise that resolves to a ServiceResponse containing the resume response.
958
1088
  */
959
- updateDevice(uuid: string, appId: string, clientVersion?: string, deviceToken?: string, requestOptions?: RequestOptions): Promise<ServiceResponse<ResumeResponse>>;
1089
+ updateDevice(params: {
1090
+ uuid: string;
1091
+ appId: string;
1092
+ clientVersion?: string;
1093
+ deviceToken?: string;
1094
+ options?: {
1095
+ [key: string]: any;
1096
+ };
1097
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ResumeResponse>>;
960
1098
  /**
961
1099
  * Retrieves the version information for the current app version.
962
1100
  * @param clientVersion - The version of the client (App Prefix + Your application version , Ex. ios_buzzebeesdemo1.0.1).
@@ -975,9 +1113,18 @@ declare class AuthenticateApi extends BaseService {
975
1113
 
976
1114
  declare class BadgeApi extends BaseService {
977
1115
  constructor(client: AxiosInstance, baseUrl: string);
978
- getBadge(params: {
1116
+ /**
1117
+ * Retrieves user badges.
1118
+ *
1119
+ * @param params - The parameters.
1120
+ * @param params.badgeId - The ID of the badge to retrieve.
1121
+ * @param params.options - (Optional) Additional params for the request.
1122
+ * @param requestOptions - (Optional) Additional options for the request.
1123
+ * @returns A promise that resolves to a ServiceResponse containing an array of Badge objects.
1124
+ */
1125
+ getBadges(params: {
979
1126
  badgeId?: string;
980
- option?: {
1127
+ options?: {
981
1128
  [key: string]: any;
982
1129
  };
983
1130
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Badge[]>>;
@@ -985,6 +1132,30 @@ declare class BadgeApi extends BaseService {
985
1132
 
986
1133
  declare class CampaignApi extends BaseService {
987
1134
  constructor(client: AxiosInstance, baseUrl: string);
1135
+ /**
1136
+ * Retrieves a list of campaigns based on the provided parameters.
1137
+ *
1138
+ * @param params - The parameters for the campaign list.
1139
+ * @param params.config - The configuration for the campaign (list name).
1140
+ * @param params.cat - The category for the campaign.
1141
+ * @param params.byConfig - A boolean indicating whether to filter by configuration.
1142
+ * @param params.skip - The number of campaigns to skip.
1143
+ * @param params.top - The number of campaigns to retrieve.
1144
+ * @param params.deviceLocale - The device locale for the campaigns.
1145
+ * @param params.locale - The locale for the campaigns.
1146
+ * @param params.keyword - The keyword for the campaigns.
1147
+ * @param params.startDate - The start date for the campaigns.
1148
+ * @param params.sponsorId - The sponsor ID for the campaigns.
1149
+ * @param params.maxPoints - The maximum points for the campaigns.
1150
+ * @param params.minPoints - The minimum points for the campaigns.
1151
+ * @param params.sortBy - The sort order for the campaigns.
1152
+ * @param params.center - The coordinates for the center of the campaigns.
1153
+ * @param params.hashTags - The hash tags for the campaigns.
1154
+ * @param params.locationAgencyId - The location agency ID for the campaigns.
1155
+ * @param params.options - (Optional) Additional params for the request.
1156
+ * @param requestOptions - The options for the HTTP request.
1157
+ * @returns A promise that resolves to a ServiceResponse containing an array of Campaign objects.
1158
+ */
988
1159
  campaign(params: {
989
1160
  config: string;
990
1161
  cat?: string;
@@ -1002,53 +1173,176 @@ declare class CampaignApi extends BaseService {
1002
1173
  center?: string;
1003
1174
  hashTags?: string;
1004
1175
  locationAgencyId?: string;
1005
- option?: {
1176
+ options?: {
1006
1177
  [key: string]: any;
1007
1178
  };
1008
1179
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Campaign[]>>;
1180
+ /**
1181
+ * Retrieves a list of user's favorite campaigns.
1182
+ *
1183
+ * @param params - The parameters.
1184
+ * @param params.skip - The number of campaigns to skip.
1185
+ * @param params.top - The number of campaigns to retrieve.
1186
+ * @param params.locale - The locale for the campaigns.
1187
+ * @param params.options - (Optional) Additional params for the request.
1188
+ * @param requestOptions - The options for the API request.
1189
+ * @returns A promise that resolves to a ServiceResponse containing an array of Campaign objects.
1190
+ */
1009
1191
  favoriteCampaigns(params: {
1010
1192
  skip?: number;
1011
1193
  top?: number;
1012
1194
  locale?: number;
1013
- option?: {
1195
+ options?: {
1014
1196
  [key: string]: any;
1015
1197
  };
1016
1198
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Campaign[]>>;
1199
+ /**
1200
+ * Retrieves the details of a campaign.
1201
+ *
1202
+ * @param param - The parameters.
1203
+ * @param param.id - The ID of the campaign.
1204
+ * @param param.deviceLocale - The device locale (optional).
1205
+ * @param param.options - Additional options for the request (optional).
1206
+ * @param requestOptions - The options for the request (optional).
1207
+ * @returns A promise that resolves to a service response containing the campaign details.
1208
+ */
1017
1209
  campaignDetails(param: {
1018
1210
  id: string;
1019
1211
  deviceLocale?: number;
1212
+ options?: {
1213
+ [key: string]: any;
1214
+ };
1020
1215
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<CampaignDetail>>;
1216
+ /**
1217
+ * Adds a campaign to the user's favorites.
1218
+ * @param id - The ID of the campaign to add to favorites.
1219
+ * @param requestOptions - Optional request options.
1220
+ * @returns A promise that resolves to a ServiceResponse containing the FavoriteResponse.
1221
+ */
1021
1222
  addToFavorite(id: string, requestOptions?: RequestOptions): Promise<ServiceResponse<FavoriteResponse>>;
1223
+ /**
1224
+ * Removes a campaign from user's favorites.
1225
+ * @param id - The ID of the campaign to remove from favorites.
1226
+ * @param requestOptions - Optional request options.
1227
+ * @returns A promise that resolves to a ServiceResponse containing the FavoriteResponse.
1228
+ */
1022
1229
  removeFromFavorite(id: string, requestOptions?: RequestOptions): Promise<ServiceResponse<FavoriteResponse>>;
1230
+ /**
1231
+ * Redeems a campaign.
1232
+ *
1233
+ * @param params - The parameters for redeeming the campaign.
1234
+ * @param params.id - The ID of the campaign to redeem.
1235
+ * @param params.addressKey - The address key of a user's address.
1236
+ * @param params.contactNumber - The contact number of the user.
1237
+ * @param params.options - Additional options for the redemption.
1238
+ * @param requestOptions - The options for the HTTP request.
1239
+ * @returns A promise that resolves to a service response containing the redeem response.
1240
+ */
1023
1241
  redeem(params: {
1024
1242
  id: string;
1025
1243
  addressKey?: string;
1026
1244
  contactNumber?: string;
1245
+ options?: {
1246
+ [key: string]: any;
1247
+ };
1248
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<RedeemResponse>>;
1249
+ /**
1250
+ * Redeems a campaign in bulk.
1251
+ *
1252
+ * @param params - The parameters.
1253
+ * @param params.id - The ID of the campaign to redeem.
1254
+ * @param params.quantity - The quantity to redeem.
1255
+ * @param params.options - Additional options for the redemption.
1256
+ * @param requestOptions - The options for the HTTP request.
1257
+ * @returns A promise that resolves to a service response containing the redeem response.
1258
+ */
1259
+ bulkRedeem(params: {
1260
+ id: string;
1261
+ quantity: number;
1262
+ options?: {
1263
+ [key: string]: any;
1264
+ };
1027
1265
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<RedeemResponse>>;
1028
- bulkRedeem(id: string, quantity: number, requestOptions?: RequestOptions): Promise<ServiceResponse<RedeemResponse>>;
1029
1266
  }
1030
1267
 
1031
1268
  declare class CartApi extends BaseService {
1032
1269
  constructor(client: AxiosInstance, baseUrl: string);
1270
+ /**
1271
+ * Adds an item to the cart.
1272
+ *
1273
+ * @param params - The parameters.
1274
+ * @param params.id - The ID of the item to add to the cart.
1275
+ * @param params.mode - The mode off adding.
1276
+ * @param params.qty - The quantity of the item.
1277
+ * @param params.sideCampaignJson - The side campaign JSON.
1278
+ * @param params.options - Additional options for adding the item to the cart.
1279
+ * @param requestOptions - The options for the request.
1280
+ * @returns A promise that resolves to a ServiceResponse containing the cart count response.
1281
+ */
1033
1282
  addCart(params: {
1034
1283
  id: string;
1035
1284
  mode?: string;
1036
1285
  qty?: number;
1037
1286
  sideCampaignJson?: string;
1287
+ options?: {
1288
+ [key: string]: any;
1289
+ };
1038
1290
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<CartCountResponse>>;
1291
+ /**
1292
+ * Retrieves the count of items in the cart.
1293
+ *
1294
+ * @param requestOptions - Optional request options.
1295
+ * @returns A promise that resolves to a ServiceResponse containing the CartCountResponse.
1296
+ */
1039
1297
  cartCount(requestOptions?: RequestOptions): Promise<ServiceResponse<CartCountResponse>>;
1040
1298
  }
1041
1299
 
1042
1300
  declare class CategoryApi extends BaseService {
1043
1301
  constructor(client: AxiosInstance, baseUrl: string);
1302
+ /**
1303
+ * Retrieves the campaign categories.
1304
+ *
1305
+ * @param params - The parameters.
1306
+ * @param params.config - The configuration string.
1307
+ * @param params.byConfig - Optional. Specifies whether to retrieve categories by configuration.
1308
+ * @param params.options - Optional. Additional options for retrieving the categories.
1309
+ * @param requestOptions - Optional. The request options.
1310
+ * @returns A promise that resolves to a service response containing an array of categories.
1311
+ */
1044
1312
  categories(params: {
1045
- byConfig: boolean;
1046
1313
  config: string;
1314
+ byConfig?: boolean;
1315
+ options?: {
1316
+ [key: string]: any;
1317
+ };
1047
1318
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Category[]>>;
1048
1319
  }
1049
1320
 
1050
1321
  declare class ConsentApi extends BaseService {
1051
1322
  constructor(client: AxiosInstance, baseUrl: string);
1323
+ /**
1324
+ * Retrieves the user's consent information.
1325
+ *
1326
+ * @param params - The parameters for the consent request.
1327
+ * @param params.termsAndConditions - The terms and conditions consent version.
1328
+ * @param params.dataPrivacy - The data privacy consent version.
1329
+ * @param params.marketingOption - The marketing option consent version.
1330
+ * @param params.email - The email consent (0 for false, 1 for true).
1331
+ * @param params.sms - The SMS consent (0 for false, 1 for true).
1332
+ * @param params.notification - The notification consent (0 for false, 1 for true).
1333
+ * @param params.line - The LINE consent (0 for false, 1 for true).
1334
+ * @param params.analyticsBuzzebeesCookies - The analytics Buzzebees cookies consent (0 for false, 1 for true).
1335
+ * @param params.analyticsFirebaseCookies - The analytics Firebase cookies consent (0 for false, 1 for true).
1336
+ * @param params.analyticsGoogleCookies - The analytics Google cookies consent (0 for false, 1 for true).
1337
+ * @param params.analyticsMetaCookies - The analytics Meta cookies consent (0 for false, 1 for true).
1338
+ * @param params.analyticsOtherCookies - The analytics other cookies consent (0 for false, 1 for true).
1339
+ * @param params.functionalCookies - The functional cookies consent (0 for false, 1 for true).
1340
+ * @param params.marketingCookies - The marketing cookies consent (0 for false, 1 for true).
1341
+ * @param params.necessaryCookies - The necessary cookies consent (0 for false, 1 for true).
1342
+ * @param params.options - Additional params.
1343
+ * @param requestOptions - The options for the request.
1344
+ * @returns A promise that resolves to a ServiceResponse containing the consent information.
1345
+ */
1052
1346
  getConsent(params: {
1053
1347
  termsAndConditions?: string;
1054
1348
  dataPrivacy?: string;
@@ -1065,28 +1359,93 @@ declare class ConsentApi extends BaseService {
1065
1359
  functionalCookies?: string;
1066
1360
  marketingCookies?: string;
1067
1361
  necessaryCookies?: string;
1362
+ options?: {
1363
+ [key: string]: any;
1364
+ };
1068
1365
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Consent>>;
1366
+ /**
1367
+ * Unconsents the user.
1368
+ *
1369
+ * @param requestOptions - The options for the request.
1370
+ * @returns A promise that resolves to a ServiceResponse containing the result of the unconsent operation.
1371
+ */
1069
1372
  unconsent(requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
1070
1373
  }
1071
1374
 
1072
1375
  declare class CouponApi extends BaseService {
1073
1376
  constructor(client: AxiosInstance, baseUrl: string);
1377
+ /**
1378
+ * Processes coupon codes.
1379
+ *
1380
+ * @param params - The parameters.
1381
+ * @param params.codes - The coupon codes to process.
1382
+ * @param params.options - Additional options for processing coupon codes.
1383
+ * @param requestOptions - The options for making the API request.
1384
+ * @returns A promise that resolves to a service response containing the coupon response.
1385
+ */
1074
1386
  processCodes(params: {
1075
1387
  codes: string;
1388
+ options?: {
1389
+ [key: string]: any;
1390
+ };
1076
1391
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<CouponResponse>>;
1077
1392
  }
1078
1393
 
1079
1394
  declare class DashboardApi extends BaseService {
1080
1395
  constructor(client: AxiosInstance, baseUrl: string);
1081
- mainDashboard(appName: string, locale: number, requestOptions?: RequestOptions): Promise<ServiceResponse<Dashboard[]>>;
1396
+ /**
1397
+ * Retrieves the main dashboard data.
1398
+ *
1399
+ * @param params - The parameters.
1400
+ * @param params.appName - The name of the application.
1401
+ * @param params.locale - The locale number.
1402
+ * @param params.options - Additional options for the request.
1403
+ * @param requestOptions - The options for the request.
1404
+ * @returns A promise that resolves to a service response containing an array of Dashboard objects.
1405
+ */
1406
+ mainDashboard(params: {
1407
+ appName: string;
1408
+ locale: number;
1409
+ options?: {
1410
+ [key: string]: any;
1411
+ };
1412
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<Dashboard[]>>;
1413
+ /**
1414
+ * Retrieves a sub-dashboard data.
1415
+ *
1416
+ * @param params - The parameters.
1417
+ * @param params.dashboardName - The name of the sub-dashboard to retrieve.
1418
+ * @param params.locale - The locale of the sub-dashboard.
1419
+ * @param params.options - Additional options for retrieving the sub-dashboard.
1420
+ * @param requestOptions - Optional request options.
1421
+ * @returns A promise that resolves to a service response containing an array of dashboards.
1422
+ */
1082
1423
  subDashboard(params: {
1083
1424
  dashboardName: string;
1084
1425
  locale: number;
1426
+ options?: {
1427
+ [key: string]: any;
1428
+ };
1085
1429
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Dashboard[]>>;
1086
1430
  }
1087
1431
 
1088
1432
  declare class HistoryApi extends BaseService {
1089
1433
  constructor(client: AxiosInstance, baseUrl: string);
1434
+ /**
1435
+ * Retrieves the redeem histories based on the specified parameters.
1436
+ *
1437
+ * @param params - The parameters for retrieving redeem histories.
1438
+ * @param params.byConfig - Indicates whether to retrieve redeem histories by config.
1439
+ * @param params.config - The config for retrieving redeem histories.
1440
+ * @param params.skip - The number of records to skip.
1441
+ * @param params.top - The number of records to retrieve.
1442
+ * @param params.locale - The locale for retrieving redeem histories (optional).
1443
+ * @param params.startDate - The start date for retrieving redeem histories (optional).
1444
+ * @param params.endDate - The end date for retrieving redeem histories (optional).
1445
+ * @param params.options - Additional options for retrieving redeem histories (optional).
1446
+ * @param requestOptions - The options for the request (optional).
1447
+ * @returns A promise that resolves to a service response containing an array of purchase objects.
1448
+ */
1090
1449
  redeemHistories(params: {
1091
1450
  byConfig: boolean;
1092
1451
  config: string;
@@ -1095,36 +1454,109 @@ declare class HistoryApi extends BaseService {
1095
1454
  locale?: number;
1096
1455
  startDate?: string;
1097
1456
  endDate?: string;
1457
+ options?: {
1458
+ [key: string]: any;
1459
+ };
1098
1460
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Purchase[]>>;
1461
+ /**
1462
+ * Marks the specified redeem key as used.
1463
+ *
1464
+ * @param params - The parameters.
1465
+ * @param params.redeemKey - The redeem key for the campaign.
1466
+ * @param params.options - Additional options for using the campaign.
1467
+ * @param requestOptions - Optional request options.
1468
+ * @returns A promise that resolves to a service response containing the result of the redemption.
1469
+ */
1099
1470
  use(params: {
1100
1471
  redeemKey: string;
1472
+ options?: {
1473
+ [key: string]: any;
1474
+ };
1101
1475
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<UseCampaignResponse>>;
1102
1476
  }
1103
1477
 
1104
1478
  declare class LineApi extends BaseService {
1105
1479
  constructor(client: AxiosInstance, baseUrl: string);
1480
+ /**
1481
+ * Authenticates with the LINE API.
1482
+ *
1483
+ * @param params - The authentication parameters.
1484
+ * @param params.grantType - The grant type.
1485
+ * @param params.code - The code.
1486
+ * @param params.clientId - The client ID.
1487
+ * @param params.clientSecret - The client secret.
1488
+ * @param params.redirectUrl - The redirect URL.
1489
+ * @param params.options - Additional options for the request.
1490
+ * @param requestOptions - The optional request options.
1491
+ * @returns A promise that resolves to a ServiceResponse containing the LineAuthResponse.
1492
+ */
1106
1493
  lineAuth(params: {
1107
1494
  grantType: string;
1108
1495
  code: string;
1109
1496
  clientId: string;
1110
1497
  clientSecret: string;
1111
1498
  redirectUrl: string;
1499
+ options?: {
1500
+ [key: string]: any;
1501
+ };
1112
1502
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<LineAuthResponse>>;
1113
1503
  }
1114
1504
 
1115
1505
  declare class NotificationApi extends BaseService {
1116
1506
  constructor(client: AxiosInstance, baseUrl: string);
1507
+ /**
1508
+ * Retrieves notifications.
1509
+ *
1510
+ * @param params - The parameters for retrieving notifications.
1511
+ * @param params.mode - The mode for retrieving notifications (new or all)
1512
+ * @param params.sortBy - The sort order for the notifications (createdate_desc or createdate_asc)
1513
+ * @param requestOptions - The options for the HTTP request.
1514
+ * @returns A promise that resolves to a service response containing an array of notifications.
1515
+ */
1117
1516
  notifications(params: {
1118
- mode: string;
1119
- sortBy: string;
1517
+ mode: string | 'new' | 'all';
1518
+ sortBy: string | 'createdate_desc' | 'createdate_asc';
1519
+ options?: {
1520
+ [key: string]: any;
1521
+ };
1120
1522
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Notification[]>>;
1523
+ /**
1524
+ * Marks notifications as read.
1525
+ *
1526
+ * @param params - The parameters for marking notifications as read.
1527
+ * @param params.ids - The IDs(RowKeys) of the notifications to mark as read. (RowKey1, RowKey2)
1528
+ * @param params.options - Additional options for marking notifications as read.
1529
+ * @param requestOptions - Optional request options.
1530
+ * @returns A promise that resolves to a service response containing the result of marking notifications as read.
1531
+ */
1121
1532
  read(params: {
1122
1533
  ids: string;
1534
+ options?: {
1535
+ [key: string]: any;
1536
+ };
1123
1537
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
1124
1538
  }
1125
1539
 
1126
1540
  declare class PlaceApi extends BaseService {
1127
1541
  constructor(client: AxiosInstance, baseUrl: string);
1542
+ /**
1543
+ * Retrieves a list of places based on the provided parameters.
1544
+ *
1545
+ * @param params - The parameters for the place list request.
1546
+ * @param params.agencyId - The ID of the agency.
1547
+ * @param params.center - The center of the search area.
1548
+ * @param params.distance - The distance from the center.
1549
+ * @param params.top - The number of places to retrieve.
1550
+ * @param params.provinceCode - The province code (optional).
1551
+ * @param params.category - The category of the place (optional).
1552
+ * @param params.mode - The mode of the place (optional).
1553
+ * @param params.requiredCampaign - Indicates whether the place requires a campaign (optional).
1554
+ * @param params.keyword - The keyword to search for (optional).
1555
+ * @param params.isFavourite - Indicates whether the place is a favourite (optional).
1556
+ * @param params.options - Additional options for the request (optional).
1557
+ * @param requestOptions - The options for the request (optional).
1558
+ * @returns A promise that resolves to a ServiceResponse containing an array of Place objects.
1559
+ */
1128
1560
  placeList(params: {
1129
1561
  agencyId: string;
1130
1562
  center: string;
@@ -1136,16 +1568,50 @@ declare class PlaceApi extends BaseService {
1136
1568
  requiredCampaign?: boolean;
1137
1569
  keyword?: string;
1138
1570
  isFavourite?: boolean;
1571
+ options?: {
1572
+ [key: string]: any;
1573
+ };
1139
1574
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Place[]>>;
1575
+ /**
1576
+ * Retrieves information about a specific place.
1577
+ *
1578
+ * @param params - The parameters for the place request.
1579
+ * @param params.id - The ID of the place.
1580
+ * @param params.agencyId - The ID of the agency.
1581
+ * @param params.requiredCampaign - (Optional) Indicates if a campaign is required.
1582
+ * @param params.isFavourite - (Optional) Indicates if the place is a favorite.
1583
+ * @param params.options - (Optional) Additional options for the request.
1584
+ * @param requestOptions - (Optional) Additional options for the HTTP request.
1585
+ * @returns A promise that resolves to a ServiceResponse containing the place information.
1586
+ */
1140
1587
  place(params: {
1141
1588
  id: string;
1142
1589
  agencyId: string;
1143
1590
  requiredCampaign?: boolean;
1144
1591
  isFavourite?: boolean;
1592
+ options?: {
1593
+ [key: string]: any;
1594
+ };
1145
1595
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<Place>>;
1596
+ /**
1597
+ * Adds a place to the user's favorites.
1598
+ *
1599
+ * @param params - The parameters.
1600
+ * @param params.id - The ID of the place to be added to favorites.
1601
+ * @param requestOptions - The optional request options.
1602
+ * @returns A promise that resolves to a ServiceResponse containing the result of the operation.
1603
+ */
1146
1604
  addToFavourite(params: {
1147
1605
  id: string;
1148
1606
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
1607
+ /**
1608
+ * Removes a place from the user's favorites.
1609
+ *
1610
+ * @param params - The parameters.
1611
+ * @param params.id - The ID of the place to be removed from favorites.
1612
+ * @param requestOptions - Optional request options.
1613
+ * @returns A promise that resolves to a ServiceResponse containing the result of the operation.
1614
+ */
1149
1615
  removeFromFavourite(params: {
1150
1616
  id: string;
1151
1617
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
@@ -1153,15 +1619,38 @@ declare class PlaceApi extends BaseService {
1153
1619
 
1154
1620
  declare class PointLogApi extends BaseService {
1155
1621
  constructor(client: AxiosInstance, baseUrl: string);
1156
- getPointLog(month: string, options?: {
1622
+ /**
1623
+ * Retrieves the point log.
1624
+ *
1625
+ * @param params - The parameters for retrieving the point log.
1626
+ * @param params.month - The month for which to retrieve the point log.
1627
+ * @param params.type - (Optional) The type of point log to retrieve. (earn/burn/etc)
1628
+ * @param params.lastRowKey - (Optional) The last row key for pagination.
1629
+ * @param params.top - (Optional) The maximum number of records to retrieve.
1630
+ * @param params.options - (Optional) Additional options for the request.
1631
+ * @param requestOption - (Optional) The request options.
1632
+ * @returns A promise that resolves to a service response containing an array of point logs.
1633
+ */
1634
+ getPointLog(params: {
1635
+ month: string;
1157
1636
  type?: string;
1158
1637
  lastRowKey?: string;
1159
1638
  top?: number;
1639
+ options?: {
1640
+ [key: string]: any;
1641
+ };
1160
1642
  }, requestOption?: RequestOptions): Promise<ServiceResponse<PointLog[]>>;
1161
1643
  }
1162
1644
 
1163
1645
  declare class ProfileApi extends BaseService {
1164
1646
  constructor(client: AxiosInstance, baseUrl: string);
1647
+ /**
1648
+ * Updates the user profile with the provided parameters.
1649
+ *
1650
+ * @param params - The parameters for updating the profile.
1651
+ * @param requestOptions - The options for the request.
1652
+ * @returns A promise that resolves to a ServiceResponse containing the updated profile.
1653
+ */
1165
1654
  updateProfile(params: {
1166
1655
  profileImage?: File;
1167
1656
  firstName?: string;
@@ -1211,8 +1700,34 @@ declare class ProfileApi extends BaseService {
1211
1700
  occupation?: string;
1212
1701
  remark?: string;
1213
1702
  displayName?: string;
1703
+ options?: {
1704
+ [key: string]: any;
1705
+ };
1214
1706
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<ProfileResponse>>;
1215
- changePassword(current: string, change: string, requestOptions?: RequestOptions): Promise<ServiceResponse<StatusResponse>>;
1707
+ /**
1708
+ * Changes the user's password.
1709
+ *
1710
+ * @param params - The parameters.
1711
+ * @param params.current - The current password.
1712
+ * @param params.change - The new password.
1713
+ * @param params.options - Optional additional options.
1714
+ * @param requestOptions - Optional request options.
1715
+ * @returns A promise that resolves to a ServiceResponse containing the status response.
1716
+ */
1717
+ changePassword(params: {
1718
+ current: string;
1719
+ change: string;
1720
+ options?: {
1721
+ [key: string]: any;
1722
+ };
1723
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<StatusResponse>>;
1724
+ /**
1725
+ * Updates the shipping information for the user.
1726
+ *
1727
+ * @param params - The parameters for updating the shipping information.
1728
+ * @param requestOptions - The options for the HTTP request.
1729
+ * @returns A promise that resolves to a ServiceResponse containing the updated shipping information.
1730
+ */
1216
1731
  updateShipping(params: {
1217
1732
  shippingFirstName?: string;
1218
1733
  shippingLastName?: string;
@@ -1225,16 +1740,82 @@ declare class ProfileApi extends BaseService {
1225
1740
  shippingDistrictName?: string;
1226
1741
  shippingSubFDistrictName?: string;
1227
1742
  shippingContactNumber?: string;
1743
+ options?: {
1744
+ [key: string]: any;
1745
+ };
1746
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
1747
+ /**
1748
+ * Changes the contact number of the user.
1749
+ *
1750
+ * @param params - The parameters for changing the contact number.
1751
+ * @param params.contactNumber - The new contact number.
1752
+ * @param params.otp - The one-time password.
1753
+ * @param params.refCode - The reference code.
1754
+ * @param params.idCard - (Optional) The ID card for additional verification.
1755
+ * @param params.options - (Optional) Additional options for the request.
1756
+ * @param requestOptions - (Optional) The options for the request.
1757
+ * @returns A promise that resolves to the response of the request.
1758
+ */
1759
+ changeContactNumber(params: {
1760
+ contactNumber: string;
1761
+ otp: string;
1762
+ refCode: string;
1763
+ idCard?: string;
1764
+ options?: {
1765
+ [key: string]: any;
1766
+ };
1767
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ConfirmOtpResponse>>;
1768
+ /**
1769
+ * Changes the contact number for the current user.
1770
+ *
1771
+ * @param params - The parameters for changing the contact number.
1772
+ * @param params.contactNumber - The new contact number.
1773
+ * @param params.otp - The one-time password for verification.
1774
+ * @param params.refCode - The reference code for verification.
1775
+ * @param params.options - Additional options for the request.
1776
+ * @param requestOptions - The options for the request.
1777
+ * @returns A promise that resolves to a ServiceResponse containing the result of the request.
1778
+ */
1779
+ changeContactNumberV2(params: {
1780
+ contactNumber: string;
1781
+ otp: string;
1782
+ refCode: string;
1783
+ options?: {
1784
+ [key: string]: any;
1785
+ };
1228
1786
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
1229
- changeContactNumber(contactNumber: string, otp: string, refCode: string, idCard?: string, requestOptions?: RequestOptions): Promise<ServiceResponse<unknown>>;
1230
- changeContactNumberV2(contactNumber: string, otp: string, refCode: string, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
1787
+ /**
1788
+ * Retrieves the updated points for the current user's profile.
1789
+ *
1790
+ * @param requestOptions - Optional request options.
1791
+ * @returns A promise that resolves to a ServiceResponse containing the updated points.
1792
+ */
1231
1793
  points(requestOptions?: RequestOptions): Promise<ServiceResponse<UpdatedPoints>>;
1794
+ /**
1795
+ * Retrieves the expiring points for the current user's profile.
1796
+ *
1797
+ * @param requestOptions - Optional request options.
1798
+ * @returns A promise that resolves to a ServiceResponse containing the expiring points.
1799
+ */
1232
1800
  expiringPoints(requestOptions?: RequestOptions): Promise<ServiceResponse<ExpiringPoints>>;
1801
+ /**
1802
+ * Deactivates the user's profile.
1803
+ *
1804
+ * @param requestOptions - Optional request options.
1805
+ * @returns A promise that resolves to a ServiceResponse containing the result of the deactivation.
1806
+ */
1233
1807
  deactivate(requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
1234
1808
  }
1235
1809
 
1236
1810
  declare class RegistrationApi extends BaseService {
1237
1811
  constructor(client: AxiosInstance, baseUrl: string);
1812
+ /**
1813
+ * Registers a user with the provided registration parameters.
1814
+ *
1815
+ * @param params - The registration parameters.
1816
+ * @param requestOptions - The optional request options.
1817
+ * @returns A promise that resolves to a service response containing the registration response.
1818
+ */
1238
1819
  register(params: {
1239
1820
  appId: string;
1240
1821
  uuid: string;
@@ -1265,6 +1846,9 @@ declare class RegistrationApi extends BaseService {
1265
1846
  notificationMarketing?: string;
1266
1847
  lineMarketing?: string;
1267
1848
  phoneMarketing?: string;
1849
+ options: {
1850
+ [key: string]: any;
1851
+ };
1268
1852
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<RegistrationResponse>>;
1269
1853
  }
1270
1854