edge-impulse-linux 1.4.3 → 1.4.5

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 (615) hide show
  1. package/build/cli/linux/runner.js +8 -2
  2. package/build/cli/linux/runner.js.map +1 -1
  3. package/build/cli/linux/webserver/public/webserver.js +47 -2
  4. package/build/cli/linux/webserver/public/webserver.js.map +1 -1
  5. package/build/library/classifier/linux-impulse-runner.js +7 -1
  6. package/build/library/classifier/linux-impulse-runner.js.map +1 -1
  7. package/build/sdk/studio/api.d.ts +2 -1
  8. package/build/sdk/studio/api.js +5 -0
  9. package/build/sdk/studio/api.js.map +1 -1
  10. package/build/sdk/studio/sdk/api/adminApi.d.ts +200 -0
  11. package/build/sdk/studio/sdk/api/adminApi.js +1529 -279
  12. package/build/sdk/studio/sdk/api/adminApi.js.map +1 -1
  13. package/build/sdk/studio/sdk/api/allowsReadOnlyApi.d.ts +29 -4
  14. package/build/sdk/studio/sdk/api/allowsReadOnlyApi.js +92 -3
  15. package/build/sdk/studio/sdk/api/allowsReadOnlyApi.js.map +1 -1
  16. package/build/sdk/studio/sdk/api/apis.d.ts +5 -1
  17. package/build/sdk/studio/sdk/api/apis.js +5 -1
  18. package/build/sdk/studio/sdk/api/apis.js.map +1 -1
  19. package/build/sdk/studio/sdk/api/classifyApi.d.ts +28 -2
  20. package/build/sdk/studio/sdk/api/classifyApi.js +91 -2
  21. package/build/sdk/studio/sdk/api/classifyApi.js.map +1 -1
  22. package/build/sdk/studio/sdk/api/dSPApi.d.ts +14 -0
  23. package/build/sdk/studio/sdk/api/dSPApi.js +85 -0
  24. package/build/sdk/studio/sdk/api/dSPApi.js.map +1 -1
  25. package/build/sdk/studio/sdk/api/jobsApi.d.ts +3 -1
  26. package/build/sdk/studio/sdk/api/jobsApi.js +3 -1
  27. package/build/sdk/studio/sdk/api/jobsApi.js.map +1 -1
  28. package/build/sdk/studio/sdk/api/learnApi.d.ts +28 -2
  29. package/build/sdk/studio/sdk/api/learnApi.js +168 -1
  30. package/build/sdk/studio/sdk/api/learnApi.js.map +1 -1
  31. package/build/sdk/studio/sdk/api/loginApi.d.ts +5 -5
  32. package/build/sdk/studio/sdk/api/loginApi.js +7 -7
  33. package/build/sdk/studio/sdk/api/loginApi.js.map +1 -1
  34. package/build/sdk/studio/sdk/api/metricsApi.js +3 -1
  35. package/build/sdk/studio/sdk/api/metricsApi.js.map +1 -1
  36. package/build/sdk/studio/sdk/api/organizationAllowGuestAccessApi.d.ts +1 -1
  37. package/build/sdk/studio/sdk/api/organizationAllowGuestAccessApi.js +1 -1
  38. package/build/sdk/studio/sdk/api/organizationDataApi.d.ts +33 -3
  39. package/build/sdk/studio/sdk/api/organizationDataApi.js +172 -2
  40. package/build/sdk/studio/sdk/api/organizationDataApi.js.map +1 -1
  41. package/build/sdk/studio/sdk/api/organizationDataCampaignsApi.d.ts +196 -0
  42. package/build/sdk/studio/sdk/api/organizationDataCampaignsApi.js +1048 -0
  43. package/build/sdk/studio/sdk/api/organizationDataCampaignsApi.js.map +1 -0
  44. package/build/sdk/studio/sdk/api/organizationRequiresAdminApi.d.ts +163 -0
  45. package/build/sdk/studio/sdk/api/organizationRequiresAdminApi.js +1064 -26
  46. package/build/sdk/studio/sdk/api/organizationRequiresAdminApi.js.map +1 -1
  47. package/build/sdk/studio/sdk/api/organizationRequiresWhitelabelAdminApi.d.ts +165 -0
  48. package/build/sdk/studio/sdk/api/organizationRequiresWhitelabelAdminApi.js +1064 -26
  49. package/build/sdk/studio/sdk/api/organizationRequiresWhitelabelAdminApi.js.map +1 -1
  50. package/build/sdk/studio/sdk/api/organizationsApi.d.ts +163 -0
  51. package/build/sdk/studio/sdk/api/organizationsApi.js +1064 -26
  52. package/build/sdk/studio/sdk/api/organizationsApi.js.map +1 -1
  53. package/build/sdk/studio/sdk/api/projectRequiresAdminApi.d.ts +65 -0
  54. package/build/sdk/studio/sdk/api/projectRequiresAdminApi.js +231 -0
  55. package/build/sdk/studio/sdk/api/projectRequiresAdminApi.js.map +1 -0
  56. package/build/sdk/studio/sdk/api/projectsApi.d.ts +17 -0
  57. package/build/sdk/studio/sdk/api/projectsApi.js +81 -0
  58. package/build/sdk/studio/sdk/api/projectsApi.js.map +1 -1
  59. package/build/sdk/studio/sdk/api/rawDataApi.d.ts +88 -0
  60. package/build/sdk/studio/sdk/api/rawDataApi.js +486 -0
  61. package/build/sdk/studio/sdk/api/rawDataApi.js.map +1 -1
  62. package/build/sdk/studio/sdk/api/requiresSudoApi.d.ts +0 -457
  63. package/build/sdk/studio/sdk/api/requiresSudoApi.js +26 -2816
  64. package/build/sdk/studio/sdk/api/requiresSudoApi.js.map +1 -1
  65. package/build/sdk/studio/sdk/api/userApi.d.ts +2 -2
  66. package/build/sdk/studio/sdk/api/userApi.js +1 -1
  67. package/build/sdk/studio/sdk/api/userApi.js.map +1 -1
  68. package/build/sdk/studio/sdk/model/addKerasFilesRequest.d.ts +33 -0
  69. package/build/sdk/studio/sdk/model/addKerasFilesRequest.js +32 -0
  70. package/build/sdk/studio/sdk/model/addKerasFilesRequest.js.map +1 -0
  71. package/build/sdk/studio/sdk/model/addMemberRequest.d.ts +2 -3
  72. package/build/sdk/studio/sdk/model/addMemberRequest.js +2 -3
  73. package/build/sdk/studio/sdk/model/addMemberRequest.js.map +1 -1
  74. package/build/sdk/studio/sdk/model/addOrganizationBucketRequest.d.ts +4 -8
  75. package/build/sdk/studio/sdk/model/addOrganizationBucketRequest.js +4 -9
  76. package/build/sdk/studio/sdk/model/addOrganizationBucketRequest.js.map +1 -1
  77. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardRequest.d.ts +32 -0
  78. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardRequest.js +43 -0
  79. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardRequest.js.map +1 -0
  80. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardResponse.d.ts +33 -0
  81. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardResponse.js +42 -0
  82. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardResponse.js.map +1 -0
  83. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardResponseAllOf.d.ts +25 -0
  84. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardResponseAllOf.js +32 -0
  85. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignDashboardResponseAllOf.js.map +1 -0
  86. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignRequest.d.ts +41 -0
  87. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignRequest.js +87 -0
  88. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignRequest.js.map +1 -0
  89. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignResponse.d.ts +33 -0
  90. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignResponse.js +42 -0
  91. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignResponse.js.map +1 -0
  92. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignResponseAllOf.d.ts +25 -0
  93. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignResponseAllOf.js +32 -0
  94. package/build/sdk/studio/sdk/model/addOrganizationDataCampaignResponseAllOf.js.map +1 -0
  95. package/build/sdk/studio/sdk/model/addOrganizationTransferLearningBlockRequest.d.ts +10 -0
  96. package/build/sdk/studio/sdk/model/addOrganizationTransferLearningBlockRequest.js +15 -0
  97. package/build/sdk/studio/sdk/model/addOrganizationTransferLearningBlockRequest.js.map +1 -1
  98. package/build/sdk/studio/sdk/model/adminAddDisallowedEmailDomainRequest.d.ts +25 -0
  99. package/build/sdk/studio/sdk/model/adminAddDisallowedEmailDomainRequest.js +32 -0
  100. package/build/sdk/studio/sdk/model/adminAddDisallowedEmailDomainRequest.js.map +1 -0
  101. package/build/sdk/studio/sdk/model/adminAddOrganizationUserRequest.d.ts +34 -0
  102. package/build/sdk/studio/sdk/model/adminAddOrganizationUserRequest.js +42 -0
  103. package/build/sdk/studio/sdk/model/adminAddOrganizationUserRequest.js.map +1 -0
  104. package/build/sdk/studio/sdk/model/adminAddOrganizationUserRequestAllOf.d.ts +30 -0
  105. package/build/sdk/studio/sdk/model/adminAddOrganizationUserRequestAllOf.js +37 -0
  106. package/build/sdk/studio/sdk/model/adminAddOrganizationUserRequestAllOf.js.map +1 -0
  107. package/build/sdk/studio/sdk/model/adminAddProjectUserRequest.d.ts +2 -5
  108. package/build/sdk/studio/sdk/model/adminAddProjectUserRequest.js +4 -9
  109. package/build/sdk/studio/sdk/model/adminAddProjectUserRequest.js.map +1 -1
  110. package/build/sdk/studio/sdk/model/adminAddUserRequest.d.ts +28 -0
  111. package/build/sdk/studio/sdk/model/adminAddUserRequest.js +32 -0
  112. package/build/sdk/studio/sdk/model/adminAddUserRequest.js.map +1 -0
  113. package/build/sdk/studio/sdk/model/adminApiOrganization.d.ts +8 -0
  114. package/build/sdk/studio/sdk/model/adminApiOrganization.js +10 -0
  115. package/build/sdk/studio/sdk/model/adminApiOrganization.js.map +1 -1
  116. package/build/sdk/studio/sdk/model/adminApiUser.d.ts +16 -1
  117. package/build/sdk/studio/sdk/model/adminApiUser.js +22 -2
  118. package/build/sdk/studio/sdk/model/adminApiUser.js.map +1 -1
  119. package/build/sdk/studio/sdk/model/adminApiUserAllOf.d.ts +9 -0
  120. package/build/sdk/studio/sdk/model/adminApiUserAllOf.js +10 -0
  121. package/build/sdk/studio/sdk/model/adminApiUserAllOf.js.map +1 -1
  122. package/build/sdk/studio/sdk/model/adminCreateUserTrialRequest.d.ts +36 -0
  123. package/build/sdk/studio/sdk/model/adminCreateUserTrialRequest.js +42 -0
  124. package/build/sdk/studio/sdk/model/adminCreateUserTrialRequest.js.map +1 -0
  125. package/build/sdk/studio/sdk/model/adminGetDataMigrationResponse.d.ts +34 -0
  126. package/build/sdk/studio/sdk/model/adminGetDataMigrationResponse.js +42 -0
  127. package/build/sdk/studio/sdk/model/adminGetDataMigrationResponse.js.map +1 -0
  128. package/build/sdk/studio/sdk/model/adminGetDataMigrationResponseAllOf.d.ts +26 -0
  129. package/build/sdk/studio/sdk/model/adminGetDataMigrationResponseAllOf.js +32 -0
  130. package/build/sdk/studio/sdk/model/adminGetDataMigrationResponseAllOf.js.map +1 -0
  131. package/build/sdk/studio/sdk/model/adminGetDataMigrationsResponse.d.ts +34 -0
  132. package/build/sdk/studio/sdk/model/adminGetDataMigrationsResponse.js +42 -0
  133. package/build/sdk/studio/sdk/model/adminGetDataMigrationsResponse.js.map +1 -0
  134. package/build/sdk/studio/sdk/model/adminGetDataMigrationsResponseAllOf.d.ts +26 -0
  135. package/build/sdk/studio/sdk/model/adminGetDataMigrationsResponseAllOf.js +32 -0
  136. package/build/sdk/studio/sdk/model/adminGetDataMigrationsResponseAllOf.js.map +1 -0
  137. package/build/sdk/studio/sdk/model/adminGetDisallowedEmailDomainsResponse.d.ts +33 -0
  138. package/build/sdk/studio/sdk/model/adminGetDisallowedEmailDomainsResponse.js +42 -0
  139. package/build/sdk/studio/sdk/model/adminGetDisallowedEmailDomainsResponse.js.map +1 -0
  140. package/build/sdk/studio/sdk/model/adminGetDisallowedEmailDomainsResponseAllOf.d.ts +25 -0
  141. package/build/sdk/studio/sdk/model/adminGetDisallowedEmailDomainsResponseAllOf.js +32 -0
  142. package/build/sdk/studio/sdk/model/adminGetDisallowedEmailDomainsResponseAllOf.js.map +1 -0
  143. package/build/sdk/studio/sdk/model/adminGetOrganizationsResponseAllOfOrganizations.d.ts +2 -0
  144. package/build/sdk/studio/sdk/model/adminGetOrganizationsResponseAllOfOrganizations.js +5 -0
  145. package/build/sdk/studio/sdk/model/adminGetOrganizationsResponseAllOfOrganizations.js.map +1 -1
  146. package/build/sdk/studio/sdk/model/adminGetUserTrialResponse.d.ts +34 -0
  147. package/build/sdk/studio/sdk/model/adminGetUserTrialResponse.js +42 -0
  148. package/build/sdk/studio/sdk/model/adminGetUserTrialResponse.js.map +1 -0
  149. package/build/sdk/studio/sdk/model/adminGetUserTrialResponseAllOf.d.ts +26 -0
  150. package/build/sdk/studio/sdk/model/adminGetUserTrialResponseAllOf.js +32 -0
  151. package/build/sdk/studio/sdk/model/adminGetUserTrialResponseAllOf.js.map +1 -0
  152. package/build/sdk/studio/sdk/model/adminOrganizationInfoResponse.d.ts +21 -3
  153. package/build/sdk/studio/sdk/model/adminOrganizationInfoResponse.js +26 -1
  154. package/build/sdk/studio/sdk/model/adminOrganizationInfoResponse.js.map +1 -1
  155. package/build/sdk/studio/sdk/model/adminOrganizationInfoResponseAllOf.d.ts +18 -0
  156. package/build/sdk/studio/sdk/model/adminOrganizationInfoResponseAllOf.js +25 -0
  157. package/build/sdk/studio/sdk/model/adminOrganizationInfoResponseAllOf.js.map +1 -1
  158. package/build/sdk/studio/sdk/model/adminToggleDataMigrationRequest.d.ts +32 -0
  159. package/build/sdk/studio/sdk/model/adminToggleDataMigrationRequest.js +37 -0
  160. package/build/sdk/studio/sdk/model/adminToggleDataMigrationRequest.js.map +1 -0
  161. package/build/sdk/studio/sdk/model/adminUpdateOrganizationRequest.d.ts +2 -0
  162. package/build/sdk/studio/sdk/model/adminUpdateOrganizationRequest.js +5 -0
  163. package/build/sdk/studio/sdk/model/adminUpdateOrganizationRequest.js.map +1 -1
  164. package/build/sdk/studio/sdk/model/adminUpdateUserPermissionsRequest.d.ts +26 -0
  165. package/build/sdk/studio/sdk/model/adminUpdateUserPermissionsRequest.js +32 -0
  166. package/build/sdk/studio/sdk/model/adminUpdateUserPermissionsRequest.js.map +1 -0
  167. package/build/sdk/studio/sdk/model/adminUpdateUserRequest.d.ts +12 -0
  168. package/build/sdk/studio/sdk/model/adminUpdateUserRequest.js +15 -0
  169. package/build/sdk/studio/sdk/model/adminUpdateUserRequest.js.map +1 -1
  170. package/build/sdk/studio/sdk/model/adminUpdateUserTrialRequest.d.ts +32 -0
  171. package/build/sdk/studio/sdk/model/adminUpdateUserTrialRequest.js +37 -0
  172. package/build/sdk/studio/sdk/model/adminUpdateUserTrialRequest.js.map +1 -0
  173. package/build/sdk/studio/sdk/model/anomalyModelMetadata.d.ts +22 -2
  174. package/build/sdk/studio/sdk/model/anomalyModelMetadata.js +31 -1
  175. package/build/sdk/studio/sdk/model/anomalyModelMetadata.js.map +1 -1
  176. package/build/sdk/studio/sdk/model/anomalyModelMetadataAllOf.d.ts +61 -0
  177. package/build/sdk/studio/sdk/model/anomalyModelMetadataAllOf.js +77 -0
  178. package/build/sdk/studio/sdk/model/anomalyModelMetadataAllOf.js.map +1 -0
  179. package/build/sdk/studio/sdk/model/anomalyModelMetadataAllOfClusters.d.ts +32 -0
  180. package/build/sdk/studio/sdk/model/anomalyModelMetadataAllOfClusters.js +37 -0
  181. package/build/sdk/studio/sdk/model/anomalyModelMetadataAllOfClusters.js.map +1 -0
  182. package/build/sdk/studio/sdk/model/classifyJobResponse.d.ts +4 -2
  183. package/build/sdk/studio/sdk/model/classifyJobResponse.js +6 -1
  184. package/build/sdk/studio/sdk/model/classifyJobResponse.js.map +1 -1
  185. package/build/sdk/studio/sdk/model/classifyJobResponseAllOf.d.ts +4 -2
  186. package/build/sdk/studio/sdk/model/classifyJobResponseAllOf.js +6 -1
  187. package/build/sdk/studio/sdk/model/classifyJobResponseAllOf.js.map +1 -1
  188. package/build/sdk/studio/sdk/model/classifyJobResponseAllOfAccuracy.d.ts +37 -0
  189. package/build/sdk/studio/sdk/model/classifyJobResponseAllOfAccuracy.js +57 -0
  190. package/build/sdk/studio/sdk/model/classifyJobResponseAllOfAccuracy.js.map +1 -0
  191. package/build/sdk/studio/sdk/model/classifyJobResponseAllOfAccuracyTotalSummary.d.ts +26 -0
  192. package/build/sdk/studio/sdk/model/classifyJobResponseAllOfAccuracyTotalSummary.js +37 -0
  193. package/build/sdk/studio/sdk/model/classifyJobResponseAllOfAccuracyTotalSummary.js.map +1 -0
  194. package/build/sdk/studio/sdk/model/classifyJobResponsePage.d.ts +36 -0
  195. package/build/sdk/studio/sdk/model/classifyJobResponsePage.js +47 -0
  196. package/build/sdk/studio/sdk/model/classifyJobResponsePage.js.map +1 -0
  197. package/build/sdk/studio/sdk/model/classifyJobResponsePageAllOf.d.ts +28 -0
  198. package/build/sdk/studio/sdk/model/classifyJobResponsePageAllOf.js +37 -0
  199. package/build/sdk/studio/sdk/model/classifyJobResponsePageAllOf.js.map +1 -0
  200. package/build/sdk/studio/sdk/model/classifySampleResponseClassificationDetails.d.ts +4 -0
  201. package/build/sdk/studio/sdk/model/classifySampleResponseClassificationDetails.js +5 -0
  202. package/build/sdk/studio/sdk/model/classifySampleResponseClassificationDetails.js.map +1 -1
  203. package/build/sdk/studio/sdk/model/dSPGroupItem.d.ts +2 -1
  204. package/build/sdk/studio/sdk/model/dSPGroupItem.js +5 -0
  205. package/build/sdk/studio/sdk/model/dSPGroupItem.js.map +1 -1
  206. package/build/sdk/studio/sdk/model/dataCampaign.d.ts +41 -0
  207. package/build/sdk/studio/sdk/model/dataCampaign.js +87 -0
  208. package/build/sdk/studio/sdk/model/dataCampaign.js.map +1 -0
  209. package/build/sdk/studio/sdk/model/dataCampaignDashboard.d.ts +35 -0
  210. package/build/sdk/studio/sdk/model/dataCampaignDashboard.js +58 -0
  211. package/build/sdk/studio/sdk/model/dataCampaignDashboard.js.map +1 -0
  212. package/build/sdk/studio/sdk/model/dataCampaignGraph.d.ts +30 -0
  213. package/build/sdk/studio/sdk/model/dataCampaignGraph.js +52 -0
  214. package/build/sdk/studio/sdk/model/dataCampaignGraph.js.map +1 -0
  215. package/build/sdk/studio/sdk/model/dataCampaignGraphValues.d.ts +26 -0
  216. package/build/sdk/studio/sdk/model/dataCampaignGraphValues.js +37 -0
  217. package/build/sdk/studio/sdk/model/dataCampaignGraphValues.js.map +1 -0
  218. package/build/sdk/studio/sdk/model/dataCampaignGraphXData.d.ts +34 -0
  219. package/build/sdk/studio/sdk/model/dataCampaignGraphXData.js +63 -0
  220. package/build/sdk/studio/sdk/model/dataCampaignGraphXData.js.map +1 -0
  221. package/build/sdk/studio/sdk/model/dataCampaignLink.d.ts +27 -0
  222. package/build/sdk/studio/sdk/model/dataCampaignLink.js +42 -0
  223. package/build/sdk/studio/sdk/model/dataCampaignLink.js.map +1 -0
  224. package/build/sdk/studio/sdk/model/dataCampaignQuery.d.ts +27 -0
  225. package/build/sdk/studio/sdk/model/dataCampaignQuery.js +42 -0
  226. package/build/sdk/studio/sdk/model/dataCampaignQuery.js.map +1 -0
  227. package/build/sdk/studio/sdk/model/deployPretrainedModelInputImage.d.ts +2 -0
  228. package/build/sdk/studio/sdk/model/deployPretrainedModelInputImage.js +5 -0
  229. package/build/sdk/studio/sdk/model/deployPretrainedModelInputImage.js.map +1 -1
  230. package/build/sdk/studio/sdk/model/deployPretrainedModelRequest.d.ts +1 -1
  231. package/build/sdk/studio/sdk/model/deployPretrainedModelRequest.js +1 -1
  232. package/build/sdk/studio/sdk/model/deployPretrainedModelRequest.js.map +1 -1
  233. package/build/sdk/studio/sdk/model/deploymentTarget.d.ts +6 -0
  234. package/build/sdk/studio/sdk/model/deploymentTarget.js +15 -0
  235. package/build/sdk/studio/sdk/model/deploymentTarget.js.map +1 -1
  236. package/build/sdk/studio/sdk/model/deploymentTargetEngine.d.ts +1 -1
  237. package/build/sdk/studio/sdk/model/deploymentTargetEngine.js +1 -1
  238. package/build/sdk/studio/sdk/model/deploymentTargetEngine.js.map +1 -1
  239. package/build/sdk/studio/sdk/model/dspRunRequestWithFeatures.d.ts +42 -0
  240. package/build/sdk/studio/sdk/model/dspRunRequestWithFeatures.js +47 -0
  241. package/build/sdk/studio/sdk/model/dspRunRequestWithFeatures.js.map +1 -0
  242. package/build/sdk/studio/sdk/model/dspRunResponse.d.ts +1 -1
  243. package/build/sdk/studio/sdk/model/dspRunResponseAllOf.d.ts +1 -1
  244. package/build/sdk/studio/sdk/model/dspRunResponseWithSample.d.ts +1 -1
  245. package/build/sdk/studio/sdk/model/dspRunResponseWithSampleAllOf.d.ts +1 -1
  246. package/build/sdk/studio/sdk/model/enterpriseTrial.d.ts +56 -0
  247. package/build/sdk/studio/sdk/model/enterpriseTrial.js +67 -0
  248. package/build/sdk/studio/sdk/model/enterpriseTrial.js.map +1 -0
  249. package/build/sdk/studio/sdk/model/entitlementLimits.d.ts +28 -0
  250. package/build/sdk/studio/sdk/model/entitlementLimits.js +47 -0
  251. package/build/sdk/studio/sdk/model/entitlementLimits.js.map +1 -0
  252. package/build/sdk/studio/sdk/model/entityCreatedResponse.d.ts +33 -0
  253. package/build/sdk/studio/sdk/model/entityCreatedResponse.js +42 -0
  254. package/build/sdk/studio/sdk/model/entityCreatedResponse.js.map +1 -0
  255. package/build/sdk/studio/sdk/model/exportKerasBlockDataRequest.d.ts +26 -0
  256. package/build/sdk/studio/sdk/model/exportKerasBlockDataRequest.js +32 -0
  257. package/build/sdk/studio/sdk/model/exportKerasBlockDataRequest.js.map +1 -0
  258. package/build/sdk/studio/sdk/model/getAllImportedFromResponse.d.ts +34 -0
  259. package/build/sdk/studio/sdk/model/getAllImportedFromResponse.js +42 -0
  260. package/build/sdk/studio/sdk/model/getAllImportedFromResponse.js.map +1 -0
  261. package/build/sdk/studio/sdk/model/getAllImportedFromResponseAllOf.d.ts +26 -0
  262. package/build/sdk/studio/sdk/model/getAllImportedFromResponseAllOf.js +32 -0
  263. package/build/sdk/studio/sdk/model/getAllImportedFromResponseAllOf.js.map +1 -0
  264. package/build/sdk/studio/sdk/model/getAllImportedFromResponseAllOfData.d.ts +27 -0
  265. package/build/sdk/studio/sdk/model/getAllImportedFromResponseAllOfData.js +42 -0
  266. package/build/sdk/studio/sdk/model/getAllImportedFromResponseAllOfData.js.map +1 -0
  267. package/build/sdk/studio/sdk/model/getAutoSegmenterResponse.d.ts +38 -0
  268. package/build/sdk/studio/sdk/model/getAutoSegmenterResponse.js +62 -0
  269. package/build/sdk/studio/sdk/model/getAutoSegmenterResponse.js.map +1 -0
  270. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOf.d.ts +30 -0
  271. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOf.js +52 -0
  272. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOf.js.map +1 -0
  273. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOfClusters.d.ts +27 -0
  274. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOfClusters.js +37 -0
  275. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOfClusters.js.map +1 -0
  276. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOfItems.d.ts +25 -0
  277. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOfItems.js +32 -0
  278. package/build/sdk/studio/sdk/model/getAutoSegmenterResponseAllOfItems.js.map +1 -0
  279. package/build/sdk/studio/sdk/model/getJWTRequest.d.ts +43 -0
  280. package/build/sdk/studio/sdk/model/getJWTRequest.js +53 -0
  281. package/build/sdk/studio/sdk/model/getJWTRequest.js.map +1 -0
  282. package/build/sdk/studio/sdk/model/getJWTResponse.d.ts +40 -0
  283. package/build/sdk/studio/sdk/model/getJWTResponse.js +47 -0
  284. package/build/sdk/studio/sdk/model/getJWTResponse.js.map +1 -0
  285. package/build/sdk/studio/sdk/model/getJWTResponseAllOf.d.ts +32 -0
  286. package/build/sdk/studio/sdk/model/getJWTResponseAllOf.js +37 -0
  287. package/build/sdk/studio/sdk/model/getJWTResponseAllOf.js.map +1 -0
  288. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardResponse.d.ts +34 -0
  289. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardResponse.js +42 -0
  290. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardResponse.js.map +1 -0
  291. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardResponseAllOf.d.ts +26 -0
  292. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardResponseAllOf.js +32 -0
  293. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardResponseAllOf.js.map +1 -0
  294. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardsResponse.d.ts +34 -0
  295. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardsResponse.js +42 -0
  296. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardsResponse.js.map +1 -0
  297. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardsResponseAllOf.d.ts +26 -0
  298. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardsResponseAllOf.js +32 -0
  299. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignDashboardsResponseAllOf.js.map +1 -0
  300. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignResponse.d.ts +36 -0
  301. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignResponse.js +47 -0
  302. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignResponse.js.map +1 -0
  303. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponse.d.ts +34 -0
  304. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponse.js +42 -0
  305. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponse.js.map +1 -0
  306. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponseAllOf.d.ts +26 -0
  307. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponseAllOf.js +32 -0
  308. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponseAllOf.js.map +1 -0
  309. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponseAllOfCampaigns.d.ts +28 -0
  310. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponseAllOfCampaigns.js +37 -0
  311. package/build/sdk/studio/sdk/model/getOrganizationDataCampaignsResponseAllOfCampaigns.js.map +1 -0
  312. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponse.d.ts +35 -0
  313. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponse.js +47 -0
  314. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponse.js.map +1 -0
  315. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponseAllOf.d.ts +27 -0
  316. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponseAllOf.js +37 -0
  317. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponseAllOf.js.map +1 -0
  318. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponseAllOfTransformationJobs.d.ts +33 -0
  319. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponseAllOfTransformationJobs.js +72 -0
  320. package/build/sdk/studio/sdk/model/getOrganizationDataItemTransformJobsResponseAllOfTransformationJobs.js.map +1 -0
  321. package/build/sdk/studio/sdk/model/getUserResponse.d.ts +11 -1
  322. package/build/sdk/studio/sdk/model/getUserResponse.js +17 -2
  323. package/build/sdk/studio/sdk/model/getUserResponse.js.map +1 -1
  324. package/build/sdk/studio/sdk/model/getUserResponseAllOf.d.ts +4 -0
  325. package/build/sdk/studio/sdk/model/getUserResponseAllOf.js +5 -0
  326. package/build/sdk/studio/sdk/model/getUserResponseAllOf.js.map +1 -1
  327. package/build/sdk/studio/sdk/model/getUserResponseAllOfWhitelabels.d.ts +4 -0
  328. package/build/sdk/studio/sdk/model/getUserResponseAllOfWhitelabels.js +5 -0
  329. package/build/sdk/studio/sdk/model/getUserResponseAllOfWhitelabels.js.map +1 -1
  330. package/build/sdk/studio/sdk/model/imageInputScaling.d.ts +16 -0
  331. package/build/sdk/studio/sdk/model/imageInputScaling.js +16 -0
  332. package/build/sdk/studio/sdk/model/imageInputScaling.js.map +1 -0
  333. package/build/sdk/studio/sdk/model/inviteOrganizationMemberRequest.d.ts +2 -3
  334. package/build/sdk/studio/sdk/model/inviteOrganizationMemberRequest.js +2 -3
  335. package/build/sdk/studio/sdk/model/inviteOrganizationMemberRequest.js.map +1 -1
  336. package/build/sdk/studio/sdk/model/job.d.ts +4 -0
  337. package/build/sdk/studio/sdk/model/job.js +5 -0
  338. package/build/sdk/studio/sdk/model/job.js.map +1 -1
  339. package/build/sdk/studio/sdk/model/jobDetails.d.ts +74 -0
  340. package/build/sdk/studio/sdk/model/jobDetails.js +92 -0
  341. package/build/sdk/studio/sdk/model/jobDetails.js.map +1 -0
  342. package/build/sdk/studio/sdk/model/jobDetailsAllOf.d.ts +37 -0
  343. package/build/sdk/studio/sdk/model/jobDetailsAllOf.js +42 -0
  344. package/build/sdk/studio/sdk/model/jobDetailsAllOf.js.map +1 -0
  345. package/build/sdk/studio/sdk/model/jobDetailsResponse.d.ts +34 -0
  346. package/build/sdk/studio/sdk/model/jobDetailsResponse.js +42 -0
  347. package/build/sdk/studio/sdk/model/jobDetailsResponse.js.map +1 -0
  348. package/build/sdk/studio/sdk/model/jobDetailsResponseAllOf.d.ts +26 -0
  349. package/build/sdk/studio/sdk/model/jobDetailsResponseAllOf.js +32 -0
  350. package/build/sdk/studio/sdk/model/jobDetailsResponseAllOf.js.map +1 -0
  351. package/build/sdk/studio/sdk/model/jobFailureDetails.d.ts +36 -0
  352. package/build/sdk/studio/sdk/model/jobFailureDetails.js +42 -0
  353. package/build/sdk/studio/sdk/model/jobFailureDetails.js.map +1 -0
  354. package/build/sdk/studio/sdk/model/jobLogsResponse.d.ts +34 -0
  355. package/build/sdk/studio/sdk/model/jobLogsResponse.js +42 -0
  356. package/build/sdk/studio/sdk/model/jobLogsResponse.js.map +1 -0
  357. package/build/sdk/studio/sdk/model/jobLogsResponseAllOf.d.ts +26 -0
  358. package/build/sdk/studio/sdk/model/jobLogsResponseAllOf.js +32 -0
  359. package/build/sdk/studio/sdk/model/jobLogsResponseAllOf.js.map +1 -0
  360. package/build/sdk/studio/sdk/model/jobMetricsResponse.d.ts +35 -0
  361. package/build/sdk/studio/sdk/model/jobMetricsResponse.js +47 -0
  362. package/build/sdk/studio/sdk/model/jobMetricsResponse.js.map +1 -0
  363. package/build/sdk/studio/sdk/model/jobMetricsResponseAllOf.d.ts +27 -0
  364. package/build/sdk/studio/sdk/model/jobMetricsResponseAllOf.js +37 -0
  365. package/build/sdk/studio/sdk/model/jobMetricsResponseAllOf.js.map +1 -0
  366. package/build/sdk/studio/sdk/model/jobParentTypeEnum.d.ts +13 -0
  367. package/build/sdk/studio/sdk/model/jobParentTypeEnum.js +16 -0
  368. package/build/sdk/studio/sdk/model/jobParentTypeEnum.js.map +1 -0
  369. package/build/sdk/studio/sdk/model/jobState.d.ts +36 -0
  370. package/build/sdk/studio/sdk/model/jobState.js +47 -0
  371. package/build/sdk/studio/sdk/model/jobState.js.map +1 -0
  372. package/build/sdk/studio/sdk/model/jobStateExecutionDetails.d.ts +28 -0
  373. package/build/sdk/studio/sdk/model/jobStateExecutionDetails.js +32 -0
  374. package/build/sdk/studio/sdk/model/jobStateExecutionDetails.js.map +1 -0
  375. package/build/sdk/studio/sdk/model/jobStep.d.ts +42 -0
  376. package/build/sdk/studio/sdk/model/jobStep.js +52 -0
  377. package/build/sdk/studio/sdk/model/jobStep.js.map +1 -0
  378. package/build/sdk/studio/sdk/model/kerasModelMetadata.d.ts +2 -0
  379. package/build/sdk/studio/sdk/model/kerasModelMetadata.js +5 -0
  380. package/build/sdk/studio/sdk/model/kerasModelMetadata.js.map +1 -1
  381. package/build/sdk/studio/sdk/model/kerasModelMetadataAllOf.d.ts +2 -0
  382. package/build/sdk/studio/sdk/model/kerasModelMetadataAllOf.js +5 -0
  383. package/build/sdk/studio/sdk/model/kerasModelMetadataAllOf.js.map +1 -1
  384. package/build/sdk/studio/sdk/model/kerasResponse.d.ts +11 -1
  385. package/build/sdk/studio/sdk/model/kerasResponse.js +10 -0
  386. package/build/sdk/studio/sdk/model/kerasResponse.js.map +1 -1
  387. package/build/sdk/studio/sdk/model/kerasResponseAllOf.d.ts +11 -1
  388. package/build/sdk/studio/sdk/model/kerasResponseAllOf.js +10 -0
  389. package/build/sdk/studio/sdk/model/kerasResponseAllOf.js.map +1 -1
  390. package/build/sdk/studio/sdk/model/listOrganizationBucketsResponseAllOfBuckets.d.ts +4 -8
  391. package/build/sdk/studio/sdk/model/listOrganizationBucketsResponseAllOfBuckets.js +5 -10
  392. package/build/sdk/studio/sdk/model/listOrganizationBucketsResponseAllOfBuckets.js.map +1 -1
  393. package/build/sdk/studio/sdk/model/listOrganizationBucketsUserResponseAllOfBuckets.d.ts +0 -8
  394. package/build/sdk/studio/sdk/model/listOrganizationBucketsUserResponseAllOfBuckets.js +0 -10
  395. package/build/sdk/studio/sdk/model/listOrganizationBucketsUserResponseAllOfBuckets.js.map +1 -1
  396. package/build/sdk/studio/sdk/model/migration.d.ts +38 -0
  397. package/build/sdk/studio/sdk/model/migration.js +43 -0
  398. package/build/sdk/studio/sdk/model/migration.js.map +1 -0
  399. package/build/sdk/studio/sdk/model/modelResult.d.ts +29 -0
  400. package/build/sdk/studio/sdk/model/modelResult.js +42 -0
  401. package/build/sdk/studio/sdk/model/modelResult.js.map +1 -0
  402. package/build/sdk/studio/sdk/model/models.d.ts +107 -7
  403. package/build/sdk/studio/sdk/model/models.js +322 -27
  404. package/build/sdk/studio/sdk/model/models.js.map +1 -1
  405. package/build/sdk/studio/sdk/model/optimizeTransferLearningModelsResponseAllOfModels.js +1 -1
  406. package/build/sdk/studio/sdk/model/optimizeTransferLearningModelsResponseAllOfModels.js.map +1 -1
  407. package/build/sdk/studio/sdk/model/organization.d.ts +8 -0
  408. package/build/sdk/studio/sdk/model/organization.js +10 -0
  409. package/build/sdk/studio/sdk/model/organization.js.map +1 -1
  410. package/build/sdk/studio/sdk/model/organizationAddDatasetRequest.d.ts +29 -0
  411. package/build/sdk/studio/sdk/model/organizationAddDatasetRequest.js +47 -0
  412. package/build/sdk/studio/sdk/model/organizationAddDatasetRequest.js.map +1 -0
  413. package/build/sdk/studio/sdk/model/organizationAddDatasetRequestBucket.d.ts +36 -0
  414. package/build/sdk/studio/sdk/model/organizationAddDatasetRequestBucket.js +42 -0
  415. package/build/sdk/studio/sdk/model/organizationAddDatasetRequestBucket.js.map +1 -0
  416. package/build/sdk/studio/sdk/model/organizationCreateProject.d.ts +2 -0
  417. package/build/sdk/studio/sdk/model/organizationCreateProject.js +10 -0
  418. package/build/sdk/studio/sdk/model/organizationCreateProject.js.map +1 -1
  419. package/build/sdk/studio/sdk/model/organizationCreateProjectRequest.d.ts +3 -1
  420. package/build/sdk/studio/sdk/model/organizationCreateProjectRequest.js +11 -1
  421. package/build/sdk/studio/sdk/model/organizationCreateProjectRequest.js.map +1 -1
  422. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFiles.d.ts +3 -0
  423. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFiles.js +15 -0
  424. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFiles.js.map +1 -1
  425. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFilesAllOf.d.ts +1 -0
  426. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFilesAllOf.js +5 -0
  427. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFilesAllOf.js.map +1 -1
  428. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFilesAllOfFiles.d.ts +1 -0
  429. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFilesAllOfFiles.js +5 -0
  430. package/build/sdk/studio/sdk/model/organizationCreateProjectWithFilesAllOfFiles.js.map +1 -1
  431. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffRequest.d.ts +26 -0
  432. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffRequest.js +32 -0
  433. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffRequest.js.map +1 -0
  434. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffRequestQueries.d.ts +30 -0
  435. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffRequestQueries.js +42 -0
  436. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffRequestQueries.js.map +1 -0
  437. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponse.d.ts +35 -0
  438. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponse.js +47 -0
  439. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponse.js.map +1 -0
  440. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponseAllOf.d.ts +27 -0
  441. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponseAllOf.js +37 -0
  442. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponseAllOf.js.map +1 -0
  443. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponseAllOfQueries.d.ts +29 -0
  444. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponseAllOfQueries.js +52 -0
  445. package/build/sdk/studio/sdk/model/organizationDataCampaignDiffResponseAllOfQueries.js.map +1 -0
  446. package/build/sdk/studio/sdk/model/organizationDataset.d.ts +5 -0
  447. package/build/sdk/studio/sdk/model/organizationDataset.js +20 -0
  448. package/build/sdk/studio/sdk/model/organizationDataset.js.map +1 -1
  449. package/build/sdk/studio/sdk/model/organizationDatasetBucket.d.ts +41 -0
  450. package/build/sdk/studio/sdk/model/organizationDatasetBucket.js +52 -0
  451. package/build/sdk/studio/sdk/model/organizationDatasetBucket.js.map +1 -0
  452. package/build/sdk/studio/sdk/model/organizationGetCreateProjectsResponseAllOfJobs.d.ts +2 -0
  453. package/build/sdk/studio/sdk/model/organizationGetCreateProjectsResponseAllOfJobs.js +10 -0
  454. package/build/sdk/studio/sdk/model/organizationGetCreateProjectsResponseAllOfJobs.js.map +1 -1
  455. package/build/sdk/studio/sdk/model/organizationInfoResponse.d.ts +5 -3
  456. package/build/sdk/studio/sdk/model/organizationInfoResponse.js +6 -1
  457. package/build/sdk/studio/sdk/model/organizationInfoResponse.js.map +1 -1
  458. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOf.d.ts +5 -3
  459. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOf.js +6 -1
  460. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOf.js.map +1 -1
  461. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliLists.d.ts +28 -0
  462. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliLists.js +37 -0
  463. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliLists.js.map +1 -0
  464. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliListsImageInputScalingOptions.d.ts +27 -0
  465. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliListsImageInputScalingOptions.js +37 -0
  466. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliListsImageInputScalingOptions.js.map +1 -0
  467. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliListsObjectDetectionLastLayerOptions.d.ts +27 -0
  468. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliListsObjectDetectionLastLayerOptions.js +37 -0
  469. package/build/sdk/studio/sdk/model/organizationInfoResponseAllOfCliListsObjectDetectionLastLayerOptions.js.map +1 -0
  470. package/build/sdk/studio/sdk/model/organizationMemberRole.d.ts +13 -0
  471. package/build/sdk/studio/sdk/model/organizationMemberRole.js +16 -0
  472. package/build/sdk/studio/sdk/model/organizationMemberRole.js.map +1 -0
  473. package/build/sdk/studio/sdk/model/organizationMetricsResponseAllOfMetrics.d.ts +1 -1
  474. package/build/sdk/studio/sdk/model/organizationPipeline.d.ts +1 -1
  475. package/build/sdk/studio/sdk/model/organizationPipeline.js +1 -1
  476. package/build/sdk/studio/sdk/model/organizationPipeline.js.map +1 -1
  477. package/build/sdk/studio/sdk/model/organizationPipelineRunStep.d.ts +2 -0
  478. package/build/sdk/studio/sdk/model/organizationPipelineRunStep.js +10 -0
  479. package/build/sdk/studio/sdk/model/organizationPipelineRunStep.js.map +1 -1
  480. package/build/sdk/studio/sdk/model/organizationPipelineStep.d.ts +2 -0
  481. package/build/sdk/studio/sdk/model/organizationPipelineStep.js +10 -0
  482. package/build/sdk/studio/sdk/model/organizationPipelineStep.js.map +1 -1
  483. package/build/sdk/studio/sdk/model/organizationTransferLearningBlock.d.ts +10 -0
  484. package/build/sdk/studio/sdk/model/organizationTransferLearningBlock.js +15 -0
  485. package/build/sdk/studio/sdk/model/organizationTransferLearningBlock.js.map +1 -1
  486. package/build/sdk/studio/sdk/model/organizationUpdatePipelineBody.d.ts +1 -1
  487. package/build/sdk/studio/sdk/model/organizationUpdatePipelineBody.js +1 -1
  488. package/build/sdk/studio/sdk/model/organizationUpdatePipelineBody.js.map +1 -1
  489. package/build/sdk/studio/sdk/model/organizationUser.d.ts +18 -6
  490. package/build/sdk/studio/sdk/model/organizationUser.js +46 -17
  491. package/build/sdk/studio/sdk/model/organizationUser.js.map +1 -1
  492. package/build/sdk/studio/sdk/model/organizationUserAllOf.d.ts +29 -0
  493. package/build/sdk/studio/sdk/model/organizationUserAllOf.js +47 -0
  494. package/build/sdk/studio/sdk/model/organizationUserAllOf.js.map +1 -0
  495. package/build/sdk/studio/sdk/model/permission.d.ts +13 -0
  496. package/build/sdk/studio/sdk/model/permission.js +16 -0
  497. package/build/sdk/studio/sdk/model/permission.js.map +1 -0
  498. package/build/sdk/studio/sdk/model/projectCollaborator.d.ts +11 -0
  499. package/build/sdk/studio/sdk/model/projectCollaborator.js +20 -0
  500. package/build/sdk/studio/sdk/model/projectCollaborator.js.map +1 -1
  501. package/build/sdk/studio/sdk/model/projectDeploymentTarget.d.ts +6 -0
  502. package/build/sdk/studio/sdk/model/projectDeploymentTarget.js +15 -0
  503. package/build/sdk/studio/sdk/model/projectDeploymentTarget.js.map +1 -1
  504. package/build/sdk/studio/sdk/model/projectInfoResponse.d.ts +4 -1
  505. package/build/sdk/studio/sdk/model/projectInfoResponse.js +5 -5
  506. package/build/sdk/studio/sdk/model/projectInfoResponse.js.map +1 -1
  507. package/build/sdk/studio/sdk/model/projectInfoResponseAllOf.d.ts +4 -1
  508. package/build/sdk/studio/sdk/model/projectInfoResponseAllOf.js +5 -5
  509. package/build/sdk/studio/sdk/model/projectInfoResponseAllOf.js.map +1 -1
  510. package/build/sdk/studio/sdk/model/projectInfoResponseAllOfDeploySettings.d.ts +1 -0
  511. package/build/sdk/studio/sdk/model/projectInfoResponseAllOfDeploySettings.js +5 -0
  512. package/build/sdk/studio/sdk/model/projectInfoResponseAllOfDeploySettings.js.map +1 -1
  513. package/build/sdk/studio/sdk/model/projectPublicData.d.ts +2 -3
  514. package/build/sdk/studio/sdk/model/projectPublicData.js +2 -3
  515. package/build/sdk/studio/sdk/model/projectPublicData.js.map +1 -1
  516. package/build/sdk/studio/sdk/model/projectTrainingDataSummaryResponse.d.ts +34 -0
  517. package/build/sdk/studio/sdk/model/projectTrainingDataSummaryResponse.js +42 -0
  518. package/build/sdk/studio/sdk/model/projectTrainingDataSummaryResponse.js.map +1 -0
  519. package/build/sdk/studio/sdk/model/projectTrainingDataSummaryResponseAllOf.d.ts +26 -0
  520. package/build/sdk/studio/sdk/model/projectTrainingDataSummaryResponseAllOf.js +32 -0
  521. package/build/sdk/studio/sdk/model/projectTrainingDataSummaryResponseAllOf.js.map +1 -0
  522. package/build/sdk/studio/sdk/model/projectType.d.ts +13 -0
  523. package/build/sdk/studio/sdk/model/projectType.js +16 -0
  524. package/build/sdk/studio/sdk/model/projectType.js.map +1 -0
  525. package/build/sdk/studio/sdk/model/runAutoSegmenterRequest.d.ts +27 -0
  526. package/build/sdk/studio/sdk/model/runAutoSegmenterRequest.js +42 -0
  527. package/build/sdk/studio/sdk/model/runAutoSegmenterRequest.js.map +1 -0
  528. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersRequest.d.ts +26 -0
  529. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersRequest.js +32 -0
  530. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersRequest.js.map +1 -0
  531. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersRequestClusters.d.ts +26 -0
  532. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersRequestClusters.js +37 -0
  533. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersRequestClusters.js.map +1 -0
  534. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersResponse.d.ts +33 -0
  535. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersResponse.js +42 -0
  536. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersResponse.js.map +1 -0
  537. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersResponseAllOf.d.ts +25 -0
  538. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersResponseAllOf.js +32 -0
  539. package/build/sdk/studio/sdk/model/saveAutoSegmenterClustersResponseAllOf.js.map +1 -0
  540. package/build/sdk/studio/sdk/model/setKerasParameterRequest.d.ts +10 -0
  541. package/build/sdk/studio/sdk/model/setKerasParameterRequest.js +10 -0
  542. package/build/sdk/studio/sdk/model/setKerasParameterRequest.js.map +1 -1
  543. package/build/sdk/studio/sdk/model/setMemberRoleRequest.d.ts +2 -3
  544. package/build/sdk/studio/sdk/model/setMemberRoleRequest.js +2 -3
  545. package/build/sdk/studio/sdk/model/setMemberRoleRequest.js.map +1 -1
  546. package/build/sdk/studio/sdk/model/startTrainingRequestAnomaly.d.ts +4 -0
  547. package/build/sdk/studio/sdk/model/startTrainingRequestAnomaly.js +5 -0
  548. package/build/sdk/studio/sdk/model/startTrainingRequestAnomaly.js.map +1 -1
  549. package/build/sdk/studio/sdk/model/structuredClassifyResult.d.ts +16 -0
  550. package/build/sdk/studio/sdk/model/structuredClassifyResult.js +20 -0
  551. package/build/sdk/studio/sdk/model/structuredClassifyResult.js.map +1 -1
  552. package/build/sdk/studio/sdk/model/themeLogos.d.ts +1 -0
  553. package/build/sdk/studio/sdk/model/themeLogos.js +5 -0
  554. package/build/sdk/studio/sdk/model/themeLogos.js.map +1 -1
  555. package/build/sdk/studio/sdk/model/timeSeriesDataPoint.d.ts +26 -0
  556. package/build/sdk/studio/sdk/model/timeSeriesDataPoint.js +37 -0
  557. package/build/sdk/studio/sdk/model/timeSeriesDataPoint.js.map +1 -0
  558. package/build/sdk/studio/sdk/model/transferLearningModel.d.ts +2 -0
  559. package/build/sdk/studio/sdk/model/transferLearningModel.js +5 -0
  560. package/build/sdk/studio/sdk/model/transferLearningModel.js.map +1 -1
  561. package/build/sdk/studio/sdk/model/updateOrganizationBucketRequest.d.ts +4 -8
  562. package/build/sdk/studio/sdk/model/updateOrganizationBucketRequest.js +4 -9
  563. package/build/sdk/studio/sdk/model/updateOrganizationBucketRequest.js.map +1 -1
  564. package/build/sdk/studio/sdk/model/updateOrganizationDataCampaignDashboardRequest.d.ts +32 -0
  565. package/build/sdk/studio/sdk/model/updateOrganizationDataCampaignDashboardRequest.js +43 -0
  566. package/build/sdk/studio/sdk/model/updateOrganizationDataCampaignDashboardRequest.js.map +1 -0
  567. package/build/sdk/studio/sdk/model/updateOrganizationDataCampaignRequest.d.ts +39 -0
  568. package/build/sdk/studio/sdk/model/updateOrganizationDataCampaignRequest.js +77 -0
  569. package/build/sdk/studio/sdk/model/updateOrganizationDataCampaignRequest.js.map +1 -0
  570. package/build/sdk/studio/sdk/model/updateOrganizationDatasetRequest.d.ts +3 -0
  571. package/build/sdk/studio/sdk/model/updateOrganizationDatasetRequest.js +10 -0
  572. package/build/sdk/studio/sdk/model/updateOrganizationDatasetRequest.js.map +1 -1
  573. package/build/sdk/studio/sdk/model/updateOrganizationTransferLearningBlockRequest.d.ts +10 -0
  574. package/build/sdk/studio/sdk/model/updateOrganizationTransferLearningBlockRequest.js +15 -0
  575. package/build/sdk/studio/sdk/model/updateOrganizationTransferLearningBlockRequest.js.map +1 -1
  576. package/build/sdk/studio/sdk/model/updateProjectRequest.d.ts +4 -0
  577. package/build/sdk/studio/sdk/model/updateProjectRequest.js +5 -0
  578. package/build/sdk/studio/sdk/model/updateProjectRequest.js.map +1 -1
  579. package/build/sdk/studio/sdk/model/updateThemeLogosRequest.d.ts +4 -0
  580. package/build/sdk/studio/sdk/model/updateThemeLogosRequest.js +5 -0
  581. package/build/sdk/studio/sdk/model/updateThemeLogosRequest.js.map +1 -1
  582. package/build/sdk/studio/sdk/model/updateUserRequest.d.ts +8 -0
  583. package/build/sdk/studio/sdk/model/updateUserRequest.js +10 -0
  584. package/build/sdk/studio/sdk/model/updateUserRequest.js.map +1 -1
  585. package/build/sdk/studio/sdk/model/updateWhitelabelDefaultDeploymentTargetRequest.d.ts +28 -0
  586. package/build/sdk/studio/sdk/model/updateWhitelabelDefaultDeploymentTargetRequest.js +32 -0
  587. package/build/sdk/studio/sdk/model/updateWhitelabelDefaultDeploymentTargetRequest.js.map +1 -0
  588. package/build/sdk/studio/sdk/model/updateWhitelabelDeploymentOptionsOrderRequest.d.ts +28 -0
  589. package/build/sdk/studio/sdk/model/updateWhitelabelDeploymentOptionsOrderRequest.js +32 -0
  590. package/build/sdk/studio/sdk/model/updateWhitelabelDeploymentOptionsOrderRequest.js.map +1 -0
  591. package/build/sdk/studio/sdk/model/updateWhitelabelRequest.d.ts +29 -0
  592. package/build/sdk/studio/sdk/model/updateWhitelabelRequest.js +35 -0
  593. package/build/sdk/studio/sdk/model/updateWhitelabelRequest.js.map +1 -0
  594. package/build/sdk/studio/sdk/model/user.d.ts +11 -0
  595. package/build/sdk/studio/sdk/model/user.js +20 -0
  596. package/build/sdk/studio/sdk/model/user.js.map +1 -1
  597. package/build/sdk/studio/sdk/model/userOrganization.d.ts +8 -0
  598. package/build/sdk/studio/sdk/model/userOrganization.js +10 -0
  599. package/build/sdk/studio/sdk/model/userOrganization.js.map +1 -1
  600. package/build/sdk/studio/sdk/model/whitelabel.d.ts +24 -0
  601. package/build/sdk/studio/sdk/model/whitelabel.js +30 -0
  602. package/build/sdk/studio/sdk/model/whitelabel.js.map +1 -1
  603. package/build/sdk/studio/sdk/model/whitelabelCustomDeploymentBlocks.d.ts +32 -0
  604. package/build/sdk/studio/sdk/model/whitelabelCustomDeploymentBlocks.js +37 -0
  605. package/build/sdk/studio/sdk/model/whitelabelCustomDeploymentBlocks.js.map +1 -0
  606. package/build/shared/bounding-box-file-types.d.ts +5 -3
  607. package/build/shared/bounding-box-file-types.js +7 -3
  608. package/build/shared/bounding-box-file-types.js.map +1 -1
  609. package/build/shared/viewmodels/init.d.ts +3 -0
  610. package/build/shared/viewmodels/init.js +3 -0
  611. package/build/shared/viewmodels/init.js.map +1 -1
  612. package/cli/linux/runner.ts +10 -2
  613. package/cli/linux/webserver/public/index.html +12 -0
  614. package/cli/linux/webserver/public/webserver.js +53 -2
  615. package/package.json +1 -1
@@ -154,235 +154,13 @@ class RequiresSudoApi {
154
154
  });
155
155
  }
156
156
  /**
157
- * Admin-only API to add a user to a project. If no user is provided, the current user is used.
158
- * @summary Add user to a project
159
- * @param projectId Project ID
160
- * @param adminAddProjectUserRequest
161
- */
162
- async adminAddUserToProject(projectId, adminAddProjectUserRequest, options = { headers: {} }) {
163
- const localVarPath = this.basePath + '/api/admin/projects/{projectId}/members'
164
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
165
- let localVarQueryParameters = {};
166
- let localVarHeaderParams = Object.assign({
167
- 'User-Agent': 'edgeimpulse-api nodejs'
168
- }, this.defaultHeaders);
169
- const produces = ['application/json'];
170
- // give precedence to 'application/json'
171
- if (produces.indexOf('application/json') >= 0) {
172
- localVarHeaderParams.Accept = 'application/json';
173
- }
174
- else {
175
- localVarHeaderParams.Accept = produces.join(',');
176
- }
177
- let localVarFormParams = {};
178
- // verify required parameter 'projectId' is not null or undefined
179
- if (projectId === null || projectId === undefined) {
180
- throw new Error('Required parameter projectId was null or undefined when calling adminAddUserToProject.');
181
- }
182
- Object.assign(localVarHeaderParams, options.headers);
183
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
184
- let localVarUseFormData = false;
185
- let localVarRequestOptions = {
186
- method: 'POST',
187
- qs: localVarQueryParameters,
188
- headers: localVarHeaderParams,
189
- uri: localVarPath,
190
- useQuerystring: this._useQuerystring,
191
- agentOptions: { keepAlive: false },
192
- json: true,
193
- body: models_1.ObjectSerializer.serialize(adminAddProjectUserRequest, "AdminAddProjectUserRequest")
194
- };
195
- let authenticationPromise = Promise.resolve();
196
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
197
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
198
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
199
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
200
- return authenticationPromise.then(() => {
201
- if (Object.keys(localVarFormParams).length) {
202
- if (localVarUseFormData) {
203
- localVarRequestOptions.formData = localVarFormParams;
204
- }
205
- else {
206
- localVarRequestOptions.form = localVarFormParams;
207
- }
208
- }
209
- return new Promise((resolve, reject) => {
210
- localVarRequest(localVarRequestOptions, (error, response, body) => {
211
- if (error) {
212
- reject(error);
213
- }
214
- else {
215
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
216
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
217
- if (typeof body.success === 'boolean' && !body.success) {
218
- reject(new Error(body.error || errString));
219
- }
220
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
221
- resolve(body);
222
- }
223
- else {
224
- reject(errString);
225
- }
226
- }
227
- });
228
- });
229
- });
230
- }
231
- /**
232
- * DEPRECATED. Admin-only API to add the current user to a project.
233
- * @summary Add current user to a project
234
- * @param projectId Project ID
235
- */
236
- async adminAddUserToProjectDeprecated(projectId, options = { headers: {} }) {
237
- const localVarPath = this.basePath + '/api/admin/projects/{projectId}/add'
238
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
239
- let localVarQueryParameters = {};
240
- let localVarHeaderParams = Object.assign({
241
- 'User-Agent': 'edgeimpulse-api nodejs'
242
- }, this.defaultHeaders);
243
- const produces = ['application/json'];
244
- // give precedence to 'application/json'
245
- if (produces.indexOf('application/json') >= 0) {
246
- localVarHeaderParams.Accept = 'application/json';
247
- }
248
- else {
249
- localVarHeaderParams.Accept = produces.join(',');
250
- }
251
- let localVarFormParams = {};
252
- // verify required parameter 'projectId' is not null or undefined
253
- if (projectId === null || projectId === undefined) {
254
- throw new Error('Required parameter projectId was null or undefined when calling adminAddUserToProjectDeprecated.');
255
- }
256
- Object.assign(localVarHeaderParams, options.headers);
257
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
258
- let localVarUseFormData = false;
259
- let localVarRequestOptions = {
260
- method: 'POST',
261
- qs: localVarQueryParameters,
262
- headers: localVarHeaderParams,
263
- uri: localVarPath,
264
- useQuerystring: this._useQuerystring,
265
- agentOptions: { keepAlive: false },
266
- json: true,
267
- };
268
- let authenticationPromise = Promise.resolve();
269
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
270
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
271
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
272
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
273
- return authenticationPromise.then(() => {
274
- if (Object.keys(localVarFormParams).length) {
275
- if (localVarUseFormData) {
276
- localVarRequestOptions.formData = localVarFormParams;
277
- }
278
- else {
279
- localVarRequestOptions.form = localVarFormParams;
280
- }
281
- }
282
- return new Promise((resolve, reject) => {
283
- localVarRequest(localVarRequestOptions, (error, response, body) => {
284
- if (error) {
285
- reject(error);
286
- }
287
- else {
288
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
289
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
290
- if (typeof body.success === 'boolean' && !body.success) {
291
- reject(new Error(body.error || errString));
292
- }
293
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
294
- resolve(body);
295
- }
296
- else {
297
- reject(errString);
298
- }
299
- }
300
- });
301
- });
302
- });
303
- }
304
- /**
305
- * Admin-only API to create a new organization.
306
- * @summary Create a new organization
307
- * @param adminCreateOrganizationRequest
308
- */
309
- async adminCreateOrganization(adminCreateOrganizationRequest, options = { headers: {} }) {
310
- const localVarPath = this.basePath + '/api/admin/organizations';
311
- let localVarQueryParameters = {};
312
- let localVarHeaderParams = Object.assign({
313
- 'User-Agent': 'edgeimpulse-api nodejs'
314
- }, this.defaultHeaders);
315
- const produces = ['application/json'];
316
- // give precedence to 'application/json'
317
- if (produces.indexOf('application/json') >= 0) {
318
- localVarHeaderParams.Accept = 'application/json';
319
- }
320
- else {
321
- localVarHeaderParams.Accept = produces.join(',');
322
- }
323
- let localVarFormParams = {};
324
- // verify required parameter 'adminCreateOrganizationRequest' is not null or undefined
325
- if (adminCreateOrganizationRequest === null || adminCreateOrganizationRequest === undefined) {
326
- throw new Error('Required parameter adminCreateOrganizationRequest was null or undefined when calling adminCreateOrganization.');
327
- }
328
- Object.assign(localVarHeaderParams, options.headers);
329
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
330
- let localVarUseFormData = false;
331
- let localVarRequestOptions = {
332
- method: 'POST',
333
- qs: localVarQueryParameters,
334
- headers: localVarHeaderParams,
335
- uri: localVarPath,
336
- useQuerystring: this._useQuerystring,
337
- agentOptions: { keepAlive: false },
338
- json: true,
339
- body: models_1.ObjectSerializer.serialize(adminCreateOrganizationRequest, "AdminCreateOrganizationRequest")
340
- };
341
- let authenticationPromise = Promise.resolve();
342
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
343
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
344
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
345
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
346
- return authenticationPromise.then(() => {
347
- if (Object.keys(localVarFormParams).length) {
348
- if (localVarUseFormData) {
349
- localVarRequestOptions.formData = localVarFormParams;
350
- }
351
- else {
352
- localVarRequestOptions.form = localVarFormParams;
353
- }
354
- }
355
- return new Promise((resolve, reject) => {
356
- localVarRequest(localVarRequestOptions, (error, response, body) => {
357
- if (error) {
358
- reject(error);
359
- }
360
- else {
361
- body = models_1.ObjectSerializer.deserialize(body, "CreateOrganizationResponse");
362
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
363
- if (typeof body.success === 'boolean' && !body.success) {
364
- reject(new Error(body.error || errString));
365
- }
366
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
367
- resolve(body);
368
- }
369
- else {
370
- reject(errString);
371
- }
372
- }
373
- });
374
- });
375
- });
376
- }
377
- /**
378
- * Admin-only API to delete an organization. If `fullDeletion` is set, it deletes the organization\'s identifiable information and files. Otherwise, it soft deletes the organization by setting its `delete_date` value.
379
- * @summary Delete an organization
380
- * @param organizationId Organization ID
381
- * @param fullDeletion Set to true for full deletion
157
+ * Admin-only API to delete the list of identity providers for a given domain.
158
+ * @summary Delete SSO settings for a domain
159
+ * @param domainName Email domain name
382
160
  */
383
- async adminDeleteOrganization(organizationId, queryParams, options = { headers: {} }) {
384
- const localVarPath = this.basePath + '/api/admin/organizations/{organizationId}'
385
- .replace('{' + 'organizationId' + '}', encodeURIComponent(String(organizationId)));
161
+ async adminDeleteSSODomainIdPs(domainName, options = { headers: {} }) {
162
+ const localVarPath = this.basePath + '/api/admin/sso/{domainName}'
163
+ .replace('{' + 'domainName' + '}', encodeURIComponent(String(domainName)));
386
164
  let localVarQueryParameters = {};
387
165
  let localVarHeaderParams = Object.assign({
388
166
  'User-Agent': 'edgeimpulse-api nodejs'
@@ -396,12 +174,9 @@ class RequiresSudoApi {
396
174
  localVarHeaderParams.Accept = produces.join(',');
397
175
  }
398
176
  let localVarFormParams = {};
399
- // verify required parameter 'organizationId' is not null or undefined
400
- if (organizationId === null || organizationId === undefined) {
401
- throw new Error('Required parameter organizationId was null or undefined when calling adminDeleteOrganization.');
402
- }
403
- if (queryParams.fullDeletion !== undefined) {
404
- localVarQueryParameters['fullDeletion'] = models_1.ObjectSerializer.serialize(queryParams.fullDeletion, "boolean");
177
+ // verify required parameter 'domainName' is not null or undefined
178
+ if (domainName === null || domainName === undefined) {
179
+ throw new Error('Required parameter domainName was null or undefined when calling adminDeleteSSODomainIdPs.');
405
180
  }
406
181
  Object.assign(localVarHeaderParams, options.headers);
407
182
  Object.assign(localVarHeaderParams, this.opts.extraHeaders);
@@ -452,13 +227,13 @@ class RequiresSudoApi {
452
227
  });
453
228
  }
454
229
  /**
455
- * Admin-only API to delete a project.
456
- * @summary Delete a project
457
- * @param projectId Project ID
230
+ * Admin-only API to get the list of identity providers enabled for a given domain.
231
+ * @summary Get SSO settings for a domain
232
+ * @param domainName Email domain name
458
233
  */
459
- async adminDeleteProject(projectId, options = { headers: {} }) {
460
- const localVarPath = this.basePath + '/api/admin/projects/{projectId}'
461
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
234
+ async adminGetSSODomainIdPs(domainName, options = { headers: {} }) {
235
+ const localVarPath = this.basePath + '/api/admin/sso/{domainName}'
236
+ .replace('{' + 'domainName' + '}', encodeURIComponent(String(domainName)));
462
237
  let localVarQueryParameters = {};
463
238
  let localVarHeaderParams = Object.assign({
464
239
  'User-Agent': 'edgeimpulse-api nodejs'
@@ -472,15 +247,15 @@ class RequiresSudoApi {
472
247
  localVarHeaderParams.Accept = produces.join(',');
473
248
  }
474
249
  let localVarFormParams = {};
475
- // verify required parameter 'projectId' is not null or undefined
476
- if (projectId === null || projectId === undefined) {
477
- throw new Error('Required parameter projectId was null or undefined when calling adminDeleteProject.');
250
+ // verify required parameter 'domainName' is not null or undefined
251
+ if (domainName === null || domainName === undefined) {
252
+ throw new Error('Required parameter domainName was null or undefined when calling adminGetSSODomainIdPs.');
478
253
  }
479
254
  Object.assign(localVarHeaderParams, options.headers);
480
255
  Object.assign(localVarHeaderParams, this.opts.extraHeaders);
481
256
  let localVarUseFormData = false;
482
257
  let localVarRequestOptions = {
483
- method: 'DELETE',
258
+ method: 'GET',
484
259
  qs: localVarQueryParameters,
485
260
  headers: localVarHeaderParams,
486
261
  uri: localVarPath,
@@ -508,7 +283,7 @@ class RequiresSudoApi {
508
283
  reject(error);
509
284
  }
510
285
  else {
511
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
286
+ body = models_1.ObjectSerializer.deserialize(body, "AdminGetSSODomainIdPsResponse");
512
287
  const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
513
288
  if (typeof body.success === 'boolean' && !body.success) {
514
289
  reject(new Error(body.error || errString));
@@ -525,13 +300,11 @@ class RequiresSudoApi {
525
300
  });
526
301
  }
527
302
  /**
528
- * Admin-only API to delete the list of identity providers for a given domain.
529
- * @summary Delete SSO settings for a domain
530
- * @param domainName Email domain name
303
+ * Admin-only API to get the SSO settings.
304
+ * @summary Get SSO settings
531
305
  */
532
- async adminDeleteSSODomainIdPs(domainName, options = { headers: {} }) {
533
- const localVarPath = this.basePath + '/api/admin/sso/{domainName}'
534
- .replace('{' + 'domainName' + '}', encodeURIComponent(String(domainName)));
306
+ async adminGetSSOSettings(options = { headers: {} }) {
307
+ const localVarPath = this.basePath + '/api/admin/sso';
535
308
  let localVarQueryParameters = {};
536
309
  let localVarHeaderParams = Object.assign({
537
310
  'User-Agent': 'edgeimpulse-api nodejs'
@@ -545,15 +318,11 @@ class RequiresSudoApi {
545
318
  localVarHeaderParams.Accept = produces.join(',');
546
319
  }
547
320
  let localVarFormParams = {};
548
- // verify required parameter 'domainName' is not null or undefined
549
- if (domainName === null || domainName === undefined) {
550
- throw new Error('Required parameter domainName was null or undefined when calling adminDeleteSSODomainIdPs.');
551
- }
552
321
  Object.assign(localVarHeaderParams, options.headers);
553
322
  Object.assign(localVarHeaderParams, this.opts.extraHeaders);
554
323
  let localVarUseFormData = false;
555
324
  let localVarRequestOptions = {
556
- method: 'DELETE',
325
+ method: 'GET',
557
326
  qs: localVarQueryParameters,
558
327
  headers: localVarHeaderParams,
559
328
  uri: localVarPath,
@@ -581,2566 +350,7 @@ class RequiresSudoApi {
581
350
  reject(error);
582
351
  }
583
352
  else {
584
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
585
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
586
- if (typeof body.success === 'boolean' && !body.success) {
587
- reject(new Error(body.error || errString));
588
- }
589
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
590
- resolve(body);
591
- }
592
- else {
593
- reject(errString);
594
- }
595
- }
596
- });
597
- });
598
- });
599
- }
600
- /**
601
- * Admin-only API to delete a user. If `fullDeletion` is set, it deletes the user\'s identifiable information and files. Otherwise, it soft deletes the user by setting it\'s `delete_date` value.
602
- * @summary Delete a user
603
- * @param userId User ID
604
- * @param fullDeletion Set to true for full deletion
605
- */
606
- async adminDeleteUser(userId, queryParams, options = { headers: {} }) {
607
- const localVarPath = this.basePath + '/api/admin/users/{userId}'
608
- .replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
609
- let localVarQueryParameters = {};
610
- let localVarHeaderParams = Object.assign({
611
- 'User-Agent': 'edgeimpulse-api nodejs'
612
- }, this.defaultHeaders);
613
- const produces = ['application/json'];
614
- // give precedence to 'application/json'
615
- if (produces.indexOf('application/json') >= 0) {
616
- localVarHeaderParams.Accept = 'application/json';
617
- }
618
- else {
619
- localVarHeaderParams.Accept = produces.join(',');
620
- }
621
- let localVarFormParams = {};
622
- // verify required parameter 'userId' is not null or undefined
623
- if (userId === null || userId === undefined) {
624
- throw new Error('Required parameter userId was null or undefined when calling adminDeleteUser.');
625
- }
626
- if (queryParams.fullDeletion !== undefined) {
627
- localVarQueryParameters['fullDeletion'] = models_1.ObjectSerializer.serialize(queryParams.fullDeletion, "boolean");
628
- }
629
- Object.assign(localVarHeaderParams, options.headers);
630
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
631
- let localVarUseFormData = false;
632
- let localVarRequestOptions = {
633
- method: 'DELETE',
634
- qs: localVarQueryParameters,
635
- headers: localVarHeaderParams,
636
- uri: localVarPath,
637
- useQuerystring: this._useQuerystring,
638
- agentOptions: { keepAlive: false },
639
- json: true,
640
- };
641
- let authenticationPromise = Promise.resolve();
642
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
643
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
644
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
645
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
646
- return authenticationPromise.then(() => {
647
- if (Object.keys(localVarFormParams).length) {
648
- if (localVarUseFormData) {
649
- localVarRequestOptions.formData = localVarFormParams;
650
- }
651
- else {
652
- localVarRequestOptions.form = localVarFormParams;
653
- }
654
- }
655
- return new Promise((resolve, reject) => {
656
- localVarRequest(localVarRequestOptions, (error, response, body) => {
657
- if (error) {
658
- reject(error);
659
- }
660
- else {
661
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
662
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
663
- if (typeof body.success === 'boolean' && !body.success) {
664
- reject(new Error(body.error || errString));
665
- }
666
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
667
- resolve(body);
668
- }
669
- else {
670
- reject(errString);
671
- }
672
- }
673
- });
674
- });
675
- });
676
- }
677
- /**
678
- * DEPRECATED. Admin-only API to find a user by username or email address.
679
- * @summary Find a user
680
- * @param query Part of e-mail address or username
681
- */
682
- async adminFindUser(queryParams, options = { headers: {} }) {
683
- const localVarPath = this.basePath + '/api/admin/find-user';
684
- let localVarQueryParameters = {};
685
- let localVarHeaderParams = Object.assign({
686
- 'User-Agent': 'edgeimpulse-api nodejs'
687
- }, this.defaultHeaders);
688
- const produces = ['application/json'];
689
- // give precedence to 'application/json'
690
- if (produces.indexOf('application/json') >= 0) {
691
- localVarHeaderParams.Accept = 'application/json';
692
- }
693
- else {
694
- localVarHeaderParams.Accept = produces.join(',');
695
- }
696
- let localVarFormParams = {};
697
- // verify required parameter 'query' is not null or undefined
698
- if (queryParams.query === null || queryParams.query === undefined) {
699
- throw new Error('Required parameter queryParams.query was null or undefined when calling adminFindUser.');
700
- }
701
- if (queryParams.query !== undefined) {
702
- localVarQueryParameters['query'] = models_1.ObjectSerializer.serialize(queryParams.query, "string");
703
- }
704
- Object.assign(localVarHeaderParams, options.headers);
705
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
706
- let localVarUseFormData = false;
707
- let localVarRequestOptions = {
708
- method: 'GET',
709
- qs: localVarQueryParameters,
710
- headers: localVarHeaderParams,
711
- uri: localVarPath,
712
- useQuerystring: this._useQuerystring,
713
- agentOptions: { keepAlive: false },
714
- json: true,
715
- };
716
- let authenticationPromise = Promise.resolve();
717
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
718
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
719
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
720
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
721
- return authenticationPromise.then(() => {
722
- if (Object.keys(localVarFormParams).length) {
723
- if (localVarUseFormData) {
724
- localVarRequestOptions.formData = localVarFormParams;
725
- }
726
- else {
727
- localVarRequestOptions.form = localVarFormParams;
728
- }
729
- }
730
- return new Promise((resolve, reject) => {
731
- localVarRequest(localVarRequestOptions, (error, response, body) => {
732
- if (error) {
733
- reject(error);
734
- }
735
- else {
736
- body = models_1.ObjectSerializer.deserialize(body, "FindUserResponse");
737
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
738
- if (typeof body.success === 'boolean' && !body.success) {
739
- reject(new Error(body.error || errString));
740
- }
741
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
742
- resolve(body);
743
- }
744
- else {
745
- reject(errString);
746
- }
747
- }
748
- });
749
- });
750
- });
751
- }
752
- /**
753
- * DEPRECATED. Admin-only API to get list of all users that have been active in the past 30 days.
754
- * @summary Get all user IDs (active last 30 days)
755
- */
756
- async adminGetAllActiveUserIds(options = { headers: {} }) {
757
- const localVarPath = this.basePath + '/api/admin/users-ids/active';
758
- let localVarQueryParameters = {};
759
- let localVarHeaderParams = Object.assign({
760
- 'User-Agent': 'edgeimpulse-api nodejs'
761
- }, this.defaultHeaders);
762
- const produces = ['application/json'];
763
- // give precedence to 'application/json'
764
- if (produces.indexOf('application/json') >= 0) {
765
- localVarHeaderParams.Accept = 'application/json';
766
- }
767
- else {
768
- localVarHeaderParams.Accept = produces.join(',');
769
- }
770
- let localVarFormParams = {};
771
- Object.assign(localVarHeaderParams, options.headers);
772
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
773
- let localVarUseFormData = false;
774
- let localVarRequestOptions = {
775
- method: 'GET',
776
- qs: localVarQueryParameters,
777
- headers: localVarHeaderParams,
778
- uri: localVarPath,
779
- useQuerystring: this._useQuerystring,
780
- agentOptions: { keepAlive: false },
781
- json: true,
782
- };
783
- let authenticationPromise = Promise.resolve();
784
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
785
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
786
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
787
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
788
- return authenticationPromise.then(() => {
789
- if (Object.keys(localVarFormParams).length) {
790
- if (localVarUseFormData) {
791
- localVarRequestOptions.formData = localVarFormParams;
792
- }
793
- else {
794
- localVarRequestOptions.form = localVarFormParams;
795
- }
796
- }
797
- return new Promise((resolve, reject) => {
798
- localVarRequest(localVarRequestOptions, (error, response, body) => {
799
- if (error) {
800
- reject(error);
801
- }
802
- else {
803
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetUserIdsResponse");
804
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
805
- if (typeof body.success === 'boolean' && !body.success) {
806
- reject(new Error(body.error || errString));
807
- }
808
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
809
- resolve(body);
810
- }
811
- else {
812
- reject(errString);
813
- }
814
- }
815
- });
816
- });
817
- });
818
- }
819
- /**
820
- * DEPRECATED. Admin-only API to get list of all users.
821
- * @summary Get all user IDs
822
- */
823
- async adminGetAllUserIds(options = { headers: {} }) {
824
- const localVarPath = this.basePath + '/api/admin/users-ids';
825
- let localVarQueryParameters = {};
826
- let localVarHeaderParams = Object.assign({
827
- 'User-Agent': 'edgeimpulse-api nodejs'
828
- }, this.defaultHeaders);
829
- const produces = ['application/json'];
830
- // give precedence to 'application/json'
831
- if (produces.indexOf('application/json') >= 0) {
832
- localVarHeaderParams.Accept = 'application/json';
833
- }
834
- else {
835
- localVarHeaderParams.Accept = produces.join(',');
836
- }
837
- let localVarFormParams = {};
838
- Object.assign(localVarHeaderParams, options.headers);
839
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
840
- let localVarUseFormData = false;
841
- let localVarRequestOptions = {
842
- method: 'GET',
843
- qs: localVarQueryParameters,
844
- headers: localVarHeaderParams,
845
- uri: localVarPath,
846
- useQuerystring: this._useQuerystring,
847
- agentOptions: { keepAlive: false },
848
- json: true,
849
- };
850
- let authenticationPromise = Promise.resolve();
851
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
852
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
853
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
854
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
855
- return authenticationPromise.then(() => {
856
- if (Object.keys(localVarFormParams).length) {
857
- if (localVarUseFormData) {
858
- localVarRequestOptions.formData = localVarFormParams;
859
- }
860
- else {
861
- localVarRequestOptions.form = localVarFormParams;
862
- }
863
- }
864
- return new Promise((resolve, reject) => {
865
- localVarRequest(localVarRequestOptions, (error, response, body) => {
866
- if (error) {
867
- reject(error);
868
- }
869
- else {
870
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetUserIdsResponse");
871
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
872
- if (typeof body.success === 'boolean' && !body.success) {
873
- reject(new Error(body.error || errString));
874
- }
875
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
876
- resolve(body);
877
- }
878
- else {
879
- reject(errString);
880
- }
881
- }
882
- });
883
- });
884
- });
885
- }
886
- /**
887
- * Admin-only API to get global metrics.
888
- * @summary Get global metrics
889
- */
890
- async adminGetMetrics(options = { headers: {} }) {
891
- const localVarPath = this.basePath + '/api/admin/metrics';
892
- let localVarQueryParameters = {};
893
- let localVarHeaderParams = Object.assign({
894
- 'User-Agent': 'edgeimpulse-api nodejs'
895
- }, this.defaultHeaders);
896
- const produces = ['application/json'];
897
- // give precedence to 'application/json'
898
- if (produces.indexOf('application/json') >= 0) {
899
- localVarHeaderParams.Accept = 'application/json';
900
- }
901
- else {
902
- localVarHeaderParams.Accept = produces.join(',');
903
- }
904
- let localVarFormParams = {};
905
- Object.assign(localVarHeaderParams, options.headers);
906
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
907
- let localVarUseFormData = false;
908
- let localVarRequestOptions = {
909
- method: 'GET',
910
- qs: localVarQueryParameters,
911
- headers: localVarHeaderParams,
912
- uri: localVarPath,
913
- useQuerystring: this._useQuerystring,
914
- agentOptions: { keepAlive: false },
915
- json: true,
916
- };
917
- let authenticationPromise = Promise.resolve();
918
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
919
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
920
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
921
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
922
- return authenticationPromise.then(() => {
923
- if (Object.keys(localVarFormParams).length) {
924
- if (localVarUseFormData) {
925
- localVarRequestOptions.formData = localVarFormParams;
926
- }
927
- else {
928
- localVarRequestOptions.form = localVarFormParams;
929
- }
930
- }
931
- return new Promise((resolve, reject) => {
932
- localVarRequest(localVarRequestOptions, (error, response, body) => {
933
- if (error) {
934
- reject(error);
935
- }
936
- else {
937
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetMetricsResponse");
938
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
939
- if (typeof body.success === 'boolean' && !body.success) {
940
- reject(new Error(body.error || errString));
941
- }
942
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
943
- resolve(body);
944
- }
945
- else {
946
- reject(errString);
947
- }
948
- }
949
- });
950
- });
951
- });
952
- }
953
- /**
954
- * Admin-only API to list all information about this organization.
955
- * @summary Organization information
956
- * @param organizationId Organization ID
957
- */
958
- async adminGetOrganizationInfo(organizationId, options = { headers: {} }) {
959
- const localVarPath = this.basePath + '/api/admin/organizations/{organizationId}'
960
- .replace('{' + 'organizationId' + '}', encodeURIComponent(String(organizationId)));
961
- let localVarQueryParameters = {};
962
- let localVarHeaderParams = Object.assign({
963
- 'User-Agent': 'edgeimpulse-api nodejs'
964
- }, this.defaultHeaders);
965
- const produces = ['application/json'];
966
- // give precedence to 'application/json'
967
- if (produces.indexOf('application/json') >= 0) {
968
- localVarHeaderParams.Accept = 'application/json';
969
- }
970
- else {
971
- localVarHeaderParams.Accept = produces.join(',');
972
- }
973
- let localVarFormParams = {};
974
- // verify required parameter 'organizationId' is not null or undefined
975
- if (organizationId === null || organizationId === undefined) {
976
- throw new Error('Required parameter organizationId was null or undefined when calling adminGetOrganizationInfo.');
977
- }
978
- Object.assign(localVarHeaderParams, options.headers);
979
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
980
- let localVarUseFormData = false;
981
- let localVarRequestOptions = {
982
- method: 'GET',
983
- qs: localVarQueryParameters,
984
- headers: localVarHeaderParams,
985
- uri: localVarPath,
986
- useQuerystring: this._useQuerystring,
987
- agentOptions: { keepAlive: false },
988
- json: true,
989
- };
990
- let authenticationPromise = Promise.resolve();
991
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
992
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
993
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
994
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
995
- return authenticationPromise.then(() => {
996
- if (Object.keys(localVarFormParams).length) {
997
- if (localVarUseFormData) {
998
- localVarRequestOptions.formData = localVarFormParams;
999
- }
1000
- else {
1001
- localVarRequestOptions.form = localVarFormParams;
1002
- }
1003
- }
1004
- return new Promise((resolve, reject) => {
1005
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1006
- if (error) {
1007
- reject(error);
1008
- }
1009
- else {
1010
- body = models_1.ObjectSerializer.deserialize(body, "AdminOrganizationInfoResponse");
1011
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1012
- if (typeof body.success === 'boolean' && !body.success) {
1013
- reject(new Error(body.error || errString));
1014
- }
1015
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1016
- resolve(body);
1017
- }
1018
- else {
1019
- reject(errString);
1020
- }
1021
- }
1022
- });
1023
- });
1024
- });
1025
- }
1026
- /**
1027
- * Admin-only API to get the list of all organizations.
1028
- * @summary Get all organizations
1029
- * @param active Whether to search for entities (users, orgs) active in the last X days
1030
- * @param sort Fields and order to sort query by
1031
- * @param limit Maximum number of results
1032
- * @param offset Offset in results, can be used in conjunction with LimitResultsParameter to implement paging.
1033
- * @param search Search query
1034
- */
1035
- async adminGetOrganizations(queryParams, options = { headers: {} }) {
1036
- const localVarPath = this.basePath + '/api/admin/organizations';
1037
- let localVarQueryParameters = {};
1038
- let localVarHeaderParams = Object.assign({
1039
- 'User-Agent': 'edgeimpulse-api nodejs'
1040
- }, this.defaultHeaders);
1041
- const produces = ['application/json'];
1042
- // give precedence to 'application/json'
1043
- if (produces.indexOf('application/json') >= 0) {
1044
- localVarHeaderParams.Accept = 'application/json';
1045
- }
1046
- else {
1047
- localVarHeaderParams.Accept = produces.join(',');
1048
- }
1049
- let localVarFormParams = {};
1050
- if (queryParams.active !== undefined) {
1051
- localVarQueryParameters['active'] = models_1.ObjectSerializer.serialize(queryParams.active, "number");
1052
- }
1053
- if (queryParams.sort !== undefined) {
1054
- localVarQueryParameters['sort'] = models_1.ObjectSerializer.serialize(queryParams.sort, "string");
1055
- }
1056
- if (queryParams.limit !== undefined) {
1057
- localVarQueryParameters['limit'] = models_1.ObjectSerializer.serialize(queryParams.limit, "number");
1058
- }
1059
- if (queryParams.offset !== undefined) {
1060
- localVarQueryParameters['offset'] = models_1.ObjectSerializer.serialize(queryParams.offset, "number");
1061
- }
1062
- if (queryParams.search !== undefined) {
1063
- localVarQueryParameters['search'] = models_1.ObjectSerializer.serialize(queryParams.search, "string");
1064
- }
1065
- Object.assign(localVarHeaderParams, options.headers);
1066
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1067
- let localVarUseFormData = false;
1068
- let localVarRequestOptions = {
1069
- method: 'GET',
1070
- qs: localVarQueryParameters,
1071
- headers: localVarHeaderParams,
1072
- uri: localVarPath,
1073
- useQuerystring: this._useQuerystring,
1074
- agentOptions: { keepAlive: false },
1075
- json: true,
1076
- };
1077
- let authenticationPromise = Promise.resolve();
1078
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1079
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1080
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1081
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1082
- return authenticationPromise.then(() => {
1083
- if (Object.keys(localVarFormParams).length) {
1084
- if (localVarUseFormData) {
1085
- localVarRequestOptions.formData = localVarFormParams;
1086
- }
1087
- else {
1088
- localVarRequestOptions.form = localVarFormParams;
1089
- }
1090
- }
1091
- return new Promise((resolve, reject) => {
1092
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1093
- if (error) {
1094
- reject(error);
1095
- }
1096
- else {
1097
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetOrganizationsResponse");
1098
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1099
- if (typeof body.success === 'boolean' && !body.success) {
1100
- reject(new Error(body.error || errString));
1101
- }
1102
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1103
- resolve(body);
1104
- }
1105
- else {
1106
- reject(errString);
1107
- }
1108
- }
1109
- });
1110
- });
1111
- });
1112
- }
1113
- /**
1114
- * Admin-only API to get project information.
1115
- * @summary Get project
1116
- * @param projectId Project ID
1117
- */
1118
- async adminGetProject(projectId, options = { headers: {} }) {
1119
- const localVarPath = this.basePath + '/api/admin/projects/{projectId}'
1120
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
1121
- let localVarQueryParameters = {};
1122
- let localVarHeaderParams = Object.assign({
1123
- 'User-Agent': 'edgeimpulse-api nodejs'
1124
- }, this.defaultHeaders);
1125
- const produces = ['application/json'];
1126
- // give precedence to 'application/json'
1127
- if (produces.indexOf('application/json') >= 0) {
1128
- localVarHeaderParams.Accept = 'application/json';
1129
- }
1130
- else {
1131
- localVarHeaderParams.Accept = produces.join(',');
1132
- }
1133
- let localVarFormParams = {};
1134
- // verify required parameter 'projectId' is not null or undefined
1135
- if (projectId === null || projectId === undefined) {
1136
- throw new Error('Required parameter projectId was null or undefined when calling adminGetProject.');
1137
- }
1138
- Object.assign(localVarHeaderParams, options.headers);
1139
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1140
- let localVarUseFormData = false;
1141
- let localVarRequestOptions = {
1142
- method: 'GET',
1143
- qs: localVarQueryParameters,
1144
- headers: localVarHeaderParams,
1145
- uri: localVarPath,
1146
- useQuerystring: this._useQuerystring,
1147
- agentOptions: { keepAlive: false },
1148
- json: true,
1149
- };
1150
- let authenticationPromise = Promise.resolve();
1151
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1152
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1153
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1154
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1155
- return authenticationPromise.then(() => {
1156
- if (Object.keys(localVarFormParams).length) {
1157
- if (localVarUseFormData) {
1158
- localVarRequestOptions.formData = localVarFormParams;
1159
- }
1160
- else {
1161
- localVarRequestOptions.form = localVarFormParams;
1162
- }
1163
- }
1164
- return new Promise((resolve, reject) => {
1165
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1166
- if (error) {
1167
- reject(error);
1168
- }
1169
- else {
1170
- body = models_1.ObjectSerializer.deserialize(body, "ProjectInfoResponse");
1171
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1172
- if (typeof body.success === 'boolean' && !body.success) {
1173
- reject(new Error(body.error || errString));
1174
- }
1175
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1176
- resolve(body);
1177
- }
1178
- else {
1179
- reject(errString);
1180
- }
1181
- }
1182
- });
1183
- });
1184
- });
1185
- }
1186
- /**
1187
- * Admin-only API to get the list of all projects.
1188
- * @summary Get all projects
1189
- * @param active Whether to search for entities (users, orgs) active in the last X days
1190
- * @param sort Fields and order to sort query by
1191
- * @param limit Maximum number of results
1192
- * @param offset Offset in results, can be used in conjunction with LimitResultsParameter to implement paging.
1193
- * @param search Search query
1194
- */
1195
- async adminGetProjects(queryParams, options = { headers: {} }) {
1196
- const localVarPath = this.basePath + '/api/admin/projects';
1197
- let localVarQueryParameters = {};
1198
- let localVarHeaderParams = Object.assign({
1199
- 'User-Agent': 'edgeimpulse-api nodejs'
1200
- }, this.defaultHeaders);
1201
- const produces = ['application/json'];
1202
- // give precedence to 'application/json'
1203
- if (produces.indexOf('application/json') >= 0) {
1204
- localVarHeaderParams.Accept = 'application/json';
1205
- }
1206
- else {
1207
- localVarHeaderParams.Accept = produces.join(',');
1208
- }
1209
- let localVarFormParams = {};
1210
- if (queryParams.active !== undefined) {
1211
- localVarQueryParameters['active'] = models_1.ObjectSerializer.serialize(queryParams.active, "number");
1212
- }
1213
- if (queryParams.sort !== undefined) {
1214
- localVarQueryParameters['sort'] = models_1.ObjectSerializer.serialize(queryParams.sort, "string");
1215
- }
1216
- if (queryParams.limit !== undefined) {
1217
- localVarQueryParameters['limit'] = models_1.ObjectSerializer.serialize(queryParams.limit, "number");
1218
- }
1219
- if (queryParams.offset !== undefined) {
1220
- localVarQueryParameters['offset'] = models_1.ObjectSerializer.serialize(queryParams.offset, "number");
1221
- }
1222
- if (queryParams.search !== undefined) {
1223
- localVarQueryParameters['search'] = models_1.ObjectSerializer.serialize(queryParams.search, "string");
1224
- }
1225
- Object.assign(localVarHeaderParams, options.headers);
1226
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1227
- let localVarUseFormData = false;
1228
- let localVarRequestOptions = {
1229
- method: 'GET',
1230
- qs: localVarQueryParameters,
1231
- headers: localVarHeaderParams,
1232
- uri: localVarPath,
1233
- useQuerystring: this._useQuerystring,
1234
- agentOptions: { keepAlive: false },
1235
- json: true,
1236
- };
1237
- let authenticationPromise = Promise.resolve();
1238
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1239
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1240
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1241
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1242
- return authenticationPromise.then(() => {
1243
- if (Object.keys(localVarFormParams).length) {
1244
- if (localVarUseFormData) {
1245
- localVarRequestOptions.formData = localVarFormParams;
1246
- }
1247
- else {
1248
- localVarRequestOptions.form = localVarFormParams;
1249
- }
1250
- }
1251
- return new Promise((resolve, reject) => {
1252
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1253
- if (error) {
1254
- reject(error);
1255
- }
1256
- else {
1257
- body = models_1.ObjectSerializer.deserialize(body, "AdminListProjectsResponse");
1258
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1259
- if (typeof body.success === 'boolean' && !body.success) {
1260
- reject(new Error(body.error || errString));
1261
- }
1262
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1263
- resolve(body);
1264
- }
1265
- else {
1266
- reject(errString);
1267
- }
1268
- }
1269
- });
1270
- });
1271
- });
1272
- }
1273
- /**
1274
- * Admin-only API to get the list of identity providers enabled for a given domain.
1275
- * @summary Get SSO settings for a domain
1276
- * @param domainName Email domain name
1277
- */
1278
- async adminGetSSODomainIdPs(domainName, options = { headers: {} }) {
1279
- const localVarPath = this.basePath + '/api/admin/sso/{domainName}'
1280
- .replace('{' + 'domainName' + '}', encodeURIComponent(String(domainName)));
1281
- let localVarQueryParameters = {};
1282
- let localVarHeaderParams = Object.assign({
1283
- 'User-Agent': 'edgeimpulse-api nodejs'
1284
- }, this.defaultHeaders);
1285
- const produces = ['application/json'];
1286
- // give precedence to 'application/json'
1287
- if (produces.indexOf('application/json') >= 0) {
1288
- localVarHeaderParams.Accept = 'application/json';
1289
- }
1290
- else {
1291
- localVarHeaderParams.Accept = produces.join(',');
1292
- }
1293
- let localVarFormParams = {};
1294
- // verify required parameter 'domainName' is not null or undefined
1295
- if (domainName === null || domainName === undefined) {
1296
- throw new Error('Required parameter domainName was null or undefined when calling adminGetSSODomainIdPs.');
1297
- }
1298
- Object.assign(localVarHeaderParams, options.headers);
1299
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1300
- let localVarUseFormData = false;
1301
- let localVarRequestOptions = {
1302
- method: 'GET',
1303
- qs: localVarQueryParameters,
1304
- headers: localVarHeaderParams,
1305
- uri: localVarPath,
1306
- useQuerystring: this._useQuerystring,
1307
- agentOptions: { keepAlive: false },
1308
- json: true,
1309
- };
1310
- let authenticationPromise = Promise.resolve();
1311
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1312
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1313
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1314
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1315
- return authenticationPromise.then(() => {
1316
- if (Object.keys(localVarFormParams).length) {
1317
- if (localVarUseFormData) {
1318
- localVarRequestOptions.formData = localVarFormParams;
1319
- }
1320
- else {
1321
- localVarRequestOptions.form = localVarFormParams;
1322
- }
1323
- }
1324
- return new Promise((resolve, reject) => {
1325
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1326
- if (error) {
1327
- reject(error);
1328
- }
1329
- else {
1330
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetSSODomainIdPsResponse");
1331
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1332
- if (typeof body.success === 'boolean' && !body.success) {
1333
- reject(new Error(body.error || errString));
1334
- }
1335
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1336
- resolve(body);
1337
- }
1338
- else {
1339
- reject(errString);
1340
- }
1341
- }
1342
- });
1343
- });
1344
- });
1345
- }
1346
- /**
1347
- * Admin-only API to get the SSO settings.
1348
- * @summary Get SSO settings
1349
- */
1350
- async adminGetSSOSettings(options = { headers: {} }) {
1351
- const localVarPath = this.basePath + '/api/admin/sso';
1352
- let localVarQueryParameters = {};
1353
- let localVarHeaderParams = Object.assign({
1354
- 'User-Agent': 'edgeimpulse-api nodejs'
1355
- }, this.defaultHeaders);
1356
- const produces = ['application/json'];
1357
- // give precedence to 'application/json'
1358
- if (produces.indexOf('application/json') >= 0) {
1359
- localVarHeaderParams.Accept = 'application/json';
1360
- }
1361
- else {
1362
- localVarHeaderParams.Accept = produces.join(',');
1363
- }
1364
- let localVarFormParams = {};
1365
- Object.assign(localVarHeaderParams, options.headers);
1366
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1367
- let localVarUseFormData = false;
1368
- let localVarRequestOptions = {
1369
- method: 'GET',
1370
- qs: localVarQueryParameters,
1371
- headers: localVarHeaderParams,
1372
- uri: localVarPath,
1373
- useQuerystring: this._useQuerystring,
1374
- agentOptions: { keepAlive: false },
1375
- json: true,
1376
- };
1377
- let authenticationPromise = Promise.resolve();
1378
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1379
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1380
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1381
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1382
- return authenticationPromise.then(() => {
1383
- if (Object.keys(localVarFormParams).length) {
1384
- if (localVarUseFormData) {
1385
- localVarRequestOptions.formData = localVarFormParams;
1386
- }
1387
- else {
1388
- localVarRequestOptions.form = localVarFormParams;
1389
- }
1390
- }
1391
- return new Promise((resolve, reject) => {
1392
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1393
- if (error) {
1394
- reject(error);
1395
- }
1396
- else {
1397
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetSSOSettingsResponse");
1398
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1399
- if (typeof body.success === 'boolean' && !body.success) {
1400
- reject(new Error(body.error || errString));
1401
- }
1402
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1403
- resolve(body);
1404
- }
1405
- else {
1406
- reject(errString);
1407
- }
1408
- }
1409
- });
1410
- });
1411
- });
1412
- }
1413
- /**
1414
- * Admin-only API to get information about a user.
1415
- * @summary Get user
1416
- * @param userId User ID
1417
- */
1418
- async adminGetUser(userId, options = { headers: {} }) {
1419
- const localVarPath = this.basePath + '/api/admin/users/{userId}'
1420
- .replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
1421
- let localVarQueryParameters = {};
1422
- let localVarHeaderParams = Object.assign({
1423
- 'User-Agent': 'edgeimpulse-api nodejs'
1424
- }, this.defaultHeaders);
1425
- const produces = ['application/json'];
1426
- // give precedence to 'application/json'
1427
- if (produces.indexOf('application/json') >= 0) {
1428
- localVarHeaderParams.Accept = 'application/json';
1429
- }
1430
- else {
1431
- localVarHeaderParams.Accept = produces.join(',');
1432
- }
1433
- let localVarFormParams = {};
1434
- // verify required parameter 'userId' is not null or undefined
1435
- if (userId === null || userId === undefined) {
1436
- throw new Error('Required parameter userId was null or undefined when calling adminGetUser.');
1437
- }
1438
- Object.assign(localVarHeaderParams, options.headers);
1439
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1440
- let localVarUseFormData = false;
1441
- let localVarRequestOptions = {
1442
- method: 'GET',
1443
- qs: localVarQueryParameters,
1444
- headers: localVarHeaderParams,
1445
- uri: localVarPath,
1446
- useQuerystring: this._useQuerystring,
1447
- agentOptions: { keepAlive: false },
1448
- json: true,
1449
- };
1450
- let authenticationPromise = Promise.resolve();
1451
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1452
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1453
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1454
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1455
- return authenticationPromise.then(() => {
1456
- if (Object.keys(localVarFormParams).length) {
1457
- if (localVarUseFormData) {
1458
- localVarRequestOptions.formData = localVarFormParams;
1459
- }
1460
- else {
1461
- localVarRequestOptions.form = localVarFormParams;
1462
- }
1463
- }
1464
- return new Promise((resolve, reject) => {
1465
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1466
- if (error) {
1467
- reject(error);
1468
- }
1469
- else {
1470
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetUserResponse");
1471
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1472
- if (typeof body.success === 'boolean' && !body.success) {
1473
- reject(new Error(body.error || errString));
1474
- }
1475
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1476
- resolve(body);
1477
- }
1478
- else {
1479
- reject(errString);
1480
- }
1481
- }
1482
- });
1483
- });
1484
- });
1485
- }
1486
- /**
1487
- * Admin-only API to get marketing metrics about a user.
1488
- * @summary Get user metrics
1489
- * @param userId User ID
1490
- */
1491
- async adminGetUserMetrics(userId, options = { headers: {} }) {
1492
- const localVarPath = this.basePath + '/api/admin/users/{userId}/metrics'
1493
- .replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
1494
- let localVarQueryParameters = {};
1495
- let localVarHeaderParams = Object.assign({
1496
- 'User-Agent': 'edgeimpulse-api nodejs'
1497
- }, this.defaultHeaders);
1498
- const produces = ['application/json'];
1499
- // give precedence to 'application/json'
1500
- if (produces.indexOf('application/json') >= 0) {
1501
- localVarHeaderParams.Accept = 'application/json';
1502
- }
1503
- else {
1504
- localVarHeaderParams.Accept = produces.join(',');
1505
- }
1506
- let localVarFormParams = {};
1507
- // verify required parameter 'userId' is not null or undefined
1508
- if (userId === null || userId === undefined) {
1509
- throw new Error('Required parameter userId was null or undefined when calling adminGetUserMetrics.');
1510
- }
1511
- Object.assign(localVarHeaderParams, options.headers);
1512
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1513
- let localVarUseFormData = false;
1514
- let localVarRequestOptions = {
1515
- method: 'GET',
1516
- qs: localVarQueryParameters,
1517
- headers: localVarHeaderParams,
1518
- uri: localVarPath,
1519
- useQuerystring: this._useQuerystring,
1520
- agentOptions: { keepAlive: false },
1521
- json: true,
1522
- };
1523
- let authenticationPromise = Promise.resolve();
1524
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1525
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1526
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1527
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1528
- return authenticationPromise.then(() => {
1529
- if (Object.keys(localVarFormParams).length) {
1530
- if (localVarUseFormData) {
1531
- localVarRequestOptions.formData = localVarFormParams;
1532
- }
1533
- else {
1534
- localVarRequestOptions.form = localVarFormParams;
1535
- }
1536
- }
1537
- return new Promise((resolve, reject) => {
1538
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1539
- if (error) {
1540
- reject(error);
1541
- }
1542
- else {
1543
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetUserMetricsResponse");
1544
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1545
- if (typeof body.success === 'boolean' && !body.success) {
1546
- reject(new Error(body.error || errString));
1547
- }
1548
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1549
- resolve(body);
1550
- }
1551
- else {
1552
- reject(errString);
1553
- }
1554
- }
1555
- });
1556
- });
1557
- });
1558
- }
1559
- /**
1560
- * Admin-only API to get the list of all registered users.
1561
- * @summary Get all users
1562
- * @param active Whether to search for entities (users, orgs) active in the last X days
1563
- * @param tier Whether to search for free, pro or enterprise entities (users, projects)
1564
- * @param fields Comma separated list of fields to fetch in a query
1565
- * @param sort Fields and order to sort query by
1566
- * @param limit Maximum number of results
1567
- * @param offset Offset in results, can be used in conjunction with LimitResultsParameter to implement paging.
1568
- * @param search Search query
1569
- */
1570
- async adminGetUsers(queryParams, options = { headers: {} }) {
1571
- const localVarPath = this.basePath + '/api/admin/users';
1572
- let localVarQueryParameters = {};
1573
- let localVarHeaderParams = Object.assign({
1574
- 'User-Agent': 'edgeimpulse-api nodejs'
1575
- }, this.defaultHeaders);
1576
- const produces = ['application/json'];
1577
- // give precedence to 'application/json'
1578
- if (produces.indexOf('application/json') >= 0) {
1579
- localVarHeaderParams.Accept = 'application/json';
1580
- }
1581
- else {
1582
- localVarHeaderParams.Accept = produces.join(',');
1583
- }
1584
- let localVarFormParams = {};
1585
- if (queryParams.active !== undefined) {
1586
- localVarQueryParameters['active'] = models_1.ObjectSerializer.serialize(queryParams.active, "number");
1587
- }
1588
- if (queryParams.tier !== undefined) {
1589
- localVarQueryParameters['tier'] = models_1.ObjectSerializer.serialize(queryParams.tier, "'free' | 'pro' | 'enterprise'");
1590
- }
1591
- if (queryParams.fields !== undefined) {
1592
- localVarQueryParameters['fields'] = models_1.ObjectSerializer.serialize(queryParams.fields, "string");
1593
- }
1594
- if (queryParams.sort !== undefined) {
1595
- localVarQueryParameters['sort'] = models_1.ObjectSerializer.serialize(queryParams.sort, "string");
1596
- }
1597
- if (queryParams.limit !== undefined) {
1598
- localVarQueryParameters['limit'] = models_1.ObjectSerializer.serialize(queryParams.limit, "number");
1599
- }
1600
- if (queryParams.offset !== undefined) {
1601
- localVarQueryParameters['offset'] = models_1.ObjectSerializer.serialize(queryParams.offset, "number");
1602
- }
1603
- if (queryParams.search !== undefined) {
1604
- localVarQueryParameters['search'] = models_1.ObjectSerializer.serialize(queryParams.search, "string");
1605
- }
1606
- Object.assign(localVarHeaderParams, options.headers);
1607
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1608
- let localVarUseFormData = false;
1609
- let localVarRequestOptions = {
1610
- method: 'GET',
1611
- qs: localVarQueryParameters,
1612
- headers: localVarHeaderParams,
1613
- uri: localVarPath,
1614
- useQuerystring: this._useQuerystring,
1615
- agentOptions: { keepAlive: false },
1616
- json: true,
1617
- };
1618
- let authenticationPromise = Promise.resolve();
1619
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1620
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1621
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1622
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1623
- return authenticationPromise.then(() => {
1624
- if (Object.keys(localVarFormParams).length) {
1625
- if (localVarUseFormData) {
1626
- localVarRequestOptions.formData = localVarFormParams;
1627
- }
1628
- else {
1629
- localVarRequestOptions.form = localVarFormParams;
1630
- }
1631
- }
1632
- return new Promise((resolve, reject) => {
1633
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1634
- if (error) {
1635
- reject(error);
1636
- }
1637
- else {
1638
- body = models_1.ObjectSerializer.deserialize(body, "AdminGetUsersResponse");
1639
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1640
- if (typeof body.success === 'boolean' && !body.success) {
1641
- reject(new Error(body.error || errString));
1642
- }
1643
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1644
- resolve(body);
1645
- }
1646
- else {
1647
- reject(errString);
1648
- }
1649
- }
1650
- });
1651
- });
1652
- });
1653
- }
1654
- /**
1655
- * Admin-only API to remove a user from a project.
1656
- * @summary Remove user from a project
1657
- * @param projectId Project ID
1658
- * @param userId User ID
1659
- */
1660
- async adminRemoveUserFromProject(projectId, userId, options = { headers: {} }) {
1661
- const localVarPath = this.basePath + '/api/admin/projects/{projectId}/members/{userId}'
1662
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)))
1663
- .replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
1664
- let localVarQueryParameters = {};
1665
- let localVarHeaderParams = Object.assign({
1666
- 'User-Agent': 'edgeimpulse-api nodejs'
1667
- }, this.defaultHeaders);
1668
- const produces = ['application/json'];
1669
- // give precedence to 'application/json'
1670
- if (produces.indexOf('application/json') >= 0) {
1671
- localVarHeaderParams.Accept = 'application/json';
1672
- }
1673
- else {
1674
- localVarHeaderParams.Accept = produces.join(',');
1675
- }
1676
- let localVarFormParams = {};
1677
- // verify required parameter 'projectId' is not null or undefined
1678
- if (projectId === null || projectId === undefined) {
1679
- throw new Error('Required parameter projectId was null or undefined when calling adminRemoveUserFromProject.');
1680
- }
1681
- // verify required parameter 'userId' is not null or undefined
1682
- if (userId === null || userId === undefined) {
1683
- throw new Error('Required parameter userId was null or undefined when calling adminRemoveUserFromProject.');
1684
- }
1685
- Object.assign(localVarHeaderParams, options.headers);
1686
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1687
- let localVarUseFormData = false;
1688
- let localVarRequestOptions = {
1689
- method: 'DELETE',
1690
- qs: localVarQueryParameters,
1691
- headers: localVarHeaderParams,
1692
- uri: localVarPath,
1693
- useQuerystring: this._useQuerystring,
1694
- agentOptions: { keepAlive: false },
1695
- json: true,
1696
- };
1697
- let authenticationPromise = Promise.resolve();
1698
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1699
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1700
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1701
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1702
- return authenticationPromise.then(() => {
1703
- if (Object.keys(localVarFormParams).length) {
1704
- if (localVarUseFormData) {
1705
- localVarRequestOptions.formData = localVarFormParams;
1706
- }
1707
- else {
1708
- localVarRequestOptions.form = localVarFormParams;
1709
- }
1710
- }
1711
- return new Promise((resolve, reject) => {
1712
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1713
- if (error) {
1714
- reject(error);
1715
- }
1716
- else {
1717
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
1718
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1719
- if (typeof body.success === 'boolean' && !body.success) {
1720
- reject(new Error(body.error || errString));
1721
- }
1722
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1723
- resolve(body);
1724
- }
1725
- else {
1726
- reject(errString);
1727
- }
1728
- }
1729
- });
1730
- });
1731
- });
1732
- }
1733
- /**
1734
- * DEPRECATED. Admin-only API to remove the current user from a project.
1735
- * @summary Remove current user from a project
1736
- * @param projectId Project ID
1737
- */
1738
- async adminRemoveUserFromProjectDeprecated(projectId, options = { headers: {} }) {
1739
- const localVarPath = this.basePath + '/api/admin/projects/{projectId}/remove'
1740
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
1741
- let localVarQueryParameters = {};
1742
- let localVarHeaderParams = Object.assign({
1743
- 'User-Agent': 'edgeimpulse-api nodejs'
1744
- }, this.defaultHeaders);
1745
- const produces = ['application/json'];
1746
- // give precedence to 'application/json'
1747
- if (produces.indexOf('application/json') >= 0) {
1748
- localVarHeaderParams.Accept = 'application/json';
1749
- }
1750
- else {
1751
- localVarHeaderParams.Accept = produces.join(',');
1752
- }
1753
- let localVarFormParams = {};
1754
- // verify required parameter 'projectId' is not null or undefined
1755
- if (projectId === null || projectId === undefined) {
1756
- throw new Error('Required parameter projectId was null or undefined when calling adminRemoveUserFromProjectDeprecated.');
1757
- }
1758
- Object.assign(localVarHeaderParams, options.headers);
1759
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1760
- let localVarUseFormData = false;
1761
- let localVarRequestOptions = {
1762
- method: 'POST',
1763
- qs: localVarQueryParameters,
1764
- headers: localVarHeaderParams,
1765
- uri: localVarPath,
1766
- useQuerystring: this._useQuerystring,
1767
- agentOptions: { keepAlive: false },
1768
- json: true,
1769
- };
1770
- let authenticationPromise = Promise.resolve();
1771
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1772
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1773
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1774
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1775
- return authenticationPromise.then(() => {
1776
- if (Object.keys(localVarFormParams).length) {
1777
- if (localVarUseFormData) {
1778
- localVarRequestOptions.formData = localVarFormParams;
1779
- }
1780
- else {
1781
- localVarRequestOptions.form = localVarFormParams;
1782
- }
1783
- }
1784
- return new Promise((resolve, reject) => {
1785
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1786
- if (error) {
1787
- reject(error);
1788
- }
1789
- else {
1790
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
1791
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1792
- if (typeof body.success === 'boolean' && !body.success) {
1793
- reject(new Error(body.error || errString));
1794
- }
1795
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1796
- resolve(body);
1797
- }
1798
- else {
1799
- reject(errString);
1800
- }
1801
- }
1802
- });
1803
- });
1804
- });
1805
- }
1806
- /**
1807
- * Admin-only API to update organization properties such as name and logo.
1808
- * @summary Update organization
1809
- * @param organizationId Organization ID
1810
- * @param adminUpdateOrganizationRequest
1811
- */
1812
- async adminUpdateOrganization(organizationId, adminUpdateOrganizationRequest, options = { headers: {} }) {
1813
- const localVarPath = this.basePath + '/api/admin/organizations/{organizationId}'
1814
- .replace('{' + 'organizationId' + '}', encodeURIComponent(String(organizationId)));
1815
- let localVarQueryParameters = {};
1816
- let localVarHeaderParams = Object.assign({
1817
- 'User-Agent': 'edgeimpulse-api nodejs'
1818
- }, this.defaultHeaders);
1819
- const produces = ['application/json'];
1820
- // give precedence to 'application/json'
1821
- if (produces.indexOf('application/json') >= 0) {
1822
- localVarHeaderParams.Accept = 'application/json';
1823
- }
1824
- else {
1825
- localVarHeaderParams.Accept = produces.join(',');
1826
- }
1827
- let localVarFormParams = {};
1828
- // verify required parameter 'organizationId' is not null or undefined
1829
- if (organizationId === null || organizationId === undefined) {
1830
- throw new Error('Required parameter organizationId was null or undefined when calling adminUpdateOrganization.');
1831
- }
1832
- // verify required parameter 'adminUpdateOrganizationRequest' is not null or undefined
1833
- if (adminUpdateOrganizationRequest === null || adminUpdateOrganizationRequest === undefined) {
1834
- throw new Error('Required parameter adminUpdateOrganizationRequest was null or undefined when calling adminUpdateOrganization.');
1835
- }
1836
- Object.assign(localVarHeaderParams, options.headers);
1837
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1838
- let localVarUseFormData = false;
1839
- let localVarRequestOptions = {
1840
- method: 'POST',
1841
- qs: localVarQueryParameters,
1842
- headers: localVarHeaderParams,
1843
- uri: localVarPath,
1844
- useQuerystring: this._useQuerystring,
1845
- agentOptions: { keepAlive: false },
1846
- json: true,
1847
- body: models_1.ObjectSerializer.serialize(adminUpdateOrganizationRequest, "AdminUpdateOrganizationRequest")
1848
- };
1849
- let authenticationPromise = Promise.resolve();
1850
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1851
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1852
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1853
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1854
- return authenticationPromise.then(() => {
1855
- if (Object.keys(localVarFormParams).length) {
1856
- if (localVarUseFormData) {
1857
- localVarRequestOptions.formData = localVarFormParams;
1858
- }
1859
- else {
1860
- localVarRequestOptions.form = localVarFormParams;
1861
- }
1862
- }
1863
- return new Promise((resolve, reject) => {
1864
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1865
- if (error) {
1866
- reject(error);
1867
- }
1868
- else {
1869
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
1870
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1871
- if (typeof body.success === 'boolean' && !body.success) {
1872
- reject(new Error(body.error || errString));
1873
- }
1874
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1875
- resolve(body);
1876
- }
1877
- else {
1878
- reject(errString);
1879
- }
1880
- }
1881
- });
1882
- });
1883
- });
1884
- }
1885
- /**
1886
- * Admin-only API to update project properties.
1887
- * @summary Update project
1888
- * @param projectId Project ID
1889
- * @param updateProjectRequest
1890
- */
1891
- async adminUpdateProject(projectId, updateProjectRequest, options = { headers: {} }) {
1892
- const localVarPath = this.basePath + '/api/admin/projects/{projectId}'
1893
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
1894
- let localVarQueryParameters = {};
1895
- let localVarHeaderParams = Object.assign({
1896
- 'User-Agent': 'edgeimpulse-api nodejs'
1897
- }, this.defaultHeaders);
1898
- const produces = ['application/json'];
1899
- // give precedence to 'application/json'
1900
- if (produces.indexOf('application/json') >= 0) {
1901
- localVarHeaderParams.Accept = 'application/json';
1902
- }
1903
- else {
1904
- localVarHeaderParams.Accept = produces.join(',');
1905
- }
1906
- let localVarFormParams = {};
1907
- // verify required parameter 'projectId' is not null or undefined
1908
- if (projectId === null || projectId === undefined) {
1909
- throw new Error('Required parameter projectId was null or undefined when calling adminUpdateProject.');
1910
- }
1911
- // verify required parameter 'updateProjectRequest' is not null or undefined
1912
- if (updateProjectRequest === null || updateProjectRequest === undefined) {
1913
- throw new Error('Required parameter updateProjectRequest was null or undefined when calling adminUpdateProject.');
1914
- }
1915
- Object.assign(localVarHeaderParams, options.headers);
1916
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1917
- let localVarUseFormData = false;
1918
- let localVarRequestOptions = {
1919
- method: 'POST',
1920
- qs: localVarQueryParameters,
1921
- headers: localVarHeaderParams,
1922
- uri: localVarPath,
1923
- useQuerystring: this._useQuerystring,
1924
- agentOptions: { keepAlive: false },
1925
- json: true,
1926
- body: models_1.ObjectSerializer.serialize(updateProjectRequest, "UpdateProjectRequest")
1927
- };
1928
- let authenticationPromise = Promise.resolve();
1929
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
1930
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
1931
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
1932
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
1933
- return authenticationPromise.then(() => {
1934
- if (Object.keys(localVarFormParams).length) {
1935
- if (localVarUseFormData) {
1936
- localVarRequestOptions.formData = localVarFormParams;
1937
- }
1938
- else {
1939
- localVarRequestOptions.form = localVarFormParams;
1940
- }
1941
- }
1942
- return new Promise((resolve, reject) => {
1943
- localVarRequest(localVarRequestOptions, (error, response, body) => {
1944
- if (error) {
1945
- reject(error);
1946
- }
1947
- else {
1948
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
1949
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
1950
- if (typeof body.success === 'boolean' && !body.success) {
1951
- reject(new Error(body.error || errString));
1952
- }
1953
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
1954
- resolve(body);
1955
- }
1956
- else {
1957
- reject(errString);
1958
- }
1959
- }
1960
- });
1961
- });
1962
- });
1963
- }
1964
- /**
1965
- * Admin-only API to update user properties.
1966
- * @summary Update user
1967
- * @param userId User ID
1968
- * @param adminUpdateUserRequest
1969
- */
1970
- async adminUpdateUser(userId, adminUpdateUserRequest, options = { headers: {} }) {
1971
- const localVarPath = this.basePath + '/api/admin/users/{userId}'
1972
- .replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
1973
- let localVarQueryParameters = {};
1974
- let localVarHeaderParams = Object.assign({
1975
- 'User-Agent': 'edgeimpulse-api nodejs'
1976
- }, this.defaultHeaders);
1977
- const produces = ['application/json'];
1978
- // give precedence to 'application/json'
1979
- if (produces.indexOf('application/json') >= 0) {
1980
- localVarHeaderParams.Accept = 'application/json';
1981
- }
1982
- else {
1983
- localVarHeaderParams.Accept = produces.join(',');
1984
- }
1985
- let localVarFormParams = {};
1986
- // verify required parameter 'userId' is not null or undefined
1987
- if (userId === null || userId === undefined) {
1988
- throw new Error('Required parameter userId was null or undefined when calling adminUpdateUser.');
1989
- }
1990
- // verify required parameter 'adminUpdateUserRequest' is not null or undefined
1991
- if (adminUpdateUserRequest === null || adminUpdateUserRequest === undefined) {
1992
- throw new Error('Required parameter adminUpdateUserRequest was null or undefined when calling adminUpdateUser.');
1993
- }
1994
- Object.assign(localVarHeaderParams, options.headers);
1995
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
1996
- let localVarUseFormData = false;
1997
- let localVarRequestOptions = {
1998
- method: 'POST',
1999
- qs: localVarQueryParameters,
2000
- headers: localVarHeaderParams,
2001
- uri: localVarPath,
2002
- useQuerystring: this._useQuerystring,
2003
- agentOptions: { keepAlive: false },
2004
- json: true,
2005
- body: models_1.ObjectSerializer.serialize(adminUpdateUserRequest, "AdminUpdateUserRequest")
2006
- };
2007
- let authenticationPromise = Promise.resolve();
2008
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2009
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2010
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2011
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2012
- return authenticationPromise.then(() => {
2013
- if (Object.keys(localVarFormParams).length) {
2014
- if (localVarUseFormData) {
2015
- localVarRequestOptions.formData = localVarFormParams;
2016
- }
2017
- else {
2018
- localVarRequestOptions.form = localVarFormParams;
2019
- }
2020
- }
2021
- return new Promise((resolve, reject) => {
2022
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2023
- if (error) {
2024
- reject(error);
2025
- }
2026
- else {
2027
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
2028
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2029
- if (typeof body.success === 'boolean' && !body.success) {
2030
- reject(new Error(body.error || errString));
2031
- }
2032
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2033
- resolve(body);
2034
- }
2035
- else {
2036
- reject(errString);
2037
- }
2038
- }
2039
- });
2040
- });
2041
- });
2042
- }
2043
- /**
2044
- * Create a new third party authentication partner
2045
- * @summary Create third party auth
2046
- * @param createThirdPartyAuthRequest
2047
- */
2048
- async createThirdPartyAuth(createThirdPartyAuthRequest, options = { headers: {} }) {
2049
- const localVarPath = this.basePath + '/api/third-party-auth';
2050
- let localVarQueryParameters = {};
2051
- let localVarHeaderParams = Object.assign({
2052
- 'User-Agent': 'edgeimpulse-api nodejs'
2053
- }, this.defaultHeaders);
2054
- const produces = ['application/json'];
2055
- // give precedence to 'application/json'
2056
- if (produces.indexOf('application/json') >= 0) {
2057
- localVarHeaderParams.Accept = 'application/json';
2058
- }
2059
- else {
2060
- localVarHeaderParams.Accept = produces.join(',');
2061
- }
2062
- let localVarFormParams = {};
2063
- // verify required parameter 'createThirdPartyAuthRequest' is not null or undefined
2064
- if (createThirdPartyAuthRequest === null || createThirdPartyAuthRequest === undefined) {
2065
- throw new Error('Required parameter createThirdPartyAuthRequest was null or undefined when calling createThirdPartyAuth.');
2066
- }
2067
- Object.assign(localVarHeaderParams, options.headers);
2068
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2069
- let localVarUseFormData = false;
2070
- let localVarRequestOptions = {
2071
- method: 'POST',
2072
- qs: localVarQueryParameters,
2073
- headers: localVarHeaderParams,
2074
- uri: localVarPath,
2075
- useQuerystring: this._useQuerystring,
2076
- agentOptions: { keepAlive: false },
2077
- json: true,
2078
- body: models_1.ObjectSerializer.serialize(createThirdPartyAuthRequest, "CreateThirdPartyAuthRequest")
2079
- };
2080
- let authenticationPromise = Promise.resolve();
2081
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2082
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2083
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2084
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2085
- return authenticationPromise.then(() => {
2086
- if (Object.keys(localVarFormParams).length) {
2087
- if (localVarUseFormData) {
2088
- localVarRequestOptions.formData = localVarFormParams;
2089
- }
2090
- else {
2091
- localVarRequestOptions.form = localVarFormParams;
2092
- }
2093
- }
2094
- return new Promise((resolve, reject) => {
2095
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2096
- if (error) {
2097
- reject(error);
2098
- }
2099
- else {
2100
- body = models_1.ObjectSerializer.deserialize(body, "CreateThirdPartyAuthResponse");
2101
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2102
- if (typeof body.success === 'boolean' && !body.success) {
2103
- reject(new Error(body.error || errString));
2104
- }
2105
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2106
- resolve(body);
2107
- }
2108
- else {
2109
- reject(errString);
2110
- }
2111
- }
2112
- });
2113
- });
2114
- });
2115
- }
2116
- /**
2117
- * Create a new white label
2118
- * @summary Create a new white label
2119
- * @param createWhitelabelRequest
2120
- */
2121
- async createWhitelabel(createWhitelabelRequest, options = { headers: {} }) {
2122
- const localVarPath = this.basePath + '/api/whitelabels';
2123
- let localVarQueryParameters = {};
2124
- let localVarHeaderParams = Object.assign({
2125
- 'User-Agent': 'edgeimpulse-api nodejs'
2126
- }, this.defaultHeaders);
2127
- const produces = ['application/json'];
2128
- // give precedence to 'application/json'
2129
- if (produces.indexOf('application/json') >= 0) {
2130
- localVarHeaderParams.Accept = 'application/json';
2131
- }
2132
- else {
2133
- localVarHeaderParams.Accept = produces.join(',');
2134
- }
2135
- let localVarFormParams = {};
2136
- // verify required parameter 'createWhitelabelRequest' is not null or undefined
2137
- if (createWhitelabelRequest === null || createWhitelabelRequest === undefined) {
2138
- throw new Error('Required parameter createWhitelabelRequest was null or undefined when calling createWhitelabel.');
2139
- }
2140
- Object.assign(localVarHeaderParams, options.headers);
2141
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2142
- let localVarUseFormData = false;
2143
- let localVarRequestOptions = {
2144
- method: 'POST',
2145
- qs: localVarQueryParameters,
2146
- headers: localVarHeaderParams,
2147
- uri: localVarPath,
2148
- useQuerystring: this._useQuerystring,
2149
- agentOptions: { keepAlive: false },
2150
- json: true,
2151
- body: models_1.ObjectSerializer.serialize(createWhitelabelRequest, "CreateWhitelabelRequest")
2152
- };
2153
- let authenticationPromise = Promise.resolve();
2154
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2155
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2156
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2157
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2158
- return authenticationPromise.then(() => {
2159
- if (Object.keys(localVarFormParams).length) {
2160
- if (localVarUseFormData) {
2161
- localVarRequestOptions.formData = localVarFormParams;
2162
- }
2163
- else {
2164
- localVarRequestOptions.form = localVarFormParams;
2165
- }
2166
- }
2167
- return new Promise((resolve, reject) => {
2168
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2169
- if (error) {
2170
- reject(error);
2171
- }
2172
- else {
2173
- body = models_1.ObjectSerializer.deserialize(body, "CreateWhitelabelResponse");
2174
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2175
- if (typeof body.success === 'boolean' && !body.success) {
2176
- reject(new Error(body.error || errString));
2177
- }
2178
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2179
- resolve(body);
2180
- }
2181
- else {
2182
- reject(errString);
2183
- }
2184
- }
2185
- });
2186
- });
2187
- });
2188
- }
2189
- /**
2190
- * Delete a third party authentication partner
2191
- * @summary Delete third party auth
2192
- * @param authId Auth ID
2193
- */
2194
- async deleteThirdPartyAuth(authId, options = { headers: {} }) {
2195
- const localVarPath = this.basePath + '/api/third-party-auth/{authId}'
2196
- .replace('{' + 'authId' + '}', encodeURIComponent(String(authId)));
2197
- let localVarQueryParameters = {};
2198
- let localVarHeaderParams = Object.assign({
2199
- 'User-Agent': 'edgeimpulse-api nodejs'
2200
- }, this.defaultHeaders);
2201
- const produces = ['application/json'];
2202
- // give precedence to 'application/json'
2203
- if (produces.indexOf('application/json') >= 0) {
2204
- localVarHeaderParams.Accept = 'application/json';
2205
- }
2206
- else {
2207
- localVarHeaderParams.Accept = produces.join(',');
2208
- }
2209
- let localVarFormParams = {};
2210
- // verify required parameter 'authId' is not null or undefined
2211
- if (authId === null || authId === undefined) {
2212
- throw new Error('Required parameter authId was null or undefined when calling deleteThirdPartyAuth.');
2213
- }
2214
- Object.assign(localVarHeaderParams, options.headers);
2215
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2216
- let localVarUseFormData = false;
2217
- let localVarRequestOptions = {
2218
- method: 'DELETE',
2219
- qs: localVarQueryParameters,
2220
- headers: localVarHeaderParams,
2221
- uri: localVarPath,
2222
- useQuerystring: this._useQuerystring,
2223
- agentOptions: { keepAlive: false },
2224
- json: true,
2225
- };
2226
- let authenticationPromise = Promise.resolve();
2227
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2228
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2229
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2230
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2231
- return authenticationPromise.then(() => {
2232
- if (Object.keys(localVarFormParams).length) {
2233
- if (localVarUseFormData) {
2234
- localVarRequestOptions.formData = localVarFormParams;
2235
- }
2236
- else {
2237
- localVarRequestOptions.form = localVarFormParams;
2238
- }
2239
- }
2240
- return new Promise((resolve, reject) => {
2241
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2242
- if (error) {
2243
- reject(error);
2244
- }
2245
- else {
2246
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
2247
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2248
- if (typeof body.success === 'boolean' && !body.success) {
2249
- reject(new Error(body.error || errString));
2250
- }
2251
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2252
- resolve(body);
2253
- }
2254
- else {
2255
- reject(errString);
2256
- }
2257
- }
2258
- });
2259
- });
2260
- });
2261
- }
2262
- /**
2263
- * Deletes the white label with the given id.
2264
- * @summary Deletes a white label
2265
- * @param whitelabelIdentifier Whitelabel ID
2266
- */
2267
- async deleteWhitelabel(whitelabelIdentifier, options = { headers: {} }) {
2268
- const localVarPath = this.basePath + '/api/whitelabel/{whitelabelIdentifier}'
2269
- .replace('{' + 'whitelabelIdentifier' + '}', encodeURIComponent(String(whitelabelIdentifier)));
2270
- let localVarQueryParameters = {};
2271
- let localVarHeaderParams = Object.assign({
2272
- 'User-Agent': 'edgeimpulse-api nodejs'
2273
- }, this.defaultHeaders);
2274
- const produces = ['application/json'];
2275
- // give precedence to 'application/json'
2276
- if (produces.indexOf('application/json') >= 0) {
2277
- localVarHeaderParams.Accept = 'application/json';
2278
- }
2279
- else {
2280
- localVarHeaderParams.Accept = produces.join(',');
2281
- }
2282
- let localVarFormParams = {};
2283
- // verify required parameter 'whitelabelIdentifier' is not null or undefined
2284
- if (whitelabelIdentifier === null || whitelabelIdentifier === undefined) {
2285
- throw new Error('Required parameter whitelabelIdentifier was null or undefined when calling deleteWhitelabel.');
2286
- }
2287
- Object.assign(localVarHeaderParams, options.headers);
2288
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2289
- let localVarUseFormData = false;
2290
- let localVarRequestOptions = {
2291
- method: 'DELETE',
2292
- qs: localVarQueryParameters,
2293
- headers: localVarHeaderParams,
2294
- uri: localVarPath,
2295
- useQuerystring: this._useQuerystring,
2296
- agentOptions: { keepAlive: false },
2297
- json: true,
2298
- };
2299
- let authenticationPromise = Promise.resolve();
2300
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2301
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2302
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2303
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2304
- return authenticationPromise.then(() => {
2305
- if (Object.keys(localVarFormParams).length) {
2306
- if (localVarUseFormData) {
2307
- localVarRequestOptions.formData = localVarFormParams;
2308
- }
2309
- else {
2310
- localVarRequestOptions.form = localVarFormParams;
2311
- }
2312
- }
2313
- return new Promise((resolve, reject) => {
2314
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2315
- if (error) {
2316
- reject(error);
2317
- }
2318
- else {
2319
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
2320
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2321
- if (typeof body.success === 'boolean' && !body.success) {
2322
- reject(new Error(body.error || errString));
2323
- }
2324
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2325
- resolve(body);
2326
- }
2327
- else {
2328
- reject(errString);
2329
- }
2330
- }
2331
- });
2332
- });
2333
- });
2334
- }
2335
- /**
2336
- * Lists all possible DSP and ML blocks available for this white label.
2337
- * @summary Get impulse blocks
2338
- * @param whitelabelIdentifier Whitelabel ID
2339
- */
2340
- async getAllImpulseBlocks(whitelabelIdentifier, options = { headers: {} }) {
2341
- const localVarPath = this.basePath + '/api/whitelabel/{whitelabelIdentifier}/impulse/blocks'
2342
- .replace('{' + 'whitelabelIdentifier' + '}', encodeURIComponent(String(whitelabelIdentifier)));
2343
- let localVarQueryParameters = {};
2344
- let localVarHeaderParams = Object.assign({
2345
- 'User-Agent': 'edgeimpulse-api nodejs'
2346
- }, this.defaultHeaders);
2347
- const produces = ['application/json'];
2348
- // give precedence to 'application/json'
2349
- if (produces.indexOf('application/json') >= 0) {
2350
- localVarHeaderParams.Accept = 'application/json';
2351
- }
2352
- else {
2353
- localVarHeaderParams.Accept = produces.join(',');
2354
- }
2355
- let localVarFormParams = {};
2356
- // verify required parameter 'whitelabelIdentifier' is not null or undefined
2357
- if (whitelabelIdentifier === null || whitelabelIdentifier === undefined) {
2358
- throw new Error('Required parameter whitelabelIdentifier was null or undefined when calling getAllImpulseBlocks.');
2359
- }
2360
- Object.assign(localVarHeaderParams, options.headers);
2361
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2362
- let localVarUseFormData = false;
2363
- let localVarRequestOptions = {
2364
- method: 'GET',
2365
- qs: localVarQueryParameters,
2366
- headers: localVarHeaderParams,
2367
- uri: localVarPath,
2368
- useQuerystring: this._useQuerystring,
2369
- agentOptions: { keepAlive: false },
2370
- json: true,
2371
- };
2372
- let authenticationPromise = Promise.resolve();
2373
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2374
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2375
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2376
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2377
- return authenticationPromise.then(() => {
2378
- if (Object.keys(localVarFormParams).length) {
2379
- if (localVarUseFormData) {
2380
- localVarRequestOptions.formData = localVarFormParams;
2381
- }
2382
- else {
2383
- localVarRequestOptions.form = localVarFormParams;
2384
- }
2385
- }
2386
- return new Promise((resolve, reject) => {
2387
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2388
- if (error) {
2389
- reject(error);
2390
- }
2391
- else {
2392
- body = models_1.ObjectSerializer.deserialize(body, "GetImpulseBlocksResponse");
2393
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2394
- if (typeof body.success === 'boolean' && !body.success) {
2395
- reject(new Error(body.error || errString));
2396
- }
2397
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2398
- resolve(body);
2399
- }
2400
- else {
2401
- reject(errString);
2402
- }
2403
- }
2404
- });
2405
- });
2406
- });
2407
- }
2408
- /**
2409
- * Get information about all third party authentication partners
2410
- * @summary Get all third party auth
2411
- */
2412
- async getAllThirdPartyAuth(options = { headers: {} }) {
2413
- const localVarPath = this.basePath + '/api/third-party-auth';
2414
- let localVarQueryParameters = {};
2415
- let localVarHeaderParams = Object.assign({
2416
- 'User-Agent': 'edgeimpulse-api nodejs'
2417
- }, this.defaultHeaders);
2418
- const produces = ['application/json'];
2419
- // give precedence to 'application/json'
2420
- if (produces.indexOf('application/json') >= 0) {
2421
- localVarHeaderParams.Accept = 'application/json';
2422
- }
2423
- else {
2424
- localVarHeaderParams.Accept = produces.join(',');
2425
- }
2426
- let localVarFormParams = {};
2427
- Object.assign(localVarHeaderParams, options.headers);
2428
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2429
- let localVarUseFormData = false;
2430
- let localVarRequestOptions = {
2431
- method: 'GET',
2432
- qs: localVarQueryParameters,
2433
- headers: localVarHeaderParams,
2434
- uri: localVarPath,
2435
- useQuerystring: this._useQuerystring,
2436
- agentOptions: { keepAlive: false },
2437
- json: true,
2438
- };
2439
- let authenticationPromise = Promise.resolve();
2440
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2441
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2442
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2443
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2444
- return authenticationPromise.then(() => {
2445
- if (Object.keys(localVarFormParams).length) {
2446
- if (localVarUseFormData) {
2447
- localVarRequestOptions.formData = localVarFormParams;
2448
- }
2449
- else {
2450
- localVarRequestOptions.form = localVarFormParams;
2451
- }
2452
- }
2453
- return new Promise((resolve, reject) => {
2454
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2455
- if (error) {
2456
- reject(error);
2457
- }
2458
- else {
2459
- body = models_1.ObjectSerializer.deserialize(body, "GetAllThirdPartyAuthResponse");
2460
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2461
- if (typeof body.success === 'boolean' && !body.success) {
2462
- reject(new Error(body.error || errString));
2463
- }
2464
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2465
- resolve(body);
2466
- }
2467
- else {
2468
- reject(errString);
2469
- }
2470
- }
2471
- });
2472
- });
2473
- });
2474
- }
2475
- /**
2476
- * Retrieve the list of registered white labels.
2477
- * @summary List the registered white labels
2478
- */
2479
- async getAllWhitelabels(options = { headers: {} }) {
2480
- const localVarPath = this.basePath + '/api/whitelabels';
2481
- let localVarQueryParameters = {};
2482
- let localVarHeaderParams = Object.assign({
2483
- 'User-Agent': 'edgeimpulse-api nodejs'
2484
- }, this.defaultHeaders);
2485
- const produces = ['application/json'];
2486
- // give precedence to 'application/json'
2487
- if (produces.indexOf('application/json') >= 0) {
2488
- localVarHeaderParams.Accept = 'application/json';
2489
- }
2490
- else {
2491
- localVarHeaderParams.Accept = produces.join(',');
2492
- }
2493
- let localVarFormParams = {};
2494
- Object.assign(localVarHeaderParams, options.headers);
2495
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2496
- let localVarUseFormData = false;
2497
- let localVarRequestOptions = {
2498
- method: 'GET',
2499
- qs: localVarQueryParameters,
2500
- headers: localVarHeaderParams,
2501
- uri: localVarPath,
2502
- useQuerystring: this._useQuerystring,
2503
- agentOptions: { keepAlive: false },
2504
- json: true,
2505
- };
2506
- let authenticationPromise = Promise.resolve();
2507
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2508
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2509
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2510
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2511
- return authenticationPromise.then(() => {
2512
- if (Object.keys(localVarFormParams).length) {
2513
- if (localVarUseFormData) {
2514
- localVarRequestOptions.formData = localVarFormParams;
2515
- }
2516
- else {
2517
- localVarRequestOptions.form = localVarFormParams;
2518
- }
2519
- }
2520
- return new Promise((resolve, reject) => {
2521
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2522
- if (error) {
2523
- reject(error);
2524
- }
2525
- else {
2526
- body = models_1.ObjectSerializer.deserialize(body, "GetAllWhitelabelsResponse");
2527
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2528
- if (typeof body.success === 'boolean' && !body.success) {
2529
- reject(new Error(body.error || errString));
2530
- }
2531
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2532
- resolve(body);
2533
- }
2534
- else {
2535
- reject(errString);
2536
- }
2537
- }
2538
- });
2539
- });
2540
- });
2541
- }
2542
- /**
2543
- * Retrieve all the information about this white label.
2544
- * @summary White label information
2545
- * @param whitelabelIdentifier Whitelabel ID
2546
- */
2547
- async getWhitelabel(whitelabelIdentifier, options = { headers: {} }) {
2548
- const localVarPath = this.basePath + '/api/whitelabel/{whitelabelIdentifier}'
2549
- .replace('{' + 'whitelabelIdentifier' + '}', encodeURIComponent(String(whitelabelIdentifier)));
2550
- let localVarQueryParameters = {};
2551
- let localVarHeaderParams = Object.assign({
2552
- 'User-Agent': 'edgeimpulse-api nodejs'
2553
- }, this.defaultHeaders);
2554
- const produces = ['application/json'];
2555
- // give precedence to 'application/json'
2556
- if (produces.indexOf('application/json') >= 0) {
2557
- localVarHeaderParams.Accept = 'application/json';
2558
- }
2559
- else {
2560
- localVarHeaderParams.Accept = produces.join(',');
2561
- }
2562
- let localVarFormParams = {};
2563
- // verify required parameter 'whitelabelIdentifier' is not null or undefined
2564
- if (whitelabelIdentifier === null || whitelabelIdentifier === undefined) {
2565
- throw new Error('Required parameter whitelabelIdentifier was null or undefined when calling getWhitelabel.');
2566
- }
2567
- Object.assign(localVarHeaderParams, options.headers);
2568
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2569
- let localVarUseFormData = false;
2570
- let localVarRequestOptions = {
2571
- method: 'GET',
2572
- qs: localVarQueryParameters,
2573
- headers: localVarHeaderParams,
2574
- uri: localVarPath,
2575
- useQuerystring: this._useQuerystring,
2576
- agentOptions: { keepAlive: false },
2577
- json: true,
2578
- };
2579
- let authenticationPromise = Promise.resolve();
2580
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2581
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2582
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2583
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2584
- return authenticationPromise.then(() => {
2585
- if (Object.keys(localVarFormParams).length) {
2586
- if (localVarUseFormData) {
2587
- localVarRequestOptions.formData = localVarFormParams;
2588
- }
2589
- else {
2590
- localVarRequestOptions.form = localVarFormParams;
2591
- }
2592
- }
2593
- return new Promise((resolve, reject) => {
2594
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2595
- if (error) {
2596
- reject(error);
2597
- }
2598
- else {
2599
- body = models_1.ObjectSerializer.deserialize(body, "GetWhitelabelResponse");
2600
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2601
- if (typeof body.success === 'boolean' && !body.success) {
2602
- reject(new Error(body.error || errString));
2603
- }
2604
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2605
- resolve(body);
2606
- }
2607
- else {
2608
- reject(errString);
2609
- }
2610
- }
2611
- });
2612
- });
2613
- });
2614
- }
2615
- /**
2616
- * Get a list of all emails sent by Edge Impulse to the current user. This function is only available through a JWT token, and is not available for all users.
2617
- * @summary List emails
2618
- */
2619
- async listEmailsCurrentUser(options = { headers: {} }) {
2620
- const localVarPath = this.basePath + '/api/user/emails';
2621
- let localVarQueryParameters = {};
2622
- let localVarHeaderParams = Object.assign({
2623
- 'User-Agent': 'edgeimpulse-api nodejs'
2624
- }, this.defaultHeaders);
2625
- const produces = ['application/json'];
2626
- // give precedence to 'application/json'
2627
- if (produces.indexOf('application/json') >= 0) {
2628
- localVarHeaderParams.Accept = 'application/json';
2629
- }
2630
- else {
2631
- localVarHeaderParams.Accept = produces.join(',');
2632
- }
2633
- let localVarFormParams = {};
2634
- Object.assign(localVarHeaderParams, options.headers);
2635
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2636
- let localVarUseFormData = false;
2637
- let localVarRequestOptions = {
2638
- method: 'GET',
2639
- qs: localVarQueryParameters,
2640
- headers: localVarHeaderParams,
2641
- uri: localVarPath,
2642
- useQuerystring: this._useQuerystring,
2643
- agentOptions: { keepAlive: false },
2644
- json: true,
2645
- };
2646
- let authenticationPromise = Promise.resolve();
2647
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2648
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2649
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2650
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2651
- return authenticationPromise.then(() => {
2652
- if (Object.keys(localVarFormParams).length) {
2653
- if (localVarUseFormData) {
2654
- localVarRequestOptions.formData = localVarFormParams;
2655
- }
2656
- else {
2657
- localVarRequestOptions.form = localVarFormParams;
2658
- }
2659
- }
2660
- return new Promise((resolve, reject) => {
2661
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2662
- if (error) {
2663
- reject(error);
2664
- }
2665
- else {
2666
- body = models_1.ObjectSerializer.deserialize(body, "ListEmailResponse");
2667
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2668
- if (typeof body.success === 'boolean' && !body.success) {
2669
- reject(new Error(body.error || errString));
2670
- }
2671
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2672
- resolve(body);
2673
- }
2674
- else {
2675
- reject(errString);
2676
- }
2677
- }
2678
- });
2679
- });
2680
- });
2681
- }
2682
- /**
2683
- * Get a list of all emails sent by Edge Impulse to a user. This function is only available through a JWT token, and is not available for all users.
2684
- * @summary List emails
2685
- * @param userId User ID
2686
- */
2687
- async listEmailsUser(userId, options = { headers: {} }) {
2688
- const localVarPath = this.basePath + '/api/users/{userId}/emails'
2689
- .replace('{' + 'userId' + '}', encodeURIComponent(String(userId)));
2690
- let localVarQueryParameters = {};
2691
- let localVarHeaderParams = Object.assign({
2692
- 'User-Agent': 'edgeimpulse-api nodejs'
2693
- }, this.defaultHeaders);
2694
- const produces = ['application/json'];
2695
- // give precedence to 'application/json'
2696
- if (produces.indexOf('application/json') >= 0) {
2697
- localVarHeaderParams.Accept = 'application/json';
2698
- }
2699
- else {
2700
- localVarHeaderParams.Accept = produces.join(',');
2701
- }
2702
- let localVarFormParams = {};
2703
- // verify required parameter 'userId' is not null or undefined
2704
- if (userId === null || userId === undefined) {
2705
- throw new Error('Required parameter userId was null or undefined when calling listEmailsUser.');
2706
- }
2707
- Object.assign(localVarHeaderParams, options.headers);
2708
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2709
- let localVarUseFormData = false;
2710
- let localVarRequestOptions = {
2711
- method: 'GET',
2712
- qs: localVarQueryParameters,
2713
- headers: localVarHeaderParams,
2714
- uri: localVarPath,
2715
- useQuerystring: this._useQuerystring,
2716
- agentOptions: { keepAlive: false },
2717
- json: true,
2718
- };
2719
- let authenticationPromise = Promise.resolve();
2720
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2721
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2722
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2723
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2724
- return authenticationPromise.then(() => {
2725
- if (Object.keys(localVarFormParams).length) {
2726
- if (localVarUseFormData) {
2727
- localVarRequestOptions.formData = localVarFormParams;
2728
- }
2729
- else {
2730
- localVarRequestOptions.form = localVarFormParams;
2731
- }
2732
- }
2733
- return new Promise((resolve, reject) => {
2734
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2735
- if (error) {
2736
- reject(error);
2737
- }
2738
- else {
2739
- body = models_1.ObjectSerializer.deserialize(body, "ListEmailResponse");
2740
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2741
- if (typeof body.success === 'boolean' && !body.success) {
2742
- reject(new Error(body.error || errString));
2743
- }
2744
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2745
- resolve(body);
2746
- }
2747
- else {
2748
- reject(errString);
2749
- }
2750
- }
2751
- });
2752
- });
2753
- });
2754
- }
2755
- /**
2756
- * Change the job compute time limit for the project. This function is only available through a JWT token, and is not available to all users.
2757
- * @summary Set compute time limit
2758
- * @param projectId Project ID
2759
- * @param setProjectComputeTimeRequest
2760
- */
2761
- async setProjectComputeTimeLimit(projectId, setProjectComputeTimeRequest, options = { headers: {} }) {
2762
- const localVarPath = this.basePath + '/api/{projectId}/compute-time-limit'
2763
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
2764
- let localVarQueryParameters = {};
2765
- let localVarHeaderParams = Object.assign({
2766
- 'User-Agent': 'edgeimpulse-api nodejs'
2767
- }, this.defaultHeaders);
2768
- const produces = ['application/json'];
2769
- // give precedence to 'application/json'
2770
- if (produces.indexOf('application/json') >= 0) {
2771
- localVarHeaderParams.Accept = 'application/json';
2772
- }
2773
- else {
2774
- localVarHeaderParams.Accept = produces.join(',');
2775
- }
2776
- let localVarFormParams = {};
2777
- // verify required parameter 'projectId' is not null or undefined
2778
- if (projectId === null || projectId === undefined) {
2779
- throw new Error('Required parameter projectId was null or undefined when calling setProjectComputeTimeLimit.');
2780
- }
2781
- // verify required parameter 'setProjectComputeTimeRequest' is not null or undefined
2782
- if (setProjectComputeTimeRequest === null || setProjectComputeTimeRequest === undefined) {
2783
- throw new Error('Required parameter setProjectComputeTimeRequest was null or undefined when calling setProjectComputeTimeLimit.');
2784
- }
2785
- Object.assign(localVarHeaderParams, options.headers);
2786
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2787
- let localVarUseFormData = false;
2788
- let localVarRequestOptions = {
2789
- method: 'POST',
2790
- qs: localVarQueryParameters,
2791
- headers: localVarHeaderParams,
2792
- uri: localVarPath,
2793
- useQuerystring: this._useQuerystring,
2794
- agentOptions: { keepAlive: false },
2795
- json: true,
2796
- body: models_1.ObjectSerializer.serialize(setProjectComputeTimeRequest, "SetProjectComputeTimeRequest")
2797
- };
2798
- let authenticationPromise = Promise.resolve();
2799
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2800
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2801
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2802
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2803
- return authenticationPromise.then(() => {
2804
- if (Object.keys(localVarFormParams).length) {
2805
- if (localVarUseFormData) {
2806
- localVarRequestOptions.formData = localVarFormParams;
2807
- }
2808
- else {
2809
- localVarRequestOptions.form = localVarFormParams;
2810
- }
2811
- }
2812
- return new Promise((resolve, reject) => {
2813
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2814
- if (error) {
2815
- reject(error);
2816
- }
2817
- else {
2818
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
2819
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2820
- if (typeof body.success === 'boolean' && !body.success) {
2821
- reject(new Error(body.error || errString));
2822
- }
2823
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2824
- resolve(body);
2825
- }
2826
- else {
2827
- reject(errString);
2828
- }
2829
- }
2830
- });
2831
- });
2832
- });
2833
- }
2834
- /**
2835
- * Change the DSP file size limit for the project. This function is only available through a JWT token, and is not available to all users.
2836
- * @summary Set DSP file size limit
2837
- * @param projectId Project ID
2838
- * @param setProjectDspFileSizeRequest
2839
- */
2840
- async setProjectFileSizeLimit(projectId, setProjectDspFileSizeRequest, options = { headers: {} }) {
2841
- const localVarPath = this.basePath + '/api/{projectId}/dsp-file-size-limit'
2842
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)));
2843
- let localVarQueryParameters = {};
2844
- let localVarHeaderParams = Object.assign({
2845
- 'User-Agent': 'edgeimpulse-api nodejs'
2846
- }, this.defaultHeaders);
2847
- const produces = ['application/json'];
2848
- // give precedence to 'application/json'
2849
- if (produces.indexOf('application/json') >= 0) {
2850
- localVarHeaderParams.Accept = 'application/json';
2851
- }
2852
- else {
2853
- localVarHeaderParams.Accept = produces.join(',');
2854
- }
2855
- let localVarFormParams = {};
2856
- // verify required parameter 'projectId' is not null or undefined
2857
- if (projectId === null || projectId === undefined) {
2858
- throw new Error('Required parameter projectId was null or undefined when calling setProjectFileSizeLimit.');
2859
- }
2860
- // verify required parameter 'setProjectDspFileSizeRequest' is not null or undefined
2861
- if (setProjectDspFileSizeRequest === null || setProjectDspFileSizeRequest === undefined) {
2862
- throw new Error('Required parameter setProjectDspFileSizeRequest was null or undefined when calling setProjectFileSizeLimit.');
2863
- }
2864
- Object.assign(localVarHeaderParams, options.headers);
2865
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2866
- let localVarUseFormData = false;
2867
- let localVarRequestOptions = {
2868
- method: 'POST',
2869
- qs: localVarQueryParameters,
2870
- headers: localVarHeaderParams,
2871
- uri: localVarPath,
2872
- useQuerystring: this._useQuerystring,
2873
- agentOptions: { keepAlive: false },
2874
- json: true,
2875
- body: models_1.ObjectSerializer.serialize(setProjectDspFileSizeRequest, "SetProjectDspFileSizeRequest")
2876
- };
2877
- let authenticationPromise = Promise.resolve();
2878
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2879
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2880
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2881
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2882
- return authenticationPromise.then(() => {
2883
- if (Object.keys(localVarFormParams).length) {
2884
- if (localVarUseFormData) {
2885
- localVarRequestOptions.formData = localVarFormParams;
2886
- }
2887
- else {
2888
- localVarRequestOptions.form = localVarFormParams;
2889
- }
2890
- }
2891
- return new Promise((resolve, reject) => {
2892
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2893
- if (error) {
2894
- reject(error);
2895
- }
2896
- else {
2897
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
2898
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2899
- if (typeof body.success === 'boolean' && !body.success) {
2900
- reject(new Error(body.error || errString));
2901
- }
2902
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2903
- resolve(body);
2904
- }
2905
- else {
2906
- reject(errString);
2907
- }
2908
- }
2909
- });
2910
- });
2911
- });
2912
- }
2913
- /**
2914
- * Update some or all of the deployment targets enabled for this white label.
2915
- * @summary Update deployment targets
2916
- * @param whitelabelIdentifier Whitelabel ID
2917
- * @param updateWhitelabelDeploymentTargetsRequest
2918
- */
2919
- async updateDeploymentTargets(whitelabelIdentifier, updateWhitelabelDeploymentTargetsRequest, options = { headers: {} }) {
2920
- const localVarPath = this.basePath + '/api/whitelabel/{whitelabelIdentifier}/deploymentTargets'
2921
- .replace('{' + 'whitelabelIdentifier' + '}', encodeURIComponent(String(whitelabelIdentifier)));
2922
- let localVarQueryParameters = {};
2923
- let localVarHeaderParams = Object.assign({
2924
- 'User-Agent': 'edgeimpulse-api nodejs'
2925
- }, this.defaultHeaders);
2926
- const produces = ['application/json'];
2927
- // give precedence to 'application/json'
2928
- if (produces.indexOf('application/json') >= 0) {
2929
- localVarHeaderParams.Accept = 'application/json';
2930
- }
2931
- else {
2932
- localVarHeaderParams.Accept = produces.join(',');
2933
- }
2934
- let localVarFormParams = {};
2935
- // verify required parameter 'whitelabelIdentifier' is not null or undefined
2936
- if (whitelabelIdentifier === null || whitelabelIdentifier === undefined) {
2937
- throw new Error('Required parameter whitelabelIdentifier was null or undefined when calling updateDeploymentTargets.');
2938
- }
2939
- // verify required parameter 'updateWhitelabelDeploymentTargetsRequest' is not null or undefined
2940
- if (updateWhitelabelDeploymentTargetsRequest === null || updateWhitelabelDeploymentTargetsRequest === undefined) {
2941
- throw new Error('Required parameter updateWhitelabelDeploymentTargetsRequest was null or undefined when calling updateDeploymentTargets.');
2942
- }
2943
- Object.assign(localVarHeaderParams, options.headers);
2944
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
2945
- let localVarUseFormData = false;
2946
- let localVarRequestOptions = {
2947
- method: 'POST',
2948
- qs: localVarQueryParameters,
2949
- headers: localVarHeaderParams,
2950
- uri: localVarPath,
2951
- useQuerystring: this._useQuerystring,
2952
- agentOptions: { keepAlive: false },
2953
- json: true,
2954
- body: models_1.ObjectSerializer.serialize(updateWhitelabelDeploymentTargetsRequest, "UpdateWhitelabelDeploymentTargetsRequest")
2955
- };
2956
- let authenticationPromise = Promise.resolve();
2957
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
2958
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
2959
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
2960
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
2961
- return authenticationPromise.then(() => {
2962
- if (Object.keys(localVarFormParams).length) {
2963
- if (localVarUseFormData) {
2964
- localVarRequestOptions.formData = localVarFormParams;
2965
- }
2966
- else {
2967
- localVarRequestOptions.form = localVarFormParams;
2968
- }
2969
- }
2970
- return new Promise((resolve, reject) => {
2971
- localVarRequest(localVarRequestOptions, (error, response, body) => {
2972
- if (error) {
2973
- reject(error);
2974
- }
2975
- else {
2976
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
2977
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
2978
- if (typeof body.success === 'boolean' && !body.success) {
2979
- reject(new Error(body.error || errString));
2980
- }
2981
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
2982
- resolve(body);
2983
- }
2984
- else {
2985
- reject(errString);
2986
- }
2987
- }
2988
- });
2989
- });
2990
- });
2991
- }
2992
- /**
2993
- * Update a third party authentication partner
2994
- * @summary Update third party auth
2995
- * @param authId Auth ID
2996
- * @param updateThirdPartyAuthRequest
2997
- */
2998
- async updateThirdPartyAuth(authId, updateThirdPartyAuthRequest, options = { headers: {} }) {
2999
- const localVarPath = this.basePath + '/api/third-party-auth/{authId}'
3000
- .replace('{' + 'authId' + '}', encodeURIComponent(String(authId)));
3001
- let localVarQueryParameters = {};
3002
- let localVarHeaderParams = Object.assign({
3003
- 'User-Agent': 'edgeimpulse-api nodejs'
3004
- }, this.defaultHeaders);
3005
- const produces = ['application/json'];
3006
- // give precedence to 'application/json'
3007
- if (produces.indexOf('application/json') >= 0) {
3008
- localVarHeaderParams.Accept = 'application/json';
3009
- }
3010
- else {
3011
- localVarHeaderParams.Accept = produces.join(',');
3012
- }
3013
- let localVarFormParams = {};
3014
- // verify required parameter 'authId' is not null or undefined
3015
- if (authId === null || authId === undefined) {
3016
- throw new Error('Required parameter authId was null or undefined when calling updateThirdPartyAuth.');
3017
- }
3018
- // verify required parameter 'updateThirdPartyAuthRequest' is not null or undefined
3019
- if (updateThirdPartyAuthRequest === null || updateThirdPartyAuthRequest === undefined) {
3020
- throw new Error('Required parameter updateThirdPartyAuthRequest was null or undefined when calling updateThirdPartyAuth.');
3021
- }
3022
- Object.assign(localVarHeaderParams, options.headers);
3023
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
3024
- let localVarUseFormData = false;
3025
- let localVarRequestOptions = {
3026
- method: 'POST',
3027
- qs: localVarQueryParameters,
3028
- headers: localVarHeaderParams,
3029
- uri: localVarPath,
3030
- useQuerystring: this._useQuerystring,
3031
- agentOptions: { keepAlive: false },
3032
- json: true,
3033
- body: models_1.ObjectSerializer.serialize(updateThirdPartyAuthRequest, "UpdateThirdPartyAuthRequest")
3034
- };
3035
- let authenticationPromise = Promise.resolve();
3036
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
3037
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
3038
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
3039
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
3040
- return authenticationPromise.then(() => {
3041
- if (Object.keys(localVarFormParams).length) {
3042
- if (localVarUseFormData) {
3043
- localVarRequestOptions.formData = localVarFormParams;
3044
- }
3045
- else {
3046
- localVarRequestOptions.form = localVarFormParams;
3047
- }
3048
- }
3049
- return new Promise((resolve, reject) => {
3050
- localVarRequest(localVarRequestOptions, (error, response, body) => {
3051
- if (error) {
3052
- reject(error);
3053
- }
3054
- else {
3055
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
3056
- const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
3057
- if (typeof body.success === 'boolean' && !body.success) {
3058
- reject(new Error(body.error || errString));
3059
- }
3060
- else if (response.statusCode && response.statusCode >= 200 && response.statusCode <= 299) {
3061
- resolve(body);
3062
- }
3063
- else {
3064
- reject(errString);
3065
- }
3066
- }
3067
- });
3068
- });
3069
- });
3070
- }
3071
- /**
3072
- * Replace Keras block files with the contents of a zip. This is an internal API.
3073
- * @summary Upload Keras files
3074
- * @param projectId Project ID
3075
- * @param learnId Learn Block ID, use the impulse functions to retrieve the ID
3076
- * @param zip
3077
- */
3078
- async uploadKerasFiles(projectId, learnId, params, options = { headers: {} }) {
3079
- const localVarPath = this.basePath + '/api/{projectId}/training/keras/{learnId}/files'
3080
- .replace('{' + 'projectId' + '}', encodeURIComponent(String(projectId)))
3081
- .replace('{' + 'learnId' + '}', encodeURIComponent(String(learnId)));
3082
- let localVarQueryParameters = {};
3083
- let localVarHeaderParams = Object.assign({
3084
- 'User-Agent': 'edgeimpulse-api nodejs'
3085
- }, this.defaultHeaders);
3086
- const produces = ['application/json'];
3087
- // give precedence to 'application/json'
3088
- if (produces.indexOf('application/json') >= 0) {
3089
- localVarHeaderParams.Accept = 'application/json';
3090
- }
3091
- else {
3092
- localVarHeaderParams.Accept = produces.join(',');
3093
- }
3094
- let localVarFormParams = {};
3095
- // verify required parameter 'projectId' is not null or undefined
3096
- if (projectId === null || projectId === undefined) {
3097
- throw new Error('Required parameter projectId was null or undefined when calling uploadKerasFiles.');
3098
- }
3099
- // verify required parameter 'learnId' is not null or undefined
3100
- if (learnId === null || learnId === undefined) {
3101
- throw new Error('Required parameter learnId was null or undefined when calling uploadKerasFiles.');
3102
- }
3103
- // verify required parameter 'zip' is not null or undefined
3104
- if (params.zip === null || params.zip === undefined) {
3105
- throw new Error('Required parameter params.zip was null or undefined when calling uploadKerasFiles.');
3106
- }
3107
- Object.assign(localVarHeaderParams, options.headers);
3108
- Object.assign(localVarHeaderParams, this.opts.extraHeaders);
3109
- let localVarUseFormData = false;
3110
- if (params.zip !== undefined) {
3111
- localVarFormParams['zip'] = params.zip;
3112
- }
3113
- localVarUseFormData = true;
3114
- let localVarRequestOptions = {
3115
- method: 'POST',
3116
- qs: localVarQueryParameters,
3117
- headers: localVarHeaderParams,
3118
- uri: localVarPath,
3119
- useQuerystring: this._useQuerystring,
3120
- agentOptions: { keepAlive: false },
3121
- json: true,
3122
- };
3123
- let authenticationPromise = Promise.resolve();
3124
- authenticationPromise = authenticationPromise.then(() => this.authentications.ApiKeyAuthentication.applyToRequest(localVarRequestOptions));
3125
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTAuthentication.applyToRequest(localVarRequestOptions));
3126
- authenticationPromise = authenticationPromise.then(() => this.authentications.JWTHttpHeaderAuthentication.applyToRequest(localVarRequestOptions));
3127
- authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
3128
- return authenticationPromise.then(() => {
3129
- if (Object.keys(localVarFormParams).length) {
3130
- if (localVarUseFormData) {
3131
- localVarRequestOptions.formData = localVarFormParams;
3132
- }
3133
- else {
3134
- localVarRequestOptions.form = localVarFormParams;
3135
- }
3136
- }
3137
- return new Promise((resolve, reject) => {
3138
- localVarRequest(localVarRequestOptions, (error, response, body) => {
3139
- if (error) {
3140
- reject(error);
3141
- }
3142
- else {
3143
- body = models_1.ObjectSerializer.deserialize(body, "GenericApiResponse");
353
+ body = models_1.ObjectSerializer.deserialize(body, "AdminGetSSOSettingsResponse");
3144
354
  const errString = `Failed to call "${localVarPath}", returned ${response.statusCode}: ` + response.body;
3145
355
  if (typeof body.success === 'boolean' && !body.success) {
3146
356
  reject(new Error(body.error || errString));