@djust-b2b/djust-front-sdk 1.16.0 → 1.17.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.
@@ -1,99 +1,44 @@
1
1
  import { CreateCustomerAccountAddressParameters, CreateCustomerAccountAddressResponse, CreateCustomerAccountOrganisationParameters, CreateCustomerAccountOrganisationResponse, CreateCustomerAccountParameters, CreateCustomerAccountResponse, DeleteCustomerAccountAddressParameters, DeleteCustomerAccountOrganisationAddressParameters, GetCustomerAccountAddressesParameters, GetCustomerAccountAddressesResponse, GetCustomerAccountOrdersParameters, GetCustomerAccountOrdersResponse, GetCustomerAccountOrganisationAddressesParameters, GetCustomerAccountOrganisationAddressesResponse, GetCustomerAccountOrganisationOrdersParameters, GetCustomerAccountOrganisationOrdersResponse, GetCustomerAccountOrganisationResponse, GetCustomerAccountOrganisationUsersParameters, GetCustomerAccountOrganisationUsersResponse, GetCustomerAccountResponse, GetCustomerAccountUsersParameters, GetCustomerAccountUsersResponse, UpdateCustomerAccountAddressParameters, UpdateCustomerAccountAddressResponse, UpdateCustomerAccountOrganisationAddressParameters, UpdateCustomerAccountOrganisationAddressResponse, UpdateCustomerAccountOrganisationParameters, UpdateCustomerAccountOrganisationResponse, UpdateCustomerAccountOrganisationUserParameters, UpdateCustomerAccountOrganisationUserResponse, UpdateCustomerAccountParameters, UpdateCustomerAccountResponse } from "./definitions";
2
2
  /**
3
- * ## Get customer accounts details
4
- * ### APICODE(ACCOUNT-501)
3
+ * 📄 Get customer account details.
5
4
  *
6
- * @returns {Promise<GetCustomerAccountsResponse>} - The response with the customer account details
5
+ * This function retrieves the detailed information of a customer account, including addresses, main contacts, custom fields, and more.
7
6
  *
8
- * @example
9
- * ### input
10
- * ```typescript
7
+ * 🛠 **Endpoint**: `GET /v1/shop/customer-accounts`
8
+ *
9
+ * 📤 **Returns**:
10
+ * A `Promise<GetCustomerAccountResponse>` containing the customer account details.
11
+ *
12
+ * 🛠 **Example usage**:
13
+ * ```ts
11
14
  * const response = await getCustomerAccount();
15
+ * console.log(response);
12
16
  * ```
13
- * ### output
14
- * ```json
15
- * {
16
- * "accountManager": "string",
17
- * "addresses": [
18
- * {
19
- * "additionalAddress": "string",
20
- * "address": "string",
21
- * "billing": true,
22
- * "city": "string",
23
- * "company": "string",
24
- * "country": "string",
25
- * "externalId": "string",
26
- * "fullName": "string",
27
- * "id": "string",
28
- * "label": "string",
29
- * "phone": "string",
30
- * "shipping": true,
31
- * "state": "string",
32
- * "zipcode": "string"
33
- * }
34
- * ],
35
- * "businessRegistrationNumber": "string",
36
- * "companyRegistrationName": "string",
37
- * "customFieldValues": [
38
- * {
39
- * "customField": {
40
- * "externalId": "string",
41
- * "id": "string",
42
- * "name": {
43
- * "additionalProp1": "string",
44
- * "additionalProp2": "string",
45
- * "additionalProp3": "string"
46
- * },
47
- * "type": "LONG_TEXT"
48
- * },
49
- * "value": {}
50
- * }
51
- * ],
52
- * "customerTags": [
53
- * {
54
- * "id": "string",
55
- * "name": "string"
56
- * }
57
- * ],
58
- * "externalId": "string",
59
- * "id": "string",
60
- * "mainContacts": [
61
- * {
62
- * "civility": "MR",
63
- * "email": "string",
64
- * "firstName": "string",
65
- * "id": "string",
66
- * "lastName": "string",
67
- * "status": "ACTIVE"
68
- * }
69
- * ],
70
- * "name": "string",
71
- * "paymentType": "ON_ACCEPTANCE",
72
- * "status": "ACTIVE",
73
- * "vatNumber": "string",
74
- * "website": "string"
75
- * }
76
- *
77
17
  */
78
18
  export declare function getCustomerAccount(): Promise<GetCustomerAccountResponse>;
79
19
  /**
80
- * ## Create a customer account
81
- * ### API CODE (ACCOUNT-100)
82
- * @param {CreateCustomerAccountParameters} params - The parameters for creating a customer account, including:
83
- * #### createAddressRequests - `object[]` | <strong style={{ color: 'red' }}>required</strong>
84
- * #### createCustomerUserRequest - `object` | <strong style={{ color: 'red' }}>required</strong>
85
- * #### createObjectCustomerAccountRequest - `object` | <strong style={{ color: 'red' }}>required</strong>
86
- * #### customFieldValues - `object[]` | <strong style={{ color: 'red' }}>required</strong>
87
- * #### customerTagList - `string[]` | <strong style={{ color: 'red' }}>required</strong>
88
- * #### fromFO - `boolean` | <strong style={{ color: 'red' }}>required</strong>
89
- * #### legalUser - `object[]` | <strong style={{ color: 'red' }}>required</strong>
90
- *
91
- * @return {Promise<CreateCustomerAccountResponse>} - The response with the customer account details
92
- *
93
- * @example
94
- * #### input
95
- * ```typescript
96
- * const response = await createCustomerAccount({
20
+ * 📄 Creates a new customer account.
21
+ *
22
+ * This function allows the creation of a new customer account with relevant details including addresses, user information, and custom fields.
23
+ *
24
+ * 🛠 **Endpoint**: `POST /v1/shop/customer-accounts`
25
+ *
26
+ * | Parameter | Type | Required | Description |
27
+ * |-----------------------------------|--------------------------------|----------|-------------|
28
+ * | `createAddressRequests` | `object[]` | | List of addresses to create, including `address`, `city`, `country`, `billing`, and `shipping` status. |
29
+ * | `createCustomerUserRequest` | `object` | | Contains user details such as `email`, `firstName`, `lastName`, `groups`, `password`, and `phone`. |
30
+ * | `createObjectCustomerAccountRequest` | `object` | ✅ | Main account details including `accountManager`, `businessRegistrationNumber`, `companyRegistrationName`, `externalId`, `name`, `vatNumber`, and `website`. |
31
+ * | `customFieldValues` | `object[]` | ✅ | List of custom fields with their `customFieldId` and `customFieldValue`. |
32
+ * | `customerTagList` | `string[]` | ✅ | List of customer tags. |
33
+ * | `fromFO` | `boolean` | ✅ | Flag indicating if the account is created from the front-office (FO). |
34
+ * | `legalUser` | `object[]` | ✅ | Information about the legal user including `birthday`, `countryOfResidence`, `email`, `firstName`, `lastName`, and `nationality`. |
35
+
36
+ * 📤 **Returns**:
37
+ * A `Promise<CreateCustomerAccountResponse>` containing the details of the created customer account.
38
+ *
39
+ * 🛠 **Example usage**:
40
+ * ```ts
41
+ * const response = await createCustomerAccount({
97
42
  * createAddressRequests: [
98
43
  * {
99
44
  * additionalAddress: "string",
@@ -121,16 +66,16 @@ export declare function getCustomerAccount(): Promise<GetCustomerAccountResponse
121
66
  * customFieldValue: 'string'
122
67
  * }
123
68
  * ],
124
- * externalId: string;
125
- * firstName: string;
126
- * groups: string[];
127
- * lastName: string;
128
- * mainOrganisationsId: string;
129
- * mainSubOrganisationsId: string;
130
- * organisationsIds: ['id1', 'id2'];
131
- * password: string;
132
- * phone: string;
133
- * subOrganisationsIds: ['id1', 'id2'];
69
+ * externalId: "string",
70
+ * firstName: "string",
71
+ * groups: ["group1", "group2"],
72
+ * lastName: "string",
73
+ * mainOrganisationsId: "orgId",
74
+ * mainSubOrganisationsId: "subOrgId",
75
+ * organisationsIds: ['orgId1', 'orgId2'],
76
+ * password: "password123",
77
+ * phone: "123456789",
78
+ * subOrganisationsIds: ['subOrgId1', 'subOrgId2']
134
79
  * },
135
80
  * createObjectCustomerAccountRequest: {
136
81
  * accountManager: "string",
@@ -143,263 +88,91 @@ export declare function getCustomerAccount(): Promise<GetCustomerAccountResponse
143
88
  * },
144
89
  * customFieldValues: [
145
90
  * {
146
- * customFieldId: string,
147
- * customFieldValue: string
91
+ * customFieldId: "string",
92
+ * customFieldValue: "value"
148
93
  * }
149
94
  * ],
150
- * customerTagList: ['stribg 1', 'string 2'],
95
+ * customerTagList: ["tag1", "tag2"],
151
96
  * fromFO: true,
152
- * legalUser: {
153
- * birthday: "2024-12-11T09:46:27.656Z",
154
- * countryOfResidence: "FR",
155
- * email: "string",
156
- * firstName: "string",
157
- * id: "string",
158
- * lastName: "string",
159
- * nationality: "FR"
160
- * },
161
- * });
162
- * ```
163
- * #### output
164
- * Response - <strong style={{ color: 'green' }}>201</strong> - Created
165
- * ```json
166
- * {
167
- * "accountManager": "string",
168
- * "addresses": [
169
- * {
170
- * "additionalAddress": "string",
171
- * "address": "string",
172
- * "billing": true,
173
- * "city": "string",
174
- * "company": "string",
175
- * "country": "string",
176
- * "externalId": "string",
177
- * "fullName": "string",
178
- * "id": "string",
179
- * "label": "string",
180
- * "phone": "string",
181
- * "shipping": true,
182
- * "state": "string",
183
- * "zipcode": "string"
184
- * }
185
- * ],
186
- * "businessRegistrationNumber": "string",
187
- * "companyRegistrationName": "string",
188
- * "customFieldValues": [
189
- * {
190
- * "customField": {
191
- * "externalId": "string",
192
- * "id": "string",
193
- * "name": {
194
- * "additionalProp1": "string",
195
- * "additionalProp2": "string",
196
- * "additionalProp3": "string"
197
- * },
198
- * "type": "LONG_TEXT"
199
- * },
200
- * "value": {}
201
- * }
202
- * ],
203
- * "customerTags": [
204
- * {
205
- * "id": "string",
206
- * "name": "string"
207
- * }
208
- * ],
209
- * "externalId": "string",
210
- * "id": "string",
211
- * "mainContacts": [
212
- * {
213
- * "civility": "MR",
214
- * "email": "string",
215
- * "firstName": "string",
216
- * "id": "string",
217
- * "lastName": "string",
218
- * "status": "ACTIVE"
219
- * }
220
- * ],
221
- * "name": "string",
222
- * "paymentType": "ON_ACCEPTANCE",
223
- * "status": "ACTIVE",
224
- * "vatNumber": "string",
225
- * "website": "string"
226
- * }
227
- */
228
- export declare function createCustomerAccount({ createAddressRequests, createCustomerUserRequest, createObjectCustomerAccountRequest, customFieldValues, customerTagList, fromFO, legalUser, }: CreateCustomerAccountParameters): Promise<CreateCustomerAccountResponse>;
229
- /**
230
- * ## Update a customer account
231
- * ### API CODE (ACCOUNT-201)
232
- *
233
- * @param {UpdateCustomerAccountParameters} params - The parameters for updating a customer account, including:
234
- * #### accountManager - `string`
235
- * #### businessRegistrationNumber - `string`
236
- * #### companyRegistrationName - `string`
237
- * #### customFieldValues - `object[]`
238
- * #### customerTagList - `string[]`
239
- * #### legalUser - `object[]`
240
- * #### name - `string`
241
- * #### vatNumber - `string`
242
- * #### website - `string`
243
- *
244
- * @return {Promise<UpdateCustomerAccountResponse>} - The response with the updated customer account details
245
- *
246
- * @example
247
- * #### input
248
- * ```typescript
249
- * const response = await updateCustomerAccount({
250
- * accountManager: "string",
251
- * businessRegistrationNumber: "string",
252
- * companyRegistrationName: "string",
253
- * customFieldValues: [
97
+ * legalUser: [
254
98
  * {
255
- * customFieldId: 'string',
256
- * customFieldValue: 'string'
99
+ * birthday: "2024-12-11T09:46:27.656Z",
100
+ * countryOfResidence: "FR",
101
+ * email: "user@example.com",
102
+ * firstName: "John",
103
+ * id: "userId",
104
+ * lastName: "Doe",
105
+ * nationality: "FR"
257
106
  * }
258
107
  * ],
259
- * customerTagList: ['stribg 1', 'string 2'],
260
- * legalUser: {
261
- * birthday: "2024-12-11T09:46:27.656Z",
262
- * countryOfResidence: "FR",
263
- * email: "string",
264
- * firstName: "string",
265
- * id: "string",
266
- * lastName: "string",
267
- * nationality: "FR"
268
- * },
269
- * name: "string",
270
- * vatNumber: "string",
271
- * website: "string"
272
- * });
108
+ * });
273
109
  * ```
274
- * #### output
275
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
276
- * ```json
277
- * {
278
- * "accountManager": "string",
279
- * "addresses": [
280
- * {
281
- * "additionalAddress": "string",
282
- * "address": "string",
283
- * "billing": true,
284
- * "city": "string",
285
- * "company": "string",
286
- * "country": "string",
287
- * "externalId": "string",
288
- * "fullName": "string",
289
- * "id": "string",
290
- * "label": "string",
291
- * "phone": "string",
292
- * "shipping": true,
293
- * "state": "string",
294
- * "zipcode": "string"
295
- * }
296
- * ],
297
- * "businessRegistrationNumber": "string",
298
- * "companyRegistrationName": "string",
299
- * "customFieldValues": [
300
- * {
301
- * "customField": {
302
- * "externalId": "string",
303
- * "id": "string",
304
- * "name": {
305
- * "additionalProp1": "string",
306
- * "additionalProp2": "string",
307
- * "additionalProp3": "string"
308
- * },
309
- * "type": "LONG_TEXT"
310
- * },
311
- * "value": {}
312
- * }
313
- * ],
314
- * "customerTags": [
315
- * {
316
- * "id": "string",
317
- * "name": "string"
318
- * }
319
- * ],
320
- * "externalId": "string",
321
- * "id": "string",
322
- * "mainContacts": [
323
- * {
324
- * "civility": "MR",
325
- * "email": "string",
326
- * "firstName": "string",
327
- * "id": "string",
328
- * "lastName": "string",
329
- * "status": "ACTIVE"
330
- * }
331
- * ],
332
- * "name": "string",
333
- * "paymentType": "ON_ACCEPTANCE",
334
- * "status": "ACTIVE",
335
- * "vatNumber": "string",
336
- * "website": "string"
337
- * }
110
+ */
111
+ export declare function createCustomerAccount({ createAddressRequests, createCustomerUserRequest, createObjectCustomerAccountRequest, customFieldValues, customerTagList, fromFO, legalUser, }: CreateCustomerAccountParameters): Promise<CreateCustomerAccountResponse>;
112
+ /**
113
+ * 📄 Update customer account details.
114
+ *
115
+ * This function allows you to update the details of an existing customer account, including account manager, registration details, tags, and more.
116
+ *
117
+ * 🛠 **Endpoint**: `PUT /v1/shop/customer-accounts`
118
+ *
119
+ * 📤 **Returns**:
120
+ * A `Promise<UpdateCustomerAccountResponse>` containing the updated customer account details.
121
+ *
122
+ * console.log(response);
338
123
  * ```
339
124
  */
340
125
  export declare function updateCustomerAccount({ accountManager, businessRegistrationNumber, companyRegistrationName, customFieldValues, customerTagList, legalUser, name, vatNumber, website, }: UpdateCustomerAccountParameters): Promise<UpdateCustomerAccountResponse>;
341
126
  /**
342
- * ## Get a customer account's addresses
343
- * ### APICODE(ACCOUNT-500)
127
+ * 📄 Get customer account's addresses.
344
128
  *
345
- * @param {GetCustomerAccountAddressesParameters} params - The parameters for the function
346
- * #### shipping - `boolean`
347
- * #### billing - `boolean`
129
+ * This function retrieves the addresses associated with a specific customer account, including shipping and billing addresses.
348
130
  *
349
- * @returns {Promise<GetCustomerAccountAddressesResponse>} - The response with the customer account addresses
131
+ * 🛠 **Endpoint**: `GET /v1/shop/customer-accounts/addresses`
350
132
  *
351
- * @example
352
- * ### input
353
- * ```typescript
133
+ * | Parameter | Type | Required | Description |
134
+ * |---------------|-----------|----------|------------------------------------------------------|
135
+ * | `shipping` | `boolean` | ✅ | Flag to include shipping address. |
136
+ * | `billing` | `boolean` | ✅ | Flag to include billing address. |
137
+ *
138
+ * 📤 **Returns**:
139
+ * A `Promise<GetCustomerAccountAddressesResponse>` containing the addresses associated with the customer account.
140
+ *
141
+ * 🛠 **Example usage**:
142
+ * ```ts
354
143
  * const response = await getCustomerAccountAddresses({ shipping: true, billing: true });
355
- * ```
356
- * ### output
357
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
358
- * ```json
359
- * [
360
- * {
361
- * "additionalAddress": "string",
362
- * "address": "string",
363
- * "billing": true,
364
- * "city": "string",
365
- * "company": "string",
366
- * "country": "string",
367
- * "externalId": "string",
368
- * "fullName": "string",
369
- * "id": "string",
370
- * "label": "string",
371
- * "phone": "string",
372
- * "shipping": true,
373
- * "state": "string",
374
- * "zipcode": "string"
375
- * }
376
- * ]
144
+ * console.log(response);
377
145
  * ```
378
146
  */
379
147
  export declare function getCustomerAccountAddresses({ shipping, billing, }: GetCustomerAccountAddressesParameters): Promise<GetCustomerAccountAddressesResponse>;
380
148
  /**
381
- * ## Create an address for a customer account
382
- * ### APICODE(ADDRESS-100)
383
- * @param {CreateCustomerAccountAddressParameters} params - The parameters for the function
384
- * #### additionalAddress - `string`
385
- * #### address - `string` | <strong style={{ color: 'red' }}>required</strong>
386
- * #### billing - `boolean`
387
- * #### city - `string` | <strong style={{ color: 'red' }}>required</strong>
388
- * #### company - `string`
389
- * #### country - `string` | <strong style={{ color: 'red' }}>required</strong>
390
- * #### externalId - `string`
391
- * #### fullName - `string` | <strong style={{ color: 'red' }}>required</strong>
392
- * #### label - `string`
393
- * #### phone - `string`
394
- * #### shipping - `boolean`
395
- * #### state - `string`
396
- * #### zipcode - `string` | <strong style={{ color: 'red' }}>required</strong>
397
- *
398
- * @returns {Promise<CreateCustomerAccountAddressResponse>} - The response with the customer account address
399
- *
400
- * @example
401
- * ### input
402
- * ```typescript
149
+ * 📄 Create an address for a customer account.
150
+ *
151
+ * This function creates a new address for a specific customer account, with optional fields like shipping and billing flags.
152
+ *
153
+ * 🛠 **Endpoint**: `POST /v1/shop/customer-accounts/addresses`
154
+ *
155
+ * | Parameter | Type | Required | Description |
156
+ * |---------------------|-----------|----------|------------------------------------------------------|
157
+ * | `additionalAddress` | `string` | | Additional address line. |
158
+ * | `address` | `string` | ✅ | The main address of the customer. |
159
+ * | `billing` | `boolean` | ❌ | Flag indicating if it's a billing address. |
160
+ * | `city` | `string` | ✅ | The city of the customer address. |
161
+ * | `company` | `string` | ❌ | The company name associated with the address. |
162
+ * | `country` | `string` | ✅ | The country of the customer address. |
163
+ * | `externalId` | `string` | ❌ | External ID for the address. |
164
+ * | `fullName` | `string` | | The full name of the person associated with the address. |
165
+ * | `label` | `string` | ❌ | Label for the address. |
166
+ * | `phone` | `string` | ❌ | Phone number associated with the address. |
167
+ * | `shipping` | `boolean` | ❌ | Flag indicating if it's a shipping address. |
168
+ * | `state` | `string` | ❌ | The state/province of the customer address. |
169
+ * | `zipcode` | `string` | ✅ | The postal code for the customer address. |
170
+ *
171
+ * 📤 **Returns**:
172
+ * A `Promise<CreateCustomerAccountAddressResponse>` containing the created customer account address.
173
+ *
174
+ * 🛠 **Example usage**:
175
+ * ```ts
403
176
  * const response = await createCustomerAccountAddress({
404
177
  * additionalAddress: "string",
405
178
  * address: "string",
@@ -415,73 +188,58 @@ export declare function getCustomerAccountAddresses({ shipping, billing, }: GetC
415
188
  * state: "string",
416
189
  * zipcode: "string"
417
190
  * });
418
- * ```
419
- * ### output
420
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
421
- * ```json
422
- * {
423
- * "additionalAddress": "string",
424
- * "address": "string",
425
- * "billing": true,
426
- * "city": "string",
427
- * "company": "string",
428
- * "country": "string",
429
- * "externalId": "string",
430
- * "fullName": "string",
431
- * "id": "string",
432
- * "label": "string",
433
- * "phone": "string",
434
- * "shipping": true,
435
- * "state": "string",
436
- * "zipcode": "string"
437
- * }
191
+ * console.log(response);
438
192
  * ```
439
193
  */
440
194
  export declare function createCustomerAccountAddress({ additionalAddress, address, billing, city, company, country, externalId, fullName, label, phone, shipping, state, zipcode, }: CreateCustomerAccountAddressParameters): Promise<CreateCustomerAccountAddressResponse>;
441
195
  /**
196
+ * 🗑️ Delete an address from a customer account.
442
197
  *
443
- * ## Delete an address from a customer account
444
- * ### APICODE(ADDRESS-300)
445
- * @param {DeleteCustomerAccountAddressParameters} params - The parameters for the function
446
- * #### addressId - `string` | <strong style={{ color: 'red' }}>required</strong>
198
+ * This function deletes a specific address from a customer's account based on the provided address ID.
447
199
  *
448
- * @returns {Promise<void>} - The response with the customer account address
200
+ * 🛠 **Endpoint**: `DELETE /v1/shop/customer-accounts/addresses/{addressId}`
449
201
  *
450
- * @example
451
- * ### input
452
- * ```typescript
453
- * const response = await deleteCustomerAccountAddress({ addressId: "string" });
454
- * ```
455
- * ### output
456
- * Response - <strong style={{ color: 'green' }}>204</strong> - No Content
457
- * ```json
202
+ * | Parameter | Type | Required | Description |
203
+ * |-------------|----------|----------|----------------------------------|
204
+ * | `addressId` | `string` | ✅ | The ID of the address to delete. |
205
+ *
206
+ * 📤 **Returns**: `Promise<void>` - No content response indicating successful deletion.
458
207
  *
208
+ * 🛠 **Example usage**:
209
+ * ```ts
210
+ * const response = await deleteCustomerAccountAddress({ addressId: "string" });
211
+ * console.log(response); // No content response
459
212
  * ```
460
213
  */
461
214
  export declare function deleteCustomerAccountAddress({ addressId, }: DeleteCustomerAccountAddressParameters): Promise<void>;
462
215
  /**
463
- * ## Update an address for a customer account
464
- * ### APICODE(ADDRESS-200)
465
- * @param {UpdateCustomerAccountAddressParameters} params - The parameters for the function
466
- * #### addressId - `string` | <strong style={{ color: 'red' }}>required</strong>
467
- * #### additionalAddress - `string`
468
- * #### address - `string`
469
- * #### billing - `boolean`
470
- * #### city - `string`
471
- * #### company - `string`
472
- * #### country - `string`
473
- * #### fullName - `string`
474
- * #### label - `string`
475
- * #### phone - `string`
476
- * #### shipping - `boolean`
477
- * #### state - `string`
478
- * #### zipcode - `string`
479
- *
480
- * @returns {Promise<UpdateCustomerAccountAddressResponse>} - The response with the customer account address
481
- *
482
- * @example
483
- * ### input
484
- * ```typescript
216
+ * ✏️ Update an address for a customer account.
217
+ *
218
+ * This function allows you to update an existing address for a customer account. You must provide the address ID and at least one of the optional parameters for updating the address.
219
+ *
220
+ * 🛠 **Endpoint**: `PUT /v1/shop/customer-accounts/addresses/{addressId}`
221
+ *
222
+ * | Parameter | Type | Required | Description |
223
+ * |----------------------|-----------|----------|-------------------------------------------------------|
224
+ * | `addressId` | `string` | ✅ | The ID of the address to update. |
225
+ * | `additionalAddress` | `string` | ❌ | Additional address line. |
226
+ * | `address` | `string` | ✅ | The main address of the customer. |
227
+ * | `billing` | `boolean` | ❌ | Flag indicating if it's a billing address. |
228
+ * | `city` | `string` | ✅ | The city of the customer address. |
229
+ * | `company` | `string` | ❌ | The company name associated with the address. |
230
+ * | `country` | `string` | ✅ | The country of the customer address. |
231
+ * | `fullName` | `string` | ✅ | The full name of the person associated with the address. |
232
+ * | `label` | `string` | ❌ | Label for the address. |
233
+ * | `phone` | `string` | ❌ | Phone number associated with the address. |
234
+ * | `shipping` | `boolean` | ❌ | Flag indicating if it's a shipping address. |
235
+ * | `state` | `string` | ❌ | The state/province of the customer address. |
236
+ * | `zipcode` | `string` | ✅ | The postal code for the customer address. |
237
+ *
238
+ * 📤 **Returns**:
239
+ * A `Promise<UpdateCustomerAccountAddressResponse>` containing the updated customer account address.
240
+ *
241
+ * 🛠 **Example usage**:
242
+ * ```ts
485
243
  * const response = await updateCustomerAccountAddress({
486
244
  * addressId: "string",
487
245
  * additionalAddress: "string",
@@ -497,1339 +255,352 @@ export declare function deleteCustomerAccountAddress({ addressId, }: DeleteCusto
497
255
  * state: "string",
498
256
  * zipcode: "string"
499
257
  * });
500
- * ```
501
- * ### output
502
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
503
- * ```json
504
- * {
505
- * "additionalAddress": "string",
506
- * "address": "string",
507
- * "billing": true,
508
- * "city": "string",
509
- * "company": "string",
510
- * "country": "string",
511
- * "externalId": "string",
512
- * "fullName": "string",
513
- * "id": "string",
514
- * "label": "string",
515
- * "phone": "string",
516
- * "shipping": true,
517
- * "state": "string",
518
- * "zipcode": "string"
519
- * }
258
+ * console.log(response); // Updated address details
520
259
  * ```
521
260
  */
522
261
  export declare function updateCustomerAccountAddress({ addressId, additionalAddress, address, billing, city, company, country, fullName, label, phone, shipping, state, zipcode, }: UpdateCustomerAccountAddressParameters): Promise<UpdateCustomerAccountAddressResponse>;
523
262
  /**
524
- * ## Get a customer account's orders
525
- * APICODE(ORDER-550)
526
- * @param {GetCustomerAccountOrdersParameters} params - The parameters for the function
527
- * #### pageable - `object` | <strong style={{ color: 'red' }}>required</strong>
528
- * #### locale - `string` | <strong style={{ color: 'red' }}>required</strong>
263
+ * 📋 Retrieves orders for a customer account.
529
264
  *
530
- * @returns {Promise<GetCustomerAccountOrdersResponse>} - The response with the customer account orders
265
+ * This function fetches the orders for a customer account based on the provided parameters.
531
266
  *
532
- * @example
533
- * ### input
267
+ * 🛠 **Endpoint**: `GET /v1/shop/customer-accounts/orders`
268
+ *
269
+ * | **Parameter** | **Type** | **Required** | **Description** |
270
+ * |----------------------|------------|--------------|---------------------------------------------------------------------------|
271
+ * | `pageable` | `object` | ✅ | The pagination parameters to retrieve paginated results. |
272
+ * | `locale` | `string` | ✅ | The locale to be used for the response. |
273
+ * | `includeInactive` | `boolean` | ❌ | Whether to include inactive orders in the response. |
274
+ * | `limit` | `number` | ❌ | The maximum number of orders to return. |
275
+ * | `offset` | `number` | ❌ | The number of orders to skip before starting to collect results. |
276
+ *
277
+ * 📤 **Returns**:
278
+ * A `Promise<GetCustomerAccountOrdersResponse>` containing the retrieved customer account orders.
279
+ *
280
+ * 🛠 **Example Usage**:
534
281
  * ```typescript
535
- * const response = await getCustomerAccountOrders({ pageable: { page: 1, size: 10 }, locale: "string" });
536
- * ```
537
- * ### output
538
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
539
- * ```json
540
- * {
541
- * "content": [
542
- * {
543
- * "billingAddressSnapshot": {
544
- * "additionalAddress": "string",
545
- * "address": "string",
546
- * "city": "string",
547
- * "company": "string",
548
- * "country": "string",
549
- * "externalId": "string",
550
- * "fullName": "string",
551
- * "id": "string",
552
- * "label": "string",
553
- * "phone": "string",
554
- * "state": "string",
555
- * "zipcode": "string"
556
- * },
557
- * "channel": "DESKTOP",
558
- * "createdAt": "2024-12-11T10:28:21.123Z",
559
- * "customFieldValues": [
560
- * {
561
- * "customField": {
562
- * "externalId": "string",
563
- * "externalSource": "MIRAKL",
564
- * "faceted": true,
565
- * "id": "string",
566
- * "indexable": true,
567
- * "mandatory": true,
568
- * "name": {
569
- * "additionalProp1": "string",
570
- * "additionalProp2": "string",
571
- * "additionalProp3": "string"
572
- * },
573
- * "role": "PRODUCT_TAX_RATE",
574
- * "sealedTarget": "string",
575
- * "searchable": true,
576
- * "sortable": true,
577
- * "status": "ACTIVE"
578
- * },
579
- * "value": {}
580
- * }
581
- * ],
582
- * "customerUserSnapshot": {
583
- * "accountExternalId": "string",
584
- * "accountId": "string",
585
- * "accountName": "string",
586
- * "accountTvaNumber": "string",
587
- * "civility": "MR",
588
- * "email": "string",
589
- * "externalId": "string",
590
- * "firstName": "string",
591
- * "id": "string",
592
- * "lastName": "string",
593
- * "phone": "string"
594
- * },
595
- * "exportStatus": "EXPORTED",
596
- * "externalId": "string",
597
- * "externalSource": "MIRAKL",
598
- * "fulfillmentMessage": "string",
599
- * "id": "string",
600
- * "incidentDeclared": true,
601
- * "initialPrice": {
602
- * "priceWithTax": 0,
603
- * "priceWithoutTax": 0,
604
- * "shippingPriceWithTax": 0,
605
- * "shippingPriceWithoutTax": 0,
606
- * "totalPriceWithTax": 0,
607
- * "totalPriceWithoutTax": 0
608
- * },
609
- * "leadTimeToShip": 0,
610
- * "lines": [
611
- * {
612
- * "confirmedQuantity": 0,
613
- * "customFieldValues": [
614
- * {
615
- * "customField": {
616
- * "externalId": "string",
617
- * "externalSource": "MIRAKL",
618
- * "faceted": true,
619
- * "id": "string",
620
- * "indexable": true,
621
- * "mandatory": true,
622
- * "name": {
623
- * "additionalProp1": "string",
624
- * "additionalProp2": "string",
625
- * "additionalProp3": "string"
626
- * },
627
- * "role": "PRODUCT_TAX_RATE",
628
- * "sealedTarget": "string",
629
- * "searchable": true,
630
- * "sortable": true,
631
- * "status": "ACTIVE"
632
- * },
633
- * "value": {}
634
- * }
635
- * ],
636
- * "externalId": "string",
637
- * "externalSource": "MIRAKL",
638
- * "id": "string",
639
- * "incidentDeclared": true,
640
- * "offerInventorySnapshotDto": {
641
- * "currency": "USD",
642
- * "customFieldValueSnapshots": [
643
- * {
644
- * "customFieldSnapshotDto": {
645
- * "externalId": "string",
646
- * "externalSource": "string",
647
- * "mandatory": true,
648
- * "names": {
649
- * "additionalProp1": "string",
650
- * "additionalProp2": "string",
651
- * "additionalProp3": "string"
652
- * },
653
- * "role": "string",
654
- * "sealedTarget": "string",
655
- * "status": "string",
656
- * "type": "string"
657
- * },
658
- * "value": "string"
659
- * }
660
- * ],
661
- * "externalSource": "MIRAKL",
662
- * "offerInventoryExternalId": "string",
663
- * "packingType": "BOX",
664
- * "productTaxCode": "string",
665
- * "productTaxRate": 0,
666
- * "quantityPerItem": 0,
667
- * "shippingTaxCode": "string",
668
- * "shippingTaxRate": 0
669
- * },
670
- * "offerPriceSnapshotDto": {
671
- * "confirmedProductPriceWithoutTaxes": 0,
672
- * "itemPerPack": 0,
673
- * "offerPriceExternalId": "string",
674
- * "offerPriceType": "PUBLIC",
675
- * "offerPriceTypeValue": "string",
676
- * "productPriceWithTaxes": 0,
677
- * "productPriceWithoutTaxes": 0,
678
- * "productTaxAmount": 0,
679
- * "shippingPriceWithTaxes": 0,
680
- * "shippingPriceWithoutTaxes": 0,
681
- * "shippingTaxAmount": 0,
682
- * "totalPriceWithTaxes": 0,
683
- * "totalPriceWithoutTaxes": 0,
684
- * "totalProductPriceWithTaxes": 0,
685
- * "totalProductPriceWithoutTaxes": 0,
686
- * "totalProductTaxAmount": 0,
687
- * "totalTaxAmount": 0
688
- * },
689
- * "orderLogisticLinePriceDto": {
690
- * "confirmedPrice": 0,
691
- * "currency": "USD",
692
- * "externalOfferId": "string",
693
- * "externalSource": "MIRAKL",
694
- * "itemPerPack": 0,
695
- * "itemPriceWithoutTaxes": 0,
696
- * "packingType": "BOX",
697
- * "priceWithTaxes": 0,
698
- * "quantityPerItem": 0,
699
- * "shippingPriceWithTaxes": 0,
700
- * "shippingPriceWithoutTaxes": 0,
701
- * "shippingTaxAmount": 0,
702
- * "taxAmount": 0,
703
- * "taxInformation": {
704
- * "productTaxAmount": 0,
705
- * "productTaxCode": "string",
706
- * "productTaxRate": 0,
707
- * "shippingTaxAmount": 0,
708
- * "shippingTaxCode": "string",
709
- * "shippingTaxRate": 0
710
- * },
711
- * "taxRate": 0,
712
- * "totalItemPrice": 0,
713
- * "totalItemPriceWithTaxes": 0,
714
- * "totalItemTaxAmount": 0,
715
- * "totalPriceWithTaxes": 0,
716
- * "totalPriceWithoutTaxes": 0,
717
- * "totalTaxes": 0,
718
- * "type": "PUBLIC",
719
- * "typeValue": "string"
720
- * },
721
- * "orderLogisticLineProductDto": {
722
- * "brand": "string",
723
- * "classificationCategory": "string",
724
- * "defaultLanguage": "EN",
725
- * "description": "string",
726
- * "externalId": "string",
727
- * "externalSource": "MIRAKL",
728
- * "name": "string",
729
- * "productAttributeValues": [
730
- * {
731
- * "attributeExternalId": "string",
732
- * "attributeExternalSource": "string",
733
- * "attributeId": "string",
734
- * "attributeName": {
735
- * "additionalProp1": "string",
736
- * "additionalProp2": "string",
737
- * "additionalProp3": "string"
738
- * },
739
- * "attributeType": "string",
740
- * "attributeValue": "string",
741
- * "id": "string"
742
- * }
743
- * ],
744
- * "productUnit": "string",
745
- * "sku": "string",
746
- * "tags": [
747
- * "string"
748
- * ]
749
- * },
750
- * "orderLogisticLineProductVariantDto": {
751
- * "attributeValues": [
752
- * {
753
- * "attributeExternalId": "string",
754
- * "attributeExternalSource": "string",
755
- * "attributeId": "string",
756
- * "attributeName": {
757
- * "additionalProp1": "string",
758
- * "additionalProp2": "string",
759
- * "additionalProp3": "string"
760
- * },
761
- * "attributeType": "string",
762
- * "attributeValue": "string",
763
- * "id": "string"
764
- * }
765
- * ],
766
- * "description": "string",
767
- * "ean": "string",
768
- * "externalId": "string",
769
- * "externalSource": "MIRAKL",
770
- * "mainImageUrl": "string",
771
- * "mpn": "string",
772
- * "name": "string",
773
- * "productMediaInfoDTOS": [
774
- * {
775
- * "isMain": true,
776
- * "urls": [
777
- * {
778
- * "formatType": "string",
779
- * "heightInPx": 0,
780
- * "sizeType": "string",
781
- * "url": "string",
782
- * "widthInPx": 0
783
- * }
784
- * ]
785
- * }
786
- * ],
787
- * "sku": "string"
788
- * },
789
- * "paymentStatus": "WAITING_REFUND",
790
- * "quantity": 0,
791
- * "quoteLineExternalId": "string",
792
- * "status": "CANCELED"
793
- * }
794
- * ],
795
- * "orderCommercialId": "string",
796
- * "orderCommercialReference": "string",
797
- * "orderLogisticPrices": {
798
- * "currency": "USD",
799
- * "totalPriceWithTax": 0,
800
- * "totalPriceWithoutTax": 0,
801
- * "totalProductTaxAmount": 0,
802
- * "totalProductWithTax": 0,
803
- * "totalProductWithoutTax": 0,
804
- * "totalShippingFeesWithTax": 0,
805
- * "totalShippingFeesWithoutTax": 0,
806
- * "totalShippingTaxAmount": 0,
807
- * "totalTaxAmount": 0
808
- * },
809
- * "orderOrigin": "CART",
810
- * "partiallyDeclinedBySupplier": true,
811
- * "paymentOption": "BANK_WIRE",
812
- * "paymentStatus": "AUTHORIZED",
813
- * "reference": "string",
814
- * "shippingAddressSnapshot": {
815
- * "additionalAddress": "string",
816
- * "address": "string",
817
- * "city": "string",
818
- * "company": "string",
819
- * "country": "string",
820
- * "externalId": "string",
821
- * "fullName": "string",
822
- * "id": "string",
823
- * "label": "string",
824
- * "phone": "string",
825
- * "state": "string",
826
- * "zipcode": "string"
827
- * },
828
- * "shippingTrackingUrl": "string",
829
- * "shippingType": "string",
830
- * "status": "CREATING",
831
- * "supplierSnapshot": {
832
- * "description": "string",
833
- * "externalId": "string",
834
- * "id": "string",
835
- * "name": "string",
836
- * "paymentDueDate": {
837
- * "paymentDueDateDelay": 0,
838
- * "paymentDueDateMode": "SIMPLE"
839
- * },
840
- * "returnPolicy": "string",
841
- * "totalOffers": 0,
842
- * "totalOrders": 0
843
- * },
844
- * "updatedAt": "2024-12-11T10:28:21.124Z",
845
- * "validatedAt": "2024-12-11T10:28:21.124Z"
846
- * }
847
- * ],
848
- * "empty": true,
849
- * "first": true,
850
- * "last": true,
851
- * "number": 0,
852
- * "numberOfElements": 0,
853
- * "pageable": {
854
- * "offset": 0,
855
- * "pageNumber": 0,
856
- * "pageSize": 0,
857
- * "paged": true,
858
- * "sort": [
859
- * {
860
- * "ascending": true,
861
- * "descending": true,
862
- * "direction": "ASC",
863
- * "ignoreCase": true,
864
- * "nullHandling": "NATIVE",
865
- * "property": "string"
866
- * }
867
- * ],
868
- * "unpaged": true
869
- * },
870
- * "size": 0,
871
- * "sort": [
872
- * {
873
- * "ascending": true,
874
- * "descending": true,
875
- * "direction": "ASC",
876
- * "ignoreCase": true,
877
- * "nullHandling": "NATIVE",
878
- * "property": "string"
879
- * }
880
- * ],
881
- * "totalElements": 0,
882
- * "totalPages": 0
883
- * }
282
+ * const orders = await getCustomerAccountOrders({
283
+ * pageable: { page: 1, size: 10 },
284
+ * locale: 'en',
285
+ * });
884
286
  * ```
287
+ *
288
+ * @param {GetCustomerAccountOrdersParameters} params - The parameters for fetching customer account orders:
289
+ * - `pageable` - Pagination parameters.
290
+ * - `locale` - The locale for the response.
291
+ * - `includeInactive` (optional) - Whether to include inactive orders.
292
+ * - `limit` (optional) - The maximum number of orders to return.
293
+ * - `offset` (optional) - The number of orders to skip before collecting results.
294
+ *
295
+ * @returns {Promise<GetCustomerAccountOrdersResponse>} - The response containing the customer account orders.
885
296
  */
886
- export declare function getCustomerAccountOrders({ pageable, locale, }: GetCustomerAccountOrdersParameters): Promise<GetCustomerAccountOrdersResponse>;
297
+ export declare function getCustomerAccountOrders(params: GetCustomerAccountOrdersParameters): Promise<GetCustomerAccountOrdersResponse>;
887
298
  /**
888
- * ## Get a customer account's users
889
- * ### APICODE(ACCOUNT-502)
890
- * @param {GetCustomerAccountUsersParameters} params - The parameters for the function
891
- * #### pageable - `object` | <strong style={{ color: 'red' }}>required</strong>
299
+ * ## Retrieve Customer Account Users
300
+ *
301
+ * This function retrieves the list of users associated with a specific customer account.
302
+ *
303
+ * ### API Code: ACCOUNT-502
892
304
  *
893
- * @returns {Promise<GetCustomerAccountUsersResponse>} - The response with the customer account users
305
+ * ### **Endpoint**: `GET /v1/shop/customer-accounts/users`
894
306
  *
895
- * @example
896
- * ### input
307
+ * | **Parameter** | **Type** | **Required** | **Description** |
308
+ * |-------------------|------------|--------------|-------------------------------------------------------------|
309
+ * | `pageable` | `object` | ✅ | Object containing pagination details: `page`, `size`, etc. |
310
+ * | `locale` | `string` | ❌ | The locale in which data should be retrieved. |
311
+ *
312
+ * ### **Returns**:
313
+ * A `Promise<GetCustomerAccountUsersResponse>` containing the list of users and pagination metadata.
314
+ *
315
+ * ### **Example Usage**:
897
316
  * ```typescript
898
- * const response = await getCustomerAccountUsers({ pageable: { page: 1, size: 10 }, locale: "string" });
899
- * ```
900
- * ### output
901
- * Response - <strong style={{ color: 'green' }}>200</strong>
902
- * ```json
903
- * {
904
- * "content": [
905
- * {
906
- * "civility": "MR",
907
- * "createdAt": "2024-12-11T10:28:21.123Z",
908
- * "customFieldValues": [
909
- * {
910
- * "customField": {
911
- * "externalId": "string",
912
- * "externalSource": "MIRAKL",
913
- * "faceted": true,
914
- * "id": "string",
915
- * "indexable": true,
916
- * "mandatory": true,
917
- * "name": {
918
- * "additionalProp1": "string",
919
- * "additionalProp2": "string",
920
- * "additionalProp3": "string"
921
- * },
922
- * "role": "PRODUCT_TAX_RATE",
923
- * "sealedTarget": "string",
924
- * "searchable": true,
925
- * "sortable": true,
926
- * "status": "ACTIVE"
927
- * },
928
- * "value": {}
929
- * }
930
- * ],
931
- * "email": "string",
932
- * "externalId": "string",
933
- * "firstName": "string",
934
- * "groups": [
935
- * "string"
936
- * ],
937
- * "id": "string",
938
- * "lastName": "string",
939
- * "mainOrganisationsId": "string",
940
- * "organisations": [
941
- * {
942
- * "id": "string",
943
- * "name": "string"
944
- * }
945
- * ],
946
- * "phone": "string",
947
- * "status": "ACTIVE",
948
- * "updatedAt": "2024-12-11T10:28:21.124Z"
949
- * }
950
- * ],
951
- * "empty": true,
952
- * "first": true,
953
- * "last": true,
954
- * "number": 0,
955
- * "numberOfElements": 0,
956
- * "pageable": {
957
- * "offset": 0,
958
- * "pageNumber": 0,
959
- * "pageSize": 0,
960
- * "paged": true,
961
- * "sort": [
962
- * {
963
- * "ascending": true,
964
- * "descending": true,
965
- * "direction": "ASC",
966
- * "ignoreCase": true,
967
- * "nullHandling": "NATIVE",
968
- * "property": "string"
969
- * }
970
- * ],
971
- * "unpaged": true
972
- * },
973
- * "size": 0,
974
- * "sort": [
975
- * {
976
- * "ascending": true,
977
- * "descending": true,
978
- * "direction": "ASC",
979
- * "ignoreCase": true,
980
- * "nullHandling": "NATIVE",
981
- * "property": "string"
982
- * }
983
- * ],
984
- * "totalElements": 0,
985
- * "totalPages": 0
986
- * }
317
+ * const response = await getCustomerAccountUsers({
318
+ * pageable: { page: 1, size: 10 },
319
+ * locale: "en-US",
320
+ * });
987
321
  * ```
988
322
  */
989
323
  export declare function getCustomerAccountUsers({ pageable, }: GetCustomerAccountUsersParameters): Promise<GetCustomerAccountUsersResponse>;
990
324
  /**
991
- * ## Create a customer account's organisation
992
- * ### APICODE(ACCOUNT-101)
993
- * @param {CreateCustomerAccountOrganisationParameters} params - The parameters for the function
994
- * #### externalId - `string` | <strong style={{ color: 'red' }}>required</strong>
995
- * #### name - `string` | <strong style={{ color: 'red' }}>required</strong>
996
- * #### parentId - `string`
325
+ * ## Create a Customer Account's Organisation
997
326
  *
998
- * @returns {Promise<CreateCustomerAccountOrganisationResponse>} - The response with the customer account organisation
327
+ * This function allows the creation of a new organisation within a customer account.
999
328
  *
1000
- * @example
1001
- * ### input
329
+ * ### API Code: ACCOUNT-101
330
+ *
331
+ * ### **Endpoint**: `POST /v1/shop/customer-accounts/organisations`
332
+ *
333
+ * | **Parameter** | **Type** | **Required** | **Description** |
334
+ * |-------------------|------------|--------------|---------------------------------------------------------------|
335
+ * | `externalId` | `string` | ✅ | A unique identifier for the organisation. |
336
+ * | `name` | `string` | ✅ | The name of the organisation. |
337
+ * | `parentId` | `string` | ❌ | The ID of the parent organisation, if applicable. |
338
+ *
339
+ * ### **Returns**:
340
+ * A `Promise<CreateCustomerAccountOrganisationResponse>` containing the newly created organisation data.
341
+ *
342
+ * ### **Example Usage**:
1002
343
  * ```typescript
1003
344
  * const response = await createCustomerAccountOrganisation({
1004
- * externalId: "string",
1005
- * name: "string",
1006
- * parentId: "string"
345
+ * externalId: "org123",
346
+ * name: "My Organisation",
347
+ * parentId: "parentOrgId"
1007
348
  * });
1008
349
  * ```
1009
- * ### output
1010
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
1011
- * ```json
1012
- * {
1013
- * "accountId": "string",
1014
- * "addresses": [
1015
- * {
1016
- * "additionalAddress": "string",
1017
- * "address": "string",
1018
- * "billing": true,
1019
- * "city": "string",
1020
- * "company": "string",
1021
- * "country": "string",
1022
- * "externalId": "string",
1023
- * "fullName": "string",
1024
- * "id": "string",
1025
- * "label": "string",
1026
- * "phone": "string",
1027
- * "shipping": true,
1028
- * "state": "string",
1029
- * "zipcode": "string"
1030
- * }
1031
- * ],
1032
- * children: ["string"],
1033
- * customFieldValues: [
1034
- * {
1035
- * customField: {
1036
- * externalId: "string",
1037
- * externalSource: "string",
1038
- * id: "string",
1039
- * mandatory: true,
1040
- * name: {
1041
- * additionalProp1: "string",
1042
- * additionalProp2: "string",
1043
- * additionalProp3: "string"
1044
- * },
1045
- * role: "string",
1046
- * sealedTarget: "string",
1047
- * status: "string",
1048
- * type: "string"
1049
- * },
1050
- * value: {}
1051
- * }
1052
- * ],
1053
- * id: "string",
1054
- * mainOrganisation: true
1055
- * name: "string",
1056
- * status: "ACTIVE",
1057
- * }
1058
- * ```
1059
350
  */
1060
351
  export declare function createCustomerAccountOrganisation({ externalId, name, parentId, }: CreateCustomerAccountOrganisationParameters): Promise<CreateCustomerAccountOrganisationResponse>;
1061
352
  /**
1062
353
  * ## Update a customer account's organisation
1063
- * ### APICODE(ACCOUNT-202)
1064
- * @param {UpdateCustomerAccountOrganisationParameters} params - The parameters for the function
1065
- * #### organisationId - `string` | <strong style={{ color: 'red' }}>required</strong>
1066
- * #### name - `string`
1067
- * #### parentId - `string`
1068
- * #### status - `string`
1069
354
  *
1070
- * @returns {Promise<UpdateCustomerAccountOrganisationResponse>} - The response with the updated customer account organisation
355
+ * This function allows updating an existing organisation within a customer account.
1071
356
  *
1072
- * @example
1073
- * ### input
357
+ * ### API Code: ACCOUNT-202
358
+ *
359
+ * ### **Endpoint**: `PUT /v1/shop/customer-accounts/organisations/{organisationId}`
360
+ *
361
+ * | **Parameter** | **Type** | **Required** | **Description** |
362
+ * |--------------------|------------|--------------|---------------------------------------------------------------|
363
+ * | `organisationId` | `string` | ✅ | The unique identifier of the organisation to be updated. |
364
+ * | `name` | `string` | ❌ | The new name of the organisation. |
365
+ * | `parentId` | `string` | ❌ | The new parent ID for the organisation, if applicable. |
366
+ * | `status` | `string` | ❌ | The new status of the organisation (e.g., ACTIVE, INACTIVE). |
367
+ *
368
+ * ### **Returns**:
369
+ * A `Promise<UpdateCustomerAccountOrganisationResponse>` containing the updated organisation data.
370
+ *
371
+ * ### **Example Usage**:
1074
372
  * ```typescript
1075
373
  * const response = await updateCustomerAccountOrganisation({
1076
- * organisationId: "string",
1077
- * name: "string",
1078
- * parentId: "string",
1079
- * status: "ACTIVE"
374
+ * organisationId: "org12345",
375
+ * name: "Updated Organisation Name",
376
+ * parentId: "parentOrg123",
377
+ * status: "ACTIVE",
1080
378
  * });
1081
- * ```
1082
- * ### output
1083
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
1084
- * ```json
1085
- * {
1086
- * "accountId": "string",
1087
- * "addresses": [
1088
- * {
1089
- * "additionalAddress": "string",
1090
- * "address": "string",
1091
- * "billing": true,
1092
- * "city": "string",
1093
- * "company": "string",
1094
- * "country": "string",
1095
- * "externalId": "string",
1096
- * "fullName": "string",
1097
- * "id": "string",
1098
- * "label": "string",
1099
- * "phone": "string",
1100
- * "shipping": true,
1101
- * "state": "string",
1102
- * "zipcode": "string"
1103
- * }
1104
- * ],
1105
- * "children": ["string"],
1106
- * "customFieldValues": [
1107
- * {
1108
- * "customField": {
1109
- * "externalId": "string",
1110
- * "externalSource": "string",
1111
- * "id": "string",
1112
- * "mandatory": true,
1113
- * "name": {
1114
- * "additionalProp1": "string",
1115
- * "additionalProp2": "string",
1116
- * "additionalProp3": "string"
1117
- * },
1118
- * "role": "string",
1119
- * "sealedTarget": "string",
1120
- * "status": "string",
1121
- * "type": "string"
1122
- * },
1123
- * "value": {}
1124
- * }
1125
- * ],
1126
- * "id": "string",
1127
- * "mainOrganisation": true,
1128
- * "name": "string",
1129
- * "status": "ACTIVE"
1130
- * }
379
+ *
380
+ * console.log(response);
1131
381
  * ```
1132
382
  */
1133
383
  export declare function updateCustomerAccountOrganisation({ organisationId, name, parentId, status, }: UpdateCustomerAccountOrganisationParameters): Promise<UpdateCustomerAccountOrganisationResponse>;
1134
384
  /**
1135
385
  * @deprecated
1136
386
  * ## Get organisations from customer account
1137
- * ### APICODE(ACCOUNT-503)
1138
- * @returns {Promise<GetCustomerAccountOrganisationResponse>} - The response with the customer account organisations
1139
387
  *
1140
- * @example
1141
- * ### input
388
+ * This function retrieves all organisations associated with a customer account.
389
+ *
390
+ * ### API Code: ACCOUNT-503
391
+ *
392
+ * ### **Endpoint**: `GET /v1/shop/customer-accounts/organisations`
393
+ *
394
+ * ### **Returns**:
395
+ * A `Promise<GetCustomerAccountOrganisationResponse>` containing the list of customer account organisations.
396
+ *
397
+ * ### **Example Usage**:
1142
398
  * ```typescript
1143
399
  * const response = await getCustomerAccountOrganisations();
1144
- * ```
1145
- * ### output
1146
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
1147
- * ```json
1148
- * {
1149
- * "content": [
1150
- * {
1151
- * "accountId": "string",
1152
- * "addresses": [
1153
- * {
1154
- * "additionalAddress": "string",
1155
- * "address": "string",
1156
- * "billing": true,
1157
- * "city": "string",
1158
- * "company": "string",
1159
- * "country": "string",
1160
- * "externalId": "string",
1161
- * "fullName": "string",
1162
- * "id": "string",
1163
- * "label": "string",
1164
- * "phone": "string",
1165
- * "shipping": true,
1166
- * "state": "string",
1167
- * "zipcode": "string"
1168
- * }
1169
- * ],
1170
- * "children": ["string"],
1171
- * "customFieldValues": [
1172
- * {
1173
- * "customField": {
1174
- * "externalId": "string",
1175
- * "externalSource": "string",
1176
- * "id": "string",
1177
- * "mandatory": true,
1178
- * "name": {
1179
- * "additionalProp1": "string",
1180
- * "additionalProp2": "string",
1181
- * "additionalProp3": "string"
1182
- * },
1183
- * "role": "string",
1184
- * "sealedTarget": "string",
1185
- * "status": "string",
1186
- * "type": "string"
1187
- * },
1188
- * "value": {}
1189
- * }
1190
- * ],
1191
- * "id": "string",
1192
- * "mainOrganisation": true,
1193
- * "name": "string",
1194
- * "status": "ACTIVE"
1195
- * }
1196
- * ],
1197
- * "empty": true,
1198
- * "first": true,
1199
- * "last": true,
1200
- * "number": 0,
1201
- * "numberOfElements": 0,
1202
- * "pageable": {
1203
- * "offset": 0,
1204
- * "pageNumber": 0,
1205
- * "pageSize": 0,
1206
- * "paged": true,
1207
- * "sort": [
1208
- * {
1209
- * "ascending": true,
1210
- * "descending": true,
1211
- * "direction": "ASC",
1212
- * "ignoreCase": true,
1213
- * "nullHandling": "NATIVE",
1214
- * "property": "string"
1215
- * }
1216
- * ],
1217
- * "unpaged": true
1218
- * },
1219
- * "size": 0,
1220
- * "sort": [
1221
- * {
1222
- * "ascending": true,
1223
- * "descending": true,
1224
- * "direction": "ASC",
1225
- * "ignoreCase": true,
1226
- * "nullHandling": "NATIVE",
1227
- * "property": "string"
1228
- * }
1229
- * ],
1230
- * "totalElements": 0,
1231
- * "totalPages": 0
1232
- * }
400
+ * console.log(response);
1233
401
  * ```
1234
402
  */
1235
403
  export declare function getCustomerAccountOrganisations(): Promise<GetCustomerAccountOrganisationResponse>;
1236
404
  /**
1237
405
  * ## Get addresses from a customer account organisation
1238
- * ### APICODE(ACCOUNT-505)
1239
- * @param {GetCustomerAccountOrganisationAddressesParameters} params - The parameters for the function
1240
- * #### organisationId - `string` | <strong style={{ color: 'red' }}>required</strong>
1241
406
  *
1242
- * @returns {Promise<GetCustomerAccountOrganisationAddressesResponse>} - The response with the customer account organisation addresses
407
+ * This function retrieves all the addresses associated with a given customer account organisation.
408
+ *
409
+ * ### API Code: ACCOUNT-505
1243
410
  *
1244
- * @example
1245
- * ### input
411
+ * ### **Endpoint**: `GET /v1/shop/customer-accounts/organisations/{organisationId}/addresses`
412
+ *
413
+ * | **Parameter** | **Type** | **Required** | **Description** |
414
+ * |---------------------|------------|--------------|--------------------------------------------------------------------|
415
+ * | `organisationId` | `string` | ✅ | The unique identifier of the organisation whose addresses are being retrieved. |
416
+ *
417
+ * ### **Returns**:
418
+ * A `Promise<GetCustomerAccountOrganisationAddressesResponse>` containing the list of addresses for the specified customer account organisation.
419
+ *
420
+ * ### **Example Usage**:
1246
421
  * ```typescript
1247
- * const response = await getCustomerAccountOrganisationAddresses({ organisationId: "string" });
1248
- * ```
1249
- * ### output
1250
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
1251
- * ```json
1252
- * [
1253
- * {
1254
- * "additionalAddress": "string",
1255
- * "address": "string",
1256
- * "billing": true,
1257
- * "city": "string",
1258
- * "company": "string",
1259
- * "country": "string",
1260
- * "externalId": "string",
1261
- * "fullName": "string",
1262
- * "id": "string",
1263
- * "label": "string",
1264
- * "phone": "string",
1265
- * "shipping": true,
1266
- * "state": "string",
1267
- * "zipcode": "string"
1268
- * }
1269
- * ]
422
+ * const addresses = await getCustomerAccountOrganisationAddresses({ organisationId: "org12345" });
423
+ * console.log(addresses);
1270
424
  * ```
1271
425
  */
1272
426
  export declare function getCustomerAccountOrganisationAddresses({ organisationId, }: GetCustomerAccountOrganisationAddressesParameters): Promise<GetCustomerAccountOrganisationAddressesResponse>;
1273
427
  /**
1274
428
  * ## Delete an address from a customer account organisation
1275
- * ### APICODE(ADDRESS-301)
1276
- * @param {DeleteCustomerAccountOrganisationAddressParameters} params - The parameters for the function
1277
- * #### organisationId - `string` | <strong style={{ color: 'red' }}>required</strong>
1278
- * #### addressId - `string` | <strong style={{ color: 'red' }}>required</strong>
1279
429
  *
1280
- * @returns {Promise<void>} - The response with the customer account organisation address
430
+ * This function deletes a specific address from a given customer account organisation.
1281
431
  *
1282
- * @example
1283
- * ### input
1284
- * ```typescript
1285
- * const response = await deleteCustomerAccountOrganisationAddress({ organisationId: "string", addressId: "string" });
1286
- * ```
1287
- * ### output
1288
- * Response - <strong style={{ color: 'green' }}>204</strong> - No Content
1289
- * ```json
432
+ * ### API Code: ADDRESS-301
433
+ *
434
+ * ### **Endpoint**: `DELETE /v1/shop/customer-accounts/organisations/{organisationId}/addresses/{addressId}`
1290
435
  *
436
+ * | **Parameter** | **Type** | **Required** | **Description** |
437
+ * |---------------------|------------|--------------|---------------------------------------------------------------------|
438
+ * | `organisationId` | `string` | ✅ | The unique identifier of the organisation from which the address will be deleted. |
439
+ * | `addressId` | `string` | ✅ | The unique identifier of the address to delete. |
440
+ *
441
+ * ### **Returns**:
442
+ * A `Promise<void>` that resolves when the address is successfully deleted.
443
+ *
444
+ * ### **Example Usage**:
445
+ * ```typescript
446
+ * await deleteCustomerAccountOrganisationAddress({
447
+ * organisationId: "org12345",
448
+ * addressId: "addr67890",
449
+ * });
450
+ * console.log('Address deleted successfully.');
1291
451
  * ```
1292
452
  */
1293
453
  export declare function deleteCustomerAccountOrganisationAddress({ organisationId, addressId, }: DeleteCustomerAccountOrganisationAddressParameters): Promise<void>;
1294
454
  /**
1295
455
  * ## Update an address from a customer account organisation
1296
- * ### APICODE(ADDRESS-201)
1297
- * @param {UpdateCustomerAccountOrganisationAddressParameters} params - The parameters for the function
1298
- * #### organisationId - `string` | <strong style={{ color: 'red' }}>required</strong>
1299
- * #### addressId - `string` | <strong style={{ color: 'red' }}>required</strong>
1300
- * #### additionalAddress - `string`
1301
- * #### address - `string`
1302
- * #### billing - `boolean`
1303
- * #### city - `string`
1304
- * #### company - `string`
1305
- * #### country - `string`
1306
- * #### fullName - `string`
1307
- * #### label - `string`
1308
- * #### phone - `string`
1309
- * #### shipping - `boolean`
1310
- * #### state - `string`
1311
- * #### zipcode - `string`
1312
- *
1313
- * @returns {Promise<UpdateCustomerAccountOrganisationAddressResponse>} - The response with the customer account organisation address
1314
- *
1315
- * @example
1316
- * ### input
456
+ *
457
+ * This function allows updating an existing address within a customer account organisation.
458
+ *
459
+ * ### API Code: ADDRESS-201
460
+ *
461
+ * ### **Endpoint**: `PUT /v1/shop/customer-accounts/organisations/{organisationId}/addresses/{addressId}`
462
+ *
463
+ * | **Parameter** | **Type** | **Required** | **Description** |
464
+ * |----------------------|------------|--------------|-------------------------------------------------------------------|
465
+ * | `organisationId` | `string` | ✅ | The unique identifier of the organisation containing the address. |
466
+ * | `addressId` | `string` | ✅ | The unique identifier of the address to be updated. |
467
+ * | `additionalAddress` | `string` | ❌ | Additional address information (optional). |
468
+ * | `address` | `string` | ❌ | The street address (optional). |
469
+ * | `billing` | `boolean` | ❌ | Whether the address is for billing purposes (optional). |
470
+ * | `city` | `string` | ❌ | The city of the address (optional). |
471
+ * | `company` | `string` | ❌ | The company associated with the address (optional). |
472
+ * | `country` | `string` | ❌ | The country of the address (optional). |
473
+ * | `fullName` | `string` | ❌ | The full name of the person associated with the address (optional).|
474
+ * | `label` | `string` | ❌ | A label for the address (optional). |
475
+ * | `phone` | `string` | ❌ | The phone number associated with the address (optional). |
476
+ * | `shipping` | `boolean` | ❌ | Whether the address is for shipping purposes (optional). |
477
+ * | `state` | `string` | ❌ | The state or region of the address (optional). |
478
+ * | `zipcode` | `string` | ❌ | The postal code for the address (optional). |
479
+ *
480
+ * ### **Returns**:
481
+ * A `Promise<UpdateCustomerAccountOrganisationAddressResponse>` containing the updated address data.
482
+ *
483
+ * ### **Example Usage**:
1317
484
  * ```typescript
1318
485
  * const response = await updateCustomerAccountOrganisationAddress({
1319
- * organisationId: "string",
1320
- * addressId: "string",
1321
- * additionalAddress: "string",
1322
- * address: "string",
486
+ * organisationId: "org12345",
487
+ * addressId: "address12345",
488
+ * additionalAddress: "Suite 5",
489
+ * address: "123 Main St",
1323
490
  * billing: true,
1324
- * city: "string",
1325
- * company: "string",
1326
- * country: "string",
1327
- * fullName: "string",
1328
- * label: "string",
1329
- * phone: "string",
491
+ * city: "New York",
492
+ * company: "Company Name",
493
+ * country: "USA",
494
+ * fullName: "John Doe",
495
+ * label: "Primary Address",
496
+ * phone: "+123456789",
1330
497
  * shipping: true,
1331
- * state: "string",
1332
- * zipcode: "string"
498
+ * state: "NY",
499
+ * zipcode: "10001"
1333
500
  * });
1334
- * ```
1335
- * ### output
1336
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
1337
- * ```json
1338
- * {
1339
- * "additionalAddress": "string",
1340
- * "address": "string",
1341
- * "billing": true,
1342
- * "city": "string",
1343
- * "company": "string",
1344
- * "country": "string",
1345
- * "externalId": "string",
1346
- * "fullName": "string",
1347
- * "id": "string",
1348
- * "label": "string",
1349
- * "phone": "string",
1350
- * "shipping": true,
1351
- * "state": "string",
1352
- * "zipcode": "string"
1353
- * }
501
+ *
502
+ * console.log(response);
1354
503
  * ```
1355
504
  */
1356
505
  export declare function updateCustomerAccountOrganisationAddress({ organisationId, addressId, additionalAddress, address, billing, city, company, country, fullName, label, phone, shipping, state, zipcode, }: UpdateCustomerAccountOrganisationAddressParameters): Promise<UpdateCustomerAccountOrganisationAddressResponse>;
1357
506
  /**
1358
- * ##Get orders from a customer account organisation
1359
- * ### APICODE(ORDER-555)
1360
- * @param {GetCustomerAccountOrganisationOrdersParameters} params - The parameters for the function
1361
- * #### organisationId - `string` | <strong style={{ color: 'red' }}>required</strong>
1362
- * #### pageable - `object` | <strong style={{ color: 'red' }}>required</strong>
1363
- * #### locale - `string` | <strong style={{ color: 'red' }}>required</strong>
507
+ * ## Get orders from a customer account organisation
508
+ *
509
+ * This function retrieves the orders associated with a specific customer account organisation.
510
+ *
511
+ * ### API Code: ORDER-555
512
+ *
513
+ * ### **Endpoint**: `GET /v1/shop/customer-accounts/organisations/{organisationId}/orders`
514
+ *
515
+ * | **Parameter** | **Type** | **Required** | **Description** |
516
+ * |----------------------|------------|--------------|---------------------------------------------------------------------------|
517
+ * | `organisationId` | `string` | ✅ | The unique identifier of the organisation whose orders need to be fetched. |
518
+ * | `pageable` | `object` | ✅ | The pagination parameters for the orders (e.g., page, size, sort). |
519
+ * | `locale` | `string` | ✅ | The locale for the response (e.g., "en_US"). |
1364
520
  *
1365
- * @returns {Promise<GetCustomerAccountOrganisationOrdersResponse>} - The response with the customer account organisation orders
521
+ * ### **Returns**:
522
+ * A `Promise<GetCustomerAccountOrganisationOrdersResponse>` containing the list of orders for the organisation.
1366
523
  *
1367
- * @example
1368
- * ### input
524
+ * ### **Example Usage**:
1369
525
  * ```typescript
1370
- * const response = await getCustomerAccountOrganisationOrders({ organisationId: "string", pageable: { page: 1, size: 10 }, locale: "string" });
1371
- * ```
1372
- * ### output
1373
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
1374
- * ```json
1375
- * {
1376
- * "content": [
1377
- * {
1378
- * "billingAddressSnapshot": {
1379
- * "additionalAddress": "string",
1380
- * "address": "string",
1381
- * "city": "string",
1382
- * "company": "string",
1383
- * "country": "string",
1384
- * "externalId": "string",
1385
- * "fullName": "string",
1386
- * "id": "string",
1387
- * "label": "string",
1388
- * "phone": "string",
1389
- * "state": "string",
1390
- * "zipcode": "string"
1391
- * },
1392
- * "channel": "DESKTOP",
1393
- * "createdAt": "2024-12-11T10:28:21.123Z",
1394
- * "customFieldValues": [
1395
- * {
1396
- * "customField": {
1397
- * "externalId": "string",
1398
- * "externalSource": "MIRAKL",
1399
- * "faceted": true,
1400
- * "id": "string",
1401
- * "indexable": true,
1402
- * "mandatory": true,
1403
- * "name": {
1404
- * "additionalProp1": "string",
1405
- * "additionalProp2": "string",
1406
- * "additionalProp3": "string"
1407
- * },
1408
- * "role": "PRODUCT_TAX_RATE",
1409
- * "sealedTarget": "string",
1410
- * "searchable": true,
1411
- * "sortable": true,
1412
- * "status": "ACTIVE"
1413
- * },
1414
- * "value": {}
1415
- * }
1416
- * ],
1417
- * "customerUserSnapshot": {
1418
- * "accountExternalId": "string",
1419
- * "accountId": "string",
1420
- * "accountName": "string",
1421
- * "accountTvaNumber": "string",
1422
- * "civility": "MR",
1423
- * "email": "string",
1424
- * "externalId": "string",
1425
- * "firstName": "string",
1426
- * "id": "string",
1427
- * "lastName": "string",
1428
- * "phone": "string"
1429
- * },
1430
- * "exportStatus": "EXPORTED",
1431
- * "externalId": "string",
1432
- * "externalSource": "MIRAKL",
1433
- * "fulfillmentMessage": "string",
1434
- * "id": "string",
1435
- * "incidentDeclared": true,
1436
- * "initialPrice": {
1437
- * "priceWithTax": 0,
1438
- * "priceWithoutTax": 0,
1439
- * "shippingPriceWithTax": 0,
1440
- * "shippingPriceWithoutTax": 0,
1441
- * "totalPriceWithTax": 0,
1442
- * "totalPriceWithoutTax": 0
1443
- * },
1444
- * "leadTimeToShip": 0,
1445
- * "lines": [
1446
- * {
1447
- * "confirmedQuantity": 0,
1448
- * "customFieldValues": [
1449
- * {
1450
- * "customField": {
1451
- * "externalId": "string",
1452
- * "externalSource": "MIRAKL",
1453
- * "faceted": true,
1454
- * "id": "string",
1455
- * "indexable": true,
1456
- * "mandatory": true,
1457
- * "name": {
1458
- * "additionalProp1": "string",
1459
- * "additionalProp2": "string",
1460
- * "additionalProp3": "string"
1461
- * },
1462
- * "role": "PRODUCT_TAX_RATE",
1463
- * "sealedTarget": "string",
1464
- * "searchable": true,
1465
- * "sortable": true,
1466
- * "status": "ACTIVE"
1467
- * },
1468
- * "value": {}
1469
- * }
1470
- * ],
1471
- * "externalId": "string",
1472
- * "externalSource": "MIRAKL",
1473
- * "id": "string",
1474
- * "incidentDeclared": true,
1475
- * "offerInventorySnapshotDto": {
1476
- * "currency": "USD",
1477
- * "customFieldValueSnapshots": [
1478
- * {
1479
- * "customFieldSnapshotDto": {
1480
- * "externalId": "string",
1481
- * "externalSource": "string",
1482
- * "mandatory": true,
1483
- * "names": {
1484
- * "additionalProp1": "string",
1485
- * "additionalProp2": "string",
1486
- * "additionalProp3": "string"
1487
- * },
1488
- * "role": "string",
1489
- * "sealedTarget": "string",
1490
- * "status": "string",
1491
- * "type": "string"
1492
- * },
1493
- * "value": "string"
1494
- * }
1495
- * ],
1496
- * "externalSource": "MIRAKL",
1497
- * "offerInventoryExternalId": "string",
1498
- * "packingType": "BOX",
1499
- * "productTaxCode": "string",
1500
- * "productTaxRate": 0,
1501
- * "quantityPerItem": 0,
1502
- * "shippingTaxCode": "string",
1503
- * "shippingTaxRate": 0
1504
- * },
1505
- * "offerPriceSnapshotDto": {
1506
- * "confirmedProductPriceWithoutTaxes": 0,
1507
- * "itemPerPack": 0,
1508
- * "offerPriceExternalId": "string",
1509
- * "offerPriceType": "PUBLIC",
1510
- * "offerPriceTypeValue": "string",
1511
- * "productPriceWithTaxes": 0,
1512
- * "productPriceWithoutTaxes": 0,
1513
- * "productTaxAmount": 0,
1514
- * "shippingPriceWithTaxes": 0,
1515
- * "shippingPriceWithoutTaxes": 0,
1516
- * "shippingTaxAmount": 0,
1517
- * "totalPriceWithTaxes": 0,
1518
- * "totalPriceWithoutTaxes": 0,
1519
- * "totalProductPriceWithTaxes": 0,
1520
- * "totalProductPriceWithoutTaxes": 0,
1521
- * "totalProductTaxAmount": 0,
1522
- * "totalTaxAmount": 0
1523
- * },
1524
- * "orderLogisticLinePriceDto": {
1525
- * "confirmedPrice": 0,
1526
- * "currency": "USD",
1527
- * "externalOfferId": "string",
1528
- * "externalSource": "MIRAKL",
1529
- * "itemPerPack": 0,
1530
- * "itemPriceWithoutTaxes": 0,
1531
- * "packingType": "BOX",
1532
- * "priceWithTaxes": 0,
1533
- * "quantityPerItem": 0,
1534
- * "shippingPriceWithTaxes": 0,
1535
- * "shippingPriceWithoutTaxes": 0,
1536
- * "shippingTaxAmount": 0,
1537
- * "taxAmount": 0,
1538
- * "taxInformation": {
1539
- * "productTaxAmount": 0,
1540
- * "productTaxCode": "string",
1541
- * "productTaxRate": 0,
1542
- * "shippingTaxAmount": 0,
1543
- * "shippingTaxCode": "string",
1544
- * "shippingTaxRate": 0
1545
- * },
1546
- * "taxRate": 0,
1547
- * "totalItemPrice": 0,
1548
- * "totalItemPriceWithTaxes": 0,
1549
- * "totalItemTaxAmount": 0,
1550
- * "totalPriceWithTaxes": 0,
1551
- * "totalPriceWithoutTaxes": 0,
1552
- * "totalTaxes": 0,
1553
- * "type": "PUBLIC",
1554
- * "typeValue": "string"
1555
- * },
1556
- * "orderLogisticLineProductDto": {
1557
- * "brand": "string",
1558
- * "classificationCategory": "string",
1559
- * "defaultLanguage": "EN",
1560
- * "description": "string",
1561
- * "externalId": "string",
1562
- * "externalSource": "MIRAKL",
1563
- * "name": "string",
1564
- * "productAttributeValues": [
1565
- * {
1566
- * "attributeExternalId": "string",
1567
- * "attributeExternalSource": "string",
1568
- * "attributeId": "string",
1569
- * "attributeName": {
1570
- * "additionalProp1": "string",
1571
- * "additionalProp2": "string",
1572
- * "additionalProp3": "string"
1573
- * },
1574
- * "attributeType": "string",
1575
- * "attributeValue": "string",
1576
- * "id": "string"
1577
- * }
1578
- * ],
1579
- * "productUnit": "string",
1580
- * "sku": "string",
1581
- * "tags": [
1582
- * "string"
1583
- * ]
1584
- * },
1585
- * "orderLogisticLineProductVariantDto": {
1586
- * "attributeValues": [
1587
- * {
1588
- * "attributeExternalId": "string",
1589
- * "attributeExternalSource": "string",
1590
- * "attributeId": "string",
1591
- * "attributeName": {
1592
- * "additionalProp1": "string",
1593
- * "additionalProp2": "string",
1594
- * "additionalProp3": "string"
1595
- * },
1596
- * "attributeType": "string",
1597
- * "attributeValue": "string",
1598
- * "id": "string"
1599
- * }
1600
- * ],
1601
- * "description": "string",
1602
- * "ean": "string",
1603
- * "externalId": "string",
1604
- * "externalSource": "MIRAKL",
1605
- * "mainImageUrl": "string",
1606
- * "mpn": "string",
1607
- * "name": "string",
1608
- * "productMediaInfoDTOS": [
1609
- * {
1610
- * "isMain": true,
1611
- * "urls": [
1612
- * {
1613
- * "formatType": "string",
1614
- * "heightInPx": 0,
1615
- * "sizeType": "string",
1616
- * "url": "string",
1617
- * "widthInPx": 0
1618
- * }
1619
- * ]
1620
- * }
1621
- * ],
1622
- * "sku": "string"
1623
- * },
1624
- * "paymentStatus": "WAITING_REFUND",
1625
- * "quantity": 0,
1626
- * "quoteLineExternalId": "string",
1627
- * "status": "CANCELED"
1628
- * }
1629
- * ],
1630
- * "orderCommercialId": "string",
1631
- * "orderCommercialReference": "string",
1632
- * "orderLogisticPrices": {
1633
- * "currency": "USD",
1634
- * "totalPriceWithTax": 0,
1635
- * "totalPriceWithoutTax": 0,
1636
- * "totalProductTaxAmount": 0,
1637
- * "totalProductWithTax": 0,
1638
- * "totalProductWithoutTax": 0,
1639
- * "totalShippingFeesWithTax": 0,
1640
- * "totalShippingFeesWithoutTax": 0,
1641
- * "totalShippingTaxAmount": 0,
1642
- * "totalTaxAmount": 0
1643
- * },
1644
- * "orderOrigin": "CART",
1645
- * "partiallyDeclinedBySupplier": true,
1646
- * "paymentOption": "BANK_WIRE",
1647
- * "paymentStatus": "AUTHORIZED",
1648
- * "reference": "string",
1649
- * "shippingAddressSnapshot": {
1650
- * "additionalAddress": "string",
1651
- * "address": "string",
1652
- * "city": "string",
1653
- * "company": "string",
1654
- * "country": "string",
1655
- * "externalId": "string",
1656
- * "fullName": "string",
1657
- * "id": "string",
1658
- * "label": "string",
1659
- * "phone": "string",
1660
- * "state": "string",
1661
- * "zipcode": "string"
1662
- * },
1663
- * "shippingTrackingUrl": "string",
1664
- * "shippingType": "string",
1665
- * "status": "CREATING",
1666
- * "supplierSnapshot": {
1667
- * "description": "string",
1668
- * "externalId": "string",
1669
- * "id": "string",
1670
- * "name": "string",
1671
- * "paymentDueDate": {
1672
- * "paymentDueDateDelay": 0,
1673
- * "paymentDueDateMode": "SIMPLE"
1674
- * },
1675
- * "returnPolicy": "string",
1676
- * "totalOffers": 0,
1677
- * "totalOrders": 0
1678
- * },
1679
- * "updatedAt": "2024-12-11T10:28:21.124Z",
1680
- * "validatedAt": "2024-12-11T10:28:21.124Z"
1681
- * }
1682
- * ],
1683
- * "empty": true,
1684
- * "first": true,
1685
- * "last": true,
1686
- * "number": 0,
1687
- * "numberOfElements": 0,
1688
- * "pageable": {
1689
- * "offset": 0,
1690
- * "pageNumber": 0,
1691
- * "pageSize": 0,
1692
- * "paged": true,
1693
- * "sort": [
1694
- * {
1695
- * "ascending": true,
1696
- * "descending": true,
1697
- * "direction": "ASC",
1698
- * "ignoreCase": true,
1699
- * "nullHandling": "NATIVE",
1700
- * "property": "string"
1701
- * }
1702
- * ],
1703
- * "unpaged": true
1704
- * },
1705
- * "size": 0,
1706
- * "sort": [
1707
- * {
1708
- * "ascending": true,
1709
- * "descending": true,
1710
- * "direction": "ASC",
1711
- * "ignoreCase": true,
1712
- * "nullHandling": "NATIVE",
1713
- * "property": "string"
1714
- * }
1715
- * ],
1716
- * "totalElements": 0,
1717
- * "totalPages": 0
1718
- * }
526
+ * const response = await getCustomerAccountOrganisationOrders({
527
+ * organisationId: "org12345",
528
+ * pageable: { page: 1, size: 10, sort: [{ property: "createdAt", direction: "DESC" }] },
529
+ * locale: "en_US"
530
+ * });
531
+ *
532
+ * console.log(response);
1719
533
  * ```
1720
534
  */
1721
535
  export declare function getCustomerAccountOrganisationOrders({ organisationId, pageable, locale, }: GetCustomerAccountOrganisationOrdersParameters): Promise<GetCustomerAccountOrganisationOrdersResponse>;
1722
536
  /**
1723
537
  * ## Get users from a customer account organisation
1724
- * ### APICODE(ACCOUNT-504)
1725
- * @param {GetCustomerAccountOrganisationUsersParameters} params - The parameters for the function
1726
- * #### organisationId - `string` | <strong style={{ color: 'red' }}>required</strong>
1727
- * #### pageable - `object` | <strong style={{ color: 'red' }}>required</strong>
1728
538
  *
1729
- * @returns {Promise<GetCustomerAccountOrganisationUsersResponse>} - The response with the customer account organisation users
539
+ * This function retrieves the list of users associated with a specific customer account organisation.
540
+ *
541
+ * ### API Code: ACCOUNT-504
542
+ *
543
+ * ### **Endpoint**: `GET /v1/shop/customer-accounts/organisations/{organisationId}/users`
544
+ *
545
+ * | **Parameter** | **Type** | **Required** | **Description** |
546
+ * |----------------------|------------|--------------|---------------------------------------------------------------------------|
547
+ * | `organisationId` | `string` | ✅ | The unique identifier of the organisation whose users need to be fetched. |
548
+ * | `pageable` | `object` | ✅ | The pagination parameters for the users (e.g., page, size, sort). |
1730
549
  *
1731
- * @example
1732
- * ### input
550
+ * ### **Returns**:
551
+ * A `Promise<GetCustomerAccountOrganisationUsersResponse>` containing the list of users for the organisation.
552
+ *
553
+ * ### **Example Usage**:
1733
554
  * ```typescript
1734
- * const response = await getCustomerAccountOrganisationUsers({ organisationId: "string", pageable: { page: 1, size: 10 }, locale: "string" });
1735
- * ```
1736
- * ### output
1737
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
1738
- * ```json
1739
- * {
1740
- * "content": [
1741
- * {
1742
- * "civility": "MR",
1743
- * "createdAt": "2024-12-11T10:28:21.123Z",
1744
- * "firstName": "string",
1745
- * "groups": [
1746
- * "string"
1747
- * ],
1748
- * "id": "string",
1749
- * "lastName": "string",
1750
- * "phone": "string",
1751
- * "status": "ACTIVE",
1752
- * }
1753
- * ],
1754
- * "empty": true,
1755
- * "first": true,
1756
- * "last": true,
1757
- * "number": 0,
1758
- * "numberOfElements": 0,
1759
- * "pageable": {
1760
- * "offset": 0,
1761
- * "pageNumber": 0,
1762
- * "pageSize": 0,
1763
- * "paged": true,
1764
- * "sort": [
1765
- * {
1766
- * "ascending": true,
1767
- * "descending": true,
1768
- * "direction": "ASC",
1769
- * "ignoreCase": true,
1770
- * "nullHandling": "NATIVE",
1771
- * "property": "string"
1772
- * }
1773
- * ],
1774
- * "unpaged": true
1775
- * },
1776
- * "size": 0,
1777
- * "sort": [
1778
- * {
1779
- * "ascending": true,
1780
- * "descending": true,
1781
- * "direction": "ASC",
1782
- * "ignoreCase": true,
1783
- * "nullHandling": "NATIVE",
1784
- * "property": "string"
1785
- * }
1786
- * ],
1787
- * "totalElements": 0,
1788
- * "totalPages": 0
1789
- * }
555
+ * const response = await getCustomerAccountOrganisationUsers({
556
+ * organisationId: "org12345",
557
+ * pageable: { page: 1, size: 10, sort: [{ property: "createdAt", direction: "DESC" }] },
558
+ * });
559
+ *
560
+ * console.log(response);
1790
561
  * ```
1791
562
  */
1792
563
  export declare function getCustomerAccountOrganisationUsers({ organisationId, pageable, }: GetCustomerAccountOrganisationUsersParameters): Promise<GetCustomerAccountOrganisationUsersResponse>;
1793
564
  /**
1794
565
  * ## Update a customer account organisation user
1795
- * ### APICODE(ACCOUNT-202)
1796
- * @param {UpdateCustomerAccountOrganisationUserParameters} params - The parameters for the function
1797
- * #### organisationId - `string` | <strong style={{ color: 'red' }}>required</strong>
1798
- * #### customerUserId - `string` | <strong style={{ color: 'red' }}>required</strong>
1799
- * #### civility - `string`
1800
- * #### customFieldValues - `object[]`
1801
- * #### firstName - `string`
1802
- * #### lastName - `string`
1803
- * #### phone - `string`
1804
- *
1805
- * @returns {Promise<UpdateCustomerAccountOrganisationUserResponse>} - The response with the updated customer account organisation user
1806
- *
1807
- * @example
1808
- * ### input
566
+ *
567
+ * This function updates the details of a specific user within a customer account organisation.
568
+ *
569
+ * ### API Code: ACCOUNT-202
570
+ *
571
+ * ### **Endpoint**: `PUT /v1/shop/customer-accounts/organisations/{organisationId}/users/{customerUserId}`
572
+ *
573
+ * | **Parameter** | **Type** | **Required** | **Description** |
574
+ * |-------------------------|-------------|--------------|---------------------------------------------------------------------------------|
575
+ * | `organisationId` | `string` | ✅ | The unique identifier of the organisation. |
576
+ * | `customerUserId` | `string` | ✅ | The unique identifier of the user to update. |
577
+ * | `civility` | `string` | ❌ | Civility of the user (e.g., "MR", "MRS"). |
578
+ * | `customFieldValues` | `object[]` | ❌ | Array of custom field values for the user. |
579
+ * | `firstName` | `string` | ❌ | First name of the user. |
580
+ * | `lastName` | `string` | ❌ | Last name of the user. |
581
+ * | `phone` | `string` | ❌ | Phone number of the user. |
582
+ *
583
+ * ### **Returns**:
584
+ * A `Promise<UpdateCustomerAccountOrganisationUserResponse>` containing the details of the updated user.
585
+ *
586
+ * ### **Example Usage**:
1809
587
  * ```typescript
1810
588
  * const response = await updateCustomerAccountOrganisationUser({
1811
- * organisationId: "string",
1812
- * customerUserId: "string",
589
+ * organisationId: "org12345",
590
+ * customerUserId: "user67890",
1813
591
  * civility: "MR",
1814
592
  * customFieldValues: [
1815
593
  * {
1816
- * customFieldId: "string",
1817
- * customFieldValue: "string"
594
+ * customFieldId: "custom123",
595
+ * customFieldValue: "value123"
1818
596
  * }
1819
597
  * ],
1820
- * firstName: "string",
1821
- * lastName: "string",
1822
- * phone: "string"
598
+ * firstName: "John",
599
+ * lastName: "Doe",
600
+ * phone: "+1234567890"
1823
601
  * });
1824
- * ```
1825
- * ### output
1826
- * Response - <strong style={{ color: 'green' }}>200</strong> - OK
1827
- * ```json
1828
- * {
1829
- * createdAt: "2024-12-11T10:28:21.123Z",
1830
- * id: "string",
1831
- * updatedAt: "2024-12-11T10:28:21.123Z"
1832
- * }
602
+ *
603
+ * console.log(response);
1833
604
  * ```
1834
605
  */
1835
606
  export declare function updateCustomerAccountOrganisationUser({ organisationId, customerUserId, civility, customFieldValues, firstName, lastName, phone, }: UpdateCustomerAccountOrganisationUserParameters): Promise<UpdateCustomerAccountOrganisationUserResponse>;