buymeua-api-fe 0.9.3 → 0.10.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. package/CHANGELOG.md +185 -0
  2. package/README.md +32 -0
  3. package/dist/entities/ad/api/adApi.d.ts +61 -181
  4. package/dist/entities/ad/api/adApi.d.ts.map +1 -1
  5. package/dist/entities/ad/model/types.d.ts +3 -3
  6. package/dist/entities/ad/model/types.d.ts.map +1 -1
  7. package/dist/entities/auth/api/authApi.d.ts +6 -6
  8. package/dist/entities/auth/api/authApi.d.ts.map +1 -1
  9. package/dist/entities/auth/api/authApi.js.map +1 -1
  10. package/dist/entities/auth/model/types.d.ts +0 -3
  11. package/dist/entities/auth/model/types.d.ts.map +1 -1
  12. package/dist/entities/cart/api/cartApi.d.ts +78 -198
  13. package/dist/entities/cart/api/cartApi.d.ts.map +1 -1
  14. package/dist/entities/cart/api/cartApi.js +1 -1
  15. package/dist/entities/cart/api/cartApi.js.map +1 -1
  16. package/dist/entities/cart/model/types.d.ts +3 -6
  17. package/dist/entities/cart/model/types.d.ts.map +1 -1
  18. package/dist/entities/chat/api/chatApi.d.ts.map +1 -1
  19. package/dist/entities/chat/api/chatApi.js.map +1 -1
  20. package/dist/entities/chat/model/types.d.ts +0 -1
  21. package/dist/entities/chat/model/types.d.ts.map +1 -1
  22. package/dist/entities/customer/api/customerApi.d.ts +3 -3
  23. package/dist/entities/customer/api/customerApi.d.ts.map +1 -1
  24. package/dist/entities/customer/api/customerApi.js.map +1 -1
  25. package/dist/entities/customer/model/types.d.ts +0 -2
  26. package/dist/entities/customer/model/types.d.ts.map +1 -1
  27. package/dist/entities/favorite/api/favoriteApi.d.ts +22 -30
  28. package/dist/entities/favorite/api/favoriteApi.d.ts.map +1 -1
  29. package/dist/entities/favorite/api/favoriteApi.js +1 -1
  30. package/dist/entities/favorite/api/favoriteApi.js.map +1 -1
  31. package/dist/entities/favorite/model/types.d.ts +0 -2
  32. package/dist/entities/favorite/model/types.d.ts.map +1 -1
  33. package/dist/entities/notification/api/notificationApi.d.ts +40 -40
  34. package/dist/entities/notification/api/notificationApi.d.ts.map +1 -1
  35. package/dist/entities/notification/api/notificationApi.js +4 -4
  36. package/dist/entities/notification/api/notificationApi.js.map +1 -1
  37. package/dist/entities/notification/model/types.d.ts +0 -4
  38. package/dist/entities/notification/model/types.d.ts.map +1 -1
  39. package/dist/entities/novaposhta/api/novaposhtaApi.d.ts +181 -1141
  40. package/dist/entities/novaposhta/api/novaposhtaApi.d.ts.map +1 -1
  41. package/dist/entities/novaposhta/model/types.d.ts +19 -19
  42. package/dist/entities/novaposhta/model/types.d.ts.map +1 -1
  43. package/dist/entities/product/api/productApi.d.ts +1159 -523
  44. package/dist/entities/product/api/productApi.d.ts.map +1 -1
  45. package/dist/entities/product/api/productApi.js +22 -1
  46. package/dist/entities/product/api/productApi.js.map +1 -1
  47. package/dist/entities/product/model/types.d.ts +94 -13
  48. package/dist/entities/product/model/types.d.ts.map +1 -1
  49. package/dist/entities/referral/api/referralApi.d.ts +60 -60
  50. package/dist/entities/store/model/types.d.ts +2 -0
  51. package/dist/entities/store/model/types.d.ts.map +1 -1
  52. package/dist/entities/stories/api/storiesApi.d.ts +61 -301
  53. package/dist/entities/stories/api/storiesApi.d.ts.map +1 -1
  54. package/dist/entities/stories/model/types.d.ts +5 -5
  55. package/dist/entities/stories/model/types.d.ts.map +1 -1
  56. package/dist/entities/supplier/api/supplierApi.d.ts +4 -4
  57. package/dist/entities/supplier/api/supplierApi.d.ts.map +1 -1
  58. package/dist/entities/supplier/api/supplierApi.js.map +1 -1
  59. package/dist/entities/supplier/model/types.d.ts +0 -1
  60. package/dist/entities/supplier/model/types.d.ts.map +1 -1
  61. package/package.json +3 -2
package/CHANGELOG.md ADDED
@@ -0,0 +1,185 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ ## [Unreleased]
9
+
10
+ ## [0.10.1] - 2025-11-26
11
+
12
+ ### Added
13
+
14
+ - Include CHANGELOG.md in published npm package
15
+
16
+ ## [0.10.0] - 2025-11-26
17
+
18
+ ### Added
19
+
20
+ - Add supplier products endpoints (getSupplierProducts, getSupplierProductDetails)
21
+ - Add supplier product types (GetSupplierProductsRequest, SupplierProductDetails, ProductAttribute)
22
+ - Add TODO markers for duplicate endpoints (getProduct/getProductById)
23
+ - Add Countries API documentation to README (useGetCountriesInfiniteQuery)
24
+
25
+ ### Changed
26
+
27
+ - Improve GetProductsRequest type - specify exact price_type values
28
+ - Add TODO for GetProductDetailsRequest refactoring
29
+ - Exclude dist directory from ESLint linting
30
+ - **BREAKING**: Replace undefined with void in RTK Query request parameters
31
+ - Affected endpoints: registerGuest, logout, deleteCustomerAccount, getCartCount,
32
+ getFavoriteCount, getNotificationsCount, getNewSuppliersCount,
33
+ markAllNotificationsAsRead, deleteAllNotifications
34
+ - Affected optional parameters: getAdPlatforms, getReferralStatistics, getStories
35
+ - Migration: Remove explicit undefined arguments from hook calls
36
+ - Example: `useGetCartCountQuery()` instead of `useGetCartCountQuery(undefined)`
37
+ - Remove useless undefined type aliases across multiple modules
38
+ - auth: LogoutRequest, LogoutResponse, RegisterGuestRequest
39
+ - customer: DeleteCustomerAccountRequest, DeleteCustomerAccountResponse
40
+ - cart: GetCartCountRequest, RemoveItemFromCartResponse, RemoveMerchantFromCartResponse
41
+ - supplier: MarkSupplierAsOldResponse
42
+ - notification: GetNotificationsCountRequest, GetNewSuppliersCountRequest,
43
+ MarkAllNotificationsAsReadRequest, DeleteAllNotificationsRequest
44
+ - favorite: GetFavoriteCountRequest, DeleteFavoriteMerchantItemResponse
45
+ - chat: DeleteChatMessageResponse
46
+ - All replaced with inline undefined in RTK Query endpoints
47
+ - Replace `Partial<{}>` type aliases with interface definitions using optional properties
48
+ - ad: GetAdPlatformsRequest
49
+ - cart: GetCartMerchantsRequest
50
+ - novaposhta: GetNovaposhtaCitiesRequest, GetNovaposhtaStreetsRequest, GetNovaposhtaWarehousesRequest
51
+ - product: GetProductsByQrRequest, GetBestsellersRequest
52
+ - stories: GetStoriesRequest
53
+
54
+ ## [0.9.3] - 2025-11-24
55
+
56
+ ### Added
57
+
58
+ - Enhance Store interfaces with additional properties and types
59
+
60
+ ## [0.9.2] - 2025-11-20
61
+
62
+ ### Fixed
63
+
64
+ - Missing build
65
+
66
+ ## [0.9.1] - 2025-11-20
67
+
68
+ ### Fixed
69
+
70
+ - Correct URL for bestsellers endpoint
71
+
72
+ ## [0.9.0] - 2025-11-20
73
+
74
+ ### Added
75
+
76
+ - Add registerGuest mutation and types for guest registration
77
+ - Extend GetProductsRequest with attribute_filter and filter_product_ids
78
+
79
+ ### Changed
80
+
81
+ - Update CHANGELOG.md
82
+ - Update README.md
83
+
84
+ ## [0.8.0] - 2025-11-18
85
+
86
+ ### Added
87
+
88
+ - Add customer api, account management endpoints and types
89
+
90
+ ### Changed
91
+
92
+ - Update CHANGELOG.md
93
+ - Update README.md
94
+
95
+ ## [0.7.0] - 2025-11-18
96
+
97
+ ### Added
98
+
99
+ - Add getStoreArticles endpoint and related types
100
+
101
+ ### Changed
102
+
103
+ - Update CHANGELOG.md
104
+ - Update README.md
105
+
106
+ ## [0.6.0] - 2025-11-17
107
+
108
+ ### Changed
109
+
110
+ - Update CHANGELOG.md
111
+ - Update StorePhone interface
112
+
113
+ ## [0.5.0] - 2025-11-14
114
+
115
+ ### Added
116
+
117
+ - Implement getStoreInfo endpoint and related types
118
+
119
+ ### Changed
120
+
121
+ - Update README.md
122
+ - Update CHANGELOG.md
123
+
124
+ ## [0.4.0] - 2025-11-14
125
+
126
+ ### Added
127
+
128
+ - Add logout endpoint
129
+
130
+ ### Changed
131
+
132
+ - Update README.md
133
+ - Update CHANGELOG.md
134
+ - Update ESLint and TypeScript dependencies to latest versions
135
+
136
+ ## [0.3.0] - 2025-11-07
137
+
138
+ ### Added
139
+
140
+ - Add country API
141
+
142
+ ### Changed
143
+
144
+ - Add ESLint rule for unused variables
145
+ - Update CHANGELOG.md
146
+
147
+ ## [0.2.0] - 2025-11-06
148
+
149
+ ### Changed
150
+
151
+ - Move @reduxjs/toolkit to peerDependencies. @reduxjs/toolkit is now a peer dependency and must be installed separately by the user
152
+
153
+ ## [0.1.1] - 2025-11-05
154
+
155
+ ### Changed
156
+
157
+ - Bump version
158
+ - Update README
159
+
160
+ ### Fixed
161
+
162
+ - Add missing export isValidationError and ValidationError type from shared/api
163
+
164
+ ## [0.1.0] - 2025-11-05
165
+
166
+ ### Added
167
+
168
+ - Create CHANGELOG.md to document project updates
169
+ - Add ValidationError interface and related utility functions
170
+ - Extract getNextPageParam function for reusable pagination logic across APIs
171
+ - Replace PaginationLinks and PaginationMeta with PaginatedResponse in various entities
172
+
173
+ ### Changed
174
+
175
+ - Bump version
176
+ - Update README
177
+
178
+ ## [0.0.1] - 2025-11-04
179
+
180
+ ### Added
181
+
182
+ -
183
+
184
+ [unreleased]: https://github.com/olivierlacan/keep-a-changelog/compare/[latest version / v1.1.1]...HEAD
185
+ [0.0.1]: https://github.com/[username]/[repository]/releases/tag/v0.0.1
package/README.md CHANGED
@@ -157,6 +157,28 @@ const { data } = useGetBestSellersQuery({
157
157
 
158
158
  // Get product details
159
159
  const { data } = useGetProductDetailsQuery({ product: number });
160
+
161
+ // Get supplier products with infinite scroll
162
+ const { data, fetchNextPage, hasNextPage } = useGetSupplierProductsInfiniteQuery({
163
+ core_filter?: string;
164
+ category_filter?: number[];
165
+ buyme_category_filter?: number[];
166
+ filter_buyme_category_set_main_category?: boolean;
167
+ filter_customer_id?: number;
168
+ filter_advertised?: boolean;
169
+ only_in_root_category?: boolean;
170
+ option_value_filter?: {
171
+ option_value_ids?: number[];
172
+ warehouse_ids?: number[];
173
+ };
174
+ price_from?: number;
175
+ price_to?: number;
176
+ per_page?: number;
177
+ price_type?: 'price' | 'price_drop';
178
+ });
179
+
180
+ // Get supplier product details
181
+ const { data } = useGetSupplierProductDetailsQuery({ id: number });
160
182
  ```
161
183
 
162
184
  ### Cart
@@ -596,6 +618,16 @@ const { data, fetchNextPage, hasNextPage } = useGetAdPlatformsInfiniteQuery({
596
618
  });
597
619
  ```
598
620
 
621
+ ### Countries
622
+
623
+ ```typescript
624
+ // Get countries list
625
+ const { data, fetchNextPage, hasNextPage } = useGetCountriesInfiniteQuery({
626
+ search?: string;
627
+ per_page?: number;
628
+ });
629
+ ```
630
+
599
631
  ### Store
600
632
 
601
633
  ```typescript