@icure/api 6.0.2 → 6.0.4

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 (238) hide show
  1. package/icc-api/api/IccAccesslogApi.d.ts +3 -1
  2. package/icc-api/api/IccAccesslogApi.js +10 -8
  3. package/icc-api/api/IccAccesslogApi.js.map +1 -1
  4. package/icc-api/api/IccAgendaApi.d.ts +3 -1
  5. package/icc-api/api/IccAgendaApi.js +10 -8
  6. package/icc-api/api/IccAgendaApi.js.map +1 -1
  7. package/icc-api/api/IccAnonymousAccessApi.d.ts +3 -1
  8. package/icc-api/api/IccAnonymousAccessApi.js +6 -4
  9. package/icc-api/api/IccAnonymousAccessApi.js.map +1 -1
  10. package/icc-api/api/IccApplicationsettingsApi.d.ts +3 -1
  11. package/icc-api/api/IccApplicationsettingsApi.js +6 -4
  12. package/icc-api/api/IccApplicationsettingsApi.js.map +1 -1
  13. package/icc-api/api/IccArticleApi.d.ts +3 -1
  14. package/icc-api/api/IccArticleApi.js +8 -6
  15. package/icc-api/api/IccArticleApi.js.map +1 -1
  16. package/icc-api/api/IccAuthApi.d.ts +13 -1
  17. package/icc-api/api/IccAuthApi.js +30 -4
  18. package/icc-api/api/IccAuthApi.js.map +1 -1
  19. package/icc-api/api/IccBeefactApi.d.ts +3 -1
  20. package/icc-api/api/IccBeefactApi.js +4 -2
  21. package/icc-api/api/IccBeefactApi.js.map +1 -1
  22. package/icc-api/api/IccBekmehrApi.d.ts +3 -1
  23. package/icc-api/api/IccBekmehrApi.js +30 -28
  24. package/icc-api/api/IccBekmehrApi.js.map +1 -1
  25. package/icc-api/api/IccBemikronoApi.d.ts +3 -1
  26. package/icc-api/api/IccBemikronoApi.js +11 -9
  27. package/icc-api/api/IccBemikronoApi.js.map +1 -1
  28. package/icc-api/api/IccBeresultexportApi.d.ts +3 -1
  29. package/icc-api/api/IccBeresultexportApi.js +6 -4
  30. package/icc-api/api/IccBeresultexportApi.js.map +1 -1
  31. package/icc-api/api/IccBeresultimportApi.d.ts +3 -1
  32. package/icc-api/api/IccBeresultimportApi.js +6 -4
  33. package/icc-api/api/IccBeresultimportApi.js.map +1 -1
  34. package/icc-api/api/IccBesamv2Api.d.ts +3 -1
  35. package/icc-api/api/IccBesamv2Api.js +36 -34
  36. package/icc-api/api/IccBesamv2Api.js.map +1 -1
  37. package/icc-api/api/IccCalendarItemApi.d.ts +3 -1
  38. package/icc-api/api/IccCalendarItemApi.js +15 -13
  39. package/icc-api/api/IccCalendarItemApi.js.map +1 -1
  40. package/icc-api/api/IccCalendarItemTypeApi.d.ts +3 -1
  41. package/icc-api/api/IccCalendarItemTypeApi.js +9 -7
  42. package/icc-api/api/IccCalendarItemTypeApi.js.map +1 -1
  43. package/icc-api/api/IccClassificationApi.d.ts +3 -1
  44. package/icc-api/api/IccClassificationApi.js +11 -9
  45. package/icc-api/api/IccClassificationApi.js.map +1 -1
  46. package/icc-api/api/IccClassificationTemplateApi.d.ts +3 -1
  47. package/icc-api/api/IccClassificationTemplateApi.js +11 -9
  48. package/icc-api/api/IccClassificationTemplateApi.js.map +1 -1
  49. package/icc-api/api/IccCodeApi.d.ts +3 -1
  50. package/icc-api/api/IccCodeApi.js +19 -17
  51. package/icc-api/api/IccCodeApi.js.map +1 -1
  52. package/icc-api/api/IccContactApi.d.ts +3 -2
  53. package/icc-api/api/IccContactApi.js +31 -32
  54. package/icc-api/api/IccContactApi.js.map +1 -1
  55. package/icc-api/api/IccDeviceApi.d.ts +3 -1
  56. package/icc-api/api/IccDeviceApi.js +21 -19
  57. package/icc-api/api/IccDeviceApi.js.map +1 -1
  58. package/icc-api/api/IccDoctemplateApi.d.ts +3 -1
  59. package/icc-api/api/IccDoctemplateApi.js +16 -14
  60. package/icc-api/api/IccDoctemplateApi.js.map +1 -1
  61. package/icc-api/api/IccDocumentApi.d.ts +3 -1
  62. package/icc-api/api/IccDocumentApi.js +23 -21
  63. package/icc-api/api/IccDocumentApi.js.map +1 -1
  64. package/icc-api/api/IccDocumentTemplateApi.d.ts +3 -1
  65. package/icc-api/api/IccDocumentTemplateApi.js +16 -14
  66. package/icc-api/api/IccDocumentTemplateApi.js.map +1 -1
  67. package/icc-api/api/IccEntityrefApi.d.ts +3 -1
  68. package/icc-api/api/IccEntityrefApi.js +5 -3
  69. package/icc-api/api/IccEntityrefApi.js.map +1 -1
  70. package/icc-api/api/IccEntitytemplateApi.d.ts +3 -1
  71. package/icc-api/api/IccEntitytemplateApi.js +14 -12
  72. package/icc-api/api/IccEntitytemplateApi.js.map +1 -1
  73. package/icc-api/api/IccFormApi.d.ts +3 -1
  74. package/icc-api/api/IccFormApi.js +27 -25
  75. package/icc-api/api/IccFormApi.js.map +1 -1
  76. package/icc-api/api/IccFrontendmigrationApi.d.ts +3 -1
  77. package/icc-api/api/IccFrontendmigrationApi.js +9 -7
  78. package/icc-api/api/IccFrontendmigrationApi.js.map +1 -1
  79. package/icc-api/api/IccGroupApi.d.ts +3 -1
  80. package/icc-api/api/IccGroupApi.js +19 -17
  81. package/icc-api/api/IccGroupApi.js.map +1 -1
  82. package/icc-api/api/IccHcpartyApi.d.ts +3 -1
  83. package/icc-api/api/IccHcpartyApi.js +25 -23
  84. package/icc-api/api/IccHcpartyApi.js.map +1 -1
  85. package/icc-api/api/IccHelementApi.d.ts +3 -1
  86. package/icc-api/api/IccHelementApi.js +16 -14
  87. package/icc-api/api/IccHelementApi.js.map +1 -1
  88. package/icc-api/api/IccIcureApi.d.ts +3 -1
  89. package/icc-api/api/IccIcureApi.js +19 -17
  90. package/icc-api/api/IccIcureApi.js.map +1 -1
  91. package/icc-api/api/IccInsuranceApi.d.ts +3 -1
  92. package/icc-api/api/IccInsuranceApi.js +10 -8
  93. package/icc-api/api/IccInsuranceApi.js.map +1 -1
  94. package/icc-api/api/IccInvoiceApi.d.ts +3 -1
  95. package/icc-api/api/IccInvoiceApi.js +34 -32
  96. package/icc-api/api/IccInvoiceApi.js.map +1 -1
  97. package/icc-api/api/IccKeywordApi.d.ts +3 -1
  98. package/icc-api/api/IccKeywordApi.js +9 -7
  99. package/icc-api/api/IccKeywordApi.js.map +1 -1
  100. package/icc-api/api/IccMaintenanceTaskApi.d.ts +3 -1
  101. package/icc-api/api/IccMaintenanceTaskApi.js +8 -6
  102. package/icc-api/api/IccMaintenanceTaskApi.js.map +1 -1
  103. package/icc-api/api/IccMedexApi.d.ts +3 -1
  104. package/icc-api/api/IccMedexApi.js +4 -2
  105. package/icc-api/api/IccMedexApi.js.map +1 -1
  106. package/icc-api/api/IccMedicallocationApi.d.ts +3 -1
  107. package/icc-api/api/IccMedicallocationApi.js +8 -6
  108. package/icc-api/api/IccMedicallocationApi.js.map +1 -1
  109. package/icc-api/api/IccMessageApi.d.ts +3 -1
  110. package/icc-api/api/IccMessageApi.js +22 -20
  111. package/icc-api/api/IccMessageApi.js.map +1 -1
  112. package/icc-api/api/IccPatientApi.d.ts +3 -1
  113. package/icc-api/api/IccPatientApi.js +37 -35
  114. package/icc-api/api/IccPatientApi.js.map +1 -1
  115. package/icc-api/api/IccPermissionApi.d.ts +3 -1
  116. package/icc-api/api/IccPermissionApi.js +4 -2
  117. package/icc-api/api/IccPermissionApi.js.map +1 -1
  118. package/icc-api/api/IccPlaceApi.d.ts +3 -1
  119. package/icc-api/api/IccPlaceApi.js +8 -6
  120. package/icc-api/api/IccPlaceApi.js.map +1 -1
  121. package/icc-api/api/IccPubsubApi.d.ts +3 -1
  122. package/icc-api/api/IccPubsubApi.js +7 -5
  123. package/icc-api/api/IccPubsubApi.js.map +1 -1
  124. package/icc-api/api/IccReceiptApi.d.ts +3 -1
  125. package/icc-api/api/IccReceiptApi.js +10 -8
  126. package/icc-api/api/IccReceiptApi.js.map +1 -1
  127. package/icc-api/api/IccReplicationApi.d.ts +3 -1
  128. package/icc-api/api/IccReplicationApi.js +7 -5
  129. package/icc-api/api/IccReplicationApi.js.map +1 -1
  130. package/icc-api/api/IccTarificationApi.d.ts +3 -1
  131. package/icc-api/api/IccTarificationApi.js +11 -9
  132. package/icc-api/api/IccTarificationApi.js.map +1 -1
  133. package/icc-api/api/IccTimeTableApi.d.ts +3 -1
  134. package/icc-api/api/IccTimeTableApi.js +9 -7
  135. package/icc-api/api/IccTimeTableApi.js.map +1 -1
  136. package/icc-api/api/IccTmpApi.d.ts +3 -1
  137. package/icc-api/api/IccTmpApi.js +74 -72
  138. package/icc-api/api/IccTmpApi.js.map +1 -1
  139. package/icc-api/api/IccUserApi.d.ts +3 -1
  140. package/icc-api/api/IccUserApi.js +29 -27
  141. package/icc-api/api/IccUserApi.js.map +1 -1
  142. package/icc-api/api/XHR.d.ts +2 -1
  143. package/icc-api/api/XHR.js +45 -59
  144. package/icc-api/api/XHR.js.map +1 -1
  145. package/icc-api/model/AuthenticationResponse.d.ts +2 -0
  146. package/icc-api/model/AuthenticationResponse.js.map +1 -1
  147. package/icc-api/model/Group.d.ts +6 -0
  148. package/icc-api/model/Group.js.map +1 -1
  149. package/icc-api/model/RefreshTokenExpiredError.d.ts +3 -0
  150. package/icc-api/model/RefreshTokenExpiredError.js +10 -0
  151. package/icc-api/model/RefreshTokenExpiredError.js.map +1 -0
  152. package/icc-api/model/RegistrationInformation.d.ts +1 -0
  153. package/icc-api/model/RegistrationInformation.js.map +1 -1
  154. package/icc-api/model/TimeTableItem.d.ts +2 -1
  155. package/icc-api/model/TimeTableItem.js.map +1 -1
  156. package/icc-x-api/auth/AuthService.d.ts +16 -0
  157. package/icc-x-api/auth/AuthService.js +3 -0
  158. package/icc-x-api/auth/AuthService.js.map +1 -0
  159. package/icc-x-api/auth/AuthenticationProvider.d.ts +30 -0
  160. package/icc-x-api/auth/AuthenticationProvider.js +56 -0
  161. package/icc-x-api/auth/AuthenticationProvider.js.map +1 -0
  162. package/icc-x-api/auth/BasicAuthService.d.ts +12 -0
  163. package/icc-x-api/auth/BasicAuthService.js +27 -0
  164. package/icc-x-api/auth/BasicAuthService.js.map +1 -0
  165. package/icc-x-api/auth/EnsembleAuthService.d.ts +17 -0
  166. package/icc-x-api/auth/EnsembleAuthService.js +60 -0
  167. package/icc-x-api/auth/EnsembleAuthService.js.map +1 -0
  168. package/icc-x-api/auth/JwtAuthService.d.ts +19 -0
  169. package/icc-x-api/auth/JwtAuthService.js +97 -0
  170. package/icc-x-api/auth/JwtAuthService.js.map +1 -0
  171. package/icc-x-api/auth/NoAuthService.d.ts +8 -0
  172. package/icc-x-api/auth/NoAuthService.js +30 -0
  173. package/icc-x-api/auth/NoAuthService.js.map +1 -0
  174. package/icc-x-api/filters/MaintenanceTaskAfterDateFilter.d.ts +1 -0
  175. package/icc-x-api/filters/MaintenanceTaskAfterDateFilter.js.map +1 -1
  176. package/icc-x-api/icc-accesslog-x-api.d.ts +2 -1
  177. package/icc-x-api/icc-accesslog-x-api.js +3 -2
  178. package/icc-x-api/icc-accesslog-x-api.js.map +1 -1
  179. package/icc-x-api/icc-bekmehr-x-api.d.ts +2 -1
  180. package/icc-x-api/icc-bekmehr-x-api.js +3 -2
  181. package/icc-x-api/icc-bekmehr-x-api.js.map +1 -1
  182. package/icc-x-api/icc-calendar-item-x-api.d.ts +2 -1
  183. package/icc-x-api/icc-calendar-item-x-api.js +3 -2
  184. package/icc-x-api/icc-calendar-item-x-api.js.map +1 -1
  185. package/icc-x-api/icc-classification-x-api.d.ts +2 -1
  186. package/icc-x-api/icc-classification-x-api.js +3 -2
  187. package/icc-x-api/icc-classification-x-api.js.map +1 -1
  188. package/icc-x-api/icc-code-x-api.d.ts +2 -1
  189. package/icc-x-api/icc-code-x-api.js +3 -2
  190. package/icc-x-api/icc-code-x-api.js.map +1 -1
  191. package/icc-x-api/icc-contact-x-api.d.ts +2 -1
  192. package/icc-x-api/icc-contact-x-api.js +3 -2
  193. package/icc-x-api/icc-contact-x-api.js.map +1 -1
  194. package/icc-x-api/icc-crypto-x-api.d.ts +13 -0
  195. package/icc-x-api/icc-crypto-x-api.js +22 -0
  196. package/icc-x-api/icc-crypto-x-api.js.map +1 -1
  197. package/icc-x-api/icc-doctemplate-x-api.d.ts +3 -1
  198. package/icc-x-api/icc-doctemplate-x-api.js +5 -3
  199. package/icc-x-api/icc-doctemplate-x-api.js.map +1 -1
  200. package/icc-x-api/icc-document-x-api.d.ts +3 -1
  201. package/icc-x-api/icc-document-x-api.js +5 -3
  202. package/icc-x-api/icc-document-x-api.js.map +1 -1
  203. package/icc-x-api/icc-form-x-api.d.ts +2 -1
  204. package/icc-x-api/icc-form-x-api.js +3 -2
  205. package/icc-x-api/icc-form-x-api.js.map +1 -1
  206. package/icc-x-api/icc-hcparty-x-api.d.ts +2 -1
  207. package/icc-x-api/icc-hcparty-x-api.js +3 -2
  208. package/icc-x-api/icc-hcparty-x-api.js.map +1 -1
  209. package/icc-x-api/icc-helement-x-api.d.ts +2 -1
  210. package/icc-x-api/icc-helement-x-api.js +3 -2
  211. package/icc-x-api/icc-helement-x-api.js.map +1 -1
  212. package/icc-x-api/icc-invoice-x-api.d.ts +2 -1
  213. package/icc-x-api/icc-invoice-x-api.js +3 -2
  214. package/icc-x-api/icc-invoice-x-api.js.map +1 -1
  215. package/icc-x-api/icc-maintenance-task-x-api.d.ts +2 -1
  216. package/icc-x-api/icc-maintenance-task-x-api.js +3 -2
  217. package/icc-x-api/icc-maintenance-task-x-api.js.map +1 -1
  218. package/icc-x-api/icc-message-x-api.d.ts +2 -1
  219. package/icc-x-api/icc-message-x-api.js +3 -2
  220. package/icc-x-api/icc-message-x-api.js.map +1 -1
  221. package/icc-x-api/icc-patient-x-api.d.ts +2 -1
  222. package/icc-x-api/icc-patient-x-api.js +3 -2
  223. package/icc-x-api/icc-patient-x-api.js.map +1 -1
  224. package/icc-x-api/icc-receipt-x-api.d.ts +2 -1
  225. package/icc-x-api/icc-receipt-x-api.js +3 -2
  226. package/icc-x-api/icc-receipt-x-api.js.map +1 -1
  227. package/icc-x-api/icc-time-table-x-api.d.ts +2 -1
  228. package/icc-x-api/icc-time-table-x-api.js +3 -2
  229. package/icc-x-api/icc-time-table-x-api.js.map +1 -1
  230. package/icc-x-api/icc-user-x-api.d.ts +2 -1
  231. package/icc-x-api/icc-user-x-api.js +3 -2
  232. package/icc-x-api/icc-user-x-api.js.map +1 -1
  233. package/icc-x-api/index.d.ts +0 -4
  234. package/icc-x-api/index.js +34 -35
  235. package/icc-x-api/index.js.map +1 -1
  236. package/icc-x-api/storage/StorageFacade.d.ts +1 -1
  237. package/icc-x-api/storage/StorageFacade.js.map +1 -1
  238. package/package.json +1 -1
@@ -32,10 +32,12 @@ const PaginatedListPatient_1 = require("../model/PaginatedListPatient");
32
32
  const Patient_1 = require("../model/Patient");
33
33
  const ReplicatorDocument_1 = require("../model/ReplicatorDocument");
34
34
  const Unit_1 = require("../model/Unit");
35
+ const AuthenticationProvider_1 = require("../../icc-x-api/auth/AuthenticationProvider");
35
36
  class IccTmpApi {
36
- constructor(host, headers, fetchImpl) {
37
+ constructor(host, headers, authenticationProvider, fetchImpl) {
37
38
  this.host = host;
38
39
  this.headers = Object.keys(headers).map((k) => new XHR_1.XHR.Header(k, headers[k]));
40
+ this.authenticationProvider = !!authenticationProvider ? authenticationProvider : new AuthenticationProvider_1.NoAuthenticationProvider();
39
41
  this.fetchImpl = fetchImpl;
40
42
  }
41
43
  setHeaders(h) {
@@ -55,7 +57,7 @@ class IccTmpApi {
55
57
  const _url = this.host + `/tmp/classification` + '?ts=' + new Date().getTime();
56
58
  let headers = this.headers;
57
59
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
58
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
60
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
59
61
  .then((doc) => new Classification_1.Classification(doc.body))
60
62
  .catch((err) => this.handleError(err));
61
63
  }
@@ -70,7 +72,7 @@ class IccTmpApi {
70
72
  const _url = this.host + `/tmp/classification/batch` + '?ts=' + new Date().getTime();
71
73
  let headers = this.headers;
72
74
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
73
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
75
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
74
76
  .then((doc) => doc.body.map((it) => new Classification_1.Classification(it)))
75
77
  .catch((err) => this.handleError(err));
76
78
  }
@@ -85,7 +87,7 @@ class IccTmpApi {
85
87
  const _url = this.host + `/tmp/contact` + '?ts=' + new Date().getTime();
86
88
  let headers = this.headers;
87
89
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
88
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
90
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
89
91
  .then((doc) => new Contact_1.Contact(doc.body))
90
92
  .catch((err) => this.handleError(err));
91
93
  }
@@ -100,7 +102,7 @@ class IccTmpApi {
100
102
  const _url = this.host + `/tmp/contact/batch` + '?ts=' + new Date().getTime();
101
103
  let headers = this.headers;
102
104
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
103
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
105
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
104
106
  .then((doc) => doc.body.map((it) => new Contact_1.Contact(it)))
105
107
  .catch((err) => this.handleError(err));
106
108
  }
@@ -112,7 +114,7 @@ class IccTmpApi {
112
114
  let _body = null;
113
115
  const _url = this.host + `/tmp` + '?ts=' + new Date().getTime();
114
116
  let headers = this.headers;
115
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
117
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
116
118
  .then((doc) => new Unit_1.Unit(doc.body))
117
119
  .catch((err) => this.handleError(err));
118
120
  }
@@ -127,7 +129,7 @@ class IccTmpApi {
127
129
  const _url = this.host + `/tmp/document` + '?ts=' + new Date().getTime();
128
130
  let headers = this.headers;
129
131
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
130
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
132
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
131
133
  .then((doc) => new Document_1.Document(doc.body))
132
134
  .catch((err) => this.handleError(err));
133
135
  }
@@ -142,7 +144,7 @@ class IccTmpApi {
142
144
  const _url = this.host + `/tmp/document/batch` + '?ts=' + new Date().getTime();
143
145
  let headers = this.headers;
144
146
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
145
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
147
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
146
148
  .then((doc) => doc.body.map((it) => new Document_1.Document(it)))
147
149
  .catch((err) => this.handleError(err));
148
150
  }
@@ -157,7 +159,7 @@ class IccTmpApi {
157
159
  const _url = this.host + `/tmp/entityTemplate` + '?ts=' + new Date().getTime();
158
160
  let headers = this.headers;
159
161
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
160
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
162
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
161
163
  .then((doc) => new EntityTemplate_1.EntityTemplate(doc.body))
162
164
  .catch((err) => this.handleError(err));
163
165
  }
@@ -172,7 +174,7 @@ class IccTmpApi {
172
174
  const _url = this.host + `/tmp/entityTemplate/batch` + '?ts=' + new Date().getTime();
173
175
  let headers = this.headers;
174
176
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
175
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
177
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
176
178
  .then((doc) => doc.body.map((it) => new EntityTemplate_1.EntityTemplate(it)))
177
179
  .catch((err) => this.handleError(err));
178
180
  }
@@ -187,7 +189,7 @@ class IccTmpApi {
187
189
  const _url = this.host + `/tmp/form` + '?ts=' + new Date().getTime();
188
190
  let headers = this.headers;
189
191
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
190
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
192
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
191
193
  .then((doc) => new Form_1.Form(doc.body))
192
194
  .catch((err) => this.handleError(err));
193
195
  }
@@ -202,7 +204,7 @@ class IccTmpApi {
202
204
  const _url = this.host + `/tmp/form/batch` + '?ts=' + new Date().getTime();
203
205
  let headers = this.headers;
204
206
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
205
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
207
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
206
208
  .then((doc) => doc.body.map((it) => new Form_1.Form(it)))
207
209
  .catch((err) => this.handleError(err));
208
210
  }
@@ -217,7 +219,7 @@ class IccTmpApi {
217
219
  const _url = this.host + `/tmp/healthElement` + '?ts=' + new Date().getTime();
218
220
  let headers = this.headers;
219
221
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
220
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
222
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
221
223
  .then((doc) => new HealthElement_1.HealthElement(doc.body))
222
224
  .catch((err) => this.handleError(err));
223
225
  }
@@ -232,7 +234,7 @@ class IccTmpApi {
232
234
  const _url = this.host + `/tmp/healthElement/batch` + '?ts=' + new Date().getTime();
233
235
  let headers = this.headers;
234
236
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
235
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
237
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
236
238
  .then((doc) => doc.body.map((it) => new HealthElement_1.HealthElement(it)))
237
239
  .catch((err) => this.handleError(err));
238
240
  }
@@ -247,7 +249,7 @@ class IccTmpApi {
247
249
  const _url = this.host + `/tmp/invoice` + '?ts=' + new Date().getTime();
248
250
  let headers = this.headers;
249
251
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
250
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
252
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
251
253
  .then((doc) => new Invoice_1.Invoice(doc.body))
252
254
  .catch((err) => this.handleError(err));
253
255
  }
@@ -262,7 +264,7 @@ class IccTmpApi {
262
264
  const _url = this.host + `/tmp/invoice/batch` + '?ts=' + new Date().getTime();
263
265
  let headers = this.headers;
264
266
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
265
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
267
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
266
268
  .then((doc) => doc.body.map((it) => new Invoice_1.Invoice(it)))
267
269
  .catch((err) => this.handleError(err));
268
270
  }
@@ -277,7 +279,7 @@ class IccTmpApi {
277
279
  const _url = this.host + `/tmp/message` + '?ts=' + new Date().getTime();
278
280
  let headers = this.headers;
279
281
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
280
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
282
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
281
283
  .then((doc) => new Message_1.Message(doc.body))
282
284
  .catch((err) => this.handleError(err));
283
285
  }
@@ -292,7 +294,7 @@ class IccTmpApi {
292
294
  const _url = this.host + `/tmp/message/batch` + '?ts=' + new Date().getTime();
293
295
  let headers = this.headers;
294
296
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
295
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
297
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
296
298
  .then((doc) => doc.body.map((it) => new Message_1.Message(it)))
297
299
  .catch((err) => this.handleError(err));
298
300
  }
@@ -307,7 +309,7 @@ class IccTmpApi {
307
309
  const _url = this.host + `/tmp/patient` + '?ts=' + new Date().getTime();
308
310
  let headers = this.headers;
309
311
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
310
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
312
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
311
313
  .then((doc) => new Patient_1.Patient(doc.body))
312
314
  .catch((err) => this.handleError(err));
313
315
  }
@@ -322,7 +324,7 @@ class IccTmpApi {
322
324
  const _url = this.host + `/tmp/patient/batch` + '?ts=' + new Date().getTime();
323
325
  let headers = this.headers;
324
326
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
325
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
327
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
326
328
  .then((doc) => doc.body.map((it) => new Patient_1.Patient(it)))
327
329
  .catch((err) => this.handleError(err));
328
330
  }
@@ -335,7 +337,7 @@ class IccTmpApi {
335
337
  let _body = null;
336
338
  const _url = this.host + `/tmp/document/${encodeURIComponent(String(documentId))}/attachment` + '?ts=' + new Date().getTime();
337
339
  let headers = this.headers;
338
- return XHR_1.XHR.sendCommand('DELETE', _url, headers, _body, this.fetchImpl)
340
+ return XHR_1.XHR.sendCommand('DELETE', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
339
341
  .then((doc) => new Document_1.Document(doc.body))
340
342
  .catch((err) => this.handleError(err));
341
343
  }
@@ -350,7 +352,7 @@ class IccTmpApi {
350
352
  const _url = this.host + `/tmp/batch/delete` + '?ts=' + new Date().getTime();
351
353
  let headers = this.headers;
352
354
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
353
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
355
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
354
356
  .then((doc) => doc.body.map((it) => new DocIdentifier_1.DocIdentifier(it)))
355
357
  .catch((err) => this.handleError(err));
356
358
  }
@@ -362,7 +364,7 @@ class IccTmpApi {
362
364
  let _body = null;
363
365
  const _url = this.host + `/tmp` + '?ts=' + new Date().getTime();
364
366
  let headers = this.headers;
365
- return XHR_1.XHR.sendCommand('DELETE', _url, headers, _body, this.fetchImpl)
367
+ return XHR_1.XHR.sendCommand('DELETE', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
366
368
  .then((doc) => new Unit_1.Unit(doc.body))
367
369
  .catch((err) => this.handleError(err));
368
370
  }
@@ -375,7 +377,7 @@ class IccTmpApi {
375
377
  let _body = null;
376
378
  const _url = this.host + `/tmp/classification/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
377
379
  let headers = this.headers;
378
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
380
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
379
381
  .then((doc) => new Classification_1.Classification(doc.body))
380
382
  .catch((err) => this.handleError(err));
381
383
  }
@@ -390,7 +392,7 @@ class IccTmpApi {
390
392
  const _url = this.host + `/tmp/classification/get` + '?ts=' + new Date().getTime();
391
393
  let headers = this.headers;
392
394
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
393
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
395
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
394
396
  .then((doc) => doc.body.map((it) => new Classification_1.Classification(it)))
395
397
  .catch((err) => this.handleError(err));
396
398
  }
@@ -403,7 +405,7 @@ class IccTmpApi {
403
405
  let _body = null;
404
406
  const _url = this.host + `/tmp/contact/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
405
407
  let headers = this.headers;
406
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
408
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
407
409
  .then((doc) => new Contact_1.Contact(doc.body))
408
410
  .catch((err) => this.handleError(err));
409
411
  }
@@ -418,7 +420,7 @@ class IccTmpApi {
418
420
  const _url = this.host + `/tmp/contact/get` + '?ts=' + new Date().getTime();
419
421
  let headers = this.headers;
420
422
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
421
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
423
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
422
424
  .then((doc) => doc.body.map((it) => new Contact_1.Contact(it)))
423
425
  .catch((err) => this.handleError(err));
424
426
  }
@@ -431,7 +433,7 @@ class IccTmpApi {
431
433
  let _body = null;
432
434
  const _url = this.host + `/tmp/document/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
433
435
  let headers = this.headers;
434
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
436
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
435
437
  .then((doc) => new Document_1.Document(doc.body))
436
438
  .catch((err) => this.handleError(err));
437
439
  }
@@ -451,7 +453,7 @@ class IccTmpApi {
451
453
  (enckeys ? '&enckeys=' + encodeURIComponent(String(enckeys)) : '') +
452
454
  (fileName ? '&fileName=' + encodeURIComponent(String(fileName)) : '');
453
455
  let headers = this.headers;
454
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
456
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
455
457
  .then((doc) => true)
456
458
  .catch((err) => this.handleError(err));
457
459
  }
@@ -466,7 +468,7 @@ class IccTmpApi {
466
468
  const _url = this.host + `/tmp/document/get` + '?ts=' + new Date().getTime();
467
469
  let headers = this.headers;
468
470
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
469
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
471
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
470
472
  .then((doc) => doc.body.map((it) => new Document_1.Document(it)))
471
473
  .catch((err) => this.handleError(err));
472
474
  }
@@ -479,7 +481,7 @@ class IccTmpApi {
479
481
  let _body = null;
480
482
  const _url = this.host + `/tmp/entityTemplate/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
481
483
  let headers = this.headers;
482
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
484
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
483
485
  .then((doc) => new EntityTemplate_1.EntityTemplate(doc.body))
484
486
  .catch((err) => this.handleError(err));
485
487
  }
@@ -494,7 +496,7 @@ class IccTmpApi {
494
496
  const _url = this.host + `/tmp/entityTemplate/get` + '?ts=' + new Date().getTime();
495
497
  let headers = this.headers;
496
498
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
497
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
499
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
498
500
  .then((doc) => doc.body.map((it) => new EntityTemplate_1.EntityTemplate(it)))
499
501
  .catch((err) => this.handleError(err));
500
502
  }
@@ -507,7 +509,7 @@ class IccTmpApi {
507
509
  let _body = null;
508
510
  const _url = this.host + `/tmp/form/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
509
511
  let headers = this.headers;
510
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
512
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
511
513
  .then((doc) => new Form_1.Form(doc.body))
512
514
  .catch((err) => this.handleError(err));
513
515
  }
@@ -522,7 +524,7 @@ class IccTmpApi {
522
524
  const _url = this.host + `/tmp/form/get` + '?ts=' + new Date().getTime();
523
525
  let headers = this.headers;
524
526
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
525
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
527
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
526
528
  .then((doc) => doc.body.map((it) => new Form_1.Form(it)))
527
529
  .catch((err) => this.handleError(err));
528
530
  }
@@ -535,7 +537,7 @@ class IccTmpApi {
535
537
  let _body = null;
536
538
  const _url = this.host + `/tmp/healthElement/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
537
539
  let headers = this.headers;
538
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
540
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
539
541
  .then((doc) => new HealthElement_1.HealthElement(doc.body))
540
542
  .catch((err) => this.handleError(err));
541
543
  }
@@ -550,7 +552,7 @@ class IccTmpApi {
550
552
  const _url = this.host + `/tmp/healthElement/get` + '?ts=' + new Date().getTime();
551
553
  let headers = this.headers;
552
554
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
553
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
555
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
554
556
  .then((doc) => doc.body.map((it) => new HealthElement_1.HealthElement(it)))
555
557
  .catch((err) => this.handleError(err));
556
558
  }
@@ -563,7 +565,7 @@ class IccTmpApi {
563
565
  let _body = null;
564
566
  const _url = this.host + `/tmp/invoice/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
565
567
  let headers = this.headers;
566
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
568
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
567
569
  .then((doc) => new Invoice_1.Invoice(doc.body))
568
570
  .catch((err) => this.handleError(err));
569
571
  }
@@ -578,7 +580,7 @@ class IccTmpApi {
578
580
  const _url = this.host + `/tmp/invoice/get` + '?ts=' + new Date().getTime();
579
581
  let headers = this.headers;
580
582
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
581
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
583
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
582
584
  .then((doc) => doc.body.map((it) => new Invoice_1.Invoice(it)))
583
585
  .catch((err) => this.handleError(err));
584
586
  }
@@ -591,7 +593,7 @@ class IccTmpApi {
591
593
  let _body = null;
592
594
  const _url = this.host + `/tmp/message/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
593
595
  let headers = this.headers;
594
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
596
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
595
597
  .then((doc) => new Message_1.Message(doc.body))
596
598
  .catch((err) => this.handleError(err));
597
599
  }
@@ -606,7 +608,7 @@ class IccTmpApi {
606
608
  const _url = this.host + `/tmp/message/get` + '?ts=' + new Date().getTime();
607
609
  let headers = this.headers;
608
610
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
609
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
611
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
610
612
  .then((doc) => doc.body.map((it) => new Message_1.Message(it)))
611
613
  .catch((err) => this.handleError(err));
612
614
  }
@@ -619,7 +621,7 @@ class IccTmpApi {
619
621
  let _body = null;
620
622
  const _url = this.host + `/tmp/patient/byId/${encodeURIComponent(String(id))}` + '?ts=' + new Date().getTime();
621
623
  let headers = this.headers;
622
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
624
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
623
625
  .then((doc) => new Patient_1.Patient(doc.body))
624
626
  .catch((err) => this.handleError(err));
625
627
  }
@@ -634,7 +636,7 @@ class IccTmpApi {
634
636
  const _url = this.host + `/tmp/patient/get` + '?ts=' + new Date().getTime();
635
637
  let headers = this.headers;
636
638
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
637
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
639
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
638
640
  .then((doc) => doc.body.map((it) => new Patient_1.Patient(it)))
639
641
  .catch((err) => this.handleError(err));
640
642
  }
@@ -653,7 +655,7 @@ class IccTmpApi {
653
655
  (firstClassificationId ? '&firstClassificationId=' + encodeURIComponent(String(firstClassificationId)) : '') +
654
656
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
655
657
  let headers = this.headers;
656
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
658
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
657
659
  .then((doc) => new PaginatedListClassification_1.PaginatedListClassification(doc.body))
658
660
  .catch((err) => this.handleError(err));
659
661
  }
@@ -672,7 +674,7 @@ class IccTmpApi {
672
674
  (firstContactId ? '&firstContactId=' + encodeURIComponent(String(firstContactId)) : '') +
673
675
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
674
676
  let headers = this.headers;
675
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
677
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
676
678
  .then((doc) => new PaginatedListInvoice_1.PaginatedListInvoice(doc.body))
677
679
  .catch((err) => this.handleError(err));
678
680
  }
@@ -691,7 +693,7 @@ class IccTmpApi {
691
693
  (firstDocumentId ? '&firstDocumentId=' + encodeURIComponent(String(firstDocumentId)) : '') +
692
694
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
693
695
  let headers = this.headers;
694
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
696
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
695
697
  .then((doc) => new PaginatedListDocument_1.PaginatedListDocument(doc.body))
696
698
  .catch((err) => this.handleError(err));
697
699
  }
@@ -710,7 +712,7 @@ class IccTmpApi {
710
712
  (firstEntityTemplateId ? '&firstEntityTemplateId=' + encodeURIComponent(String(firstEntityTemplateId)) : '') +
711
713
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
712
714
  let headers = this.headers;
713
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
715
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
714
716
  .then((doc) => new PaginatedListEntityTemplate_1.PaginatedListEntityTemplate(doc.body))
715
717
  .catch((err) => this.handleError(err));
716
718
  }
@@ -729,7 +731,7 @@ class IccTmpApi {
729
731
  (firstFormId ? '&firstFormId=' + encodeURIComponent(String(firstFormId)) : '') +
730
732
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
731
733
  let headers = this.headers;
732
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
734
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
733
735
  .then((doc) => new PaginatedListForm_1.PaginatedListForm(doc.body))
734
736
  .catch((err) => this.handleError(err));
735
737
  }
@@ -748,7 +750,7 @@ class IccTmpApi {
748
750
  (firstHealthElementId ? '&firstHealthElementId=' + encodeURIComponent(String(firstHealthElementId)) : '') +
749
751
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
750
752
  let headers = this.headers;
751
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
753
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
752
754
  .then((doc) => new PaginatedListHealthElement_1.PaginatedListHealthElement(doc.body))
753
755
  .catch((err) => this.handleError(err));
754
756
  }
@@ -767,7 +769,7 @@ class IccTmpApi {
767
769
  (firstInvoiceId ? '&firstInvoiceId=' + encodeURIComponent(String(firstInvoiceId)) : '') +
768
770
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
769
771
  let headers = this.headers;
770
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
772
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
771
773
  .then((doc) => new PaginatedListInvoice_1.PaginatedListInvoice(doc.body))
772
774
  .catch((err) => this.handleError(err));
773
775
  }
@@ -786,7 +788,7 @@ class IccTmpApi {
786
788
  (firstMessageId ? '&firstMessageId=' + encodeURIComponent(String(firstMessageId)) : '') +
787
789
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
788
790
  let headers = this.headers;
789
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
791
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
790
792
  .then((doc) => new PaginatedListInvoice_1.PaginatedListInvoice(doc.body))
791
793
  .catch((err) => this.handleError(err));
792
794
  }
@@ -805,7 +807,7 @@ class IccTmpApi {
805
807
  (firstPatientId ? '&firstPatientId=' + encodeURIComponent(String(firstPatientId)) : '') +
806
808
  (pageSize ? '&pageSize=' + encodeURIComponent(String(pageSize)) : '');
807
809
  let headers = this.headers;
808
- return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl)
810
+ return XHR_1.XHR.sendCommand('GET', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
809
811
  .then((doc) => new PaginatedListPatient_1.PaginatedListPatient(doc.body))
810
812
  .catch((err) => this.handleError(err));
811
813
  }
@@ -820,7 +822,7 @@ class IccTmpApi {
820
822
  const _url = this.host + `/tmp/classification` + '?ts=' + new Date().getTime();
821
823
  let headers = this.headers;
822
824
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
823
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
825
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
824
826
  .then((doc) => new Classification_1.Classification(doc.body))
825
827
  .catch((err) => this.handleError(err));
826
828
  }
@@ -835,7 +837,7 @@ class IccTmpApi {
835
837
  const _url = this.host + `/tmp/classification/batch` + '?ts=' + new Date().getTime();
836
838
  let headers = this.headers;
837
839
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
838
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
840
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
839
841
  .then((doc) => doc.body.map((it) => new Classification_1.Classification(it)))
840
842
  .catch((err) => this.handleError(err));
841
843
  }
@@ -850,7 +852,7 @@ class IccTmpApi {
850
852
  const _url = this.host + `/tmp/contact` + '?ts=' + new Date().getTime();
851
853
  let headers = this.headers;
852
854
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
853
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
855
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
854
856
  .then((doc) => new Contact_1.Contact(doc.body))
855
857
  .catch((err) => this.handleError(err));
856
858
  }
@@ -865,7 +867,7 @@ class IccTmpApi {
865
867
  const _url = this.host + `/tmp/contact/batch` + '?ts=' + new Date().getTime();
866
868
  let headers = this.headers;
867
869
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
868
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
870
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
869
871
  .then((doc) => doc.body.map((it) => new Contact_1.Contact(it)))
870
872
  .catch((err) => this.handleError(err));
871
873
  }
@@ -880,7 +882,7 @@ class IccTmpApi {
880
882
  const _url = this.host + `/tmp/document` + '?ts=' + new Date().getTime();
881
883
  let headers = this.headers;
882
884
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
883
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
885
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
884
886
  .then((doc) => new Document_1.Document(doc.body))
885
887
  .catch((err) => this.handleError(err));
886
888
  }
@@ -895,7 +897,7 @@ class IccTmpApi {
895
897
  const _url = this.host + `/tmp/document/batch` + '?ts=' + new Date().getTime();
896
898
  let headers = this.headers;
897
899
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
898
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
900
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
899
901
  .then((doc) => doc.body.map((it) => new Document_1.Document(it)))
900
902
  .catch((err) => this.handleError(err));
901
903
  }
@@ -910,7 +912,7 @@ class IccTmpApi {
910
912
  const _url = this.host + `/tmp/entityTemplate` + '?ts=' + new Date().getTime();
911
913
  let headers = this.headers;
912
914
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
913
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
915
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
914
916
  .then((doc) => new EntityTemplate_1.EntityTemplate(doc.body))
915
917
  .catch((err) => this.handleError(err));
916
918
  }
@@ -925,7 +927,7 @@ class IccTmpApi {
925
927
  const _url = this.host + `/tmp/entityTemplate/batch` + '?ts=' + new Date().getTime();
926
928
  let headers = this.headers;
927
929
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
928
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
930
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
929
931
  .then((doc) => doc.body.map((it) => new EntityTemplate_1.EntityTemplate(it)))
930
932
  .catch((err) => this.handleError(err));
931
933
  }
@@ -940,7 +942,7 @@ class IccTmpApi {
940
942
  const _url = this.host + `/tmp/form` + '?ts=' + new Date().getTime();
941
943
  let headers = this.headers;
942
944
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
943
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
945
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
944
946
  .then((doc) => new Form_1.Form(doc.body))
945
947
  .catch((err) => this.handleError(err));
946
948
  }
@@ -955,7 +957,7 @@ class IccTmpApi {
955
957
  const _url = this.host + `/tmp/form/batch` + '?ts=' + new Date().getTime();
956
958
  let headers = this.headers;
957
959
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
958
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
960
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
959
961
  .then((doc) => doc.body.map((it) => new Form_1.Form(it)))
960
962
  .catch((err) => this.handleError(err));
961
963
  }
@@ -970,7 +972,7 @@ class IccTmpApi {
970
972
  const _url = this.host + `/tmp/healthElement` + '?ts=' + new Date().getTime();
971
973
  let headers = this.headers;
972
974
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
973
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
975
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
974
976
  .then((doc) => new HealthElement_1.HealthElement(doc.body))
975
977
  .catch((err) => this.handleError(err));
976
978
  }
@@ -985,7 +987,7 @@ class IccTmpApi {
985
987
  const _url = this.host + `/tmp/healthElement/batch` + '?ts=' + new Date().getTime();
986
988
  let headers = this.headers;
987
989
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
988
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
990
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
989
991
  .then((doc) => doc.body.map((it) => new HealthElement_1.HealthElement(it)))
990
992
  .catch((err) => this.handleError(err));
991
993
  }
@@ -1000,7 +1002,7 @@ class IccTmpApi {
1000
1002
  const _url = this.host + `/tmp/invoice` + '?ts=' + new Date().getTime();
1001
1003
  let headers = this.headers;
1002
1004
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
1003
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
1005
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1004
1006
  .then((doc) => new Invoice_1.Invoice(doc.body))
1005
1007
  .catch((err) => this.handleError(err));
1006
1008
  }
@@ -1015,7 +1017,7 @@ class IccTmpApi {
1015
1017
  const _url = this.host + `/tmp/invoice/batch` + '?ts=' + new Date().getTime();
1016
1018
  let headers = this.headers;
1017
1019
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
1018
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
1020
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1019
1021
  .then((doc) => doc.body.map((it) => new Invoice_1.Invoice(it)))
1020
1022
  .catch((err) => this.handleError(err));
1021
1023
  }
@@ -1030,7 +1032,7 @@ class IccTmpApi {
1030
1032
  const _url = this.host + `/tmp/message` + '?ts=' + new Date().getTime();
1031
1033
  let headers = this.headers;
1032
1034
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
1033
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
1035
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1034
1036
  .then((doc) => new Message_1.Message(doc.body))
1035
1037
  .catch((err) => this.handleError(err));
1036
1038
  }
@@ -1045,7 +1047,7 @@ class IccTmpApi {
1045
1047
  const _url = this.host + `/tmp/message/batch` + '?ts=' + new Date().getTime();
1046
1048
  let headers = this.headers;
1047
1049
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
1048
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
1050
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1049
1051
  .then((doc) => doc.body.map((it) => new Message_1.Message(it)))
1050
1052
  .catch((err) => this.handleError(err));
1051
1053
  }
@@ -1060,7 +1062,7 @@ class IccTmpApi {
1060
1062
  const _url = this.host + `/tmp/patient` + '?ts=' + new Date().getTime();
1061
1063
  let headers = this.headers;
1062
1064
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
1063
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
1065
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1064
1066
  .then((doc) => new Patient_1.Patient(doc.body))
1065
1067
  .catch((err) => this.handleError(err));
1066
1068
  }
@@ -1075,7 +1077,7 @@ class IccTmpApi {
1075
1077
  const _url = this.host + `/tmp/patient/batch` + '?ts=' + new Date().getTime();
1076
1078
  let headers = this.headers;
1077
1079
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
1078
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
1080
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1079
1081
  .then((doc) => doc.body.map((it) => new Patient_1.Patient(it)))
1080
1082
  .catch((err) => this.handleError(err));
1081
1083
  }
@@ -1090,7 +1092,7 @@ class IccTmpApi {
1090
1092
  const _url = this.host + `/tmp/batch/purge` + '?ts=' + new Date().getTime();
1091
1093
  let headers = this.headers;
1092
1094
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
1093
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
1095
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1094
1096
  .then((doc) => doc.body.map((it) => new DocIdentifier_1.DocIdentifier(it)))
1095
1097
  .catch((err) => this.handleError(err));
1096
1098
  }
@@ -1105,7 +1107,7 @@ class IccTmpApi {
1105
1107
  const _url = this.host + `/tmp/replicate/from/${encodeURIComponent(String(from))}` + '?ts=' + new Date().getTime();
1106
1108
  let headers = this.headers;
1107
1109
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/json'));
1108
- return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl)
1110
+ return XHR_1.XHR.sendCommand('POST', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1109
1111
  .then((doc) => new ReplicatorDocument_1.ReplicatorDocument(doc.body))
1110
1112
  .catch((err) => this.handleError(err));
1111
1113
  }
@@ -1126,7 +1128,7 @@ class IccTmpApi {
1126
1128
  (enckeys ? '&enckeys=' + encodeURIComponent(String(enckeys)) : '');
1127
1129
  let headers = this.headers;
1128
1130
  headers = headers.filter((h) => h.header !== 'Content-Type').concat(new XHR_1.XHR.Header('Content-Type', 'application/octet-stream'));
1129
- return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl)
1131
+ return XHR_1.XHR.sendCommand('PUT', _url, headers, _body, this.fetchImpl, undefined, this.authenticationProvider.getAuthService())
1130
1132
  .then((doc) => new Document_1.Document(doc.body))
1131
1133
  .catch((err) => this.handleError(err));
1132
1134
  }