@bzbs/react-api-client 2.0.2 → 2.1.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.
package/dist/index.d.mts CHANGED
@@ -501,6 +501,11 @@ interface RedeemResponse {
501
501
  ExpireIn?: number;
502
502
  Points?: number;
503
503
  UpdatedPoints?: UpdatedPoints | null;
504
+ PointServiceUnit?: string;
505
+ PointServiceAmount?: number;
506
+ PointServiceTranId?: string;
507
+ PointServiceRef?: string;
508
+ PointServiceBalance?: number;
504
509
  PrivilegeMessage?: string;
505
510
  PrivilegeMessageEN?: string;
506
511
  PrivilegeMessageFormat?: string;
@@ -1247,6 +1252,31 @@ interface ConsentVersionValue {
1247
1252
  current_version: string;
1248
1253
  }
1249
1254
 
1255
+ interface PointBalance {
1256
+ Unit: string;
1257
+ Balance: number;
1258
+ Currents?: {
1259
+ [date: string]: number;
1260
+ };
1261
+ Expires?: {
1262
+ [date: string]: number;
1263
+ };
1264
+ }
1265
+
1266
+ interface PointHistory {
1267
+ Unit: string;
1268
+ TransactionId: string;
1269
+ Reference: string;
1270
+ Timestamp: number;
1271
+ TotalChange: number;
1272
+ Action: string;
1273
+ Type: string;
1274
+ Message: string | null;
1275
+ Data: {
1276
+ [key: string]: any;
1277
+ } | null;
1278
+ }
1279
+
1250
1280
  declare class AuthenticateApi extends BaseService {
1251
1281
  constructor(client: AxiosInstance, baseUrl: string);
1252
1282
  /**
@@ -1930,6 +1960,7 @@ declare class CampaignApi extends BaseService {
1930
1960
  * @param params.contactNumber - The contact number of the user.
1931
1961
  * @param params.options - Additional options for the redemption.
1932
1962
  * @param params.spPoints - Point Per Unit x Quantity (Donate only).
1963
+ * @param params.pointUnit - The point unit of the campaign (Point Service Only).
1933
1964
  * @param requestOptions - The options for the HTTP request.
1934
1965
  * @returns A promise that resolves to a service response containing the redeem response.
1935
1966
  */
@@ -2397,6 +2428,89 @@ declare class PointLogApi extends BaseService {
2397
2428
  }, requestOption?: RequestOptions): Promise<ServiceResponse<PointLog[]>>;
2398
2429
  }
2399
2430
 
2431
+ declare class PointApi extends BaseService {
2432
+ constructor(client: AxiosInstance, baseUrl: string);
2433
+ /**
2434
+ * Retrieves the current point balance for the authenticated user across the requested point units.
2435
+ *
2436
+ * @param params - The parameters for retrieving the point balance.
2437
+ * @param params.units - (Optional) Point unit codes (e.g. Point, Coin). Omit to use all units configured for the app.
2438
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
2439
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
2440
+ * @param params.options - (Optional) Additional options for the request.
2441
+ * @param requestOptions - (Optional) The request options.
2442
+ * @returns A promise that resolves to a service response containing an array of point balances.
2443
+ */
2444
+ balance(params?: {
2445
+ units?: string;
2446
+ boxIds?: string;
2447
+ onlyVisible?: boolean;
2448
+ options?: {
2449
+ [key: string]: unknown;
2450
+ };
2451
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<PointBalance[]>>;
2452
+ /**
2453
+ * Retrieves the point balance with Currents and Expires breakdowns keyed by date.
2454
+ *
2455
+ * @param params - The parameters for retrieving the point detail.
2456
+ * @param params.units - (Optional) Point unit codes (e.g. Point, Coin). Omit to use all units configured for the app.
2457
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
2458
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
2459
+ * @param params.options - (Optional) Additional options for the request.
2460
+ * @param requestOptions - (Optional) The request options.
2461
+ * @returns A promise that resolves to a service response containing an array of point balances with breakdowns.
2462
+ */
2463
+ detail(params?: {
2464
+ units?: string;
2465
+ boxIds?: string;
2466
+ onlyVisible?: boolean;
2467
+ options?: {
2468
+ [key: string]: unknown;
2469
+ };
2470
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<PointBalance[]>>;
2471
+ /**
2472
+ * Retrieves a paginated list of earn/burn/transfer transactions between start and end dates.
2473
+ *
2474
+ * @param params - The parameters for retrieving the point history.
2475
+ * @param params.start - Start of the range (inclusive), ISO-8601 with offset.
2476
+ * @param params.end - End of the range (inclusive), ISO-8601 with offset.
2477
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
2478
+ * @param params.skip - (Optional) Number of records to skip (offset pagination).
2479
+ * @param params.top - (Optional) Maximum number of records to return.
2480
+ * @param params.sortType - (Optional) Sort direction for Timestamp: Asc|Desc.
2481
+ * @param params.units - (Optional) Point unit codes to filter by.
2482
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
2483
+ * @param params.references - (Optional) Filter by transaction reference.
2484
+ * @param params.transactionIds - (Optional) Filter by exact transaction IDs.
2485
+ * @param params.includeActions - (Optional) Only include transactions whose Action matches (e.g. Earn, Burn, Transfer).
2486
+ * @param params.excludeActions - (Optional) Exclude transactions whose Action matches.
2487
+ * @param params.includeTypes - (Optional) Only include transactions whose Type matches.
2488
+ * @param params.excludeTypes - (Optional) Exclude transactions whose Type matches.
2489
+ * @param params.options - (Optional) Additional options for the request.
2490
+ * @param requestOptions - (Optional) The request options.
2491
+ * @returns A promise that resolves to a service response containing an array of point history transactions.
2492
+ */
2493
+ history(params: {
2494
+ start: string;
2495
+ end: string;
2496
+ onlyVisible?: boolean;
2497
+ skip?: number;
2498
+ top?: number;
2499
+ sortType?: 'Asc' | 'Desc';
2500
+ units?: string;
2501
+ boxIds?: string;
2502
+ references?: string;
2503
+ transactionIds?: string;
2504
+ includeActions?: string;
2505
+ excludeActions?: string;
2506
+ includeTypes?: string;
2507
+ excludeTypes?: string;
2508
+ options?: {
2509
+ [key: string]: unknown;
2510
+ };
2511
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<PointHistory[]>>;
2512
+ }
2513
+
2400
2514
  declare class ProfileApi extends BaseService {
2401
2515
  constructor(client: AxiosInstance, baseUrl: string);
2402
2516
  /**
@@ -3138,6 +3252,7 @@ declare class BzbsService {
3138
3252
  notificationApi: NotificationApi;
3139
3253
  placeApi: PlaceApi;
3140
3254
  pointLogApi: PointLogApi;
3255
+ pointApi: PointApi;
3141
3256
  profileApi: ProfileApi;
3142
3257
  registerApi: RegistrationApi;
3143
3258
  addressApi: AddressApi;
@@ -3151,4 +3266,4 @@ declare class BzbsService {
3151
3266
  setLineUrl(lineUrl: string): this;
3152
3267
  }
3153
3268
 
3154
- export { type AccessTokenResponse, type Address, AddressApi, type ApiResponse, type AppleToken, AuthenticateApi, type Badge, BadgeApi, BaseService, Blob, type Buzzebees, type BzbsErrorResponse, BzbsService, type Campaign, CampaignApi, type CampaignDetail, type CartAccessResponse, CartApi, type CartCountResponse, type Category, CategoryApi, type ChatMessage, type ClientError, type ConfirmOtpResponse, type Consent, ConsentApi, type ConsentVersion, type ConsentVersionValue, CouponApi, type CouponResponse, type CouponResponseData, type CreateStampResponse, type CrossPlatformFile, type Dashboard, DashboardApi, type Detail, type District, type ErrorResponse, type ExpiringPoints, type FavoriteResponse, type ForgetPasswordResponse, HistoryApi, type LikeForumResponse, LineApi, type LineAuthResponse, type LoginResponse, type Maintenance, type Mission, type Notification, NotificationApi, type OtpResponse, type Picture, type Place, PlaceApi, type PlaceService, type PointLog, PointLogApi, type PointUnit, ProfileApi, type ProfileResponse, type Province, type Purchase, type RedeemResponse, RegistrationApi, type RegistrationResponse, RequestHelpApi, type RequestHelpCode, type RequestOptions, type ResumeResponse, type ServerError, type ServiceResponse, SettingApi, type Stamp, StampApi, type StampCampaign, type StampHistory, type StampProfileResponse, type StatusResponse, type Style, type SubCampaign, type SubCampaignStyle, type SubDistrict, type SuccessResponse, type Trace, type UpdatedPoints, type UseCampaignResponse, type ValidateOtpResponse, type Version, type ZipCode };
3269
+ export { type AccessTokenResponse, type Address, AddressApi, type ApiResponse, type AppleToken, AuthenticateApi, type Badge, BadgeApi, BaseService, Blob, type Buzzebees, type BzbsErrorResponse, BzbsService, type Campaign, CampaignApi, type CampaignDetail, type CartAccessResponse, CartApi, type CartCountResponse, type Category, CategoryApi, type ChatMessage, type ClientError, type ConfirmOtpResponse, type Consent, ConsentApi, type ConsentVersion, type ConsentVersionValue, CouponApi, type CouponResponse, type CouponResponseData, type CreateStampResponse, type CrossPlatformFile, type Dashboard, DashboardApi, type Detail, type District, type ErrorResponse, type ExpiringPoints, type FavoriteResponse, type ForgetPasswordResponse, HistoryApi, type LikeForumResponse, LineApi, type LineAuthResponse, type LoginResponse, type Maintenance, type Mission, type Notification, NotificationApi, type OtpResponse, type Picture, type Place, PlaceApi, type PlaceService, PointApi, type PointBalance, type PointHistory, type PointLog, PointLogApi, type PointUnit, ProfileApi, type ProfileResponse, type Province, type Purchase, type RedeemResponse, RegistrationApi, type RegistrationResponse, RequestHelpApi, type RequestHelpCode, type RequestOptions, type ResumeResponse, type ServerError, type ServiceResponse, SettingApi, type Stamp, StampApi, type StampCampaign, type StampHistory, type StampProfileResponse, type StatusResponse, type Style, type SubCampaign, type SubCampaignStyle, type SubDistrict, type SuccessResponse, type Trace, type UpdatedPoints, type UseCampaignResponse, type ValidateOtpResponse, type Version, type ZipCode };
package/dist/index.d.ts CHANGED
@@ -501,6 +501,11 @@ interface RedeemResponse {
501
501
  ExpireIn?: number;
502
502
  Points?: number;
503
503
  UpdatedPoints?: UpdatedPoints | null;
504
+ PointServiceUnit?: string;
505
+ PointServiceAmount?: number;
506
+ PointServiceTranId?: string;
507
+ PointServiceRef?: string;
508
+ PointServiceBalance?: number;
504
509
  PrivilegeMessage?: string;
505
510
  PrivilegeMessageEN?: string;
506
511
  PrivilegeMessageFormat?: string;
@@ -1247,6 +1252,31 @@ interface ConsentVersionValue {
1247
1252
  current_version: string;
1248
1253
  }
1249
1254
 
1255
+ interface PointBalance {
1256
+ Unit: string;
1257
+ Balance: number;
1258
+ Currents?: {
1259
+ [date: string]: number;
1260
+ };
1261
+ Expires?: {
1262
+ [date: string]: number;
1263
+ };
1264
+ }
1265
+
1266
+ interface PointHistory {
1267
+ Unit: string;
1268
+ TransactionId: string;
1269
+ Reference: string;
1270
+ Timestamp: number;
1271
+ TotalChange: number;
1272
+ Action: string;
1273
+ Type: string;
1274
+ Message: string | null;
1275
+ Data: {
1276
+ [key: string]: any;
1277
+ } | null;
1278
+ }
1279
+
1250
1280
  declare class AuthenticateApi extends BaseService {
1251
1281
  constructor(client: AxiosInstance, baseUrl: string);
1252
1282
  /**
@@ -1930,6 +1960,7 @@ declare class CampaignApi extends BaseService {
1930
1960
  * @param params.contactNumber - The contact number of the user.
1931
1961
  * @param params.options - Additional options for the redemption.
1932
1962
  * @param params.spPoints - Point Per Unit x Quantity (Donate only).
1963
+ * @param params.pointUnit - The point unit of the campaign (Point Service Only).
1933
1964
  * @param requestOptions - The options for the HTTP request.
1934
1965
  * @returns A promise that resolves to a service response containing the redeem response.
1935
1966
  */
@@ -2397,6 +2428,89 @@ declare class PointLogApi extends BaseService {
2397
2428
  }, requestOption?: RequestOptions): Promise<ServiceResponse<PointLog[]>>;
2398
2429
  }
2399
2430
 
2431
+ declare class PointApi extends BaseService {
2432
+ constructor(client: AxiosInstance, baseUrl: string);
2433
+ /**
2434
+ * Retrieves the current point balance for the authenticated user across the requested point units.
2435
+ *
2436
+ * @param params - The parameters for retrieving the point balance.
2437
+ * @param params.units - (Optional) Point unit codes (e.g. Point, Coin). Omit to use all units configured for the app.
2438
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
2439
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
2440
+ * @param params.options - (Optional) Additional options for the request.
2441
+ * @param requestOptions - (Optional) The request options.
2442
+ * @returns A promise that resolves to a service response containing an array of point balances.
2443
+ */
2444
+ balance(params?: {
2445
+ units?: string;
2446
+ boxIds?: string;
2447
+ onlyVisible?: boolean;
2448
+ options?: {
2449
+ [key: string]: unknown;
2450
+ };
2451
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<PointBalance[]>>;
2452
+ /**
2453
+ * Retrieves the point balance with Currents and Expires breakdowns keyed by date.
2454
+ *
2455
+ * @param params - The parameters for retrieving the point detail.
2456
+ * @param params.units - (Optional) Point unit codes (e.g. Point, Coin). Omit to use all units configured for the app.
2457
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
2458
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
2459
+ * @param params.options - (Optional) Additional options for the request.
2460
+ * @param requestOptions - (Optional) The request options.
2461
+ * @returns A promise that resolves to a service response containing an array of point balances with breakdowns.
2462
+ */
2463
+ detail(params?: {
2464
+ units?: string;
2465
+ boxIds?: string;
2466
+ onlyVisible?: boolean;
2467
+ options?: {
2468
+ [key: string]: unknown;
2469
+ };
2470
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<PointBalance[]>>;
2471
+ /**
2472
+ * Retrieves a paginated list of earn/burn/transfer transactions between start and end dates.
2473
+ *
2474
+ * @param params - The parameters for retrieving the point history.
2475
+ * @param params.start - Start of the range (inclusive), ISO-8601 with offset.
2476
+ * @param params.end - End of the range (inclusive), ISO-8601 with offset.
2477
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
2478
+ * @param params.skip - (Optional) Number of records to skip (offset pagination).
2479
+ * @param params.top - (Optional) Maximum number of records to return.
2480
+ * @param params.sortType - (Optional) Sort direction for Timestamp: Asc|Desc.
2481
+ * @param params.units - (Optional) Point unit codes to filter by.
2482
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
2483
+ * @param params.references - (Optional) Filter by transaction reference.
2484
+ * @param params.transactionIds - (Optional) Filter by exact transaction IDs.
2485
+ * @param params.includeActions - (Optional) Only include transactions whose Action matches (e.g. Earn, Burn, Transfer).
2486
+ * @param params.excludeActions - (Optional) Exclude transactions whose Action matches.
2487
+ * @param params.includeTypes - (Optional) Only include transactions whose Type matches.
2488
+ * @param params.excludeTypes - (Optional) Exclude transactions whose Type matches.
2489
+ * @param params.options - (Optional) Additional options for the request.
2490
+ * @param requestOptions - (Optional) The request options.
2491
+ * @returns A promise that resolves to a service response containing an array of point history transactions.
2492
+ */
2493
+ history(params: {
2494
+ start: string;
2495
+ end: string;
2496
+ onlyVisible?: boolean;
2497
+ skip?: number;
2498
+ top?: number;
2499
+ sortType?: 'Asc' | 'Desc';
2500
+ units?: string;
2501
+ boxIds?: string;
2502
+ references?: string;
2503
+ transactionIds?: string;
2504
+ includeActions?: string;
2505
+ excludeActions?: string;
2506
+ includeTypes?: string;
2507
+ excludeTypes?: string;
2508
+ options?: {
2509
+ [key: string]: unknown;
2510
+ };
2511
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<PointHistory[]>>;
2512
+ }
2513
+
2400
2514
  declare class ProfileApi extends BaseService {
2401
2515
  constructor(client: AxiosInstance, baseUrl: string);
2402
2516
  /**
@@ -3138,6 +3252,7 @@ declare class BzbsService {
3138
3252
  notificationApi: NotificationApi;
3139
3253
  placeApi: PlaceApi;
3140
3254
  pointLogApi: PointLogApi;
3255
+ pointApi: PointApi;
3141
3256
  profileApi: ProfileApi;
3142
3257
  registerApi: RegistrationApi;
3143
3258
  addressApi: AddressApi;
@@ -3151,4 +3266,4 @@ declare class BzbsService {
3151
3266
  setLineUrl(lineUrl: string): this;
3152
3267
  }
3153
3268
 
3154
- export { type AccessTokenResponse, type Address, AddressApi, type ApiResponse, type AppleToken, AuthenticateApi, type Badge, BadgeApi, BaseService, Blob, type Buzzebees, type BzbsErrorResponse, BzbsService, type Campaign, CampaignApi, type CampaignDetail, type CartAccessResponse, CartApi, type CartCountResponse, type Category, CategoryApi, type ChatMessage, type ClientError, type ConfirmOtpResponse, type Consent, ConsentApi, type ConsentVersion, type ConsentVersionValue, CouponApi, type CouponResponse, type CouponResponseData, type CreateStampResponse, type CrossPlatformFile, type Dashboard, DashboardApi, type Detail, type District, type ErrorResponse, type ExpiringPoints, type FavoriteResponse, type ForgetPasswordResponse, HistoryApi, type LikeForumResponse, LineApi, type LineAuthResponse, type LoginResponse, type Maintenance, type Mission, type Notification, NotificationApi, type OtpResponse, type Picture, type Place, PlaceApi, type PlaceService, type PointLog, PointLogApi, type PointUnit, ProfileApi, type ProfileResponse, type Province, type Purchase, type RedeemResponse, RegistrationApi, type RegistrationResponse, RequestHelpApi, type RequestHelpCode, type RequestOptions, type ResumeResponse, type ServerError, type ServiceResponse, SettingApi, type Stamp, StampApi, type StampCampaign, type StampHistory, type StampProfileResponse, type StatusResponse, type Style, type SubCampaign, type SubCampaignStyle, type SubDistrict, type SuccessResponse, type Trace, type UpdatedPoints, type UseCampaignResponse, type ValidateOtpResponse, type Version, type ZipCode };
3269
+ export { type AccessTokenResponse, type Address, AddressApi, type ApiResponse, type AppleToken, AuthenticateApi, type Badge, BadgeApi, BaseService, Blob, type Buzzebees, type BzbsErrorResponse, BzbsService, type Campaign, CampaignApi, type CampaignDetail, type CartAccessResponse, CartApi, type CartCountResponse, type Category, CategoryApi, type ChatMessage, type ClientError, type ConfirmOtpResponse, type Consent, ConsentApi, type ConsentVersion, type ConsentVersionValue, CouponApi, type CouponResponse, type CouponResponseData, type CreateStampResponse, type CrossPlatformFile, type Dashboard, DashboardApi, type Detail, type District, type ErrorResponse, type ExpiringPoints, type FavoriteResponse, type ForgetPasswordResponse, HistoryApi, type LikeForumResponse, LineApi, type LineAuthResponse, type LoginResponse, type Maintenance, type Mission, type Notification, NotificationApi, type OtpResponse, type Picture, type Place, PlaceApi, type PlaceService, PointApi, type PointBalance, type PointHistory, type PointLog, PointLogApi, type PointUnit, ProfileApi, type ProfileResponse, type Province, type Purchase, type RedeemResponse, RegistrationApi, type RegistrationResponse, RequestHelpApi, type RequestHelpCode, type RequestOptions, type ResumeResponse, type ServerError, type ServiceResponse, SettingApi, type Stamp, StampApi, type StampCampaign, type StampHistory, type StampProfileResponse, type StatusResponse, type Style, type SubCampaign, type SubCampaignStyle, type SubDistrict, type SuccessResponse, type Trace, type UpdatedPoints, type UseCampaignResponse, type ValidateOtpResponse, type Version, type ZipCode };
package/dist/index.js CHANGED
@@ -73,6 +73,7 @@ __export(index_exports, {
73
73
  LineApi: () => LineApi,
74
74
  NotificationApi: () => NotificationApi,
75
75
  PlaceApi: () => PlaceApi,
76
+ PointApi: () => PointApi,
76
77
  PointLogApi: () => PointLogApi,
77
78
  ProfileApi: () => ProfileApi,
78
79
  RegistrationApi: () => RegistrationApi,
@@ -100,9 +101,26 @@ var BaseService = class {
100
101
  };
101
102
  }
102
103
  if (error.response && error.response.data) {
104
+ const data = error.response.data;
105
+ if (data["Success"]) {
106
+ return {
107
+ type: "server-error",
108
+ error: {
109
+ requestId: data.RequestId || "",
110
+ error: {
111
+ id: data.Code || data.code || error.response.status,
112
+ message: data.Message || data.message || error.response.statusText,
113
+ code: data.Code || data.code || error.response.status,
114
+ type: "buzzebees"
115
+ }
116
+ },
117
+ statusCode: error.response.status,
118
+ response: error.response
119
+ };
120
+ }
103
121
  return {
104
122
  type: "server-error",
105
- error: error.response.data,
123
+ error: data,
106
124
  statusCode: error.response.status,
107
125
  response: error.response
108
126
  };
@@ -1046,6 +1064,7 @@ var CampaignApi = class extends BaseService {
1046
1064
  * @param params.contactNumber - The contact number of the user.
1047
1065
  * @param params.options - Additional options for the redemption.
1048
1066
  * @param params.spPoints - Point Per Unit x Quantity (Donate only).
1067
+ * @param params.pointUnit - The point unit of the campaign (Point Service Only).
1049
1068
  * @param requestOptions - The options for the HTTP request.
1050
1069
  * @returns A promise that resolves to a service response containing the redeem response.
1051
1070
  */
@@ -1675,6 +1694,107 @@ var PointLogApi = class extends BaseService {
1675
1694
  }
1676
1695
  };
1677
1696
 
1697
+ // src/api/points/point-api.ts
1698
+ var PointApi = class extends BaseService {
1699
+ constructor(client, baseUrl) {
1700
+ super(client, baseUrl);
1701
+ }
1702
+ /**
1703
+ * Retrieves the current point balance for the authenticated user across the requested point units.
1704
+ *
1705
+ * @param params - The parameters for retrieving the point balance.
1706
+ * @param params.units - (Optional) Point unit codes (e.g. Point, Coin). Omit to use all units configured for the app.
1707
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
1708
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
1709
+ * @param params.options - (Optional) Additional options for the request.
1710
+ * @param requestOptions - (Optional) The request options.
1711
+ * @returns A promise that resolves to a service response containing an array of point balances.
1712
+ */
1713
+ balance(params, requestOptions) {
1714
+ return __async(this, null, function* () {
1715
+ return yield this.get(
1716
+ "point/balance",
1717
+ __spreadValues({
1718
+ units: params == null ? void 0 : params.units,
1719
+ boxIds: params == null ? void 0 : params.boxIds,
1720
+ onlyVisible: params == null ? void 0 : params.onlyVisible
1721
+ }, params == null ? void 0 : params.options),
1722
+ requestOptions
1723
+ );
1724
+ });
1725
+ }
1726
+ /**
1727
+ * Retrieves the point balance with Currents and Expires breakdowns keyed by date.
1728
+ *
1729
+ * @param params - The parameters for retrieving the point detail.
1730
+ * @param params.units - (Optional) Point unit codes (e.g. Point, Coin). Omit to use all units configured for the app.
1731
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
1732
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
1733
+ * @param params.options - (Optional) Additional options for the request.
1734
+ * @param requestOptions - (Optional) The request options.
1735
+ * @returns A promise that resolves to a service response containing an array of point balances with breakdowns.
1736
+ */
1737
+ detail(params, requestOptions) {
1738
+ return __async(this, null, function* () {
1739
+ return yield this.get(
1740
+ "point/detail",
1741
+ __spreadValues({
1742
+ units: params == null ? void 0 : params.units,
1743
+ boxIds: params == null ? void 0 : params.boxIds,
1744
+ onlyVisible: params == null ? void 0 : params.onlyVisible
1745
+ }, params == null ? void 0 : params.options),
1746
+ requestOptions
1747
+ );
1748
+ });
1749
+ }
1750
+ /**
1751
+ * Retrieves a paginated list of earn/burn/transfer transactions between start and end dates.
1752
+ *
1753
+ * @param params - The parameters for retrieving the point history.
1754
+ * @param params.start - Start of the range (inclusive), ISO-8601 with offset.
1755
+ * @param params.end - End of the range (inclusive), ISO-8601 with offset.
1756
+ * @param params.onlyVisible - (Optional) When true (default), only units marked visible for the app are considered.
1757
+ * @param params.skip - (Optional) Number of records to skip (offset pagination).
1758
+ * @param params.top - (Optional) Maximum number of records to return.
1759
+ * @param params.sortType - (Optional) Sort direction for Timestamp: Asc|Desc.
1760
+ * @param params.units - (Optional) Point unit codes to filter by.
1761
+ * @param params.boxIds - (Optional) Box (sub-bucket) identifiers to filter by.
1762
+ * @param params.references - (Optional) Filter by transaction reference.
1763
+ * @param params.transactionIds - (Optional) Filter by exact transaction IDs.
1764
+ * @param params.includeActions - (Optional) Only include transactions whose Action matches (e.g. Earn, Burn, Transfer).
1765
+ * @param params.excludeActions - (Optional) Exclude transactions whose Action matches.
1766
+ * @param params.includeTypes - (Optional) Only include transactions whose Type matches.
1767
+ * @param params.excludeTypes - (Optional) Exclude transactions whose Type matches.
1768
+ * @param params.options - (Optional) Additional options for the request.
1769
+ * @param requestOptions - (Optional) The request options.
1770
+ * @returns A promise that resolves to a service response containing an array of point history transactions.
1771
+ */
1772
+ history(params, requestOptions) {
1773
+ return __async(this, null, function* () {
1774
+ return yield this.get(
1775
+ "point/history",
1776
+ __spreadValues({
1777
+ start: params.start,
1778
+ end: params.end,
1779
+ onlyVisible: params.onlyVisible,
1780
+ skip: params.skip,
1781
+ top: params.top,
1782
+ sortType: params.sortType,
1783
+ units: params.units,
1784
+ boxIds: params.boxIds,
1785
+ references: params.references,
1786
+ transactionIds: params.transactionIds,
1787
+ includeActions: params.includeActions,
1788
+ excludeActions: params.excludeActions,
1789
+ includeTypes: params.includeTypes,
1790
+ excludeTypes: params.excludeTypes
1791
+ }, params.options),
1792
+ requestOptions
1793
+ );
1794
+ });
1795
+ }
1796
+ };
1797
+
1678
1798
  // src/api/profile/profile-api.ts
1679
1799
  var ProfileApi = class extends BaseService {
1680
1800
  constructor(client, baseUrl) {
@@ -2634,6 +2754,7 @@ var BzbsService = class {
2634
2754
  this.notificationApi = new NotificationApi(this.client, this.baseUrl);
2635
2755
  this.placeApi = new PlaceApi(this.client, this.baseUrl);
2636
2756
  this.pointLogApi = new PointLogApi(this.client, this.baseUrl);
2757
+ this.pointApi = new PointApi(this.client, this.baseUrl);
2637
2758
  this.profileApi = new ProfileApi(this.client, this.baseUrl);
2638
2759
  this.registerApi = new RegistrationApi(this.client, this.baseUrl);
2639
2760
  this.addressApi = new AddressApi(this.client, this.baseUrl);
@@ -2656,6 +2777,7 @@ var BzbsService = class {
2656
2777
  this.notificationApi.setBaseUrl(baseUrl);
2657
2778
  this.placeApi.setBaseUrl(baseUrl);
2658
2779
  this.pointLogApi.setBaseUrl(baseUrl);
2780
+ this.pointApi.setBaseUrl(baseUrl);
2659
2781
  this.profileApi.setBaseUrl(baseUrl);
2660
2782
  this.registerApi.setBaseUrl(baseUrl);
2661
2783
  this.addressApi.setBaseUrl(baseUrl);
@@ -2692,6 +2814,7 @@ var BzbsService = class {
2692
2814
  LineApi,
2693
2815
  NotificationApi,
2694
2816
  PlaceApi,
2817
+ PointApi,
2695
2818
  PointLogApi,
2696
2819
  ProfileApi,
2697
2820
  RegistrationApi,