@opensearch-project/opensearch 3.0.0-beta.7 → 3.0.0-beta.9

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 (610) hide show
  1. package/api/{OpenSearchAPI.d.ts → OpenSearchApi.d.ts} +251 -6
  2. package/api/{OpenSearchAPI.js → OpenSearchApi.js} +15 -0
  3. package/api/_core/bulk.d.ts +4 -4
  4. package/api/_core/bulk.js +1 -1
  5. package/api/_core/bulkStream.d.ts +52 -0
  6. package/api/_core/bulkStream.js +61 -0
  7. package/api/_core/clearScroll.d.ts +3 -3
  8. package/api/_core/clearScroll.js +2 -2
  9. package/api/_core/count.d.ts +5 -5
  10. package/api/_core/count.js +4 -4
  11. package/api/_core/create.d.ts +2 -2
  12. package/api/_core/createPit.d.ts +3 -3
  13. package/api/_core/createPit.js +3 -3
  14. package/api/_core/delete.d.ts +2 -2
  15. package/api/_core/deleteAllPits.d.ts +2 -2
  16. package/api/_core/deleteByQuery.d.ts +5 -20
  17. package/api/_core/deleteByQuery.js +8 -8
  18. package/api/_core/deleteByQueryRethrottle.d.ts +1 -1
  19. package/api/_core/deletePit.d.ts +3 -3
  20. package/api/_core/deleteScript.d.ts +1 -1
  21. package/api/_core/deleteScript.js +1 -1
  22. package/api/_core/exists.d.ts +4 -4
  23. package/api/_core/exists.js +2 -2
  24. package/api/_core/existsSource.d.ts +4 -4
  25. package/api/_core/existsSource.js +3 -3
  26. package/api/_core/explain.d.ts +6 -5
  27. package/api/_core/explain.js +1 -1
  28. package/api/_core/fieldCaps.d.ts +3 -5
  29. package/api/_core/fieldCaps.js +6 -6
  30. package/api/_core/get.d.ts +4 -4
  31. package/api/_core/get.js +3 -3
  32. package/api/_core/getAllPits.d.ts +2 -2
  33. package/api/_core/getScript.d.ts +2 -2
  34. package/api/_core/getScriptContext.d.ts +2 -2
  35. package/api/_core/getScriptLanguages.d.ts +2 -2
  36. package/api/_core/getSource.d.ts +4 -4
  37. package/api/_core/getSource.js +4 -4
  38. package/api/_core/index.d.ts +2 -2
  39. package/api/_core/index.js +1 -1
  40. package/api/_core/info.d.ts +2 -2
  41. package/api/_core/mget.d.ts +6 -6
  42. package/api/_core/mget.js +3 -3
  43. package/api/_core/msearch.d.ts +1 -1
  44. package/api/_core/msearch.js +4 -4
  45. package/api/_core/msearchTemplate.d.ts +2 -2
  46. package/api/_core/msearchTemplate.js +2 -2
  47. package/api/_core/mtermvectors.d.ts +4 -4
  48. package/api/_core/mtermvectors.js +3 -3
  49. package/api/_core/putScript.d.ts +2 -2
  50. package/api/_core/putScript.js +3 -3
  51. package/api/_core/rankEval.d.ts +4 -4
  52. package/api/_core/rankEval.js +5 -5
  53. package/api/_core/reindex.d.ts +4 -19
  54. package/api/_core/reindex.js +1 -1
  55. package/api/_core/reindexRethrottle.d.ts +2 -2
  56. package/api/_core/reindexRethrottle.js +1 -1
  57. package/api/_core/renderSearchTemplate.d.ts +5 -5
  58. package/api/_core/renderSearchTemplate.js +2 -2
  59. package/api/_core/scriptsPainlessExecute.d.ts +5 -5
  60. package/api/_core/scroll.d.ts +3 -3
  61. package/api/_core/scroll.js +3 -3
  62. package/api/_core/search.d.ts +5 -8
  63. package/api/_core/search.js +9 -9
  64. package/api/_core/searchShards.d.ts +14 -3
  65. package/api/_core/searchShards.js +5 -4
  66. package/api/_core/searchTemplate.d.ts +5 -4
  67. package/api/_core/searchTemplate.js +6 -6
  68. package/api/_core/termvectors.d.ts +6 -5
  69. package/api/_core/termvectors.js +2 -2
  70. package/api/_core/update.d.ts +4 -4
  71. package/api/_core/update.js +3 -3
  72. package/api/_core/updateByQuery.d.ts +5 -20
  73. package/api/_core/updateByQuery.js +8 -8
  74. package/api/_core/updateByQueryRethrottle.d.ts +2 -2
  75. package/api/_types/_common.aggregations.d.ts +195 -193
  76. package/api/_types/_common.analysis.d.ts +129 -102
  77. package/api/_types/_common.d.ts +252 -192
  78. package/api/_types/_common.mapping.d.ts +98 -162
  79. package/api/_types/_common.query_dsl.d.ts +128 -131
  80. package/api/_types/_core._common.d.ts +4 -4
  81. package/api/_types/_core.bulk.d.ts +9 -9
  82. package/api/_types/_core.explain.d.ts +4 -4
  83. package/api/_types/_core.field_caps.d.ts +1 -6
  84. package/api/_types/_core.get.d.ts +1 -1
  85. package/api/_types/_core.get_script_context.d.ts +3 -3
  86. package/api/_types/_core.get_script_languages.d.ts +1 -1
  87. package/api/_types/_core.mget.d.ts +3 -3
  88. package/api/_types/_core.msearch.d.ts +6 -8
  89. package/api/_types/_core.msearch_template.d.ts +3 -3
  90. package/api/_types/_core.mtermvectors.d.ts +3 -2
  91. package/api/_types/_core.rank_eval.d.ts +15 -14
  92. package/api/_types/_core.reindex.d.ts +3 -5
  93. package/api/_types/_core.reindex_rethrottle.d.ts +5 -3
  94. package/api/_types/_core.scripts_painless_execute.d.ts +2 -2
  95. package/api/_types/_core.search.d.ts +46 -45
  96. package/api/_types/_core.search_shards.d.ts +1 -1
  97. package/api/_types/_core.termvectors.d.ts +5 -5
  98. package/api/_types/_core.update.d.ts +1 -1
  99. package/api/_types/_core.update_by_query_rethrottle.d.ts +1 -1
  100. package/api/_types/_global.d.ts +1 -1
  101. package/api/_types/asynchronous_search._common.d.ts +7 -9
  102. package/api/_types/cat._common.d.ts +5 -4
  103. package/api/_types/cat.aliases.d.ts +1 -1
  104. package/api/_types/cat.allocation.d.ts +2 -2
  105. package/api/_types/cat.cluster_manager.d.ts +1 -1
  106. package/api/_types/cat.count.d.ts +1 -1
  107. package/api/_types/cat.fielddata.d.ts +1 -1
  108. package/api/_types/cat.health.d.ts +2 -2
  109. package/api/_types/cat.indices.d.ts +1 -1
  110. package/api/_types/cat.master.d.ts +1 -1
  111. package/api/_types/cat.nodeattrs.d.ts +1 -1
  112. package/api/_types/cat.nodes.d.ts +5 -5
  113. package/api/_types/cat.pending_tasks.d.ts +1 -1
  114. package/api/_types/cat.plugins.d.ts +1 -1
  115. package/api/_types/cat.recovery.d.ts +4 -4
  116. package/api/_types/cat.repositories.d.ts +1 -1
  117. package/api/_types/cat.segments.d.ts +2 -2
  118. package/api/_types/cat.shards.d.ts +1 -1
  119. package/api/_types/cat.snapshots.d.ts +1 -1
  120. package/api/_types/cat.tasks.d.ts +1 -1
  121. package/api/_types/cat.templates.d.ts +1 -1
  122. package/api/_types/cat.thread_pool.d.ts +1 -1
  123. package/api/_types/cluster._common.d.ts +4 -5
  124. package/api/_types/cluster.allocation_explain.d.ts +20 -20
  125. package/api/_types/cluster.health.d.ts +6 -5
  126. package/api/_types/cluster.pending_tasks.d.ts +1 -1
  127. package/api/_types/cluster.remote_info.d.ts +2 -2
  128. package/api/_types/cluster.reroute.d.ts +10 -8
  129. package/api/_types/cluster.stats.d.ts +88 -102
  130. package/api/_types/cluster.weighted_routing.d.ts +3 -3
  131. package/api/_types/dangling_indices.list_dangling_indices.d.ts +1 -1
  132. package/api/_types/flow_framework.common.d.ts +131 -7
  133. package/api/_types/flow_framework.errors.d.ts +90 -9
  134. package/api/_types/indices._common.d.ts +364 -236
  135. package/api/_types/indices.add_block.d.ts +1 -1
  136. package/api/_types/indices.analyze.d.ts +6 -6
  137. package/api/_types/indices.close.d.ts +2 -2
  138. package/api/_types/indices.get_alias.d.ts +1 -1
  139. package/api/_types/indices.get_field_mapping.d.ts +1 -1
  140. package/api/_types/indices.get_index_template.d.ts +2 -2
  141. package/api/_types/indices.get_mapping.d.ts +1 -1
  142. package/api/_types/indices.put_index_template.d.ts +2 -3
  143. package/api/_types/indices.recovery.d.ts +25 -21
  144. package/api/_types/indices.resolve_index.d.ts +3 -3
  145. package/api/_types/indices.rollover.d.ts +9 -9
  146. package/api/_types/indices.segments.d.ts +8 -8
  147. package/api/_types/indices.shard_stores.d.ts +7 -6
  148. package/api/_types/indices.simulate_template.d.ts +4 -4
  149. package/api/_types/indices.stats.d.ts +18 -16
  150. package/api/_types/indices.update_aliases.d.ts +4 -4
  151. package/api/_types/indices.validate_query.d.ts +1 -1
  152. package/api/_types/ingest._common.d.ts +39 -39
  153. package/api/_types/ingest.simulate.d.ts +5 -5
  154. package/api/_types/insights._common.d.ts +95 -0
  155. package/api/_types/ism._common.d.ts +259 -0
  156. package/api/_types/knn._common.d.ts +83 -0
  157. package/api/_types/ml._common.d.ts +106 -15
  158. package/api/_types/nodes._common.d.ts +192 -183
  159. package/api/_types/nodes.info.d.ts +61 -61
  160. package/api/_types/nodes.reload_secure_settings.d.ts +2 -2
  161. package/api/_types/nodes.stats.d.ts +2 -2
  162. package/api/_types/nodes.usage.d.ts +5 -5
  163. package/api/_types/notifications._common.d.ts +21 -21
  164. package/api/_types/observability._common.d.ts +16 -16
  165. package/api/_types/query._common.d.ts +12 -7
  166. package/api/_types/remote_store._common.d.ts +2 -2
  167. package/api/_types/replication._common.d.ts +143 -0
  168. package/api/_types/rollups._common.d.ts +22 -38
  169. package/api/_types/search_pipeline._common.d.ts +21 -21
  170. package/api/_types/security._common.d.ts +49 -42
  171. package/api/_types/sm._common.d.ts +198 -0
  172. package/api/_types/snapshot._common.d.ts +48 -57
  173. package/api/_types/snapshot.cleanup_repository.d.ts +1 -1
  174. package/api/_types/snapshot.restore.d.ts +1 -1
  175. package/api/_types/snapshot.verify_repository.d.ts +1 -1
  176. package/api/_types/sql._common.d.ts +18 -18
  177. package/api/_types/tasks._common.d.ts +26 -14
  178. package/api/_types/transforms._common.d.ts +56 -41
  179. package/api/_types/wlm._common.d.ts +53 -0
  180. package/api/asynchronousSearch/delete.d.ts +1 -1
  181. package/api/asynchronousSearch/get.d.ts +1 -1
  182. package/api/asynchronousSearch/search.d.ts +1 -1
  183. package/api/asynchronousSearch/search.js +3 -3
  184. package/api/asynchronousSearch/stats.d.ts +1 -1
  185. package/api/cat/aliases.d.ts +2 -2
  186. package/api/cat/aliases.js +9 -9
  187. package/api/cat/allPitSegments.d.ts +3 -3
  188. package/api/cat/allPitSegments.js +1 -1
  189. package/api/cat/allocation.d.ts +3 -3
  190. package/api/cat/allocation.js +11 -11
  191. package/api/cat/clusterManager.d.ts +2 -2
  192. package/api/cat/clusterManager.js +6 -6
  193. package/api/cat/count.d.ts +2 -2
  194. package/api/cat/count.js +4 -4
  195. package/api/cat/fielddata.d.ts +3 -3
  196. package/api/cat/fielddata.js +3 -3
  197. package/api/cat/health.d.ts +2 -2
  198. package/api/cat/health.js +2 -2
  199. package/api/cat/indices.d.ts +3 -3
  200. package/api/cat/indices.js +8 -8
  201. package/api/cat/master.d.ts +2 -2
  202. package/api/cat/master.js +2 -2
  203. package/api/cat/nodeattrs.d.ts +2 -2
  204. package/api/cat/nodeattrs.js +2 -2
  205. package/api/cat/nodes.d.ts +3 -3
  206. package/api/cat/nodes.js +2 -2
  207. package/api/cat/pendingTasks.d.ts +2 -2
  208. package/api/cat/pendingTasks.js +2 -2
  209. package/api/cat/pitSegments.d.ts +4 -4
  210. package/api/cat/pitSegments.js +1 -1
  211. package/api/cat/plugins.d.ts +2 -2
  212. package/api/cat/plugins.js +2 -2
  213. package/api/cat/recovery.d.ts +3 -3
  214. package/api/cat/recovery.js +3 -3
  215. package/api/cat/repositories.d.ts +2 -2
  216. package/api/cat/repositories.js +2 -2
  217. package/api/cat/segmentReplication.d.ts +3 -3
  218. package/api/cat/segmentReplication.js +6 -6
  219. package/api/cat/segments.d.ts +3 -3
  220. package/api/cat/segments.js +4 -4
  221. package/api/cat/shards.d.ts +3 -3
  222. package/api/cat/shards.js +4 -4
  223. package/api/cat/snapshots.d.ts +2 -2
  224. package/api/cat/snapshots.js +4 -4
  225. package/api/cat/tasks.d.ts +2 -2
  226. package/api/cat/tasks.js +1 -1
  227. package/api/cat/templates.d.ts +2 -2
  228. package/api/cat/templates.js +3 -3
  229. package/api/cat/threadPool.d.ts +2 -2
  230. package/api/cat/threadPool.js +3 -3
  231. package/api/cluster/allocationExplain.d.ts +4 -4
  232. package/api/cluster/allocationExplain.js +2 -2
  233. package/api/cluster/deleteComponentTemplate.d.ts +1 -1
  234. package/api/cluster/deleteComponentTemplate.js +1 -1
  235. package/api/cluster/deleteDecommissionAwareness.d.ts +1 -1
  236. package/api/cluster/deleteVotingConfigExclusions.js +1 -1
  237. package/api/cluster/deleteWeightedRouting.d.ts +1 -1
  238. package/api/cluster/existsComponentTemplate.d.ts +1 -1
  239. package/api/cluster/existsComponentTemplate.js +2 -2
  240. package/api/cluster/getComponentTemplate.d.ts +3 -3
  241. package/api/cluster/getComponentTemplate.js +3 -3
  242. package/api/cluster/getDecommissionAwareness.d.ts +1 -1
  243. package/api/cluster/getSettings.d.ts +2 -2
  244. package/api/cluster/getSettings.js +1 -1
  245. package/api/cluster/getWeightedRouting.d.ts +1 -1
  246. package/api/cluster/health.d.ts +2 -2
  247. package/api/cluster/health.js +8 -8
  248. package/api/cluster/pendingTasks.d.ts +3 -3
  249. package/api/cluster/pendingTasks.js +2 -2
  250. package/api/cluster/postVotingConfigExclusions.d.ts +1 -1
  251. package/api/cluster/postVotingConfigExclusions.js +2 -2
  252. package/api/cluster/putComponentTemplate.d.ts +2 -2
  253. package/api/cluster/putComponentTemplate.js +2 -2
  254. package/api/cluster/putDecommissionAwareness.d.ts +1 -1
  255. package/api/cluster/putSettings.d.ts +3 -3
  256. package/api/cluster/putSettings.js +1 -1
  257. package/api/cluster/putWeightedRouting.d.ts +1 -1
  258. package/api/cluster/remoteInfo.d.ts +1 -1
  259. package/api/cluster/reroute.d.ts +5 -5
  260. package/api/cluster/reroute.js +4 -4
  261. package/api/cluster/state.d.ts +2 -2
  262. package/api/cluster/state.js +8 -8
  263. package/api/cluster/stats.d.ts +4 -2
  264. package/api/cluster/stats.js +15 -2
  265. package/api/danglingIndices/deleteDanglingIndex.d.ts +1 -1
  266. package/api/danglingIndices/deleteDanglingIndex.js +4 -4
  267. package/api/danglingIndices/importDanglingIndex.d.ts +1 -1
  268. package/api/danglingIndices/importDanglingIndex.js +4 -4
  269. package/api/danglingIndices/listDanglingIndices.d.ts +2 -2
  270. package/api/danglingIndices/listDanglingIndices.js +1 -1
  271. package/api/flowFramework/_api.js +12 -0
  272. package/api/flowFramework/create.d.ts +7 -6
  273. package/api/flowFramework/create.js +3 -2
  274. package/api/flowFramework/delete.d.ts +3 -2
  275. package/api/flowFramework/deprovision.d.ts +31 -0
  276. package/api/flowFramework/deprovision.js +50 -0
  277. package/api/flowFramework/get.d.ts +3 -2
  278. package/api/flowFramework/getStatus.d.ts +31 -0
  279. package/api/flowFramework/getStatus.js +50 -0
  280. package/api/flowFramework/getSteps.d.ts +30 -0
  281. package/api/flowFramework/getSteps.js +47 -0
  282. package/api/flowFramework/provision.d.ts +31 -0
  283. package/api/flowFramework/provision.js +50 -0
  284. package/api/flowFramework/search.d.ts +30 -0
  285. package/api/flowFramework/search.js +47 -0
  286. package/api/flowFramework/searchState.d.ts +30 -0
  287. package/api/flowFramework/searchState.js +47 -0
  288. package/api/flowFramework/update.d.ts +8 -4
  289. package/api/flowFramework/update.js +4 -0
  290. package/api/index.d.ts +108 -6
  291. package/api/indices/addBlock.d.ts +2 -2
  292. package/api/indices/addBlock.js +6 -6
  293. package/api/indices/analyze.d.ts +3 -3
  294. package/api/indices/analyze.js +1 -1
  295. package/api/indices/clearCache.d.ts +1 -1
  296. package/api/indices/clearCache.js +5 -5
  297. package/api/indices/clone.d.ts +3 -3
  298. package/api/indices/clone.js +2 -2
  299. package/api/indices/close.d.ts +2 -2
  300. package/api/indices/close.js +2 -2
  301. package/api/indices/create.d.ts +4 -4
  302. package/api/indices/create.js +1 -1
  303. package/api/indices/createDataStream.d.ts +1 -1
  304. package/api/indices/dataStreamsStats.d.ts +6 -6
  305. package/api/indices/dataStreamsStats.js +1 -1
  306. package/api/indices/delete.d.ts +1 -1
  307. package/api/indices/delete.js +3 -3
  308. package/api/indices/deleteAlias.d.ts +1 -1
  309. package/api/indices/deleteAlias.js +2 -2
  310. package/api/indices/deleteDataStream.d.ts +1 -1
  311. package/api/indices/deleteIndexTemplate.d.ts +1 -1
  312. package/api/indices/deleteIndexTemplate.js +1 -1
  313. package/api/indices/deleteTemplate.d.ts +1 -1
  314. package/api/indices/deleteTemplate.js +1 -1
  315. package/api/indices/exists.d.ts +1 -1
  316. package/api/indices/exists.js +2 -2
  317. package/api/indices/existsAlias.d.ts +1 -1
  318. package/api/indices/existsAlias.js +4 -4
  319. package/api/indices/existsIndexTemplate.d.ts +1 -1
  320. package/api/indices/existsIndexTemplate.js +1 -1
  321. package/api/indices/existsTemplate.d.ts +1 -1
  322. package/api/indices/existsTemplate.js +1 -1
  323. package/api/indices/flush.d.ts +1 -1
  324. package/api/indices/flush.js +4 -4
  325. package/api/indices/forcemerge.d.ts +1 -1
  326. package/api/indices/forcemerge.js +6 -6
  327. package/api/indices/get.d.ts +1 -1
  328. package/api/indices/get.js +9 -9
  329. package/api/indices/getAlias.d.ts +1 -1
  330. package/api/indices/getAlias.js +3 -3
  331. package/api/indices/getDataStream.d.ts +2 -2
  332. package/api/indices/getDataStream.js +1 -1
  333. package/api/indices/getFieldMapping.d.ts +1 -1
  334. package/api/indices/getFieldMapping.js +3 -3
  335. package/api/indices/getIndexTemplate.d.ts +2 -2
  336. package/api/indices/getIndexTemplate.js +4 -4
  337. package/api/indices/getMapping.d.ts +1 -1
  338. package/api/indices/getMapping.js +5 -5
  339. package/api/indices/getSettings.d.ts +1 -1
  340. package/api/indices/getSettings.js +6 -6
  341. package/api/indices/getTemplate.d.ts +1 -1
  342. package/api/indices/getTemplate.js +2 -2
  343. package/api/indices/getUpgrade.d.ts +3 -2
  344. package/api/indices/getUpgrade.js +6 -6
  345. package/api/indices/open.d.ts +1 -1
  346. package/api/indices/open.js +4 -4
  347. package/api/indices/putAlias.d.ts +2 -2
  348. package/api/indices/putAlias.js +3 -3
  349. package/api/indices/putIndexTemplate.d.ts +2 -2
  350. package/api/indices/putIndexTemplate.js +1 -1
  351. package/api/indices/putMapping.d.ts +2 -3
  352. package/api/indices/putMapping.js +3 -3
  353. package/api/indices/putSettings.d.ts +1 -1
  354. package/api/indices/putSettings.js +5 -5
  355. package/api/indices/putTemplate.d.ts +4 -4
  356. package/api/indices/putTemplate.js +2 -2
  357. package/api/indices/recovery.d.ts +1 -1
  358. package/api/indices/recovery.js +2 -2
  359. package/api/indices/refresh.d.ts +1 -1
  360. package/api/indices/refresh.js +4 -4
  361. package/api/indices/resolveIndex.d.ts +2 -2
  362. package/api/indices/resolveIndex.js +2 -2
  363. package/api/indices/rollover.d.ts +4 -4
  364. package/api/indices/rollover.js +2 -2
  365. package/api/indices/segments.d.ts +2 -2
  366. package/api/indices/segments.js +3 -3
  367. package/api/indices/shardStores.d.ts +3 -3
  368. package/api/indices/shardStores.js +5 -5
  369. package/api/indices/shrink.d.ts +3 -3
  370. package/api/indices/shrink.js +2 -2
  371. package/api/indices/simulateIndexTemplate.d.ts +2 -4
  372. package/api/indices/simulateIndexTemplate.js +1 -3
  373. package/api/indices/simulateTemplate.d.ts +2 -2
  374. package/api/indices/simulateTemplate.js +3 -3
  375. package/api/indices/split.d.ts +3 -3
  376. package/api/indices/split.js +2 -2
  377. package/api/indices/stats.d.ts +3 -3
  378. package/api/indices/stats.js +7 -7
  379. package/api/indices/updateAliases.d.ts +2 -2
  380. package/api/indices/updateAliases.js +1 -1
  381. package/api/indices/upgrade.d.ts +4 -2
  382. package/api/indices/upgrade.js +8 -7
  383. package/api/indices/validateQuery.d.ts +4 -4
  384. package/api/indices/validateQuery.js +3 -3
  385. package/api/ingest/deletePipeline.d.ts +1 -1
  386. package/api/ingest/deletePipeline.js +1 -1
  387. package/api/ingest/getPipeline.d.ts +1 -1
  388. package/api/ingest/getPipeline.js +2 -2
  389. package/api/ingest/processorGrok.d.ts +4 -2
  390. package/api/ingest/processorGrok.js +3 -1
  391. package/api/ingest/putPipeline.d.ts +2 -2
  392. package/api/ingest/putPipeline.js +1 -1
  393. package/api/ingest/simulate.d.ts +4 -4
  394. package/api/ingest/simulate.js +1 -1
  395. package/api/{_types/indices.data_streams_stats.d.ts → insights/_api.js} +9 -7
  396. package/api/insights/topQueries.d.ts +30 -0
  397. package/api/insights/topQueries.js +48 -0
  398. package/api/ism/_api.js +61 -0
  399. package/api/ism/addPolicy.d.ts +32 -0
  400. package/api/ism/addPolicy.js +49 -0
  401. package/api/ism/changePolicy.d.ts +32 -0
  402. package/api/ism/changePolicy.js +49 -0
  403. package/api/ism/deletePolicy.d.ts +30 -0
  404. package/api/ism/deletePolicy.js +49 -0
  405. package/api/ism/existsPolicy.d.ts +29 -0
  406. package/api/ism/existsPolicy.js +49 -0
  407. package/api/ism/explainPolicy.d.ts +34 -0
  408. package/api/ism/explainPolicy.js +49 -0
  409. package/api/ism/getPolicies.d.ts +28 -0
  410. package/api/ism/getPolicies.js +45 -0
  411. package/api/ism/getPolicy.d.ts +30 -0
  412. package/api/ism/getPolicy.js +49 -0
  413. package/api/ism/putPolicies.d.ts +34 -0
  414. package/api/ism/putPolicies.js +51 -0
  415. package/api/ism/putPolicy.d.ts +34 -0
  416. package/api/ism/putPolicy.js +52 -0
  417. package/api/ism/refreshSearchAnalyzers.d.ts +31 -0
  418. package/api/ism/refreshSearchAnalyzers.js +49 -0
  419. package/api/ism/removePolicy.d.ts +31 -0
  420. package/api/ism/removePolicy.js +48 -0
  421. package/api/ism/retryIndex.d.ts +32 -0
  422. package/api/ism/retryIndex.js +49 -0
  423. package/api/knn/deleteModel.d.ts +2 -1
  424. package/api/knn/searchModels.d.ts +4 -3
  425. package/api/knn/searchModels.js +10 -10
  426. package/api/knn/stats.d.ts +4 -3
  427. package/api/knn/stats.js +1 -1
  428. package/api/knn/trainModel.d.ts +5 -12
  429. package/api/knn/trainModel.js +5 -5
  430. package/api/knn/warmup.d.ts +2 -1
  431. package/api/knn/warmup.js +1 -1
  432. package/api/{_types/snapshot.get.d.ts → list/_api.js} +9 -6
  433. package/api/list/help.d.ts +27 -0
  434. package/api/list/help.js +45 -0
  435. package/api/list/indices.d.ts +51 -0
  436. package/api/list/indices.js +65 -0
  437. package/api/list/shards.d.ts +47 -0
  438. package/api/list/shards.js +61 -0
  439. package/api/ml/_api.js +12 -0
  440. package/api/ml/createConnector.d.ts +43 -0
  441. package/api/ml/createConnector.js +47 -0
  442. package/api/ml/deleteAgent.d.ts +30 -0
  443. package/api/ml/deleteAgent.js +49 -0
  444. package/api/ml/deleteConnector.d.ts +30 -0
  445. package/api/ml/deleteConnector.js +49 -0
  446. package/api/ml/deleteModel.d.ts +1 -1
  447. package/api/ml/deleteModelGroup.d.ts +1 -1
  448. package/api/ml/deleteTask.d.ts +1 -1
  449. package/api/ml/deployModel.d.ts +1 -1
  450. package/api/ml/registerAgents.d.ts +43 -0
  451. package/api/ml/registerAgents.js +47 -0
  452. package/api/ml/registerModel.d.ts +2 -2
  453. package/api/ml/registerModelGroup.d.ts +1 -1
  454. package/api/ml/searchModels.d.ts +6 -1
  455. package/api/nodes/hotThreads.d.ts +1 -1
  456. package/api/nodes/hotThreads.js +2 -2
  457. package/api/nodes/info.d.ts +1 -1
  458. package/api/nodes/info.js +3 -3
  459. package/api/nodes/reloadSecureSettings.d.ts +2 -2
  460. package/api/nodes/reloadSecureSettings.js +2 -2
  461. package/api/nodes/stats.d.ts +1 -1
  462. package/api/nodes/stats.js +5 -5
  463. package/api/nodes/usage.d.ts +1 -1
  464. package/api/nodes/usage.js +1 -1
  465. package/api/notifications/createConfig.d.ts +1 -1
  466. package/api/notifications/getConfigs.d.ts +3 -1
  467. package/api/notifications/getConfigs.js +2 -0
  468. package/api/notifications/listChannels.d.ts +1 -1
  469. package/api/notifications/listFeatures.d.ts +1 -1
  470. package/api/notifications/sendTest.d.ts +1 -1
  471. package/api/notifications/updateConfig.d.ts +1 -1
  472. package/api/observability/createObject.d.ts +1 -1
  473. package/api/observability/deleteObject.d.ts +1 -1
  474. package/api/observability/deleteObjects.d.ts +1 -1
  475. package/api/observability/getLocalstats.d.ts +1 -1
  476. package/api/observability/getLocalstats.js +1 -1
  477. package/api/observability/updateObject.d.ts +1 -1
  478. package/api/ppl/explain.js +1 -1
  479. package/api/ppl/getStats.js +1 -1
  480. package/api/ppl/postStats.js +1 -1
  481. package/api/ppl/query.js +1 -1
  482. package/api/remoteStore/restore.d.ts +3 -3
  483. package/api/replication/_api.js +48 -0
  484. package/api/replication/autofollowStats.d.ts +28 -0
  485. package/api/replication/autofollowStats.js +45 -0
  486. package/api/replication/createReplicationRule.d.ts +31 -0
  487. package/api/replication/createReplicationRule.js +47 -0
  488. package/api/replication/deleteReplicationRule.d.ts +31 -0
  489. package/api/replication/deleteReplicationRule.js +47 -0
  490. package/api/replication/followerStats.d.ts +28 -0
  491. package/api/replication/followerStats.js +45 -0
  492. package/api/replication/leaderStats.d.ts +28 -0
  493. package/api/replication/leaderStats.js +45 -0
  494. package/api/replication/pause.d.ts +33 -0
  495. package/api/replication/pause.js +50 -0
  496. package/api/replication/resume.d.ts +33 -0
  497. package/api/replication/resume.js +50 -0
  498. package/api/replication/start.d.ts +32 -0
  499. package/api/replication/start.js +50 -0
  500. package/api/replication/status.d.ts +31 -0
  501. package/api/replication/status.js +49 -0
  502. package/api/replication/stop.d.ts +33 -0
  503. package/api/replication/stop.js +50 -0
  504. package/api/replication/updateSettings.d.ts +32 -0
  505. package/api/replication/updateSettings.js +50 -0
  506. package/api/rollups/delete.d.ts +2 -2
  507. package/api/rollups/explain.d.ts +1 -1
  508. package/api/rollups/get.d.ts +1 -1
  509. package/api/rollups/put.d.ts +1 -1
  510. package/api/rollups/start.d.ts +2 -2
  511. package/api/rollups/stop.d.ts +2 -2
  512. package/api/searchPipeline/delete.d.ts +2 -2
  513. package/api/searchPipeline/get.d.ts +1 -1
  514. package/api/searchPipeline/get.js +1 -1
  515. package/api/searchPipeline/put.d.ts +2 -2
  516. package/api/security/_api.js +3 -0
  517. package/api/security/createAllowlist.js +1 -1
  518. package/api/security/generateUserTokenLegacy.d.ts +29 -0
  519. package/api/security/generateUserTokenLegacy.js +49 -0
  520. package/api/security/getAllCertificates.d.ts +1 -1
  521. package/api/security/getDistinguishedName.d.ts +1 -1
  522. package/api/security/getDistinguishedName.js +1 -1
  523. package/api/security/getDistinguishedNames.js +1 -1
  524. package/api/security/getNodeCertificates.d.ts +1 -1
  525. package/api/security/getSslinfo.js +1 -1
  526. package/api/security/health.js +1 -1
  527. package/api/security/patchConfiguration.js +1 -1
  528. package/api/security/patchDistinguishedName.d.ts +1 -1
  529. package/api/security/patchDistinguishedName.js +2 -2
  530. package/api/security/updateConfiguration.js +1 -1
  531. package/api/security/updateDistinguishedName.js +1 -1
  532. package/api/security/validate.js +1 -1
  533. package/api/sm/_api.js +49 -0
  534. package/api/sm/createPolicy.d.ts +31 -0
  535. package/api/sm/createPolicy.js +50 -0
  536. package/api/sm/deletePolicy.d.ts +30 -0
  537. package/api/sm/deletePolicy.js +49 -0
  538. package/api/sm/explainPolicy.d.ts +30 -0
  539. package/api/sm/explainPolicy.js +49 -0
  540. package/api/sm/getPolicies.d.ts +34 -0
  541. package/api/sm/getPolicies.js +51 -0
  542. package/api/sm/getPolicy.d.ts +30 -0
  543. package/api/sm/getPolicy.js +49 -0
  544. package/api/sm/startPolicy.d.ts +31 -0
  545. package/api/sm/startPolicy.js +49 -0
  546. package/api/sm/stopPolicy.d.ts +31 -0
  547. package/api/sm/stopPolicy.js +49 -0
  548. package/api/sm/updatePolicy.d.ts +33 -0
  549. package/api/sm/updatePolicy.js +54 -0
  550. package/api/snapshot/cleanupRepository.d.ts +2 -2
  551. package/api/snapshot/cleanupRepository.js +1 -1
  552. package/api/snapshot/clone.d.ts +2 -2
  553. package/api/snapshot/clone.js +2 -2
  554. package/api/snapshot/create.d.ts +3 -3
  555. package/api/snapshot/create.js +1 -1
  556. package/api/snapshot/createRepository.d.ts +2 -2
  557. package/api/snapshot/createRepository.js +1 -1
  558. package/api/snapshot/delete.d.ts +1 -1
  559. package/api/snapshot/delete.js +1 -1
  560. package/api/snapshot/deleteRepository.d.ts +1 -1
  561. package/api/snapshot/deleteRepository.js +1 -1
  562. package/api/snapshot/get.d.ts +3 -7
  563. package/api/snapshot/get.js +4 -4
  564. package/api/snapshot/getRepository.d.ts +1 -1
  565. package/api/snapshot/getRepository.js +2 -2
  566. package/api/snapshot/restore.d.ts +9 -5
  567. package/api/snapshot/restore.js +1 -1
  568. package/api/snapshot/status.d.ts +3 -3
  569. package/api/snapshot/status.js +3 -3
  570. package/api/snapshot/verifyRepository.d.ts +2 -2
  571. package/api/snapshot/verifyRepository.js +1 -1
  572. package/api/sql/close.d.ts +1 -1
  573. package/api/sql/close.js +5 -5
  574. package/api/sql/explain.d.ts +1 -1
  575. package/api/sql/explain.js +5 -5
  576. package/api/sql/getStats.js +1 -1
  577. package/api/sql/postStats.d.ts +1 -1
  578. package/api/sql/postStats.js +5 -5
  579. package/api/sql/query.d.ts +1 -1
  580. package/api/sql/query.js +5 -5
  581. package/api/sql/settings.d.ts +1 -1
  582. package/api/sql/settings.js +5 -5
  583. package/api/tasks/cancel.d.ts +1 -1
  584. package/api/tasks/cancel.js +1 -1
  585. package/api/tasks/get.d.ts +3 -3
  586. package/api/tasks/list.d.ts +1 -1
  587. package/api/transforms/delete.d.ts +3 -2
  588. package/api/transforms/explain.d.ts +1 -1
  589. package/api/transforms/get.d.ts +2 -2
  590. package/api/transforms/preview.d.ts +3 -1
  591. package/api/transforms/preview.js +4 -2
  592. package/api/transforms/put.d.ts +3 -3
  593. package/api/transforms/put.js +1 -1
  594. package/api/transforms/start.d.ts +1 -1
  595. package/api/transforms/stop.d.ts +1 -1
  596. package/api/utils.js +1 -1
  597. package/api/wlm/_api.js +37 -0
  598. package/api/wlm/createQueryGroup.d.ts +30 -0
  599. package/api/wlm/createQueryGroup.js +47 -0
  600. package/api/wlm/deleteQueryGroup.d.ts +31 -0
  601. package/api/wlm/deleteQueryGroup.js +49 -0
  602. package/api/wlm/getQueryGroup.d.ts +32 -0
  603. package/api/wlm/getQueryGroup.js +48 -0
  604. package/api/wlm/updateQueryGroup.d.ts +31 -0
  605. package/api/wlm/updateQueryGroup.js +50 -0
  606. package/index.js +0 -2
  607. package/lib/Client.d.ts +1 -1
  608. package/lib/Client.js +1 -1
  609. package/lib/Serializer.js +1 -1
  610. package/package.json +3 -3
@@ -15,8 +15,9 @@
15
15
  */
16
16
 
17
17
  import { ApiResponse } from '../../lib/Transport'
18
- import * as Global from '../_types/_global'
19
18
  import * as Common from '../_types/_common'
19
+ import * as Global from '../_types/_global'
20
+ import * as Transforms_Common from '../_types/transforms._common'
20
21
 
21
22
  export interface Transforms_Delete_Request extends Global.Params {
22
23
  id: Common.Id;
@@ -26,5 +27,5 @@ export interface Transforms_Delete_Response extends ApiResponse {
26
27
  body: Transforms_Delete_ResponseBody;
27
28
  }
28
29
 
29
- export type Transforms_Delete_ResponseBody = Record<string, any>
30
+ export type Transforms_Delete_ResponseBody = Transforms_Common.DeleteTransformsResponse
30
31
 
@@ -15,8 +15,8 @@
15
15
  */
16
16
 
17
17
  import { ApiResponse } from '../../lib/Transport'
18
- import * as Global from '../_types/_global'
19
18
  import * as Common from '../_types/_common'
19
+ import * as Global from '../_types/_global'
20
20
  import * as Transforms_Common from '../_types/transforms._common'
21
21
 
22
22
  export interface Transforms_Explain_Request extends Global.Params {
@@ -15,8 +15,8 @@
15
15
  */
16
16
 
17
17
  import { ApiResponse } from '../../lib/Transport'
18
- import * as Global from '../_types/_global'
19
18
  import * as Common from '../_types/_common'
19
+ import * as Global from '../_types/_global'
20
20
  import * as Transforms_Common from '../_types/transforms._common'
21
21
 
22
22
  export interface Transforms_Get_Request extends Global.Params {
@@ -27,5 +27,5 @@ export interface Transforms_Get_Response extends ApiResponse {
27
27
  body: Transforms_Get_ResponseBody;
28
28
  }
29
29
 
30
- export type Transforms_Get_ResponseBody = Transforms_Common.TransformEntity
30
+ export type Transforms_Get_ResponseBody = Transforms_Common.TransformResponse
31
31
 
@@ -18,7 +18,9 @@ import { ApiResponse } from '../../lib/Transport'
18
18
  import * as Global from '../_types/_global'
19
19
  import * as Transforms_Common from '../_types/transforms._common'
20
20
 
21
- export type Transforms_Preview_Request = Global.Params & Record<string, any>
21
+ export interface Transforms_Preview_Request extends Global.Params {
22
+ body?: Transforms_Common.TransformRequest;
23
+ }
22
24
 
23
25
  export interface Transforms_Preview_Response extends ApiResponse {
24
26
  body: Transforms_Preview_ResponseBody;
@@ -24,7 +24,9 @@ const { normalizeArguments } = require('../utils');
24
24
  *
25
25
  * @memberOf API-Transforms
26
26
  *
27
- * @param {object} [params] - (Unused)
27
+ * @param {object} [params]
28
+ * @param {object} [params.body]
29
+ *
28
30
  * @param {TransportRequestOptions} [options] - Options for {@link Transport#request}
29
31
  * @param {function} [callback] - Callback that handles errors and response
30
32
  *
@@ -36,7 +38,7 @@ function previewFunc(params, options, callback) {
36
38
  let { body, ...querystring } = params;
37
39
 
38
40
  const path = '/_plugins/_transform/_preview';
39
- const method = 'GET';
41
+ const method = 'POST';
40
42
  body = body || '';
41
43
 
42
44
  return this.transport.request({ method, path, querystring, body }, options, callback);
@@ -15,12 +15,12 @@
15
15
  */
16
16
 
17
17
  import { ApiResponse } from '../../lib/Transport'
18
+ import * as Common from '../_types/_common'
18
19
  import * as Global from '../_types/_global'
19
20
  import * as Transforms_Common from '../_types/transforms._common'
20
- import * as Common from '../_types/_common'
21
21
 
22
22
  export interface Transforms_Put_Request extends Global.Params {
23
- body?: Transforms_Common.Transform;
23
+ body?: Transforms_Common.TransformRequest;
24
24
  id: Common.Id;
25
25
  if_primary_term?: number;
26
26
  if_seq_no?: Common.SequenceNumber;
@@ -30,5 +30,5 @@ export interface Transforms_Put_Response extends ApiResponse {
30
30
  body: Transforms_Put_ResponseBody;
31
31
  }
32
32
 
33
- export type Transforms_Put_ResponseBody = Transforms_Common.TransformEntity
33
+ export type Transforms_Put_ResponseBody = Transforms_Common.TransformResponse
34
34
 
@@ -19,7 +19,7 @@
19
19
  const { normalizeArguments, parsePathParam, handleMissingParam } = require('../utils');
20
20
 
21
21
  /**
22
- * Create an index transform, or update a transform if if_seq_no and if_primary_term are provided.
22
+ * Create an index transform, or update a transform if `if_seq_no` and `if_primary_term` are provided.
23
23
  * <br/> See Also: {@link https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#create-a-transform-job - transforms.put}
24
24
  *
25
25
  * @memberOf API-Transforms
@@ -15,8 +15,8 @@
15
15
  */
16
16
 
17
17
  import { ApiResponse } from '../../lib/Transport'
18
- import * as Global from '../_types/_global'
19
18
  import * as Common from '../_types/_common'
19
+ import * as Global from '../_types/_global'
20
20
 
21
21
  export interface Transforms_Start_Request extends Global.Params {
22
22
  id: Common.Id;
@@ -15,8 +15,8 @@
15
15
  */
16
16
 
17
17
  import { ApiResponse } from '../../lib/Transport'
18
- import * as Global from '../_types/_global'
19
18
  import * as Common from '../_types/_common'
19
+ import * as Global from '../_types/_global'
20
20
 
21
21
  export interface Transforms_Stop_Request extends Global.Params {
22
22
  id: Common.Id;
package/api/utils.js CHANGED
@@ -35,7 +35,7 @@ const kConfigErr = Symbol('configuration error');
35
35
  function noop() {}
36
36
 
37
37
  function parsePathParam(param) {
38
- if (param == null) return null;
38
+ if (param == null || param === '') return null;
39
39
  return encodeURIComponent(param);
40
40
  }
41
41
 
@@ -0,0 +1,37 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ 'use strict';
18
+
19
+ /** @namespace API-Wlm */
20
+
21
+ function WlmApi(bindObj) {
22
+ this.createQueryGroup = require('./createQueryGroup').bind(bindObj);
23
+ this.deleteQueryGroup = require('./deleteQueryGroup').bind(bindObj);
24
+ this.getQueryGroup = require('./getQueryGroup').bind(bindObj);
25
+ this.updateQueryGroup = require('./updateQueryGroup').bind(bindObj);
26
+
27
+ // Deprecated: Use createQueryGroup instead.
28
+ this.create_query_group = require('./createQueryGroup').bind(bindObj);
29
+ // Deprecated: Use deleteQueryGroup instead.
30
+ this.delete_query_group = require('./deleteQueryGroup').bind(bindObj);
31
+ // Deprecated: Use getQueryGroup instead.
32
+ this.get_query_group = require('./getQueryGroup').bind(bindObj);
33
+ // Deprecated: Use updateQueryGroup instead.
34
+ this.update_query_group = require('./updateQueryGroup').bind(bindObj);
35
+ }
36
+
37
+ module.exports = WlmApi;
@@ -0,0 +1,30 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ import { ApiResponse } from '../../lib/Transport'
18
+ import * as Global from '../_types/_global'
19
+ import * as Wlm_Common from '../_types/wlm._common'
20
+
21
+ export interface Wlm_CreateQueryGroup_Request extends Global.Params {
22
+ body: Wlm_Common.QueryGroupCreate;
23
+ }
24
+
25
+ export interface Wlm_CreateQueryGroup_Response extends ApiResponse {
26
+ body: Wlm_CreateQueryGroup_ResponseBody;
27
+ }
28
+
29
+ export type Wlm_CreateQueryGroup_ResponseBody = Wlm_Common.QueryGroupResponse
30
+
@@ -0,0 +1,47 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ 'use strict';
18
+
19
+ const { normalizeArguments, handleMissingParam } = require('../utils');
20
+
21
+ /**
22
+ * Creates a new query group and sets the resource limits for the new query group.
23
+ * <br/> See Also: {@link undefined - wlm.create_query_group}
24
+ *
25
+ * @memberOf API-Wlm
26
+ *
27
+ * @param {object} params
28
+ * @param {object} params.body
29
+ *
30
+ * @param {TransportRequestOptions} [options] - Options for {@link Transport#request}
31
+ * @param {function} [callback] - Callback that handles errors and response
32
+ *
33
+ * @returns {{abort: function(), then: function(), catch: function()}|Promise<never>|*}
34
+ */
35
+ function createQueryGroupFunc(params, options, callback) {
36
+ [params, options, callback] = normalizeArguments(params, options, callback);
37
+ if (params.body == null) return handleMissingParam('body', this, callback);
38
+
39
+ let { body, ...querystring } = params;
40
+
41
+ const path = '/_wlm/query_group';
42
+ const method = 'PUT';
43
+
44
+ return this.transport.request({ method, path, querystring, body }, options, callback);
45
+ }
46
+
47
+ module.exports = createQueryGroupFunc;
@@ -0,0 +1,31 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ import { ApiResponse } from '../../lib/Transport'
18
+ import * as Global from '../_types/_global'
19
+
20
+ export interface Wlm_DeleteQueryGroup_Request extends Global.Params {
21
+ name: string;
22
+ }
23
+
24
+ export interface Wlm_DeleteQueryGroup_Response extends ApiResponse {
25
+ body: Wlm_DeleteQueryGroup_ResponseBody;
26
+ }
27
+
28
+ export type Wlm_DeleteQueryGroup_ResponseBody = {
29
+ acknowledged?: boolean;
30
+ }
31
+
@@ -0,0 +1,49 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ 'use strict';
18
+
19
+ const { normalizeArguments, parsePathParam, handleMissingParam } = require('../utils');
20
+
21
+ /**
22
+ * Deletes the specified query group.
23
+ * <br/> See Also: {@link undefined - wlm.delete_query_group}
24
+ *
25
+ * @memberOf API-Wlm
26
+ *
27
+ * @param {object} params
28
+ * @param {string} params.name - The name of the query group.
29
+ *
30
+ * @param {TransportRequestOptions} [options] - Options for {@link Transport#request}
31
+ * @param {function} [callback] - Callback that handles errors and response
32
+ *
33
+ * @returns {{abort: function(), then: function(), catch: function()}|Promise<never>|*}
34
+ */
35
+ function deleteQueryGroupFunc(params, options, callback) {
36
+ [params, options, callback] = normalizeArguments(params, options, callback);
37
+ if (params.name == null) return handleMissingParam('name', this, callback);
38
+
39
+ let { body, name, ...querystring } = params;
40
+ name = parsePathParam(name);
41
+
42
+ const path = '/_wlm/query_group/' + name;
43
+ const method = 'DELETE';
44
+ body = body || '';
45
+
46
+ return this.transport.request({ method, path, querystring, body }, options, callback);
47
+ }
48
+
49
+ module.exports = deleteQueryGroupFunc;
@@ -0,0 +1,32 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ import { ApiResponse } from '../../lib/Transport'
18
+ import * as Global from '../_types/_global'
19
+ import * as Wlm_Common from '../_types/wlm._common'
20
+
21
+ export interface Wlm_GetQueryGroup_Request extends Global.Params {
22
+ name?: string;
23
+ }
24
+
25
+ export interface Wlm_GetQueryGroup_Response extends ApiResponse {
26
+ body: Wlm_GetQueryGroup_ResponseBody;
27
+ }
28
+
29
+ export type Wlm_GetQueryGroup_ResponseBody = {
30
+ query_groups?: Wlm_Common.QueryGroupResponse[];
31
+ }
32
+
@@ -0,0 +1,48 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ 'use strict';
18
+
19
+ const { normalizeArguments, parsePathParam } = require('../utils');
20
+
21
+ /**
22
+ * Retrieves the specified query group. If no query group is specified, all query groups in the cluster are retrieved.
23
+ * <br/> See Also: {@link undefined - wlm.get_query_group}
24
+ *
25
+ * @memberOf API-Wlm
26
+ *
27
+ * @param {object} [params]
28
+ * @param {string} [params.name] - The name of the query group.
29
+ *
30
+ * @param {TransportRequestOptions} [options] - Options for {@link Transport#request}
31
+ * @param {function} [callback] - Callback that handles errors and response
32
+ *
33
+ * @returns {{abort: function(), then: function(), catch: function()}|Promise<never>|*}
34
+ */
35
+ function getQueryGroupFunc(params, options, callback) {
36
+ [params, options, callback] = normalizeArguments(params, options, callback);
37
+
38
+ let { body, name, ...querystring } = params;
39
+ name = parsePathParam(name);
40
+
41
+ const path = ['/_wlm/query_group', name].filter(c => c != null).join('/');
42
+ const method = 'GET';
43
+ body = body || '';
44
+
45
+ return this.transport.request({ method, path, querystring, body }, options, callback);
46
+ }
47
+
48
+ module.exports = getQueryGroupFunc;
@@ -0,0 +1,31 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ import { ApiResponse } from '../../lib/Transport'
18
+ import * as Global from '../_types/_global'
19
+ import * as Wlm_Common from '../_types/wlm._common'
20
+
21
+ export interface Wlm_UpdateQueryGroup_Request extends Global.Params {
22
+ body: Wlm_Common.QueryGroupUpdate;
23
+ name: string;
24
+ }
25
+
26
+ export interface Wlm_UpdateQueryGroup_Response extends ApiResponse {
27
+ body: Wlm_UpdateQueryGroup_ResponseBody;
28
+ }
29
+
30
+ export type Wlm_UpdateQueryGroup_ResponseBody = Wlm_Common.QueryGroupResponse
31
+
@@ -0,0 +1,50 @@
1
+ /*
2
+ * Copyright OpenSearch Contributors
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ *
5
+ * The OpenSearch Contributors require contributions made to
6
+ * this file be licensed under the Apache-2.0 license or a
7
+ * compatible open source license.
8
+ *
9
+ */
10
+
11
+ /*
12
+ * This file was generated from the OpenSearch API Spec. Do NOT edit it
13
+ * manually. If you want to make changes, either update the spec or
14
+ * modify the API generator.
15
+ */
16
+
17
+ 'use strict';
18
+
19
+ const { normalizeArguments, parsePathParam, handleMissingParam } = require('../utils');
20
+
21
+ /**
22
+ * Updates the specified query group.
23
+ * <br/> See Also: {@link undefined - wlm.update_query_group}
24
+ *
25
+ * @memberOf API-Wlm
26
+ *
27
+ * @param {object} params
28
+ * @param {string} params.name - The name of the query group.
29
+ * @param {object} params.body
30
+ *
31
+ * @param {TransportRequestOptions} [options] - Options for {@link Transport#request}
32
+ * @param {function} [callback] - Callback that handles errors and response
33
+ *
34
+ * @returns {{abort: function(), then: function(), catch: function()}|Promise<never>|*}
35
+ */
36
+ function updateQueryGroupFunc(params, options, callback) {
37
+ [params, options, callback] = normalizeArguments(params, options, callback);
38
+ if (params.name == null) return handleMissingParam('name', this, callback);
39
+ if (params.body == null) return handleMissingParam('body', this, callback);
40
+
41
+ let { body, name, ...querystring } = params;
42
+ name = parsePathParam(name);
43
+
44
+ const path = '/_wlm/query_group/' + name;
45
+ const method = 'PUT';
46
+
47
+ return this.transport.request({ method, path, querystring, body }, options, callback);
48
+ }
49
+
50
+ module.exports = updateQueryGroupFunc;
package/index.js CHANGED
@@ -8,8 +8,6 @@
8
8
  *
9
9
  */
10
10
 
11
-
12
-
13
11
  /*
14
12
  * Licensed to Elasticsearch B.V. under one or more contributor
15
13
  * license agreements. See the NOTICE file distributed with
package/lib/Client.d.ts CHANGED
@@ -10,7 +10,7 @@
10
10
 
11
11
  import { ConnectionOptions as TlsConnectionOptions } from 'tls';
12
12
  import { URL } from 'url';
13
- import OpenSearchAPI from '../api/OpenSearchAPI';
13
+ import OpenSearchAPI from '../api/OpenSearchApi';
14
14
  import Serializer from './Serializer';
15
15
  import Helpers from './Helpers';
16
16
  import Connection, { AgentOptions, agentFn } from './Connection';
package/lib/Client.js CHANGED
@@ -46,7 +46,7 @@ const kChild = Symbol('opensearchjs-child');
46
46
  const kExtensions = Symbol('opensearchjs-extensions');
47
47
  const kEventEmitter = Symbol('opensearchjs-event-emitter');
48
48
 
49
- const OpenSearchAPI = require('../api/OpenSearchAPI');
49
+ const OpenSearchAPI = require('../api/OpenSearchApi');
50
50
 
51
51
  class Client extends OpenSearchAPI {
52
52
  constructor(opts = {}) {
package/lib/Serializer.js CHANGED
@@ -101,7 +101,7 @@ class Serializer {
101
101
  if (
102
102
  numeralsAreNumbers &&
103
103
  typeof val === 'number' &&
104
- (val < Number.MAX_SAFE_INTEGER || val > Number.MAX_SAFE_INTEGER)
104
+ (val < Number.MIN_SAFE_INTEGER || val > Number.MAX_SAFE_INTEGER)
105
105
  ) {
106
106
  numeralsAreNumbers = false;
107
107
  }
package/package.json CHANGED
@@ -36,7 +36,7 @@
36
36
  "LICENSE.txt"
37
37
  ],
38
38
  "homepage": "https://www.opensearch.org/",
39
- "version": "3.0.0-beta.7",
39
+ "version": "3.0.0-beta.9",
40
40
  "versionCanary": "7.10.0-canary.6",
41
41
  "keywords": [
42
42
  "opensearch",
@@ -108,7 +108,7 @@
108
108
  "aws4": "^1.11.0",
109
109
  "debug": "^4.3.1",
110
110
  "hpagent": "^1.2.0",
111
- "json11": "^1.1.2",
111
+ "json11": "^2.0.0",
112
112
  "ms": "^2.1.3",
113
113
  "secure-json-parse": "^2.4.0"
114
114
  },
@@ -124,7 +124,7 @@
124
124
  "url": "https://github.com/opensearch-project/opensearch-js/issues"
125
125
  },
126
126
  "engines": {
127
- "node": ">=18",
127
+ "node": ">=14",
128
128
  "yarn": "^1.22.10"
129
129
  },
130
130
  "tsd": {