@djust-b2b/djust-front-sdk 1.15.0 → 1.15.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.
- package/lib/index.d.ts +7 -7
- package/lib/services/auth/definitions.requests.d.ts +21 -0
- package/lib/services/auth/definitions.requests.js +2 -0
- package/lib/services/auth/index.d.ts +14 -4
- package/lib/services/auth/index.js +12 -3
- package/lib/services/cart/index.d.ts +0 -5
- package/lib/services/cart/index.js +0 -5
- package/lib/services/custom-field/index.d.ts +5 -10
- package/lib/services/custom-field/index.js +5 -15
- package/lib/services/customer-user/index.d.ts +107 -125
- package/lib/services/customer-user/index.js +107 -125
- package/lib/services/navigation-category/index.d.ts +68 -119
- package/lib/services/navigation-category/index.js +68 -119
- package/lib/services/product/index.d.ts +296 -1687
- package/lib/services/product/index.js +312 -1706
- package/lib/services/product-variant/index.d.ts +53 -160
- package/lib/services/product-variant/index.js +53 -160
- package/package.json +1 -1
|
@@ -1,9 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* @packageDocumentation
|
|
4
|
-
*
|
|
5
|
-
* @document documents/customer-user.md
|
|
6
|
-
*/
|
|
7
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
3
|
exports.getAuthenticatedUser = getAuthenticatedUser;
|
|
9
4
|
exports.createCustomerUser = createCustomerUser;
|
|
@@ -15,19 +10,27 @@ exports.sendCustomerUserActivationRequest = sendCustomerUserActivationRequest;
|
|
|
15
10
|
const parameters_validation_1 = require("../../helpers/parameters-validation");
|
|
16
11
|
const fetch_instance_1 = require("../../settings/fetch-instance");
|
|
17
12
|
/**
|
|
18
|
-
*
|
|
13
|
+
* 🚚 **Retrieve Authenticated User**
|
|
14
|
+
*
|
|
15
|
+
* **APICODE(USER-500)**
|
|
19
16
|
* Retrieves the authenticated user.
|
|
20
17
|
*
|
|
21
18
|
* This function sends a request to obtain the details of the currently authenticated user.
|
|
22
19
|
*
|
|
23
|
-
*
|
|
20
|
+
* 🛠 **Endpoint**: `GET /v1/authenticated-user`
|
|
21
|
+
*
|
|
22
|
+
* | Parameter | Type | Required | Description |
|
|
23
|
+
* |-----------|--------|----------|---------------------------|
|
|
24
|
+
* | N/A | N/A | N/A | This function does not require any parameters. |
|
|
24
25
|
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
26
|
+
* 📤 **Returns**:
|
|
27
|
+
* A `Promise` resolving to an object containing the authenticated user's data.
|
|
28
|
+
*
|
|
29
|
+
* 🛠 **Example usage**:
|
|
30
|
+
* ```ts
|
|
28
31
|
* const user = await getAuthenticatedUser();
|
|
29
32
|
* ```
|
|
30
|
-
* ####
|
|
33
|
+
* #### Output
|
|
31
34
|
* ```json
|
|
32
35
|
* {
|
|
33
36
|
* "id": "user1",
|
|
@@ -43,57 +46,36 @@ async function getAuthenticatedUser() {
|
|
|
43
46
|
return data;
|
|
44
47
|
}
|
|
45
48
|
/**
|
|
46
|
-
*
|
|
49
|
+
* 🚚 **Create Customer User**
|
|
50
|
+
*
|
|
51
|
+
* **APICODE(USER-100)**
|
|
47
52
|
* Creates a customer user.
|
|
48
53
|
*
|
|
49
54
|
* This function sends a request to create a new customer user with the specified parameters.
|
|
50
55
|
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
* The
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
65
|
-
*
|
|
66
|
-
* The
|
|
67
|
-
*
|
|
68
|
-
*
|
|
69
|
-
*
|
|
70
|
-
*
|
|
71
|
-
*
|
|
72
|
-
*
|
|
73
|
-
*
|
|
74
|
-
*
|
|
75
|
-
* Custom fields for additional user information.
|
|
76
|
-
* #### externalId - `string`
|
|
77
|
-
*
|
|
78
|
-
* An external identifier for the user.
|
|
79
|
-
* #### status - `string`
|
|
80
|
-
*
|
|
81
|
-
* The status of the user (e.g., active, inactive).
|
|
82
|
-
* #### mainOrganisationId - `string`
|
|
83
|
-
*
|
|
84
|
-
* The ID of the main organization associated with the user.
|
|
85
|
-
* #### organisations - `string[]`
|
|
86
|
-
*
|
|
87
|
-
* The list of organizations associated with the user.
|
|
88
|
-
* #### phone - `string`
|
|
89
|
-
*
|
|
90
|
-
* The phone number of the user.
|
|
91
|
-
*
|
|
92
|
-
* @returns {Promise<CreateCustomerUserResponse>} - The data of the created user.
|
|
93
|
-
*
|
|
94
|
-
* @example
|
|
95
|
-
* #### input
|
|
96
|
-
* ```typescript
|
|
56
|
+
* 🛠 **Endpoint**: `POST /v1/shop/customer-users`
|
|
57
|
+
*
|
|
58
|
+
* | Parameter | Type | Required | Description |
|
|
59
|
+
* |--------------------|--------|----------|--------------------------------------------------|
|
|
60
|
+
* | `email` | string | ✅ | The email address of the user. |
|
|
61
|
+
* | `password` | string | ✅ | The password of the user. |
|
|
62
|
+
* | `firstName` | string | ✅ | The first name of the user. |
|
|
63
|
+
* | `lastName` | string | ✅ | The last name of the user. |
|
|
64
|
+
* | `groups` | string[] | ✅ | The groups to which the user belongs. |
|
|
65
|
+
* | `activationUrl` | string | ❌ | The URL for user activation. |
|
|
66
|
+
* | `civility` | string | ❌ | The civility of the user (e.g., Mr., Ms.). |
|
|
67
|
+
* | `customFieldValues`| object | ❌ | Custom fields for additional user information. |
|
|
68
|
+
* | `externalId` | string | ❌ | An external identifier for the user. |
|
|
69
|
+
* | `status` | string | ❌ | The status of the user (e.g., active, inactive). |
|
|
70
|
+
* | `mainOrganisationId`| string | ❌ | The ID of the main organization associated with the user. |
|
|
71
|
+
* | `organisations` | string[] | ❌ | The list of organizations associated with the user. |
|
|
72
|
+
* | `phone` | string | ❌ | The phone number of the user. |
|
|
73
|
+
*
|
|
74
|
+
* 📤 **Returns**:
|
|
75
|
+
* A `Promise` resolving to an object containing the created user's data.
|
|
76
|
+
*
|
|
77
|
+
* 🛠 **Example usage**:
|
|
78
|
+
* ```ts
|
|
97
79
|
* const newUser = await createCustomerUser({
|
|
98
80
|
* email: 'user@example.com',
|
|
99
81
|
* password: 'securePassword',
|
|
@@ -110,7 +92,7 @@ async function getAuthenticatedUser() {
|
|
|
110
92
|
* phone: '123-456-7890'
|
|
111
93
|
* });
|
|
112
94
|
* ```
|
|
113
|
-
* ####
|
|
95
|
+
* #### Output
|
|
114
96
|
* ```json
|
|
115
97
|
* {
|
|
116
98
|
* "id": "user1",
|
|
@@ -143,33 +125,28 @@ async function createCustomerUser(params) {
|
|
|
143
125
|
return data;
|
|
144
126
|
}
|
|
145
127
|
/**
|
|
146
|
-
*
|
|
128
|
+
* 🚚 **Update Customer User**
|
|
129
|
+
*
|
|
130
|
+
* **APICODE(USER-201)**
|
|
147
131
|
* Updates a customer user.
|
|
148
132
|
*
|
|
149
133
|
* This function sends a request to update the details of an existing customer user.
|
|
150
134
|
*
|
|
151
|
-
*
|
|
152
|
-
* #### firstName - `string` | <strong style={{ color: 'red' }}>required</strong>
|
|
153
|
-
*
|
|
154
|
-
* The first name of the user.
|
|
155
|
-
* #### lastName - `string` | <strong style={{ color: 'red' }}>required</strong>
|
|
156
|
-
*
|
|
157
|
-
* The last name of the user.
|
|
158
|
-
* #### civility - `string`
|
|
159
|
-
*
|
|
160
|
-
* The civility of the user (e.g., Mr., Ms.).
|
|
161
|
-
* #### phone - `string`
|
|
162
|
-
*
|
|
163
|
-
* The phone number of the user.
|
|
164
|
-
* #### customFieldValues - `object`
|
|
135
|
+
* 🛠 **Endpoint**: `PUT /v1/shop/customer-users`
|
|
165
136
|
*
|
|
166
|
-
*
|
|
137
|
+
* | Parameter | Type | Required | Description |
|
|
138
|
+
* |--------------------|--------|----------|--------------------------------------------------|
|
|
139
|
+
* | `firstName` | string | ✅ | The first name of the user. |
|
|
140
|
+
* | `lastName` | string | ✅ | The last name of the user. |
|
|
141
|
+
* | `civility` | string | ❌ | The civility of the user (e.g., Mr., Ms.). |
|
|
142
|
+
* | `phone` | string | ❌ | The phone number of the user. |
|
|
143
|
+
* | `customFieldValues`| object | ❌ | Custom fields for additional user information. |
|
|
167
144
|
*
|
|
168
|
-
*
|
|
145
|
+
* 📤 **Returns**:
|
|
146
|
+
* A `Promise` resolving to an object containing the updated user's data.
|
|
169
147
|
*
|
|
170
|
-
*
|
|
171
|
-
*
|
|
172
|
-
* ```typescript
|
|
148
|
+
* 🛠 **Example usage**:
|
|
149
|
+
* ```ts
|
|
173
150
|
* const updatedUser = await updateCustomerUser({
|
|
174
151
|
* firstName: 'John',
|
|
175
152
|
* lastName: 'Doe',
|
|
@@ -178,7 +155,7 @@ async function createCustomerUser(params) {
|
|
|
178
155
|
* customFieldValues: {}
|
|
179
156
|
* });
|
|
180
157
|
* ```
|
|
181
|
-
* ####
|
|
158
|
+
* #### Output
|
|
182
159
|
* ```json
|
|
183
160
|
* {
|
|
184
161
|
* "detail": "User updated successfully"
|
|
@@ -201,24 +178,27 @@ async function updateCustomerUser({ civility, firstName, lastName, phone, custom
|
|
|
201
178
|
return data;
|
|
202
179
|
}
|
|
203
180
|
/**
|
|
204
|
-
*
|
|
181
|
+
* 🚚 **Activate Customer User**
|
|
182
|
+
*
|
|
183
|
+
* **APICODE(USER-200)**
|
|
205
184
|
* Activates a customer user.
|
|
206
185
|
*
|
|
207
186
|
* This function sends a request to activate a customer user with a specified token.
|
|
208
187
|
*
|
|
209
|
-
*
|
|
210
|
-
* #### token - `string` | <strong style={{ color: 'red' }}>required</strong>
|
|
188
|
+
* 🛠 **Endpoint**: `POST /v1/shop/customer-users/activate`
|
|
211
189
|
*
|
|
212
|
-
*
|
|
190
|
+
* | Parameter | Type | Required | Description |
|
|
191
|
+
* |-----------|--------|----------|--------------------------------------------------|
|
|
192
|
+
* | `token` | string | ✅ | The activation token of the user. |
|
|
213
193
|
*
|
|
214
|
-
*
|
|
194
|
+
* 📤 **Returns**:
|
|
195
|
+
* A `Promise` resolving when the user is activated.
|
|
215
196
|
*
|
|
216
|
-
*
|
|
217
|
-
*
|
|
218
|
-
* ```typescript
|
|
197
|
+
* 🛠 **Example usage**:
|
|
198
|
+
* ```ts
|
|
219
199
|
* await activateCustomerUser({ token: 'activationToken' });
|
|
220
200
|
* ```
|
|
221
|
-
* ####
|
|
201
|
+
* #### Output
|
|
222
202
|
* ```json
|
|
223
203
|
* {
|
|
224
204
|
* "detail": "User activated successfully"
|
|
@@ -237,30 +217,27 @@ async function activateCustomerUser(params) {
|
|
|
237
217
|
});
|
|
238
218
|
}
|
|
239
219
|
/**
|
|
240
|
-
*
|
|
220
|
+
* 🚚 **Retrieve Customer User Addresses**
|
|
221
|
+
*
|
|
222
|
+
* **APICODE(USER-501)**
|
|
241
223
|
* Retrieves customer user addresses.
|
|
242
224
|
*
|
|
243
225
|
* This function sends a request to obtain the addresses associated with a customer user.
|
|
244
226
|
*
|
|
245
|
-
*
|
|
246
|
-
* #### shipping - `boolean`
|
|
247
|
-
*
|
|
248
|
-
* Indicates whether to retrieve shipping addresses.
|
|
249
|
-
* #### billing - `boolean`
|
|
250
|
-
*
|
|
251
|
-
* Indicates whether to retrieve billing addresses.
|
|
252
|
-
* #### account - `string`
|
|
253
|
-
*
|
|
254
|
-
* The ID of the account for which to retrieve addresses.
|
|
255
|
-
* #### organisationIds - `string[]`
|
|
227
|
+
* 🛠 **Endpoint**: `GET /v1/shop/customer-users/addresses`
|
|
256
228
|
*
|
|
257
|
-
*
|
|
229
|
+
* | Parameter | Type | Required | Description |
|
|
230
|
+
* |------------------|---------|----------|-----------------------------------------------|
|
|
231
|
+
* | `shipping` | boolean | ✅ | Indicates whether to retrieve shipping addresses. |
|
|
232
|
+
* | `billing` | boolean | ✅ | Indicates whether to retrieve billing addresses. |
|
|
233
|
+
* | `account` | string | ✅ | The ID of the account for which to retrieve addresses. |
|
|
234
|
+
* | `organisationIds`| string[]| ❌ | An array of organization IDs to filter the addresses. |
|
|
258
235
|
*
|
|
259
|
-
*
|
|
236
|
+
* 📤 **Returns**:
|
|
237
|
+
* A `Promise` resolving to the list of addresses associated with the customer user.
|
|
260
238
|
*
|
|
261
|
-
*
|
|
262
|
-
*
|
|
263
|
-
* ```typescript
|
|
239
|
+
* 🛠 **Example usage**:
|
|
240
|
+
* ```ts
|
|
264
241
|
* const addresses = await getCustomerUserAddresses({
|
|
265
242
|
* shipping: true,
|
|
266
243
|
* billing: false,
|
|
@@ -268,7 +245,7 @@ async function activateCustomerUser(params) {
|
|
|
268
245
|
* organisationIds: ['org1', 'org2']
|
|
269
246
|
* });
|
|
270
247
|
* ```
|
|
271
|
-
* ####
|
|
248
|
+
* #### Output
|
|
272
249
|
* ```json
|
|
273
250
|
* {
|
|
274
251
|
* "addresses": [
|
|
@@ -294,19 +271,23 @@ async function getCustomerUserAddresses({ shipping, billing, account, organisati
|
|
|
294
271
|
return data;
|
|
295
272
|
}
|
|
296
273
|
/**
|
|
297
|
-
*
|
|
274
|
+
* 🚚 **Retrieve Customer User Organisations**
|
|
275
|
+
*
|
|
276
|
+
* **APICODE(USER-502)**
|
|
298
277
|
* Retrieves customer user organisations.
|
|
299
278
|
*
|
|
300
279
|
* This function sends a request to obtain the organisations associated with a customer user.
|
|
301
280
|
*
|
|
302
|
-
*
|
|
281
|
+
* 🛠 **Endpoint**: `GET /v1/shop/customer-users/organisations`
|
|
282
|
+
*
|
|
283
|
+
* 📤 **Returns**:
|
|
284
|
+
* A `Promise` resolving to the list of organisations associated with the customer user.
|
|
303
285
|
*
|
|
304
|
-
*
|
|
305
|
-
*
|
|
306
|
-
* ```typescript
|
|
286
|
+
* 🛠 **Example usage**:
|
|
287
|
+
* ```ts
|
|
307
288
|
* const organisations = await getCustomerUserOrganisations();
|
|
308
289
|
* ```
|
|
309
|
-
* ####
|
|
290
|
+
* #### Output
|
|
310
291
|
* ```json
|
|
311
292
|
* {
|
|
312
293
|
* "organisations": [
|
|
@@ -330,30 +311,31 @@ async function getCustomerUserOrganisations() {
|
|
|
330
311
|
return data;
|
|
331
312
|
}
|
|
332
313
|
/**
|
|
333
|
-
*
|
|
314
|
+
* 🚚 **Send Customer User Activation Request**
|
|
315
|
+
*
|
|
316
|
+
* **APICODE(USER-203)**
|
|
334
317
|
* Sends a customer user activation request.
|
|
335
318
|
*
|
|
336
319
|
* This function sends a request to resend an activation request to a customer user.
|
|
337
320
|
*
|
|
338
|
-
*
|
|
339
|
-
* #### token - `string` | <strong style={{ color: 'red' }}>required</strong>
|
|
340
|
-
*
|
|
341
|
-
* The activation token of the user.
|
|
342
|
-
* #### redirectUrl - `string`
|
|
321
|
+
* 🛠 **Endpoint**: `POST /v1/shop/customer-users/resend-activation-request`
|
|
343
322
|
*
|
|
344
|
-
*
|
|
323
|
+
* | Parameter | Type | Required | Description |
|
|
324
|
+
* |-------------|--------|----------|--------------------------------------------------|
|
|
325
|
+
* | `token` | string | ✅ | The activation token of the user. |
|
|
326
|
+
* | `redirectUrl`| string | ❌ | The URL to redirect the user after activation. |
|
|
345
327
|
*
|
|
346
|
-
*
|
|
328
|
+
* 📤 **Returns**:
|
|
329
|
+
* A `Promise` resolving when the request is sent.
|
|
347
330
|
*
|
|
348
|
-
*
|
|
349
|
-
*
|
|
350
|
-
* ```typescript
|
|
331
|
+
* 🛠 **Example usage**:
|
|
332
|
+
* ```ts
|
|
351
333
|
* await sendCustomerUserActivationRequest({
|
|
352
334
|
* token: 'activationToken',
|
|
353
335
|
* redirectUrl: 'http://example.com/redirect'
|
|
354
336
|
* });
|
|
355
337
|
* ```
|
|
356
|
-
* ####
|
|
338
|
+
* #### Output
|
|
357
339
|
* ```json
|
|
358
340
|
* {
|
|
359
341
|
* "detail": "Activation request sent successfully"
|
|
@@ -1,132 +1,81 @@
|
|
|
1
1
|
import { GetNavigationCategoriesParameters, GetNavigationCategoriesResponse, GetNavigationCategoryBreadcrumbsParameters, GetNavigationCategoryBreadcrumbsResponse, GetNavigationCategoryParameters, GetNavigationCategoryResponse } from "./definitions";
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
3
|
+
* 📄 Gets all navigation categories.
|
|
4
|
+
*
|
|
5
|
+
* Retrieves a list of all navigation categories available for the shop.
|
|
6
|
+
*
|
|
7
|
+
* 🛠 **Endpoint**: `GET /v1/shop/navigation-category/online`
|
|
8
|
+
*
|
|
9
|
+
* | Parameter | Type | Required | Description |
|
|
10
|
+
* |-----------------------|-------------------------------|------------|---------------------------------------------------------------|
|
|
11
|
+
* | `locale` | `string` | ✅ | Locale of the navigation categories to fetch. |
|
|
12
|
+
*
|
|
13
|
+
* 📤 **Returns**:
|
|
14
|
+
* A `Promise<GetNavigationCategoriesResponse>` containing a list of navigation categories.
|
|
15
|
+
*
|
|
16
|
+
* 🛠 **Example usage**:
|
|
17
|
+
* ```ts
|
|
18
|
+
* const categories = await getNavigationCategories({
|
|
19
|
+
* locale: 'en-US',
|
|
20
|
+
* });
|
|
21
|
+
*
|
|
22
|
+
* console.log(categories);
|
|
11
23
|
* ```
|
|
12
|
-
* ### output
|
|
13
|
-
* Response - <strong style={{ color: 'green' }}>200</strong> - OK
|
|
14
|
-
* ```json
|
|
15
|
-
* [
|
|
16
|
-
* {
|
|
17
|
-
* "active": true,
|
|
18
|
-
* "childrenCategories": [
|
|
19
|
-
* string
|
|
20
|
-
* ],
|
|
21
|
-
* "customFieldValues": [
|
|
22
|
-
* {
|
|
23
|
-
* "customField": {
|
|
24
|
-
* "externalId": "string",
|
|
25
|
-
* "id": "string",
|
|
26
|
-
* "name": {
|
|
27
|
-
* "additionalProp1": "string",
|
|
28
|
-
* "additionalProp2": "string",
|
|
29
|
-
* "additionalProp3": "string"
|
|
30
|
-
* },
|
|
31
|
-
* "type": "LONG_TEXT"
|
|
32
|
-
* },
|
|
33
|
-
* "value": {}
|
|
34
|
-
* }
|
|
35
|
-
* ],
|
|
36
|
-
* "externalId": "string",
|
|
37
|
-
* "id": "string",
|
|
38
|
-
* "name": "string"
|
|
39
|
-
* }
|
|
40
|
-
* ]
|
|
41
24
|
*/
|
|
42
25
|
export declare function getNavigationCategories({ locale, }: GetNavigationCategoriesParameters): Promise<GetNavigationCategoriesResponse>;
|
|
43
26
|
/**
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
27
|
+
* 📄 Gets a specific navigation category.
|
|
28
|
+
*
|
|
29
|
+
* Retrieves a specific navigation category based on its ID.
|
|
30
|
+
*
|
|
31
|
+
* 🛠 **Endpoint**: `GET /v1/shop/navigation-category/{navigationCategoryId}`
|
|
32
|
+
*
|
|
33
|
+
* | Parameter | Type | Required | Description |
|
|
34
|
+
* |-----------------------|-------------------------------|------------|---------------------------------------------------------------|
|
|
35
|
+
* | `locale` | `string` | ✅ | Locale of the navigation category. |
|
|
36
|
+
* | `idType` | `string` | ✅ | Type of the ID used to identify the category (e.g., `id`, `slug`). |
|
|
37
|
+
* | `navigationCategoryId`| `string` | ✅ | ID of the navigation category to fetch. |
|
|
38
|
+
*
|
|
39
|
+
* 📤 **Returns**:
|
|
40
|
+
* A `Promise<GetNavigationCategoryResponse>` containing the specific navigation category.
|
|
41
|
+
*
|
|
42
|
+
* 🛠 **Example usage**:
|
|
43
|
+
* ```ts
|
|
44
|
+
* const category = await getNavigationCategory({
|
|
45
|
+
* locale: 'en-US',
|
|
46
|
+
* idType: 'id',
|
|
47
|
+
* navigationCategoryId: '123',
|
|
48
|
+
* });
|
|
49
|
+
*
|
|
50
|
+
* console.log(category);
|
|
57
51
|
* ```
|
|
58
|
-
* ### output
|
|
59
|
-
* Response - <strong style={{ color: 'green' }}>200</strong> - OK
|
|
60
|
-
* ```json
|
|
61
|
-
* {
|
|
62
|
-
* "active": true,
|
|
63
|
-
* "childrenCategories": [
|
|
64
|
-
* string
|
|
65
|
-
* ],
|
|
66
|
-
* "customFieldValues": [
|
|
67
|
-
* {
|
|
68
|
-
* "customField": {
|
|
69
|
-
* "externalId": "string",
|
|
70
|
-
* "id": "string",
|
|
71
|
-
* "name": {
|
|
72
|
-
* "additionalProp1": "string",
|
|
73
|
-
* "additionalProp2": "string",
|
|
74
|
-
* "additionalProp3": "string"
|
|
75
|
-
* },
|
|
76
|
-
* "type": "LONG_TEXT"
|
|
77
|
-
* },
|
|
78
|
-
* "value": {}
|
|
79
|
-
* }
|
|
80
|
-
* ],
|
|
81
|
-
* "externalId": "string",
|
|
82
|
-
* "id": "string",
|
|
83
|
-
* "name": "string",
|
|
84
|
-
* }
|
|
85
52
|
*/
|
|
86
53
|
export declare function getNavigationCategory({ locale, idType, navigationCategoryId, }: GetNavigationCategoryParameters): Promise<GetNavigationCategoryResponse>;
|
|
87
54
|
/**
|
|
88
|
-
*
|
|
89
|
-
*
|
|
90
|
-
*
|
|
91
|
-
*
|
|
92
|
-
*
|
|
93
|
-
*
|
|
94
|
-
*
|
|
95
|
-
*
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
*
|
|
99
|
-
*
|
|
100
|
-
*
|
|
55
|
+
* 📄 Gets breadcrumbs for a specific navigation category.
|
|
56
|
+
*
|
|
57
|
+
* Retrieves the breadcrumb trail for a specific navigation category, showing its hierarchy.
|
|
58
|
+
*
|
|
59
|
+
* 🛠 **Endpoint**: `GET /v1/shop/navigation-category/{navigationCategoryId}/breadcrumb`
|
|
60
|
+
*
|
|
61
|
+
* | Parameter | Type | Required | Description |
|
|
62
|
+
* |-----------------------|-------------------------------|------------|---------------------------------------------------------------|
|
|
63
|
+
* | `locale` | `string` | ✅ | Locale of the navigation category breadcrumbs. |
|
|
64
|
+
* | `idType` | `string` | ✅ | Type of the ID used to identify the category (e.g., `id`, `slug`). |
|
|
65
|
+
* | `navigationCategoryId`| `string` | ✅ | ID of the navigation category to fetch breadcrumbs for. |
|
|
66
|
+
*
|
|
67
|
+
* 📤 **Returns**:
|
|
68
|
+
* A `Promise<GetNavigationCategoryBreadcrumbsResponse>` containing the breadcrumb trail for the navigation category.
|
|
69
|
+
*
|
|
70
|
+
* 🛠 **Example usage**:
|
|
71
|
+
* ```ts
|
|
72
|
+
* const breadcrumbs = await getNavigationCategoryBreadcrumbs({
|
|
73
|
+
* locale: 'en-US',
|
|
74
|
+
* idType: 'id',
|
|
75
|
+
* navigationCategoryId: '123',
|
|
76
|
+
* });
|
|
77
|
+
*
|
|
78
|
+
* console.log(breadcrumbs);
|
|
101
79
|
* ```
|
|
102
|
-
* ### output
|
|
103
|
-
* Response - <strong style={{ color: 'green' }}>200</strong> - OK
|
|
104
|
-
* ```json
|
|
105
|
-
* [
|
|
106
|
-
* {
|
|
107
|
-
* "active": true,
|
|
108
|
-
* "childrenCategories": [
|
|
109
|
-
* string
|
|
110
|
-
* ],
|
|
111
|
-
* "customFieldValues": [
|
|
112
|
-
* {
|
|
113
|
-
* "customField": {
|
|
114
|
-
* "externalId": "string",
|
|
115
|
-
* "id": "string",
|
|
116
|
-
* "name": {
|
|
117
|
-
* "additionalProp1": "string",
|
|
118
|
-
* "additionalProp2": "string",
|
|
119
|
-
* "additionalProp3": "string"
|
|
120
|
-
* },
|
|
121
|
-
* "type": "LONG_TEXT"
|
|
122
|
-
* },
|
|
123
|
-
* "value": {}
|
|
124
|
-
* }
|
|
125
|
-
* ],
|
|
126
|
-
* "externalId": "string",
|
|
127
|
-
* "id": "string",
|
|
128
|
-
* "name": "string",
|
|
129
|
-
* "parent": "string"
|
|
130
|
-
* }
|
|
131
80
|
*/
|
|
132
81
|
export declare function getNavigationCategoryBreadcrumbs({ locale, idType, navigationCategoryId, }: GetNavigationCategoryBreadcrumbsParameters): Promise<GetNavigationCategoryBreadcrumbsResponse>;
|