@nomalism-com/api 1.3.30 → 1.3.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (129) hide show
  1. package/dist/index.d.ts +2 -1942
  2. package/dist/index.js +105 -65
  3. package/dist/main.d.ts +384 -0
  4. package/dist/modules/document/NPF.d.ts +8 -0
  5. package/dist/modules/document/NRCL.d.ts +8 -0
  6. package/dist/modules/document/billOfLading.d.ts +8 -0
  7. package/dist/modules/document/inventario.d.ts +9 -0
  8. package/dist/modules/document/materialEntrance.d.ts +13 -0
  9. package/dist/modules/document/order.d.ts +16 -0
  10. package/dist/modules/document/productionOrder.d.ts +8 -0
  11. package/dist/modules/document/proforma.d.ts +9 -0
  12. package/dist/modules/document/propostaFornecedor.d.ts +8 -0
  13. package/dist/modules/document/propostaSheets.d.ts +17 -0
  14. package/dist/modules/document/providerCreditNoteFromReturn.d.ts +9 -0
  15. package/dist/modules/document/providerFinancialCreditNote.d.ts +9 -0
  16. package/dist/modules/document/providerServiceInvoice.d.ts +8 -0
  17. package/dist/modules/document/purchase.d.ts +12 -0
  18. package/dist/modules/document/quebra.d.ts +12 -0
  19. package/dist/modules/document/returnToProvider.d.ts +10 -0
  20. package/dist/modules/document/transformado.d.ts +9 -0
  21. package/dist/modules/document/upfrontReturn.d.ts +8 -0
  22. package/dist/modules/documentManagement/multimedia.d.ts +10 -0
  23. package/dist/modules/integration/emailLog.d.ts +11 -0
  24. package/dist/modules/integration/emailTemplate.d.ts +13 -0
  25. package/dist/modules/integration/emailTemplateAttachment.d.ts +9 -0
  26. package/dist/modules/integration/emailVerification.d.ts +10 -0
  27. package/dist/modules/integration/googleFilePermission.d.ts +11 -0
  28. package/dist/modules/integration/googleSheets.d.ts +11 -0
  29. package/dist/modules/integration/observation.d.ts +12 -0
  30. package/dist/modules/integration/observationType.d.ts +12 -0
  31. package/dist/modules/integration/patchNotes.d.ts +9 -0
  32. package/dist/modules/integration/projectInfo.d.ts +8 -0
  33. package/dist/modules/integration/settings.d.ts +12 -0
  34. package/dist/modules/llm/llm.d.ts +10 -0
  35. package/dist/modules/print/npc.d.ts +10 -0
  36. package/dist/modules/print/printer.d.ts +12 -0
  37. package/dist/modules/print/schedulePrintJob.d.ts +12 -0
  38. package/dist/modules/stock/accountCode.d.ts +8 -0
  39. package/dist/modules/stock/chat.d.ts +16 -0
  40. package/dist/modules/stock/chatRapidMessage.d.ts +12 -0
  41. package/dist/modules/stock/dashboard.d.ts +9 -0
  42. package/dist/modules/stock/file.d.ts +11 -0
  43. package/dist/modules/stock/gmails.d.ts +9 -0
  44. package/dist/modules/stock/googleCalendar.d.ts +8 -0
  45. package/dist/modules/stock/location.d.ts +15 -0
  46. package/dist/modules/stock/prison.d.ts +13 -0
  47. package/dist/modules/stock/productGoogleSheets.d.ts +30 -0
  48. package/dist/modules/stock/productImage.d.ts +14 -0
  49. package/dist/modules/stock/promotion.d.ts +16 -0
  50. package/dist/modules/stock/promotionAssoc.d.ts +14 -0
  51. package/dist/modules/stock/queryList.d.ts +14 -0
  52. package/dist/modules/stock/queryParameter.d.ts +13 -0
  53. package/dist/modules/stock/recurrentTasks.d.ts +9 -0
  54. package/dist/modules/stock/returnReason.d.ts +11 -0
  55. package/dist/modules/stock/savedEmPicking.d.ts +11 -0
  56. package/dist/modules/stock/savedProviderProposal.d.ts +9 -0
  57. package/dist/modules/stock/schedule.d.ts +8 -0
  58. package/dist/modules/stock/stockMovement.d.ts +12 -0
  59. package/dist/modules/stock/tag.d.ts +11 -0
  60. package/dist/modules/stock/task.d.ts +14 -0
  61. package/dist/modules/stock/taskMessage.d.ts +10 -0
  62. package/dist/modules/stock/taskRead.d.ts +9 -0
  63. package/dist/modules/stock/typeOfLocation.d.ts +15 -0
  64. package/dist/modules/stock/unitOfMeasure.d.ts +15 -0
  65. package/dist/modules/stock/vatTax.d.ts +15 -0
  66. package/dist/modules/stock/vatTaxZone.d.ts +15 -0
  67. package/dist/modules/supply/currentAccount.d.ts +13 -0
  68. package/dist/modules/supply/documentHeader.d.ts +27 -0
  69. package/dist/modules/supply/documentHeaderHistory.d.ts +8 -0
  70. package/dist/modules/supply/documentHeaderSubscriber.d.ts +10 -0
  71. package/dist/modules/supply/documentHeaderSurvey.d.ts +10 -0
  72. package/dist/modules/supply/documentLine.d.ts +14 -0
  73. package/dist/modules/supply/documentLineAssoc.d.ts +10 -0
  74. package/dist/modules/supply/documentLineMt.d.ts +9 -0
  75. package/dist/modules/supply/documentLineNote.d.ts +8 -0
  76. package/dist/modules/supply/documentLineRm.d.ts +9 -0
  77. package/dist/modules/supply/documentSet.d.ts +13 -0
  78. package/dist/modules/supply/documentType.d.ts +13 -0
  79. package/dist/modules/supply/externalDocumentHeader.d.ts +13 -0
  80. package/dist/modules/supply/externalDocumentType.d.ts +9 -0
  81. package/dist/modules/supply/googleSheetPool.d.ts +8 -0
  82. package/dist/modules/supply/orderManagement.d.ts +9 -0
  83. package/dist/modules/supply/payment.d.ts +14 -0
  84. package/dist/modules/supply/paymentBatch.d.ts +18 -0
  85. package/dist/modules/supply/preSale.d.ts +15 -0
  86. package/dist/modules/supply/preSaleProduct.d.ts +9 -0
  87. package/dist/modules/supply/saft.d.ts +11 -0
  88. package/dist/modules/supply/startDocumentHeaderLastUpdate.d.ts +8 -0
  89. package/dist/modules/supply/vatValidation.d.ts +8 -0
  90. package/dist/modules/supply/workflow.d.ts +12 -0
  91. package/dist/modules/tickets/channel.d.ts +13 -0
  92. package/dist/modules/tickets/clt.d.ts +13 -0
  93. package/dist/modules/tickets/language.d.ts +13 -0
  94. package/dist/modules/tickets/tickets.d.ts +11 -0
  95. package/dist/modules/ui/portal.d.ts +10 -0
  96. package/dist/modules/ui/sideMenu.d.ts +11 -0
  97. package/dist/modules/user/bankData.d.ts +14 -0
  98. package/dist/modules/user/chatSubscriber.d.ts +13 -0
  99. package/dist/modules/user/clientType.d.ts +14 -0
  100. package/dist/modules/user/clients.d.ts +17 -0
  101. package/dist/modules/user/commissioner.d.ts +16 -0
  102. package/dist/modules/user/country.d.ts +16 -0
  103. package/dist/modules/user/deliveryMethods.d.ts +13 -0
  104. package/dist/modules/user/favorites.d.ts +11 -0
  105. package/dist/modules/user/language.d.ts +15 -0
  106. package/dist/modules/user/logout.d.ts +7 -0
  107. package/dist/modules/user/maturityDates.d.ts +13 -0
  108. package/dist/modules/user/password.d.ts +9 -0
  109. package/dist/modules/user/paymentMethods.d.ts +13 -0
  110. package/dist/modules/user/persona.d.ts +18 -0
  111. package/dist/modules/user/provider.d.ts +18 -0
  112. package/dist/modules/user/providerType.d.ts +15 -0
  113. package/dist/modules/user/purchaseCondition.d.ts +14 -0
  114. package/dist/modules/user/reasonForExemption.d.ts +14 -0
  115. package/dist/modules/user/refreshToken.d.ts +8 -0
  116. package/dist/modules/user/segmentsArea.d.ts +14 -0
  117. package/dist/modules/user/sessions.d.ts +8 -0
  118. package/dist/modules/user/shippings.d.ts +14 -0
  119. package/dist/modules/user/storeOperator.d.ts +14 -0
  120. package/dist/modules/user/swift.d.ts +15 -0
  121. package/dist/modules/user/tenant.d.ts +11 -0
  122. package/dist/modules/user/theme.d.ts +8 -0
  123. package/dist/modules/user/user.d.ts +16 -0
  124. package/dist/modules/user/userPositions.d.ts +14 -0
  125. package/dist/modules/user/vehicles.d.ts +11 -0
  126. package/dist/modules/user/zipCode.d.ts +9 -0
  127. package/dist/modules/view/adminPanel.d.ts +8 -0
  128. package/dist/modules/view/errorLog.d.ts +8 -0
  129. package/package.json +10 -10
package/dist/index.js CHANGED
@@ -1,5 +1,3 @@
1
- import axios, { AxiosHeaders } from 'axios';
2
-
3
1
  var __defProp = Object.defineProperty;
4
2
  var __export = (target, all) => {
5
3
  for (var name in all)
@@ -26,6 +24,7 @@ __export(main_exports, {
26
24
  DeliveryMethods: () => deliveryMethods_exports,
27
25
  DocumentHeader: () => documentHeader_exports,
28
26
  DocumentHeaderHistory: () => documentHeaderHistory_exports,
27
+ DocumentHeaderSubscriberClass: () => documentHeaderSubscriber_exports,
29
28
  DocumentLine: () => documentLine_exports,
30
29
  DocumentLineAssoc: () => documentLineAssoc_exports,
31
30
  DocumentLineMtClass: () => documentLineMt_exports,
@@ -125,6 +124,7 @@ __export(main_exports, {
125
124
  Workflow: () => workflow_exports,
126
125
  ZipCode: () => zipCode_exports
127
126
  });
127
+ import axios, { AxiosHeaders } from "axios";
128
128
 
129
129
  // src/modules/user/bankData.ts
130
130
  var bankData_exports = {};
@@ -268,24 +268,12 @@ var Repository4 = class {
268
268
  this.api = api;
269
269
  this.route = route;
270
270
  }
271
- async findActiveByOwnerId(params) {
271
+ async findByOwnerId(params) {
272
272
  const response = await this.api.get(`${this.route}active`, {
273
273
  params
274
274
  });
275
275
  return response.data;
276
276
  }
277
- async clientWebAppFindActiveByOwnerId(params) {
278
- const response = await this.api.get(`${this.route}client_web_app`, {
279
- params
280
- });
281
- return response.data;
282
- }
283
- async findActiveBySubscriberId(params) {
284
- const response = await this.api.get(`${this.route}active_by_subscriber_id`, {
285
- params
286
- });
287
- return response.data;
288
- }
289
277
  async create(body) {
290
278
  const response = await this.api.post(`${this.route}`, body);
291
279
  return response.data;
@@ -310,6 +298,10 @@ var Repository4 = class {
310
298
  `${this.route}mark_all_client_read_unread/${params.chat_document_header_id}/${params.client_read}`
311
299
  );
312
300
  }
301
+ async translate(body) {
302
+ const response = await this.api.post(`${this.route}translate`, body);
303
+ return response.data;
304
+ }
313
305
  };
314
306
 
315
307
  // src/modules/user/commissioner.ts
@@ -633,13 +625,6 @@ var Repository16 = class {
633
625
  async update(selector, body) {
634
626
  await this.api.put(`${this.route}${selector.id}`, body);
635
627
  }
636
- async updateIndexes(document_line_ids) {
637
- await this.api.put(`${this.route}update_indexes`, document_line_ids);
638
- }
639
- async updateData(data) {
640
- const response = await this.api.post(`${this.route}update_data`, data);
641
- return response.data;
642
- }
643
628
  async updateMany(data) {
644
629
  const response = await this.api.post(`${this.route}update_many`, data);
645
630
  return response.data;
@@ -688,14 +673,6 @@ var Repository17 = class {
688
673
  });
689
674
  return response.data;
690
675
  }
691
- async create(body) {
692
- const response = await this.api.post(`${this.route}`, body);
693
- return response.data;
694
- }
695
- async update(selector, body) {
696
- const response = await this.api.put(`${this.route}${selector.id}`, body);
697
- return response.data;
698
- }
699
676
  };
700
677
 
701
678
  // src/modules/supply/documentType.ts
@@ -2141,14 +2118,6 @@ var Repository56 = class {
2141
2118
  this.api = api;
2142
2119
  this.route = route;
2143
2120
  }
2144
- async create(body) {
2145
- const response = await this.api.post(`${this.route}`, body);
2146
- return response.data;
2147
- }
2148
- async update(selector, body) {
2149
- const response = await this.api.put(`${this.route}${selector.id}`, body);
2150
- return response.data;
2151
- }
2152
2121
  async findById(selector) {
2153
2122
  const response = await this.api.get(`${this.route}${selector.id}`);
2154
2123
  return response.data;
@@ -2157,14 +2126,6 @@ var Repository56 = class {
2157
2126
  const response = await this.api.get(`${this.route}by_owner`, { params });
2158
2127
  return response.data;
2159
2128
  }
2160
- async find(params) {
2161
- const response = await this.api.get(`${this.route}`, { params });
2162
- return response.data;
2163
- }
2164
- async findPaginated(params) {
2165
- const response = await this.api.get(`${this.route}paginated`, { params });
2166
- return response.data;
2167
- }
2168
2129
  async deleteOne(params) {
2169
2130
  const response = await this.api.get(`${this.route}`, { params });
2170
2131
  return response.data;
@@ -2172,6 +2133,13 @@ var Repository56 = class {
2172
2133
  async sendEmailDocument(body) {
2173
2134
  await this.api.post(`${this.route}sendEmail`, body);
2174
2135
  }
2136
+ async retry(body) {
2137
+ await this.api.post(`${this.route}retry`, body);
2138
+ }
2139
+ async create(body) {
2140
+ const response = await this.api.post(`${this.route}`, body);
2141
+ return response.data;
2142
+ }
2175
2143
  };
2176
2144
 
2177
2145
  // src/modules/supply/vatValidation.ts
@@ -2909,6 +2877,9 @@ var Repository79 = class {
2909
2877
  const response = await this.api.get(`${this.route}for_gmail`, { params });
2910
2878
  return response.data;
2911
2879
  }
2880
+ async publicUpdate(selector, body) {
2881
+ await this.api.put(`${this.route}public/${selector.id}`, body);
2882
+ }
2912
2883
  };
2913
2884
 
2914
2885
  // src/modules/integration/projectInfo.ts
@@ -2963,6 +2934,15 @@ var Repository81 = class {
2963
2934
  const response = await this.api.get(`${this.route}`, { params });
2964
2935
  return response.data;
2965
2936
  }
2937
+ async previewRegroupLinesInProviderOrder({
2938
+ id
2939
+ }) {
2940
+ const response = await this.api.get(`${this.route}regroup/${id}`);
2941
+ return response.data;
2942
+ }
2943
+ async regroupLinesInProviderOrder({ id }) {
2944
+ await this.api.post(`${this.route}regroup/${id}`);
2945
+ }
2966
2946
  };
2967
2947
 
2968
2948
  // src/modules/document/purchase.ts
@@ -3151,6 +3131,10 @@ var Repository87 = class {
3151
3131
  const response = await this.api.post(`${this.route}send`, data);
3152
3132
  return response.data;
3153
3133
  }
3134
+ async preview(selector, data) {
3135
+ const response = await this.api.post(`${this.route}preview/${selector.id}`, data);
3136
+ return response.data;
3137
+ }
3154
3138
  };
3155
3139
 
3156
3140
  // src/modules/integration/emailTemplateAttachment.ts
@@ -3770,16 +3754,12 @@ var Repository110 = class {
3770
3754
  this.api = api;
3771
3755
  this.route = route;
3772
3756
  }
3773
- async createOrUpdate(data) {
3774
- const response = await this.api.post(`${this.route}`, data);
3757
+ async findDocumentHeaderSubscribers(params) {
3758
+ const response = await this.api.get(`${this.route}document_header_subscribers`, { params });
3775
3759
  return response.data;
3776
3760
  }
3777
- async findByOwner(params) {
3778
- const response = await this.api.get(`${this.route}`, { params });
3779
- return response.data;
3780
- }
3781
- async clientWebAppFindByOwner(params) {
3782
- const response = await this.api.get(`${this.route}client_web_app`, { params });
3761
+ async findSubscribedDocumentHeaders(params) {
3762
+ const response = await this.api.get(`${this.route}subscribed_document_headers`, { params });
3783
3763
  return response.data;
3784
3764
  }
3785
3765
  async findById({
@@ -3788,8 +3768,15 @@ var Repository110 = class {
3788
3768
  const response = await this.api.get(`${this.route}${id}`);
3789
3769
  return response.data;
3790
3770
  }
3771
+ async createOrUpdate(data) {
3772
+ const response = await this.api.post(`${this.route}`, data);
3773
+ return response.data;
3774
+ }
3791
3775
  async deleteOne({ id }) {
3792
- await this.api.delete(`${this.route}/${id}`);
3776
+ await this.api.delete(`${this.route}${id}`);
3777
+ }
3778
+ async deleteByDocumentHeader({ id }) {
3779
+ await this.api.delete(`${this.route}document_header/${id}`);
3793
3780
  }
3794
3781
  };
3795
3782
 
@@ -3985,23 +3972,17 @@ var Repository117 = class {
3985
3972
  this.api = api;
3986
3973
  this.route = route;
3987
3974
  }
3988
- async publicFindByOwnerId(params) {
3989
- const response = await this.api.get(`${this.route}public_by_owner`, {
3990
- params
3991
- });
3992
- return response.data;
3993
- }
3994
3975
  async publicFindBySubscriberId(params) {
3995
3976
  const response = await this.api.get(`${this.route}public_by_subscriber`, {
3996
3977
  params
3997
3978
  });
3998
3979
  return response.data;
3999
3980
  }
4000
- async createPublicDocumentHeaderNote(data) {
3981
+ async publicCreateDocumentHeaderNote(data) {
4001
3982
  const response = await this.api.post(`${this.route}public_document_header_note`, data);
4002
3983
  return response.data;
4003
3984
  }
4004
- async updatePublicDocumentHeaderNote({ id }, data) {
3985
+ async publicUpdateDocumentHeaderNote({ id }, data) {
4005
3986
  const response = await this.api.put(`${this.route}public_document_header_note/${id}`, data);
4006
3987
  return response.data;
4007
3988
  }
@@ -4101,6 +4082,14 @@ var Repository121 = class {
4101
4082
  })();
4102
4083
  return { abort: () => ac.abort() };
4103
4084
  }
4085
+ async translate(body) {
4086
+ const response = await this.api.post(`${this.route}translate`, body);
4087
+ return response.data;
4088
+ }
4089
+ async identifyLanguage(body) {
4090
+ const response = await this.api.post(`${this.route}identify_language`, body);
4091
+ return response.data;
4092
+ }
4104
4093
  };
4105
4094
 
4106
4095
  // src/modules/integration/patchNotes.ts
@@ -4123,6 +4112,50 @@ var Repository122 = class {
4123
4112
  }
4124
4113
  };
4125
4114
 
4115
+ // src/modules/supply/documentHeaderSurvey.ts
4116
+ var Repository123 = class {
4117
+ constructor({ api, route }) {
4118
+ this.api = api;
4119
+ this.route = route;
4120
+ }
4121
+ async find() {
4122
+ const response = await this.api.get(`${this.route}`);
4123
+ return response.data;
4124
+ }
4125
+ async updateSent(body) {
4126
+ const response = await this.api.put(`${this.route}sent`, body);
4127
+ return response.data;
4128
+ }
4129
+ async updateSurvey(body) {
4130
+ const response = await this.api.put(`${this.route}survey`, body);
4131
+ return response.data;
4132
+ }
4133
+ };
4134
+
4135
+ // src/modules/supply/documentHeaderSubscriber.ts
4136
+ var documentHeaderSubscriber_exports = {};
4137
+ __export(documentHeaderSubscriber_exports, {
4138
+ default: () => Repository124
4139
+ });
4140
+ var Repository124 = class {
4141
+ constructor({ api, route }) {
4142
+ this.api = api;
4143
+ this.route = route;
4144
+ }
4145
+ async findByOwnerId(params) {
4146
+ const response = await this.api.get(`${this.route}by_owner`, {
4147
+ params
4148
+ });
4149
+ return response.data;
4150
+ }
4151
+ async create(body) {
4152
+ await this.api.post(`${this.route}`, body);
4153
+ }
4154
+ async deleteOne(selector) {
4155
+ await this.api.delete(`${this.route}${selector.id}`);
4156
+ }
4157
+ };
4158
+
4126
4159
  // src/main.ts
4127
4160
  var API = class {
4128
4161
  constructor({ processEnvironment, services, gatewayUrl, apikey, tokenBearer }) {
@@ -4323,10 +4356,17 @@ var API = class {
4323
4356
  this.AccountCode = new Repository120(getModuleParams("stock", "account_code"));
4324
4357
  this.LLM = new Repository121(getModuleParams("llm", "llm"));
4325
4358
  this.PatchNotes = new Repository122(getModuleParams("integration", "patch_notes"));
4359
+ this.DocumentHeaderSurvey = new Repository123(
4360
+ getModuleParams("stock", "document_header_survey")
4361
+ );
4362
+ this.DocumentHeaderSubscriber = new Repository124(
4363
+ getModuleParams("stock", "document_header_subscriber")
4364
+ );
4326
4365
  }
4327
4366
  };
4328
4367
 
4329
4368
  // src/index.ts
4330
4369
  var index_default = main_exports;
4331
-
4332
- export { index_default as default };
4370
+ export {
4371
+ index_default as default
4372
+ };