@webitel/api-services 26.8.88 → 26.8.90

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webitel/api-services",
3
- "version": "26.8.88",
3
+ "version": "26.8.90",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",
@@ -8,6 +8,7 @@ import {
8
8
  import { getDefaultGetListResponse, getDefaultGetParams } from '../../defaults';
9
9
  import {
10
10
  applyTransform,
11
+ camelToSnake,
11
12
  merge,
12
13
  notify,
13
14
  sanitizeToWire,
@@ -302,15 +303,17 @@ const sanitizeListFields = (itemInstance: ApiParams) => {
302
303
  const add = async ({ itemInstance }: AddItemParams) => {
303
304
  // `name`/`managers[].user`/`timezones[].timezone`/`groups[].group` are
304
305
  // expected already in the shape `ContactsInputContact` declares (e.g.
305
- // `name: { commonName }`, not a plain string) — callers build the draft
306
- // against the raw `Contact` type now, so no request-side wrapping happens
307
- // here anymore.
306
+ // `name: { commonName }`, not a plain string). Nested keys are rewritten
307
+ // to the wire spelling below (`commonName` -> `common_name`).
308
308
  const item = applyTransform(itemInstance, [
309
309
  sanitizeManagers,
310
310
  sanitizeTimezones,
311
311
  sanitizeGroups,
312
312
  sanitizeListFields,
313
313
  sanitizeToWire(createFieldsToSend),
314
+ camelToSnake([
315
+ 'custom',
316
+ ]),
314
317
  ]);
315
318
  try {
316
319
  const response = await getContacts().createContact(item);
@@ -334,6 +337,9 @@ const update = async ({ itemInstance }: AddItemParams) => {
334
337
  sanitizeGroups,
335
338
  sanitizeListFields,
336
339
  sanitizeToWire(updateFieldsToSend),
340
+ camelToSnake([
341
+ 'custom',
342
+ ]),
337
343
  ]);
338
344
  try {
339
345
  const response = await getContacts().updateContact(etag, item, {
@@ -49,4 +49,5 @@ export const EngineSystemSettingName = {
49
49
  LoginOptions: 'login_options',
50
50
  DefaultMembersFilter: 'default_members_filter',
51
51
  SelfAssignedCallSoundNotification: 'self_assigned_call_sound_notification',
52
+ RecordAllCalls: 'record_all_calls',
52
53
  } as const;
@@ -49,4 +49,5 @@ export const SearchSystemSettingNameItem = {
49
49
  LoginOptions: 'login_options',
50
50
  DefaultMembersFilter: 'default_members_filter',
51
51
  SelfAssignedCallSoundNotification: 'self_assigned_call_sound_notification',
52
+ RecordAllCalls: 'record_all_calls',
52
53
  } as const;
@@ -49,4 +49,5 @@ export const EngineSystemSettingName = {
49
49
  LoginOptions: 'login_options',
50
50
  DefaultMembersFilter: 'default_members_filter',
51
51
  SelfAssignedCallSoundNotification: 'self_assigned_call_sound_notification',
52
+ RecordAllCalls: 'record_all_calls',
52
53
  } as const;
@@ -49,4 +49,5 @@ export const SearchSystemSettingNameItem = {
49
49
  LoginOptions: 'login_options',
50
50
  DefaultMembersFilter: 'default_members_filter',
51
51
  SelfAssignedCallSoundNotification: 'self_assigned_call_sound_notification',
52
+ RecordAllCalls: 'record_all_calls',
52
53
  } as const;
@@ -55,6 +55,7 @@ export const SearchSystemSettingQueryParams = zod.object({
55
55
  'login_options',
56
56
  'default_members_filter',
57
57
  'self_assigned_call_sound_notification',
58
+ 'record_all_calls',
58
59
  ]),
59
60
  )
60
61
  .optional()
@@ -110,6 +111,7 @@ export const SearchSystemSettingResponse = zod.object({
110
111
  'login_options',
111
112
  'default_members_filter',
112
113
  'self_assigned_call_sound_notification',
114
+ 'record_all_calls',
113
115
  ])
114
116
  .default(searchSystemSettingResponseItemsItemNameDefault),
115
117
  }),
@@ -163,6 +165,7 @@ export const CreateSystemSettingBody = zod.object({
163
165
  'login_options',
164
166
  'default_members_filter',
165
167
  'self_assigned_call_sound_notification',
168
+ 'record_all_calls',
166
169
  ])
167
170
  .default(createSystemSettingBodyNameDefault),
168
171
  });
@@ -213,6 +216,7 @@ export const CreateSystemSettingResponse = zod.object({
213
216
  'login_options',
214
217
  'default_members_filter',
215
218
  'self_assigned_call_sound_notification',
219
+ 'record_all_calls',
216
220
  ])
217
221
  .default(createSystemSettingResponseNameDefault),
218
222
  });
@@ -286,6 +290,7 @@ export const DeleteSystemSettingResponse = zod.object({
286
290
  'login_options',
287
291
  'default_members_filter',
288
292
  'self_assigned_call_sound_notification',
293
+ 'record_all_calls',
289
294
  ])
290
295
  .default(deleteSystemSettingResponseNameDefault),
291
296
  });
@@ -340,6 +345,7 @@ export const ReadSystemSettingResponse = zod.object({
340
345
  'login_options',
341
346
  'default_members_filter',
342
347
  'self_assigned_call_sound_notification',
348
+ 'record_all_calls',
343
349
  ])
344
350
  .default(readSystemSettingResponseNameDefault),
345
351
  });
@@ -398,6 +404,7 @@ export const PatchSystemSettingResponse = zod.object({
398
404
  'login_options',
399
405
  'default_members_filter',
400
406
  'self_assigned_call_sound_notification',
407
+ 'record_all_calls',
401
408
  ])
402
409
  .default(patchSystemSettingResponseNameDefault),
403
410
  });
@@ -454,6 +461,7 @@ export const UpdateSystemSettingResponse = zod.object({
454
461
  'login_options',
455
462
  'default_members_filter',
456
463
  'self_assigned_call_sound_notification',
464
+ 'record_all_calls',
457
465
  ])
458
466
  .default(updateSystemSettingResponseNameDefault),
459
467
  });