@bzbs/react-api-client 0.0.21 → 0.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
@@ -1914,6 +1914,512 @@ declare class RegistrationApi extends BaseService {
1914
1914
  }, requestOptions?: RequestOptions): Promise<ServiceResponse<RegistrationResponse>>;
1915
1915
  }
1916
1916
 
1917
+ interface ZipCode {
1918
+ cityId?: string;
1919
+ subDistrictCode?: string;
1920
+ subDistrictName?: string;
1921
+ subDistrictNameEN?: string;
1922
+ zipCode?: string;
1923
+ districtCode?: string;
1924
+ districtName?: string;
1925
+ districtNameEN?: string;
1926
+ provinceCode?: string;
1927
+ provinceName?: string;
1928
+ provinceNameEN?: string;
1929
+ active?: boolean;
1930
+ createDate?: number;
1931
+ createBy?: string;
1932
+ modifyDate?: number;
1933
+ modifyBy?: string;
1934
+ zone?: string;
1935
+ }
1936
+
1937
+ interface Address {
1938
+ active?: boolean;
1939
+ isDefault?: boolean;
1940
+ isDefaultTax?: boolean;
1941
+ createDate?: number;
1942
+ modifyDate?: number;
1943
+ addressName?: string;
1944
+ title?: string;
1945
+ firstName?: string;
1946
+ lastName?: string;
1947
+ name?: string;
1948
+ companyName?: string;
1949
+ contactNumber?: string;
1950
+ homeContactNumber?: string;
1951
+ alternateContactNumber?: string;
1952
+ email?: string;
1953
+ idCard?: any;
1954
+ type?: any;
1955
+ address?: any;
1956
+ village?: string;
1957
+ building?: any;
1958
+ number?: any;
1959
+ moo?: any;
1960
+ room?: any;
1961
+ floor?: any;
1962
+ soi?: string;
1963
+ city?: string;
1964
+ road?: string;
1965
+ subDistrictCode?: number;
1966
+ subDistrictName?: string;
1967
+ districtCode?: number;
1968
+ districtName?: string;
1969
+ provinceCode?: number;
1970
+ provinceName?: string;
1971
+ countryId?: number;
1972
+ countryCode?: number;
1973
+ countryName?: string;
1974
+ zipcode?: any;
1975
+ remark?: any;
1976
+ landmark?: any;
1977
+ latitude?: any;
1978
+ longitude?: any;
1979
+ isTax?: boolean;
1980
+ taxName?: string;
1981
+ taxId?: any;
1982
+ taxAddressName?: string;
1983
+ taxNumber?: string;
1984
+ taxSoi?: any;
1985
+ taxSubDistrictCode?: number;
1986
+ taxSubDistrictName?: string;
1987
+ taxDistrictCode?: number;
1988
+ taxDistrictName?: string;
1989
+ taxProvinceCode?: number;
1990
+ taxProvinceName?: string;
1991
+ taxZipcode?: any;
1992
+ taxDetail?: any;
1993
+ personType?: string;
1994
+ branchName?: string;
1995
+ blockNumber?: any;
1996
+ house?: any;
1997
+ street?: string;
1998
+ ward?: any;
1999
+ greaterArea?: any;
2000
+ state?: any;
2001
+ customInfo1?: any;
2002
+ customInfo2?: any;
2003
+ customInfo3?: any;
2004
+ customInfo4?: any;
2005
+ customInfo5?: any;
2006
+ extra?: any;
2007
+ partitionKey?: string;
2008
+ rowKey?: string;
2009
+ timestamp?: number;
2010
+ eTag?: string;
2011
+ }
2012
+
2013
+ declare class AddressApi extends BaseService {
2014
+ constructor(client: AxiosInstance, baseUrl: string);
2015
+ /**
2016
+ * Get information of zip code
2017
+ *
2018
+ * @param zipCode - Zip code
2019
+ * @param requestOptions - Optional request options
2020
+ * @returns A promise that resolves to a service response containing an array of ZipCode objects
2021
+ */
2022
+ zipCodes(params: {
2023
+ zipCode?: string;
2024
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ZipCode[]>>;
2025
+ /**
2026
+ * Get list of Thailand province
2027
+ *
2028
+ * @param requestOptions - Optional request options
2029
+ * @returns A promise that resolves to a service response containing an array of ZipCode objects
2030
+ */
2031
+ provinces(requestOptions?: RequestOptions): Promise<ServiceResponse<ZipCode[]>>;
2032
+ /**
2033
+ * Get list of Thailand district
2034
+ *
2035
+ * @param provinceCode - Province code
2036
+ * @param requestOptions - Optional request options
2037
+ * @returns A promise that resolves to a service response containing an array of ZipCode objects
2038
+ */
2039
+ districts(params: {
2040
+ provinceCode?: string;
2041
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ZipCode[]>>;
2042
+ /**
2043
+ * Get list of Thailand sub district
2044
+ *
2045
+ * @param provinceCode - Province code
2046
+ * @param districtCode - District code
2047
+ * @param requestOptions - Optional request options
2048
+ * @returns A promise that resolves to a service response containing an array of ZipCode objects
2049
+ */
2050
+ subDistricts(params: {
2051
+ provinceCode?: string;
2052
+ districtCode?: string;
2053
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ZipCode[]>>;
2054
+ /**
2055
+ * Get user addresses
2056
+ *
2057
+ * @param requestOptions - Optional request options
2058
+ * @returns A promise that resolves to a service response containing an array of Address objects
2059
+ */
2060
+ userAddresses(requestOptions?: RequestOptions): Promise<ServiceResponse<Address[]>>;
2061
+ /**
2062
+ * Update user address
2063
+ *
2064
+ * @param params - The parameters for updating the address
2065
+ * @param requestOptions - Optional request options
2066
+ * @returns A promise that resolves to a service response containing the updated Address object
2067
+ */
2068
+ updateAddress(params: {
2069
+ addressName?: string;
2070
+ firstName?: string;
2071
+ lastName?: string;
2072
+ address?: string;
2073
+ zipcode?: string;
2074
+ provinceCode?: string;
2075
+ provinceName?: string;
2076
+ districtCode?: string;
2077
+ districtName?: string;
2078
+ subDistrictCode?: string;
2079
+ subDistrictName?: string;
2080
+ contactNumber?: string;
2081
+ countryCode?: string;
2082
+ countryName?: string;
2083
+ isDefault?: boolean;
2084
+ rowKey?: string;
2085
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<Address>>;
2086
+ /**
2087
+ * Delete user address
2088
+ *
2089
+ * @param rowKey - Row key
2090
+ * @param requestOptions - Optional request options
2091
+ * @returns A promise that resolves to a service response containing the result of the deletion
2092
+ */
2093
+ deleteAddress(params: {
2094
+ rowKey?: string;
2095
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
2096
+ /**
2097
+ * Get user tax addresses
2098
+ *
2099
+ * @param requestOptions - Optional request options
2100
+ * @returns A promise that resolves to a service response containing an array of Address objects
2101
+ */
2102
+ userTaxAddresses(requestOptions?: RequestOptions): Promise<ServiceResponse<Address[]>>;
2103
+ /**
2104
+ * Update user tax address
2105
+ *
2106
+ * @param params - The parameters for updating the tax address
2107
+ * @param requestOptions - Optional request options
2108
+ * @returns A promise that resolves to a service response containing the updated Address object
2109
+ */
2110
+ updateTaxAddress(params: {
2111
+ rowKey?: string;
2112
+ taxId?: string;
2113
+ isDefault?: boolean;
2114
+ personType?: string;
2115
+ title?: string;
2116
+ firstName?: string;
2117
+ lastName?: string;
2118
+ email?: string;
2119
+ contactNumber?: string;
2120
+ companyName?: string;
2121
+ address?: string;
2122
+ addressName?: string;
2123
+ floor?: string;
2124
+ building?: string;
2125
+ moo?: string;
2126
+ road?: string;
2127
+ room?: string;
2128
+ soi?: string;
2129
+ village?: string;
2130
+ districtCode?: string;
2131
+ districtName?: string;
2132
+ provinceCode?: string;
2133
+ provinceName?: string;
2134
+ subDistrictCode?: string;
2135
+ subDistrictName?: string;
2136
+ zipCode?: string;
2137
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<Address>>;
2138
+ /**
2139
+ * Delete user tax address
2140
+ *
2141
+ * @param rowKey - Row key
2142
+ * @param requestOptions - Optional request options
2143
+ * @returns A promise that resolves to a service response containing the result of the deletion
2144
+ */
2145
+ deleteTaxAddress(params: {
2146
+ rowKey?: string;
2147
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<any>>;
2148
+ }
2149
+
2150
+ interface CreateStampResponse {
2151
+ success?: boolean;
2152
+ balance?: number;
2153
+ cardId?: string;
2154
+ userId?: string;
2155
+ imei?: string;
2156
+ appId?: string;
2157
+ issuer?: string;
2158
+ stampId?: string;
2159
+ sponsorId?: number;
2160
+ }
2161
+
2162
+ interface Stamp {
2163
+ amount?: number;
2164
+ agencyId?: number;
2165
+ cardId?: string;
2166
+ issuer?: string;
2167
+ stampId?: string;
2168
+ imageUrl?: string;
2169
+ owner?: string;
2170
+ timestamp?: number;
2171
+ active?: boolean;
2172
+ name?: string;
2173
+ description?: string;
2174
+ stampImageUrl?: string;
2175
+ maxQuantity?: number;
2176
+ currentQuantity?: number;
2177
+ pricePerStamp?: number;
2178
+ codeExpireIn?: number;
2179
+ stampRawScore?: number;
2180
+ stampScore?: number;
2181
+ stampSpecialScore?: number;
2182
+ }
2183
+
2184
+ interface StampProfileResponse {
2185
+ id?: string;
2186
+ agencyId?: number;
2187
+ cardId?: string;
2188
+ name?: string;
2189
+ description?: string;
2190
+ imageUrl?: string;
2191
+ backgroundUrl?: string;
2192
+ maxQuantity?: number;
2193
+ currentQuantity?: number;
2194
+ expireDate?: number;
2195
+ pricePerStamp?: number;
2196
+ otherPromotions?: any;
2197
+ otherStamps?: Stamp[];
2198
+ campaigns?: StampCampaign[];
2199
+ history?: StampHistory[];
2200
+ }
2201
+ interface StampCampaign {
2202
+ id?: number;
2203
+ imgUrl?: string;
2204
+ qty?: number;
2205
+ }
2206
+ interface StampHistory {
2207
+ amount?: number;
2208
+ terminalId?: string;
2209
+ branchId?: string;
2210
+ branchName?: string;
2211
+ brandId?: string;
2212
+ customerId?: string;
2213
+ customerName?: any;
2214
+ campaignId?: any;
2215
+ description?: string;
2216
+ issuer?: string;
2217
+ issuerName?: string;
2218
+ imageUrl?: string;
2219
+ merchant?: string;
2220
+ merchantName?: string;
2221
+ status?: number;
2222
+ timestamp?: number;
2223
+ type?: string;
2224
+ stampCount?: number;
2225
+ createDate?: number;
2226
+ name?: string;
2227
+ backgroundUrl?: string;
2228
+ }
2229
+
2230
+ declare class StampApi extends BaseService {
2231
+ constructor(client: AxiosInstance, baseUrl: string);
2232
+ /**
2233
+ * Create stamp
2234
+ *
2235
+ * @param params - The parameters for creating the stamp
2236
+ * @param requestOptions - Optional request options
2237
+ * @returns A promise that resolves to a service response containing the created stamp response
2238
+ */
2239
+ createStamp(params: {
2240
+ imei?: string;
2241
+ issuer?: string;
2242
+ os?: string;
2243
+ platform?: string;
2244
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<CreateStampResponse>>;
2245
+ /**
2246
+ * Get list of stamps
2247
+ *
2248
+ * @param requestOptions - Optional request options
2249
+ * @returns A promise that resolves to a service response containing an array of stamps
2250
+ */
2251
+ stamps(requestOptions?: RequestOptions): Promise<ServiceResponse<Stamp[]>>;
2252
+ /**
2253
+ * Get stamp info
2254
+ *
2255
+ * @param id - Stamp id
2256
+ * @param cardId - Card Id
2257
+ * @param requestOptions - Optional request options
2258
+ * @returns A promise that resolves to a service response containing the stamp profile response
2259
+ */
2260
+ stampProfile(params: {
2261
+ id: string;
2262
+ cardId: string;
2263
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<StampProfileResponse>>;
2264
+ }
2265
+
2266
+ interface RequestHelpCode {
2267
+ code?: string;
2268
+ }
2269
+
2270
+ interface ChatMessage {
2271
+ userId?: string;
2272
+ name?: string;
2273
+ message?: string;
2274
+ placeId?: any;
2275
+ placeName?: any;
2276
+ imageUrl?: any;
2277
+ rating?: any;
2278
+ postId?: any;
2279
+ width?: number;
2280
+ height?: number;
2281
+ photoId?: any;
2282
+ type?: string;
2283
+ agencyId?: any;
2284
+ agencyName?: any;
2285
+ likes?: number;
2286
+ isLiked?: boolean;
2287
+ isApproved?: boolean;
2288
+ isReply?: boolean;
2289
+ sticker?: any;
2290
+ commentCount?: number;
2291
+ latestCommentDate?: any;
2292
+ latestCommentBy?: any;
2293
+ latestAdminCommentDate?: any;
2294
+ latestAdminGroupId?: any;
2295
+ latestAdminCommentBy?: any;
2296
+ subject?: any;
2297
+ isRead?: boolean;
2298
+ isHidden?: boolean;
2299
+ readCount?: number;
2300
+ unReadCount?: number;
2301
+ hiddenCount?: number;
2302
+ createdTime?: number;
2303
+ buzzKey?: string;
2304
+ appId?: string;
2305
+ os?: any;
2306
+ locationAgencyId?: any;
2307
+ campaignId?: any;
2308
+ lineChannelId?: any;
2309
+ lineChatRoomId?: any;
2310
+ lineUserId?: any;
2311
+ lineProfileDisplayName?: any;
2312
+ lineProfilePictureUrl?: any;
2313
+ lineChatRepliedRoomAdminGroupId?: any;
2314
+ lineChatRepliedRoomAdminId?: any;
2315
+ lineChatRepliedRoomPartitionKey?: any;
2316
+ lineChatRepliedRoomRowKey?: any;
2317
+ lineChatMessagePartitionKey?: any;
2318
+ lineChatMessageRowKey?: any;
2319
+ lineChatMessageEventTimestamp?: any;
2320
+ lineChatMessageUtcDate?: any;
2321
+ lineChatMessageJson?: any;
2322
+ partitionKey?: string;
2323
+ rowKey?: string;
2324
+ timestamp?: number;
2325
+ eTag?: string;
2326
+ }
2327
+
2328
+ interface LikeForumResponse {
2329
+ result?: boolean;
2330
+ }
2331
+
2332
+ declare class ForumApi extends BaseService {
2333
+ constructor(client: AxiosInstance, baseUrl: string);
2334
+ /**
2335
+ * Get help code
2336
+ *
2337
+ * @param params - The parameters for getting the help code
2338
+ * @param requestOptions - Optional request options
2339
+ * @returns A promise that resolves to a service response containing the help code
2340
+ */
2341
+ helpCode(params: {
2342
+ os: string;
2343
+ platform: string;
2344
+ clientVersion: string;
2345
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<RequestHelpCode>>;
2346
+ /**
2347
+ * Get request help list
2348
+ *
2349
+ * @param params - The parameters for getting the request help list
2350
+ * @param requestOptions - Optional request options
2351
+ * @returns A promise that resolves to a service response containing a list of chat messages
2352
+ */
2353
+ requestHelpList(params: {
2354
+ requestId: string;
2355
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ChatMessage[]>>;
2356
+ /**
2357
+ * Get request help detail
2358
+ *
2359
+ * @param params - The parameters for getting the request help detail
2360
+ * @param requestOptions - Optional request options
2361
+ * @returns A promise that resolves to a service response containing a chat message
2362
+ */
2363
+ requestDetail(params: {
2364
+ buzzKey: string;
2365
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ChatMessage>>;
2366
+ /**
2367
+ * Create request help
2368
+ *
2369
+ * @param params - The parameters for creating the request help
2370
+ * @param requestOptions - Optional request options
2371
+ * @returns A promise that resolves to a service response containing a chat message
2372
+ */
2373
+ postRequestHelp(params: {
2374
+ requestId: string;
2375
+ message: string;
2376
+ image?: File;
2377
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ChatMessage>>;
2378
+ /**
2379
+ * Get comment list
2380
+ *
2381
+ * @param params - The parameters for getting the comment list
2382
+ * @param requestOptions - Optional request options
2383
+ * @returns A promise that resolves to a service response containing a list of chat messages
2384
+ */
2385
+ comments(params: {
2386
+ buzzKey: string;
2387
+ lastRowKey?: string;
2388
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ChatMessage[]>>;
2389
+ /**
2390
+ * Create comment
2391
+ *
2392
+ * @param params - The parameters for creating the comment
2393
+ * @param requestOptions - Optional request options
2394
+ * @returns A promise that resolves to a service response containing a chat message
2395
+ */
2396
+ postComment(params: {
2397
+ buzzKey: string;
2398
+ message: string;
2399
+ image?: File;
2400
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<ChatMessage>>;
2401
+ /**
2402
+ * Like/Unlike forum
2403
+ *
2404
+ * @param params - The parameters for liking the forum
2405
+ * @param requestOptions - Optional request options
2406
+ * @returns A promise that resolves to a service response containing the like forum response
2407
+ */
2408
+ likeForum(params: {
2409
+ buzzKey: string;
2410
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<LikeForumResponse>>;
2411
+ /**
2412
+ * Unlike forum
2413
+ *
2414
+ * @param params - The parameters for unliking the forum
2415
+ * @param requestOptions - Optional request options
2416
+ * @returns A promise that resolves to a service response containing the like forum response
2417
+ */
2418
+ unlikeForum(params: {
2419
+ buzzKey: string;
2420
+ }, requestOptions?: RequestOptions): Promise<ServiceResponse<LikeForumResponse>>;
2421
+ }
2422
+
1917
2423
  declare class BzbsService {
1918
2424
  client: AxiosInstance;
1919
2425
  baseUrl: string;
@@ -1933,7 +2439,10 @@ declare class BzbsService {
1933
2439
  pointLogApi: PointLogApi;
1934
2440
  profileApi: ProfileApi;
1935
2441
  registerApi: RegistrationApi;
2442
+ addressApi: AddressApi;
2443
+ stampApi: StampApi;
2444
+ forumApi: ForumApi;
1936
2445
  constructor(client: AxiosInstance, baseUrl: string, baseLineUrl: string);
1937
2446
  }
1938
2447
 
1939
- export { type Badge, BaseService, type Buzzebees, type BzbsErrorResponse, BzbsService, type Campaign, type CampaignDetail, type CartAccessResponse, type CartCountResponse, type Category, type ConfirmOtpResponse, type Consent, type CouponResponse, type CouponResponseData, type Dashboard, type Detail, type ExpiringPoints, type FavoriteResponse, type ForgetPasswordResponse, type LineAuthResponse, type LoginResponse, type Mission, type Notification, type OtpResponse, type Picture, type Place, type PlaceService, type PointLog, type ProfileResponse, type Purchase, type RedeemResponse, type RegistrationResponse, type RequestOptions, type ResumeResponse, type ServiceResponse, type StatusResponse, type Style, type SubCampaign, type SubCampaignStyle, type Trace, type UpdatedPoints, type UseCampaignResponse, type ValidateOtpResponse, type Version };
2448
+ export { type Badge, BaseService, type Buzzebees, type BzbsErrorResponse, BzbsService, type Campaign, type CampaignDetail, type CartAccessResponse, type CartCountResponse, type Category, type ClientError, type ConfirmOtpResponse, type Consent, type CouponResponse, type CouponResponseData, type Dashboard, type Detail, type ErrorResponse, type ExpiringPoints, type FavoriteResponse, type ForgetPasswordResponse, type LineAuthResponse, type LoginResponse, type Mission, type Notification, type OtpResponse, type Picture, type Place, type PlaceService, type PointLog, type ProfileResponse, type Purchase, type RedeemResponse, type RegistrationResponse, type RequestOptions, type ResumeResponse, type ServerError, type ServiceResponse, type StatusResponse, type Style, type SubCampaign, type SubCampaignStyle, type SuccessResponse, type Trace, type UpdatedPoints, type UseCampaignResponse, type ValidateOtpResponse, type Version };