diff --git a/go.mod b/go.mod index d2fadc4d45..7e657d01b9 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/opencloud-eu/opencloud -go 1.25.8 +go 1.25.9 require ( dario.cat/mergo v1.0.2 @@ -65,7 +65,7 @@ require ( github.com/opencloud-eu/icap-client v0.0.0-20250930132611-28a2afe62d89 github.com/opencloud-eu/libre-graph-api-go v1.0.8-0.20260310090739-853d972b282d github.com/opencloud-eu/reva/v2 v2.48.0 - github.com/opensearch-project/opensearch-go/v4 v4.6.0 + github.com/opensearch-project/opensearch-go/v4 v4.7.3 github.com/orcaman/concurrent-map v1.0.0 github.com/pkg/errors v0.9.1 github.com/pkg/xattr v0.4.12 @@ -384,7 +384,7 @@ require ( go.uber.org/zap v1.27.0 // indirect go.yaml.in/yaml/v2 v2.4.4 // indirect go.yaml.in/yaml/v3 v3.0.4 // indirect - golang.org/x/mod v0.37.0 // indirect + golang.org/x/mod v0.38.0 // indirect golang.org/x/sys v0.47.0 // indirect golang.org/x/time v0.15.0 // indirect golang.org/x/tools v0.47.0 // indirect diff --git a/go.sum b/go.sum index e3518668b1..35180c6b48 100644 --- a/go.sum +++ b/go.sum @@ -950,8 +950,8 @@ github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8 github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.1.1 h1:y0fUlFfIZhPF1W537XOLg0/fcx6zcHCJwooC2xJA040= github.com/opencontainers/image-spec v1.1.1/go.mod h1:qpqAh3Dmcf36wStyyWU+kCeDgrGnAve2nCC8+7h8Q0M= -github.com/opensearch-project/opensearch-go/v4 v4.6.0 h1:Ac8aLtDSmLEyOmv0r1qhQLw3b4vcUhE42NE9k+Z4cRc= -github.com/opensearch-project/opensearch-go/v4 v4.6.0/go.mod h1:3iZtb4SNt3IzaxavKq0dURh1AmtVgYW71E4XqmYnIiQ= +github.com/opensearch-project/opensearch-go/v4 v4.7.3 h1:JzETy7bYnnSDj4gueUh8t4EYBhs9rhKsgeVsoul77rA= +github.com/opensearch-project/opensearch-go/v4 v4.7.3/go.mod h1:+iikkyLrVC8ZvyfKv2sua1Ze1LbpWL7eZe4IkHqNGtg= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+1B0VhjKrZUs= github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc= @@ -1235,8 +1235,8 @@ github.com/vmihailenco/msgpack/v5 v5.4.1/go.mod h1:GaZTsDaehaPpQVyxrf5mtQlH+pc21 github.com/vmihailenco/tagparser/v2 v2.0.0 h1:y09buUbR+b5aycVFQs/g70pqKVZNBmxwAhO7/IwNM9g= github.com/vmihailenco/tagparser/v2 v2.0.0/go.mod h1:Wri+At7QHww0WTrCBeu4J6bNtoV6mEfg5OIWRZA9qds= github.com/vultr/govultr/v2 v2.0.0/go.mod h1:2PsEeg+gs3p/Fo5Pw8F9mv+DUBEOlrNZ8GmCTGmhOhs= -github.com/wI2L/jsondiff v0.7.0 h1:1lH1G37GhBPqCfp/lrs91rf/2j3DktX6qYAKZkLuCQQ= -github.com/wI2L/jsondiff v0.7.0/go.mod h1:KAEIojdQq66oJiHhDyQez2x+sRit0vIzC9KeK0yizxM= +github.com/wI2L/jsondiff v0.7.1 h1:Fg9+yj+1/x3UtPBJhR91TKEzRkrEEWcAcLbg9dzEaNM= +github.com/wI2L/jsondiff v0.7.1/go.mod h1:yAt2W7U6Jd4HK0RA8DGSGk0zDtfEtOUUJVnH/xICpjo= github.com/wk8/go-ordered-map v1.0.0 h1:BV7z+2PaK8LTSd/mWgY12HyMAo5CEgkHqbkVq2thqr8= github.com/wk8/go-ordered-map v1.0.0/go.mod h1:9ZIbRunKbuvfPKyBP1SIKLcXNlv74YCOZ3t3VTS6gRk= github.com/xanzy/ssh-agent v0.3.3 h1:+/15pJfg/RsTxqYcX6fHqOXZwwMP+2VyYWJeWM2qQFM= @@ -1393,8 +1393,8 @@ golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.37.0 h1:vF1DjpVEshcIqoEaauuHebaLk1O1forxjxBaVn884JQ= -golang.org/x/mod v0.37.0/go.mod h1:m8S8VeM9r4dzDwjrKO0a1sZP3YjeMamRRlD+fmR2Q/0= +golang.org/x/mod v0.38.0 h1:MECBjubtXD7yj4HrhIUcywNaGeNVUdfVnxmPajOk4yk= +golang.org/x/mod v0.38.0/go.mod h1:V6Xz0pq8TQ3dGqVQ1FVHuelZpAL0uNhSkk9ogYP3c40= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/.codecov.yml b/vendor/github.com/opensearch-project/opensearch-go/v4/.codecov.yml index 7b390d3a0e..b8f5aa9b5c 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/.codecov.yml +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/.codecov.yml @@ -11,5 +11,29 @@ coverage: status: project: default: - threshold: 5% # allow 5% coverage decrease + target: auto + threshold: 5% + core: + paths: + - "opensearch*.go" + - "opensearchtransport/" + - "opensearchutil/" + - "signer/" + target: 80% + threshold: 2% + path: + paths: + - "internal/path/" + target: 95% + threshold: 2% + opensearchapi: + paths: + - "opensearchapi/" + target: 14% + threshold: 2% + opensearchapiv5: + paths: + - "v5preview/opensearchapi/" + target: 25% + threshold: 5% patch: off diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/.gitignore b/vendor/github.com/opensearch-project/opensearch-go/v4/.gitignore index 8c2fd150ab..393d5aa2e0 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/.gitignore +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/.gitignore @@ -1,9 +1,17 @@ tmp/ *.test +coverage.out +test-*.log # editors .idea .vscode bin/ -.DS_Store \ No newline at end of file +.DS_Store +# Admin certificates for testing +admin.pem +admin.key + +# Compiled generator binaries +cmd/osgen/osgen diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/.golangci.yml b/vendor/github.com/opensearch-project/opensearch-go/v4/.golangci.yml index 78cbd90e63..3b28a9e784 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/.golangci.yml +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/.golangci.yml @@ -29,7 +29,7 @@ linters: - godox - goheader - gomoddirectives - - gomodguard + - gomodguard_v2 - goprintffuncname - gosec - govet @@ -42,6 +42,7 @@ linters: - makezero - mirror - misspell + - modernize - musttag - nakedret - nestif @@ -60,6 +61,7 @@ linters: - sqlclosecheck - staticcheck - tagalign + - testifylint - testpackage - thelper - tparallel @@ -106,6 +108,8 @@ linters: - sayRepetitiveInsteadOfStutters severity: error disabled: false + testifylint: + enable-all: true unparam: check-exported: true exclusions: @@ -123,7 +127,14 @@ linters: - gochecknoinits - goconst - noctx - path: (_test\.go|internal/) + path: (_test\.go|internal/|opensearchtransport/testutil/) + # cmd/osgen is a code-gen tool that uses many short, repeated literal + # strings as identifiers/keywords/import paths in template input. Most + # would not benefit from extraction to consts; skip goconst here. + # TODO: revisit goconst extraction in cmd/osgen. + - linters: + - goconst + path: cmd/osgen/ - linters: - gosec path: _test\.go @@ -141,7 +152,7 @@ linters: path: -params\.go - linters: - errcheck - text: Error return value of `debugLogger.Logf` is not checked + text: Error return value of `dl.Logf` is not checked - linters: - errcheck - gochecknoglobals @@ -151,7 +162,13 @@ linters: path: opensearchtransport/opensearchtransport.go - linters: - dupl - path: (-params\.go|api_indices|api_dangling\.go|api_point_in_time\.go|rethrottle\.go|api_cat-.*\.go|plugins/security/api_\w+.go|plugins/security/api_.*-patch.go) + path: (-params\.go|api_indices|api_dangling\.go|api_point_in_time\.go|rethrottle\.go|api_cat-.*\.go|plugins/security/api_\w+.go|plugins/security/api_.*-patch.go|_gen\.go) + # Generated code emits long lines from upstream spec descriptions, table + # rows, and inline struct literals that lose readability if wrapped at the + # template level. + - linters: + - lll + path: _integ_gen_test\.go|internal/path/builders_gen(_test)?\.go|v5preview/opensearchapi/.*_gen\.go paths: - third_party$ - builtin$ diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/CHANGELOG.md b/vendor/github.com/opensearch-project/opensearch-go/v4/CHANGELOG.md index 6d8e66b4eb..d960510d24 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/CHANGELOG.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/CHANGELOG.md @@ -2,21 +2,325 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) +## [4.7.3] + +### Changed + +- Point Dependabot at the `cmd/osgen` module as well as the repository root. The `gomod` entry in `.github/dependabot.yml` used the singular `directory: "/"` key and so only ever read the root manifest, leaving the nested generator module unwatched since it was introduced. It now uses `directories` with both paths listed explicitly, which is what the singular key cannot express. Modules are listed one by one rather than globbed so that linter testdata fixtures, which pin old dependency versions deliberately, stay out of scope. Any nested module added later needs its own entry ([#1019](https://github.com/opensearch-project/opensearch-go/pull/1019)) + +### Fixed + +- Fix `opensearchutil.BulkIndexer` retaining a worker's peak batch memory after a traffic burst subsides. `(*worker).flush` released a completed batch with `w.items = w.items[:0]`, which keeps the slice's backing array -- and every `BulkIndexerItem` it holds, including each item's `Body` (an `io.ReadSeeker` over the caller's document bytes) and its `OnSuccess`/`OnFailure` closures -- reachable until a later batch of equal or greater size overwrites the slots. A worker that peaked at N items during a backlog replay stayed pinned at ~N items' worth of document bodies and closures indefinitely, even after traffic dropped. `flush` now `clear`s the item slice before truncating, dropping those references so the GC can reclaim them ([#912](https://github.com/opensearch-project/opensearch-go/issues/912)) +- Fix an unbounded connection/heap leak in node discovery when the cluster has a dedicated cluster manager (`cluster_manager` role with no work roles). The node was filtered out of the `allConns` inventory while the router received the unfiltered added/removed diffs, so `findConnectionByURL` never matched it: a new `*Connection` was created every discovery cycle and the stale one was never evicted, accumulating without bound in the round-robin fallback pool whose `checkDead` health checks repopulated a per-connection `poolRegistry` `sync.Map` each cycle (leak rate scaled with discovery frequency). `allConns` is now the full connection inventory so discovery reuses and evicts symmetrically, and dedicated cluster managers are excluded at request-routing selection instead: `RoundRobinPolicy` skips them in its `DiscoveryUpdate` add path and `multiServerPool.Next()` skips them during selection (including the no-router fallback), both gated on `IncludeDedicatedClusterManagers`. Discovery still bootstraps against a dedicated cluster manager seed via the seed-fallback pool ([#1003](https://github.com/opensearch-project/opensearch-go/pull/1003)) + +### Dependencies + +- Bump `github.com/getkin/kin-openapi` from 0.142.0 to 0.144.0 and `golang.org/x/text` from 0.14.0 to 0.40.0 in `cmd/osgen` in order to resolve CVE-2026-56852. Details in the Pull Request ([#1019](https://github.com/opensearch-project/opensearch-go/pull/1019)) + +## [4.7.2] + +### Fixed + +- Fix data races on `multiServerPool` lock-guarded fields: `activeListCap`, `warmupRounds`, `warmupSkipCount`, and `healthCheck` were de-facto guarded by `cp.mu` but declared at the top level of the struct, allowing accesses from `snapshot()`, `createOrUpdateMultiNodePoolWithLock`, and `updateConnectionPool` to escape the lock without looking wrong. All four fields are now nested inside the `mu` embedded struct so every access is spelled `cp.mu.` and the guard is structural. `snapshot()` reads `activeListCap` under the read lock; `createOrUpdateMultiNodePoolWithLock` runs fully under `allConnsPool.mu` with per-connection `conn.mu` taken inside the loop; `updateConnectionPool`'s RTT-probe scheduling loop reads `healthCheck` under the read lock. `recalculateWarmupParams`/`getWarmupParams` renamed `*WithLock` to document that all callers now hold the pool lock ([#995](https://github.com/opensearch-project/opensearch-go/pull/995)) +- Fix removed `opensearch.BuildRequest` reference in v4 upgrade guide ([#978](https://github.com/opensearch-project/opensearch-go/pull/978)) + +### Dependencies + +- Bump `actions/setup-go` to 7.0.0 and `actions/setup-java` to 5.6.0 ([#993](https://github.com/opensearch-project/opensearch-go/pull/993)) + +## [4.7.1] + +### Changed + +- Add a first-class container-provider abstraction to the test harness `Makefile`. `CONTAINER_PROVIDER` is auto-detected by CLI presence in the order Colima -> Rancher Desktop (`rdctl`) -> Docker, and overridable with `CONTAINER_PROVIDER=colima|rancher|docker`. Selecting a provider pins the docker context (`colima` / `rancher-desktop`; the Docker provider leaves the active context alone, and a pre-set `DOCKER_CONTEXT` in the environment is respected), resolves the CLI runtime `$(CTR)` (now `docker` by default for every provider, with `CONTAINER_RUNTIME=nerdctl` as an advanced override), ensures the backing VM/daemon is running via the new `cluster.provider.ensure` target (wired into `cluster.start`), and sets `vm.max_map_count` through the provider's VM (`colima ssh` / `rdctl shell`) or a privileged helper container. Previously `$(CTR)` preferred `nerdctl` whenever it was on `PATH`, so a Rancher-installed `nerdctl` could hijack a Colima session. `make cluster.runtime` now reports the detected provider, docker context, and runtime ([#968](https://github.com/opensearch-project/opensearch-go/pull/968)) + +### Fixed + +- Fix two gaps in the seed-fallback routing path left by [#952](https://github.com/opensearch-project/opensearch-go/pull/952)/[#954](https://github.com/opensearch-project/opensearch-go/pull/954)/[#956](https://github.com/opensearch-project/opensearch-go/pull/956): `RoundRobinPolicy.Eval` went straight to `pool.Next()` without checking its own `psEnabled` bit (unlike `CoordinatorPolicy.Eval` and `RolePolicy.Eval`), so a dead but unverified discovered node was returned as a zombie producing a transport error — not `ErrNoConnections` — and the seed fallback never fired; `PolicyChain.Eval` also did not gate on `IsEnabled()` even though `PolicyChain.Route` did, leaving the nested chain inside `IfEnabledPolicy.Eval` unguarded. Both gaps are now closed: `RoundRobinPolicy.Eval` returns no connection when its enabled bit is clear, and `PolicyChain.Eval` skips not-enabled sub-policies, matching the behavior of every other leaf policy and `Route` ([#966](https://github.com/opensearch-project/opensearch-go/pull/966)) +- Fix node discovery serving unverified discovered nodes as last-resort zombies and bypassing the seed-URL fallback when `publish_address` is unroutable from the client (NAT'd clusters, Kubernetes stack clusters in CI). `multiServerPool.nextFallbackWithLock` previously returned any dead connection unconditionally; a never-health-checked discovered node was handed out and failed with a transport error (`connection reset by peer` / `no route to host`), which is not `ErrNoConnections` so the seed fallback never fired. Introduce `lcViable`, a monotonic lifecycle bit meaning "proven directly reachable at least once" — seeds are born viable; discovered nodes earn it on their first successful health check or request. `availableForRouting()` now gates on `lcViable` so a dead list holding only never-verified discovered nodes yields `ErrNoConnections` and the request cascades to the seed-URL fallback ([#973](https://github.com/opensearch-project/opensearch-go/pull/973)) + +## [4.7.0] + +### Added + +- Add `Close()` to `opensearch.Client` and `opensearchapi.Client` to release background goroutines (node discovery, health/stats pollers, DNS refresh) and idle connections; `opensearchutil.NewBulkIndexer` now closes the client it implicitly creates. Backport of #926 without the default-client cache ([#928](https://github.com/opensearch-project/opensearch-go/issues/928), [#893](https://github.com/opensearch-project/opensearch-go/issues/893)) +- Add `VerifyDeadAfter` (`opensearch.Config` / `opensearchtransport.Config`, env override `OPENSEARCH_GO_VERIFY_DEAD_AFTER`): bounds how long a connection proven reachable may still be blindly resurrected as a last-resort "zombie" while dead. Each discovery cycle clears the viability mark on any non-seed connection that has been dead longer than the window, so a node that never recovers stops absorbing requests and must health-check clean again before it is routed to; seed connections are exempt. The env var accepts a boolean (`true` selects the 15m default, `false` disables the expiry) or a `time.ParseDuration` string; the `Config` field follows the `0` = default, `<0` = disabled, `>0` = explicit convention. See `guides/routing.md` (Zombie Connection Resurrection and Connection Viability) +- Add `cmd/osgen` code generator for typed path builders and API consumer files from the OpenAPI spec +- v5preview/opensearchapi: `NewClient` and `NewDefaultClient` now inject `opensearchtransport.NewDefaultRouter` when `config.Client.Router` is nil, opting every v5preview client into intelligent request routing by default. The `OPENSEARCH_GO_ROUTER` env var preserves its v4 semantics end-to-end: `=true`/`=1` enables auto-discovery (via `DiscoverNodesOnStart`); `=false`/`=0` suppresses both Router injection and auto-discovery; unset injects the Router without auto-discovery. v4's `opensearchapi.NewClient` is unchanged. ([#816](https://github.com/opensearch-project/opensearch-go/issues/816)) +- Add `envvars.Falsy(name)` helper that distinguishes "explicitly opted out" from "unset" (Truthy collapses both into false). Used by v5preview's router injection rule. +- Add `v5preview/opensearchapi/` package: regenerated v5-track API surface produced by `cmd/osgen` from the OpenAPI spec. Fully typed Req/Resp/Params structs, sub-clients matching OpenSearch namespaces (`client.Cat`, `client.Cluster`, `client.Indices`, etc.), and a `plugins/` subtree for ML/k-NN/security/ISM/etc. Coexists with `opensearchapi/` during the v4 -> v5 transition; see `v5preview/opensearchapi/README.md` for usage and `UPGRADING.md` for migration guidance ([#650](https://github.com/opensearch-project/opensearch-go/issues/650)) +- Add `primary_terms_map` and `split_shards_metadata` fields to ClusterState index metadata for OpenSearch >=3.6.0 compatibility +- Add generic `opensearch.Do[T]()` function for compile-time pointer enforcement on response types, preventing a class of bugs where non-pointer values are silently passed to `Client.Do()` and fail at runtime during JSON unmarshaling. Includes `opensearch.NoBody` marker type for calls that expect no response body, unifying all internal dispatch through a single generic path ([#809](https://github.com/opensearch-project/opensearch-go/pull/809)) +- Add dynamic read cost scoring: primary shard cost scales with write-pool utilization via `connScoreFunc`, preferring primaries at idle and shedding reads to replicas under write load +- Add `OPENSEARCH_GO_SHARD_COST` environment variable and `WithShardCosts()` router option with `r:base`/`r:amplify`/`r:exponent` curve keys and static cost overrides +- Add `ShardCostConfig` field to `Config` struct for programmatic shard cost override passthrough +- Add `OPENSEARCH_GO_ROUTER` environment variable to enable the DefaultRouter without code changes; set to `true` to opt in (off by default in v4, on by default in v5, removed in v6) ([#815](https://github.com/opensearch-project/opensearch-go/pull/815)) +- Add client-side metrics guide covering Metrics API, ConnectionMetric, PolicySnapshot, and RouterSnapshot ([#812](https://github.com/opensearch-project/opensearch-go/pull/812)) +- Add `InsecureSkipVerify` config option to disable TLS certificate verification without constructing a custom `http.Transport`, preserving `DefaultTransport` connection pooling, HTTP/2, and timeout defaults ([#786](https://github.com/opensearch-project/opensearch-go/issues/786)) +- Add `(*opensearchtransport.Client).Stream(*http.Request) (*http.Response, error)` and a `(*opensearch.Client).Stream` passthrough for raw byte forwarding (proxy and streaming use cases). Stream returns the unbuffered response body from `RoundTrip`; the caller owns reading and closing `res.Body`. Pairs with `opensearch.Do[T]` for typed, decoded results (the SDK owns the body). Stream is exposed only on the concrete `*Client` in v4; v5 will add it to `opensearchtransport.Interface` and remove the deprecated `Perform` ([#786](https://github.com/opensearch-project/opensearch-go/issues/786)) +- Add per-attempt `RequestTimeout` to bound individual HTTP round-trips, preventing indefinite hangs on stalled connections ([#786](https://github.com/opensearch-project/opensearch-go/issues/786)) +- Add `opensearchutil/shardhash` package with exported `Hash` and `ForRouting` functions for computing OpenSearch shard routing +- Enhanced cluster readiness checking for improved test reliability: `testutil.NewClient()` now includes readiness validation (health + cluster state + nodes info) +- Add `Status` field (`json.RawMessage`) to `TasksGetResp`, `TasksListTask`, and `TaskCancelInfo` for polymorphic task status data; add typed status structs matching the OpenSearch API specification: `BulkByScrollTaskStatus`, `ReplicationTaskStatus`, `ResyncTaskStatus`, `PersistentTaskStatus`; add `Parse*` helpers and `BulkByScrollTaskStatusOrException` for sliced task status ([#788](https://github.com/opensearch-project/opensearch-go/issues/788)) +- Test parallelization support via TEST_PARALLEL environment variable (default: CPU cores - 1, minimum 1) +- Add `cmd/osgen/emit.TestPerOpErrorTypeName_CatalogConsistency` to pin the catalog <-> switch coupling between `emit.PerOpErrorTypeName` and `errwrap.OperationWrappers`. Asserts three directions: every group naming a per-op aggregator type has 2+ wrappers in the catalog, every catalog entry with 2+ wrappers names a per-op aggregator type, and every group named by the switch is present in the catalog. Does not pin the runtime `emittableWrappers`/`resolveErrorWrappers` paths; today those sets coincide for the only 2+-wrapper groups (`msearch` / `msearch_template`) ([#857](https://github.com/opensearch-project/opensearch-go/pull/857)) +- opensearchapi/testutil package with test suite, client helpers, and JSON comparison utilities +- Add typed path builders in `internal/path/` generated from the OpenAPI spec via `cmd/osgen` for compile-time URL construction safety ([#617](https://github.com/opensearch-project/opensearch-go/issues/617), [#650](https://github.com/opensearch-project/opensearch-go/issues/650)) + - `sync.Pool`-backed `[]byte` buffers eliminate per-request allocation churn; buffers over 4 KiB are discarded to bound pool growth +- opensearchtransport/testutil package with PollUntil helper for eventual consistency testing (ISM policies, index readiness, cluster state changes) +- Configuration option `IncludeDedicatedClusterManagers` for controlling cluster manager node routing ([#765](https://github.com/opensearch-project/opensearch-go/issues/765)) +- Policy-based routing system for improved request routing and service availability ([#771](https://github.com/opensearch-project/opensearch-go/pull/771)) + - `Policy` interface for composable routing strategies with lifecycle management + - `Router` interface with `Route()` method for request-based connection selection + - `NewPolicy()` implementing chain-of-responsibility pattern for composable routing strategies + - `NewIfEnabledPolicy()` for conditional routing with runtime evaluation + - `NewMuxPolicy()` for trie-based HTTP pattern matching with zero-allocation route lookup + - `NewRolePolicy()` for role-based node selection + - `NewRoundRobinRouter()` with coordinating node preference and round-robin fallback + - `NewMuxRouter()` providing role-based request routing with graceful fallback + - Automatic routing of bulk, streaming bulk, and reindex operations to ingest nodes + - Automatic routing of search operations (search, msearch, count, by-query operations, scroll, PIT, validate, rank eval) to search/data nodes + - Automatic routing of document retrieval operations (get, mget, source, explain, termvectors, mtermvectors) to search/data nodes for read locality + - Automatic routing of template operations (search template, msearch template) and search shards to search/data nodes + - Automatic routing of field capabilities to search/data nodes + - Automatic routing of shard maintenance operations (refresh, flush, synced flush, forcemerge, cache clear, segments) to data nodes + - Automatic routing of single-document writes (index, create, update, delete) to data nodes + - Automatic routing of shard diagnostics (recovery, shard stores, stats) and rethrottle operations to data nodes + - `NewDefaultRouter()` extending role-based routing with per-index node affinity (recommended for most users) +- Add consistent hash routing with per-index node affinity for cache locality and AZ-aware load distribution ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) + - Rendezvous hashing selects a stable subset of nodes per index, preserving OS page cache and query cache locality + - RTT-bucketed scoring naturally prefers AZ-local nodes and overflows to remote AZs under load + - Per-pool congestion window (cwnd) routing using TCP-style AIMD congestion control for capacity-aware connection scoring + - Thread pool discovery via `/_nodes/_local/http,os,thread_pool` provides per-pool capacity ceiling (maxCwnd) + - Thread pool stats polling via `/_nodes/_local/stats/jvm,breaker,thread_pool` drives AIMD window adjustments + - Scoring formula: `RTTBucket * (InFlight + 1) / Cwnd * ShardCostMultiplier` -- nearest node with most headroom wins + - In-flight request tracking per node per pool with atomic add/release bracketing each RoundTrip + - AIMD slow start (double cwnd) transitions to congestion avoidance (additive increase) at ssthresh + - Multiplicative decrease on congestion signals: `total_wait_time_in_nanos` for RESIZABLE pools, queue saturation fallback for others + - Pool overload detection: `delta(rejected) > 0` or HTTP 429 marks pool overloaded, cleared only by stats poller + - HTTP 429 handling: TryLock + set overloaded + halve cwnd + retry on different node + - Quorum gating: pre-quorum uses `4 * defaultServerCoreCount` (= 32) as synthetic cwnd, post-discovery uses `4 * allocatedProcessors`, post-quorum uses real pool cwnd + - Asymmetric scale-up/scale-down thresholds with hysteresis band for stable active pool sizing + - Dynamic per-index fan-out driven by shard placement (`/_cat/shards`) and request rate + - `RouterOption` functional options: `WithMinFanOut`, `WithMaxFanOut`, `WithIndexFanOut`, `WithIdleEvictionTTL`, `WithDecayFactor`, `WithFanOutPerRequest` +- Add environment variable escape hatches (`OPENSEARCH_GO_POLICY_*`) to disable specific routing policies at startup ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) +- Add failure-triggered shard map invalidation for faster routing recovery ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) + - `lcNeedsCatUpdate` lifecycle bit excludes failed connections from routing candidate sets until `/_cat/shards` refresh + - Connections remain available for general routing (round-robin, zombie tryouts) while excluded from scored routing + - Dedicated `discoverCatTimer` schedules lightweight `/_cat/shards`-only refresh (no full node discovery) + - Refresh urgency scales with cluster impact: `interval = discoverNodesInterval * (1 - flaggedFraction)`, clamped to 5s floor + - `OnShardMapInvalidation` observer event for monitoring invalidation triggers + - `NeedsCatUpdate` field in `ConnectionMetric` for observability +- Add routing observability: observer events, metrics snapshot, connection inspection ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) + - `OnRoute` observer event with full scoring breakdown (`RouteEvent`, `RouteCandidate`) + - `RouterSnapshot` in `Client.Metrics()` exposes per-index cache state (fan-out, shard nodes, request rate, idle-since) + - `Connection.RTTMedian()`, `Connection.RTTBucket()`, `Connection.EstLoad()` for per-connection inspection + - `ConnectionMetric` enriched with `rtt_bucket`, `rtt_median`, `est_load` fields +- Add murmur3 shard-exact routing for `?routing=` and document ID requests ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) + - Client-side murmur3 x86 32-bit hash matching OpenSearch's `Murmur3HashFunction.hash(String)` for shard-exact targeting + - Document-level requests (`_doc`, `_source`, `_update`, `_explain`, `_termvectors`) use doc ID as default routing value when no explicit `?routing=` present, matching OpenSearch's `OperationRouting.generateShardId()` behavior + - Client-side murmur3 shard-exact candidate selection routes requests to nodes hosting the target shard + - Per-shard-number placement data from `/_cat/shards` maps shard numbers to primary and replica node names + - Graceful fallback to rendezvous hashing when shard map data is unavailable + - `RoutingValue`, `EffectiveRoutingKey`, `TargetShard`, `ShardExactMatch` fields in `RouteEvent` for observability +- Add `OPENSEARCH_GO_ROUTING_CONFIG` and `OPENSEARCH_GO_DISCOVERY_CONFIG` environment variables for runtime feature control ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) + - `OPENSEARCH_GO_ROUTING_CONFIG`: toggle shard-exact routing (`-shard_exact`) + - `OPENSEARCH_GO_DISCOVERY_CONFIG`: skip individual discovery server calls (`-cat_shards`, `-routing_num_shards`, `-cluster_health`, `-node_stats`) + - Bitfield flags use `+`/`-` prefix convention for explicit opt-in/out; zero-initialized = all features enabled + - `WithShardExactRouting(bool)` `RouterOption` for programmatic control (env var overrides) + - Evaluated once at client init time; immutable after + - Document environment variables in `guides/routing.md` + - Document read-after-write visibility guarantees with operation-aware routing in `guides/routing.md` +- Add adaptive `max_concurrent_shard_requests` derived from cluster-wide AIMD congestion window ([#800](https://github.com/opensearch-project/opensearch-go/issues/800)) +- Add partial failure error types (`PartialBulkError`, `PartialSearchError`, `ShardFailureError`, `MultiSearchItemError`) that surface HTTP 200 partial failures as typed Go errors, controlled by a per-category `errmask.ErrorMask` bitfield on `Config.Errors` ([#816](https://github.com/opensearch-project/opensearch-go/issues/816)) + - `PartialBulkError` returned from `Bulk` when `resp.Errors` is true, carries `FailedItems` and `SucceededCount` + - `PartialSearchError` returned from `Search`, `MSearch`, `MSearchTemplate`, `SearchTemplate`, `Scroll.Get` when `_shards.failed > 0` + - `ShardFailureError` returned from `Index`, `Document.Create`, `Document.Delete`, `Update` when replica shards fail + - `MultiSearchItemError` returned from `MSearch`/`MSearchTemplate` for per-sub-response Error envelopes + - `MSearchErrors` / `MSearchTemplateErrors` per-op containers (Go 1.20+ multi-error contract via `Unwrap() []error`) when 2+ wrapper categories fire on the same response + - `PartialFailureError` marker interface with `IsPartial() bool` for type-switching across all partial-failure types + - `opensearchapi.Errors(err) []error` package-level helper that flattens single- and multi-wrapper errors into a uniform slice; recommended call-site pattern is a `for`/`switch` over the result (not `errors.As` against a specific type) + - Helper functions: `IsPartialFailure`, `ToleratePartialFailures`, `RequireSuccessRate` for threshold-based error tolerance + - Operation constants: `OperationIndex`, `OperationCreate`, `OperationUpdate`, `OperationDelete` + - Per-Resp helper methods (`BulkItemFailures`, `SearchShardFailures`, `WriteShardFailures`, `MultiSearchItemFailures`, `PartialFailures(mask)`) exist on the response types as engine machinery for the dispatch; new code should prefer a `for`/`switch` over `opensearchapi.Errors(err)` rather than the per-Resp helpers, for forward compatibility + - `Config.Errors *errmask.ErrorMask` replaces a single boolean: each bit suppresses one wrapper category. v4 defaults to `errmask.All` (mask everything, preserves pre-bitfield behavior); v5+ defaults to `errmask.Empty` (report everything) + - `OPENSEARCH_GO_ERROR_MASK` environment variable overrides `Config.Errors` at runtime via comma-separated `+`/`-` tokens (lowercase snake_case wrapper names; unknown tokens silently dropped, debug-logged) + - Both `(resp, error)` are non-nil on partial failure -- response is fully populated + - `v5preview/opensearchapi` ports the same model with spec-driven types (regenerated from the OpenAPI `x-error-responses` extension on every `cmd/osgen` run) +- Add `OperationClassifier` for zero-allocation HTTP method+path to `OperationID` mapping ([#816](https://github.com/opensearch-project/opensearch-go/issues/816)) + - Bit-packed `OperationID` (int64) encoding R/W flag, category, and minor operation + - Masking helpers: `IsWrite`, `IsRead`, `Category`, `Minor` + - `String()` returns Prometheus-friendly labels (e.g., `"search"`, `"bulk"`, `"doc_get"`) + - Reuses existing `routeTrie` for O(path-segments) lookup, safe for concurrent use + - Enables transparent metrics/tracing middleware at the `http.RoundTripper` layer + - Transport automatically sets `max_concurrent_shard_requests` query parameter on search requests routed through a coordinator node + - Value derived from a cluster-wide aggregate of all polled nodes' search pool wait-time and completion deltas, clamped to `[floor, cap]` (default: 5–256) + - Cluster-wide signal correctly models data-node fan-out capacity: single hot nodes are diluted by healthy peers, and MCSR only drops when aggregate cluster pressure rises + - Per-node AIMD for connection scoring remains unchanged (hot-node avoidance is handled by connection selection, not fan-out throttling) + - Falls back to per-node cwnd before the first poll cycle completes + - Respects explicit caller overrides: pre-existing `max_concurrent_shard_requests` query parameter is never clobbered + - Not applied to shard-exact routed requests (coordinator fan-out is irrelevant) + - `WithAdaptiveConcurrency(bool)` and `WithAdaptiveConcurrencyLimits(floor, cap)` `RouterOption` for programmatic control + - `OPENSEARCH_GO_SHARD_REQUESTS` environment variable: `true`/`false` to enable/disable, or `min:max` to set floor and cap (e.g., `10:512`) + - `OPENSEARCH_GO_ROUTING_CONFIG=-adaptive_mcsr` to disable via routing config bitfield + - `MaxConcurrentShardRequests` field in `RouteEvent` for observability +- Add seed URL fallback as last-resort connection source when all router pools are exhausted ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) + - Builds a dedicated `multiServerPool` from fresh copies of the original seed URLs at client init + - Fires after the entire retry loop when all router policies and connection pools return `ErrNoConnections` + - On success: triggers immediate cluster rediscovery to repopulate router pools + - `OPENSEARCH_GO_FALLBACK=false` disables seed fallback (enabled by default) +- Add consolidated environment variable reference in `guides/routing.md` and `USER_GUIDE.md` ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) +- Add connection pool health probes with cluster-aware resurrection timing ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) + - Auto-discover server core count from `/_nodes/http,os,thread_pool` to derive all rate-limiting and congestion window parameters (default: 8 cores) + - Weighted round-robin for heterogeneous clusters: nodes with more cores get proportionally more traffic via GCD-normalized duplicate pointers in the ready list + - `lcNeedsHardware` lifecycle bit tracks connections needing hardware info; per-node fallback via `/_nodes/_local/http,os,thread_pool` during health checks + - Capacity model dynamically recalculated on each discovery cycle from minimum `allocatedProcessors` across all nodes + - TLS-aware rate limiting prevents overwhelming recovering servers during outages + - Three-input timeout formula: `max(healthTimeout, rateLimitedTimeout, minimumFloor) + jitter` + - Shuffle ready connection list on add/resurrect to prevent round-robin hot-spotting + - Two-phase readiness health check: `GET /` then `GET /_cluster/health?local=true` with `initializing_shards` gate to prevent routing to recovering nodes + - Store cluster health metrics (`ClusterHealthLocal`) on each connection for observability + - Periodic cluster health refresh for ready connections keeps `ClusterHealthLocal` data current for load-shedding and routing decisions + - Refresh interval scales with cluster size: `clamp(liveNodes * clientsPerServer / healthCheckRate, 5s, 5min)` + - Single-node clusters skip refresh entirely (no routing benefit) + - Node stats polling with load shedding via `NodeStatsInterval` configuration + - Polls `GET /_nodes/_local/stats/jvm,breaker,thread_pool` to detect overloaded nodes and update congestion windows + - Per-pool AIMD congestion control adjusts cwnd based on thread pool wait time and queue saturation + - Overloaded nodes are demoted from the ready list to the standby partition + - Overload detection: JVM heap threshold (`OverloadedHeapThreshold`, default 85%), circuit breaker size ratio (`OverloadedBreakerRatio`, default 0.90), breaker trip delta, and cluster status red +- Add heterogeneous Docker cluster targets for integration-testing weighted routing and role-based request routing + - `cluster.heterogeneous.cpu.1` and `cluster.heterogeneous.cpu.2` set per-node CPU limits via Docker Compose overrides + - `cluster.heterogeneous.roles` assigns distinct node roles (cluster_manager+ingest, data+ingest, data) + - `cluster.homogeneous` removes all overrides to reset to default configuration + - `cluster.status` now shows per-node roles and allocated processors via `_nodes/http,os` +- Add request routing guide (`guides/routing.md`) consolidating routing architecture, connection scoring, pool lifecycle, cost model, and configuration reference ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) +- Add per-item `Error` field to `MGetResp`, `MTermvectorsResp`, and `MSearchResp` for detecting partial failures in multi-document operations ([#797](https://github.com/opensearch-project/opensearch-go/issues/797)) +- Add `DocumentError` type for structured per-item error information in multi-document responses +- Add `BulkByScrollFailure` type for structured failure information in `_delete_by_query`, `_update_by_query`, and `_reindex` responses +- Add `Routing` and `Fields` to `MGetResp.Docs` to match the full OpenSearch `_mget` response format +- Add `ForcedRefresh` field to `IndexResp`, `DocumentDeleteResp`, and `UpdateResp` for consistency with `DocumentCreateResp` +- Add `Status` and `Primary` fields to `ResponseShardsFailure` for shard failure diagnostics + +### Changed + +- Connection dead/overloaded timestamps (`deadSince`/`overloadedAt`) are now lock-free `atomic.Int64` values. `buildConnectionMetric` no longer locks each connection to read them, removing the dominant metrics-snapshot lock contention against the per-request writers. No public API change; `EnableMetrics` behavior is unchanged. ([#892](https://github.com/opensearch-project/opensearch-go/issues/892)) +- Per-request transport metrics (`requests`, `failures`, responses-by-status) are now always collected via lock-free atomics, independent of `EnableMetrics`. `EnableMetrics` now gates only the detailed-metrics snapshot (per-connection, per-policy, and router state returned by `Metrics()`). The responses-by-status counter moved from a mutex-guarded map to a lock-free atomic array. `Metrics()` no longer returns an error when metrics are disabled — it always returns the per-request counters (callers that branched on `if err != nil` for the disabled case should drop that check). ([#891](https://github.com/opensearch-project/opensearch-go/issues/891)) +- **BREAKING**: `opensearch.Request` interface signature changed from `GetRequest() (*http.Request, error)` to `GetRequest(method string) (*http.Request, error)`. The HTTP method is now caller-provided rather than hardcoded per operation, enabling correct method selection for operations that support multiple HTTP methods (e.g. search supports both GET and POST). This only affects code that implements or calls `GetRequest` directly; standard usage through client methods (e.g. `client.Search(ctx, req)`) is unaffected ([#650](https://github.com/opensearch-project/opensearch-go/issues/650)) +- Bump CI and developer guide OpenSearch versions: compatibility matrix to 2.19.5, default integration test version to 3.6.0 ([#810](https://github.com/opensearch-project/opensearch-go/pull/810)) +- Include `_nodes.failures` detail in discovery error messages for diagnosing intermittent CI failures on older OpenSearch versions ([#823](https://github.com/opensearch-project/opensearch-go/pull/823)) +- Test against Opensearch 3.6.0 ([#817](https://github.com/opensearch-project/opensearch-go/pull/817)) +- Consolidate test utilities into two canonical packages: opensearchtransport/testutil (env helpers, polling, version comparison) and opensearchapi/testutil (client-dependent helpers, test suite, JSON comparison) +- Rename `singleConnectionPool` to `singleServerPool` and `statusConnectionPool` to `multiServerPool` for clarity ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) +- Refactor Client struct to use embedded mutex pattern for improved thread safety ([#775](https://github.com/opensearch-project/opensearch-go/pull/775)) +- Refactor metrics struct to use atomic counters for lock-free request/failure tracking ([#776](https://github.com/opensearch-project/opensearch-go/pull/776)) +- Test against Opensearch 2.19.4, 3.1, 3.3, and 3.4 ([#782](https://github.com/opensearch-project/opensearch-go/pull/782)) +- Migrate all test files to context-aware API calls for proper timeout and cancellation support +- Add cluster readiness validation and improve cluster error diagnostics +- Update Docker cluster management to add version-aware role detection (cluster_manager vs master) +- Generate unique document IDs in tests for parallel test execution and eliminate known test flakes +- Reduce integration test timeout from 1h to 10m per package with parallel execution support +- Refactor transport code for improved maintainability (rename ErrInvalidRole -> InvalidRoleError, add response body cleanup, simplify initialization) +- **BREAKING**: Change `CatTemplatesReq.Templates` and `IndexTemplateGetReq.IndexTemplates` from `[]string` to `string` to match the OpenSearch API specification, which types these path parameters as scalar name patterns (not comma-separated lists). This breakage will show up at compile time as a type mismatch and is easy to fix. Callers passing a single pattern only need to remove the slice literal (e.g. `[]string{"*"}` becomes `"*"`). Callers that relied on the old behavior of joining multiple patterns can use `strings.Join(patterns, ",")` to produce the comma-separated string themselves. +- **BREAKING**: Enhanced node discovery to match OpenSearch server behavior ([#765](https://github.com/opensearch-project/opensearch-go/issues/765)) + - Dedicated cluster manager nodes are now excluded from client request routing by default (best practice) + - Node selection logic now matches Java client `NodeSelector.SKIP_DEDICATED_CLUSTER_MASTERS` behavior +- **BREAKING**: Add context support to discovery and client lifecycle management + - `opensearchtransport.Discoverable` interface now requires `context.Context` parameter: `DiscoverNodes(ctx context.Context) error` + - `opensearch.Client.DiscoverNodes()` and `opensearchtransport.Client.DiscoverNodes()` now require `context.Context` parameter + - `opensearch.Config` and `opensearchtransport.Config` now accept optional `Context` and `CancelFunc` fields + - `opensearchutil.BulkIndexerConfig` now accepts optional `Context` and `CancelFunc` fields + - Enables proper context propagation for timeouts, cancellation, and graceful shutdown + - Role compatibility validation prevents conflicting role assignments (master+cluster_manager, warm+search) + - OpenSearch 3.0+ searchable snapshots now use `warm` role instead of deprecated `search` role +- **BREAKING**: Migrate `signer/aws` package from AWS SDK v1 to AWS SDK v2 due to AWS SDK v1 reaching end-of-support on July 31, 2025 + - Constructor now takes `aws.Config` instead of `session.Options` + - See USER_GUIDE.md for details required to migrate + - Users who need access to the existing `signer/awsv2` API can still use it, however they are encouraged to migrate to `signer/aws` +- **BREAKING**: Replace `[]json.RawMessage` with typed `[]BulkByScrollFailure` for `Failures` field in `DocumentDeleteByQueryResp`, `UpdateByQueryResp`, and `ReindexResp` ([#797](https://github.com/opensearch-project/opensearch-go/issues/797)). This is a compile-time change only — callers that were not accessing `.Failures` are unaffected, and callers that were manually unmarshaling `json.RawMessage` can now access typed fields directly. +- Replace inline `_shards` struct with `ResponseShards` in `IndexResp`, `DocumentCreateResp`, `DocumentDeleteResp`, `UpdateResp`, `IndicesRefreshResp`, and `IndicesCountResp` to expose shard `Failures` and `Skipped` fields ([#797](https://github.com/opensearch-project/opensearch-go/issues/797)). Code accessing `resp.Shards.Total`, `resp.Shards.Successful`, or `resp.Shards.Failed` compiles unchanged. +- Add `omitempty` to all deprecated `_type` JSON tags so empty values are omitted during marshaling +- Modernize tests to use Go 1.25's `WaitGroup.Go()` ([#834](https://github.com/opensearch-project/opensearch-go/pull/834)) + +### Deprecated + +- Mark `opensearchtransport.Client.Perform` and the `opensearch.Client.Perform` passthrough as deprecated; both remain fully functional in v4 (still buffering the response body via `io.ReadAll` + `NopCloser`) and will be removed in v5. New code should call `opensearch.Do[T]` for typed, decoded results or `opensearchtransport.Client.Stream` / `opensearch.Client.Stream` for raw byte forwarding. +- Mark `Client.Do()` with a `Deprecated` doc annotation in favor of `opensearch.Do[T]()` for compile-time pointer safety; `Client.Do()` remains fully functional and will not be removed, but `staticcheck` SA1019 will nudge cross-package callers toward the safer generic alternative +- Mark `opensearch.ToPointer` and `opensearchapi.ToPointer` as deprecated; they remain fully functional but will be removed in v5. Once the module's go directive moves to 1.26, callers can drop the helper entirely in favor of native `new(value)` literal syntax (e.g. `new(false)`) + +### Removed + +### Fixed + +- Fix node discovery hijacking the request stream with unverified, unreachable discovered nodes and masking the user-supplied seed-URL fallback. When discovered `publish_address` values are unroutable from the client (NAT'd or misconfigured clusters, e.g. a Kubernetes stack cluster in CI), a freshly discovered but never-health-checked node could be served to requests as a zombie -- failing every request with `no route to host` -- instead of returning `ErrNoConnections` and cascading to the reachable seed URL. Connections are now considered available for routing only when they are a user-supplied seed (assumed reachable) or a discovered node confirmed reachable, and every routing policy and pool (round-robin, role, coordinator, index/doc router, single-server, and multi-server pools) consistently honors that gate on both the enabled-bit and connection-selection paths, so the seed fallback serves requests until a discovered node health-checks clean ([#952](https://github.com/opensearch-project/opensearch-go/pull/952), [#954](https://github.com/opensearch-project/opensearch-go/pull/954), [#956](https://github.com/opensearch-project/opensearch-go/pull/956)) +- Fix `BulkIndexerStats.NumAdded` overcounting items rejected by `Add()` when the caller's context is cancelled before the item could be enqueued: increment `NumAdded` only after the queue accepts the item, and add a new `BulkAddFailCount` counter for items dropped on the `<-ctx.Done()` branch. Migrate `bulkIndexerStats` fields to `sync/atomic.Uint64` typed values so future direct access is a compile-time error rather than a `-race`-only finding ([#783](https://github.com/opensearch-project/opensearch-go/issues/783)) +- Fix `opensearchtransport.Client.setReqGlobalHeader` comparing the per-request header value against the global header name, so a request-level header never suppressed the matching global default and both were sent ([#859](https://github.com/opensearch-project/opensearch-go/pull/859)) +- Fix gzip buffer-pool nil poisoning on compress error: `gzipCompressor.compress` returned `(nil, err)` while the caller's deferred `collectBuffer` still ran, putting a typed-nil `*bytes.Buffer` into the `sync.Pool` that panics on the next `Get().Reset()` ([#859](https://github.com/opensearch-project/opensearch-go/pull/859)) +- Fix `opensearchtransport.Client.Perform` silently dropping `io.ReadAll` errors during response buffering via `:=` shadowing; the read error now propagates wrapped in the new `opensearchtransport.ErrResponseBodyRead` sentinel, and `opensearch.Client.Do` classifies the `(resp != nil, err != nil)` case via `errors.Is` so only genuine body-read failures are labeled `ErrReadBody` (an unrelated transport error returned alongside a response, such as context cancellation during retry backoff, is no longer misreported as a read failure). As a consequence, `opensearch.Client.Do` now returns a non-nil `*Response` alongside a non-nil error in this case where it previously returned `(nil, err)`; callers detecting a hard transport failure should check `resp == nil` rather than `err != nil` ([#859](https://github.com/opensearch-project/opensearch-go/pull/859)) +- Fix error-response body not being closed in `opensearch.ParseError`. `ParseError` now closes the original body before re-wrapping the read bytes in a `NopCloser`. The v5preview `do()` no-decode error path no longer needs its own drain: `opensearch.Do` routes through the buffered `opensearchtransport.Client.Perform`, so the returned `resp.Body` is already an in-memory `NopCloser` over the full payload and stays readable for the caller ([#859](https://github.com/opensearch-project/opensearch-go/pull/859)) +- Fix response-body lifecycle on the raw `RoundTrip` paths that lack `Perform`'s buffering safety net, where closing a partially-read body defeated HTTP keep-alive: the stats poller (`cluster_health.go`), discovery's `/_cat/shards`, `/_cluster/state/metadata`, and `/_nodes` paths, and the `fetchClusterHealth`/`baselineHealthCheck`/`hardwareInfoHealthCheck` pollers now drain to EOF (`io.Copy(io.Discard, ...)`) before close (covering both non-200 returns and `json.Decode` success paths that stop before EOF). The AWS v1 and v2 signers now close the request body on the read-error path in `hexEncodedSha256OfRequest` ([#859](https://github.com/opensearch-project/opensearch-go/pull/859)) +- Add typed response-format defaults for `v5preview/opensearchapi/` cat, list, ppl, and sql operations: when the caller leaves `Format` unset, the SDK now emits the value the typed Resp struct expects (`json` for cat/list/explain, `jdbc` for ppl/sql query) instead of letting the server fall back to a default the JSON decoder cannot handle. +- Replace `WaitForAllNodesReady` inline `require.Eventually` loop with a layered readiness FSM (`internal/test/readiness`) that observes per-node progression through `LayerTCP -> LayerHTTP -> LayerClusterJoin -> LayerStatsReady`, records transitions including regressions, and emits a structured per-node diagnostic with the full last cat-nodes response on timeout. Per-layer budgets are tuned for CI pessimism (cold JVM startup is the long pole); total budget for `TargetClusterReady` is 6.5 minutes. ([#650](https://github.com/opensearch-project/opensearch-go/issues/650)) +- Fix bulk indexer HTML-escaping `_id` and `routing` values containing `<`, `>`, or `&` characters, causing OpenSearch to store escaped values (e.g., `\u003croot_account\u003e` stored instead of ``), leading to duplicate documents, unreachable data on read-by-ID paths, and potential shard routing mismatches. Present since the `json.Marshal` migration in 2021 (commit `3da59092`). Replace `json.Marshal` with `json.NewEncoder` + `SetEscapeHTML(false)` in `opensearchutil.worker.writeMeta` and `opensearchutil.JSONReader`; replace per-worker `aux []byte` with `sync.Pool`-backed `*bytes.Buffer`; add table-driven test coverage for `writeMeta` edge cases and refactor remaining `TestBulkIndexer` subtests to table-driven `require`-based style ([#824](https://github.com/opensearch-project/opensearch-go/pull/824)) +- Fix pool replacement orphaning resurrection goroutines during node discovery, causing connections to become permanently dead with no active health checker ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) +- Fix multi-to-single pool demotion leaking resurrection goroutines by giving each `multiServerPool` its own derived context and cancelling it on demotion ([#830](https://github.com/opensearch-project/opensearch-go/pull/830)) +- Extract `newMultiServerPoolFromClientWithLock` as single source of truth for Client-to-pool settings propagation ([#786](https://github.com/opensearch-project/opensearch-go/pull/786)) +- Skip shard routing integration tests on OpenSearch < 2.2.0 with security plugin due to server-side `OptionalDataException` from non-thread-safe User serialization (opensearch-project/security#1970) +- Fix URL path construction across 74 `GetRequest` methods where empty path segments produced a double-slash `//` that `http.NewRequest` misparsed as an RFC 3986 authority separator; replace manual `strings.Builder` paths with typed path builder structs that reject empty required segments ([#617](https://github.com/opensearch-project/opensearch-go/issues/617), [#650](https://github.com/opensearch-project/opensearch-go/issues/650)) +- Eliminate per-request `url.Parse` overhead by constructing `*http.Request` directly with a coalesced struct; reduce per-request allocations from 8/2930B to 2/472B for typical operations ([#650](https://github.com/opensearch-project/opensearch-go/issues/650)) +- Fix alias, mapping, settings, and block API URL path construction when Indices is empty, which caused `http.NewRequest` to misparse the double-slash as an authority separator ([#650](https://github.com/opensearch-project/opensearch-go/issues/650)) +- Fix discovery pool wipe when all cluster nodes time out during `/_nodes/http` fan-out: parse `_nodes` metadata envelope and return `errDiscoveryEmpty` when `successful == 0`, preserving the existing connection pool for retry ([#821](https://github.com/opensearch-project/opensearch-go/pull/821)) +- Skip shard routing integration tests on OpenSearch < 2.2.0 with security plugin due to server-side `OptionalDataException` from non-thread-safe User serialization (opensearch-project/security#1970) +- Fix flaky `TestDefaultHealthCheck_RetryAfterMaxRetry`: replace wall-clock `time.Sleep` + `atomic.Int64` synchronization with context cancellation (`ctx.Done()`), and widen `maxRetryClusterHealth` to 5s so the baseline HTTP round-trip cannot race past the retry interval ([#787](https://github.com/opensearch-project/opensearch-go/pull/787)) +- Skip opensearchtransport integration tests on OpenSearch < 2.2.0 with security plugin due to server-side `OptionalDataException` from non-thread-safe User serialization (opensearch-project/security#1970) +- Skip shard routing integration tests on OpenSearch < 2.2.0 with security plugin due to server-side `OptionalDataException` from non-thread-safe User serialization (opensearch-project/security#1970) +- Fix connection lifecycle bug in multiServerPool.OnFailure where connections were scheduled for resurrection before being moved from ready to dead list, causing potential race conditions +- Fix flaky connection integration test by replacing arbitrary sleep times with proper server readiness polling +- Fix cluster readiness checks in integration tests to handle HTTPS cold start delays (increase timeout to 15s) +- Fix GitHub Actions workflow authentication for OpenSearch 2.12.0+ password changes (admin -> myStrongPassword123!) +- Fix Docker cluster management to properly handle version-specific configurations and clean stale images/volumes +- Fix OpenSearch 2.8.0+ Tasks API compatibility by adding cancellation_time_millis field to TasksListTask struct +- Fix OpenSearch 3.1.0+ API compatibility by adding phase_results_processors field to nodes API and time_in_execution fields to cluster pending tasks API +- Fix OpenSearch 3.2.0+ API compatibility by adding max_last_index_request_timestamp and startree query fields across nodes stats, indices stats, and cat APIs, plus settings field to security plugin health API +- Fix OpenSearch 3.3.0+ API compatibility by adding neural_search breaker, query_failed and startree_query_failed search fields, search pipeline system_generated fields across multiple APIs, plus ingestion_status field to cluster state API and jwks_uri field to security config API +- Fix OpenSearch 3.4.0+ API compatibility by adding warmer fields to merges section, parallelism field to thread pool, and status_counter field across multiple APIs +- Fix cat indices API field naming compatibility across OpenSearch versions by using forward-compatible field names (PrimarySearchStartreeQuery) that match the corrected 3.3.0+ naming, with fallback support for the temporary 3.2.0 field names +- Fix cat APIs data type compatibility by changing byte fields from int to string to properly handle values like "0b" +- Fix floating point precision loss in nodes stats concurrent_avg_slice_count field by changing from float32 to float64 +- Fix ISM RefreshSearchAnalyzers missing leading slash in URL path, causing HTTP/2 request failures ([#686](https://github.com/opensearch-project/opensearch-go/pull/686)) + +### Security + +### Dependencies + +- Bump golangci-lint from v2.11.2 to v2.11.4 +- Bump `golang.org/x/sync` from v0.19.0 to v0.20.0 ([#831](https://github.com/opensearch-project/opensearch-go/pull/831)) +- Bump `golang.org/x/mod` from v0.33.0 to v0.35.0 ([#831](https://github.com/opensearch-project/opensearch-go/pull/831)) +- Bump `github.com/wI2L/jsondiff` from v0.7.0 to v0.7.1 ([#831](https://github.com/opensearch-project/opensearch-go/pull/831)) +- Bump `github.com/aws/aws-sdk-go-v2` from v1.41.1 to v1.41.7 ([#831](https://github.com/opensearch-project/opensearch-go/pull/831)) +- Bump `github.com/aws/aws-sdk-go-v2/config` from v1.32.7 to v1.32.17 ([#831](https://github.com/opensearch-project/opensearch-go/pull/831)) +- Bump `github.com/aws/aws-sdk-go-v2/credentials` from v1.19.7 to v1.19.16 ([#831](https://github.com/opensearch-project/opensearch-go/pull/831)) +- Bump `github.com/aws/smithy-go` from v1.24.0 to v1.25.1 ([#831](https://github.com/opensearch-project/opensearch-go/pull/831)) +- Bump `github.com/aws/aws-sdk-go-v2/config` from 1.32.6 to 1.32.7 ([#767](https://github.com/opensearch-project/opensearch-go/pull/767)) + ## [4.6.0] ### Dependencies + - Bump `github.com/aws/aws-sdk-go-v2/config` from 1.29.14 to 1.32.5 ([#707](https://github.com/opensearch-project/opensearch-go/pull/707), [#711](https://github.com/opensearch-project/opensearch-go/pull/711), [#719](https://github.com/opensearch-project/opensearch-go/pull/719), [#730](https://github.com/opensearch-project/opensearch-go/pull/730), [#737](https://github.com/opensearch-project/opensearch-go/pull/737), [#761](https://github.com/opensearch-project/opensearch-go/pull/761)) - Bump `github.com/aws/aws-sdk-go-v2` from 1.36.4 to 1.41.0 ([#710](https://github.com/opensearch-project/opensearch-go/pull/710), [#720](https://github.com/opensearch-project/opensearch-go/pull/720), [#759](https://github.com/opensearch-project/opensearch-go/pull/759)) - Bump `github.com/stretchr/testify` from 1.10.0 to 1.11.1 ([#728](https://github.com/opensearch-project/opensearch-go/pull/728)) - Bump `github.com/aws/aws-sdk-go` from 1.55.7 to 1.55.8 ([#716](https://github.com/opensearch-project/opensearch-go/pull/716)) +- Bump go version from 1.24.0 to 1.25.9 in order to resolve certain CVEs. Details in the Pull Request ([#825](https://github.com/opensearch-project/opensearch-go/pull/825)) ### Added + - Adds new fields for Opensearch 3.0 ([#702](https://github.com/opensearch-project/opensearch-go/pull/702)) - Allow users to override signing port ([#721](https://github.com/opensearch-project/opensearch-go/pull/721)) - Add `phase_took` features supported from OpenSearch 2.12 ([#722](https://github.com/opensearch-project/opensearch-go/pull/722)) - Adds the action to refresh the search analyzers to the ISM plugin ([#686](https://github.com/opensearch-project/opensearch-go/pull/686)) ### Changed + - Test against Opensearch 3.0 ([#702](https://github.com/opensearch-project/opensearch-go/pull/702)) - Add more SuggestOptions to SearchResp ([#713](https://github.com/opensearch-project/opensearch-go/pull/713)) - Updates Go version to 1.24 ([#674](https://github.com/opensearch-project/opensearch-go/pull/674)) @@ -31,6 +335,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ### Removed ### Fixed + - Missing "caused by" information in StructError ([#752](https://github.com/opensearch-project/opensearch-go/pull/752)) - Add missing `ignore_unavailable`, `allow_no_indices`, and `expand_wildcards` params to MSearch ([#757](https://github.com/opensearch-project/opensearch-go/pull/757)) - Fix `UpdateResp` to correctly parse the `get` field when `_source` is requested in update operations. ([#739](https://github.com/opensearch-project/opensearch-go/pull/739)) @@ -40,17 +345,20 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ## [4.5.0] ### Dependencies + - Bump `github.com/aws/aws-sdk-go-v2/config` from 1.29.6 to 1.29.14 ([#692](https://github.com/opensearch-project/opensearch-go/pull/692)) - Bump `github.com/aws/aws-sdk-go` from 1.55.6 to 1.55.7 ([#696](https://github.com/opensearch-project/opensearch-go/pull/696)) - Bump `github.com/wI2L/jsondiff` from 0.6.1 to 0.7.0 ([#700](https://github.com/opensearch-project/opensearch-go/pull/700)) ### Added + - Adds DataStream field to IndicesGetResp struct ([#701](https://github.com/opensearch-project/opensearch-go/pull/701)) - Adds `InnerHits` field to `SearchResp` ([#672](https://github.com/opensearch-project/opensearch-go/pull/672)) - Adds `FilterPath` param ([#673](https://github.com/opensearch-project/opensearch-go/pull/673)) - Adds `Aggregations` field to `MSearchResp` ([#690](https://github.com/opensearch-project/opensearch-go/pull/690)) ### Changed + - Bump golang version to 1.22 ([#691](https://github.com/opensearch-project/opensearch-go/pull/691)) - Change ChangeCatRecoveryItemResp Byte fields from int to string ([#691](https://github.com/opensearch-project/opensearch-go/pull/691)) - Changed log formatted examples code ([#694](https://github.com/opensearch-project/opensearch-go/pull/694)) @@ -67,6 +375,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ## [4.4.0] ### Added + - Adds `Highlight` field to `SearchHit` ([#654](https://github.com/opensearch-project/opensearch-go/pull/654)) - Adds `MatchedQueries` field to `SearchHit` ([#663](https://github.com/opensearch-project/opensearch-go/pull/663)) - Adds support for Opensearch 2.19 ([#668](https://github.com/opensearch-project/opensearch-go/pull/668)) @@ -82,6 +391,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ### Security ### Dependencies + - Bump `github.com/aws/aws-sdk-go` from 1.55.5 to 1.55.6 ([#657](https://github.com/opensearch-project/opensearch-go/pull/657)) - Bump `github.com/wI2L/jsondiff` from 0.6.0 to 0.6.1 ([#643](https://github.com/opensearch-project/opensearch-go/pull/643)) - Bump `github.com/aws/aws-sdk-go-v2` from 1.32.2 to 1.36.1 ([#664](https://github.com/opensearch-project/opensearch-go/pull/664)) @@ -91,6 +401,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ## [4.3.0] ### Added + - Adds ISM Alias action ([#615](https://github.com/opensearch-project/opensearch-go/pull/615)) - Adds support for opensearch 2.17 ([#623](https://github.com/opensearch-project/opensearch-go/pull/623)) @@ -101,6 +412,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ### Removed ### Fixed + - Fix ISM Transition to omitempty Conditions field ([#609](https://github.com/opensearch-project/opensearch-go/pull/609)) - Fix ISM Allocation field types ([#609](https://github.com/opensearch-project/opensearch-go/pull/609)) - Fix ISM Error Notification types ([#612](https://github.com/opensearch-project/opensearch-go/pull/612)) @@ -110,25 +422,30 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ### Security ### Dependencies + - Bump `github.com/aws/aws-sdk-go-v2/config` from 1.27.31 to 1.27.43 ([#611](https://github.com/opensearch-project/opensearch-go/pull/611), [#630](https://github.com/opensearch-project/opensearch-go/pull/630), [#632](https://github.com/opensearch-project/opensearch-go/pull/632)) - Bump `github.com/aws/aws-sdk-go-v2` from 1.32.1 to 1.32.2 ([#631](https://github.com/opensearch-project/opensearch-go/pull/631)) ## [4.2.0] ### Dependencies + - Bump `github.com/aws/aws-sdk-go-v2/config` from 1.27.23 to 1.27.31 ([#584](https://github.com/opensearch-project/opensearch-go/pull/584), [#588](https://github.com/opensearch-project/opensearch-go/pull/588), [#593](https://github.com/opensearch-project/opensearch-go/pull/593), [#605](https://github.com/opensearch-project/opensearch-go/pull/605)) - Bump `github.com/aws/aws-sdk-go` from 1.54.12 to 1.55.5 ([#583](https://github.com/opensearch-project/opensearch-go/pull/583), [#590](https://github.com/opensearch-project/opensearch-go/pull/590), [#595](https://github.com/opensearch-project/opensearch-go/pull/595), [#596](https://github.com/opensearch-project/opensearch-go/pull/596)) ### Added + - Adds `Suggest` to `SearchResp` ([#602](https://github.com/opensearch-project/opensearch-go/pull/602)) - Adds `MaxScore` to `ScrollGetResp` ([#607](https://github.com/opensearch-project/opensearch-go/pull/607)) ### Changed -- Split SnapshotGetResp into sub structs ([#603](https://github.com/opensearch-project/opensearch-go/pull/603)) + +- Split SnapshotGetResp into sub structs ([#603](https://github.com/opensearch-project/opensearch-go/pull/603)) ### Deprecated ### Removed + - Remove workflow tests against gotip ([#604](https://github.com/opensearch-project/opensearch-go/pull/604)) ### Fixed @@ -138,6 +455,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ## [4.1.0] ### Added + - Adds the `Routing` field in SearchHit interface. ([#516](https://github.com/opensearch-project/opensearch-go/pull/516)) - Adds the `SearchPipelines` field to `SearchParams` ([#532](https://github.com/opensearch-project/opensearch-go/pull/532)) - Adds support for OpenSearch 2.14 ([#552](https://github.com/opensearch-project/opensearch-go/pull/552)) @@ -147,6 +465,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) - Adds OpenSearch 2.15 to compatibility workflow test ([#575](https://github.com/opensearch-project/opensearch-go/pull/575)) ### Changed + - Security roles get response struct has its own sub structs without omitempty ([#572](https://github.com/opensearch-project/opensearch-go/pull/572)) ### Deprecated @@ -168,6 +487,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ### Security ### Dependencies + - Bump `github.com/aws/aws-sdk-go` from 1.51.21 to 1.54.12 ([#534](https://github.com/opensearch-project/opensearch-go/pull/534), [#537](https://github.com/opensearch-project/opensearch-go/pull/537), [#538](https://github.com/opensearch-project/opensearch-go/pull/538), [#545](https://github.com/opensearch-project/opensearch-go/pull/545), [#554](https://github.com/opensearch-project/opensearch-go/pull/554), [#557](https://github.com/opensearch-project/opensearch-go/pull/557), [#563](https://github.com/opensearch-project/opensearch-go/pull/563), [#564](https://github.com/opensearch-project/opensearch-go/pull/564), [#570](https://github.com/opensearch-project/opensearch-go/pull/570), [#579](https://github.com/opensearch-project/opensearch-go/pull/579)) - Bump `github.com/wI2L/jsondiff` from 0.5.1 to 0.6.0 ([#535](https://github.com/opensearch-project/opensearch-go/pull/535), [#566](https://github.com/opensearch-project/opensearch-go/pull/566)) - Bump `github.com/aws/aws-sdk-go-v2/config` from 1.27.11 to 1.27.23 ([#546](https://github.com/opensearch-project/opensearch-go/pull/546), [#553](https://github.com/opensearch-project/opensearch-go/pull/553), [#558](https://github.com/opensearch-project/opensearch-go/pull/558), [#562](https://github.com/opensearch-project/opensearch-go/pull/562), [#567](https://github.com/opensearch-project/opensearch-go/pull/567), [#571](https://github.com/opensearch-project/opensearch-go/pull/571), [#577](https://github.com/opensearch-project/opensearch-go/pull/577)) @@ -176,6 +496,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ## [4.0.0] ### Added + - Adds GlobalIOUsage struct for nodes stats ([#506](https://github.com/opensearch-project/opensearch-go/pull/506)) - Adds the `Explanation` field containing the document explain details to the `SearchHit` struct. ([#504](https://github.com/opensearch-project/opensearch-go/pull/504)) - Adds new error types ([#512](https://github.com/opensearch-project/opensearch-go/pull/506)) @@ -189,6 +510,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) - Adds ism plugin ([#524](https://github.com/opensearch-project/opensearch-go/pull/524)) ### Changed + - Uses docker compose v2 instead of v1 ([#506](https://github.com/opensearch-project/opensearch-go/pull/506)) - Updates go version to 1.21 ([#509](https://github.com/opensearch-project/opensearch-go/pull/509)) - Moves Error structs from opensearchapi to opensearch package ([#512](https://github.com/opensearch-project/opensearch-go/pull/506)) @@ -199,7 +521,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) - Bumps codecov action version to v4 ([#517](https://github.com/opensearch-project/opensearch-go/pull/517)) - Changes bulk error/reason field and some cat response fields to pointer as they can be nil ([#510](https://github.com/opensearch-project/opensearch-go/pull/510)) - Adjust workflows to work with security plugin ([#507](https://github.com/opensearch-project/opensearch-go/pull/507)) -- Updates USER_GUIDE.md and /_samples/ ([#518](https://github.com/opensearch-project/opensearch-go/pull/518)) +- Updates USER_GUIDE.md and add samples ([#518](https://github.com/opensearch-project/opensearch-go/pull/518)) - Updates opensearchtransport.Client to use pooled gzip writer and buffer ([#521](https://github.com/opensearch-project/opensearch-go/pull/521)) - Use go:build tags for testing ([#52?](https://github.com/opensearch-project/opensearch-go/pull/52?)) @@ -208,12 +530,14 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) ### Removed ### Fixed + - Fixes search request missing a slash when no indices are given ([#470](https://github.com/opensearch-project/opensearch-go/pull/469)) - Fixes opensearchtransport check for nil response body ([#517](https://github.com/opensearch-project/opensearch-go/pull/517)) ### Security ### Dependencies + - Bumps `github.com/aws/aws-sdk-go-v2` from 1.25.3 to 1.26.1 - Bumps `github.com/wI2L/jsondiff` from 0.4.0 to 0.5.1 - Bumps `github.com/aws/aws-sdk-go` from 1.50.36 to 1.51.21 @@ -231,7 +555,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) - Updates workflow action versions ([#488](https://github.com/opensearch-project/opensearch-go/pull/488)) - Changes integration tests to work with secure and unsecure OpenSearch ([#488](https://github.com/opensearch-project/opensearch-go/pull/488)) -- Moves functions from `opensearch/internal/test` to `internal/test` for more general test uses ([#488](https://github.com/opensearch-project/opensearch-go/pull/488)) +- Moves functions from `opensearch/internal/test` to `opensearchutil/testutil` for shared test utilities ([#488](https://github.com/opensearch-project/opensearch-go/pull/488)) - Changes `custom_foldername` field to pointer as it can be `null` ([#488](https://github.com/opensearch-project/opensearch-go/pull/488)) - Changs cat indices Primary and Replica field to pointer as it can be `null` ([#488](https://github.com/opensearch-project/opensearch-go/pull/488)) - Replaces `ioutil` with `io` in examples and integration tests [#495](https://github.com/opensearch-project/opensearch-go/pull/495) @@ -364,6 +688,10 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) - Bumps `github.com/stretchr/testify` from 1.8.0 to 1.8.1 - Bumps `github.com/aws/aws-sdk-go` from 1.44.45 to 1.44.132 +[4.7.3]: https://github.com/opensearch-project/opensearch-go/compare/v4.7.2...v4.7.3 +[4.7.2]: https://github.com/opensearch-project/opensearch-go/compare/v4.7.1...v4.7.2 +[4.7.1]: https://github.com/opensearch-project/opensearch-go/compare/v4.7.0...v4.7.1 +[4.7.0]: https://github.com/opensearch-project/opensearch-go/compare/v4.6.0...v4.7.0 [4.6.0]: https://github.com/opensearch-project/opensearch-go/compare/v4.5.0...v4.6.0 [4.5.0]: https://github.com/opensearch-project/opensearch-go/compare/v4.4.0...v4.5.0 [4.4.0]: https://github.com/opensearch-project/opensearch-go/compare/v4.3.0...v4.4.0 diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/COMPATIBILITY.md b/vendor/github.com/opensearch-project/opensearch-go/v4/COMPATIBILITY.md index c70019bd56..c09642c156 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/COMPATIBILITY.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/COMPATIBILITY.md @@ -10,7 +10,9 @@ The below matrix shows the compatibility of the [`opensearch-go`](https://pkg.go | 1.x.0 | 1.x | | 2.x.0 | 1.3.13-2.11.0 | | 3.x.0 | 1.3.13-2.12.0 | -| 4.x.0 | 1.3.20-3.0.0 | +| 4.x.0 | 1.3.20-3.6.x | + +The 4.x client is tested through OpenSearch 3.6.x. Versions beyond that are supported on a best-effort basis. ## Upgrading diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/CONTRIBUTING.md b/vendor/github.com/opensearch-project/opensearch-go/v4/CONTRIBUTING.md index e7b0764fd4..f74ec2a109 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/CONTRIBUTING.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/CONTRIBUTING.md @@ -84,7 +84,7 @@ Each commit must include a DCO which looks like this Signed-off-by: Jane Smith ``` -You may type this line on your own when writing your commit messages. However, if your user.name and user.email are set in your git configs, you can use `-s` or `– – signoff` to add the `Signed-off-by` line to the end of the commit message. +You may type this line on your own when writing your commit messages. However, if your git config `user.name` and `user.email` are set properly, you can use `-s` or `--signoff` to add the `Signed-off-by` line to the end of the commit message. ## Changelog diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/DEVELOPER_GUIDE.md b/vendor/github.com/opensearch-project/opensearch-go/v4/DEVELOPER_GUIDE.md index a265498ff9..7645929902 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/DEVELOPER_GUIDE.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/DEVELOPER_GUIDE.md @@ -8,7 +8,33 @@ - [Unit Testing](#unit-testing) - [Integration Testing](#integration-testing) - [Composing an OpenSearch Docker Container](#composing-an-opensearch-docker-container) + - [Container Providers](#container-providers) - [Execute integration tests from your terminal](#execute-integration-tests-from-your-terminal) + - [Advanced Cluster Configuration](#advanced-cluster-configuration) + - [Cluster Scaling](#cluster-scaling) + - [Heterogeneous Clusters](#heterogeneous-clusters) + - [CPU Limits](#cpu-limits) + - [Node Roles](#node-roles) + - [Combining Overrides](#combining-overrides) + - [Resetting to Defaults](#resetting-to-defaults) + - [Testing Specific OpenSearch Versions](#testing-specific-opensearch-versions) + - [Cluster Status and Troubleshooting](#cluster-status-and-troubleshooting) + - [Network Latency Simulation](#network-latency-simulation) + - [Latency Profiles](#latency-profiles) + - [Inspecting and Clearing Latency](#inspecting-and-clearing-latency) + - [Code Generation](#code-generation) + - [Demo](#demo) + - [Verification Matrix](#verification-matrix) + - [Individual Verifications](#individual-verifications) + - [Workload and Fanout Comparisons](#workload-and-fanout-comparisons) + - [Full Matrix](#full-matrix) + - [Reviewing Results](#reviewing-results) + - [Inspecting CI Failures](#inspecting-ci-failures) + - [Quick Summary](#quick-summary) + - [Detailed Failure Output](#detailed-failure-output) + - [Failure Context](#failure-context) + - [Full Logs](#full-logs) + - [Inspecting a Specific Run](#inspecting-a-specific-run) - [Lint](#lint) - [Markdown lint](#markdown-lint) - [Go lint](#go-lint) @@ -42,6 +68,7 @@ OpenSearch Go Client builds using [Go](https://go.dev/doc/install) 1.24 at a min To build the project on Windows, use [WSL2](https://learn.microsoft.com/en-us/windows/wsl/install), the compatibility layer for running Linux applications. Install `make` + ``` sudo apt install make ``` @@ -67,7 +94,7 @@ In order to test opensearch-go client, you need a running OpenSearch cluster. Yo ### Composing an OpenSearch Docker Container -Ensure that Docker is installed on your local machine. You can check by running `docker --version`. Next, navigate to your local opensearch-go repository. Run the following command to build and start the OpenSearch docker container. +Ensure that Docker is installed on your local machine. You can check by running `docker --version`. Next, navigate to your local opensearch-go repository. Run the following command to build and start the OpenSearch docker container. ``` make cluster.build cluster.start @@ -75,7 +102,30 @@ make cluster.build cluster.start This command will start the OpenSearch container using the `docker-compose.yaml` configuration file. During the build process, the necessary dependencies and files will be downloaded, which may take some time depending on your internet connection and system resources. -Once the container is built and running, you can open a web browser and navigate to localhost:9200 to access the OpenSearch docker container. +Once the container is built and running, you can open a web browser and navigate to localhost:9200 to access the OpenSearch docker container. + +#### Container Providers + +The cluster targets work with any of three container providers. When you do not specify one, the Makefile auto-detects a provider by CLI presence in this order: + +1. **Colima** (`colima` on `PATH`) +2. **Rancher Desktop** (`rdctl` on `PATH`) +3. **Docker** / Docker Desktop (`docker` on `PATH`) + +Override the choice explicitly with `CONTAINER_PROVIDER`: + +``` +CONTAINER_PROVIDER=docker make cluster.start +``` + +Selecting a provider does four things: + +- Pins the docker context commands talk to (`colima` for Colima, `rancher-desktop` for Rancher; the Docker provider leaves your active context alone). If `DOCKER_CONTEXT` is already set in your environment, it is respected and not overridden. +- Resolves the CLI runtime `$(CTR)` (defaults to `docker` for every provider). For advanced containerd use you can force `CONTAINER_RUNTIME=nerdctl`, though docker-context pinning does not apply to nerdctl. +- Ensures the backing VM/daemon is running (`make cluster.provider.ensure`, run automatically by `cluster.start`), starting it if needed. +- Sets `vm.max_map_count=262144` through the provider's VM (`colima ssh` / `rdctl shell`) or, for the Docker provider, a privileged helper container. + +Run `make cluster.runtime` to see the detected provider, docker context, and runtime. In order to differentiate unit tests from integration tests, Go has a built-in mechanism for allowing you to logically separate your tests with [build tags](https://pkg.go.dev/cmd/go#hdr-Build_constraints). The build tag needs to be placed as close to the top of the file as possible, and must have a blank line beneath it. Hence, create all integration tests with build tag 'integration'. @@ -94,6 +144,334 @@ In order to differentiate unit tests from integration tests, Go has a built-in m make cluster.stop cluster.clean ``` +## Advanced Cluster Configuration + +By default, `make cluster.start` launches a 3-node cluster where every node has the same resources and roles (`cluster_manager,data,ingest`). The targets below let you customize the cluster for testing weighted round-robin routing, role-based request routing, and other behavior that only surfaces with non-uniform nodes. + +### Cluster Scaling + +Scale the running cluster to a different number of nodes without rebuilding: + +``` +make cluster.scale.1 # Single-node cluster +make cluster.scale.2 # 2-node cluster +make cluster.scale.3 # Full 3-node cluster (default) +``` + +### Heterogeneous Clusters + +Override files let you change CPU limits and node roles independently. Each target writes a Docker Compose override file under `.ci/opensearch/` that is automatically merged with `docker-compose.yml` on the next `cluster.build` or `cluster.start`. The override files are not checked into source control. + +The override file paths are: + +| Override | File | +| ---------- | -------------------------------------------------- | +| CPU limits | `.ci/opensearch/docker-compose.cpu-override.yml` | +| Node roles | `.ci/opensearch/docker-compose.roles-override.yml` | + +These are standard Docker Compose files. You can hand-edit them for custom configurations (e.g., different CPU ratios or role combinations not covered by the Make targets), or remove individual files to selectively reset one dimension while keeping the other: + +``` +# Remove only the CPU override, keep roles +rm .ci/opensearch/docker-compose.cpu-override.yml + +# Remove only the roles override, keep CPU limits +rm .ci/opensearch/docker-compose.roles-override.yml +``` + +#### CPU Limits + +Set per-node CPU limits so the client's weighted round-robin allocates proportional traffic. The `deploy.resources.limits.cpus` value is reported by each node via `GET /_nodes/os` as `allocated_processors`, which the client uses to compute connection weights. + +``` +# Balanced weights [1,1,2] +make cluster.heterogeneous.cpu.1 # node1=2, node2=2, node3=4 CPUs + +# Skewed weights [1,2,4] +make cluster.heterogeneous.cpu.2 # node1=1, node2=2, node3=4 CPUs +``` + +#### Node Roles + +Assign different roles to each node so the client's role-based routing policy can direct requests to the correct nodes (e.g., bulk requests to ingest-capable nodes, search requests to data nodes): + +``` +make cluster.heterogeneous.roles # node1=cluster_manager+ingest, node2=data+ingest, node3=data +``` + +#### Combining Overrides + +CPU and role overrides are independent files and can be combined. Set both, then rebuild: + +``` +make cluster.heterogeneous.cpu.1 cluster.heterogeneous.roles +make cluster.stop cluster.clean cluster.build cluster.start +``` + +Verify the resulting configuration: + +``` +curl -sk 'https://admin:myStrongPassword123%21@localhost:9200/_nodes/http,os?pretty' \ + | jq '.nodes[] | {name, roles: .roles, processors: .os.allocated_processors}' +``` + +#### Resetting to Defaults + +Remove all override files and return to the default homogeneous 3-node cluster: + +``` +make cluster.homogeneous +make cluster.stop cluster.clean cluster.build cluster.start +``` + +### Testing Specific OpenSearch Versions + +The cluster supports any published OpenSearch Docker image version. Always clean before switching versions to avoid stale data or cached images: + +``` +make cluster.stop +OPENSEARCH_VERSION=3.6.0 make cluster.clean cluster.build cluster.start +make test-integ +``` + +Set `SECURE_INTEGRATION=false` to disable TLS and basic auth: + +``` +SECURE_INTEGRATION=false OPENSEARCH_VERSION=3.6.0 make cluster.clean cluster.build cluster.start +``` + +### Cluster Status and Troubleshooting + +Use `make cluster.status` to display cluster health, node info, Docker container state, and index/shard details. It auto-detects whether the cluster is running in secure or insecure mode. + +``` +make cluster.status +``` + +## Network Latency Simulation + +The `cluster.latency.*` targets inject artificial network delay into running Docker containers using Linux `tc` (traffic control). This lets you test the client's RTT-bucketed connection scoring and congestion-aware routing under realistic network topologies without leaving your development machine. + +All latency targets use `tc qdisc` with `netem` delay and require the cluster to be running. They operate on the Docker container network interfaces directly. + +### Latency Profiles + +Four predefined profiles cover common deployment topologies: + +``` +# Asymmetric — simulates 3 availability zones at different distances +make cluster.latency.asymmetric # node1=0ms, node2=50ms ±5ms, node3=150ms ±15ms + +# Symmetric — single data center, all nodes equidistant +make cluster.latency.symmetric # all nodes 1ms ±100us + +# Bimodal — 2 local nodes + 1 remote node +make cluster.latency.bimodal # node1=1ms, node2=1ms, node3=20ms + +# Graduated — wide spread across 3 tiers +make cluster.latency.graduated # node1=1ms, node2=10ms, node3=100ms +``` + +### Inspecting and Clearing Latency + +``` +# Show current tc qdisc rules on each node +make cluster.latency.show + +# Remove all artificial latency +make cluster.latency.clear +``` + +## Demo + +The `cmd/demo` binary exercises the client with affinity routing enabled, printing live per-node request distribution and latency statistics. It connects to a running cluster and generates configurable workloads. + +``` +make demo.build # Build bin/demo +make demo.run # Build and run with default affinity-visible settings +``` + +`demo.run` connects to all three local nodes with request routing, node discovery, and periodic stats output. The binary accepts flags for concurrency, workload type, fanout, and report output — run `bin/demo -help` for the full list. + +## Verification Matrix + +The `verify.*` targets automate end-to-end validation of the client's affinity routing behavior. Each target applies a latency profile, runs a workload through the demo binary, and writes a JSON report to `reports/verify/`. + +### Individual Verifications + +Run a single latency profile with the default search workload: + +``` +make verify.symmetric # Equal distribution under symmetric latency +make verify.asymmetric # Tier equalization under asymmetric latency (0/50/150ms) +make verify.bimodal # 2-local + 1-remote equalization (1/1/20ms) +make verify.graduated # Wide tier-spread equalization (1/10/100ms) +``` + +### Workload and Fanout Comparisons + +``` +# Compare fanout=1 vs fanout=2 vs fanout=3 under bimodal latency +make verify.fanout + +# Compare search, read-write, bulk-write, and write-only across all latency profiles +make verify.workloads + +# Verify CPU-proportional distribution with heterogeneous CPUs [1,2,4] +make verify.hetero.cpu +``` + +### Full Matrix + +Run every combination of latency profile, workload, fanout, and hardware configuration: + +``` +make verify.matrix +``` + +Reports are written to `reports/verify/`. The full matrix takes several minutes to complete. + +### Reviewing Results + +``` +# Print a tabular summary of all reports (name, total, RPS, P50, P99, connections) +make verify.summary + +# Validate that distribution expectations are met +make verify.check +``` + +## Inspecting CI Failures + +When a GitHub Actions check fails, searching the raw logs for keywords like "fail" or "error" produces many false positives from test names that legitimately contain those words. The `gh.fail.*` Makefile targets use the `gh` CLI to fetch only the failed steps and extract Go's structured failure markers (`--- FAIL:`, `FAIL\t`, `panic:`), giving clean output with no noise. + +All targets auto-detect the most recent failed run on the current branch. Requires the [GitHub CLI](https://cli.github.com/) (`gh`) to be installed and authenticated. + +### Quick Summary + +Show which jobs failed and a deduplicated list of failed test names: + +``` +make gh.fail.summary +``` + +Example output: + +``` +Run 22722089811 — failed jobs: + ✗ integ-test-compat (true, 2.19.5) + ✗ integ-test-compat (false, 3.6.0) + +Failed tests: + --- FAIL: TestShardExactRouting_FullPipeline_Integration (2.56s) + --- FAIL: TestShardExactRouting_FullPipeline_Integration/pipeline/routing=0 (0.01s) + --- FAIL: TestShardExactRouting_FullPipeline_Integration/pipeline/routing=order-12345 (0.01s) +``` + +### Detailed Failure Output + +Show all `--- FAIL:`, `FAIL`, and `panic:` lines with the job/step/timestamp prefix stripped: + +``` +make gh.fail +``` + +### Failure Context + +Show 5 lines of context before each `--- FAIL:` or `panic:` line. This surfaces the assertion error messages (e.g., `Error:`, `Messages:`, `Error Trace:`) that explain why the test failed: + +``` +make gh.fail.context +``` + +### Full Logs + +Dump the complete log output from all failed steps (raw `gh run view --log-failed`): + +``` +make gh.fail.full +``` + +### Inspecting a Specific Run + +All targets accept a `GH_RUN_ID` override to inspect any run, not just the most recent failure: + +``` +make gh.fail.summary GH_RUN_ID=22705106053 +``` + +To find run IDs, list recent checks: + +``` +make gh.checks # All checks on the current branch +make gh.checks.failed # Only failed checks +``` + +## Code Generation + +The `cmd/osgen` tool generates typed path builder structs (`internal/path/`) and API consumer files (`v5preview/opensearchapi/`, `v5preview/opensearchapi/plugins/`) from the published [OpenSearch API specification](https://github.com/opensearch-project/opensearch-api-specification). It reads `x-operation-group`, `x-version-added`, `x-version-deprecated`, `x-version-removed`, and `x-error-responses` extensions from the spec to produce version-aware Go source. + +The `v5preview/opensearchapi/` package is the v5-track API surface and coexists with the hand-written `opensearchapi/` package during the v4 -> v5 transition. New code should target `v5preview/opensearchapi/`; see `v5preview/opensearchapi/README.md` for usage and `UPGRADING.md` for migration guidance. + +> **PRs that edit `*_gen.go` will be rejected.** These files are generated. To change them, send a PR against `cmd/osgen` (the generator) or against the [OpenSearch API specification](https://github.com/opensearch-project/opensearch-api-specification) (the input). + +> **Spec-extension status.** Some `x-*` extensions osgen reads (notably `x-error-responses`) are still in flight upstream. Until they merge, the build pulls from the local `opensearch-openapi.yaml` checkout in this repo rather than the published spec. Once upstream catches up, the local file goes away. + +### Partial-failure error generation + +The `x-error-responses` extension on a spec operation declares the categories of partial failure that operation can produce. For each category named on an operation, osgen emits: + +- A typed Go error (e.g. `*PartialBulkError`, `*PartialSearchError`, `*ShardFailureError`, `*MultiSearchItemError`) decoded from the response body when that category fires. +- A bit on `errmask.ErrorMask` (PascalCase, e.g. `errmask.BulkItems`) plus the corresponding env-var token (`bulk_items`) so callers can suppress or surface it via `Config.Errors` or `OPENSEARCH_GO_ERROR_MASK`. +- A per-Resp helper method on the operation's typed response (e.g. `BulkResp.BulkItemFailures()`, `SearchResp.SearchShardFailures()`). These exist as engine machinery for the dispatch and are not the recommended call-site pattern; user docs point callers at a `for`/`switch` over `opensearchapi.Errors(err)` instead. +- A `PartialFailures(mask)` aggregator on the same Resp. + +Operations that declare two or more categories also get a per-op error container (e.g. `*MSearchErrors`) implementing `Unwrap() []error`, used when more than one category fires on a single response. + +The user-facing partial-failure model and best-practices guidance live in [`v5preview/opensearchapi/README.md`](v5preview/opensearchapi/README.md#partial-failure-errors) and [`guides/error_handling.md`](guides/error_handling.md). They deliberately omit `x-error-responses` terminology because callers don't need to read the spec to use the resulting errors. The spec-driven mechanics are documented here and in [`cmd/osgen/README.md`](cmd/osgen/README.md). + +To regenerate (downloads the spec automatically if not cached): + +``` +make gen +``` + +To force a fresh spec download, remove the cached file first: + +``` +rm -f opensearch-openapi.yaml +make gen +``` + +### Version-Scoped Generation + +By default, `make gen` includes all operations and fields across every OpenSearch version. Three Makefile variables scope the generated output to a version window: + +| Variable | Default | Effect | +| ----------------------- | -------- | -------------------------------------------------------- | +| `GEN_MIN_VERSION` | `epoch` | Exclude operations removed before this floor | +| `GEN_MAX_VERSION` | `latest` | Exclude operations added after this ceiling | +| `GEN_REMOVE_DEPRECATED` | `epoch` | Treat operations deprecated at or before this as removed | + +Override on the command line: + +``` +# Generate a client targeting only OpenSearch 2.x+, dropping deprecated APIs +make gen GEN_MIN_VERSION=2.0 GEN_REMOVE_DEPRECATED=2.0 + +# Generate a client for a specific version range +make gen GEN_MIN_VERSION=2.0 GEN_MAX_VERSION=2.99 + +# Strict less-than ceiling (excludes 3.0.0 itself) +make gen GEN_MAX_VERSION="<3.0.0" +``` + +Version flags accept an optional operator prefix (`>=`, `>`, `<=`, `<`). When omitted, `--min-version` defaults to `>=` and `--max-version` defaults to `<=`. The magic values `epoch` (no floor) and `latest` (no ceiling) mean "include everything". + +When items are excluded by version filtering, breadcrumb comments are left in the generated code explaining the reason (e.g., `// cat.masterPath: deprecated in OpenSearch 2.0.0 (treated as removed).`). Breadcrumb visibility is configurable per category via `-version-breadcrumb-*` flags. + +See [`cmd/osgen/README.md`](cmd/osgen/README.md) for the full flag reference and subcommand details. + ## Lint To keep all the code in a certain uniform format, it was decided to use some writing rules. If you wrote something wrong, it's okay, you can simply run the script to check the necessary files, and optionally format the content. But keep in mind that all these checks are repeated on the pipeline, so it's better to check locally. @@ -143,5 +521,4 @@ After you have opened your project, you need to specify the location of the Go S ### Vim -To improve your vim experience with Go, you might want to check out [fatih/vim-go](https://github.com/fatih/vim-go). -For example it correctly formats the file and validates it on save. +To improve your vim experience with Go, you might want to check out [fatih/vim-go](https://github.com/fatih/vim-go). For example it correctly formats the file and validates it on save. diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/MAINTAINERS.md b/vendor/github.com/opensearch-project/opensearch-go/v4/MAINTAINERS.md index aedb8850bd..896c5f2960 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/MAINTAINERS.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/MAINTAINERS.md @@ -9,6 +9,7 @@ This document contains a list of maintainers in this repo. See [opensearch-proje | Jakob Hahn | [Jakob3xD](https://github.com/Jakob3xD) | Hetzner Online GmbH | | Vacha Shah | [VachaShah](https://github.com/VachaShah) | Amazon | | Vijayan Balasubramanian | [VijayanB](https://github.com/VijayanB) | Amazon | +| Sean Chittenden | [sean-](https://github.com/sean-) | CrowdStrike | ## Emeritus diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/Makefile b/vendor/github.com/opensearch-project/opensearch-go/v4/Makefile index d95b2a21b8..1b6f1aa536 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/Makefile +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/Makefile @@ -1,90 +1,271 @@ SHELL := /bin/bash -##@ Format project using goimports tool -format: +# Tool versions +GOLANGCI_LINT_VERSION := v2.12.2 + +# Build tags for linting. +# +# golangci-lint can only compile ONE point in the build-tag space per run, so a +# single invocation can never lint every file. Two mutually-exclusive boolean +# axes partition the tree: +# - integration vs !integration: every unit *_test.go is `!integration`; every +# integration test is `integration`. Setting `integration` drops all unit +# test files from the type-check, and omitting it drops all integration ones. +# - multinode vs !multinode (within integration only): the single-node +# integration files are `!multinode`; the multinode ones require `multinode`. +# The feature tags below are pure-OR alternatives -- `core` satisfies every +# `(core || X)` constraint and `plugins` every `(plugins || X)` one -- so they +# union harmlessly into every run. Complete coverage therefore requires running +# golangci-lint once per (integration, multinode) combination with the feature +# tags unioned in. GOLANGCI_LINT_TAG_SETS enumerates those runs; each element is +# one quoted --build-tags argument. GOLANGCI_LINT_BUILD_TAGS is retained as the +# maximal set for the osgen module, which has no build-constrained files. +GOLANGCI_LINT_FEATURE_TAGS := core plugins plugin_security plugin_index_management +GOLANGCI_LINT_BUILD_TAGS := "integration $(GOLANGCI_LINT_FEATURE_TAGS) multinode" +GOLANGCI_LINT_TAG_SETS := \ + "$(GOLANGCI_LINT_FEATURE_TAGS)" \ + "integration $(GOLANGCI_LINT_FEATURE_TAGS)" \ + "integration $(GOLANGCI_LINT_FEATURE_TAGS) multinode" + +# Container provider detection: prefer Colima, then Rancher Desktop, then Docker. +# A provider is the machine/daemon backing the containers; it drives the docker +# context commands talk to, the CLI runtime $(CTR) resolves to, whether the VM +# is started (cluster.provider.ensure), and how vm.max_map_count is set +# (cluster.sysctl). Override with CONTAINER_PROVIDER=colima|rancher|docker. +# Detection is by CLI presence in the order colima -> rancher (rdctl) -> docker. +ifndef CONTAINER_PROVIDER + ifneq (,$(shell command -v colima 2>/dev/null)) + CONTAINER_PROVIDER := colima + else ifneq (,$(shell command -v rdctl 2>/dev/null)) + CONTAINER_PROVIDER := rancher + else ifneq (,$(shell command -v docker 2>/dev/null)) + CONTAINER_PROVIDER := docker + endif +endif + +# Docker context to pin per provider. Colima and Rancher Desktop each register a +# named docker context; the plain docker provider leaves the active context +# alone. Exported below so every recipe shell targets the right daemon. +PROVIDER_CONTEXT := $(if $(filter colima,$(CONTAINER_PROVIDER)),colima,$(if $(filter rancher,$(CONTAINER_PROVIDER)),rancher-desktop,)) +ifneq ($(PROVIDER_CONTEXT),) + ifneq ($(origin DOCKER_CONTEXT),environment) + export DOCKER_CONTEXT := $(PROVIDER_CONTEXT) + endif +endif + +# Container runtime (CLI): defaults to docker for every provider, since Colima +# and Rancher Desktop both ship a docker shim and register a docker context. +# Override with CONTAINER_RUNTIME=nerdctl for advanced containerd use (docker +# context pinning does not apply to nerdctl). +# Detection is lazy: only targets that use $(CTR) or $(CTR_COMPOSE) will fail +# if no runtime is available, allowing test-unit to work without a provider. +ifndef CONTAINER_RUNTIME + ifneq (,$(shell command -v docker 2>/dev/null)) + CONTAINER_RUNTIME := docker + else ifneq (,$(shell command -v nerdctl 2>/dev/null)) + CONTAINER_RUNTIME := nerdctl + endif +endif +CTR = $(if $(CONTAINER_RUNTIME),$(CONTAINER_RUNTIME),$(error No container runtime found. Install a provider (colima, rancher, or docker) or set CONTAINER_RUNTIME.)) +REPO_ROOT := $(shell git rev-parse --show-toplevel 2>/dev/null || pwd) + +# Compose with optional override files for heterogeneous clusters. +# Override files are generated by cluster.heterogeneous.* targets and removed +# by cluster.homogeneous. When no overrides exist, CTR_COMPOSE falls back +# to the default: $(CTR) compose --project-directory .ci/opensearch. +COMPOSE_DIR := .ci/opensearch +COMPOSE_OVERRIDES = $(wildcard $(COMPOSE_DIR)/docker-compose.*-override.yml) +COMPOSE_FILES = $(if $(COMPOSE_OVERRIDES),-f $(COMPOSE_DIR)/docker-compose.yml $(addprefix -f ,$(COMPOSE_OVERRIDES))) +CTR_COMPOSE = $(CTR) compose --project-directory $(COMPOSE_DIR) $(COMPOSE_FILES) + +##@ Formatting +format: ## Format all Go files with goimports goimports -w .; -##@ Test -test-unit: ## Run unit tests - @printf "\033[2m→ Running unit tests...\033[0m\n" +##@ Testing +test-unit: ## Run unit tests across all modules (root + cmd/osgen) + @printf "\033[2m-> Running unit tests...\033[0m\n" ifdef race $(eval testunitargs += "-race") + $(eval testosgenargs += "-race") endif $(eval testunitargs += "-cover" "./..." "-args" "-test.gocoverdir=$(PWD)/tmp/unit") - @mkdir -p $(PWD)/tmp/unit + $(eval testosgenargs += "-cover" "./..." "-args" "-test.gocoverdir=$(PWD)/tmp/osgen") + @rm -rf $(PWD)/tmp/unit $(PWD)/tmp/osgen + @mkdir -p $(PWD)/tmp/unit $(PWD)/tmp/osgen @echo "go test -v" $(testunitargs); \ - go test -v $(testunitargs); + go test -v $(testunitargs) 2>&1 | tee test-unit.log; \ + exit $${PIPESTATUS[0]}; + @printf "\033[2m-> Running cmd/osgen unit tests (separate module)...\033[0m\n" + @echo "(cd cmd/osgen && go test -v" $(testosgenargs) ")"; \ + cd cmd/osgen && go test -v $(testosgenargs) 2>&1 | tee $(PWD)/test-osgen.log; \ + exit $${PIPESTATUS[0]}; ifdef coverage @go tool covdata textfmt -i=$(PWD)/tmp/unit -o $(PWD)/tmp/unit.cov + @go tool covdata textfmt -i=$(PWD)/tmp/osgen -o $(PWD)/tmp/osgen.cov endif test: test-unit test-integ: ## Run integration tests - @printf "\033[2m→ Running integration tests...\033[0m\n" + @printf "\033[2m-> Running integration tests...\033[0m\n" $(eval testintegtags += "integration,core,plugins") + $(eval testintegdir ?= integration) + $(eval OPENSEARCH_NODE_COUNT ?= 3) ifdef multinode $(eval testintegtags += "multinode") endif ifdef race $(eval testintegargs += "-race") endif - $(eval testintegargs += "-cover" "-tags=$(testintegtags)" "-timeout=1h" "./..." "-args" "-test.gocoverdir=$(PWD)/tmp/integration") - @mkdir -p $(PWD)/tmp/integration + $(eval TEST_PARALLEL ?= $(shell ncpu=$$(sysctl -n hw.ncpu 2>/dev/null || nproc 2>/dev/null || echo 4); parallel=$$((ncpu / 2)); [ $$parallel -lt 1 ] && parallel=1; echo $$parallel)) + $(eval TEST_TIMEOUT ?= 10m) + $(eval testintegargs += "-cover" "-tags=$(testintegtags)" "-timeout=$(TEST_TIMEOUT)" "-parallel=$(TEST_PARALLEL)" "./..." "-args" "-test.gocoverdir=$(PWD)/tmp/$(testintegdir)") + @rm -rf $(PWD)/tmp/$(testintegdir) + @mkdir -p $(PWD)/tmp/$(testintegdir) @echo "go test -v" $(testintegargs); \ - go test -v $(testintegargs); + OPENSEARCH_NODE_COUNT=$(OPENSEARCH_NODE_COUNT) go test -v $(testintegargs) 2>&1 | tee test-integ.log; \ + exit $${PIPESTATUS[0]}; ifdef coverage - @go tool covdata textfmt -i=$(PWD)/tmp/integration -o $(PWD)/tmp/integ.cov + @go tool covdata textfmt -i=$(PWD)/tmp/$(testintegdir) -o $(PWD)/tmp/$(testintegdir).cov endif test-integ-core: ## Run base integration tests - @make test-integ testintegtags=integration,core + @$(MAKE) test-integ testintegtags=integration,core testintegdir=integration-core test-integ-plugins: ## Run plugin integration tests - @make test-integ testintegtags=integration,plugins + @$(MAKE) test-integ testintegtags=integration,plugins testintegdir=integration-plugins -test-integ-secure: ##Run secure integration tests - @SECURE_INTEGRATION=true make test-integ +test-integ-secure: ## Run secure integration tests + @SECURE_INTEGRATION=true $(MAKE) test-integ test-integ-core-secure: ## Run secure base integration tests - @SECURE_INTEGRATION=true make test-integ testintegtags=integration,core + @SECURE_INTEGRATION=true $(MAKE) test-integ testintegtags=integration,core test-integ-plugins-secure: ## Run secure plugin integration tests - @SECURE_INTEGRATION=true make test-integ testintegtags=integration,plugins + @SECURE_INTEGRATION=true $(MAKE) test-integ testintegtags=integration,plugins + +test-all: ## Run all tests with all build tags (unit + integration) + @printf "\033[2m-> Running all unit tests...\033[0m\n" + @$(MAKE) test-unit + @printf "\033[2m-> Running all integration tests with all tags...\033[0m\n" + @$(MAKE) test-integ testintegtags=integration,core,plugins,plugin_security,plugin_index_management,multinode +test-race: ## Run all tests with race detection enabled + @printf "\033[2m-> Running all unit tests with race detection...\033[0m\n" + @$(MAKE) test-unit race=true + @printf "\033[2m-> Running all integration tests with race detection and all tags...\033[0m\n" + @$(MAKE) test-integ race=true testintegtags=integration,core,plugins,plugin_security,plugin_index_management,multinode test-bench: ## Run benchmarks - @printf "\033[2m→ Running benchmarks...\033[0m\n" - go test -run=none -bench=. -benchmem ./... + @printf "\033[2m-> Running benchmarks...\033[0m\n" + go test -run=none -bench=. -benchmem -benchtime=200ms ./... coverage: ## Print test coverage report - @make gen-coverage + @$(MAKE) gen-coverage @go tool cover -func=$(PWD)/tmp/total.cov @printf "\033[0m--------------------------------------------------------------------------------\n\033[0m" coverage-html: ## Open test coverage report in browser - @make gen-coverage + @$(MAKE) gen-coverage @go tool cover -html $(PWD)/tmp/total.cov gen-coverage: ## Generate test coverage report - @printf "\033[2m→ Generating test coverage report...\033[0m\n" + @printf "\033[2m-> Generating test coverage report...\033[0m\n" @rm -rf tmp @mkdir tmp @mkdir tmp/unit @mkdir tmp/integration - @make test-unit coverage=true - @make test-integ coverage=true - @make build-coverage + @$(MAKE) test-unit coverage=true + @$(MAKE) test-integ coverage=true + @$(MAKE) build-coverage build-coverage: @go tool covdata textfmt -i=$(PWD)/tmp/unit,$(PWD)/tmp/integration -o $(PWD)/tmp/total.cov +OPENAPI_SPEC := $(REPO_ROOT)/opensearch-openapi.yaml +OPENAPI_SPEC_URL := https://github.com/opensearch-project/opensearch-api-specification/releases/latest/download/opensearch-openapi.yaml + +# Generated code output directories. +GEN_PATH_DIR := $(REPO_ROOT)/internal/path +GEN_OSAPI_DIR := $(REPO_ROOT)/v5preview/opensearchapi +GEN_PLUGINS_DIR := $(GEN_OSAPI_DIR)/plugins + +# Version filtering defaults for code generation. +# Override on the command line to scope generated code to a version window: +# make gen GEN_MIN_VERSION=2.0 GEN_REMOVE_DEPRECATED=2.0 +GEN_MIN_VERSION ?= epoch +GEN_MAX_VERSION ?= latest +GEN_REMOVE_DEPRECATED ?= epoch + ##@ Development +fetch-opensearch-spec: ## Download the OpenSearch OpenAPI spec (skips if already present) + @if [ ! -f "$(OPENAPI_SPEC)" ]; then \ + printf "\033[2m-> Downloading %s...\033[0m\n" "$(OPENAPI_SPEC)"; \ + curl -sSfL "$(OPENAPI_SPEC_URL)" -o "$(OPENAPI_SPEC)"; \ + else \ + printf "\033[2m-> %s already present\033[0m\n" "$(OPENAPI_SPEC)"; \ + fi + +fetch-opensearch-spec-force: ## Re-download the OpenSearch OpenAPI spec from upstream + @printf "\033[2m-> Downloading %s...\033[0m\n" "$(OPENAPI_SPEC)" + @curl -sSfL "$(OPENAPI_SPEC_URL)" -o "$(OPENAPI_SPEC)" + +clean-gen: ## Remove all generated Go files (v5preview/opensearchapi, plugins, internal/path) + @printf "\033[2m-> Removing generated files...\033[0m\n" + @rm -f $(GEN_PATH_DIR)/builders_gen.go $(GEN_PATH_DIR)/builders_gen_test.go + @rm -f $(GEN_OSAPI_DIR)/*_gen.go $(GEN_OSAPI_DIR)/*_gen_test.go + @find $(GEN_PLUGINS_DIR) -name '*_gen.go' -o -name '*_gen_test.go' | xargs rm -f 2>/dev/null || true + +gen-paths: fetch-opensearch-spec ## Regenerate path builders only + @printf "\033[2m-> Regenerating path builders...\033[0m\n" + cd $(REPO_ROOT)/cmd/osgen && go run . paths \ + -spec $(OPENAPI_SPEC) \ + -pkg path \ + -o $(GEN_PATH_DIR)/builders_gen.go \ + -test-out $(GEN_PATH_DIR)/builders_gen_test.go \ + -min-version=$(GEN_MIN_VERSION) \ + -max-version=$(GEN_MAX_VERSION) \ + -remove-deprecated=$(GEN_REMOVE_DEPRECATED) + +gen-api: fetch-opensearch-spec ## Regenerate API consumer files only + @printf "\033[2m-> Regenerating API consumer files...\033[0m\n" + cd $(REPO_ROOT)/cmd/osgen && go run . api \ + -spec $(OPENAPI_SPEC) \ + -out $(GEN_OSAPI_DIR) \ + -pkg opensearchapi \ + -plugins-out $(GEN_PLUGINS_DIR) \ + -min-version=$(GEN_MIN_VERSION) \ + -max-version=$(GEN_MAX_VERSION) \ + -remove-deprecated=$(GEN_REMOVE_DEPRECATED) + +gen: gen-paths gen-api ## Regenerate all code from OpenAPI spec (run gen-paths and gen-api in parallel with `make -j gen`) + +regen: clean-gen gen ## Clean generated files then regenerate from spec + +test-gen: regen ## Regen then run unit + integration tests (ensures tests use fresh output) + @$(MAKE) test-unit + @printf "\033[2m-> Running integration tests...\033[0m\n" + $(eval SECURE_INTEGRATION ?= true) + @SECURE_INTEGRATION=$(SECURE_INTEGRATION) go test -v -tags=integration -count=1 -timeout=5m ./v5preview/opensearchapi/... + lint: ## Run lint on the package - @make linters + @$(MAKE) linters + +lint.headers: ## Check license headers on all Go files (same check as CI) + @.github/check-license-headers.sh + +lint.local: ## Run lint locally (not in Docker) across all build-tag combinations + @printf "\033[2m-> Running golangci-lint locally across all build-tag sets...\033[0m\n" + @for tags in $(GOLANGCI_LINT_TAG_SETS); do \ + printf "\033[2m --build-tags %s\033[0m\n" "$$tags"; \ + golangci-lint run --fix --build-tags "$$tags" --timeout=5m -v ./... || exit $$?; \ + done + @printf "\033[2m-> Running golangci-lint in cmd/osgen (separate Go module)...\033[0m\n" + cd cmd/osgen && golangci-lint run --fix --build-tags $(GOLANGCI_LINT_BUILD_TAGS) --timeout=5m -v ./... package := "prettier" lint.markdown: - @printf "\033[2m→ Checking node installed...\033[0m\n" + @printf "\033[2m-> Checking node installed...\033[0m\n" if type node > /dev/null 2>&1 && which node > /dev/null 2>&1 ; then \ node -v; \ echo -e "\033[33m Node is installed, continue...\033[0m\n"; \ @@ -92,7 +273,7 @@ lint.markdown: echo -e "\033[31m Please install node\033[0m\n"; \ exit 1; \ fi - @printf "\033[2m→ Checking npm installed...\033[0m\n" + @printf "\033[2m-> Checking npm installed...\033[0m\n" if type npm > /dev/null 2>&1 && which npm > /dev/null 2>&1 ; then \ npm -v; \ echo -e "\033[33m NPM is installed, continue...\033[0m\n"; \ @@ -100,18 +281,18 @@ lint.markdown: echo -e "\033[31m Please install npm\033[0m\n"; \ exit 1; \ fi - @printf "\033[2m→ Checking $(package) installed...\033[0m\n" + @printf "\033[2m-> Checking $(package) installed...\033[0m\n" if [ `npm list -g | grep -c $(package)` -eq 0 -o ! -d node_module ]; then \ echo -e "\033[33m Installing $(package)...\033[0m"; \ npm install -g $(package) --no-shrinkwrap; \ fi @printf "\033[2m→ Running markdown lint...\033[0m\n" - if npx $(package) --prose-wrap never --check **/*.md; [[ $$? -ne 0 ]]; then \ + if npx $(package) --prose-wrap never --print-width 300 --check **/*.md; [[ $$? -ne 0 ]]; then \ echo -e "\033[32m→ Found invalid files. Want to auto-format invalid files? (y/n) \033[0m"; \ read RESP; \ - if [[ $$RESP = "y" || $$RESP = "Y" ]]; then \ + if [ "$$RESP" = "y" ] || [ "$$RESP" = "Y" ]; then \ echo -e "\033[33m Formatting...\033[0m"; \ - npx $(package) --prose-wrap never --write **/*.md; \ + npx $(package) --prose-wrap never --print-width 300 --write **/*.md; \ echo -e "\033[34m \nAll invalid files are formatted\033[0m"; \ else \ echo -e "\033[33m Unfortunately you are cancelled auto fixing. But we will definitely fix it in the pipeline\033[0m"; \ @@ -130,7 +311,7 @@ else $(eval branches_list = $(shell echo $(branches) | tr ',' ' ') ) endif $(eval commits_list = $(shell echo $(commits) | tr ',' ' ')) - @printf "\033[2m→ Backporting commits [$(commits)]\033[0m\n" + @printf "\033[2m-> Backporting commits [$(commits)]\033[0m\n" @{ \ set -e -o pipefail; \ for commit in $(commits_list); do \ @@ -138,7 +319,7 @@ endif done; \ echo ""; \ for branch in $(branches_list); do \ - printf "\033[2m→ $$branch\033[0m\n"; \ + printf "\033[2m-> $$branch\033[0m\n"; \ git checkout $$branch; \ for commit in $(commits_list); do \ git cherry-pick -x $$commit; \ @@ -146,7 +327,7 @@ endif git status --short --branch; \ echo ""; \ done; \ - printf "\033[2m→ Push updates to Github:\033[0m\n"; \ + printf "\033[2m-> Push updates to Github:\033[0m\n"; \ for branch in $(branches_list); do \ echo "git push --verbose origin $$branch"; \ done; \ @@ -155,7 +336,7 @@ endif release: ## Release a new version to Github $(eval branch = $(shell git rev-parse --abbrev-ref HEAD)) $(eval current_version = $(shell cat internal/version/version.go | sed -Ee 's/const Client = "(.*)"/\1/' | tail -1)) - @printf "\033[2m→ [$(branch)] Current version: $(current_version)...\033[0m\n" + @printf "\033[2m-> [$(branch)] Current version: $(current_version)...\033[0m\n" ifndef version @printf "\033[31m[!] Missing version argument, exiting...\033[0m\n" @exit 2 @@ -164,7 +345,7 @@ ifeq ($(version), "") @printf "\033[31m[!] Empty version argument, exiting...\033[0m\n" @exit 2 endif - @printf "\033[2m→ [$(branch)] Creating version $(version)...\033[0m\n" + @printf "\033[2m-> [$(branch)] Creating version $(version)...\033[0m\n" @{ \ set -e -o pipefail; \ cp internal/version/version.go internal/version/version.go.OLD && \ @@ -175,19 +356,19 @@ endif } @{ \ set -e -o pipefail; \ - printf "\033[2m→ Commit and create Git tag? (y/n): \033[0m\c"; \ + printf "\033[2m-> Commit and create Git tag? (y/n): \033[0m\c"; \ read continue; \ - if [[ $$continue == "y" ]]; then \ + if [ "$$continue" = "y" ]; then \ git add internal/version/version.go && \ git commit --no-status --quiet --message "Release $(version)" && \ git tag --annotate v$(version) --message 'Release $(version)'; \ - printf "\033[2m→ Push `git show --pretty='%h (%s)' --no-patch HEAD` to Github:\033[0m\n\n"; \ + printf "\033[2m-> Push `git show --pretty='%h (%s)' --no-patch HEAD` to Github:\033[0m\n\n"; \ printf "\033[1m git push origin HEAD && git push origin v$(version)\033[0m\n\n"; \ mv internal/version/version.go.OLD internal/version/version.go && \ git add internal/version/version.go && \ original_version=`cat internal/version/version.go | sed -ne 's;^const Client = "\(.*\)"$$;\1;p'` && \ git commit --no-status --quiet --message "Update version to $$original_version"; \ - printf "\033[2m→ Version updated to [$$original_version].\033[0m\n\n"; \ + printf "\033[2m-> Version updated to [$$original_version].\033[0m\n\n"; \ else \ echo "Aborting..."; \ rm internal/version/version.go.OLD; \ @@ -196,61 +377,571 @@ endif } godoc: ## Display documentation for the package - @printf "\033[2m→ Generating documentation...\033[0m\n" + @printf "\033[2m-> Generating documentation...\033[0m\n" @echo "* http://localhost:6060/pkg/github.com/opensearch-project/opensearch-go" @echo "* http://localhost:6060/pkg/github.com/opensearch-project/opensearch-go/opensearchapi" + @echo "* http://localhost:6060/pkg/github.com/opensearch-project/opensearch-go/v4/v5preview/opensearchapi" @echo "* http://localhost:6060/pkg/github.com/opensearch-project/opensearch-go/opensearchtransport" @echo "* http://localhost:6060/pkg/github.com/opensearch-project/opensearch-go/opensearchutil" @printf "\n" godoc --http=localhost:6060 --play -cluster.build: - docker compose --project-directory .ci/opensearch build --pull; +workflow: ## Run full CI workflow locally (lint, test, integration) +# Lint + $(MAKE) lint +# License Checker + .github/check-license-headers.sh +# Unit Test + $(MAKE) test-unit race=true +# Benchmarks Test + $(MAKE) test-bench +# Integration Test +### OpenSearch + $(MAKE) cluster.clean cluster.build cluster.start + $(MAKE) test-integ race=true + $(MAKE) cluster.stop + +##@ Cluster Lifecycle +cluster.runtime: ## Show detected container provider, docker context, and runtime + @echo "Container provider: $(if $(CONTAINER_PROVIDER),$(CONTAINER_PROVIDER),(none detected))" + @echo "Docker context: $(if $(DOCKER_CONTEXT),$(DOCKER_CONTEXT),(active default))" + @echo "Container runtime: $(CTR)" + @$(CTR) --version + @$(CTR) compose version + +cluster.provider.ensure: ## Ensure the selected provider's VM/daemon is running (starts it if needed) + @case "$(CONTAINER_PROVIDER)" in \ + colima) \ + if colima status >/dev/null 2>&1; then \ + printf "\033[2m-> Colima already running\033[0m\n"; \ + else \ + printf "\033[2m-> Starting Colima...\033[0m\n"; colima start; \ + fi ;; \ + rancher) \ + if rdctl shell true >/dev/null 2>&1; then \ + printf "\033[2m-> Rancher Desktop already running\033[0m\n"; \ + else \ + printf "\033[2m-> Starting Rancher Desktop...\033[0m\n"; rdctl start; \ + fi ;; \ + docker) \ + if $(CTR) info >/dev/null 2>&1; then \ + printf "\033[2m-> Docker daemon already running\033[0m\n"; \ + elif [ "$$(uname)" = "Darwin" ]; then \ + printf "\033[2m-> Starting Docker Desktop...\033[0m\n"; open -a Docker; \ + for i in $$(seq 30); do $(CTR) info >/dev/null 2>&1 && break; sleep 2; done; \ + $(CTR) info >/dev/null 2>&1 || { echo "Docker daemon did not become ready"; exit 1; }; \ + else \ + echo "Docker daemon is not running; start it and retry."; exit 1; \ + fi ;; \ + *) echo "No container provider detected. Install colima, rancher, or docker, or set CONTAINER_PROVIDER."; exit 1 ;; \ + esac + +cluster.sysctl: ## Ensure vm.max_map_count is set for OpenSearch (Linux, or macOS via Colima/Rancher/Docker) + @if [ "$$(uname)" != "Darwin" ]; then \ + vmexec=""; setter="sudo sysctl -w vm.max_map_count=262144"; \ + elif [ "$(CONTAINER_PROVIDER)" = "colima" ]; then \ + vmexec="colima ssh --"; setter="colima ssh -- sudo sysctl -w vm.max_map_count=262144"; \ + elif [ "$(CONTAINER_PROVIDER)" = "rancher" ]; then \ + vmexec="rdctl shell"; setter="rdctl shell sudo sysctl -w vm.max_map_count=262144"; \ + else \ + vmexec="$(CTR) run --rm --privileged --net=host busybox"; \ + setter="$(CTR) run --rm --privileged --net=host busybox sysctl -w vm.max_map_count=262144"; \ + fi; \ + current=$$($$vmexec cat /proc/sys/vm/max_map_count 2>/dev/null || echo 0); \ + if [ "$$current" -ge 262144 ]; then \ + printf "\033[2m-> vm.max_map_count already $$current (>= 262144)\033[0m\n"; \ + else \ + printf "\033[2m-> Setting vm.max_map_count=262144 (was $$current)...\033[0m\n"; \ + $$setter; \ + fi + +cluster.build: ## Build OpenSearch Docker images (version-aware) + @$(MAKE) cluster.docker-build + +cluster.start: ## Build, start cluster, wait for ready, and fetch certs + @$(MAKE) cluster.provider.ensure + @$(MAKE) cluster.sysctl + @$(MAKE) cluster.docker-up + @$(MAKE) cluster.wait-ready + @$(MAKE) cluster.get-cert + +cluster.stop: ## Stop the OpenSearch cluster + $(CTR_COMPOSE) down; + +cluster.status: ## Show detailed cluster status and health information + @printf "\033[1m=== OpenSearch Cluster Status ===\033[0m\n\n" + @# Determine auth settings + @{ \ + set -e; \ + HTTP_URL="http://localhost:9200"; \ + HTTPS_URL="https://localhost:9200"; \ + BASE_URL=""; \ + CURL_OPTS=""; \ + VERSION="$${OPENSEARCH_VERSION:-latest}"; \ + if [ "$$VERSION" = "latest" ]; then \ + PASSWORD="myStrongPassword123!"; \ + else \ + MAJOR=$$(echo "$$VERSION" | cut -d. -f1); \ + MINOR=$$(echo "$$VERSION" | cut -d. -f2); \ + if [ $$MAJOR -gt 2 ] || ([ $$MAJOR -eq 2 ] && [ $$MINOR -ge 12 ]); then \ + PASSWORD="myStrongPassword123!"; \ + else \ + PASSWORD="admin"; \ + fi; \ + fi; \ + if curl -sf "$$HTTP_URL" > /dev/null 2>&1; then \ + BASE_URL="$$HTTP_URL"; \ + CURL_OPTS=""; \ + printf "\033[36m→ Using HTTP (insecure cluster)\033[0m\n\n"; \ + elif curl -sf -k -u "admin:$$PASSWORD" "$$HTTPS_URL" > /dev/null 2>&1; then \ + BASE_URL="$$HTTPS_URL"; \ + CURL_OPTS="-k -u admin:$$PASSWORD"; \ + printf "\033[36m→ Using HTTPS (secure cluster)\033[0m\n\n"; \ + else \ + printf "\033[31m✗ Cannot connect to cluster at $$HTTP_URL or $$HTTPS_URL\033[0m\n"; \ + printf "\033[2m\nDocker containers:\033[0m\n"; \ + $(CTR_COMPOSE) ps || echo "No containers running"; \ + exit 1; \ + fi; \ + printf "\033[1m--- Cluster Info ---\033[0m\n"; \ + curl -sf $$CURL_OPTS "$$BASE_URL" | jq -C . || echo "Failed to get cluster info"; \ + printf "\n\033[1m--- Cluster Health ---\033[0m\n"; \ + curl -sf $$CURL_OPTS "$$BASE_URL/_cluster/health?pretty" | jq -C . || echo "Failed to get cluster health"; \ + printf "\n\033[1m--- Nodes ---\033[0m\n"; \ + curl -sf $$CURL_OPTS "$$BASE_URL/_cat/nodes?v&h=name,ip,heap.percent,ram.percent,cpu,load_1m,load_5m,load_15m,node.role,master,version" || echo "Failed to get nodes"; \ + printf "\n\n\033[1m--- Node Details (roles, CPUs) ---\033[0m\n"; \ + curl -sf $$CURL_OPTS "$$BASE_URL/_nodes/http,os" | jq -C '.nodes | to_entries[] | {name: .value.name, roles: .value.roles, allocated_processors: .value.os.allocated_processors, http_address: .value.http.publish_address}' || echo "Failed to get node details"; \ + printf "\n\033[1m--- Containers ---\033[0m\n"; \ + $(CTR_COMPOSE) ps; \ + printf "\n\033[1m--- Indices ---\033[0m\n"; \ + curl -sf $$CURL_OPTS "$$BASE_URL/_cat/indices?v&h=health,status,index,docs.count,store.size,pri,rep" || echo "Failed to get indices"; \ + printf "\n\n\033[1m--- Shards ---\033[0m\n"; \ + curl -sf $$CURL_OPTS "$$BASE_URL/_cat/shards?v&h=index,shard,prirep,state,docs,store,node" || echo "Failed to get shards"; \ + printf "\n"; \ + } + +cluster.docker-build: + @# Determine version-specific settings + $(eval OPENSEARCH_VERSION ?= latest) + $(eval SECURE_INTEGRATION ?= true) + $(eval version_major := $(shell \ + if [ "$(OPENSEARCH_VERSION)" = "latest" ]; then \ + echo "2"; \ + else \ + echo "$(OPENSEARCH_VERSION)" | awk -F. '{print $$1}'; \ + fi \ + )) + $(eval manager_role := $(shell \ + if [ "$(version_major)" = "1" ]; then \ + echo "master"; \ + else \ + echo "cluster_manager"; \ + fi \ + )) + @echo "Building OpenSearch $(OPENSEARCH_VERSION) with role: $(manager_role), secure: $(SECURE_INTEGRATION)" + @echo "Pre-pulling base image opensearchproject/opensearch:$(OPENSEARCH_VERSION)..." + @for attempt in $$(seq 30); do \ + $(CTR) pull opensearchproject/opensearch:$(OPENSEARCH_VERSION) && break; \ + echo "Pull attempt $$attempt/30 failed, retrying in 10s..."; \ + [ "$$attempt" -eq 30 ] && { echo "All 30 pull attempts failed, aborting."; exit 1; }; \ + sleep 10; \ + done + OPENSEARCH_MANAGER_ROLE=$(manager_role) OPENSEARCH_MANAGER_SETTING=$(manager_role) \ + $(CTR_COMPOSE) build --pull -cluster.start: - docker compose --project-directory .ci/opensearch up -d; +cluster.docker-up: + @# Determine version-specific settings + $(eval OPENSEARCH_VERSION ?= latest) + $(eval SECURE_INTEGRATION ?= true) + $(eval version_major := $(shell \ + if [ "$(OPENSEARCH_VERSION)" = "latest" ]; then \ + echo "2"; \ + else \ + echo "$(OPENSEARCH_VERSION)" | awk -F. '{print $$1}'; \ + fi \ + )) + $(eval manager_role := $(shell \ + if [ "$(version_major)" = "1" ]; then \ + echo "master"; \ + else \ + echo "cluster_manager"; \ + fi \ + )) + @# Apply cgroup workaround for OpenSearch 2.0.1-2.3.0 + $(eval java_opts_extra := $(shell \ + if [ "$(OPENSEARCH_VERSION)" != "latest" ]; then \ + version() { echo "$$@" | awk -F. '{ printf("%d%03d%03d%03d\n", $$1,$$2,$$3,$$4); }'; }; \ + v=$$(version $(OPENSEARCH_VERSION)); \ + v_min=$$(version 2.0.1); \ + v_max=$$(version 2.3.0); \ + if [ $$v -ge $$v_min ] && [ $$v -le $$v_max ]; then \ + echo " -XX:-UseContainerSupport"; \ + fi; \ + fi \ + )) + $(eval OPENSEARCH_HEAP_SIZE ?= 1g) + $(eval OPENSEARCH_NODE_COUNT ?= 3) + @# OpenSearch <=2.17.x carries a node-join/node-left race condition + @# (fixed in 2.18 via opensearch-project/OpenSearch#15521, backported + @# via opensearch-project/OpenSearch#16118) that leaves a node in + @# cluster state but disconnected at the transport layer, breaking + @# NodesStats RPC fan-out indefinitely. Single-node clusters cannot + @# hit the race; the workflow sets OPENSEARCH_NODE_COUNT=1 for those + @# versions. Scale flags are derived inline below; an earlier form + @# that nested a case statement inside an eval/shell broke CI. + @echo "Starting OpenSearch $(OPENSEARCH_VERSION) with role: $(manager_role), secure: $(SECURE_INTEGRATION), heap: $(OPENSEARCH_HEAP_SIZE), nodes: $(OPENSEARCH_NODE_COUNT)" + @OVERRIDES="$$(ls $(COMPOSE_DIR)/docker-compose.*-override.yml 2>/dev/null | xargs -n1 basename 2>/dev/null)"; \ + if [ -n "$$OVERRIDES" ]; then echo "Active overrides: $$OVERRIDES"; fi + @export SECURE_INTEGRATION=$(SECURE_INTEGRATION); \ + export OPENSEARCH_VERSION=$(OPENSEARCH_VERSION); \ + export OPENSEARCH_MANAGER_ROLE=$(manager_role); \ + export OPENSEARCH_MANAGER_SETTING=$(manager_role); \ + export OPENSEARCH_HEAP_SIZE=$(OPENSEARCH_HEAP_SIZE); \ + export OPENSEARCH_JAVA_OPTS_EXTRA="$(java_opts_extra)"; \ + SCALE_ARGS=""; \ + if [ "$(OPENSEARCH_NODE_COUNT)" = "1" ]; then \ + SCALE_ARGS="--scale opensearch-node2=0 --scale opensearch-node3=0"; \ + export OPENSEARCH_SEED_HOSTS="opensearch-node1"; \ + export OPENSEARCH_INITIAL_MANAGER_NODES="opensearch-node1"; \ + elif [ "$(OPENSEARCH_NODE_COUNT)" = "2" ]; then \ + SCALE_ARGS="--scale opensearch-node3=0"; \ + export OPENSEARCH_SEED_HOSTS="opensearch-node1,opensearch-node2"; \ + export OPENSEARCH_INITIAL_MANAGER_NODES="opensearch-node1,opensearch-node2"; \ + fi; \ + $(CTR_COMPOSE) up -d $$SCALE_ARGS -cluster.stop: - docker compose --project-directory .ci/opensearch down; +##@ Cluster Scaling & Configuration +cluster.scale.1: ## Start single-node cluster + $(CTR_COMPOSE) up -d --scale opensearch-node2=0 --scale opensearch-node3=0; + +cluster.scale.2: ## Start 2-node cluster + $(CTR_COMPOSE) up -d --scale opensearch-node1=1 --scale opensearch-node2=1 --scale opensearch-node3=0; + +cluster.scale.3: ## Start full 3-node cluster + $(CTR_COMPOSE) up -d --scale opensearch-node1=1 --scale opensearch-node2=1 --scale opensearch-node3=1; cluster.get-cert: - @if [[ -v SECURE_INTEGRATION ]] && [[ $$SECURE_INTEGRATION == "true" ]]; then \ - docker cp $$(docker compose --project-directory .ci/opensearch ps --format '{{.Name}}'):/usr/share/opensearch/config/kirk.pem admin.pem && \ - docker cp $$(docker compose --project-directory .ci/opensearch ps --format '{{.Name}}'):/usr/share/opensearch/config/kirk-key.pem admin.key; \ + @if curl -sf http://localhost:9200 >/dev/null 2>&1; then \ + printf "\033[2m-> Cluster is HTTP (insecure), skipping cert extraction\033[0m\n"; \ + elif curl -sk -o /dev/null -w '' https://localhost:9200 2>/dev/null; then \ + CONTAINER=$$($(CTR_COMPOSE) ps --format '{{.Name}}' | head -1); \ + if [ -z "$$CONTAINER" ]; then \ + echo "Error: No OpenSearch containers running. Start cluster first with 'make cluster.start'"; \ + exit 1; \ + fi; \ + printf "\033[2m-> Extracting admin certs from $$CONTAINER...\033[0m\n"; \ + $(CTR) cp $$CONTAINER:/usr/share/opensearch/config/kirk.pem admin.pem && \ + $(CTR) cp $$CONTAINER:/usr/share/opensearch/config/kirk-key.pem admin.key; \ + else \ + printf "\033[33m-> Cluster not responding on HTTP or HTTPS, skipping cert extraction\033[0m\n"; \ fi +cluster.wait-ready: ## Poll cluster until health status is green or yellow + @printf "\033[2m-> Waiting for cluster to be ready...\033[0m\n" + @{ \ + set -e; \ + MAX_ATTEMPTS=60; \ + ATTEMPT=1; \ + HTTP_URL="http://localhost:9200/_cluster/health"; \ + HTTPS_URL="https://localhost:9200/_cluster/health"; \ + HEALTH_URL=""; \ + CURL_OPTS=""; \ + VERSION="$${OPENSEARCH_VERSION:-latest}"; \ + if [ "$$VERSION" = "latest" ]; then \ + PASSWORD="myStrongPassword123!"; \ + else \ + MAJOR=$$(echo "$$VERSION" | cut -d. -f1); \ + MINOR=$$(echo "$$VERSION" | cut -d. -f2); \ + if [ $$MAJOR -gt 2 ] || ([ $$MAJOR -eq 2 ] && [ $$MINOR -ge 12 ]); then \ + PASSWORD="myStrongPassword123!"; \ + else \ + PASSWORD="admin"; \ + fi; \ + fi; \ + while [ $$ATTEMPT -le $$MAX_ATTEMPTS ]; do \ + if [ -z "$$HEALTH_URL" ]; then \ + if curl -sf "$$HTTP_URL" > /dev/null 2>&1; then \ + printf "\033[36m→ Detected insecure cluster (HTTP)\033[0m\n"; \ + HEALTH_URL="$$HTTP_URL"; \ + CURL_OPTS=""; \ + elif curl -sf -k -u "admin:$$PASSWORD" "$$HTTPS_URL" > /dev/null 2>&1; then \ + printf "\033[36m→ Detected secure cluster (HTTPS)\033[0m\n"; \ + HEALTH_URL="$$HTTPS_URL"; \ + CURL_OPTS="-k -u admin:$$PASSWORD"; \ + else \ + printf "\033[33m⋯ Waiting for cluster to respond (attempt $$ATTEMPT/$$MAX_ATTEMPTS)\033[0m\n"; \ + ATTEMPT=$$((ATTEMPT + 1)); \ + sleep 3; \ + continue; \ + fi; \ + fi; \ + if curl -sf $$CURL_OPTS "$$HEALTH_URL" > /dev/null 2>&1; then \ + STATUS=$$(curl -sf $$CURL_OPTS "$$HEALTH_URL" | grep -o '"status":"[^"]*"' | cut -d'"' -f4); \ + if [ "$$STATUS" = "green" ] || [ "$$STATUS" = "yellow" ]; then \ + printf "\033[32m✓ Cluster is ready (status: $$STATUS) after $$ATTEMPT attempts\033[0m\n"; \ + INFO_URL="$${HEALTH_URL%%/_cluster/health}"; \ + CLUSTER_INFO=$$(curl -sf $$CURL_OPTS "$$INFO_URL" 2>/dev/null); \ + if [ -n "$$CLUSTER_INFO" ]; then \ + CLUSTER_NAME=$$(echo "$$CLUSTER_INFO" | grep -o '"cluster_name":"[^"]*"' | cut -d'"' -f4); \ + CLUSTER_VERSION=$$(echo "$$CLUSTER_INFO" | grep -o '"number":"[^"]*"' | head -1 | cut -d'"' -f4); \ + printf "\033[2m Cluster: $$CLUSTER_NAME\033[0m\n"; \ + printf "\033[2m Version: $$CLUSTER_VERSION\033[0m\n"; \ + printf "\033[2m URL: $$INFO_URL\033[0m\n"; \ + if [ -n "$$CURL_OPTS" ]; then \ + printf "\033[2m Auth: admin:****\033[0m\n"; \ + fi; \ + fi; \ + exit 0; \ + fi; \ + printf "\033[33m⋯ Cluster status: $$STATUS (attempt $$ATTEMPT/$$MAX_ATTEMPTS)\033[0m\n"; \ + else \ + printf "\033[33m⋯ Waiting for cluster to respond (attempt $$ATTEMPT/$$MAX_ATTEMPTS)\033[0m\n"; \ + fi; \ + ATTEMPT=$$((ATTEMPT + 1)); \ + sleep 3; \ + done; \ + printf "\033[31m✗ Cluster failed to become ready after $$MAX_ATTEMPTS attempts\033[0m\n"; \ + printf "\033[2m\n--- Diagnostic Information ---\033[0m\n"; \ + printf "\033[2mDocker containers:\033[0m\n"; \ + $(CTR_COMPOSE) ps || true; \ + printf "\033[2m\nFull logs from all containers:\033[0m\n"; \ + $(CTR_COMPOSE) logs || true; \ + printf "\033[2m\nAttempted URLs:\033[0m\n"; \ + printf " HTTP: $$HTTP_URL\n"; \ + printf " HTTPS: $$HTTPS_URL\n"; \ + printf "\033[2m\nCurl test results:\033[0m\n"; \ + printf " HTTP: "; curl -sf "$$HTTP_URL" && echo "✓ OK" || echo "✗ Failed"; \ + printf " HTTPS: "; curl -sf -k -u "admin:$$PASSWORD" "$$HTTPS_URL" && echo "✓ OK" || echo "✗ Failed"; \ + exit 1; \ + } + +cluster.clean: ## Remove unused container volumes and networks + @printf "\033[2m-> Cleaning up container assets...\033[0m\n" + @# Stop and remove containers first to release volumes + @$(CTR_COMPOSE) down --volumes 2>/dev/null || true + @# Remove OpenSearch built images to ensure clean rebuilds when switching versions + @imgs=$$($(CTR) images -q --filter 'reference=opensearch-opensearch-node*' 2>/dev/null); \ + [ -n "$$imgs" ] && echo "$$imgs" | xargs $(CTR) rmi -f || true + @# Remove OpenSearch volumes to clear stale data + @vols=$$($(CTR) volume ls -q --filter "name=opensearch" 2>/dev/null); \ + [ -n "$$vols" ] && echo "$$vols" | xargs $(CTR) volume rm || true + @# Clean up unused container resources + $(CTR) volume prune --force + $(CTR) network prune --force + $(CTR) system prune --volumes --force -cluster.clean: ## Remove unused Docker volumes and networks - @printf "\033[2m→ Cleaning up Docker assets...\033[0m\n" - docker volume prune --force - docker network prune --force - docker system prune --volumes --force +cluster.heterogeneous.cpu.1: ## Set CPU limits: node1=2, node2=2, node3=4 + @printf '%s\n' \ + 'services:' \ + ' opensearch-node1:' \ + ' deploy:' \ + ' resources:' \ + ' limits:' \ + " cpus: '2'" \ + ' opensearch-node2:' \ + ' deploy:' \ + ' resources:' \ + ' limits:' \ + " cpus: '2'" \ + ' opensearch-node3:' \ + ' deploy:' \ + ' resources:' \ + ' limits:' \ + " cpus: '4'" \ + > $(COMPOSE_DIR)/docker-compose.cpu-override.yml + @echo "CPU override: node1=2, node2=2, node3=4 (weights [1,1,2])" + +cluster.heterogeneous.cpu.2: ## Set CPU limits: node1=1, node2=2, node3=4 + @printf '%s\n' \ + 'services:' \ + ' opensearch-node1:' \ + ' deploy:' \ + ' resources:' \ + ' limits:' \ + " cpus: '1'" \ + ' opensearch-node2:' \ + ' deploy:' \ + ' resources:' \ + ' limits:' \ + " cpus: '2'" \ + ' opensearch-node3:' \ + ' deploy:' \ + ' resources:' \ + ' limits:' \ + " cpus: '4'" \ + > $(COMPOSE_DIR)/docker-compose.cpu-override.yml + @echo "CPU override: node1=1, node2=2, node3=4 (weights [1,2,4])" + +cluster.heterogeneous.roles: ## Set roles: node1=cm+ingest, node2=data+ingest, node3=data + @printf '%s\n' \ + 'services:' \ + ' opensearch-node1:' \ + ' environment:' \ + ' - node.roles=$${OPENSEARCH_MANAGER_ROLE:-cluster_manager},ingest' \ + ' opensearch-node2:' \ + ' environment:' \ + ' - node.roles=data,ingest' \ + ' opensearch-node3:' \ + ' environment:' \ + ' - node.roles=data' \ + > $(COMPOSE_DIR)/docker-compose.roles-override.yml + @echo "Roles override: node1=cm+ingest, node2=data+ingest, node3=data" + +cluster.homogeneous: ## Remove all override files (reset to defaults) + @rm -f $(COMPOSE_DIR)/docker-compose.*-override.yml + @echo "Removed all overrides — cluster will use default (homogeneous) config" + +##@ Network Latency Simulation +cluster.latency.asymmetric: ## Add asymmetric latency: node1=0ms, node2=50ms, node3=150ms + @printf "\033[2m-> Applying asymmetric latency...\033[0m\n" + @NODES="$$($(CTR_COMPOSE) ps --format '{{.Name}}')"; \ + for NODE in $$NODES; do \ + $(CTR) exec --user root $$NODE tc qdisc del dev eth0 root 2>/dev/null || true; \ + done; \ + NODE1=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node1 2>/dev/null | head -1); \ + NODE2=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node2 2>/dev/null | head -1); \ + NODE3=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node3 2>/dev/null | head -1); \ + if [ -n "$$NODE1" ]; then echo " node1 ($$NODE1): 0ms (no delay)"; fi; \ + if [ -n "$$NODE2" ]; then $(CTR) exec --user root $$NODE2 tc qdisc add dev eth0 root netem delay 50ms 5ms && echo " node2 ($$NODE2): 50ms ±5ms"; fi; \ + if [ -n "$$NODE3" ]; then $(CTR) exec --user root $$NODE3 tc qdisc add dev eth0 root netem delay 150ms 15ms && echo " node3 ($$NODE3): 150ms ±15ms"; fi; \ + echo "Latency applied. Use 'make cluster.latency.show' to verify." + +cluster.latency.symmetric: ## Add symmetric latency: all nodes 1ms (single tier, bucket ~10) + @printf "\033[2m-> Applying symmetric latency...\033[0m\n" + @NODES="$$($(CTR_COMPOSE) ps --format '{{.Name}}')"; \ + for NODE in $$NODES; do \ + $(CTR) exec --user root $$NODE tc qdisc del dev eth0 root 2>/dev/null || true; \ + $(CTR) exec --user root $$NODE tc qdisc add dev eth0 root netem delay 1ms 100us && \ + echo " $$NODE: 1ms ±100us (bucket ~10)"; \ + done; \ + echo "Symmetric latency applied (all nodes same tier)." + +cluster.latency.bimodal: ## Add bimodal latency: node1=1ms, node2=1ms, node3=20ms (2 local + 1 remote) + @printf "\033[2m-> Applying bimodal latency...\033[0m\n" + @NODES="$$($(CTR_COMPOSE) ps --format '{{.Name}}')"; \ + for NODE in $$NODES; do \ + $(CTR) exec --user root $$NODE tc qdisc del dev eth0 root 2>/dev/null || true; \ + done; \ + NODE1=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node1 2>/dev/null | head -1); \ + NODE2=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node2 2>/dev/null | head -1); \ + NODE3=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node3 2>/dev/null | head -1); \ + if [ -n "$$NODE1" ]; then $(CTR) exec --user root $$NODE1 tc qdisc add dev eth0 root netem delay 1ms 100us && echo " node1 ($$NODE1): 1ms ±100us (bucket ~10)"; fi; \ + if [ -n "$$NODE2" ]; then $(CTR) exec --user root $$NODE2 tc qdisc add dev eth0 root netem delay 1ms 100us && echo " node2 ($$NODE2): 1ms ±100us (bucket ~10)"; fi; \ + if [ -n "$$NODE3" ]; then $(CTR) exec --user root $$NODE3 tc qdisc add dev eth0 root netem delay 20ms 2ms && echo " node3 ($$NODE3): 20ms ±2ms (bucket ~14)"; fi; \ + echo "Bimodal latency applied (2 local + 1 remote)." + +cluster.latency.graduated: ## Add graduated latency: node1=1ms, node2=10ms, node3=100ms (buckets 10,14,17) + @printf "\033[2m-> Applying graduated latency...\033[0m\n" + @NODES="$$($(CTR_COMPOSE) ps --format '{{.Name}}')"; \ + for NODE in $$NODES; do \ + $(CTR) exec --user root $$NODE tc qdisc del dev eth0 root 2>/dev/null || true; \ + done; \ + NODE1=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node1 2>/dev/null | head -1); \ + NODE2=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node2 2>/dev/null | head -1); \ + NODE3=$$($(CTR_COMPOSE) ps --format '{{.Name}}' opensearch-node3 2>/dev/null | head -1); \ + if [ -n "$$NODE1" ]; then $(CTR) exec --user root $$NODE1 tc qdisc add dev eth0 root netem delay 1ms 100us && echo " node1 ($$NODE1): 1ms ±100us (bucket ~10)"; fi; \ + if [ -n "$$NODE2" ]; then $(CTR) exec --user root $$NODE2 tc qdisc add dev eth0 root netem delay 10ms 1ms && echo " node2 ($$NODE2): 10ms ±1ms (bucket ~14)"; fi; \ + if [ -n "$$NODE3" ]; then $(CTR) exec --user root $$NODE3 tc qdisc add dev eth0 root netem delay 100ms 10ms && echo " node3 ($$NODE3): 100ms ±10ms (bucket ~17)"; fi; \ + echo "Graduated latency applied (3 distinct tiers)." + +cluster.latency.clear: ## Remove all artificial latency from nodes + @printf "\033[2m-> Clearing network latency...\033[0m\n" + @NODES="$$($(CTR_COMPOSE) ps --format '{{.Name}}')"; \ + for NODE in $$NODES; do \ + $(CTR) exec --user root $$NODE tc qdisc del dev eth0 root 2>/dev/null && echo " Cleared $$NODE" || echo " $$NODE: no qdisc to clear"; \ + done; \ + echo "All latency rules removed." + +cluster.latency.show: ## Show current tc qdisc rules on each node + @NODES="$$($(CTR_COMPOSE) ps --format '{{.Name}}')"; \ + for NODE in $$NODES; do \ + echo "--- $$NODE ---"; \ + $(CTR) exec --user root $$NODE tc qdisc show dev eth0 2>/dev/null || echo " (tc not available)"; \ + done linters: - docker run -t --rm -v $$(pwd):/app -v ~/.cache/golangci-lint/v2.7.2:/root/.cache -w /app golangci/golangci-lint:v2.7.2 golangci-lint run --timeout=5m -v + @for tags in $(GOLANGCI_LINT_TAG_SETS); do \ + printf "\033[2m-> golangci-lint --build-tags %s\033[0m\n" "$$tags"; \ + $(CTR) run -t --rm -v $$(pwd):/app -v ~/.cache/golangci-lint/$(GOLANGCI_LINT_VERSION):/root/.cache -w /app golangci/golangci-lint:$(GOLANGCI_LINT_VERSION) golangci-lint run --fix --build-tags "$$tags" --timeout=5m -v ./... || exit $$?; \ + done -workflow: ## Run all github workflow commands here sequentially +##@ GitHub CI +#------------------------------------------------------------------------------ +# Fetch and filter CI check results from GitHub Actions using the gh CLI. +# These targets extract only the actual failures from CI logs, avoiding false +# positives from test names that contain words like "fail", "error", or "panic". -# Lint - make lint -# License Checker - .github/check-license-headers.sh -# Unit Test - make test-unit race=true -# Benchmarks Test - make test-bench -# Integration Test -### OpenSearch - make cluster.clean cluster.build cluster.start - make test-integ race=true - make cluster.stop +# GH_RUN_ID: override to inspect a specific run. When unset, targets auto-detect +# the most recent failed run on the current branch. +GH_RUN_ID ?= + +# Internal: resolve GH_RUN_ID lazily. If the caller didn't set it, pick the +# latest failed run for the current branch. +_gh_run_id = $(or $(GH_RUN_ID),$(shell gh run list --branch "$$(git branch --show-current)" --status failure --limit 1 --json databaseId --jq '.[0].databaseId')) + +gh.checks: ## Show all CI check statuses for the current branch + @gh run list --branch "$$(git branch --show-current)" --limit 10 + +gh.checks.failed: ## List only failed CI runs for the current branch + @gh run list --branch "$$(git branch --show-current)" --status failure --limit 10 + +gh.fail: ## Show failed test names and error messages from the latest (or GH_RUN_ID) failed run + @RUN_ID=$(_gh_run_id); \ + if [ -z "$$RUN_ID" ]; then \ + echo "No failed runs found on branch $$(git branch --show-current)"; \ + exit 0; \ + fi; \ + printf "\033[1m=== Failed run: $$RUN_ID ===\033[0m\n"; \ + gh run view "$$RUN_ID" --json jobs --jq '.jobs[] | select(.conclusion == "failure") | " \(.name)"' 2>/dev/null; \ + printf "\n"; \ + gh run view "$$RUN_ID" --log-failed 2>&1 \ + | grep -E -e '--- FAIL:' -e 'FAIL ' -e 'panic:' \ + | cut -f3- \ + | sed 's/^[^ ]* //' + +gh.fail.full: ## Show full failed-step logs from the latest (or GH_RUN_ID) failed run + @RUN_ID=$(_gh_run_id); \ + if [ -z "$$RUN_ID" ]; then \ + echo "No failed runs found on branch $$(git branch --show-current)"; \ + exit 0; \ + fi; \ + printf "\033[1m=== Failed run: $$RUN_ID ===\033[0m\n\n"; \ + gh run view "$$RUN_ID" --log-failed + +gh.fail.context: ## Show failed tests with 5 lines of context before each failure + @RUN_ID=$(_gh_run_id); \ + if [ -z "$$RUN_ID" ]; then \ + echo "No failed runs found on branch $$(git branch --show-current)"; \ + exit 0; \ + fi; \ + printf "\033[1m=== Failed run: $$RUN_ID ===\033[0m\n\n"; \ + gh run view "$$RUN_ID" --log-failed 2>&1 \ + | cut -f3- \ + | sed 's/^[^ ]* //' \ + | grep -B5 -E -e '--- FAIL:' -e 'panic:' + +gh.fail.summary: ## One-line-per-failure summary from the latest (or GH_RUN_ID) failed run + @RUN_ID=$(_gh_run_id); \ + if [ -z "$$RUN_ID" ]; then \ + echo "No failed runs found on branch $$(git branch --show-current)"; \ + exit 0; \ + fi; \ + printf "\033[1mRun $$RUN_ID — failed jobs:\033[0m\n"; \ + gh run view "$$RUN_ID" --json jobs --jq '.jobs[] | select(.conclusion == "failure") | " \u001b[31m✗\u001b[0m \(.name)"' 2>/dev/null; \ + printf "\n\033[1mFailed tests:\033[0m\n"; \ + gh run view "$$RUN_ID" --log-failed 2>&1 \ + | grep -E -- '--- FAIL:' \ + | cut -f3- \ + | sed 's/^[^ ]* //' \ + | sort -u \ + | sed 's/^/ /' ##@ Other #------------------------------------------------------------------------------ help: ## Display help - @awk 'BEGIN {FS = ":.*##"; printf "Usage:\n make \033[36m\033[0m\n"} /^[a-zA-Z_-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST) + @awk 'BEGIN {FS = ":.*##"; printf "Usage:\n make \033[36m\033[0m\n"} /^[a-zA-Z_][a-zA-Z0-9._-]+:.*?##/ { printf " \033[36m%-35s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST) #------------- -------------- .DEFAULT_GOAL := help -.PHONY: help backport cluster cluster.clean coverage godoc lint release test test-bench test-integ test-unit linters linters.install +.PHONY: help backport cluster.runtime cluster.provider.ensure cluster.sysctl cluster.build cluster.start cluster.stop cluster.docker-build cluster.docker-up cluster.clean cluster.heterogeneous.cpu.1 cluster.heterogeneous.cpu.2 cluster.heterogeneous.roles cluster.homogeneous cluster.latency.asymmetric cluster.latency.symmetric cluster.latency.bimodal cluster.latency.graduated cluster.latency.clear cluster.latency.show gh.checks gh.checks.failed gh.fail gh.fail.full gh.fail.context gh.fail.summary coverage godoc lint lint.local release test test-all test-race test-bench test-integ test-unit linters linters.install .SILENT: lint.markdown diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/README.md b/vendor/github.com/opensearch-project/opensearch-go/v4/README.md index 5824b12625..fe26493462 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/README.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/README.md @@ -14,6 +14,8 @@ OpenSearch Go Client **opensearch-go** is [a community-driven, open source fork](https://aws.amazon.com/blogs/opensource/introducing-opensearch/) of go-elasticsearch licensed under the [Apache v2.0 License](LICENSE.txt). For more information, see [opensearch.org](https://opensearch.org/). +The client supports automatic node discovery, request-based connection routing, and role-aware node selection. See the [User Guide](USER_GUIDE.md) and [guides](guides/) for usage examples and configuration options. + ## Project Resources - [Project Website](https://opensearch.org/) diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/RELEASING.md b/vendor/github.com/opensearch-project/opensearch-go/v4/RELEASING.md index f6ecb7b123..96fcd332c6 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/RELEASING.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/RELEASING.md @@ -41,21 +41,23 @@ The release process is standard across repositories in this org and is run by a 6. Create a tag, e.g. `v4.3.0`, and push it to the GitHub repo. This [makes the new version available](https://go.dev/doc/modules/publishing) on [pkg.go.dev](https://pkg.go.dev/github.com/opensearch-project/opensearch-go/v4). 7. Draft and publish a [new GitHub release](https://github.com/opensearch-project/opensearch-go/releases/new) from the newly created tag. 8. Create a new `Unreleased` section in the [CHANGELOG](CHANGELOG.md), increment version in [version.go](internal/version/version.go) to the next developer iteration (e.g. `4.3.1`), and make a pull request with this change into `main`, e.g. [opensearch-go#448](https://github.com/opensearch-project/opensearch-go/pull/448). - ``` - ## [Unreleased] - ### Added + ``` + ## [Unreleased] - ### Changed + ### Added - ### Deprecated + ### Changed - ### Removed + ### Deprecated - ### Fixed + ### Removed - ### Security + ### Fixed + + ### Security + + ### Dependencies + ``` - ### Dependencies - ``` 9. Run `go list` with the new version to refresh [pkg.go.dev](https://pkg.go.dev/github.com/opensearch-project/opensearch-go/v4), e.g. `go list -m github.com/opensearch-project/opensearch-go/v4@v4.3.0`. diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/UPGRADING.md b/vendor/github.com/opensearch-project/opensearch-go/v4/UPGRADING.md index 3e5473113f..a9cf5e4061 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/UPGRADING.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/UPGRADING.md @@ -1,39 +1,330 @@ -- [Upgrading Opensearch GO Client](#upgrading-opensearch-go-client) +- [Upgrading OpenSearch Go Client](#upgrading-opensearch-go-client) + - [Upgrading to >= 5.0.0](#upgrading-to->=-5.0.0) + - [Partial failure errors (Config.Errors)](#partial-failure-errors-configerrors) + - [Default Router Injection in v5preview](#default-router-injection-in-v5preview) + - [DiscoverNodes() blocking semantics](#discovernodes-blocking-semantics) + - [opensearchtransport.Route interface gained OpID()](#opensearchtransportroute-interface-gained-opid) + - [Response.Body becomes a method](#responsebody-becomes-a-method) + - [Upgrading to >= 4.7.0](#upgrading-to->=-4.7.0) + - [opensearch.Request interface signature change](#opensearchrequest-interface-signature-change) + - [Path segment values are percent-encoded](#path-segment-values-are-percent-encoded) + - [v5preview/opensearchapi/ package - v5 preview API surface](#v5previewopensearchapi-package---v5-preview-api-surface) - [Upgrading to >= 4.0.0](#upgrading-to->=-4.0.0) - - [error types](#error-types) + - [Import path](#import-path) + - [Error types](#error-types) + - [StringError for unknown JSON responses](#stringerror-for-unknown-json-responses) + - [AWS signer](#aws-signer) + - [Typed failure arrays in by-query and reindex responses](#typed-failure-arrays-in-by-query-and-reindex-responses) + - [Inline `_shards` structs replaced with ResponseShards](#inline-_shards-structs-replaced-with-responseshards) + - [`_type` field tags now include omitempty](#_type-field-tags-now-include-omitempty) - [Upgrading to >= 3.0.0](#upgrading-to->=-3.0.0) - - [client creation](#client-creation) - - [requests](#requests) - - [responses](#responses) - - [error handing](#error-handling) + - [Client creation](#client-creation) + - [Requests](#requests) + - [Responses](#responses) + - [Error handling](#error-handling) + - [API reorganization](#api-reorganization) - [Upgrading to >= 2.3.0](#upgrading-to->=-2.3.0) - - [snapshot delete](#snapshot-delete) + - [Snapshot delete](#snapshot-delete) -# Upgrading Opensearch GO Client +# Upgrading OpenSearch Go Client ## Upgrading to >= 5.0.0 -Version 5.0.0 returns `*opensearch.StringError` error type instead of `*fmt.wrapError` when response received from the server is an unknown JSON. For example, consider delete document API which returns an unknown JSON body when document is not found. + +### Partial Failure Errors (Config.Errors) + +Version 5.0.0 introduces typed partial-failure errors and a per-category bitmask that controls which categories surface as Go errors. OpenSearch returns HTTP 200 for many operations that partially succeed (bulk item failures, shard failures on search, replica failures on writes). The new model turns those partial failures into typed errors that callers can dispatch on; idiomatic partial error handling is shown below. + +**Default behavior change:** + +| Surface | `Config.Errors == nil` means | Effect | +| ------- | ---------------------------- | ------------------------------------------------- | +| v4 | `errmask.All` | mask everything (preserves pre-bitfield behavior) | +| v5+ | `errmask.Empty` | report every partial-failure category | + +A v4 caller upgrading to v5 who never set `Config.Errors` will start seeing partial failures as `error`. To preserve v4-style silence on v5, set `Errors: errmask.New(errmask.All)` explicitly. To opt v4 in to v5-style surfacing today, set `Errors: errmask.New()`. + +**New surface (v5):** + +- `Config.Errors *errmask.ErrorMask` field with the matrix above. +- `OPENSEARCH_GO_ERROR_MASK` environment-variable override (comma-separated `+`/`-` tokens of lowercase snake_case wrapper names like `bulk_items`, `search_shards`, `write_shards`, `multi_search_items`). +- Typed errors: `*PartialBulkError`, `*PartialSearchError`, `*ShardFailureError`, `*MultiSearchItemError`, `*MSearchErrors`, `*MSearchTemplateErrors`. +- `opensearchapi.Errors(err) []error` to flatten single- and multi-wrapper error shapes into a uniform slice. +- Helper functions: `IsPartialFailure(err)`, `ToleratePartialFailures(err)`, `RequireSuccessRate(err, threshold)`. +- Operation constants: `OperationIndex`, `OperationCreate`, `OperationUpdate`, `OperationDelete`. + +The recommended call-site pattern is a `for`/`switch` over `opensearchapi.Errors(err)`, not `errors.As` against a specific type. Per-Resp helper methods (`BulkItemFailures()`, `SearchShardFailures()`, `WriteShardFailures()`, `MultiSearchItemFailures()`, `PartialFailures(mask)`) exist on the response types as engine machinery for the dispatch and remain available for focused inspection of a known category, but new code should use the type switch -- see [`guides/error_handling.md`](guides/error_handling.md#why-a-type-switch-not-errorsas-has-or-per-resp-helpers) for why. + +**Where to read more:** + +- [`v5preview/opensearchapi/README.md`](v5preview/opensearchapi/README.md) - full v5preview usage guide for these errors, including the type-switch pattern and the rationale for preferring it over `errors.As`/`Has`. +- [`guides/error_handling.md`](guides/error_handling.md) - cross-version best-practices guide with v4 and v5preview examples side-by-side. +- [`v5preview/opensearchapi/MIGRATING.md`](v5preview/opensearchapi/MIGRATING.md) - v4 -> v5preview surface delta. + +**Error types in v4 `opensearchapi/`** (the upgrade source): + +| Error Type | Returned By | Key Fields | +| ------------------------ | ----------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | +| `*PartialBulkError` | `Bulk` | `FailedItems []BulkRespItem`, `SucceededCount int` | +| `*PartialSearchError` | `Search`, `Scroll.Get`, `SearchTemplate` (single-bit); also via `*MSearchErrors` and `*MSearchTemplateErrors` for shard aggregation | `FailedShards int`, `TotalShards int`, `Failures []ResponseShardsFailure` | +| `*ShardFailureError` | `Index`, `Document.Create`, `Document.Delete`, `Update` | `Operation string`, `FailedShards int`, `TotalShards int` | +| `*MultiSearchItemError` | `MSearch`, `MSearchTemplate` (per-sub-response error inspection) | `Items []MultiSearchItemFailure`, `SucceededCount int` | +| `*MSearchErrors` | `MSearch` when 2+ wrappers fire | `Unwrap() []error` (multi-error contract) | +| `*MSearchTemplateErrors` | `MSearchTemplate` when 2+ wrappers fire | `Unwrap() []error` | + +The v5preview surface ports the same model with internal field types regenerated from the [OpenSearch API specification](https://github.com/opensearch-project/opensearch-api-specification) ([see MIGRATING.md](v5preview/opensearchapi/MIGRATING.md#partial-failure-type-renames) for the table). + +### Default Router Injection in v5preview + +`v5preview/opensearchapi.NewClient` (and `NewDefaultClient`) now inject [`opensearchtransport.NewDefaultRouter`](https://pkg.go.dev/github.com/opensearch-project/opensearch-go/v4/opensearchtransport#NewDefaultRouter) when the caller leaves `config.Client.Router` nil. The `OPENSEARCH_GO_ROUTER` environment variable acts as an opt-out: + +| `OPENSEARCH_GO_ROUTER` | v4 | v5preview | +| ---------------------- | --------------------------------------------------- | ----------------------------------------------------------- | +| unset | no Router, no auto-discovery | **default Router injected**, no auto-discovery | +| `true` / `1` | default Router (transport layer), auto-discovery on | **default Router injected, auto-discovery on** | +| `false` / `0` | no Router, no auto-discovery | **injection skipped (Router stays nil)**, no auto-discovery | +| unparseable | no Router, no auto-discovery | default Router injected, no auto-discovery | + +Truthy and falsy semantics are preserved end-to-end: a v4 caller running with `OPENSEARCH_GO_ROUTER=true` keeps auto-discovery when migrating to v5preview, and `=false` opts out of both Router injection and auto-discovery. A caller-supplied `DiscoverNodesOnStart` value always wins over the env-var-driven side-effect. + +v4's `opensearchapi.NewClient` is unchanged: it doesn't auto-inject a Router, so existing v4 code keeps its current behavior. + +For full usage and rationale see [`v5preview/opensearchapi/README.md` Default Router Injection](v5preview/opensearchapi/README.md#default-router-injection). + +### `DiscoverNodes()` blocking semantics + +`opensearch.Client.DiscoverNodes()` and `opensearchtransport.Client.DiscoverNodes()` now **block** when an in-flight discovery cycle is active and return that cycle's error verbatim, instead of the previous immediate `nil` no-op. + +The previous "fire-and-forget" behavior masked discovery failures: a caller that handed control back after a failing discovery saw `err == nil` and continued against a stale node list. The new behavior surfaces the failure synchronously so callers can react (retry, alert, fall back to seed nodes). + +Client construction itself never blocks on discovery: when `Config.DiscoverNodesOnStart` is `&true`, `opensearch.NewClient` launches a detached goroutine that calls `DiscoverNodes()`, then returns. Callers who want fully manual control set `DiscoverNodesOnStart: &false` and `DiscoverNodesInterval: 0` -- no on-start goroutine, no polling loop -- and call `client.DiscoverNodes(ctx)` themselves before issuing requests: + +```go +discoverOnStart := false +client, err := opensearch.NewClient(opensearch.Config{ + Addresses: []string{"https://localhost:9200"}, + DiscoverNodesOnStart: &discoverOnStart, // skip auto-discovery + DiscoverNodesInterval: 0, // disable polling loop +}) +if err != nil { + log.Fatal(err) +} + +ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second) +defer cancel() +if err := client.DiscoverNodes(ctx); err != nil { + log.Printf("initial discovery failed: %s", err) +} + +// proceed to use the client; topology data is ready. +``` + +The signature already changed earlier in this version to take `context.Context` (see CHANGELOG); this is a behavioral change on top of the signature change. + +### `opensearchtransport.Route` interface gained `OpID()` + +The exported `Route` interface in `opensearchtransport` gained a new method: + +```go +type Route interface { + Policy() Policy + Attrs() routeAttr + PoolName() string + OpID() OperationID // new in v5 +} +``` + +External code that implements `Route` (custom routing policies) must add an `OpID() OperationID` method returning the [`OperationID`](https://pkg.go.dev/github.com/opensearch-project/opensearch-go/v4/opensearchtransport#OperationID) for the route -- typically the `Op*` constant matching the route's HTTP method+path. Built-in routes built via `NewRouteMux` are populated automatically; only hand-written `Route` implementations are affected. + +### `Response.Body` becomes a method + +`Response.Body` changes from a public `io.ReadCloser` field to a `Body()` method. The new `RawBody() []byte` method (available since v4) provides access to the buffered response bytes without consuming the body reader. Before 5.0.0: + +```go +body, err := io.ReadAll(resp.Body) +``` + +After 5.0.0: + +```go +body, err := io.ReadAll(resp.Body()) + +// Or, if you only need the raw bytes and the response was already read: +raw := resp.RawBody() +``` + +## Upgrading to >= 4.7.0 + +### `opensearch.Request` interface signature change + +`GetRequest()` now receives the HTTP method from the caller: + +```go +// Before +GetRequest() (*http.Request, error) + +// After +GetRequest(method string) (*http.Request, error) +``` + +This change is invisible to almost all callers: the typed `Req` structs that the client consumes (e.g. `opensearchapi.SearchReq`, the v5-preview `opensearchapi.IndexReq`) already implement the new signature. Only code that defines a custom type satisfying `opensearch.Request` is affected. + +If you maintain such a type, add a `method string` parameter and forward it to your request builder. The `opensearch.BuildRequest` helper that earlier v4 releases exposed for this purpose was **removed in 4.7.0**; construct the request with `net/http` directly instead. Give the path a leading slash (e.g. `/_plugins/my_plugin/status`) -- the transport prepends the base URL by string concatenation, so a path without a leading slash produces a malformed URL. + +```go +// Before (<= 4.6.0): method stored on the struct, built via the removed +// opensearch.BuildRequest helper (which set Content-Type for a non-nil body). +func (r customReq) GetRequest() (*http.Request, error) { + return opensearch.BuildRequest(r.method, r.path, r.body, nil, nil) +} + +// After (>= 4.7.0): method comes from the caller, built with net/http. +func (r customReq) GetRequest(method string) (*http.Request, error) { + req, err := http.NewRequest(method, r.path, r.body) + if err != nil { + return nil, err + } + // BuildRequest set this automatically for a non-nil body; http.NewRequest + // does not, so set it here or OpenSearch may reject a JSON body with 400/415. + if r.body != nil { + req.Header.Set("Content-Type", "application/json") + } + return req, nil +} +``` + +`opensearch.BuildRequest` also accepted `params map[string]string` and `headers http.Header` arguments. To preserve those, set them on the `*http.Request` after construction: encode params onto `req.URL.RawQuery` (via `url.Values`) and add headers to `req.Header`. + +### Path segment values are percent-encoded + +Every typed `Req.GetRequest()` method now constructs URL paths through the generated `internal/path/*Path` builders, which unconditionally percent-encode user-supplied segment values (via `url.PathEscape`, plus an explicit `/` -> `%2F` substitution). This closes the [#650] path-injection class of bugs: an `Index` value containing `../../_cluster/health` can no longer escape its segment to alter routing. + +Prior to this release, `buildPath` wrote segment values raw, which left the wire format ambiguous and the encoding contract undefined: callers who passed unencoded metacharacters got a malformed URL, and callers who passed pre-encoded values got the encoded bytes through to the server. Both interpretations existed simultaneously. The client now defines a single contract — pass raw, unencoded values; the client encodes — and applies it everywhere. + +The practical consequence for callers who were already passing pre-encoded values is that those values are now double-encoded: + +```go +// Before: the URL contained "my%2Findex" verbatim (relying on undefined behavior) +// After: the URL contains "my%252Findex" (the percent itself is encoded) +client.Indices.Get(ctx, opensearchapi.IndicesGetReq{Index: []string{"my%2Findex"}}) +``` + +If your code intentionally passes percent-encoded values, decode them with `url.PathUnescape` before populating the Req struct. + +[#650]: https://github.com/opensearch-project/opensearch-go/issues/650 + +### `v5preview/opensearchapi/` package — v5 preview API surface + +This release introduces a new `v5preview/opensearchapi/` package alongside the existing top-level `opensearchapi/` package. The new package is the **preview of the v5 API in the v4 branch** and is generated from the [OpenSearch API specification](https://github.com/opensearch-project/opensearch-api-specification) by `cmd/osgen`. It deliberately reuses the package name `opensearchapi` so that callers who migrate during the v4 branch only need to change the import path at v5 release time -- every reference in code (e.g. `opensearchapi.IndexReq`, `opensearchapi.NewClient`) stays the same. + +**Migration Considerations:** + +- Migrating to `v5preview/opensearchapi/` in v4 gives you the v5 surface ahead of v5 release. The trade-off at v5 release time is a single edit per consuming file: change the import path from `/v4/v5preview/opensearchapi` to `/v5/opensearchapi`. Package qualifiers do not change. +- Staying on the top-level `opensearchapi/` package is fine through the rest of v4. At v5, the hand-written `opensearchapi/` is removed; the only forward path is the code-generated API surface (closely matches the existing hand-written ergonomics). + +**Import path:** + +```go +import "github.com/opensearch-project/opensearch-go/v4/v5preview/opensearchapi" + +client, err := opensearchapi.NewClient(opensearchapi.Config{...}) +``` + +**Surface differences worth knowing about:** + +- Optional `Params` are `*Params` pointer fields (nil-safe; pass `&opensearchapi.IndexParams{...}` to set). +- Optional boolean query parameters are `*bool` so a deliberate `false` can be sent over the wire. +- Multi-index `Req` types use `Index []string` (the spec spelling); v4's hand-written `Indices` is renamed. +- Plugin APIs (k-NN, ML, Security, ISM, etc.) live in `v5preview/opensearchapi/plugins/`. + +For the full v4 -> v5preview surface delta and the optional forward-compatible `replace` directive, see [`v5preview/opensearchapi/MIGRATING.md`](v5preview/opensearchapi/MIGRATING.md). For everyday usage (errors, routing, response handling) see [`v5preview/opensearchapi/README.md`](v5preview/opensearchapi/README.md). + +## Upgrading to >= 4.0.0 + +Version 4.0.0 updated the module import path, moved error types from opensearchapi to opensearch, renamed them, added new error types, and migrated the `signer/aws` package from AWS SDK v1 to AWS SDK v2. + +### Import Path + +Update all import paths from `v3` to `v4`: + +```go +// Before (v3) +import ( + "github.com/opensearch-project/opensearch-go/v3" + "github.com/opensearch-project/opensearch-go/v3/opensearchapi" +) + +// After (v4) +import ( + "github.com/opensearch-project/opensearch-go/v4" + "github.com/opensearch-project/opensearch-go/v4/opensearchapi" +) +``` + +Update your `go.mod`: + +```bash +go get github.com/opensearch-project/opensearch-go/v4@latest +``` + +### Error Types + +Before 4.0.0: Error types: + +- `opensearchapi.Error` +- `opensearchapi.StringError` + +With 4.0.0: Error types + +- `opensearch.Error` -- base error with string `Err` field +- `opensearch.StringError` -- raw string error body +- `opensearch.ReasonError` -- error with `Reason` and `Status` fields +- `opensearch.MessageError` -- error with `Message` field +- `opensearch.StructError` -- structured JSON error with `Type`, `Reason`, `RootCause` (was `opensearchapi.Error`) + +Update `errors.As` targets to use `opensearch.*` instead of `opensearchapi.*`: + +```go +// Before (v3) +var opensearchError *opensearchapi.Error +if errors.As(err, &opensearchError) { + fmt.Println(opensearchError.Err.Type) +} + +// After (v4) +var opensearchError *opensearch.StructError +if errors.As(err, &opensearchError) { + fmt.Println(opensearchError.Err.Type) +} +``` + +### StringError for Unknown JSON Responses + +Version 4.0.0 returns `*opensearch.StringError` error type instead of `*fmt.wrapError` when response received from the server is an unknown JSON. For example, consider delete document API which returns an unknown JSON body when document is not found. + +Before 4.0.0: + ```go docDelResp, err = client.Document.Delete(ctx, opensearchapi.DocumentDeleteReq{Index: "movies", DocumentID: "3"}) if err != nil { fmt.Println(err) - + if !errors.Is(err, opensearch.ErrJSONUnmarshalBody) && docDelResp != nil { resp := docDelResp.Inspect().Response // get http status fmt.Println(resp.StatusCode) body := strings.TrimPrefix(err.Error(), "opensearch error response could not be parsed as error: ") errResp := opensearchapi.DocumentDeleteResp{} - json.Unmarshal([]byte(body), &errResp) - // extract result field from the body + json.Unmarshal([]byte(body), &errResp) + // extract result field from the body fmt.Println(errResp.Result) } } ``` -After 5.0.0: +After 4.0.0: + ```go docDelResp, err = client.Document.Delete(ctx, opensearchapi.DocumentDeleteReq{Index: "movies", DocumentID: "3"}) if err != nil { @@ -50,34 +341,86 @@ if err != nil { } ``` +### AWS Signer -## Upgrading to >= 4.0.0 +The `signer/aws` package now uses AWS SDK v2 instead of AWS SDK v1. AWS SDK v1 reached end-of-support on July 31, 2025. -Version 4.0.0 moved the error types, added with 3.0.0, from opensearchapi to opensearch, renamed them and added new error types. +Before 4.0.0 (AWS SDK v1): -### Error Types +```go +import ( + "github.com/aws/aws-sdk-go/aws/session" + signer "github.com/opensearch-project/opensearch-go/v3/signer/aws" +) -Before 4.0.0: -Error types: -- `opensearchapi.Error` -- `opensearchapi.StringError` +awsSigner, err := signer.NewSigner(session.Options{ + Config: aws.Config{Region: aws.String("us-east-1")}, +}) +``` + +With 4.0.0 (AWS SDK v2): -With 4.0.0: -Error types -- `opensearch.Error` -- `opensearch.StringError` -- `opensearch.ReasonError` -- `opensearch.MessageError` -- `opensearch.StructError` (which was the `opensearchapi.Error`) +```go +import ( + "context" + "github.com/aws/aws-sdk-go-v2/config" + signer "github.com/opensearch-project/opensearch-go/v4/signer/aws" +) + +cfg, err := config.LoadDefaultConfig(context.TODO(), config.WithRegion("us-east-1")) +if err != nil { + return err +} +awsSigner, err := signer.NewSigner(cfg) +``` + +The `signer/awsv2` package (which already used AWS SDK v2) remains available at `github.com/opensearch-project/opensearch-go/v4/signer/awsv2` with the same API. + +### Typed Failure Arrays in By-Query and Reindex Responses + +The `Failures` field in `DocumentDeleteByQueryResp`, `UpdateByQueryResp`, and `ReindexResp` changed from `[]json.RawMessage` to `[]BulkByScrollFailure`. + +**Who is affected:** Only callers that directly access the `.Failures` slice. Code that ignores failures or only checks `len(resp.Failures) > 0` compiles without changes. + +Before: + +```go +for _, raw := range resp.Failures { + var f MyFailureType + if err := json.Unmarshal(raw, &f); err != nil { ... } + // use f.Index, f.Status, etc. +} +``` + +After: + +```go +for _, f := range resp.Failures { + // Fields are available directly — no unmarshaling needed. + fmt.Println(f.Index, f.Status, f.Cause) +} +``` + +### Inline `_shards` Structs Replaced with ResponseShards + +The `Shards` field in `IndexResp`, `DocumentCreateResp`, `DocumentDeleteResp`, `UpdateResp`, `IndicesRefreshResp`, and `IndicesCountResp` changed from an anonymous inline struct to the named `ResponseShards` type. + +**Who is affected:** Code accessing `resp.Shards.Total`, `resp.Shards.Successful`, or `resp.Shards.Failed` compiles unchanged. The only theoretical break is code using reflection or type assertions on the `Shards` field itself. The new type additionally exposes `Failures []ResponseShardsFailure` and `Skipped int` which were previously unavailable. + +### `_type` Field Tags Now Include `omitempty` + +All deprecated `_type` fields across response structs now use `json:"_type,omitempty"`. Mapping types were deprecated in Elasticsearch 6.0 (2017), reduced to the single `_doc` type in Elasticsearch 7.0 (2019), and completely removed from the OpenSearch server in 2.0.0 (May 2022). OpenSearch forked from Elasticsearch 7.10.2, so the deprecation was inherited from day one. This change means the empty string is no longer emitted when marshaling response structs back to JSON. Deserialization behavior is unchanged. ## Upgrading to >= 3.0.0 Version 3.0.0 is a major refactor of the client. ### Client Creation -You now create the client from the opensearchapi and not from the opensearch lib. This was done to make the different APIs independent from each other. Plugin APIs like Security will get there own folder and therefore its own sub-lib. + +You now create the client from the opensearchapi package instead of opensearch. This was done to make the different APIs independent from each other. Plugin APIs like Security get their own folder and therefore their own sub-lib. Before 3.0.0: + ```go // default client client, err := opensearch.NewDefaultClient() @@ -85,9 +428,7 @@ client, err := opensearch.NewDefaultClient() // with config client, err := opensearch.NewClient( opensearch.Config{ - Transport: &http.Transport{ - TLSClientConfig: &tls.Config{InsecureSkipVerify: true}, - }, + InsecureSkipVerify: true, Addresses: []string{"https://localhost:9200"}, Username: "admin", Password: "admin", @@ -105,12 +446,10 @@ client, err := opensearchapi.NewDefaultClient() client, err := opensearchapi.NewClient( opensearchapi.Config{ Client: opensearch.Config{ - Transport: &http.Transport{ - TLSClientConfig: &tls.Config{InsecureSkipVerify: true}, // For testing only. Use certificate for validation. - }, - Addresses: []string{"https://localhost:9200"}, - Username: "admin", // For testing only. Don't store credentials in code. - Password: "admin", + InsecureSkipVerify: true, // For testing only. Use certificate for validation. + Addresses: []string{"https://localhost:9200"}, + Username: "admin", // For testing only. Don't store credentials in code. + Password: "admin", }, }, ) @@ -150,7 +489,6 @@ createIndexResponse, err := client.Indices.Create( ) ``` - ### Responses With the version 3.0.0 the lib no longer returns the opensearch.Response which is just a wrap up http.Response. Instead it will check the response for errors and try to parse the body into existing structs. Please note that some responses are so complex that we parse them as [json.RawMessage](https://pkg.go.dev/encoding/json#RawMessage) so you can parse them to your expected struct. If you need the opensearch.Response, then you can call .Inspect(). @@ -181,11 +519,11 @@ createResp := struct { Acknowledged bool `json:"acknowledged"` ShardsAcknowledged bool `json:"shards_acknowledged"` Index string `json:"index"` -} +}{} // Try to parse the response into the created struct if err := json.NewDecoder(resp.Body).Decode(&createResp); err != nil { - return fmt.Errorf("Undexpected response body: %s, %#v, %s"resp.StatusCode, resp.Body, err) + return fmt.Errorf("unexpected response body: %d, %#v, %s", resp.StatusCode, resp.Body, err) } // Print the created index name fmt.Println(createResp.Index) @@ -265,6 +603,144 @@ if err != nil { } ``` +### API Reorganization + +Version 3.0.0 reorganized APIs into logical sub-clients. The following tables cover every method that moved, was renamed, or was removed. + +**Naming conventions changed:** + +- Request types: `*Request` to `*Req` (e.g., `SearchRequest` to `SearchReq`) +- Query parameters: separate `*Params` sub-struct (e.g., `SearchParams`) +- Functional options (`With*`) removed entirely +- `req.Do(ctx, client)` pattern removed; use `client.Method(ctx, req)` instead + +#### Document Operations -- Moved to `client.Document` + +| Before 3.0.0 | With 3.0.0 | +| ------------------------------------- | --------------------------------------------------- | +| `client.Create(...)` | `client.Document.Create(ctx, req)` | +| `client.Delete(...)` | `client.Document.Delete(ctx, req)` | +| `client.DeleteByQuery(...)` | `client.Document.DeleteByQuery(ctx, req)` | +| `client.DeleteByQueryRethrottle(...)` | `client.Document.DeleteByQueryRethrottle(ctx, req)` | +| `client.Exists(...)` | `client.Document.Exists(ctx, req)` | +| `client.ExistsSource(...)` | `client.Document.ExistsSource(ctx, req)` | +| `client.Explain(...)` | `client.Document.Explain(ctx, req)` | +| `client.Get(...)` | `client.Document.Get(ctx, req)` | +| `client.GetSource(...)` | `client.Document.Source(ctx, req)` | + +#### Scroll Operations -- Moved to `client.Scroll` + +| Before 3.0.0 | With 3.0.0 | +| ------------------------- | -------------------------------- | +| `client.ClearScroll(...)` | `client.Scroll.Delete(ctx, req)` | +| `client.Scroll(...)` | `client.Scroll.Get(ctx, req)` | + +#### Script Operations -- Moved to `client.Script` + +| Before 3.0.0 | With 3.0.0 | +| ------------------------------------ | ----------------------------------------- | +| `client.DeleteScript(...)` | `client.Script.Delete(ctx, req)` | +| `client.GetScript(...)` | `client.Script.Get(ctx, req)` | +| `client.GetScriptContext(...)` | `client.Script.Context(ctx, req)` | +| `client.GetScriptLanguages(...)` | `client.Script.Language(ctx, req)` | +| `client.PutScript(...)` | `client.Script.Put(ctx, req)` | +| `client.ScriptsPainlessExecute(...)` | `client.Script.PainlessExecute(ctx, req)` | + +#### Index Alias, Mapping, Settings -- Moved to Nested Sub-clients + +| Before 3.0.0 | With 3.0.0 | +| ------------------------------------- | ---------------------------------------- | +| `client.Indices.DeleteAlias(...)` | `client.Indices.Alias.Delete(ctx, req)` | +| `client.Indices.ExistsAlias(...)` | `client.Indices.Alias.Exists(ctx, req)` | +| `client.Indices.GetAlias(...)` | `client.Indices.Alias.Get(ctx, req)` | +| `client.Indices.PutAlias(...)` | `client.Indices.Alias.Put(ctx, req)` | +| `client.Indices.UpdateAliases(...)` | `client.Aliases(ctx, req)` | +| `client.Indices.GetMapping(...)` | `client.Indices.Mapping.Get(ctx, req)` | +| `client.Indices.PutMapping(...)` | `client.Indices.Mapping.Put(ctx, req)` | +| `client.Indices.GetFieldMapping(...)` | `client.Indices.Mapping.Field(ctx, req)` | +| `client.Indices.GetSettings(...)` | `client.Indices.Settings.Get(ctx, req)` | +| `client.Indices.PutSettings(...)` | `client.Indices.Settings.Put(ctx, req)` | + +#### Templates -- Moved to Top-level Sub-clients + +| Before 3.0.0 | With 3.0.0 | +| --------------------------------------------- | ---------------------------------------------- | +| `client.Indices.DeleteIndexTemplate(...)` | `client.IndexTemplate.Delete(ctx, req)` | +| `client.Indices.ExistsIndexTemplate(...)` | `client.IndexTemplate.Exists(ctx, req)` | +| `client.Indices.GetIndexTemplate(...)` | `client.IndexTemplate.Get(ctx, req)` | +| `client.Indices.PutIndexTemplate(...)` | `client.IndexTemplate.Create(ctx, req)` | +| `client.Indices.SimulateIndexTemplate(...)` | `client.IndexTemplate.SimulateIndex(ctx, req)` | +| `client.Indices.SimulateTemplate(...)` | `client.IndexTemplate.Simulate(ctx, req)` | +| `client.Indices.DeleteTemplate(...)` | `client.Template.Delete(ctx, req)` | +| `client.Indices.ExistsTemplate(...)` | `client.Template.Exists(ctx, req)` | +| `client.Indices.GetTemplate(...)` | `client.Template.Get(ctx, req)` | +| `client.Indices.PutTemplate(...)` | `client.Template.Create(ctx, req)` | +| `client.Cluster.DeleteComponentTemplate(...)` | `client.ComponentTemplate.Delete(ctx, req)` | +| `client.Cluster.ExistsComponentTemplate(...)` | `client.ComponentTemplate.Exists(ctx, req)` | +| `client.Cluster.GetComponentTemplate(...)` | `client.ComponentTemplate.Get(ctx, req)` | +| `client.Cluster.PutComponentTemplate(...)` | `client.ComponentTemplate.Create(ctx, req)` | + +#### Data Streams -- Moved to `client.DataStream` + +| Before 3.0.0 | With 3.0.0 | +| ---------------------------------------- | ------------------------------------ | +| `client.Indices.CreateDataStream(...)` | `client.DataStream.Create(ctx, req)` | +| `client.Indices.DeleteDataStream(...)` | `client.DataStream.Delete(ctx, req)` | +| `client.Indices.GetDataStream(...)` | `client.DataStream.Get(ctx, req)` | +| `client.Indices.GetDataStreamStats(...)` | `client.DataStream.Stats(ctx, req)` | + +#### Snapshot Repository -- Moved to `client.Snapshot.Repository` + +| Before 3.0.0 | With 3.0.0 | +| ---------------------------------------- | ---------------------------------------------- | +| `client.Snapshot.CreateRepository(...)` | `client.Snapshot.Repository.Create(ctx, req)` | +| `client.Snapshot.DeleteRepository(...)` | `client.Snapshot.Repository.Delete(ctx, req)` | +| `client.Snapshot.GetRepository(...)` | `client.Snapshot.Repository.Get(ctx, req)` | +| `client.Snapshot.CleanupRepository(...)` | `client.Snapshot.Repository.Cleanup(ctx, req)` | +| `client.Snapshot.VerifyRepository(...)` | `client.Snapshot.Repository.Verify(ctx, req)` | + +#### Ingest -- Renamed Methods + +| Before 3.0.0 | With 3.0.0 | +| ----------------------------------- | -------------------------------- | +| `client.Ingest.PutPipeline(...)` | `client.Ingest.Create(ctx, req)` | +| `client.Ingest.DeletePipeline(...)` | `client.Ingest.Delete(ctx, req)` | +| `client.Ingest.GetPipeline(...)` | `client.Ingest.Get(ctx, req)` | +| `client.Ingest.ProcessorGrok(...)` | `client.Ingest.Grok(ctx, req)` | + +#### Dangling Indices -- Moved to `client.Dangling` + +| Before 3.0.0 | With 3.0.0 | +| ------------------------------------------------ | ---------------------------------- | +| `client.DanglingIndicesDeleteDanglingIndex(...)` | `client.Dangling.Delete(ctx, req)` | +| `client.DanglingIndicesImportDanglingIndex(...)` | `client.Dangling.Import(ctx, req)` | +| `client.DanglingIndicesListDanglingIndices(...)` | `client.Dangling.Get(ctx, req)` | + +#### Other Renames + +| Before 3.0.0 | With 3.0.0 | +| ---------------------------------------- | --------------------------------------- | +| `client.Count(...)` | `client.Indices.Count(ctx, req)` | +| `client.FieldCaps(...)` | `client.Indices.FieldCaps(ctx, req)` | +| `client.Mget(...)` | `client.MGet(ctx, req)` | +| `client.MSearch(...)` | `client.MSearch(ctx, req)` | +| `client.MSearchTemplate(...)` | `client.MSearchTemplate(ctx, req)` | +| `client.Mtermvectors(...)` | `client.MTermvectors(ctx, req)` | +| `client.Indices.AddBlock(...)` | `client.Indices.Block(ctx, req)` | +| `client.Indices.ResolveIndex(...)` | `client.Indices.Resolve(ctx, req)` | +| `client.Cat.Fielddata(...)` | `client.Cat.FieldData(ctx, req)` | +| `client.Cat.Nodeattrs(...)` | `client.Cat.NodeAttrs(ctx, req)` | +| `client.Nodes.ReloadSecureSettings(...)` | `client.Nodes.ReloadSecurity(ctx, req)` | + +#### Removed APIs (no v3+ equivalent) + +- `client.TermsEnum(...)` +- `client.Cat.Help(...)` +- `client.Indices.DiskUsage(...)` +- `client.Indices.FieldUsageStats(...)` +- `client.Indices.GetUpgrade(...)` +- `client.Indices.Upgrade(...)` + ## Upgrading to >= 2.3.0 ### Snapshot Delete @@ -304,4 +780,5 @@ sliceSnapshotToDelete := []string{"snapshot-1", "snapshot-2"} reqSnapshots := &opensearchapi.SnapshotDeleteRequest{ Repository: repo, Snapshot: sliceSnapshotsToDelete, +} ``` diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/USER_GUIDE.md b/vendor/github.com/opensearch-project/opensearch-go/v4/USER_GUIDE.md index edef4d3583..0556da8006 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/USER_GUIDE.md +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/USER_GUIDE.md @@ -1,9 +1,10 @@ - [User Guide](#user-guide) - - [Example](#example) - - [Amazon OpenSearch Service](#amazon-opensearch-service) - - [AWS SDK v1](#aws-sdk-v1) - - [AWS SDK v2](#aws-sdk-v2) - - [Guides by Topic](#guides-by-topic) + - [Example](#example) + - [Amazon OpenSearch Service](#amazon-opensearch-service) + - [AWS SDK v1](#aws-sdk-v1) + - [AWS SDK v2](#aws-sdk-v2) + - [Custom Transport](#custom-transport) + - [Guides by Topic](#guides-by-topic) # User Guide @@ -16,15 +17,16 @@ package main import ( "context" - "crypto/tls" "errors" "fmt" - "net/http" "os" "strings" + "time" "github.com/opensearch-project/opensearch-go/v4" + "github.com/opensearch-project/opensearch-go/v4/errmask" "github.com/opensearch-project/opensearch-go/v4/opensearchapi" + "github.com/opensearch-project/opensearch-go/v4/opensearchtransport" "github.com/opensearch-project/opensearch-go/v4/opensearchutil" ) @@ -39,16 +41,34 @@ func main() { func example() error { // Initialize the client with SSL/TLS enabled. + router, err := opensearchtransport.NewDefaultRouter() + if err != nil { + return err + } + + // Surface partial failures (bulk item errors, shard failures) as Go + // errors. See guides/error_handling.md for the per-category bitmask. + errMask := errmask.Empty + discoverOnStart := true client, err := opensearchapi.NewClient( opensearchapi.Config{ Client: opensearch.Config{ - Transport: &http.Transport{ - TLSClientConfig: &tls.Config{InsecureSkipVerify: true}, // For testing only. Use certificate for validation. - }, - Addresses: []string{"https://localhost:9200"}, - Username: "admin", // For testing only. Don't store credentials in code. - Password: "myStrongPassword123!", + InsecureSkipVerify: true, // For testing only. Use certificate for validation. + Addresses: []string{"https://localhost:9200"}, + Username: "admin", // For testing only. Don't store credentials in code. + Password: "myStrongPassword123!", + + // Optional: Enable node discovery + DiscoverNodesOnStart: &discoverOnStart, + DiscoverNodesInterval: 5 * time.Minute, + + // Optional: Enable intelligent request routing + Router: router, }, + + // Optional: Surface partial failures (bulk item errors, shard failures) + // as Go errors. See guides/error_handling.md for details. + Errors: &errMask, }, ) if err != nil { @@ -85,7 +105,7 @@ func example() error { var opensearchError *opensearch.StructError - // Load err into opensearch.Error to access the fields and tolerate if the index already exists + // Load err into opensearch.StructError to access the fields and tolerate if the index already exists if err != nil { if errors.As(err, &opensearchError) { if opensearchError.Err.Type != "resource_already_exists_exception" { @@ -187,7 +207,7 @@ func example() error { // Try to delete the index again which fails as it does not exist _, err = client.Indices.Delete(ctx, deleteIndex) - // Load err into opensearchapi.Error to access the fields and tolerate if the index is missing + // Load err into opensearch.StructError to access the fields and tolerate if the index is missing if err != nil { if errors.As(err, &opensearchError) { if opensearchError.Err.Type != "index_not_found_exception" { @@ -210,13 +230,19 @@ Before starting, we strongly recommend reading the full AWS documentation regard > > See [Managed Domains signing-service requests.](https://docs.aws.amazon.com/opensearch-service/latest/developerguide/ac.html#managedomains-signing-service-requests) -Depending on the version of AWS SDK used, import the v1 or v2 request signer from `signer/aws` or `signer/awsv2` respectively. Both signers are equivalent in their functionality, they provide AWS Signature Version 4 (SigV4). +Depending on the version of AWS SDK used, import the request signer from `signer/aws` (recommended) or `signer/awsv2`. Both signers use AWS SDK v2 and provide AWS Signature Version 4 (SigV4). + +**BREAKING CHANGE**: As of this version, the main `signer/aws` package has been migrated from AWS SDK v1 to AWS SDK v2 due to AWS SDK v1 reaching end-of-support on July 31, 2025. To read more about SigV4 see [Signature Version 4 signing process](https://docs.aws.amazon.com/general/latest/gr/signature-version-4.html) Here are some Go samples that show how to sign each OpenSearch request and automatically search for AWS credentials from the ~/.aws folder or environment variables: -### AWS SDK v1 +### AWS SDK v2 (Recommended) + +**Migration Note**: If you were previously using `signer/aws` with AWS SDK v1, you need to update your imports and configuration as shown below. + +**Credential Caching**: The signer automatically enables credential caching for improved performance, especially when using STS credentials (assume role, web identity, etc.). This reduces API calls to AWS STS and improves signing performance. ```go package main @@ -226,7 +252,8 @@ import ( "fmt" "os" - "github.com/aws/aws-sdk-go/aws/session" + "github.com/aws/aws-sdk-go-v2/aws" + "github.com/aws/aws-sdk-go-v2/config" requestsigner "github.com/opensearch-project/opensearch-go/v4/signer/aws" "github.com/opensearch-project/opensearch-go/v4" @@ -245,16 +272,22 @@ func main() { const endpoint = "" // e.g. https://opensearch-domain.region.com func example() error { - // Create an AWS request Signer and load AWS configuration using default config folder or env vars. - // See https://docs.aws.amazon.com/opensearch-service/latest/developerguide/request-signing.html#request-signing-go - signer, err := requestsigner.NewSignerWithService( - session.Options{SharedConfigState: session.SharedConfigEnable}, - requestsigner.OpenSearchService, // Use requestsigner.OpenSearchServerless for Amazon OpenSearch Serverless. - ) + ctx := context.Background() + + // Load AWS configuration + awsCfg, err := config.LoadDefaultConfig(ctx) if err != nil { return err } - // Create an opensearch client and use the request-signer. + + // Create an AWS request Signer + signer, err := requestsigner.NewSignerWithService(awsCfg, requestsigner.OpenSearchService) + // Use requestsigner.OpenSearchServerless for Amazon OpenSearch Serverless + if err != nil { + return err + } + + // Create an opensearch client and use the request-signer client, err := opensearchapi.NewClient( opensearchapi.Config{ Client: opensearch.Config{ @@ -267,20 +300,18 @@ func example() error { return err } - ctx := context.Background() - ping, err := client.Ping(ctx, nil) if err != nil { return err } - fmt.Println(ping) + fmt.Println(ping) return nil } ``` -### AWS SDK v2 +### Alternative: Using signer/awsv2 Use the AWS SDK v2 for Go to authenticate with Amazon OpenSearch service. @@ -387,8 +418,158 @@ func getCredentialProvider(accessKey, secretAccessKey, token string) aws.Credent } ``` +## Custom Transport + +For common TLS options, prefer the built-in config fields (`InsecureSkipVerify`, `CACert`) over constructing a custom `http.Transport`. These options clone the default transport internally, preserving connection pooling, HTTP/2, and timeout defaults. + +If you need a custom transport (e.g. for mutual TLS or a corporate proxy), **always clone `http.DefaultTransport` rather than constructing a bare `&http.Transport{}`**. A bare transport defaults to `MaxIdleConnsPerHost: 2`, disables HTTP/2 multiplexing, and has no dialer timeouts -- causing excessive TLS handshakes and connection churn under concurrency. + +```go +// Good: clone DefaultTransport, then customize. +tp := http.DefaultTransport.(*http.Transport).Clone() +tp.TLSClientConfig.Certificates = []tls.Certificate{cert} + +client, err := opensearch.NewClient(opensearch.Config{ + Addresses: []string{"https://localhost:9200"}, + Transport: tp, +}) +``` + +```go +// Bad: bare transport loses all DefaultTransport defaults. +client, err := opensearch.NewClient(opensearch.Config{ + Addresses: []string{"https://localhost:9200"}, + Transport: &http.Transport{ + TLSClientConfig: &tls.Config{ + Certificates: []tls.Certificate{cert}, + }, + }, + // MaxIdleConnsPerHost = 2, no HTTP/2, no dialer timeouts! +}) +``` + +Key settings to verify on any custom transport: + +| Setting | `DefaultTransport` | Bare `&http.Transport{}` | +| ---------------------- | ------------------ | ------------------------ | +| `MaxIdleConns` | 100 | 0 (unlimited) | +| `MaxIdleConnsPerHost` | 2 | 2 | +| `ForceAttemptHTTP2` | true | false | +| `IdleConnTimeout` | 90s | 0 (no timeout) | +| `TLSHandshakeTimeout` | 10s | 0 (no timeout) | +| `DialContext` timeouts | 30s | none | + +`Clone()` copies all of these. If you must build from scratch (e.g. for a non-`*http.Transport` round tripper), set at minimum `ForceAttemptHTTP2: true` and `MaxIdleConnsPerHost` >= your expected concurrency. + +## Operation Classifier + +The `opensearchtransport.OperationClassifier` maps HTTP method+path pairs to structured `OperationID` values. This enables transparent metrics, tracing, or access-control middleware at the `http.RoundTripper` layer without per-operation wrapper code. + +```go +import "github.com/opensearch-project/opensearch-go/v4/opensearchtransport" + +// Build once, reuse across requests. Safe for concurrent use. +classifier := opensearchtransport.NewOperationClassifier() + +// In an http.RoundTripper: +func (t *MetricsTransport) RoundTrip(req *http.Request) (*http.Response, error) { + op := t.classifier.Classify(req.Method, req.URL.Path) + + start := time.Now() + resp, err := t.next.RoundTrip(req) + duration := time.Since(start) + + status := 0 + if resp != nil { + status = resp.StatusCode + } + t.histogram.WithLabelValues(op.String(), strconv.Itoa(status)).Observe( + float64(duration.Milliseconds()), + ) + return resp, err +} +``` + +`OperationID` is a bit-packed `int64` with masking helpers: + +```go +op := classifier.Classify("POST", "/my-index/_search") +op.String() // "search" +op.IsWrite() // false +op.IsRead() // true +op.Category() // CatSearch +``` + +Returns `OpOther` for unrecognized patterns. + +## Debugging + +Set the `OPENSEARCH_GO_DEBUG` environment variable to enable debug logging for connection management, node discovery, and request routing. Debug output is written to stderr. + +```bash +OPENSEARCH_GO_DEBUG=true go run myapp.go +``` + +For programmatic control, set `EnableDebugLogger: true` in the client configuration: + +```go +client, err := opensearchapi.NewClient( + opensearchapi.Config{ + Client: opensearch.Config{ + Addresses: []string{"http://localhost:9200"}, + EnableDebugLogger: true, + }, + }, +) +``` + +In tests, use the `testutil.IsDebugEnabled(t)` helper which also reads `OPENSEARCH_GO_DEBUG`: + +```bash +OPENSEARCH_GO_DEBUG=true go test ./... +``` + +## Policy Overrides + +Disable specific routing policies at startup via environment variables for debugging, A/B testing, or emergency overrides: + +```bash +# Disable all connection scoring (fall back to plain role-based) +OPENSEARCH_GO_POLICY_ROUTER=false myapp + +# Disable a specific policy instance by path +OPENSEARCH_GO_POLICY_ROLE=chain[0].mux[0].role[0]=false myapp + +# Regex path matching +OPENSEARCH_GO_POLICY_ROLE=.*mux.*role.*=false myapp +``` + +Set `OPENSEARCH_GO_DEBUG=true` to see policy paths and override actions. See [Request Routing](guides/routing.md#policy-override-variables) for full documentation. + +## Environment Variables + +All `OPENSEARCH_GO_*` environment variables are evaluated once at client initialization. A complete reference is in [Request Routing: Configuration Reference](guides/routing.md#14-configuration-reference). Quick summary: + +| Variable | Default | Description | +| ----------------------------------- | ------------- | --------------------------------------------------------------------------- | +| `OPENSEARCH_GO_REQUEST_TIMEOUT` | 0 (none) | Per-attempt HTTP request timeout (duration or secs) | +| `OPENSEARCH_GO_DEBUG` | `false` | Debug logging to stderr | +| `OPENSEARCH_GO_ROUTER` | `false` | Auto-construct DefaultRouter when no Router is set | +| `OPENSEARCH_GO_ROUTING_CONFIG` | (all enabled) | Shard-exact routing (`-shard_exact`) | +| `OPENSEARCH_GO_SHARD_REQUESTS` | `true` | Adaptive `max_concurrent_shard_requests` bounds | +| `OPENSEARCH_GO_SHARD_COST` | (defaults) | Shard cost multipliers for connection scoring | +| `OPENSEARCH_GO_DISCOVERY_CONFIG` | (all enabled) | Skip specific discovery calls | +| `OPENSEARCH_GO_FALLBACK` | `true` | Seed URL fallback when all pools exhausted | +| `OPENSEARCH_GO_NODE_STATS_INTERVAL` | auto (5s-30s) | Stats polling interval | +| `OPENSEARCH_GO_POLICY_*` | (all enabled) | Disable specific routing policies (10 variables) | +| `OPENSEARCH_GO_ACTIVE_LIST_CAP` | auto | Max active connections per pool | +| `OPENSEARCH_GO_STANDBY_*` | (see guide) | Standby rotation and promotion tuning (3 variables) | +| `OPENSEARCH_GO_OVERLOADED_*` | (see guide) | JVM heap and breaker thresholds (2 variables) | +| `OPENSEARCH_GO_ERROR_MASK` | (version-dep) | Mask partial-failure categories (`+`/`-` tokens; overrides `Config.Errors`) | + ## Guides by Topic +- [**Security**](guides/security.md) - TLS, credentials, input validation, index patterns, error disclosure - [Index Lifecycle](guides/index_lifecycle.md) - [Document Lifecycle](guides/document_lifecycle.md) - [Search](guides/search.md) @@ -396,4 +577,10 @@ func getCredentialProvider(accessKey, secretAccessKey, token string) aws.Credent - [Advanced Index Actions](guides/advanced_index_actions.md) - [Index Templates](guides/index_template.md) - [Data Streams](guides/data_streams.md) +- [Making Raw JSON REST Requests](guides/json.md) +- [Request Routing](guides/routing.md) +- [Cluster Health Checking](guides/cluster_health_checking.md) +- [Node Discovery and Role Management](guides/node_discovery_and_roles.md) +- [Response Body Buffering](guides/response_buffering.md) - [Retry and Backoff](guides/retry_backoff.md) +- [Error Handling](guides/error_handling.md) diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/doc.go b/vendor/github.com/opensearch-project/opensearch-go/v4/doc.go index b2bfd6398c..a01a7835d8 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/doc.go +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/doc.go @@ -37,21 +37,21 @@ It is an error to set both environment variable. To configure the client, pass a Config object to the NewClient function: + // Clone DefaultTransport to preserve connection pooling, HTTP/2, and timeouts. + tp := http.DefaultTransport.(*http.Transport).Clone() + tp.MaxIdleConnsPerHost = 10 + tp.ResponseHeaderTimeout = time.Second + tp.DialContext = (&net.Dialer{Timeout: time.Second}).DialContext + tp.TLSClientConfig.MinVersion = tls.VersionTLS11 + cfg := opensearch.Config{ Addresses: []string{ "http://localhost:9200", "http://localhost:9201", }, - Username: "foo", - Password: "bar", - Transport: &http.Transport{ - MaxIdleConnsPerHost: 10, - ResponseHeaderTimeout: time.Second, - DialContext: (&net.Dialer{Timeout: time.Second}).DialContext, - TLSClientConfig: &tls.Config{ - MinVersion: tls.VersionTLS11, - }, - }, + Username: "foo", + Password: "bar", + Transport: tp, } opensearch.NewClient(cfg) diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/errmask/errmask.go b/vendor/github.com/opensearch-project/opensearch-go/v4/errmask/errmask.go new file mode 100644 index 0000000000..2bb9ceef33 --- /dev/null +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/errmask/errmask.go @@ -0,0 +1,325 @@ +// SPDX-License-Identifier: Apache-2.0 +// +// The OpenSearch Contributors require contributions made to +// this file be licensed under the Apache-2.0 license or a +// compatible open source license. + +// Package errmask defines the bitfield used by opensearchapi to mask +// (ignore) specific categories of partial-failure errors. +// +// Each bit corresponds to one wrapper schema in the +// "x-error-responses" extension proposed for the OpenAPI spec +// (see issue-x-partial-failure-mode.md in opensearch-api-specification). +// Until that extension lands upstream, cmd/osgen carries a hardcoded +// per-operation map of which wrappers each operation can return. +// +// Bit semantics: a set bit masks (suppresses) that category; an unset +// bit reports it as a typed Go error. [Empty] (the zero value) reports +// every category; [All] is the union of every defined wrapper bit and +// masks every category. [None] and [Unknown] are doc-friendly aliases +// for [Empty] -- both equal 0. +// +// Callers wire ErrorMask through Config.Errors as a *ErrorMask pointer. +// The pointer's nil/non-nil state is what disambiguates "use the +// version's default" from "caller chose this value": +// +// cfg.Errors == nil use the version's default +// (v4: errmask.All; v5+: errmask.Empty) +// cfg.Errors == errmask.New() caller wants every category reported +// cfg.Errors == errmask.New(All) caller wants every category masked +// +// Because [Empty] and [All] are constants they are not addressable; use +// [New] to obtain the *ErrorMask the Config field expects (New() with no +// arguments yields a pointer to [Empty]). +// +// The same ErrorMask value is consumed by both the v4 opensearchapi +// package and the generated v5preview/opensearchapi package, so callers +// can reason about error behavior uniformly across the two surfaces. +package errmask + +import ( + "strings" +) + +// ErrorMask is a bitfield of error categories to mask. A set bit causes +// the API method to return (resp, nil) for that class of partial failure +// instead of the typed error. The zero value [Empty] masks nothing. +type ErrorMask uint32 + +// New returns a pointer to the mask formed by OR-ing bits together, ready +// to assign to Config.Errors. With no arguments it returns a pointer to +// [Empty] (report every partial-failure category). Constants such as +// [Empty] and [All] are not addressable, so this is the supported way to +// build the *ErrorMask the Config field expects: +// +// Config{Errors: errmask.New()} // report everything +// Config{Errors: errmask.New(errmask.All)} // mask everything +// Config{Errors: errmask.New( // composite +// errmask.SearchShards | errmask.MultiSearchItems)} +func New(bits ...ErrorMask) *ErrorMask { + var m ErrorMask + for _, b := range bits { + m |= b + } + return &m +} + +// ErrorMask bits. One bit per wrapper schema in the proposed +// x-error-responses catalog. Append new wrappers at the end so existing +// values remain stable across releases. The set of bits assigned here +// matches the catalog in +// opensearch-api-specification/issue-x-partial-failure-mode.md. +const ( + // BulkItems masks PartialBulkError on bulk-style responses with + // errors=true and per-item error objects (Bulk, BulkStream). + BulkItems ErrorMask = 1 << iota + + // SearchShards masks PartialSearchError on the standard _shards + // envelope of search-family responses (Search, Scroll, SearchTemplate, + // CreatePIT, Count, AsyncSearch.*). + SearchShards + + // WriteShards masks ShardFailureError on the _shards envelope of + // single-document write responses (Index, Update, Delete). + WriteShards + + // BroadcastShards masks shard failures on the _shards envelope of + // broadcast responses (Indices.Refresh/Flush/ForceMerge/etc.). + BroadcastShards + + // NodeFailures masks node-level failures emitted under the _nodes + // envelope (Cluster.Stats, Nodes.Info/Stats/Usage, etc.). + NodeFailures + + // BulkByScrollFailures masks the top-level failures[] array in + // Reindex / UpdateByQuery / DeleteByQuery responses. + BulkByScrollFailures + + // TaskFailures masks the parallel task_failures[] / node_failures[] + // arrays returned by Tasks.List and Tasks.Cancel. + TaskFailures + + // MultiSearchItems masks per-response error objects within + // responses[] of MSearch / MSearchTemplate. + MultiSearchItems + + // MultiDocItems masks per-document error objects within docs[] + // of MGet / MTermvectors. + MultiDocItems + + // SnapshotCreateShardFailures masks snapshot.failures[] on a + // Snapshot.Create response (when wait_for_completion=true). + SnapshotCreateShardFailures + + // SnapshotGetShardFailures masks snapshots[].failures[] on a + // Snapshot.Get response (per snapshot in the list). + SnapshotGetShardFailures + + // SimulateDocFailures masks docs[].error and per-processor errors + // on Ingest.Simulate responses. + SimulateDocFailures + + // RankEvalFailures masks the top-level failures: { queryId: error } + // map on _rank_eval responses. + RankEvalFailures + + // IngestionShardFailures masks the failures: { indexName: [...] } + // map on Ingestion.Pause / Ingestion.Resume responses. + IngestionShardFailures + + // PitNodeFailures masks the top-level failures[] array on + // _core.get_all_pits responses (server-side server quirk: not + // wrapped in _nodes). + PitNodeFailures +) + +// Empty is the zero value of [ErrorMask]: no categories masked, every +// partial-failure category is reported as a typed Go error. +// +// [Unknown] and [None] are doc-friendly aliases. They all equal 0; the +// nil-vs-non-nil pointer state of Config.Errors is what disambiguates +// "use the version's default" from "caller explicitly set Empty". +const Empty ErrorMask = 0 + +// Unknown is an alias for [Empty] used at API boundaries where a +// nil-vs-non-nil pointer disambiguates "the caller did not configure +// a mask" from "the caller chose Empty". The resolver substitutes a +// version-specific default for nil pointers (v4 -> [All]; v5 -> +// [Empty]); a non-nil pointer to Unknown is honored verbatim. +const Unknown = Empty + +// None is an alias for [Empty]. Reads naturally at call sites that say +// "no categories should be suppressed" without invoking the +// nil-pointer-versus-zero-value subtlety. +const None = Empty + +// All is the union of every defined wrapper bit; every category is +// masked. +const All = BulkItems | SearchShards | WriteShards | BroadcastShards | + NodeFailures | BulkByScrollFailures | TaskFailures | + MultiSearchItems | MultiDocItems | + SnapshotCreateShardFailures | SnapshotGetShardFailures | + SimulateDocFailures | RankEvalFailures | IngestionShardFailures | + PitNodeFailures + +// Token names accepted by [Parse] and emitted by [ErrorMask.String]. +// +//nolint:gosec // G101 false positive: these are wire-format error category tokens, not credentials +const ( + TokenBulkItems = "bulk_items" + TokenSearchShards = "search_shards" + TokenWriteShards = "write_shards" + TokenBroadcastShards = "broadcast_shards" + TokenNodeFailures = "node_failures" + TokenBulkByScrollFailures = "bulk_by_scroll_failures" + TokenTaskFailures = "task_failures" + TokenMultiSearchItems = "multi_search_items" + TokenMultiDocItems = "multi_doc_items" + TokenSnapshotCreateShardFailures = "snapshot_create_shard_failures" + TokenSnapshotGetShardFailures = "snapshot_get_shard_failures" + TokenSimulateDocFailures = "simulate_doc_failures" + TokenRankEvalFailures = "rank_eval_failures" + TokenIngestionShardFailures = "ingestion_shard_failures" + TokenPitNodeFailures = "pit_node_failures" + + // TokenAll selects every wrapper bit at once. + TokenAll = "all" + + // TokenEmpty is the canonical "mask nothing" token. TokenNone and + // TokenUnknown are accepted as aliases on input; [String] always + // emits TokenEmpty for a zero mask. + TokenEmpty = "empty" + TokenNone = "none" + TokenUnknown = "unknown" +) + +// Token prefixes used by [Parse]. A bare token (no prefix) is treated +// as PrefixSet. +const ( + PrefixSet = '+' + PrefixClear = '-' +) + +// Has reports whether every bit in mask is set on m. At API call sites +// the natural form is `if !m.Has(errmask.BulkItems) { ... }` -- negate +// to mean "this category is reported (not masked)". +func (m ErrorMask) Has(mask ErrorMask) bool { + return m&mask == mask +} + +// String returns a canonical comma-separated token list (snake_case, +// sorted by bit position) of the masked categories. The zero value +// renders as [TokenEmpty]. Useful for logging and the round-trip Parse +// contract. +func (m ErrorMask) String() string { + if m == Empty { + return TokenEmpty + } + var parts []string + for _, e := range tokenOrder { + if m.Has(e.bit) { + parts = append(parts, e.token) + } + } + return strings.Join(parts, ",") +} + +// Parse applies a comma-separated token list to base and returns the +// resulting mask plus a slice of any unknown tokens that were ignored. +// Each token is one of: +// +// shorthand for + +// + set the bit (mask the category) +// - clear the bit (unmask the category) +// +// Recognized names are the snake_case tokens above plus the special +// "all" token (set every wrapper bit) and the "empty"/"none"/"unknown" +// aliases (clear every bit). Tokens are applied left-to-right, so +// callers can express composite changes such as "+all,-bulk_items". +// +// Parse is liberal: unknown tokens are skipped (forward-compatible) and +// returned in the second slice so callers can debug-log them. An empty +// input returns base unchanged with a nil unknown slice. +func Parse(s string, base ErrorMask) (ErrorMask, []string) { + out := base + if s == "" { + return out, nil + } + var unknown []string + for raw := range strings.SplitSeq(s, ",") { + tok := strings.TrimSpace(raw) + if tok == "" { + continue + } + set := true + switch tok[0] { + case PrefixSet: + tok = tok[1:] + case PrefixClear: + set = false + tok = tok[1:] + } + bit, isReset, ok := nameToBit(tok) + if !ok { + unknown = append(unknown, raw) + continue + } + switch { + case isReset: + // "empty" / "none" / "unknown" reset to the zero value + // regardless of +/- prefix. + out = Empty + case set: + out |= bit + default: + out &^= bit + } + } + return out, unknown +} + +// tokenEntry pairs a bit with its canonical snake_case token. The order +// of this slice defines the deterministic String() output. +type tokenEntry struct { + bit ErrorMask + token string +} + +//nolint:gochecknoglobals // canonical bit-order lookup table shared by String and nameToBit +var tokenOrder = []tokenEntry{ + {BulkItems, TokenBulkItems}, + {SearchShards, TokenSearchShards}, + {WriteShards, TokenWriteShards}, + {BroadcastShards, TokenBroadcastShards}, + {NodeFailures, TokenNodeFailures}, + {BulkByScrollFailures, TokenBulkByScrollFailures}, + {TaskFailures, TokenTaskFailures}, + {MultiSearchItems, TokenMultiSearchItems}, + {MultiDocItems, TokenMultiDocItems}, + {SnapshotCreateShardFailures, TokenSnapshotCreateShardFailures}, + {SnapshotGetShardFailures, TokenSnapshotGetShardFailures}, + {SimulateDocFailures, TokenSimulateDocFailures}, + {RankEvalFailures, TokenRankEvalFailures}, + {IngestionShardFailures, TokenIngestionShardFailures}, + {PitNodeFailures, TokenPitNodeFailures}, +} + +// nameToBit maps a snake_case token to its bit pattern. The second +// return is true for the empty/none/unknown aliases, which always +// reset the mask to zero regardless of +/- prefix. Tokens are matched +// exactly as written -- the canonical lowercase snake_case form is +// the only accepted spelling. +func nameToBit(name string) (ErrorMask, bool, bool) { + switch name { + case TokenAll: + return All, false, true + case TokenEmpty, TokenNone, TokenUnknown: + return 0, true, true + } + for _, e := range tokenOrder { + if name == e.token { + return e.bit, false, true + } + } + return 0, false, false +} diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/error.go b/vendor/github.com/opensearch-project/opensearch-go/v4/error.go index 6259884596..2935ea5bde 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/error.go +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/error.go @@ -7,6 +7,7 @@ package opensearch import ( + "bytes" "encoding/json" "errors" "fmt" @@ -145,10 +146,19 @@ func ParseError(resp *Response) error { } body, err := io.ReadAll(resp.Body) + resp.Body.Close() if err != nil { + // Restore Body so callers don't see a closed reader. The partial + // bytes are intentionally dropped because the underlying read + // already failed; what matters is keeping the Body field + // consistent with the success branch below (an in-memory + // NopCloser the caller can safely Read or Close). + resp.Body = io.NopCloser(bytes.NewReader(body)) return fmt.Errorf("%w: %w", ErrReadBody, err) } + resp.Body = io.NopCloser(bytes.NewReader(body)) + var testResp struct { Status any `json:"status"` Error any `json:"error"` @@ -156,7 +166,7 @@ func ParseError(resp *Response) error { Reason any `json:"reason"` } if err = json.Unmarshal(body, &testResp); err != nil { - return fmt.Errorf("%w: %w", ErrJSONUnmarshalBody, err) + return fmt.Errorf("%w, status: %d, body: %q", ErrJSONUnmarshalBody, resp.StatusCode, string(body)) } // Check for errors where status is a number diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/internal/build/request.go b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/build/request.go new file mode 100644 index 0000000000..2d7feae6e4 --- /dev/null +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/build/request.go @@ -0,0 +1,204 @@ +// SPDX-License-Identifier: Apache-2.0 +// +// The OpenSearch Contributors require contributions made to +// this file be licensed under the Apache-2.0 license or a +// compatible open source license. + +// Package build constructs [http.Request] values for the OpenSearch client +// without the overhead of [http.NewRequest] (which calls [url.Parse] on every +// invocation). All paths produced by the typed path builders are simple +// relative paths with no scheme, host, query, or fragment, so parsing is +// unnecessary. The transport layer prepends the base URL before sending. +package build + +import ( + "bytes" + "errors" + "fmt" + "io" + "net/http" + "net/url" + "strings" +) + +const ( + // HeaderContentType is the canonical HTTP Content-Type header name. + HeaderContentType = "Content-Type" + + // ContentTypeJSON is the default body Content-Type for OpenSearch + // requests. + ContentTypeJSON = "application/json" + + // ContentTypeNDJSON is the body Content-Type for newline-delimited + // JSON request bodies (e.g. _bulk, _msearch, _msearch/template). + ContentTypeNDJSON = "application/x-ndjson" +) + +// headerContentType retains the lowercase name for internal lookups +// where the existing call sites (and the http.Header map's canonical +// form) use the unexported identifier. +const headerContentType = HeaderContentType + +var headerContentTypeJSON = []string{ContentTypeJSON} + +// NullJSON is the JSON `null` literal as a byte slice. Generated MarshalJSON +// implementations return it for the empty/zero case. +var NullJSON = []byte("null") + +// errMissingMethod is returned when an empty HTTP method is passed to Request. +var errMissingMethod = errors.New("HTTP method must be specified") + +var ( + errInvalidMethod = errors.New("net/http: invalid method") + errInvalidPath = errors.New("invalid percent-encoding in path") +) + +// requestBuf coalesces http.Request and url.URL into a single heap allocation. +// Taking the address of buf.req causes the entire struct to escape, but only +// as one object rather than two separate allocations for Request and URL. +type requestBuf struct { + req http.Request + url url.URL +} + +// Request constructs an [http.Request] from a method, path, body, query +// parameters, and headers. The path must be a relative URL path (no scheme or +// host); the transport layer prepends the base URL before sending. +// +// When body != nil, Content-Type defaults to "application/json"; callers that +// need a different body type (e.g. "application/x-ndjson" for _bulk) must +// supply Content-Type in headers and the caller's value wins. +// +// Header is intentionally left nil when body is nil and no custom headers are +// passed. The transport layer ([opensearch.Client.Perform]) lazily allocates +// the Header map before setting User-Agent and other transport headers. This +// keeps the fast path (GET with no body) down to 2 heap allocations: the +// coalesced requestBuf and the path string from the path builder. +func Request(method string, path string, body io.Reader, params map[string]string, headers http.Header) (*http.Request, error) { + if method == "" { + return nil, errMissingMethod + } + + if !validMethod(method) { + return nil, errInvalidMethod + } + + var buf requestBuf + // Setting both RawPath and Path ensures url.URL.EscapedPath() honors + // the percent-encoded form produced by the path builders (e.g. %2F for + // a literal slash inside a document ID). Without RawPath, EscapedPath + // re-encodes Path from scratch and leaves '/' and '..' untouched, + // enabling path traversal and segment injection. + // + // A PathUnescape failure means the path contains an invalid percent + // sequence (e.g. "%ZZ"). Falling through and assigning the raw bytes + // to Path would cause EscapedPath() to silently re-encode the literal + // '%' as "%25", corrupting the wire form. Reject the request. + buf.url.RawPath = path + p, err := url.PathUnescape(path) + if err != nil { + return nil, fmt.Errorf("%w: %s", errInvalidPath, err.Error()) + } + buf.url.Path = p + buf.req.Method = method + buf.req.URL = &buf.url + buf.req.Proto = "HTTP/1.1" + buf.req.ProtoMajor = 1 + buf.req.ProtoMinor = 1 + + if body != nil { + rc, ok := body.(io.ReadCloser) + if !ok { + rc = io.NopCloser(body) + } + buf.req.Body = rc + + // Snapshot known reader types so GetBody can replay the body for + // retries. Mirrors the behavior of http.NewRequest. + switch v := body.(type) { + case *bytes.Buffer: + buf.req.ContentLength = int64(v.Len()) + b := v.Bytes() + buf.req.GetBody = func() (io.ReadCloser, error) { + return io.NopCloser(bytes.NewReader(b)), nil + } + case *bytes.Reader: + buf.req.ContentLength = int64(v.Len()) + snapshot := *v + buf.req.GetBody = func() (io.ReadCloser, error) { + r := snapshot + return io.NopCloser(&r), nil + } + case *strings.Reader: + buf.req.ContentLength = int64(v.Len()) + snapshot := *v + buf.req.GetBody = func() (io.ReadCloser, error) { + r := snapshot + return io.NopCloser(&r), nil + } + } + + buf.req.Header = make(http.Header, len(headers)+1) + // Seed default Content-Type only when the caller did not supply + // one; otherwise the caller's value wins (e.g. application/x-ndjson + // for _bulk and _msearch). + if _, ok := headers[headerContentType]; !ok { + buf.req.Header[headerContentType] = headerContentTypeJSON + } + } else if len(headers) > 0 { + buf.req.Header = make(http.Header, len(headers)) + } + + for k, vv := range headers { + for _, v := range vv { + buf.req.Header.Add(k, v) + } + } + + if len(params) > 0 { + q := buf.url.Query() + for k, v := range params { + q.Set(k, v) + } + buf.url.RawQuery = q.Encode() + } + + return &buf.req, nil +} + +// isTokenChar reports whether c is a valid HTTP token character per +// RFC 7230 section 3.2.6. The set is the same as net/http's internal +// isTokenTable. +func isTokenChar(c byte) bool { + switch { + case c >= 'a' && c <= 'z': + return true + case c >= 'A' && c <= 'Z': + return true + case c >= '0' && c <= '9': + return true + } + switch c { + case '!', '#', '$', '%', '&', '\'', '*', '+', '-', '.', '^', '_', '`', '|', '~': + return true + } + return false +} + +// validMethod reports whether method is a syntactically valid HTTP +// method per RFC 7230. Empty methods are rejected by the caller; this +// function rejects any non-token byte (control chars, spaces, lowercase +// letters within ASCII range are still tokens, but methods like "get" +// or "GET,POST" or "PROP[]FIND" use non-token punctuation and are +// rejected here). +func validMethod(method string) bool { + if method == "" { + return false + } + for i := range method { + if !isTokenChar(method[i]) { + return false + } + } + return true +} diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/internal/build/union.go b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/build/union.go new file mode 100644 index 0000000000..0fe397ab7b --- /dev/null +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/build/union.go @@ -0,0 +1,68 @@ +// SPDX-License-Identifier: Apache-2.0 +// +// The OpenSearch Contributors require contributions made to +// this file be licensed under the Apache-2.0 license or a +// compatible open source license. + +package build + +import ( + "encoding/json" + "sync" +) + +// maxPooledKeySetSize bounds the maps [HasJSONKeys] returns to keySetPool. +// A pathological sub-response with thousands of distinct top-level keys would +// grow the probe map to match; returning that map to the pool would pin its +// backing storage for the process lifetime. Maps that exceed this many keys +// are dropped (left for GC) instead of recycled, so the pool's steady-state +// footprint stays bounded while still covering the common small-object case. +const maxPooledKeySetSize = 32 + +// keySetPool recycles the maps used by [HasJSONKeys] so the discriminator +// probe does not allocate a fresh map on every union sub-response decode. +// The value type is json.RawMessage so the probe accepts objects whose +// fields hold any JSON value -- a map[string]struct{} would reject scalar +// values, since a number, string, or bool cannot decode into struct{}. +var keySetPool = sync.Pool{ + New: func() any { return make(map[string]json.RawMessage, 16) }, +} + +// HasJSONKeys reports whether data is a JSON object containing every key in +// keys. Generated discriminated-union UnmarshalJSON methods call it to gate a +// branch on the presence of its required (discriminator) fields before +// decoding into it: encoding/json does not enforce a schema's "required" set, +// so a structurally permissive branch would otherwise absorb JSON that belongs +// to a more specific branch (e.g. an error sub-response decoding into the +// success branch). Non-object JSON (arrays, primitives, null) yields false. +// +// The probe decodes into a pooled map[string]json.RawMessage so only the +// top-level key set is needed; values are captured as raw byte slices and +// discarded. +func HasJSONKeys(data []byte, keys ...string) bool { + if len(keys) == 0 { + return true + } + + fields, _ := keySetPool.Get().(map[string]json.RawMessage) + defer func() { + // Drop maps that ballooned past the cap: returning them would pin + // oversized backing storage in the pool. len is read before clear, + // which resets it to 0. + if len(fields) > maxPooledKeySetSize { + return + } + clear(fields) + keySetPool.Put(fields) + }() + + if err := json.Unmarshal(data, &fields); err != nil { + return false + } + for _, k := range keys { + if _, ok := fields[k]; !ok { + return false + } + } + return true +} diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/internal/envvars/envvars.go b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/envvars/envvars.go new file mode 100644 index 0000000000..ed9cf7a162 --- /dev/null +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/envvars/envvars.go @@ -0,0 +1,173 @@ +// SPDX-License-Identifier: Apache-2.0 +// +// The OpenSearch Contributors require contributions made to +// this file be licensed under the Apache-2.0 license or a +// compatible open source license. + +// Package envvars holds the canonical names of OPENSEARCH_GO_* environment +// variables consumed by both the opensearch and opensearchtransport packages. +// Centralizing the names here avoids two-way duplication across the import +// boundary (opensearch depends on opensearchtransport, but the transport +// must not import opensearch). +package envvars + +import ( + "errors" + "fmt" + "os" + "strconv" + "time" +) + +// OpenSearchURL is the comma-separated seed-URL list used by [opensearch.NewClient] +// when no Addresses are configured programmatically. +const OpenSearchURL = "OPENSEARCH_URL" + +// Router controls whether the DefaultRouter is created automatically when +// no programmatic Config.Router is set, and whether opensearch.NewClient +// inherits on-start node discovery. Parsed as strconv.ParseBool. +const Router = "OPENSEARCH_GO_ROUTER" + +// ShardCost configures shard cost multipliers for connection scoring. +// See [opensearchtransport.WithShardCosts] for the format. +const ShardCost = "OPENSEARCH_GO_SHARD_COST" + +// RoutingConfig is a comma-separated bitfield/key-value spec controlling +// request-time routing features (e.g. -shard_exact, -adaptive_mcsr). +const RoutingConfig = "OPENSEARCH_GO_ROUTING_CONFIG" + +// DiscoveryConfig is a comma-separated bitfield spec controlling which +// discovery API calls run (e.g. -cat_shards, -node_stats). +const DiscoveryConfig = "OPENSEARCH_GO_DISCOVERY_CONFIG" + +// Fallback toggles seed-URL fallback when all router pools are exhausted. +const Fallback = "OPENSEARCH_GO_FALLBACK" + +// ShardRequests configures adaptive max_concurrent_shard_requests bounds. +// Format: "true"/"false" or "min:max" (e.g. "10:512"). +const ShardRequests = "OPENSEARCH_GO_SHARD_REQUESTS" + +// RequestTimeout overrides the per-attempt HTTP round-trip timeout. +const RequestTimeout = "OPENSEARCH_GO_REQUEST_TIMEOUT" + +// NodeStatsInterval overrides the node stats polling interval. +const NodeStatsInterval = "OPENSEARCH_GO_NODE_STATS_INTERVAL" + +// OverloadedHeapThreshold overrides the JVM heap percentage threshold for +// marking a node overloaded. +const OverloadedHeapThreshold = "OPENSEARCH_GO_OVERLOADED_HEAP_THRESHOLD" + +// OverloadedBreakerRatio overrides the circuit-breaker ratio threshold for +// marking a node overloaded. +const OverloadedBreakerRatio = "OPENSEARCH_GO_OVERLOADED_BREAKER_RATIO" + +// ActiveListCap overrides the per-pool active-connection cap. +const ActiveListCap = "OPENSEARCH_GO_ACTIVE_LIST_CAP" + +// VerifyDeadAfter is the duration a dead connection can be blindly resurrected +// for use as a zombie connection when no other healthy connections are +// available. Past this window the discovery loop stops treating the node as a +// zombie candidate until it health-checks clean again. Parsed by +// [ParseVerifyDeadAfter]: a boolean true selects [VerifyDeadAfterDefault]; +// false disables the expiry (a proven connection stays a zombie candidate +// indefinitely); any other value is a time.ParseDuration string (e.g. "10m"). +const VerifyDeadAfter = "OPENSEARCH_GO_VERIFY_DEAD_AFTER" + +// VerifyDeadAfterDefault is the zombie-resurrection window used when +// VerifyDeadAfter is unset or set to a truthy boolean. 15m matches the AWS +// Lambda max timeout, so a proven connection is not force-expired mid-invocation. +const VerifyDeadAfterDefault = 15 * time.Minute + +// StandbyRotationInterval overrides the interval between standby rotation cycles. +const StandbyRotationInterval = "OPENSEARCH_GO_STANDBY_ROTATION_INTERVAL" + +// StandbyRotationCount overrides the number of standby rotations performed +// per cycle. +const StandbyRotationCount = "OPENSEARCH_GO_STANDBY_ROTATION_COUNT" + +// StandbyPromotionChecks overrides the number of consecutive successful +// health checks required to promote a standby connection to active. +const StandbyPromotionChecks = "OPENSEARCH_GO_STANDBY_PROMOTION_CHECKS" + +// Debug enables verbose internal logging via [strconv.ParseBool]. +const Debug = "OPENSEARCH_GO_DEBUG" + +// ErrorMask is a comma-separated bitfield spec controlling which categories +// of partial-failure errors API methods mask (ignore) instead of returning +// as typed Go errors. Tokens are the lowercase snake_case wrapper-schema +// names (`bulk_items`, `search_shards`, `write_shards`, `broadcast_shards`, +// `node_failures`, `bulk_by_scroll_failures`, `task_failures`, +// `multi_search_items`, `multi_doc_items`, `snapshot_create_shard_failures`, +// `snapshot_get_shard_failures`, `simulate_doc_failures`, +// `rank_eval_failures`, `ingestion_shard_failures`, `pit_node_failures`) +// plus `all` and `none`/`empty`/`unknown` (aliases for zero). Each token +// may be prefixed with `+` (set/mask) or `-` (clear/unmask); bare tokens +// are treated as `+`. Tokens are applied left-to-right starting from the +// programmatic Config.Errors value. Unrecognized tokens are silently +// dropped (forward-compatible) and reported via the debug logger when +// OPENSEARCH_GO_DEBUG=true. +const ErrorMask = "OPENSEARCH_GO_ERROR_MASK" + +// Truthy reports whether the named environment variable is set to a +// strconv.ParseBool-truthy value. Empty, unset, unparseable, or falsy +// values all return false. +func Truthy(name string) bool { + val, ok := os.LookupEnv(name) + if !ok || val == "" { + return false + } + b, err := strconv.ParseBool(val) + return err == nil && b +} + +// Falsy reports whether the named environment variable is set to a +// strconv.ParseBool-falsy value. Empty, unset, unparseable, or truthy +// values all return false. Use this when "explicitly opted out" needs +// to be distinguished from "unset" (where Truthy alone collapses both +// into false). +func Falsy(name string) bool { + val, ok := os.LookupEnv(name) + if !ok || val == "" { + return false + } + b, err := strconv.ParseBool(val) + return err == nil && !b +} + +// ErrInvalidVerifyDeadAfter is returned by ParseVerifyDeadAfter (wrapped, match +// with errors.Is) when the value is neither a boolean nor a parseable duration. +var ErrInvalidVerifyDeadAfter = errors.New("envvars: invalid verify-dead-after value") + +// ParseVerifyDeadAfter interprets a VerifyDeadAfter value. A boolean (per +// strconv.ParseBool) is handled first: true selects VerifyDeadAfterDefault, +// false disables the expiry. Otherwise the value is parsed as a duration by +// time.ParseDuration ("10m", "90s") or as a bare number of seconds ("600"). +// A zero or negative result disables the expiry. The returned duration is the +// resolved window, or 0 when disabled. The error is non-nil (wrapping +// ErrInvalidVerifyDeadAfter) only when the value cannot be parsed at all; an +// empty value is treated as "disabled" with a nil error. +func ParseVerifyDeadAfter(val string) (time.Duration, error) { + if val == "" { + return 0, nil + } + if b, err := strconv.ParseBool(val); err == nil { + if b { + return VerifyDeadAfterDefault, nil + } + return 0, nil + } + if d, err := time.ParseDuration(val); err == nil { + if d <= 0 { + return 0, nil + } + return d, nil + } + if secs, err := strconv.ParseFloat(val, 64); err == nil { + d := time.Duration(secs * float64(time.Second)) + if d <= 0 { + return 0, nil + } + return d, nil + } + return 0, fmt.Errorf("%w: %q", ErrInvalidVerifyDeadAfter, val) +} diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/builders_gen.go b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/builders_gen.go new file mode 100644 index 0000000000..05aa4e2954 --- /dev/null +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/builders_gen.go @@ -0,0 +1,12675 @@ +// SPDX-License-Identifier: Apache-2.0 +// +// The OpenSearch Contributors require contributions made to +// this file be licensed under the Apache-2.0 license or a +// compatible open source license. + +// Code generated by cmd/osgen; DO NOT EDIT. + +package path + +import ( + "errors" + "fmt" + "net/url" + "strings" + "sync" +) + +var errRequired = errors.New("required path segment is empty") + +// listSep is the separator OpenSearch uses to join multi-value path +// segments (e.g. index lists rendered as "/a,b,c"). +const listSep = "," + +type buf struct { + b []byte +} + +//nolint:gochecknoglobals // sync.Pool must be package-level +var bufPool = sync.Pool{ + New: func() any { return &buf{b: make([]byte, 0, 256)} }, +} + +const maxPooledBuf = 4096 + +func acquire() *buf { + pb := bufPool.Get().(*buf) + pb.b = pb.b[:0] + return pb +} + +func (pb *buf) release() string { + s := string(pb.b) + if cap(pb.b) <= maxPooledBuf { + bufPool.Put(pb) + } + return s +} + +// encSeg percent-encodes a user-supplied path segment value so that +// metacharacters (/, .., ?, #, etc.) cannot alter the URL structure. +// url.PathEscape leaves '/' alone (path-safe per RFC 3986 sec 3.3), +// so we encode it separately to prevent segment injection. +func encSeg(v string) string { + s := url.PathEscape(v) + if strings.IndexByte(s, '/') < 0 { + return s + } + return strings.ReplaceAll(s, "/", "%2F") +} + +// writeLit appends a spec-defined literal path segment. These are +// constant strings from the OpenAPI specification (e.g. "_doc", +// "_search") and are never user-controlled at runtime. +func (pb *buf) writeLit(v string) { pb.b = append(pb.b, '/'); pb.b = append(pb.b, v...) } + +// writeReq appends a user-supplied path segment, percent-encoding +// characters that would otherwise alter URL routing. +func (pb *buf) writeReq(v string) { pb.b = append(pb.b, '/'); pb.b = append(pb.b, encSeg(v)...) } + +// writeSegments appends a comma-separated list of percent-encoded path +// segments (e.g. multi-index targets). Empty strings are silently skipped +// to prevent double-slash paths that corrupt URL authority parsing. +func writeSegments(pb *buf, segments []string) { + first := true + for _, seg := range segments { + if seg == "" { + continue + } + if first { + pb.b = append(pb.b, '/') + first = false + } else { + pb.b = append(pb.b, listSep...) + } + pb.b = append(pb.b, encSeg(seg)...) + } +} + +// hasNonEmpty reports whether ss contains at least one non-empty string. +// Used by required-field validation to reject slices like []string{""} +// that pass a len() > 0 check but carry no meaningful content. +func hasNonEmpty(ss []string) bool { + for _, s := range ss { + if s != "" { + return true + } + } + return false +} + +// builder is implemented by every generated path type. It exists so the +// compiler enforces a uniform Build() (string, error) signature: any new +// path type whose method drifts (renamed, return type changed, etc.) fails +// the compile-time assertions below instead of escaping to runtime. +// Unexported because the assertions are intra-package; no external caller +// needs to write path.Builder. +type builder interface { + Build() (string, error) +} + +var ( + _ builder = AsynchronousSearchDeletePath{} + _ builder = AsynchronousSearchGetPath{} + _ builder = AsynchronousSearchSearchPath{} + _ builder = AsynchronousSearchStatsPath{} + _ builder = BulkPath{} + _ builder = BulkStreamPath{} + _ builder = CatAliasesPath{} + _ builder = CatAllPITSegmentsPath{} + _ builder = CatAllocationPath{} + _ builder = CatClusterManagerPath{} + _ builder = CatCountPath{} + _ builder = CatFielddataPath{} + _ builder = CatHealthPath{} + _ builder = CatHelpPath{} + _ builder = CatIndicesPath{} + _ builder = CatMasterPath{} + _ builder = CatNodeattrsPath{} + _ builder = CatNodesPath{} + _ builder = CatPendingTasksPath{} + _ builder = CatPITSegmentsPath{} + _ builder = CatPluginsPath{} + _ builder = CatRecoveryPath{} + _ builder = CatRepositoriesPath{} + _ builder = CatSegmentReplicationPath{} + _ builder = CatSegmentsPath{} + _ builder = CatShardsPath{} + _ builder = CatSnapshotsPath{} + _ builder = CatTasksPath{} + _ builder = CatTemplatesPath{} + _ builder = CatThreadPoolPath{} + _ builder = ClearScrollPath{} + _ builder = ClusterAllocationExplainPath{} + _ builder = ClusterDeleteComponentTemplatePath{} + _ builder = ClusterDeleteDecommissionAwarenessPath{} + _ builder = ClusterDeleteVotingConfigExclusionsPath{} + _ builder = ClusterDeleteWeightedRoutingPath{} + _ builder = ClusterExistsComponentTemplatePath{} + _ builder = ClusterGetComponentTemplatePath{} + _ builder = ClusterGetDecommissionAwarenessPath{} + _ builder = ClusterGetSettingsPath{} + _ builder = ClusterGetWeightedRoutingPath{} + _ builder = ClusterHealthPath{} + _ builder = ClusterPendingTasksPath{} + _ builder = ClusterPostVotingConfigExclusionsPath{} + _ builder = ClusterPutComponentTemplatePath{} + _ builder = ClusterPutDecommissionAwarenessPath{} + _ builder = ClusterPutSettingsPath{} + _ builder = ClusterPutWeightedRoutingPath{} + _ builder = ClusterRemoteInfoPath{} + _ builder = ClusterReroutePath{} + _ builder = ClusterStatePath{} + _ builder = ClusterStatsPath{} + _ builder = CountPath{} + _ builder = CreatePath{} + _ builder = CreatePITPath{} + _ builder = DanglingIndicesDeleteDanglingIndexPath{} + _ builder = DanglingIndicesImportDanglingIndexPath{} + _ builder = DanglingIndicesListDanglingIndicesPath{} + _ builder = DeletePath{} + _ builder = DeleteAllPitsPath{} + _ builder = DeleteByQueryPath{} + _ builder = DeleteByQueryRethrottlePath{} + _ builder = DeletePITPath{} + _ builder = DeleteScriptPath{} + _ builder = ExistsPath{} + _ builder = ExistsSourcePath{} + _ builder = ExplainPath{} + _ builder = FieldCapsPath{} + _ builder = FlowFrameworkCreatePath{} + _ builder = FlowFrameworkDeletePath{} + _ builder = FlowFrameworkDeprovisionPath{} + _ builder = FlowFrameworkGetPath{} + _ builder = FlowFrameworkGetStatusPath{} + _ builder = FlowFrameworkGetStepsPath{} + _ builder = FlowFrameworkProvisionPath{} + _ builder = FlowFrameworkSearchPath{} + _ builder = FlowFrameworkSearchStatePath{} + _ builder = FlowFrameworkUpdatePath{} + _ builder = GeospatialDeleteIp2geoDatasourcePath{} + _ builder = GeospatialGeojsonUploadPostPath{} + _ builder = GeospatialGeojsonUploadPutPath{} + _ builder = GeospatialGetIp2geoDatasourcePath{} + _ builder = GeospatialGetUploadStatsPath{} + _ builder = GeospatialPutIp2geoDatasourcePath{} + _ builder = GeospatialPutIp2geoDatasourceSettingsPath{} + _ builder = GetPath{} + _ builder = GetAllPitsPath{} + _ builder = GetScriptPath{} + _ builder = GetScriptContextPath{} + _ builder = GetScriptLanguagesPath{} + _ builder = GetSourcePath{} + _ builder = IndexPath{} + _ builder = IndicesAddBlockPath{} + _ builder = IndicesAnalyzePath{} + _ builder = IndicesClearCachePath{} + _ builder = IndicesClonePath{} + _ builder = IndicesClosePath{} + _ builder = IndicesCreatePath{} + _ builder = IndicesCreateDataStreamPath{} + _ builder = IndicesDataStreamsStatsPath{} + _ builder = IndicesDeletePath{} + _ builder = IndicesDeleteAliasPath{} + _ builder = IndicesDeleteDataStreamPath{} + _ builder = IndicesDeleteIndexTemplatePath{} + _ builder = IndicesDeleteTemplatePath{} + _ builder = IndicesExistsPath{} + _ builder = IndicesExistsAliasPath{} + _ builder = IndicesExistsIndexTemplatePath{} + _ builder = IndicesExistsTemplatePath{} + _ builder = IndicesFlushPath{} + _ builder = IndicesForcemergePath{} + _ builder = IndicesGetPath{} + _ builder = IndicesGetAliasPath{} + _ builder = IndicesGetDataStreamPath{} + _ builder = IndicesGetFieldMappingPath{} + _ builder = IndicesGetIndexTemplatePath{} + _ builder = IndicesGetMappingPath{} + _ builder = IndicesGetSettingsPath{} + _ builder = IndicesGetTemplatePath{} + _ builder = IndicesGetUpgradePath{} + _ builder = IndicesOpenPath{} + _ builder = IndicesPutAliasPath{} + _ builder = IndicesPutIndexTemplatePath{} + _ builder = IndicesPutMappingPath{} + _ builder = IndicesPutSettingsPath{} + _ builder = IndicesPutTemplatePath{} + _ builder = IndicesRecoveryPath{} + _ builder = IndicesRefreshPath{} + _ builder = IndicesResolveIndexPath{} + _ builder = IndicesRolloverPath{} + _ builder = IndicesSegmentsPath{} + _ builder = IndicesShardStoresPath{} + _ builder = IndicesShrinkPath{} + _ builder = IndicesSimulateIndexTemplatePath{} + _ builder = IndicesSimulateTemplatePath{} + _ builder = IndicesSplitPath{} + _ builder = IndicesStatsPath{} + _ builder = IndicesUpdateAliasesPath{} + _ builder = IndicesUpgradePath{} + _ builder = IndicesValidateQueryPath{} + _ builder = InfoPath{} + _ builder = IngestDeletePipelinePath{} + _ builder = IngestGetPipelinePath{} + _ builder = IngestProcessorGrokPath{} + _ builder = IngestPutPipelinePath{} + _ builder = IngestSimulatePath{} + _ builder = IngestionGetStatePath{} + _ builder = IngestionPausePath{} + _ builder = IngestionResumePath{} + _ builder = InsightsTopQueriesPath{} + _ builder = IsmAddPolicyPath{} + _ builder = IsmChangePolicyPath{} + _ builder = IsmDeletePolicyPath{} + _ builder = IsmExistsPolicyPath{} + _ builder = IsmExplainPolicyPath{} + _ builder = IsmGetPoliciesPath{} + _ builder = IsmGetPolicyPath{} + _ builder = IsmPutPoliciesPath{} + _ builder = IsmPutPolicyPath{} + _ builder = IsmRefreshSearchAnalyzersPath{} + _ builder = IsmRemovePolicyPath{} + _ builder = IsmRetryIndexPath{} + _ builder = KnnDeleteModelPath{} + _ builder = KnnGetModelPath{} + _ builder = KnnSearchModelsPath{} + _ builder = KnnStatsPath{} + _ builder = KnnTrainModelPath{} + _ builder = KnnWarmupPath{} + _ builder = ListHelpPath{} + _ builder = ListIndicesPath{} + _ builder = ListShardsPath{} + _ builder = LtrAddFeaturesToSetPath{} + _ builder = LtrAddFeaturesToSetByQueryPath{} + _ builder = LtrCacheStatsPath{} + _ builder = LtrClearCachePath{} + _ builder = LtrCreateDefaultStorePath{} + _ builder = LtrCreateFeaturePath{} + _ builder = LtrCreateFeaturesetPath{} + _ builder = LtrCreateModelPath{} + _ builder = LtrCreateModelFromSetPath{} + _ builder = LtrCreateStorePath{} + _ builder = LtrDeleteDefaultStorePath{} + _ builder = LtrDeleteFeaturePath{} + _ builder = LtrDeleteFeaturesetPath{} + _ builder = LtrDeleteModelPath{} + _ builder = LtrDeleteStorePath{} + _ builder = LtrGetFeaturePath{} + _ builder = LtrGetFeaturesetPath{} + _ builder = LtrGetModelPath{} + _ builder = LtrGetStorePath{} + _ builder = LtrListStoresPath{} + _ builder = LtrSearchFeaturesPath{} + _ builder = LtrSearchFeaturesetsPath{} + _ builder = LtrSearchModelsPath{} + _ builder = LtrStatsPath{} + _ builder = LtrUpdateFeaturePath{} + _ builder = LtrUpdateFeaturesetPath{} + _ builder = MgetPath{} + _ builder = MlAddAgenticMemoryPath{} + _ builder = MlChunkModelPath{} + _ builder = MlCreateConnectorPath{} + _ builder = MlCreateControllerPath{} + _ builder = MlCreateMemoryPath{} + _ builder = MlCreateMemoryContainerPath{} + _ builder = MlCreateMemoryContainerSessionPath{} + _ builder = MlCreateMessagePath{} + _ builder = MlCreateModelMetaPath{} + _ builder = MlDeleteAgentPath{} + _ builder = MlDeleteAgenticMemoryPath{} + _ builder = MlDeleteAgenticMemoryQueryPath{} + _ builder = MlDeleteConnectorPath{} + _ builder = MlDeleteControllerPath{} + _ builder = MlDeleteMemoryPath{} + _ builder = MlDeleteMemoryContainerPath{} + _ builder = MlDeleteModelPath{} + _ builder = MlDeleteModelGroupPath{} + _ builder = MlDeleteTaskPath{} + _ builder = MlDeployModelPath{} + _ builder = MlExecuteAgentPath{} + _ builder = MlExecuteAgentStreamPath{} + _ builder = MlExecuteAlgorithmPath{} + _ builder = MlExecuteToolPath{} + _ builder = MlGetAgentPath{} + _ builder = MlGetAgenticMemoryPath{} + _ builder = MlGetAllMemoriesPath{} + _ builder = MlGetAllMessagesPath{} + _ builder = MlGetAllToolsPath{} + _ builder = MlGetConnectorPath{} + _ builder = MlGetControllerPath{} + _ builder = MlGetMemoryPath{} + _ builder = MlGetMemoryContainerPath{} + _ builder = MlGetMessagePath{} + _ builder = MlGetMessageTracesPath{} + _ builder = MlGetModelPath{} + _ builder = MlGetModelGroupPath{} + _ builder = MlGetProfilePath{} + _ builder = MlGetProfileModelsPath{} + _ builder = MlGetProfileTasksPath{} + _ builder = MlGetStatsPath{} + _ builder = MlGetTaskPath{} + _ builder = MlGetToolPath{} + _ builder = MlLoadModelPath{} + _ builder = MlPredictPath{} + _ builder = MlPredictModelPath{} + _ builder = MlPredictModelStreamPath{} + _ builder = MlRegisterAgentsPath{} + _ builder = MlRegisterModelPath{} + _ builder = MlRegisterModelGroupPath{} + _ builder = MlRegisterModelMetaPath{} + _ builder = MlSearchAgenticMemoryPath{} + _ builder = MlSearchAgentsPath{} + _ builder = MlSearchConnectorsPath{} + _ builder = MlSearchMemoryPath{} + _ builder = MlSearchMemoryContainerPath{} + _ builder = MlSearchMessagePath{} + _ builder = MlSearchModelGroupPath{} + _ builder = MlSearchModelsPath{} + _ builder = MlSearchTasksPath{} + _ builder = MlTrainPath{} + _ builder = MlTrainPredictPath{} + _ builder = MlUndeployModelPath{} + _ builder = MlUnloadModelPath{} + _ builder = MlUpdateAgenticMemoryPath{} + _ builder = MlUpdateConnectorPath{} + _ builder = MlUpdateControllerPath{} + _ builder = MlUpdateMemoryPath{} + _ builder = MlUpdateMemoryContainerPath{} + _ builder = MlUpdateMessagePath{} + _ builder = MlUpdateModelPath{} + _ builder = MlUpdateModelGroupPath{} + _ builder = MlUploadChunkPath{} + _ builder = MlUploadModelPath{} + _ builder = MsearchPath{} + _ builder = MsearchTemplatePath{} + _ builder = MtermvectorsPath{} + _ builder = NeuralStatsPath{} + _ builder = NodesHotThreadsPath{} + _ builder = NodesInfoPath{} + _ builder = NodesReloadSecureSettingsPath{} + _ builder = NodesStatsPath{} + _ builder = NodesUsagePath{} + _ builder = NotificationsCreateConfigPath{} + _ builder = NotificationsDeleteConfigPath{} + _ builder = NotificationsDeleteConfigsPath{} + _ builder = NotificationsGetConfigPath{} + _ builder = NotificationsGetConfigsPath{} + _ builder = NotificationsListChannelsPath{} + _ builder = NotificationsListFeaturesPath{} + _ builder = NotificationsSendTestPath{} + _ builder = NotificationsUpdateConfigPath{} + _ builder = ObservabilityCreateObjectPath{} + _ builder = ObservabilityDeleteObjectPath{} + _ builder = ObservabilityDeleteObjectsPath{} + _ builder = ObservabilityGetLocalstatsPath{} + _ builder = ObservabilityGetObjectPath{} + _ builder = ObservabilityListObjectsPath{} + _ builder = ObservabilityUpdateObjectPath{} + _ builder = PingPath{} + _ builder = PplExplainPath{} + _ builder = PplGetStatsPath{} + _ builder = PplPostStatsPath{} + _ builder = PplQueryPath{} + _ builder = PutScriptPath{} + _ builder = QueryDatasourceDeletePath{} + _ builder = QueryDatasourceRetrievePath{} + _ builder = QueryDatasourcesCreatePath{} + _ builder = QueryDatasourcesListPath{} + _ builder = QueryDatasourcesUpdatePath{} + _ builder = RankEvalPath{} + _ builder = ReindexPath{} + _ builder = ReindexRethrottlePath{} + _ builder = RemoteStoreRestorePath{} + _ builder = RenderSearchTemplatePath{} + _ builder = ReplicationAutofollowStatsPath{} + _ builder = ReplicationCreateReplicationRulePath{} + _ builder = ReplicationDeleteReplicationRulePath{} + _ builder = ReplicationFollowerStatsPath{} + _ builder = ReplicationLeaderStatsPath{} + _ builder = ReplicationPausePath{} + _ builder = ReplicationResumePath{} + _ builder = ReplicationStartPath{} + _ builder = ReplicationStatusPath{} + _ builder = ReplicationStopPath{} + _ builder = ReplicationUpdateSettingsPath{} + _ builder = RollupsDeletePath{} + _ builder = RollupsExplainPath{} + _ builder = RollupsGetPath{} + _ builder = RollupsPutPath{} + _ builder = RollupsStartPath{} + _ builder = RollupsStopPath{} + _ builder = ScriptsPainlessExecutePath{} + _ builder = ScrollPath{} + _ builder = SearchPath{} + _ builder = SearchPipelineDeletePath{} + _ builder = SearchPipelineGetPath{} + _ builder = SearchPipelinePutPath{} + _ builder = SearchRelevanceDeleteExperimentsPath{} + _ builder = SearchRelevanceDeleteJudgmentsPath{} + _ builder = SearchRelevanceDeleteQuerySetsPath{} + _ builder = SearchRelevanceDeleteScheduledExperimentsPath{} + _ builder = SearchRelevanceDeleteSearchConfigurationsPath{} + _ builder = SearchRelevanceGetExperimentsPath{} + _ builder = SearchRelevanceGetJudgmentsPath{} + _ builder = SearchRelevanceGetNodeStatsPath{} + _ builder = SearchRelevanceGetQuerySetsPath{} + _ builder = SearchRelevanceGetScheduledExperimentsPath{} + _ builder = SearchRelevanceGetSearchConfigurationsPath{} + _ builder = SearchRelevanceGetStatsPath{} + _ builder = SearchRelevancePostQuerySetsPath{} + _ builder = SearchRelevancePostScheduledExperimentsPath{} + _ builder = SearchRelevancePutExperimentsPath{} + _ builder = SearchRelevancePutJudgmentsPath{} + _ builder = SearchRelevancePutQuerySetsPath{} + _ builder = SearchRelevancePutSearchConfigurationsPath{} + _ builder = SearchShardsPath{} + _ builder = SearchTemplatePath{} + _ builder = SecurityAuthinfoPath{} + _ builder = SecurityAuthtokenPath{} + _ builder = SecurityChangePasswordPath{} + _ builder = SecurityConfigUpgradeCheckPath{} + _ builder = SecurityConfigUpgradePerformPath{} + _ builder = SecurityCreateActionGroupPath{} + _ builder = SecurityCreateAllowlistPath{} + _ builder = SecurityCreateRolePath{} + _ builder = SecurityCreateRoleMappingPath{} + _ builder = SecurityCreateTenantPath{} + _ builder = SecurityCreateUpdateTenancyConfigPath{} + _ builder = SecurityCreateUserPath{} + _ builder = SecurityCreateUserLegacyPath{} + _ builder = SecurityDeleteActionGroupPath{} + _ builder = SecurityDeleteDistinguishedNamePath{} + _ builder = SecurityDeleteRolePath{} + _ builder = SecurityDeleteRoleMappingPath{} + _ builder = SecurityDeleteTenantPath{} + _ builder = SecurityDeleteUserPath{} + _ builder = SecurityDeleteUserLegacyPath{} + _ builder = SecurityFlushCachePath{} + _ builder = SecurityGenerateOboTokenPath{} + _ builder = SecurityGenerateUserTokenPath{} + _ builder = SecurityGenerateUserTokenLegacyPath{} + _ builder = SecurityGetAccountDetailsPath{} + _ builder = SecurityGetActionGroupPath{} + _ builder = SecurityGetActionGroupsPath{} + _ builder = SecurityGetAllCertificatesPath{} + _ builder = SecurityGetAllowlistPath{} + _ builder = SecurityGetAuditConfigurationPath{} + _ builder = SecurityGetCertificatesPath{} + _ builder = SecurityGetConfigurationPath{} + _ builder = SecurityGetDashboardsInfoPath{} + _ builder = SecurityGetDistinguishedNamePath{} + _ builder = SecurityGetDistinguishedNamesPath{} + _ builder = SecurityGetNodeCertificatesPath{} + _ builder = SecurityGetPermissionsInfoPath{} + _ builder = SecurityGetRolePath{} + _ builder = SecurityGetRoleMappingPath{} + _ builder = SecurityGetRoleMappingsPath{} + _ builder = SecurityGetRolesPath{} + _ builder = SecurityGetSslinfoPath{} + _ builder = SecurityGetTenancyConfigPath{} + _ builder = SecurityGetTenantPath{} + _ builder = SecurityGetTenantsPath{} + _ builder = SecurityGetUserPath{} + _ builder = SecurityGetUserLegacyPath{} + _ builder = SecurityGetUsersPath{} + _ builder = SecurityGetUsersLegacyPath{} + _ builder = SecurityHealthPath{} + _ builder = SecurityMigratePath{} + _ builder = SecurityPatchActionGroupPath{} + _ builder = SecurityPatchActionGroupsPath{} + _ builder = SecurityPatchAllowlistPath{} + _ builder = SecurityPatchAuditConfigurationPath{} + _ builder = SecurityPatchConfigurationPath{} + _ builder = SecurityPatchDistinguishedNamePath{} + _ builder = SecurityPatchDistinguishedNamesPath{} + _ builder = SecurityPatchRolePath{} + _ builder = SecurityPatchRoleMappingPath{} + _ builder = SecurityPatchRoleMappingsPath{} + _ builder = SecurityPatchRolesPath{} + _ builder = SecurityPatchTenantPath{} + _ builder = SecurityPatchTenantsPath{} + _ builder = SecurityPatchUserPath{} + _ builder = SecurityPatchUsersPath{} + _ builder = SecurityPostDashboardsInfoPath{} + _ builder = SecurityReloadHTTPCertificatesPath{} + _ builder = SecurityReloadTransportCertificatesPath{} + _ builder = SecurityTenantInfoPath{} + _ builder = SecurityUpdateAuditConfigurationPath{} + _ builder = SecurityUpdateConfigurationPath{} + _ builder = SecurityUpdateDistinguishedNamePath{} + _ builder = SecurityValidatePath{} + _ builder = SecurityWhoAmIPath{} + _ builder = SecurityWhoAmIProtectedPath{} + _ builder = SecurityAnalyticsGetAlertsPath{} + _ builder = SecurityAnalyticsGetFindingsPath{} + _ builder = SecurityAnalyticsSearchFindingCorrelationsPath{} + _ builder = SmCreatePolicyPath{} + _ builder = SmDeletePolicyPath{} + _ builder = SmExplainPolicyPath{} + _ builder = SmGetPoliciesPath{} + _ builder = SmGetPolicyPath{} + _ builder = SmStartPolicyPath{} + _ builder = SmStopPolicyPath{} + _ builder = SmUpdatePolicyPath{} + _ builder = SnapshotCleanupRepositoryPath{} + _ builder = SnapshotClonePath{} + _ builder = SnapshotCreatePath{} + _ builder = SnapshotCreateRepositoryPath{} + _ builder = SnapshotDeletePath{} + _ builder = SnapshotDeleteRepositoryPath{} + _ builder = SnapshotGetPath{} + _ builder = SnapshotGetRepositoryPath{} + _ builder = SnapshotRestorePath{} + _ builder = SnapshotStatusPath{} + _ builder = SnapshotVerifyRepositoryPath{} + _ builder = SQLClosePath{} + _ builder = SQLExplainPath{} + _ builder = SQLGetStatsPath{} + _ builder = SQLPostStatsPath{} + _ builder = SQLQueryPath{} + _ builder = SQLSettingsPath{} + _ builder = TasksCancelPath{} + _ builder = TasksGetPath{} + _ builder = TasksListPath{} + _ builder = TermvectorsPath{} + _ builder = TransformsDeletePath{} + _ builder = TransformsExplainPath{} + _ builder = TransformsGetPath{} + _ builder = TransformsPreviewPath{} + _ builder = TransformsPutPath{} + _ builder = TransformsSearchPath{} + _ builder = TransformsStartPath{} + _ builder = TransformsStopPath{} + _ builder = UbiInitializePath{} + _ builder = UpdatePath{} + _ builder = UpdateByQueryPath{} + _ builder = UpdateByQueryRethrottlePath{} + _ builder = WlmCreateQueryGroupPath{} + _ builder = WlmDeleteQueryGroupPath{} + _ builder = WlmGetQueryGroupPath{} + _ builder = WlmUpdateQueryGroupPath{} +) + +// --------------------------------------------------------------------------- +// AsynchronousSearchDeletePath (asynchronous_search.delete) +// --------------------------------------------------------------------------- + +// AsynchronousSearchDeletePath builds URL paths for the asynchronous_search.delete operation. +// +// Deletes any responses from an asynchronous search. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/async/index/#delete-searches-and-results +type AsynchronousSearchDeletePath struct { + ID string +} + +func (p AsynchronousSearchDeletePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("AsynchronousSearchDeletePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_asynchronous_search") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// AsynchronousSearchGetPath (asynchronous_search.get) +// --------------------------------------------------------------------------- + +// AsynchronousSearchGetPath builds URL paths for the asynchronous_search.get operation. +// +// Gets partial responses from an asynchronous search. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/async/index/#get-partial-results +type AsynchronousSearchGetPath struct { + ID string +} + +func (p AsynchronousSearchGetPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("AsynchronousSearchGetPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_asynchronous_search") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// AsynchronousSearchSearchPath (asynchronous_search.search) +// --------------------------------------------------------------------------- + +// AsynchronousSearchSearchPath builds URL paths for the asynchronous_search.search operation. +// +// Performs an asynchronous search. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/async/index/#rest-api +type AsynchronousSearchSearchPath struct { +} + +func (p AsynchronousSearchSearchPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_asynchronous_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// AsynchronousSearchStatsPath (asynchronous_search.stats) +// --------------------------------------------------------------------------- + +// AsynchronousSearchStatsPath builds URL paths for the asynchronous_search.stats operation. +// +// Monitors any asynchronous searches that are `running`, `completed`, or `persisted`. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/async/index/#monitor-stats +type AsynchronousSearchStatsPath struct { +} + +func (p AsynchronousSearchStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_asynchronous_search") + pb.writeLit("stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// BulkPath (bulk) +// --------------------------------------------------------------------------- + +// BulkPath builds URL paths for the bulk operation. +// +// Allows to perform multiple index/update/delete operations in a single request. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/bulk/ +type BulkPath struct { + Index string +} + +func (p BulkPath) Build() (string, error) { + pb := acquire() + if p.Index != "" { + pb.writeReq(p.Index) + } + pb.writeLit("_bulk") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// BulkStreamPath (bulk_stream) +// --------------------------------------------------------------------------- + +// BulkStreamPath builds URL paths for the bulk_stream operation. +// +// Allows to perform multiple index/update/delete operations using request response streaming. +// +// Available: >= 2.17.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/bulk-streaming/ +type BulkStreamPath struct { + Index string +} + +func (p BulkStreamPath) Build() (string, error) { + pb := acquire() + if p.Index != "" { + pb.writeReq(p.Index) + } + pb.writeLit("_bulk") + pb.writeLit("stream") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatAliasesPath (cat.aliases) +// --------------------------------------------------------------------------- + +// CatAliasesPath builds URL paths for the cat.aliases operation. +// +// Shows information about aliases currently configured to indexes, including filter and routing information. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-aliases/ +type CatAliasesPath struct { + Name []string +} + +func (p CatAliasesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("aliases") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatAllPITSegmentsPath (cat.all_pit_segments) +// --------------------------------------------------------------------------- + +// CatAllPITSegmentsPath builds URL paths for the cat.all_pit_segments operation. +// +// Lists all active CAT point-in-time segments. +// +// Available: >= 2.4.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/ +type CatAllPITSegmentsPath struct { +} + +func (p CatAllPITSegmentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("pit_segments") + pb.writeLit("_all") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatAllocationPath (cat.allocation) +// --------------------------------------------------------------------------- + +// CatAllocationPath builds URL paths for the cat.allocation operation. +// +// Provides a snapshot of how many shards are allocated to each data node and how much disk space they are using. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-allocation/ +type CatAllocationPath struct { + NodeID []string +} + +func (p CatAllocationPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("allocation") + writeSegments(pb, p.NodeID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatClusterManagerPath (cat.cluster_manager) +// --------------------------------------------------------------------------- + +// CatClusterManagerPath builds URL paths for the cat.cluster_manager operation. +// +// Returns information about the cluster-manager node. +// +// Available: >= 2.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-cluster_manager/ +type CatClusterManagerPath struct { +} + +func (p CatClusterManagerPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("cluster_manager") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatCountPath (cat.count) +// --------------------------------------------------------------------------- + +// CatCountPath builds URL paths for the cat.count operation. +// +// Provides quick access to the document count of the entire cluster or of an individual index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-count/ +type CatCountPath struct { + Index []string +} + +func (p CatCountPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("count") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatFielddataPath (cat.fielddata) +// --------------------------------------------------------------------------- + +// CatFielddataPath builds URL paths for the cat.fielddata operation. +// +// Shows how much heap memory is currently being used by field data on every data node in the cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-field-data/ +type CatFielddataPath struct { + Fields []string +} + +func (p CatFielddataPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("fielddata") + writeSegments(pb, p.Fields) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatHealthPath (cat.health) +// --------------------------------------------------------------------------- + +// CatHealthPath builds URL paths for the cat.health operation. +// +// Returns a concise representation of the cluster health. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-health/ +type CatHealthPath struct { +} + +func (p CatHealthPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("health") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatHelpPath (cat.help) +// --------------------------------------------------------------------------- + +// CatHelpPath builds URL paths for the cat.help operation. +// +// Returns help for the Cat APIs. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/index/ +type CatHelpPath struct { +} + +func (p CatHelpPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatIndicesPath (cat.indices) +// --------------------------------------------------------------------------- + +// CatIndicesPath builds URL paths for the cat.indices operation. +// +// Lists information related to indexes, that is, how much disk space they are using, how many shards they have, their health status, and so on. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-indices/ +type CatIndicesPath struct { + Index []string +} + +func (p CatIndicesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("indices") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatMasterPath (cat.master) +// --------------------------------------------------------------------------- + +// CatMasterPath builds URL paths for the cat.master operation. +// +// Returns information about the cluster-manager node. +// +// Availability: >= 1.0.0; <= 2.0.0. To promote inclusive language, use +// '/_cat/cluster_manager' instead. +type CatMasterPath struct { +} + +func (p CatMasterPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("master") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatNodeattrsPath (cat.nodeattrs) +// --------------------------------------------------------------------------- + +// CatNodeattrsPath builds URL paths for the cat.nodeattrs operation. +// +// Returns information about custom node attributes. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-nodeattrs/ +type CatNodeattrsPath struct { +} + +func (p CatNodeattrsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("nodeattrs") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatNodesPath (cat.nodes) +// --------------------------------------------------------------------------- + +// CatNodesPath builds URL paths for the cat.nodes operation. +// +// Returns basic statistics about the performance of cluster nodes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-nodes/ +type CatNodesPath struct { +} + +func (p CatNodesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("nodes") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatPendingTasksPath (cat.pending_tasks) +// --------------------------------------------------------------------------- + +// CatPendingTasksPath builds URL paths for the cat.pending_tasks operation. +// +// Returns a concise representation of the cluster's pending tasks. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-pending-tasks/ +type CatPendingTasksPath struct { +} + +func (p CatPendingTasksPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("pending_tasks") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatPITSegmentsPath (cat.pit_segments) +// --------------------------------------------------------------------------- + +// CatPITSegmentsPath builds URL paths for the cat.pit_segments operation. +// +// Lists one or several CAT point-in-time segments. +// +// Available: >= 2.4.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/ +type CatPITSegmentsPath struct { +} + +func (p CatPITSegmentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("pit_segments") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatPluginsPath (cat.plugins) +// --------------------------------------------------------------------------- + +// CatPluginsPath builds URL paths for the cat.plugins operation. +// +// Returns information about the names, components, and versions of the installed plugins. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-plugins/ +type CatPluginsPath struct { +} + +func (p CatPluginsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("plugins") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatRecoveryPath (cat.recovery) +// --------------------------------------------------------------------------- + +// CatRecoveryPath builds URL paths for the cat.recovery operation. +// +// Returns all completed and ongoing index and shard recoveries. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-plugins/ +type CatRecoveryPath struct { + Index []string +} + +func (p CatRecoveryPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("recovery") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatRepositoriesPath (cat.repositories) +// --------------------------------------------------------------------------- + +// CatRepositoriesPath builds URL paths for the cat.repositories operation. +// +// Returns information about all snapshot repositories for a cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-repositories/ +type CatRepositoriesPath struct { +} + +func (p CatRepositoriesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("repositories") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatSegmentReplicationPath (cat.segment_replication) +// --------------------------------------------------------------------------- + +// CatSegmentReplicationPath builds URL paths for the cat.segment_replication operation. +// +// Returns information about active and last-completed segment replication events on each replica shard, including related shard-level metrics. +// These metrics provide information about how far behind the primary shard the replicas are lagging. +// +// Available: >= 2.6.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-segment-replication/ +type CatSegmentReplicationPath struct { + Index []string +} + +func (p CatSegmentReplicationPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("segment_replication") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatSegmentsPath (cat.segments) +// --------------------------------------------------------------------------- + +// CatSegmentsPath builds URL paths for the cat.segments operation. +// +// Provides low-level information about the segments in the shards of an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-segments/ +type CatSegmentsPath struct { + Index []string +} + +func (p CatSegmentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("segments") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatShardsPath (cat.shards) +// --------------------------------------------------------------------------- + +// CatShardsPath builds URL paths for the cat.shards operation. +// +// Lists the states of all primary and replica shards and how they are distributed. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-shards/ +type CatShardsPath struct { + Index []string +} + +func (p CatShardsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("shards") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatSnapshotsPath (cat.snapshots) +// --------------------------------------------------------------------------- + +// CatSnapshotsPath builds URL paths for the cat.snapshots operation. +// +// Lists all of the snapshots stored in a specific repository. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-snapshots/ +type CatSnapshotsPath struct { + Repository []string +} + +func (p CatSnapshotsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("snapshots") + writeSegments(pb, p.Repository) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatTasksPath (cat.tasks) +// --------------------------------------------------------------------------- + +// CatTasksPath builds URL paths for the cat.tasks operation. +// +// Lists the progress of all tasks currently running on the cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-tasks/ +type CatTasksPath struct { +} + +func (p CatTasksPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("tasks") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatTemplatesPath (cat.templates) +// --------------------------------------------------------------------------- + +// CatTemplatesPath builds URL paths for the cat.templates operation. +// +// Lists the names, patterns, order numbers, and version numbers of index templates. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-templates/ +type CatTemplatesPath struct { + Name string +} + +func (p CatTemplatesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("templates") + if p.Name != "" { + pb.writeReq(p.Name) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CatThreadPoolPath (cat.thread_pool) +// --------------------------------------------------------------------------- + +// CatThreadPoolPath builds URL paths for the cat.thread_pool operation. +// +// Returns cluster-wide thread pool statistics per node. +// By default the active, queued, and rejected statistics are returned for all thread pools. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cat/cat-thread-pool/ +type CatThreadPoolPath struct { + ThreadPoolPatterns []string +} + +func (p CatThreadPoolPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cat") + pb.writeLit("thread_pool") + writeSegments(pb, p.ThreadPoolPatterns) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClearScrollPath (clear_scroll) +// --------------------------------------------------------------------------- + +// ClearScrollPath builds URL paths for the clear_scroll operation. +// +// Explicitly clears the search context for a scroll. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/scroll/ +type ClearScrollPath struct { + ScrollID []string +} + +func (p ClearScrollPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_search") + pb.writeLit("scroll") + writeSegments(pb, p.ScrollID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterAllocationExplainPath (cluster.allocation_explain) +// --------------------------------------------------------------------------- + +// ClusterAllocationExplainPath builds URL paths for the cluster.allocation_explain operation. +// +// Explains how shards are allocated in the current cluster and provides an explanation for why unassigned shards can't be allocated to a node. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-allocation/ +type ClusterAllocationExplainPath struct { +} + +func (p ClusterAllocationExplainPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("allocation") + pb.writeLit("explain") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterDeleteComponentTemplatePath (cluster.delete_component_template) +// --------------------------------------------------------------------------- + +// ClusterDeleteComponentTemplatePath builds URL paths for the cluster.delete_component_template operation. +// +// Deletes a component template. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ClusterDeleteComponentTemplatePath struct { + Name string +} + +func (p ClusterDeleteComponentTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("ClusterDeleteComponentTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_component_template") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterDeleteDecommissionAwarenessPath (cluster.delete_decommission_awareness) +// --------------------------------------------------------------------------- + +// ClusterDeleteDecommissionAwarenessPath builds URL paths for the cluster.delete_decommission_awareness operation. +// +// Recommissions a decommissioned zone. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-decommission/#example-decommissioning-and-recommissioning-a-zone +type ClusterDeleteDecommissionAwarenessPath struct { +} + +func (p ClusterDeleteDecommissionAwarenessPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("decommission") + pb.writeLit("awareness") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterDeleteVotingConfigExclusionsPath (cluster.delete_voting_config_exclusions) +// --------------------------------------------------------------------------- + +// ClusterDeleteVotingConfigExclusionsPath builds URL paths for the cluster.delete_voting_config_exclusions operation. +// +// Clears any cluster voting configuration exclusions. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ClusterDeleteVotingConfigExclusionsPath struct { +} + +func (p ClusterDeleteVotingConfigExclusionsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("voting_config_exclusions") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterDeleteWeightedRoutingPath (cluster.delete_weighted_routing) +// --------------------------------------------------------------------------- + +// ClusterDeleteWeightedRoutingPath builds URL paths for the cluster.delete_weighted_routing operation. +// +// Delete weighted shard routing weights. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-awareness/#example-deleting-weights +type ClusterDeleteWeightedRoutingPath struct { +} + +func (p ClusterDeleteWeightedRoutingPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("routing") + pb.writeLit("awareness") + pb.writeLit("weights") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterExistsComponentTemplatePath (cluster.exists_component_template) +// --------------------------------------------------------------------------- + +// ClusterExistsComponentTemplatePath builds URL paths for the cluster.exists_component_template operation. +// +// Returns information about whether a particular component template exist. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ClusterExistsComponentTemplatePath struct { + Name string +} + +func (p ClusterExistsComponentTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("ClusterExistsComponentTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_component_template") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterGetComponentTemplatePath (cluster.get_component_template) +// --------------------------------------------------------------------------- + +// ClusterGetComponentTemplatePath builds URL paths for the cluster.get_component_template operation. +// +// Returns one or more component templates. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ClusterGetComponentTemplatePath struct { + Name string +} + +func (p ClusterGetComponentTemplatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_component_template") + if p.Name != "" { + pb.writeReq(p.Name) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterGetDecommissionAwarenessPath (cluster.get_decommission_awareness) +// --------------------------------------------------------------------------- + +// ClusterGetDecommissionAwarenessPath builds URL paths for the cluster.get_decommission_awareness operation. +// +// Retrieves the decommission status for all zones. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-decommission/#example-getting-zone-decommission-status +type ClusterGetDecommissionAwarenessPath struct { + AwarenessAttributeName string +} + +func (p ClusterGetDecommissionAwarenessPath) Build() (string, error) { + if p.AwarenessAttributeName == "" { + return "", fmt.Errorf("ClusterGetDecommissionAwarenessPath.AwarenessAttributeName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("decommission") + pb.writeLit("awareness") + pb.writeReq(p.AwarenessAttributeName) + pb.writeLit("_status") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterGetSettingsPath (cluster.get_settings) +// --------------------------------------------------------------------------- + +// ClusterGetSettingsPath builds URL paths for the cluster.get_settings operation. +// +// Returns cluster settings. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-settings/ +type ClusterGetSettingsPath struct { +} + +func (p ClusterGetSettingsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("settings") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterGetWeightedRoutingPath (cluster.get_weighted_routing) +// --------------------------------------------------------------------------- + +// ClusterGetWeightedRoutingPath builds URL paths for the cluster.get_weighted_routing operation. +// +// Fetches weighted shard routing weights. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-awareness/#example-getting-weights-for-all-zones +type ClusterGetWeightedRoutingPath struct { + Attribute string +} + +func (p ClusterGetWeightedRoutingPath) Build() (string, error) { + if p.Attribute == "" { + return "", fmt.Errorf("ClusterGetWeightedRoutingPath.Attribute: %w", errRequired) + } + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("routing") + pb.writeLit("awareness") + pb.writeReq(p.Attribute) + pb.writeLit("weights") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterHealthPath (cluster.health) +// --------------------------------------------------------------------------- + +// ClusterHealthPath builds URL paths for the cluster.health operation. +// +// Returns basic information about the health of the cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-health/ +type ClusterHealthPath struct { + Index []string +} + +func (p ClusterHealthPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("health") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterPendingTasksPath (cluster.pending_tasks) +// --------------------------------------------------------------------------- + +// ClusterPendingTasksPath builds URL paths for the cluster.pending_tasks operation. +// +// Returns a list of pending cluster-level tasks, such as index creation, mapping updates, +// or new allocations. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ClusterPendingTasksPath struct { +} + +func (p ClusterPendingTasksPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("pending_tasks") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterPostVotingConfigExclusionsPath (cluster.post_voting_config_exclusions) +// --------------------------------------------------------------------------- + +// ClusterPostVotingConfigExclusionsPath builds URL paths for the cluster.post_voting_config_exclusions operation. +// +// Updates the cluster voting configuration by excluding certain node IDs or names. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ClusterPostVotingConfigExclusionsPath struct { +} + +func (p ClusterPostVotingConfigExclusionsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("voting_config_exclusions") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterPutComponentTemplatePath (cluster.put_component_template) +// --------------------------------------------------------------------------- + +// ClusterPutComponentTemplatePath builds URL paths for the cluster.put_component_template operation. +// +// Creates or updates a component template. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-templates/#use-component-templates-to-create-an-index-template +type ClusterPutComponentTemplatePath struct { + Name string +} + +func (p ClusterPutComponentTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("ClusterPutComponentTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_component_template") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterPutDecommissionAwarenessPath (cluster.put_decommission_awareness) +// --------------------------------------------------------------------------- + +// ClusterPutDecommissionAwarenessPath builds URL paths for the cluster.put_decommission_awareness operation. +// +// Decommissions a cluster zone based on awareness. This can greatly benefit multi-zone deployments, where awareness attributes can aid in applying new upgrades to a cluster in a controlled fashion. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-decommission/#example-decommissioning-and-recommissioning-a-zone +type ClusterPutDecommissionAwarenessPath struct { + AwarenessAttributeName string + AwarenessAttributeValue string +} + +func (p ClusterPutDecommissionAwarenessPath) Build() (string, error) { + if p.AwarenessAttributeName == "" { + return "", fmt.Errorf("ClusterPutDecommissionAwarenessPath.AwarenessAttributeName: %w", errRequired) + } + if p.AwarenessAttributeValue == "" { + return "", fmt.Errorf("ClusterPutDecommissionAwarenessPath.AwarenessAttributeValue: %w", errRequired) + } + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("decommission") + pb.writeLit("awareness") + pb.writeReq(p.AwarenessAttributeName) + pb.writeReq(p.AwarenessAttributeValue) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterPutSettingsPath (cluster.put_settings) +// --------------------------------------------------------------------------- + +// ClusterPutSettingsPath builds URL paths for the cluster.put_settings operation. +// +// Updates the cluster settings. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-settings/ +type ClusterPutSettingsPath struct { +} + +func (p ClusterPutSettingsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("settings") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterPutWeightedRoutingPath (cluster.put_weighted_routing) +// --------------------------------------------------------------------------- + +// ClusterPutWeightedRoutingPath builds URL paths for the cluster.put_weighted_routing operation. +// +// Updates weighted shard routing weights. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-awareness/#example-weighted-round-robin-search +type ClusterPutWeightedRoutingPath struct { + Attribute string +} + +func (p ClusterPutWeightedRoutingPath) Build() (string, error) { + if p.Attribute == "" { + return "", fmt.Errorf("ClusterPutWeightedRoutingPath.Attribute: %w", errRequired) + } + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("routing") + pb.writeLit("awareness") + pb.writeReq(p.Attribute) + pb.writeLit("weights") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterRemoteInfoPath (cluster.remote_info) +// --------------------------------------------------------------------------- + +// ClusterRemoteInfoPath builds URL paths for the cluster.remote_info operation. +// +// Returns the information about configured remote clusters. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/remote-info/ +type ClusterRemoteInfoPath struct { +} + +func (p ClusterRemoteInfoPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_remote") + pb.writeLit("info") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterReroutePath (cluster.reroute) +// --------------------------------------------------------------------------- + +// ClusterReroutePath builds URL paths for the cluster.reroute operation. +// +// Allows to manually change the allocation of individual shards in the cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ClusterReroutePath struct { +} + +func (p ClusterReroutePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("reroute") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ClusterStatePath (cluster.state) +// --------------------------------------------------------------------------- + +// ClusterStatePath builds URL paths for the cluster.state operation. +// +// Returns comprehensive information about the state of the cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ClusterStatePath struct { + Metric []string + Index []string +} + +func (p ClusterStatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("state") + switch { + case hasNonEmpty(p.Metric) && hasNonEmpty(p.Index): + writeSegments(pb, p.Metric) + writeSegments(pb, p.Index) + case hasNonEmpty(p.Metric): + writeSegments(pb, p.Metric) + default: + if hasNonEmpty(p.Metric) || hasNonEmpty(p.Index) { + return "", explainClusterStatePath(p) + } + } + return pb.release(), nil +} + +// explainClusterStatePath returns a specific error describing why the +// caller's field combination does not match any spec path variant. The +// switch in ClusterStatePath.Build dispatches here from its +// default: case after confirming at least one optional field is set. +func explainClusterStatePath(p ClusterStatePath) error { + if hasNonEmpty(p.Index) && !hasNonEmpty(p.Metric) { + return fmt.Errorf("ClusterStatePath.Index requires ClusterStatePath.Metric: %w", errRequired) + } + return fmt.Errorf("ClusterStatePath: invalid combination of fields: %w", errRequired) +} + +// --------------------------------------------------------------------------- +// ClusterStatsPath (cluster.stats) +// --------------------------------------------------------------------------- + +// ClusterStatsPath builds URL paths for the cluster.stats operation. +// +// Returns a high-level overview of cluster statistics. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-stats/ +type ClusterStatsPath struct { + Metric []string + IndexMetric []string + NodeID []string +} + +func (p ClusterStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_cluster") + pb.writeLit("stats") + switch { + case hasNonEmpty(p.Metric) && hasNonEmpty(p.IndexMetric) && hasNonEmpty(p.NodeID): + writeSegments(pb, p.Metric) + writeSegments(pb, p.IndexMetric) + pb.writeLit("nodes") + writeSegments(pb, p.NodeID) + case hasNonEmpty(p.Metric) && hasNonEmpty(p.NodeID): + writeSegments(pb, p.Metric) + pb.writeLit("nodes") + writeSegments(pb, p.NodeID) + case hasNonEmpty(p.NodeID): + pb.writeLit("nodes") + writeSegments(pb, p.NodeID) + default: + if hasNonEmpty(p.Metric) || hasNonEmpty(p.IndexMetric) || hasNonEmpty(p.NodeID) { + return "", explainClusterStatsPath(p) + } + } + return pb.release(), nil +} + +// explainClusterStatsPath returns a specific error describing why the +// caller's field combination does not match any spec path variant. The +// switch in ClusterStatsPath.Build dispatches here from its +// default: case after confirming at least one optional field is set. +func explainClusterStatsPath(p ClusterStatsPath) error { + if hasNonEmpty(p.Metric) && !hasNonEmpty(p.NodeID) { + return fmt.Errorf("ClusterStatsPath.Metric requires ClusterStatsPath.NodeID: %w", errRequired) + } + if hasNonEmpty(p.IndexMetric) && !hasNonEmpty(p.Metric) { + return fmt.Errorf("ClusterStatsPath.IndexMetric requires ClusterStatsPath.Metric: %w", errRequired) + } + return fmt.Errorf("ClusterStatsPath: invalid combination of fields: %w", errRequired) +} + +// --------------------------------------------------------------------------- +// CountPath (count) +// --------------------------------------------------------------------------- + +// CountPath builds URL paths for the count operation. +// +// Returns number of documents matching a query. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/count/ +type CountPath struct { + Index []string +} + +func (p CountPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_count") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CreatePath (create) +// --------------------------------------------------------------------------- + +// CreatePath builds URL paths for the create operation. +// +// Creates a new document in the index. +// +// Returns a 409 response when a document with a same ID already exists in the index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/index-document/ +type CreatePath struct { + Index string + ID string +} + +func (p CreatePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("CreatePath.Index: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("CreatePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_create") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// CreatePITPath (create_pit) +// --------------------------------------------------------------------------- + +// CreatePITPath builds URL paths for the create_pit operation. +// +// Creates point in time context. +// +// Available: >= 2.4.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/#create-a-pit +type CreatePITPath struct { + Index []string +} + +func (p CreatePITPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("CreatePITPath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_search") + pb.writeLit("point_in_time") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DanglingIndicesDeleteDanglingIndexPath (dangling_indices.delete_dangling_index) +// --------------------------------------------------------------------------- + +// DanglingIndicesDeleteDanglingIndexPath builds URL paths for the dangling_indices.delete_dangling_index operation. +// +// Deletes the specified dangling index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/dangling-index/ +type DanglingIndicesDeleteDanglingIndexPath struct { + IndexUUID string +} + +func (p DanglingIndicesDeleteDanglingIndexPath) Build() (string, error) { + if p.IndexUUID == "" { + return "", fmt.Errorf("DanglingIndicesDeleteDanglingIndexPath.IndexUUID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_dangling") + pb.writeReq(p.IndexUUID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DanglingIndicesImportDanglingIndexPath (dangling_indices.import_dangling_index) +// --------------------------------------------------------------------------- + +// DanglingIndicesImportDanglingIndexPath builds URL paths for the dangling_indices.import_dangling_index operation. +// +// Imports the specified dangling index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/dangling-index/ +type DanglingIndicesImportDanglingIndexPath struct { + IndexUUID string +} + +func (p DanglingIndicesImportDanglingIndexPath) Build() (string, error) { + if p.IndexUUID == "" { + return "", fmt.Errorf("DanglingIndicesImportDanglingIndexPath.IndexUUID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_dangling") + pb.writeReq(p.IndexUUID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DanglingIndicesListDanglingIndicesPath (dangling_indices.list_dangling_indices) +// --------------------------------------------------------------------------- + +// DanglingIndicesListDanglingIndicesPath builds URL paths for the dangling_indices.list_dangling_indices operation. +// +// Returns all dangling indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/dangling-index/ +type DanglingIndicesListDanglingIndicesPath struct { +} + +func (p DanglingIndicesListDanglingIndicesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_dangling") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DeletePath (delete) +// --------------------------------------------------------------------------- + +// DeletePath builds URL paths for the delete operation. +// +// Removes a document from the index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/delete-document/ +type DeletePath struct { + Index string + ID string +} + +func (p DeletePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("DeletePath.Index: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("DeletePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_doc") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DeleteAllPitsPath (delete_all_pits) +// --------------------------------------------------------------------------- + +// DeleteAllPitsPath builds URL paths for the delete_all_pits operation. +// +// Deletes all active point in time searches. +// +// Available: >= 2.4.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/#delete-pits +type DeleteAllPitsPath struct { +} + +func (p DeleteAllPitsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_search") + pb.writeLit("point_in_time") + pb.writeLit("_all") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DeleteByQueryPath (delete_by_query) +// --------------------------------------------------------------------------- + +// DeleteByQueryPath builds URL paths for the delete_by_query operation. +// +// Deletes documents matching the provided query. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/delete-by-query/ +type DeleteByQueryPath struct { + Index []string +} + +func (p DeleteByQueryPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("DeleteByQueryPath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_delete_by_query") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DeleteByQueryRethrottlePath (delete_by_query_rethrottle) +// --------------------------------------------------------------------------- + +// DeleteByQueryRethrottlePath builds URL paths for the delete_by_query_rethrottle operation. +// +// Changes the number of requests per second for a particular Delete By Query operation. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type DeleteByQueryRethrottlePath struct { + TaskID string +} + +func (p DeleteByQueryRethrottlePath) Build() (string, error) { + if p.TaskID == "" { + return "", fmt.Errorf("DeleteByQueryRethrottlePath.TaskID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_delete_by_query") + pb.writeReq(p.TaskID) + pb.writeLit("_rethrottle") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DeletePITPath (delete_pit) +// --------------------------------------------------------------------------- + +// DeletePITPath builds URL paths for the delete_pit operation. +// +// Deletes one or more point in time searches based on the IDs passed. +// +// Available: >= 2.4.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/#delete-pits +type DeletePITPath struct { +} + +func (p DeletePITPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_search") + pb.writeLit("point_in_time") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// DeleteScriptPath (delete_script) +// --------------------------------------------------------------------------- + +// DeleteScriptPath builds URL paths for the delete_script operation. +// +// Deletes a script. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/script-apis/delete-script/ +type DeleteScriptPath struct { + ID string +} + +func (p DeleteScriptPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("DeleteScriptPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_scripts") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ExistsPath (exists) +// --------------------------------------------------------------------------- + +// ExistsPath builds URL paths for the exists operation. +// +// Returns information about whether a document exists in an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/get-documents/ +type ExistsPath struct { + Index string + ID string +} + +func (p ExistsPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ExistsPath.Index: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("ExistsPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_doc") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ExistsSourcePath (exists_source) +// --------------------------------------------------------------------------- + +// ExistsSourcePath builds URL paths for the exists_source operation. +// +// Returns information about whether a document source exists in an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/get-documents/ +type ExistsSourcePath struct { + Index string + ID string +} + +func (p ExistsSourcePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ExistsSourcePath.Index: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("ExistsSourcePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_source") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ExplainPath (explain) +// --------------------------------------------------------------------------- + +// ExplainPath builds URL paths for the explain operation. +// +// Returns information about why a specific document matches (or doesn't match) a query. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/explain/ +type ExplainPath struct { + Index string + ID string +} + +func (p ExplainPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ExplainPath.Index: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("ExplainPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_explain") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FieldCapsPath (field_caps) +// --------------------------------------------------------------------------- + +// FieldCapsPath builds URL paths for the field_caps operation. +// +// Returns the information about the capabilities of fields among multiple indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/field-types/supported-field-types/alias/#using-aliases-in-field-capabilities-api-operations +type FieldCapsPath struct { + Index []string +} + +func (p FieldCapsPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_field_caps") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkCreatePath (flow_framework.create) +// --------------------------------------------------------------------------- + +// FlowFrameworkCreatePath builds URL paths for the flow_framework.create operation. +// +// Creates a new workflow template. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/create-workflow/ +type FlowFrameworkCreatePath struct { +} + +func (p FlowFrameworkCreatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkDeletePath (flow_framework.delete) +// --------------------------------------------------------------------------- + +// FlowFrameworkDeletePath builds URL paths for the flow_framework.delete operation. +// +// Deletes a workflow template. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/delete-workflow/ +type FlowFrameworkDeletePath struct { + WorkflowID string +} + +func (p FlowFrameworkDeletePath) Build() (string, error) { + if p.WorkflowID == "" { + return "", fmt.Errorf("FlowFrameworkDeletePath.WorkflowID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeReq(p.WorkflowID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkDeprovisionPath (flow_framework.deprovision) +// --------------------------------------------------------------------------- + +// FlowFrameworkDeprovisionPath builds URL paths for the flow_framework.deprovision operation. +// +// Deprovision workflow's resources when you no longer need them. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/deprovision-workflow/ +type FlowFrameworkDeprovisionPath struct { + WorkflowID string +} + +func (p FlowFrameworkDeprovisionPath) Build() (string, error) { + if p.WorkflowID == "" { + return "", fmt.Errorf("FlowFrameworkDeprovisionPath.WorkflowID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeReq(p.WorkflowID) + pb.writeLit("_deprovision") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkGetPath (flow_framework.get) +// --------------------------------------------------------------------------- + +// FlowFrameworkGetPath builds URL paths for the flow_framework.get operation. +// +// Retrieves a workflow template. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/get-workflow/ +type FlowFrameworkGetPath struct { + WorkflowID string +} + +func (p FlowFrameworkGetPath) Build() (string, error) { + if p.WorkflowID == "" { + return "", fmt.Errorf("FlowFrameworkGetPath.WorkflowID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeReq(p.WorkflowID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkGetStatusPath (flow_framework.get_status) +// --------------------------------------------------------------------------- + +// FlowFrameworkGetStatusPath builds URL paths for the flow_framework.get_status operation. +// +// Retrieves the current workflow provisioning status. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/get-workflow-status/ +type FlowFrameworkGetStatusPath struct { + WorkflowID string +} + +func (p FlowFrameworkGetStatusPath) Build() (string, error) { + if p.WorkflowID == "" { + return "", fmt.Errorf("FlowFrameworkGetStatusPath.WorkflowID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeReq(p.WorkflowID) + pb.writeLit("_status") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkGetStepsPath (flow_framework.get_steps) +// --------------------------------------------------------------------------- + +// FlowFrameworkGetStepsPath builds URL paths for the flow_framework.get_steps operation. +// +// Retrieves available workflow steps. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/get-workflow-steps/ +type FlowFrameworkGetStepsPath struct { +} + +func (p FlowFrameworkGetStepsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeLit("_steps") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkProvisionPath (flow_framework.provision) +// --------------------------------------------------------------------------- + +// FlowFrameworkProvisionPath builds URL paths for the flow_framework.provision operation. +// +// Provisioning a workflow. This API is also executed when the Create or Update Workflow API is called with the provision parameter set to true. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/provision-workflow/ +type FlowFrameworkProvisionPath struct { + WorkflowID string +} + +func (p FlowFrameworkProvisionPath) Build() (string, error) { + if p.WorkflowID == "" { + return "", fmt.Errorf("FlowFrameworkProvisionPath.WorkflowID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeReq(p.WorkflowID) + pb.writeLit("_provision") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkSearchPath (flow_framework.search) +// --------------------------------------------------------------------------- + +// FlowFrameworkSearchPath builds URL paths for the flow_framework.search operation. +// +// Search for workflows by using a query matching a field. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/provision-workflow/ +type FlowFrameworkSearchPath struct { +} + +func (p FlowFrameworkSearchPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkSearchStatePath (flow_framework.search_state) +// --------------------------------------------------------------------------- + +// FlowFrameworkSearchStatePath builds URL paths for the flow_framework.search_state operation. +// +// Search for workflows by using a query matching a field. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/search-workflow-state/ +type FlowFrameworkSearchStatePath struct { +} + +func (p FlowFrameworkSearchStatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeLit("state") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// FlowFrameworkUpdatePath (flow_framework.update) +// --------------------------------------------------------------------------- + +// FlowFrameworkUpdatePath builds URL paths for the flow_framework.update operation. +// +// Updates a workflow template that has not been provisioned. +// +// Available: >= 2.12.0 +// +// See: https://opensearch.org/docs/latest/automating-configurations/api/create-workflow/ +type FlowFrameworkUpdatePath struct { + WorkflowID string +} + +func (p FlowFrameworkUpdatePath) Build() (string, error) { + if p.WorkflowID == "" { + return "", fmt.Errorf("FlowFrameworkUpdatePath.WorkflowID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_flow_framework") + pb.writeLit("workflow") + pb.writeReq(p.WorkflowID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GeospatialDeleteIp2geoDatasourcePath (geospatial.delete_ip2geo_datasource) +// --------------------------------------------------------------------------- + +// GeospatialDeleteIp2geoDatasourcePath builds URL paths for the geospatial.delete_ip2geo_datasource operation. +// +// Delete a specific IP2Geo data source. +// +// Available: >= 2.11.0 +// +// See: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#deleting-the-ip2geo-data-source +type GeospatialDeleteIp2geoDatasourcePath struct { + Name string +} + +func (p GeospatialDeleteIp2geoDatasourcePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("GeospatialDeleteIp2geoDatasourcePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("geospatial") + pb.writeLit("ip2geo") + pb.writeLit("datasource") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GeospatialGeojsonUploadPostPath (geospatial.geojson_upload_post) +// --------------------------------------------------------------------------- + +// GeospatialGeojsonUploadPostPath builds URL paths for the geospatial.geojson_upload_post operation. +// +// Use an OpenSearch query to upload `GeoJSON`, operation will fail if index exists. +// - When type is `geo_point`, only Point geometry is allowed +// - When type is `geo_shape`, all geometry types are allowed (Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Envelope). +// +// Available: >= 2.11.0 +type GeospatialGeojsonUploadPostPath struct { +} + +func (p GeospatialGeojsonUploadPostPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("geospatial") + pb.writeLit("geojson") + pb.writeLit("_upload") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GeospatialGeojsonUploadPutPath (geospatial.geojson_upload_put) +// --------------------------------------------------------------------------- + +// GeospatialGeojsonUploadPutPath builds URL paths for the geospatial.geojson_upload_put operation. +// +// Use an OpenSearch query to upload `GeoJSON` regardless if index exists. +// - When type is `geo_point`, only Point geometry is allowed +// - When type is `geo_shape`, all geometry types are allowed (Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Envelope). +// +// Available: >= 2.11.0 +type GeospatialGeojsonUploadPutPath struct { +} + +func (p GeospatialGeojsonUploadPutPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("geospatial") + pb.writeLit("geojson") + pb.writeLit("_upload") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GeospatialGetIp2geoDatasourcePath (geospatial.get_ip2geo_datasource) +// --------------------------------------------------------------------------- + +// GeospatialGetIp2geoDatasourcePath builds URL paths for the geospatial.get_ip2geo_datasource operation. +// +// Get one or more IP2Geo data sources, defaulting to returning all if no names specified. +// +// Available: >= 2.11.0 +// +// See: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#sending-a-get-request +type GeospatialGetIp2geoDatasourcePath struct { + Name []string +} + +func (p GeospatialGetIp2geoDatasourcePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("geospatial") + pb.writeLit("ip2geo") + pb.writeLit("datasource") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GeospatialGetUploadStatsPath (geospatial.get_upload_stats) +// --------------------------------------------------------------------------- + +// GeospatialGetUploadStatsPath builds URL paths for the geospatial.get_upload_stats operation. +// +// Retrieves statistics for all geospatial uploads. +// +// Available: >= 2.11.0 +type GeospatialGetUploadStatsPath struct { +} + +func (p GeospatialGetUploadStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("geospatial") + pb.writeLit("_upload") + pb.writeLit("stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GeospatialPutIp2geoDatasourcePath (geospatial.put_ip2geo_datasource) +// --------------------------------------------------------------------------- + +// GeospatialPutIp2geoDatasourcePath builds URL paths for the geospatial.put_ip2geo_datasource operation. +// +// Create a specific IP2Geo data source. +// Default values: +// - `endpoint`: `"https://geoip.maps.opensearch.org/v1/geolite2-city/manifest.json"` +// - `update_interval_in_days`: 3. +// +// Available: >= 2.11.0 +// +// See: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#data-source-options +type GeospatialPutIp2geoDatasourcePath struct { + Name string +} + +func (p GeospatialPutIp2geoDatasourcePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("GeospatialPutIp2geoDatasourcePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("geospatial") + pb.writeLit("ip2geo") + pb.writeLit("datasource") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GeospatialPutIp2geoDatasourceSettingsPath (geospatial.put_ip2geo_datasource_settings) +// --------------------------------------------------------------------------- + +// GeospatialPutIp2geoDatasourceSettingsPath builds URL paths for the geospatial.put_ip2geo_datasource_settings operation. +// +// Update a specific IP2Geo data source. +// +// Available: >= 2.11.0 +// +// See: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#updating-an-ip2geo-data-source +type GeospatialPutIp2geoDatasourceSettingsPath struct { + Name string +} + +func (p GeospatialPutIp2geoDatasourceSettingsPath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("GeospatialPutIp2geoDatasourceSettingsPath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("geospatial") + pb.writeLit("ip2geo") + pb.writeLit("datasource") + pb.writeReq(p.Name) + pb.writeLit("_settings") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GetPath (get) +// --------------------------------------------------------------------------- + +// GetPath builds URL paths for the get operation. +// +// Returns a document. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/get-documents/ +type GetPath struct { + Index string + ID string +} + +func (p GetPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("GetPath.Index: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("GetPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_doc") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GetAllPitsPath (get_all_pits) +// --------------------------------------------------------------------------- + +// GetAllPitsPath builds URL paths for the get_all_pits operation. +// +// Lists all active point in time searches. +// +// Available: >= 2.4.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/#list-all-pits +type GetAllPitsPath struct { +} + +func (p GetAllPitsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_search") + pb.writeLit("point_in_time") + pb.writeLit("_all") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GetScriptPath (get_script) +// --------------------------------------------------------------------------- + +// GetScriptPath builds URL paths for the get_script operation. +// +// Returns a script. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/script-apis/get-stored-script/ +type GetScriptPath struct { + ID string +} + +func (p GetScriptPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("GetScriptPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_scripts") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GetScriptContextPath (get_script_context) +// --------------------------------------------------------------------------- + +// GetScriptContextPath builds URL paths for the get_script_context operation. +// +// Returns all script contexts. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/script-apis/get-script-contexts/ +type GetScriptContextPath struct { +} + +func (p GetScriptContextPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_script_context") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GetScriptLanguagesPath (get_script_languages) +// --------------------------------------------------------------------------- + +// GetScriptLanguagesPath builds URL paths for the get_script_languages operation. +// +// Returns available script types, languages and contexts. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/script-apis/get-script-language/ +type GetScriptLanguagesPath struct { +} + +func (p GetScriptLanguagesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_script_language") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// GetSourcePath (get_source) +// --------------------------------------------------------------------------- + +// GetSourcePath builds URL paths for the get_source operation. +// +// Returns the source of a document. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/get-documents/ +type GetSourcePath struct { + Index string + ID string +} + +func (p GetSourcePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("GetSourcePath.Index: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("GetSourcePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_source") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndexPath (index) +// --------------------------------------------------------------------------- + +// IndexPath builds URL paths for the index operation. +// +// Creates or updates a document in an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/index-document/ +type IndexPath struct { + Index string + ID string +} + +func (p IndexPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("IndexPath.Index: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_doc") + if p.ID != "" { + pb.writeReq(p.ID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesAddBlockPath (indices.add_block) +// --------------------------------------------------------------------------- + +// IndicesAddBlockPath builds URL paths for the indices.add_block operation. +// +// Adds a block to an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesAddBlockPath struct { + Index []string + Block string +} + +func (p IndicesAddBlockPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IndicesAddBlockPath.Index: %w", errRequired) + } + if p.Block == "" { + return "", fmt.Errorf("IndicesAddBlockPath.Block: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_block") + pb.writeReq(p.Block) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesAnalyzePath (indices.analyze) +// --------------------------------------------------------------------------- + +// IndicesAnalyzePath builds URL paths for the indices.analyze operation. +// +// Performs the analysis process on a text and return the tokens breakdown of the text. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/analyze-apis/perform-text-analysis/ +type IndicesAnalyzePath struct { + Index string +} + +func (p IndicesAnalyzePath) Build() (string, error) { + pb := acquire() + if p.Index != "" { + pb.writeReq(p.Index) + } + pb.writeLit("_analyze") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesClearCachePath (indices.clear_cache) +// --------------------------------------------------------------------------- + +// IndicesClearCachePath builds URL paths for the indices.clear_cache operation. +// +// Clears all or specific caches for one or more indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/clear-index-cache/ +type IndicesClearCachePath struct { + Index []string +} + +func (p IndicesClearCachePath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_cache") + pb.writeLit("clear") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesClonePath (indices.clone) +// --------------------------------------------------------------------------- + +// IndicesClonePath builds URL paths for the indices.clone operation. +// +// Clones an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/clone/ +type IndicesClonePath struct { + Index string + Target string +} + +func (p IndicesClonePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("IndicesClonePath.Index: %w", errRequired) + } + if p.Target == "" { + return "", fmt.Errorf("IndicesClonePath.Target: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_clone") + pb.writeReq(p.Target) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesClosePath (indices.close) +// --------------------------------------------------------------------------- + +// IndicesClosePath builds URL paths for the indices.close operation. +// +// Closes an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/close-index/ +type IndicesClosePath struct { + Index []string +} + +func (p IndicesClosePath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IndicesClosePath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_close") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesCreatePath (indices.create) +// --------------------------------------------------------------------------- + +// IndicesCreatePath builds URL paths for the indices.create operation. +// +// Creates an index with optional settings and mappings. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/create-index/ +type IndicesCreatePath struct { + Index string +} + +func (p IndicesCreatePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("IndicesCreatePath.Index: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesCreateDataStreamPath (indices.create_data_stream) +// --------------------------------------------------------------------------- + +// IndicesCreateDataStreamPath builds URL paths for the indices.create_data_stream operation. +// +// Creates or updates a data stream. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/data-streams/ +type IndicesCreateDataStreamPath struct { + Name string +} + +func (p IndicesCreateDataStreamPath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("IndicesCreateDataStreamPath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_data_stream") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesDataStreamsStatsPath (indices.data_streams_stats) +// --------------------------------------------------------------------------- + +// IndicesDataStreamsStatsPath builds URL paths for the indices.data_streams_stats operation. +// +// Provides statistics on operations happening in a data stream. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/data-streams/ +type IndicesDataStreamsStatsPath struct { + Name []string +} + +func (p IndicesDataStreamsStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_data_stream") + writeSegments(pb, p.Name) + pb.writeLit("_stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesDeletePath (indices.delete) +// --------------------------------------------------------------------------- + +// IndicesDeletePath builds URL paths for the indices.delete operation. +// +// Deletes an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/delete-index/ +type IndicesDeletePath struct { + Index []string +} + +func (p IndicesDeletePath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IndicesDeletePath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesDeleteAliasPath (indices.delete_alias) +// --------------------------------------------------------------------------- + +// IndicesDeleteAliasPath builds URL paths for the indices.delete_alias operation. +// +// Deletes an alias. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-alias/#delete-aliases +type IndicesDeleteAliasPath struct { + Index []string + Name []string +} + +func (p IndicesDeleteAliasPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IndicesDeleteAliasPath.Index: %w", errRequired) + } + if !hasNonEmpty(p.Name) { + return "", fmt.Errorf("IndicesDeleteAliasPath.Name: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_alias") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesDeleteDataStreamPath (indices.delete_data_stream) +// --------------------------------------------------------------------------- + +// IndicesDeleteDataStreamPath builds URL paths for the indices.delete_data_stream operation. +// +// Deletes a data stream. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/data-streams/ +type IndicesDeleteDataStreamPath struct { + Name []string +} + +func (p IndicesDeleteDataStreamPath) Build() (string, error) { + if !hasNonEmpty(p.Name) { + return "", fmt.Errorf("IndicesDeleteDataStreamPath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_data_stream") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesDeleteIndexTemplatePath (indices.delete_index_template) +// --------------------------------------------------------------------------- + +// IndicesDeleteIndexTemplatePath builds URL paths for the indices.delete_index_template operation. +// +// Deletes an index template. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-templates/#delete-a-template +type IndicesDeleteIndexTemplatePath struct { + Name string +} + +func (p IndicesDeleteIndexTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("IndicesDeleteIndexTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_index_template") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesDeleteTemplatePath (indices.delete_template) +// --------------------------------------------------------------------------- + +// IndicesDeleteTemplatePath builds URL paths for the indices.delete_template operation. +// +// Deletes an index template. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesDeleteTemplatePath struct { + Name string +} + +func (p IndicesDeleteTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("IndicesDeleteTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_template") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesExistsPath (indices.exists) +// --------------------------------------------------------------------------- + +// IndicesExistsPath builds URL paths for the indices.exists operation. +// +// Returns information about whether a particular index exists. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/exists/ +type IndicesExistsPath struct { + Index []string +} + +func (p IndicesExistsPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IndicesExistsPath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesExistsAliasPath (indices.exists_alias) +// --------------------------------------------------------------------------- + +// IndicesExistsAliasPath builds URL paths for the indices.exists_alias operation. +// +// Returns information about whether a particular alias exists. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesExistsAliasPath struct { + Index []string + Name []string +} + +func (p IndicesExistsAliasPath) Build() (string, error) { + if !hasNonEmpty(p.Name) { + return "", fmt.Errorf("IndicesExistsAliasPath.Name: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_alias") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesExistsIndexTemplatePath (indices.exists_index_template) +// --------------------------------------------------------------------------- + +// IndicesExistsIndexTemplatePath builds URL paths for the indices.exists_index_template operation. +// +// Returns information about whether a particular index template exists. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-templates/ +type IndicesExistsIndexTemplatePath struct { + Name string +} + +func (p IndicesExistsIndexTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("IndicesExistsIndexTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_index_template") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesExistsTemplatePath (indices.exists_template) +// --------------------------------------------------------------------------- + +// IndicesExistsTemplatePath builds URL paths for the indices.exists_template operation. +// +// Returns information about whether a particular index template exists. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesExistsTemplatePath struct { + Name []string +} + +func (p IndicesExistsTemplatePath) Build() (string, error) { + if !hasNonEmpty(p.Name) { + return "", fmt.Errorf("IndicesExistsTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_template") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesFlushPath (indices.flush) +// --------------------------------------------------------------------------- + +// IndicesFlushPath builds URL paths for the indices.flush operation. +// +// Performs the flush operation on one or more indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesFlushPath struct { + Index []string +} + +func (p IndicesFlushPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_flush") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesForcemergePath (indices.forcemerge) +// --------------------------------------------------------------------------- + +// IndicesForcemergePath builds URL paths for the indices.forcemerge operation. +// +// Performs the force merge operation on one or more indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesForcemergePath struct { + Index []string +} + +func (p IndicesForcemergePath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_forcemerge") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetPath (indices.get) +// --------------------------------------------------------------------------- + +// IndicesGetPath builds URL paths for the indices.get operation. +// +// Returns information about one or more indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/get-index/ +type IndicesGetPath struct { + Index []string +} + +func (p IndicesGetPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IndicesGetPath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetAliasPath (indices.get_alias) +// --------------------------------------------------------------------------- + +// IndicesGetAliasPath builds URL paths for the indices.get_alias operation. +// +// Returns an alias. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-alias/ +type IndicesGetAliasPath struct { + Index []string + Name []string +} + +func (p IndicesGetAliasPath) Build() (string, error) { + pb := acquire() + switch { + case hasNonEmpty(p.Index) && hasNonEmpty(p.Name): + writeSegments(pb, p.Index) + pb.writeLit("_alias") + writeSegments(pb, p.Name) + case hasNonEmpty(p.Index): + writeSegments(pb, p.Index) + pb.writeLit("_alias") + case hasNonEmpty(p.Name): + pb.writeLit("_alias") + writeSegments(pb, p.Name) + default: + pb.writeLit("_alias") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetDataStreamPath (indices.get_data_stream) +// --------------------------------------------------------------------------- + +// IndicesGetDataStreamPath builds URL paths for the indices.get_data_stream operation. +// +// Returns data streams. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/data-streams/ +type IndicesGetDataStreamPath struct { + Name []string +} + +func (p IndicesGetDataStreamPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_data_stream") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetFieldMappingPath (indices.get_field_mapping) +// --------------------------------------------------------------------------- + +// IndicesGetFieldMappingPath builds URL paths for the indices.get_field_mapping operation. +// +// Returns mapping for one or more fields. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/field-types/index/ +type IndicesGetFieldMappingPath struct { + Index []string + Fields []string +} + +func (p IndicesGetFieldMappingPath) Build() (string, error) { + if !hasNonEmpty(p.Fields) { + return "", fmt.Errorf("IndicesGetFieldMappingPath.Fields: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_mapping") + pb.writeLit("field") + writeSegments(pb, p.Fields) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetIndexTemplatePath (indices.get_index_template) +// --------------------------------------------------------------------------- + +// IndicesGetIndexTemplatePath builds URL paths for the indices.get_index_template operation. +// +// Returns an index template. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-templates/ +type IndicesGetIndexTemplatePath struct { + Name string +} + +func (p IndicesGetIndexTemplatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_index_template") + if p.Name != "" { + pb.writeReq(p.Name) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetMappingPath (indices.get_mapping) +// --------------------------------------------------------------------------- + +// IndicesGetMappingPath builds URL paths for the indices.get_mapping operation. +// +// Returns mappings for one or more indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/field-types/index/#get-a-mapping +type IndicesGetMappingPath struct { + Index []string +} + +func (p IndicesGetMappingPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_mapping") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetSettingsPath (indices.get_settings) +// --------------------------------------------------------------------------- + +// IndicesGetSettingsPath builds URL paths for the indices.get_settings operation. +// +// Returns settings for one or more indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/get-settings/ +type IndicesGetSettingsPath struct { + Index []string + Name []string +} + +func (p IndicesGetSettingsPath) Build() (string, error) { + pb := acquire() + switch { + case hasNonEmpty(p.Index) && hasNonEmpty(p.Name): + writeSegments(pb, p.Index) + pb.writeLit("_settings") + writeSegments(pb, p.Name) + case hasNonEmpty(p.Index): + writeSegments(pb, p.Index) + pb.writeLit("_settings") + case hasNonEmpty(p.Name): + pb.writeLit("_settings") + writeSegments(pb, p.Name) + default: + pb.writeLit("_settings") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetTemplatePath (indices.get_template) +// --------------------------------------------------------------------------- + +// IndicesGetTemplatePath builds URL paths for the indices.get_template operation. +// +// Returns an index template. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesGetTemplatePath struct { + Name []string +} + +func (p IndicesGetTemplatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_template") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesGetUpgradePath (indices.get_upgrade) +// --------------------------------------------------------------------------- + +// IndicesGetUpgradePath builds URL paths for the indices.get_upgrade operation. +// +// The `_upgrade` API is no longer useful and will be removed. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesGetUpgradePath struct { + Index []string +} + +func (p IndicesGetUpgradePath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_upgrade") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesOpenPath (indices.open) +// --------------------------------------------------------------------------- + +// IndicesOpenPath builds URL paths for the indices.open operation. +// +// Opens an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/open-index/ +type IndicesOpenPath struct { + Index []string +} + +func (p IndicesOpenPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IndicesOpenPath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_open") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesPutAliasPath (indices.put_alias) +// --------------------------------------------------------------------------- + +// IndicesPutAliasPath builds URL paths for the indices.put_alias operation. +// +// Creates or updates an alias. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ +type IndicesPutAliasPath struct { + Index []string + Name string +} + +func (p IndicesPutAliasPath) Build() (string, error) { + pb := acquire() + switch { + case hasNonEmpty(p.Index) && p.Name != "": + writeSegments(pb, p.Index) + pb.writeLit("_alias") + pb.writeReq(p.Name) + case hasNonEmpty(p.Index): + writeSegments(pb, p.Index) + pb.writeLit("_alias") + case p.Name != "": + pb.writeLit("_alias") + pb.writeReq(p.Name) + default: + pb.writeLit("_alias") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesPutIndexTemplatePath (indices.put_index_template) +// --------------------------------------------------------------------------- + +// IndicesPutIndexTemplatePath builds URL paths for the indices.put_index_template operation. +// +// Creates or updates an index template. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-templates/ +type IndicesPutIndexTemplatePath struct { + Name string +} + +func (p IndicesPutIndexTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("IndicesPutIndexTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_index_template") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesPutMappingPath (indices.put_mapping) +// --------------------------------------------------------------------------- + +// IndicesPutMappingPath builds URL paths for the indices.put_mapping operation. +// +// Updates the index mappings. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/put-mapping/ +type IndicesPutMappingPath struct { + Index []string +} + +func (p IndicesPutMappingPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IndicesPutMappingPath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_mapping") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesPutSettingsPath (indices.put_settings) +// --------------------------------------------------------------------------- + +// IndicesPutSettingsPath builds URL paths for the indices.put_settings operation. +// +// Updates the index settings. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/update-settings/ +type IndicesPutSettingsPath struct { + Index []string +} + +func (p IndicesPutSettingsPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_settings") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesPutTemplatePath (indices.put_template) +// --------------------------------------------------------------------------- + +// IndicesPutTemplatePath builds URL paths for the indices.put_template operation. +// +// Creates or updates an index template. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-templates/ +type IndicesPutTemplatePath struct { + Name string +} + +func (p IndicesPutTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("IndicesPutTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_template") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesRecoveryPath (indices.recovery) +// --------------------------------------------------------------------------- + +// IndicesRecoveryPath builds URL paths for the indices.recovery operation. +// +// Returns information about ongoing index shard recoveries. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesRecoveryPath struct { + Index []string +} + +func (p IndicesRecoveryPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_recovery") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesRefreshPath (indices.refresh) +// --------------------------------------------------------------------------- + +// IndicesRefreshPath builds URL paths for the indices.refresh operation. +// +// Performs the refresh operation in one or more indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/availability-and-recovery/remote-store/index/#refresh-level-and-request-level-durability +type IndicesRefreshPath struct { + Index []string +} + +func (p IndicesRefreshPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_refresh") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesResolveIndexPath (indices.resolve_index) +// --------------------------------------------------------------------------- + +// IndicesResolveIndexPath builds URL paths for the indices.resolve_index operation. +// +// Returns information about any matching indexes, aliases, and data streams. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesResolveIndexPath struct { + Name []string +} + +func (p IndicesResolveIndexPath) Build() (string, error) { + if !hasNonEmpty(p.Name) { + return "", fmt.Errorf("IndicesResolveIndexPath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_resolve") + pb.writeLit("index") + writeSegments(pb, p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesRolloverPath (indices.rollover) +// --------------------------------------------------------------------------- + +// IndicesRolloverPath builds URL paths for the indices.rollover operation. +// +// Updates an alias to point to a new index when the existing index +// is considered to be too large or too old. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/dashboards/im-dashboards/rollover/ +type IndicesRolloverPath struct { + Alias string + NewIndex string +} + +func (p IndicesRolloverPath) Build() (string, error) { + if p.Alias == "" { + return "", fmt.Errorf("IndicesRolloverPath.Alias: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Alias) + pb.writeLit("_rollover") + if p.NewIndex != "" { + pb.writeReq(p.NewIndex) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesSegmentsPath (indices.segments) +// --------------------------------------------------------------------------- + +// IndicesSegmentsPath builds URL paths for the indices.segments operation. +// +// Provides low-level information about segments in a Lucene index. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest +type IndicesSegmentsPath struct { + Index []string +} + +func (p IndicesSegmentsPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_segments") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesShardStoresPath (indices.shard_stores) +// --------------------------------------------------------------------------- + +// IndicesShardStoresPath builds URL paths for the indices.shard_stores operation. +// +// Provides store information for shard copies of indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesShardStoresPath struct { + Index []string +} + +func (p IndicesShardStoresPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_shard_stores") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesShrinkPath (indices.shrink) +// --------------------------------------------------------------------------- + +// IndicesShrinkPath builds URL paths for the indices.shrink operation. +// +// Allow to shrink an existing index into a new index with fewer primary shards. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/shrink-index/ +type IndicesShrinkPath struct { + Index string + Target string +} + +func (p IndicesShrinkPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("IndicesShrinkPath.Index: %w", errRequired) + } + if p.Target == "" { + return "", fmt.Errorf("IndicesShrinkPath.Target: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_shrink") + pb.writeReq(p.Target) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesSimulateIndexTemplatePath (indices.simulate_index_template) +// --------------------------------------------------------------------------- + +// IndicesSimulateIndexTemplatePath builds URL paths for the indices.simulate_index_template operation. +// +// Simulate matching the given index name against the index templates in the system. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesSimulateIndexTemplatePath struct { + Name string +} + +func (p IndicesSimulateIndexTemplatePath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("IndicesSimulateIndexTemplatePath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_index_template") + pb.writeLit("_simulate_index") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesSimulateTemplatePath (indices.simulate_template) +// --------------------------------------------------------------------------- + +// IndicesSimulateTemplatePath builds URL paths for the indices.simulate_template operation. +// +// Simulate resolving the given template name or body. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesSimulateTemplatePath struct { + Name string +} + +func (p IndicesSimulateTemplatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_index_template") + pb.writeLit("_simulate") + if p.Name != "" { + pb.writeReq(p.Name) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesSplitPath (indices.split) +// --------------------------------------------------------------------------- + +// IndicesSplitPath builds URL paths for the indices.split operation. +// +// Allows you to split an existing index into a new index with more primary shards. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/split/ +type IndicesSplitPath struct { + Index string + Target string +} + +func (p IndicesSplitPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("IndicesSplitPath.Index: %w", errRequired) + } + if p.Target == "" { + return "", fmt.Errorf("IndicesSplitPath.Target: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_split") + pb.writeReq(p.Target) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesStatsPath (indices.stats) +// --------------------------------------------------------------------------- + +// IndicesStatsPath builds URL paths for the indices.stats operation. +// +// Provides statistics on operations happening in an index. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesStatsPath struct { + Index []string + Metric []string +} + +func (p IndicesStatsPath) Build() (string, error) { + pb := acquire() + switch { + case hasNonEmpty(p.Index) && hasNonEmpty(p.Metric): + writeSegments(pb, p.Index) + pb.writeLit("_stats") + writeSegments(pb, p.Metric) + case hasNonEmpty(p.Index): + writeSegments(pb, p.Index) + pb.writeLit("_stats") + case hasNonEmpty(p.Metric): + pb.writeLit("_stats") + writeSegments(pb, p.Metric) + default: + pb.writeLit("_stats") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesUpdateAliasesPath (indices.update_aliases) +// --------------------------------------------------------------------------- + +// IndicesUpdateAliasesPath builds URL paths for the indices.update_aliases operation. +// +// Updates index aliases. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/index-apis/alias/ +type IndicesUpdateAliasesPath struct { +} + +func (p IndicesUpdateAliasesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_aliases") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesUpgradePath (indices.upgrade) +// --------------------------------------------------------------------------- + +// IndicesUpgradePath builds URL paths for the indices.upgrade operation. +// +// The `_upgrade` API is no longer useful and will be removed. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesUpgradePath struct { + Index []string +} + +func (p IndicesUpgradePath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_upgrade") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IndicesValidateQueryPath (indices.validate_query) +// --------------------------------------------------------------------------- + +// IndicesValidateQueryPath builds URL paths for the indices.validate_query operation. +// +// Allows a user to validate a potentially expensive query without executing it. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IndicesValidateQueryPath struct { + Index []string +} + +func (p IndicesValidateQueryPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_validate") + pb.writeLit("query") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// InfoPath (info) +// --------------------------------------------------------------------------- + +// InfoPath builds URL paths for the info operation. +// +// Returns basic information about the cluster. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-serverless. +// +// See: https://opensearch.org/docs/latest +type InfoPath struct { +} + +func (p InfoPath) Build() (string, error) { + return "/", nil +} + +// --------------------------------------------------------------------------- +// IngestDeletePipelinePath (ingest.delete_pipeline) +// --------------------------------------------------------------------------- + +// IngestDeletePipelinePath builds URL paths for the ingest.delete_pipeline operation. +// +// Deletes an ingest pipeline. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/ingest-apis/delete-ingest/ +type IngestDeletePipelinePath struct { + ID string +} + +func (p IngestDeletePipelinePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("IngestDeletePipelinePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ingest") + pb.writeLit("pipeline") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IngestGetPipelinePath (ingest.get_pipeline) +// --------------------------------------------------------------------------- + +// IngestGetPipelinePath builds URL paths for the ingest.get_pipeline operation. +// +// Returns an ingest pipeline. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/ingest-apis/get-ingest/ +type IngestGetPipelinePath struct { + ID string +} + +func (p IngestGetPipelinePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ingest") + pb.writeLit("pipeline") + if p.ID != "" { + pb.writeReq(p.ID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IngestProcessorGrokPath (ingest.processor_grok) +// --------------------------------------------------------------------------- + +// IngestProcessorGrokPath builds URL paths for the ingest.processor_grok operation. +// +// Returns a list of built-in grok patterns. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type IngestProcessorGrokPath struct { +} + +func (p IngestProcessorGrokPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ingest") + pb.writeLit("processor") + pb.writeLit("grok") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IngestPutPipelinePath (ingest.put_pipeline) +// --------------------------------------------------------------------------- + +// IngestPutPipelinePath builds URL paths for the ingest.put_pipeline operation. +// +// Creates or updates an ingest pipeline. +// +// Available: >= 1.0.0 +// +// See: https://docs.opensearch.org/latest/ingest-pipelines/create-ingest/ +type IngestPutPipelinePath struct { + ID string +} + +func (p IngestPutPipelinePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("IngestPutPipelinePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ingest") + pb.writeLit("pipeline") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IngestSimulatePath (ingest.simulate) +// --------------------------------------------------------------------------- + +// IngestSimulatePath builds URL paths for the ingest.simulate operation. +// +// Simulates an ingest pipeline with example documents. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/ingest-apis/simulate-ingest/ +type IngestSimulatePath struct { + ID string +} + +func (p IngestSimulatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ingest") + pb.writeLit("pipeline") + if p.ID != "" { + pb.writeReq(p.ID) + } + pb.writeLit("_simulate") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IngestionGetStatePath (ingestion.get_state) +// --------------------------------------------------------------------------- + +// IngestionGetStatePath builds URL paths for the ingestion.get_state operation. +// +// Use this API to retrieve the ingestion state for a given index. +// +// Available: >= 3.1.0 +// +// See: https://docs.opensearch.org/docs/latest/api-reference/document-apis/pull-based-ingestion-management/ +type IngestionGetStatePath struct { + Index string +} + +func (p IngestionGetStatePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("IngestionGetStatePath.Index: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("ingestion") + pb.writeLit("_state") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IngestionPausePath (ingestion.pause) +// --------------------------------------------------------------------------- + +// IngestionPausePath builds URL paths for the ingestion.pause operation. +// +// Use this API to pause ingestion for a given index. +// +// Available: >= 3.1.0 +// +// See: https://docs.opensearch.org/docs/latest/api-reference/document-apis/pull-based-ingestion-management/ +type IngestionPausePath struct { + Index string +} + +func (p IngestionPausePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("IngestionPausePath.Index: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("ingestion") + pb.writeLit("_pause") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IngestionResumePath (ingestion.resume) +// --------------------------------------------------------------------------- + +// IngestionResumePath builds URL paths for the ingestion.resume operation. +// +// Use this API to resume ingestion for the given index. +// +// Available: >= 3.1.0 +// +// See: https://docs.opensearch.org/docs/latest/api-reference/document-apis/pull-based-ingestion-management/ +type IngestionResumePath struct { + Index string +} + +func (p IngestionResumePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("IngestionResumePath.Index: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("ingestion") + pb.writeLit("_resume") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// InsightsTopQueriesPath (insights.top_queries) +// --------------------------------------------------------------------------- + +// InsightsTopQueriesPath builds URL paths for the insights.top_queries operation. +// +// Retrieves the top queries based on the given metric type (latency, CPU, or memory). +// +// Available: >= 1.0.0 +type InsightsTopQueriesPath struct { +} + +func (p InsightsTopQueriesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_insights") + pb.writeLit("top_queries") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmAddPolicyPath (ism.add_policy) +// --------------------------------------------------------------------------- + +// IsmAddPolicyPath builds URL paths for the ism.add_policy operation. +// +// Adds a policy to an index. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#add-policy +type IsmAddPolicyPath struct { + Index []string +} + +func (p IsmAddPolicyPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("add") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmChangePolicyPath (ism.change_policy) +// --------------------------------------------------------------------------- + +// IsmChangePolicyPath builds URL paths for the ism.change_policy operation. +// +// Updates the managed index policy to a new policy. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#update-managed-index-policy +type IsmChangePolicyPath struct { + Index []string +} + +func (p IsmChangePolicyPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("change_policy") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmDeletePolicyPath (ism.delete_policy) +// --------------------------------------------------------------------------- + +// IsmDeletePolicyPath builds URL paths for the ism.delete_policy operation. +// +// Deletes a policy. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#delete-policy +type IsmDeletePolicyPath struct { + PolicyID string +} + +func (p IsmDeletePolicyPath) Build() (string, error) { + if p.PolicyID == "" { + return "", fmt.Errorf("IsmDeletePolicyPath.PolicyID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("policies") + pb.writeReq(p.PolicyID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmExistsPolicyPath (ism.exists_policy) +// --------------------------------------------------------------------------- + +// IsmExistsPolicyPath builds URL paths for the ism.exists_policy operation. +// +// Checks for the existence of a policy. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#get-policy +type IsmExistsPolicyPath struct { + PolicyID string +} + +func (p IsmExistsPolicyPath) Build() (string, error) { + if p.PolicyID == "" { + return "", fmt.Errorf("IsmExistsPolicyPath.PolicyID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("policies") + pb.writeReq(p.PolicyID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmExplainPolicyPath (ism.explain_policy) +// --------------------------------------------------------------------------- + +// IsmExplainPolicyPath builds URL paths for the ism.explain_policy operation. +// +// Retrieves the currently applied policy on the specified indexes. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index +type IsmExplainPolicyPath struct { + Index []string +} + +func (p IsmExplainPolicyPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("explain") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmGetPoliciesPath (ism.get_policies) +// --------------------------------------------------------------------------- + +// IsmGetPoliciesPath builds URL paths for the ism.get_policies operation. +// +// Retrieves the policies. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#get-policy +type IsmGetPoliciesPath struct { +} + +func (p IsmGetPoliciesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("policies") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmGetPolicyPath (ism.get_policy) +// --------------------------------------------------------------------------- + +// IsmGetPolicyPath builds URL paths for the ism.get_policy operation. +// +// Retrieves a specific policy. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#put-policy +type IsmGetPolicyPath struct { + PolicyID string +} + +func (p IsmGetPolicyPath) Build() (string, error) { + if p.PolicyID == "" { + return "", fmt.Errorf("IsmGetPolicyPath.PolicyID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("policies") + pb.writeReq(p.PolicyID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmPutPoliciesPath (ism.put_policies) +// --------------------------------------------------------------------------- + +// IsmPutPoliciesPath builds URL paths for the ism.put_policies operation. +// +// Creates or updates policies. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#create-policy +type IsmPutPoliciesPath struct { +} + +func (p IsmPutPoliciesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("policies") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmPutPolicyPath (ism.put_policy) +// --------------------------------------------------------------------------- + +// IsmPutPolicyPath builds URL paths for the ism.put_policy operation. +// +// Creates or updates a policy. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#create-policy +type IsmPutPolicyPath struct { + PolicyID string +} + +func (p IsmPutPolicyPath) Build() (string, error) { + if p.PolicyID == "" { + return "", fmt.Errorf("IsmPutPolicyPath.PolicyID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("policies") + pb.writeReq(p.PolicyID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmRefreshSearchAnalyzersPath (ism.refresh_search_analyzers) +// --------------------------------------------------------------------------- + +// IsmRefreshSearchAnalyzersPath builds URL paths for the ism.refresh_search_analyzers operation. +// +// Refreshes search analyzers in real time. +// +// See: https://opensearch.org/docs/latest/im-plugin/refresh-analyzer/ +type IsmRefreshSearchAnalyzersPath struct { + Index []string +} + +func (p IsmRefreshSearchAnalyzersPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("IsmRefreshSearchAnalyzersPath.Index: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_refresh_search_analyzers") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmRemovePolicyPath (ism.remove_policy) +// --------------------------------------------------------------------------- + +// IsmRemovePolicyPath builds URL paths for the ism.remove_policy operation. +// +// Removes a policy from an index. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#remove-policy +type IsmRemovePolicyPath struct { + Index []string +} + +func (p IsmRemovePolicyPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("remove") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// IsmRetryIndexPath (ism.retry_index) +// --------------------------------------------------------------------------- + +// IsmRetryIndexPath builds URL paths for the ism.retry_index operation. +// +// Retries the failed action for an index. +// +// See: https://opensearch.org/docs/latest/im-plugin/ism/api/#retry-failed-index +type IsmRetryIndexPath struct { + Index []string +} + +func (p IsmRetryIndexPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ism") + pb.writeLit("retry") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// KnnDeleteModelPath (knn.delete_model) +// --------------------------------------------------------------------------- + +// KnnDeleteModelPath builds URL paths for the knn.delete_model operation. +// +// Used to delete a particular model in the cluster. +// +// Available: >= 1.0.0 +// +// See: https://docs.opensearch.org/latest/vector-search/api/knn/#delete-a-model +type KnnDeleteModelPath struct { + ModelID string +} + +func (p KnnDeleteModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("KnnDeleteModelPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_knn") + pb.writeLit("models") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// KnnGetModelPath (knn.get_model) +// --------------------------------------------------------------------------- + +// KnnGetModelPath builds URL paths for the knn.get_model operation. +// +// Used to retrieve information about models present in the cluster. +// +// Available: >= 1.0.0 +// +// See: https://docs.opensearch.org/latest/vector-search/api/knn/#get-a-model +type KnnGetModelPath struct { + ModelID string +} + +func (p KnnGetModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("KnnGetModelPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_knn") + pb.writeLit("models") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// KnnSearchModelsPath (knn.search_models) +// --------------------------------------------------------------------------- + +// KnnSearchModelsPath builds URL paths for the knn.search_models operation. +// +// Use an OpenSearch query to search for models in the index. +// +// Available: >= 1.0.0 +// +// See: https://docs.opensearch.org/latest/vector-search/api/knn/#search-for-a-model +type KnnSearchModelsPath struct { +} + +func (p KnnSearchModelsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_knn") + pb.writeLit("models") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// KnnStatsPath (knn.stats) +// --------------------------------------------------------------------------- + +// KnnStatsPath builds URL paths for the knn.stats operation. +// +// Provides information about the current status of the k-NN plugin. +// +// Available: >= 1.0.0 +// +// See: https://docs.opensearch.org/latest/vector-search/api/knn/#stats +type KnnStatsPath struct { + NodeID []string + Stat []string +} + +func (p KnnStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_knn") + switch { + case hasNonEmpty(p.NodeID) && hasNonEmpty(p.Stat): + writeSegments(pb, p.NodeID) + pb.writeLit("stats") + writeSegments(pb, p.Stat) + case hasNonEmpty(p.NodeID): + writeSegments(pb, p.NodeID) + pb.writeLit("stats") + case hasNonEmpty(p.Stat): + pb.writeLit("stats") + writeSegments(pb, p.Stat) + default: + pb.writeLit("stats") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// KnnTrainModelPath (knn.train_model) +// --------------------------------------------------------------------------- + +// KnnTrainModelPath builds URL paths for the knn.train_model operation. +// +// Create and train a model that can be used for initializing k-NN native library indexes during indexing. +// +// Available: >= 1.0.0 +// +// See: https://docs.opensearch.org/latest/vector-search/api/knn/#train-a-model +type KnnTrainModelPath struct { + ModelID string +} + +func (p KnnTrainModelPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_knn") + pb.writeLit("models") + if p.ModelID != "" { + pb.writeReq(p.ModelID) + } + pb.writeLit("_train") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// KnnWarmupPath (knn.warmup) +// --------------------------------------------------------------------------- + +// KnnWarmupPath builds URL paths for the knn.warmup operation. +// +// Preloads native library files into memory, reducing initial search latency for specified indexes. +// +// Available: >= 1.0.0 +// +// See: https://docs.opensearch.org/latest/vector-search/api/knn/#warmup-operation +type KnnWarmupPath struct { + Index []string +} + +func (p KnnWarmupPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("KnnWarmupPath.Index: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_knn") + pb.writeLit("warmup") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ListHelpPath (list.help) +// --------------------------------------------------------------------------- + +// ListHelpPath builds URL paths for the list.help operation. +// +// Returns help for the List APIs. +// +// Available: >= 2.18.0 +// +// See: https://opensearch.org/docs/latest/api-reference/list/index/ +type ListHelpPath struct { +} + +func (p ListHelpPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_list") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ListIndicesPath (list.indices) +// --------------------------------------------------------------------------- + +// ListIndicesPath builds URL paths for the list.indices operation. +// +// Returns paginated information about indexes including number of primaries and replicas, document counts, disk size. +// +// Available: >= 2.18.0 +// +// See: https://opensearch.org/docs/latest/api-reference/list/list-indices/ +type ListIndicesPath struct { + Index []string +} + +func (p ListIndicesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_list") + pb.writeLit("indices") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ListShardsPath (list.shards) +// --------------------------------------------------------------------------- + +// ListShardsPath builds URL paths for the list.shards operation. +// +// Returns paginated details of shard allocation on nodes. +// +// Available: >= 2.18.0 +// +// See: https://opensearch.org/docs/latest/api-reference/list/list-shards/ +type ListShardsPath struct { + Index []string +} + +func (p ListShardsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_list") + pb.writeLit("shards") + writeSegments(pb, p.Index) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrAddFeaturesToSetPath (ltr.add_features_to_set) +// --------------------------------------------------------------------------- + +// LtrAddFeaturesToSetPath builds URL paths for the ltr.add_features_to_set operation. +// +// Add features to an existing feature set in the default feature store. +// +// Available: >= 2.19.0 +type LtrAddFeaturesToSetPath struct { + Store string + Name string +} + +func (p LtrAddFeaturesToSetPath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("LtrAddFeaturesToSetPath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_featureset") + pb.writeReq(p.Name) + pb.writeLit("_addfeatures") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrAddFeaturesToSetByQueryPath (ltr.add_features_to_set_by_query) +// --------------------------------------------------------------------------- + +// LtrAddFeaturesToSetByQueryPath builds URL paths for the ltr.add_features_to_set_by_query operation. +// +// Add features to an existing feature set in the default feature store. +// +// Available: >= 2.19.0 +type LtrAddFeaturesToSetByQueryPath struct { + Store string + Name string + Query string +} + +func (p LtrAddFeaturesToSetByQueryPath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("LtrAddFeaturesToSetByQueryPath.Name: %w", errRequired) + } + if p.Query == "" { + return "", fmt.Errorf("LtrAddFeaturesToSetByQueryPath.Query: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_featureset") + pb.writeReq(p.Name) + pb.writeLit("_addfeatures") + pb.writeReq(p.Query) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrCacheStatsPath (ltr.cache_stats) +// --------------------------------------------------------------------------- + +// LtrCacheStatsPath builds URL paths for the ltr.cache_stats operation. +// +// Retrieves cache statistics for all feature stores. +// +// Available: >= 2.19.0 +type LtrCacheStatsPath struct { +} + +func (p LtrCacheStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ltr") + pb.writeLit("_cachestats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrClearCachePath (ltr.clear_cache) +// --------------------------------------------------------------------------- + +// LtrClearCachePath builds URL paths for the ltr.clear_cache operation. +// +// Clears the store caches. +// +// Available: >= 2.19.0 +type LtrClearCachePath struct { + Store string +} + +func (p LtrClearCachePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_clearcache") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrCreateDefaultStorePath (ltr.create_default_store) +// --------------------------------------------------------------------------- + +// LtrCreateDefaultStorePath builds URL paths for the ltr.create_default_store operation. +// +// Creates the default feature store. +// +// Available: >= 2.17.1 +type LtrCreateDefaultStorePath struct { +} + +func (p LtrCreateDefaultStorePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ltr") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrCreateFeaturePath (ltr.create_feature) +// --------------------------------------------------------------------------- + +// LtrCreateFeaturePath builds URL paths for the ltr.create_feature operation. +// +// Create or update a feature in the default feature store. +// +// Available: >= 2.19.0 +type LtrCreateFeaturePath struct { + Store string + ID string +} + +func (p LtrCreateFeaturePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrCreateFeaturePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_feature") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrCreateFeaturesetPath (ltr.create_featureset) +// --------------------------------------------------------------------------- + +// LtrCreateFeaturesetPath builds URL paths for the ltr.create_featureset operation. +// +// Create or update a feature set in the default feature store. +// +// Available: >= 2.19.0 +type LtrCreateFeaturesetPath struct { + Store string + ID string +} + +func (p LtrCreateFeaturesetPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrCreateFeaturesetPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_featureset") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrCreateModelPath (ltr.create_model) +// --------------------------------------------------------------------------- + +// LtrCreateModelPath builds URL paths for the ltr.create_model operation. +// +// Create or update a model in the default feature store. +// +// Available: >= 2.19.0 +type LtrCreateModelPath struct { + Store string + ID string +} + +func (p LtrCreateModelPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrCreateModelPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_model") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrCreateModelFromSetPath (ltr.create_model_from_set) +// --------------------------------------------------------------------------- + +// LtrCreateModelFromSetPath builds URL paths for the ltr.create_model_from_set operation. +// +// Create a model from an existing feature set in the default feature store. +// +// Available: >= 2.19.0 +type LtrCreateModelFromSetPath struct { + Store string + Name string +} + +func (p LtrCreateModelFromSetPath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("LtrCreateModelFromSetPath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_featureset") + pb.writeReq(p.Name) + pb.writeLit("_createmodel") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrCreateStorePath (ltr.create_store) +// --------------------------------------------------------------------------- + +// LtrCreateStorePath builds URL paths for the ltr.create_store operation. +// +// Creates a new feature store with the specified name. +// +// Available: >= 2.17.1 +type LtrCreateStorePath struct { + Store string +} + +func (p LtrCreateStorePath) Build() (string, error) { + if p.Store == "" { + return "", fmt.Errorf("LtrCreateStorePath.Store: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + pb.writeReq(p.Store) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrDeleteDefaultStorePath (ltr.delete_default_store) +// --------------------------------------------------------------------------- + +// LtrDeleteDefaultStorePath builds URL paths for the ltr.delete_default_store operation. +// +// Deletes the default feature store. +// +// Available: >= 2.17.1 +type LtrDeleteDefaultStorePath struct { +} + +func (p LtrDeleteDefaultStorePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ltr") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrDeleteFeaturePath (ltr.delete_feature) +// --------------------------------------------------------------------------- + +// LtrDeleteFeaturePath builds URL paths for the ltr.delete_feature operation. +// +// Delete a feature from the default feature store. +// +// Available: >= 2.19.0 +type LtrDeleteFeaturePath struct { + Store string + ID string +} + +func (p LtrDeleteFeaturePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrDeleteFeaturePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_feature") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrDeleteFeaturesetPath (ltr.delete_featureset) +// --------------------------------------------------------------------------- + +// LtrDeleteFeaturesetPath builds URL paths for the ltr.delete_featureset operation. +// +// Delete a feature set from the default feature store. +// +// Available: >= 2.19.0 +type LtrDeleteFeaturesetPath struct { + Store string + ID string +} + +func (p LtrDeleteFeaturesetPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrDeleteFeaturesetPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_featureset") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrDeleteModelPath (ltr.delete_model) +// --------------------------------------------------------------------------- + +// LtrDeleteModelPath builds URL paths for the ltr.delete_model operation. +// +// Delete a model from the default feature store. +// +// Available: >= 2.19.0 +type LtrDeleteModelPath struct { + Store string + ID string +} + +func (p LtrDeleteModelPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrDeleteModelPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_model") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrDeleteStorePath (ltr.delete_store) +// --------------------------------------------------------------------------- + +// LtrDeleteStorePath builds URL paths for the ltr.delete_store operation. +// +// Deletes a feature store with the specified name. +// +// Available: >= 2.17.1 +type LtrDeleteStorePath struct { + Store string +} + +func (p LtrDeleteStorePath) Build() (string, error) { + if p.Store == "" { + return "", fmt.Errorf("LtrDeleteStorePath.Store: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + pb.writeReq(p.Store) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrGetFeaturePath (ltr.get_feature) +// --------------------------------------------------------------------------- + +// LtrGetFeaturePath builds URL paths for the ltr.get_feature operation. +// +// Get a feature from the default feature store. +// +// Available: >= 2.19.0 +type LtrGetFeaturePath struct { + Store string + ID string +} + +func (p LtrGetFeaturePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrGetFeaturePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_feature") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrGetFeaturesetPath (ltr.get_featureset) +// --------------------------------------------------------------------------- + +// LtrGetFeaturesetPath builds URL paths for the ltr.get_featureset operation. +// +// Get a feature set from the default feature store. +// +// Available: >= 2.19.0 +type LtrGetFeaturesetPath struct { + Store string + ID string +} + +func (p LtrGetFeaturesetPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrGetFeaturesetPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_featureset") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrGetModelPath (ltr.get_model) +// --------------------------------------------------------------------------- + +// LtrGetModelPath builds URL paths for the ltr.get_model operation. +// +// Get a model from the default feature store. +// +// Available: >= 2.19.0 +type LtrGetModelPath struct { + Store string + ID string +} + +func (p LtrGetModelPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrGetModelPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_model") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrGetStorePath (ltr.get_store) +// --------------------------------------------------------------------------- + +// LtrGetStorePath builds URL paths for the ltr.get_store operation. +// +// Checks if a store exists. +// +// Available: >= 2.17.1 +type LtrGetStorePath struct { + Store string +} + +func (p LtrGetStorePath) Build() (string, error) { + if p.Store == "" { + return "", fmt.Errorf("LtrGetStorePath.Store: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + pb.writeReq(p.Store) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrListStoresPath (ltr.list_stores) +// --------------------------------------------------------------------------- + +// LtrListStoresPath builds URL paths for the ltr.list_stores operation. +// +// Lists all available feature stores. +// +// Available: >= 2.17.1 +type LtrListStoresPath struct { +} + +func (p LtrListStoresPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ltr") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrSearchFeaturesPath (ltr.search_features) +// --------------------------------------------------------------------------- + +// LtrSearchFeaturesPath builds URL paths for the ltr.search_features operation. +// +// Search for features in a feature store. +// +// Available: >= 2.19.0 +type LtrSearchFeaturesPath struct { + Store string +} + +func (p LtrSearchFeaturesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_feature") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrSearchFeaturesetsPath (ltr.search_featuresets) +// --------------------------------------------------------------------------- + +// LtrSearchFeaturesetsPath builds URL paths for the ltr.search_featuresets operation. +// +// Search for feature sets in a feature store. +// +// Available: >= 2.19.0 +type LtrSearchFeaturesetsPath struct { + Store string +} + +func (p LtrSearchFeaturesetsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_featureset") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrSearchModelsPath (ltr.search_models) +// --------------------------------------------------------------------------- + +// LtrSearchModelsPath builds URL paths for the ltr.search_models operation. +// +// Search for models in a feature store. +// +// Available: >= 2.19.0 +type LtrSearchModelsPath struct { + Store string +} + +func (p LtrSearchModelsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_model") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrStatsPath (ltr.stats) +// --------------------------------------------------------------------------- + +// LtrStatsPath builds URL paths for the ltr.stats operation. +// +// Provides information about the current status of the LTR plugin. +// +// Available: >= 2.19.0 +type LtrStatsPath struct { + NodeID []string + Stat []string +} + +func (p LtrStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ltr") + switch { + case hasNonEmpty(p.NodeID) && hasNonEmpty(p.Stat): + writeSegments(pb, p.NodeID) + pb.writeLit("stats") + writeSegments(pb, p.Stat) + case hasNonEmpty(p.NodeID): + writeSegments(pb, p.NodeID) + pb.writeLit("stats") + case hasNonEmpty(p.Stat): + pb.writeLit("stats") + writeSegments(pb, p.Stat) + default: + pb.writeLit("stats") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrUpdateFeaturePath (ltr.update_feature) +// --------------------------------------------------------------------------- + +// LtrUpdateFeaturePath builds URL paths for the ltr.update_feature operation. +// +// Update a feature in the default feature store. +// +// Available: >= 2.19.0 +type LtrUpdateFeaturePath struct { + Store string + ID string +} + +func (p LtrUpdateFeaturePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrUpdateFeaturePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_feature") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// LtrUpdateFeaturesetPath (ltr.update_featureset) +// --------------------------------------------------------------------------- + +// LtrUpdateFeaturesetPath builds URL paths for the ltr.update_featureset operation. +// +// Update a feature set in the default feature store. +// +// Available: >= 2.19.0 +type LtrUpdateFeaturesetPath struct { + Store string + ID string +} + +func (p LtrUpdateFeaturesetPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("LtrUpdateFeaturesetPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_ltr") + if p.Store != "" { + pb.writeReq(p.Store) + } + pb.writeLit("_featureset") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MgetPath (mget) +// --------------------------------------------------------------------------- + +// MgetPath builds URL paths for the mget operation. +// +// Allows to get multiple documents in one request. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/multi-get/ +type MgetPath struct { + Index string +} + +func (p MgetPath) Build() (string, error) { + pb := acquire() + if p.Index != "" { + pb.writeReq(p.Index) + } + pb.writeLit("_mget") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlAddAgenticMemoryPath (ml.add_agentic_memory) +// --------------------------------------------------------------------------- + +// MlAddAgenticMemoryPath builds URL paths for the ml.add_agentic_memory operation. +// +// Add agentic memory to a memory container. +// +// Available: >= 3.3.0 +type MlAddAgenticMemoryPath struct { + MemoryContainerID string +} + +func (p MlAddAgenticMemoryPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlAddAgenticMemoryPath.MemoryContainerID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + pb.writeLit("memories") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlChunkModelPath (ml.chunk_model) +// --------------------------------------------------------------------------- + +// MlChunkModelPath builds URL paths for the ml.chunk_model operation. +// +// Uploads model chunk. +// +// Deprecated: >= 2.7.0. Use `upload_chunk` instead. +type MlChunkModelPath struct { + ModelID string + ChunkNumber string +} + +func (p MlChunkModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlChunkModelPath.ModelID: %w", errRequired) + } + if p.ChunkNumber == "" { + return "", fmt.Errorf("MlChunkModelPath.ChunkNumber: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + pb.writeLit("chunk") + pb.writeReq(p.ChunkNumber) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlCreateConnectorPath (ml.create_connector) +// --------------------------------------------------------------------------- + +// MlCreateConnectorPath builds URL paths for the ml.create_connector operation. +// +// Creates a standalone connector. +type MlCreateConnectorPath struct { +} + +func (p MlCreateConnectorPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("connectors") + pb.writeLit("_create") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlCreateControllerPath (ml.create_controller) +// --------------------------------------------------------------------------- + +// MlCreateControllerPath builds URL paths for the ml.create_controller operation. +// +// Creates a controller. +// +// Available: >= 2.12.0 +type MlCreateControllerPath struct { + ModelID string +} + +func (p MlCreateControllerPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlCreateControllerPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("controllers") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlCreateMemoryPath (ml.create_memory) +// --------------------------------------------------------------------------- + +// MlCreateMemoryPath builds URL paths for the ml.create_memory operation. +// +// Create a memory. +// +// Available: >= 2.12.0 +type MlCreateMemoryPath struct { +} + +func (p MlCreateMemoryPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlCreateMemoryContainerPath (ml.create_memory_container) +// --------------------------------------------------------------------------- + +// MlCreateMemoryContainerPath builds URL paths for the ml.create_memory_container operation. +// +// Create a memory container. +// +// Available: >= 3.3.0 +type MlCreateMemoryContainerPath struct { +} + +func (p MlCreateMemoryContainerPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeLit("_create") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlCreateMemoryContainerSessionPath (ml.create_memory_container_session) +// --------------------------------------------------------------------------- + +// MlCreateMemoryContainerSessionPath builds URL paths for the ml.create_memory_container_session operation. +// +// Create session in a memory container. +// +// Available: >= 3.3.0 +type MlCreateMemoryContainerSessionPath struct { + MemoryContainerID string +} + +func (p MlCreateMemoryContainerSessionPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlCreateMemoryContainerSessionPath.MemoryContainerID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + pb.writeLit("memories") + pb.writeLit("sessions") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlCreateMessagePath (ml.create_message) +// --------------------------------------------------------------------------- + +// MlCreateMessagePath builds URL paths for the ml.create_message operation. +// +// Create a message. +// +// Available: >= 2.12.0 +type MlCreateMessagePath struct { + MemoryID string +} + +func (p MlCreateMessagePath) Build() (string, error) { + if p.MemoryID == "" { + return "", fmt.Errorf("MlCreateMessagePath.MemoryID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeReq(p.MemoryID) + pb.writeLit("messages") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlCreateModelMetaPath (ml.create_model_meta) +// --------------------------------------------------------------------------- + +// MlCreateModelMetaPath builds URL paths for the ml.create_model_meta operation. +// +// Registers model metadata. +// +// Deprecated: >= 2.7.0. Use `_register_meta` instead. +type MlCreateModelMetaPath struct { +} + +func (p MlCreateModelMetaPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeLit("meta") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteAgentPath (ml.delete_agent) +// --------------------------------------------------------------------------- + +// MlDeleteAgentPath builds URL paths for the ml.delete_agent operation. +// +// Delete an agent. +// +// Available: >= 2.13.0 +type MlDeleteAgentPath struct { + AgentID string +} + +func (p MlDeleteAgentPath) Build() (string, error) { + if p.AgentID == "" { + return "", fmt.Errorf("MlDeleteAgentPath.AgentID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("agents") + pb.writeReq(p.AgentID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteAgenticMemoryPath (ml.delete_agentic_memory) +// --------------------------------------------------------------------------- + +// MlDeleteAgenticMemoryPath builds URL paths for the ml.delete_agentic_memory operation. +// +// Delete a specific memory by its type and ID. +// +// Available: >= 3.3.0 +type MlDeleteAgenticMemoryPath struct { + MemoryContainerID string + Type string + ID string +} + +func (p MlDeleteAgenticMemoryPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlDeleteAgenticMemoryPath.MemoryContainerID: %w", errRequired) + } + if p.Type == "" { + return "", fmt.Errorf("MlDeleteAgenticMemoryPath.Type: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("MlDeleteAgenticMemoryPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + pb.writeLit("memories") + pb.writeReq(p.Type) + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteAgenticMemoryQueryPath (ml.delete_agentic_memory_query) +// --------------------------------------------------------------------------- + +// MlDeleteAgenticMemoryQueryPath builds URL paths for the ml.delete_agentic_memory_query operation. +// +// Delete multiple memories using a query to match specific criteria. +// +// Available: >= 3.3.0 +type MlDeleteAgenticMemoryQueryPath struct { + MemoryContainerID string + Type string +} + +func (p MlDeleteAgenticMemoryQueryPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlDeleteAgenticMemoryQueryPath.MemoryContainerID: %w", errRequired) + } + if p.Type == "" { + return "", fmt.Errorf("MlDeleteAgenticMemoryQueryPath.Type: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + pb.writeLit("memories") + pb.writeReq(p.Type) + pb.writeLit("_delete_by_query") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteConnectorPath (ml.delete_connector) +// --------------------------------------------------------------------------- + +// MlDeleteConnectorPath builds URL paths for the ml.delete_connector operation. +// +// Deletes a standalone connector. +type MlDeleteConnectorPath struct { + ConnectorID string +} + +func (p MlDeleteConnectorPath) Build() (string, error) { + if p.ConnectorID == "" { + return "", fmt.Errorf("MlDeleteConnectorPath.ConnectorID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("connectors") + pb.writeReq(p.ConnectorID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteControllerPath (ml.delete_controller) +// --------------------------------------------------------------------------- + +// MlDeleteControllerPath builds URL paths for the ml.delete_controller operation. +// +// Deletes a controller. +// +// Available: >= 2.12.0 +type MlDeleteControllerPath struct { + ModelID string +} + +func (p MlDeleteControllerPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlDeleteControllerPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("controllers") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteMemoryPath (ml.delete_memory) +// --------------------------------------------------------------------------- + +// MlDeleteMemoryPath builds URL paths for the ml.delete_memory operation. +// +// Delete a memory. +// +// Available: >= 2.12.0 +type MlDeleteMemoryPath struct { + MemoryID string +} + +func (p MlDeleteMemoryPath) Build() (string, error) { + if p.MemoryID == "" { + return "", fmt.Errorf("MlDeleteMemoryPath.MemoryID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeReq(p.MemoryID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteMemoryContainerPath (ml.delete_memory_container) +// --------------------------------------------------------------------------- + +// MlDeleteMemoryContainerPath builds URL paths for the ml.delete_memory_container operation. +// +// Delete a memory container. +// +// Available: >= 3.3.0 +type MlDeleteMemoryContainerPath struct { + MemoryContainerID string +} + +func (p MlDeleteMemoryContainerPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlDeleteMemoryContainerPath.MemoryContainerID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteModelPath (ml.delete_model) +// --------------------------------------------------------------------------- + +// MlDeleteModelPath builds URL paths for the ml.delete_model operation. +// +// Deletes a model. +// +// Available: >= 1.3.0 +type MlDeleteModelPath struct { + ModelID string +} + +func (p MlDeleteModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlDeleteModelPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteModelGroupPath (ml.delete_model_group) +// --------------------------------------------------------------------------- + +// MlDeleteModelGroupPath builds URL paths for the ml.delete_model_group operation. +// +// Deletes a model group. +type MlDeleteModelGroupPath struct { + ModelGroupID string +} + +func (p MlDeleteModelGroupPath) Build() (string, error) { + if p.ModelGroupID == "" { + return "", fmt.Errorf("MlDeleteModelGroupPath.ModelGroupID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("model_groups") + pb.writeReq(p.ModelGroupID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeleteTaskPath (ml.delete_task) +// --------------------------------------------------------------------------- + +// MlDeleteTaskPath builds URL paths for the ml.delete_task operation. +// +// Deletes a task. +// +// Available: >= 1.3.0 +type MlDeleteTaskPath struct { + TaskID string +} + +func (p MlDeleteTaskPath) Build() (string, error) { + if p.TaskID == "" { + return "", fmt.Errorf("MlDeleteTaskPath.TaskID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("tasks") + pb.writeReq(p.TaskID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlDeployModelPath (ml.deploy_model) +// --------------------------------------------------------------------------- + +// MlDeployModelPath builds URL paths for the ml.deploy_model operation. +// +// Deploys a model. +// +// Available: >= 2.7.0 +type MlDeployModelPath struct { + ModelID string +} + +func (p MlDeployModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlDeployModelPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + pb.writeLit("_deploy") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlExecuteAgentPath (ml.execute_agent) +// --------------------------------------------------------------------------- + +// MlExecuteAgentPath builds URL paths for the ml.execute_agent operation. +// +// Execute an agent. +// +// Available: >= 2.13.0 +type MlExecuteAgentPath struct { + AgentID string +} + +func (p MlExecuteAgentPath) Build() (string, error) { + if p.AgentID == "" { + return "", fmt.Errorf("MlExecuteAgentPath.AgentID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("agents") + pb.writeReq(p.AgentID) + pb.writeLit("_execute") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlExecuteAgentStreamPath (ml.execute_agent_stream) +// --------------------------------------------------------------------------- + +// MlExecuteAgentStreamPath builds URL paths for the ml.execute_agent_stream operation. +// +// Execute an agent in streaming mode. +// +// Available: >= 3.3.0 +type MlExecuteAgentStreamPath struct { + AgentID string +} + +func (p MlExecuteAgentStreamPath) Build() (string, error) { + if p.AgentID == "" { + return "", fmt.Errorf("MlExecuteAgentStreamPath.AgentID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("agents") + pb.writeReq(p.AgentID) + pb.writeLit("_execute") + pb.writeLit("stream") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlExecuteAlgorithmPath (ml.execute_algorithm) +// --------------------------------------------------------------------------- + +// MlExecuteAlgorithmPath builds URL paths for the ml.execute_algorithm operation. +// +// Execute an algorithm. +// +// Available: >= 2.0.0 +type MlExecuteAlgorithmPath struct { + AlgorithmName string +} + +func (p MlExecuteAlgorithmPath) Build() (string, error) { + if p.AlgorithmName == "" { + return "", fmt.Errorf("MlExecuteAlgorithmPath.AlgorithmName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("_execute") + pb.writeReq(p.AlgorithmName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlExecuteToolPath (ml.execute_tool) +// --------------------------------------------------------------------------- + +// MlExecuteToolPath builds URL paths for the ml.execute_tool operation. +// +// Execute a tool. +// +// Available: >= 3.3.0 +type MlExecuteToolPath struct { + ToolName string +} + +func (p MlExecuteToolPath) Build() (string, error) { + if p.ToolName == "" { + return "", fmt.Errorf("MlExecuteToolPath.ToolName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("tools") + pb.writeLit("_execute") + pb.writeReq(p.ToolName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetAgentPath (ml.get_agent) +// --------------------------------------------------------------------------- + +// MlGetAgentPath builds URL paths for the ml.get_agent operation. +// +// Get an agent. +// +// Available: >= 2.13.0 +type MlGetAgentPath struct { + AgentID string +} + +func (p MlGetAgentPath) Build() (string, error) { + if p.AgentID == "" { + return "", fmt.Errorf("MlGetAgentPath.AgentID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("agents") + pb.writeReq(p.AgentID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetAgenticMemoryPath (ml.get_agentic_memory) +// --------------------------------------------------------------------------- + +// MlGetAgenticMemoryPath builds URL paths for the ml.get_agentic_memory operation. +// +// Get a specific memory by its type and ID. +// +// Available: >= 3.3.0 +type MlGetAgenticMemoryPath struct { + MemoryContainerID string + Type string + ID string +} + +func (p MlGetAgenticMemoryPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlGetAgenticMemoryPath.MemoryContainerID: %w", errRequired) + } + if p.Type == "" { + return "", fmt.Errorf("MlGetAgenticMemoryPath.Type: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("MlGetAgenticMemoryPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + pb.writeLit("memories") + pb.writeReq(p.Type) + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetAllMemoriesPath (ml.get_all_memories) +// --------------------------------------------------------------------------- + +// MlGetAllMemoriesPath builds URL paths for the ml.get_all_memories operation. +// +// Get all memories. +// +// Available: >= 2.12.0 +type MlGetAllMemoriesPath struct { +} + +func (p MlGetAllMemoriesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetAllMessagesPath (ml.get_all_messages) +// --------------------------------------------------------------------------- + +// MlGetAllMessagesPath builds URL paths for the ml.get_all_messages operation. +// +// Get all messages in a memory. +// +// Available: >= 2.12.0 +type MlGetAllMessagesPath struct { + MemoryID string +} + +func (p MlGetAllMessagesPath) Build() (string, error) { + if p.MemoryID == "" { + return "", fmt.Errorf("MlGetAllMessagesPath.MemoryID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeReq(p.MemoryID) + pb.writeLit("messages") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetAllToolsPath (ml.get_all_tools) +// --------------------------------------------------------------------------- + +// MlGetAllToolsPath builds URL paths for the ml.get_all_tools operation. +// +// Get tools. +// +// Available: >= 2.12.0 +type MlGetAllToolsPath struct { +} + +func (p MlGetAllToolsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("tools") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetConnectorPath (ml.get_connector) +// --------------------------------------------------------------------------- + +// MlGetConnectorPath builds URL paths for the ml.get_connector operation. +// +// Retrieves a standalone connector. +// +// Available: >= 2.11.0 +type MlGetConnectorPath struct { + ConnectorID string +} + +func (p MlGetConnectorPath) Build() (string, error) { + if p.ConnectorID == "" { + return "", fmt.Errorf("MlGetConnectorPath.ConnectorID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("connectors") + pb.writeReq(p.ConnectorID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetControllerPath (ml.get_controller) +// --------------------------------------------------------------------------- + +// MlGetControllerPath builds URL paths for the ml.get_controller operation. +// +// Retrieves a controller. +// +// Available: >= 2.12.0 +type MlGetControllerPath struct { + ModelID string +} + +func (p MlGetControllerPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlGetControllerPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("controllers") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetMemoryPath (ml.get_memory) +// --------------------------------------------------------------------------- + +// MlGetMemoryPath builds URL paths for the ml.get_memory operation. +// +// Get a memory. +// +// Available: >= 2.12.0 +type MlGetMemoryPath struct { + MemoryID string +} + +func (p MlGetMemoryPath) Build() (string, error) { + if p.MemoryID == "" { + return "", fmt.Errorf("MlGetMemoryPath.MemoryID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeReq(p.MemoryID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetMemoryContainerPath (ml.get_memory_container) +// --------------------------------------------------------------------------- + +// MlGetMemoryContainerPath builds URL paths for the ml.get_memory_container operation. +// +// Get a memory container. +// +// Available: >= 3.3.0 +type MlGetMemoryContainerPath struct { + MemoryContainerID string +} + +func (p MlGetMemoryContainerPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlGetMemoryContainerPath.MemoryContainerID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetMessagePath (ml.get_message) +// --------------------------------------------------------------------------- + +// MlGetMessagePath builds URL paths for the ml.get_message operation. +// +// Get a message. +// +// Available: >= 2.12.0 +type MlGetMessagePath struct { + MessageID string +} + +func (p MlGetMessagePath) Build() (string, error) { + if p.MessageID == "" { + return "", fmt.Errorf("MlGetMessagePath.MessageID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeLit("message") + pb.writeReq(p.MessageID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetMessageTracesPath (ml.get_message_traces) +// --------------------------------------------------------------------------- + +// MlGetMessageTracesPath builds URL paths for the ml.get_message_traces operation. +// +// Get a message traces. +// +// Available: >= 2.12.0 +type MlGetMessageTracesPath struct { + MessageID string +} + +func (p MlGetMessageTracesPath) Build() (string, error) { + if p.MessageID == "" { + return "", fmt.Errorf("MlGetMessageTracesPath.MessageID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeLit("message") + pb.writeReq(p.MessageID) + pb.writeLit("traces") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetModelPath (ml.get_model) +// --------------------------------------------------------------------------- + +// MlGetModelPath builds URL paths for the ml.get_model operation. +// +// Retrieves a model. +// +// Available: >= 1.3.0 +type MlGetModelPath struct { + ModelID string +} + +func (p MlGetModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlGetModelPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetModelGroupPath (ml.get_model_group) +// --------------------------------------------------------------------------- + +// MlGetModelGroupPath builds URL paths for the ml.get_model_group operation. +// +// Retrieves a model group. +type MlGetModelGroupPath struct { + ModelGroupID string +} + +func (p MlGetModelGroupPath) Build() (string, error) { + if p.ModelGroupID == "" { + return "", fmt.Errorf("MlGetModelGroupPath.ModelGroupID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("model_groups") + pb.writeReq(p.ModelGroupID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetProfilePath (ml.get_profile) +// --------------------------------------------------------------------------- + +// MlGetProfilePath builds URL paths for the ml.get_profile operation. +// +// Get a profile. +// +// Available: >= 2.4.0 +type MlGetProfilePath struct { +} + +func (p MlGetProfilePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("profile") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetProfileModelsPath (ml.get_profile_models) +// --------------------------------------------------------------------------- + +// MlGetProfileModelsPath builds URL paths for the ml.get_profile_models operation. +// +// Get a profile models. +// +// Available: >= 2.4.0 +type MlGetProfileModelsPath struct { + ModelID string +} + +func (p MlGetProfileModelsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("profile") + pb.writeLit("models") + if p.ModelID != "" { + pb.writeReq(p.ModelID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetProfileTasksPath (ml.get_profile_tasks) +// --------------------------------------------------------------------------- + +// MlGetProfileTasksPath builds URL paths for the ml.get_profile_tasks operation. +// +// Get a profile tasks. +// +// Available: >= 2.4.0 +type MlGetProfileTasksPath struct { + TaskID string +} + +func (p MlGetProfileTasksPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("profile") + pb.writeLit("tasks") + if p.TaskID != "" { + pb.writeReq(p.TaskID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetStatsPath (ml.get_stats) +// --------------------------------------------------------------------------- + +// MlGetStatsPath builds URL paths for the ml.get_stats operation. +// +// Get stats. +// +// Available: >= 1.3.0 +type MlGetStatsPath struct { + NodeID string + Stat []string +} + +func (p MlGetStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + switch { + case p.NodeID != "" && hasNonEmpty(p.Stat): + pb.writeReq(p.NodeID) + pb.writeLit("stats") + writeSegments(pb, p.Stat) + case p.NodeID != "": + pb.writeReq(p.NodeID) + pb.writeLit("stats") + case hasNonEmpty(p.Stat): + pb.writeLit("stats") + writeSegments(pb, p.Stat) + default: + pb.writeLit("stats") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetTaskPath (ml.get_task) +// --------------------------------------------------------------------------- + +// MlGetTaskPath builds URL paths for the ml.get_task operation. +// +// Retrieves a task. +// +// Available: >= 1.3.0 +type MlGetTaskPath struct { + TaskID string +} + +func (p MlGetTaskPath) Build() (string, error) { + if p.TaskID == "" { + return "", fmt.Errorf("MlGetTaskPath.TaskID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("tasks") + pb.writeReq(p.TaskID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlGetToolPath (ml.get_tool) +// --------------------------------------------------------------------------- + +// MlGetToolPath builds URL paths for the ml.get_tool operation. +// +// Get tools. +// +// Available: >= 2.12.0 +type MlGetToolPath struct { + ToolName string +} + +func (p MlGetToolPath) Build() (string, error) { + if p.ToolName == "" { + return "", fmt.Errorf("MlGetToolPath.ToolName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("tools") + pb.writeReq(p.ToolName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlLoadModelPath (ml.load_model) +// --------------------------------------------------------------------------- + +// MlLoadModelPath builds URL paths for the ml.load_model operation. +// +// Deploys a model. +// +// Deprecated: >= 2.7.0. Use `deploy_model` instead. +type MlLoadModelPath struct { + ModelID string +} + +func (p MlLoadModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlLoadModelPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + pb.writeLit("_load") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlPredictPath (ml.predict) +// --------------------------------------------------------------------------- + +// MlPredictPath builds URL paths for the ml.predict operation. +// +// Predicts new data with trained model. +// +// Available: >= 1.3.0 +type MlPredictPath struct { + AlgorithmName string + ModelID string +} + +func (p MlPredictPath) Build() (string, error) { + if p.AlgorithmName == "" { + return "", fmt.Errorf("MlPredictPath.AlgorithmName: %w", errRequired) + } + if p.ModelID == "" { + return "", fmt.Errorf("MlPredictPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("_predict") + pb.writeReq(p.AlgorithmName) + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlPredictModelPath (ml.predict_model) +// --------------------------------------------------------------------------- + +// MlPredictModelPath builds URL paths for the ml.predict_model operation. +// +// Predicts a model. +// +// Available: >= 2.12.0 +type MlPredictModelPath struct { + ModelID string +} + +func (p MlPredictModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlPredictModelPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + pb.writeLit("_predict") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlPredictModelStreamPath (ml.predict_model_stream) +// --------------------------------------------------------------------------- + +// MlPredictModelStreamPath builds URL paths for the ml.predict_model_stream operation. +// +// Predicts a model in streaming mode. +// +// Available: >= 3.3.0 +type MlPredictModelStreamPath struct { + ModelID string +} + +func (p MlPredictModelStreamPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlPredictModelStreamPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + pb.writeLit("_predict") + pb.writeLit("stream") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlRegisterAgentsPath (ml.register_agents) +// --------------------------------------------------------------------------- + +// MlRegisterAgentsPath builds URL paths for the ml.register_agents operation. +// +// Register an agent. +// +// Available: >= 2.13.0 +type MlRegisterAgentsPath struct { +} + +func (p MlRegisterAgentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("agents") + pb.writeLit("_register") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlRegisterModelPath (ml.register_model) +// --------------------------------------------------------------------------- + +// MlRegisterModelPath builds URL paths for the ml.register_model operation. +// +// Registers a model. +// +// Available: >= 2.7.0 +type MlRegisterModelPath struct { +} + +func (p MlRegisterModelPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeLit("_register") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlRegisterModelGroupPath (ml.register_model_group) +// --------------------------------------------------------------------------- + +// MlRegisterModelGroupPath builds URL paths for the ml.register_model_group operation. +// +// Registers a model group. +type MlRegisterModelGroupPath struct { +} + +func (p MlRegisterModelGroupPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("model_groups") + pb.writeLit("_register") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlRegisterModelMetaPath (ml.register_model_meta) +// --------------------------------------------------------------------------- + +// MlRegisterModelMetaPath builds URL paths for the ml.register_model_meta operation. +// +// Registers model metadata. +// +// Available: >= 2.7.0 +type MlRegisterModelMetaPath struct { +} + +func (p MlRegisterModelMetaPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeLit("_register_meta") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchAgenticMemoryPath (ml.search_agentic_memory) +// --------------------------------------------------------------------------- + +// MlSearchAgenticMemoryPath builds URL paths for the ml.search_agentic_memory operation. +// +// Search for memories of a specific type within a memory container. +// +// Available: >= 3.3.0 +type MlSearchAgenticMemoryPath struct { + MemoryContainerID string + Type string +} + +func (p MlSearchAgenticMemoryPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlSearchAgenticMemoryPath.MemoryContainerID: %w", errRequired) + } + if p.Type == "" { + return "", fmt.Errorf("MlSearchAgenticMemoryPath.Type: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + pb.writeLit("memories") + pb.writeReq(p.Type) + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchAgentsPath (ml.search_agents) +// --------------------------------------------------------------------------- + +// MlSearchAgentsPath builds URL paths for the ml.search_agents operation. +// +// Search agents. +// +// Available: >= 2.13.0 +type MlSearchAgentsPath struct { +} + +func (p MlSearchAgentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("agents") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchConnectorsPath (ml.search_connectors) +// --------------------------------------------------------------------------- + +// MlSearchConnectorsPath builds URL paths for the ml.search_connectors operation. +// +// Searches for standalone connectors. +// +// Available: >= 2.11.0 +type MlSearchConnectorsPath struct { +} + +func (p MlSearchConnectorsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("connectors") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchMemoryPath (ml.search_memory) +// --------------------------------------------------------------------------- + +// MlSearchMemoryPath builds URL paths for the ml.search_memory operation. +// +// Search memory. +// +// Available: >= 2.12.0 +type MlSearchMemoryPath struct { +} + +func (p MlSearchMemoryPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchMemoryContainerPath (ml.search_memory_container) +// --------------------------------------------------------------------------- + +// MlSearchMemoryContainerPath builds URL paths for the ml.search_memory_container operation. +// +// Search memory containers. +// +// Available: >= 3.3.0 +type MlSearchMemoryContainerPath struct { +} + +func (p MlSearchMemoryContainerPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchMessagePath (ml.search_message) +// --------------------------------------------------------------------------- + +// MlSearchMessagePath builds URL paths for the ml.search_message operation. +// +// Search messages. +// +// Available: >= 2.12.0 +type MlSearchMessagePath struct { + MemoryID string +} + +func (p MlSearchMessagePath) Build() (string, error) { + if p.MemoryID == "" { + return "", fmt.Errorf("MlSearchMessagePath.MemoryID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeReq(p.MemoryID) + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchModelGroupPath (ml.search_model_group) +// --------------------------------------------------------------------------- + +// MlSearchModelGroupPath builds URL paths for the ml.search_model_group operation. +// +// Searches for model groups. +// +// Available: >= 2.9.0 +type MlSearchModelGroupPath struct { +} + +func (p MlSearchModelGroupPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("model_groups") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchModelsPath (ml.search_models) +// --------------------------------------------------------------------------- + +// MlSearchModelsPath builds URL paths for the ml.search_models operation. +// +// Searches for models. +// +// Available: >= 1.3.0 +type MlSearchModelsPath struct { +} + +func (p MlSearchModelsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlSearchTasksPath (ml.search_tasks) +// --------------------------------------------------------------------------- + +// MlSearchTasksPath builds URL paths for the ml.search_tasks operation. +// +// Searches for tasks. +// +// Available: >= 1.3.0 +type MlSearchTasksPath struct { +} + +func (p MlSearchTasksPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("tasks") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlTrainPath (ml.train) +// --------------------------------------------------------------------------- + +// MlTrainPath builds URL paths for the ml.train operation. +// +// Trains a model synchronously. +// +// Available: >= 1.3.0 +type MlTrainPath struct { + AlgorithmName string +} + +func (p MlTrainPath) Build() (string, error) { + if p.AlgorithmName == "" { + return "", fmt.Errorf("MlTrainPath.AlgorithmName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("_train") + pb.writeReq(p.AlgorithmName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlTrainPredictPath (ml.train_predict) +// --------------------------------------------------------------------------- + +// MlTrainPredictPath builds URL paths for the ml.train_predict operation. +// +// Trains a model and predicts against the same training dataset. +// +// Available: >= 1.3.0 +type MlTrainPredictPath struct { + AlgorithmName string +} + +func (p MlTrainPredictPath) Build() (string, error) { + if p.AlgorithmName == "" { + return "", fmt.Errorf("MlTrainPredictPath.AlgorithmName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("_train_predict") + pb.writeReq(p.AlgorithmName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUndeployModelPath (ml.undeploy_model) +// --------------------------------------------------------------------------- + +// MlUndeployModelPath builds URL paths for the ml.undeploy_model operation. +// +// Undeploys a model. +// +// Available: >= 2.7.0 +type MlUndeployModelPath struct { + ModelID string +} + +func (p MlUndeployModelPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + if p.ModelID != "" { + pb.writeReq(p.ModelID) + } + pb.writeLit("_undeploy") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUnloadModelPath (ml.unload_model) +// --------------------------------------------------------------------------- + +// MlUnloadModelPath builds URL paths for the ml.unload_model operation. +// +// Unloads a model. +// +// Deprecated: >= 2.7.0. Use `undeploy_model` instead. +type MlUnloadModelPath struct { + ModelID string +} + +func (p MlUnloadModelPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + if p.ModelID != "" { + pb.writeReq(p.ModelID) + } + pb.writeLit("_unload") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUpdateAgenticMemoryPath (ml.update_agentic_memory) +// --------------------------------------------------------------------------- + +// MlUpdateAgenticMemoryPath builds URL paths for the ml.update_agentic_memory operation. +// +// Update a specific memory by its type and ID. +// +// Available: >= 3.3.0 +type MlUpdateAgenticMemoryPath struct { + MemoryContainerID string + Type string + ID string +} + +func (p MlUpdateAgenticMemoryPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlUpdateAgenticMemoryPath.MemoryContainerID: %w", errRequired) + } + if p.Type == "" { + return "", fmt.Errorf("MlUpdateAgenticMemoryPath.Type: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("MlUpdateAgenticMemoryPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + pb.writeLit("memories") + pb.writeReq(p.Type) + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUpdateConnectorPath (ml.update_connector) +// --------------------------------------------------------------------------- + +// MlUpdateConnectorPath builds URL paths for the ml.update_connector operation. +// +// Updates a standalone connector. +// +// Available: >= 2.12.0 +type MlUpdateConnectorPath struct { + ConnectorID string +} + +func (p MlUpdateConnectorPath) Build() (string, error) { + if p.ConnectorID == "" { + return "", fmt.Errorf("MlUpdateConnectorPath.ConnectorID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("connectors") + pb.writeReq(p.ConnectorID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUpdateControllerPath (ml.update_controller) +// --------------------------------------------------------------------------- + +// MlUpdateControllerPath builds URL paths for the ml.update_controller operation. +// +// Updates a controller. +// +// Available: >= 2.12.0 +type MlUpdateControllerPath struct { + ModelID string +} + +func (p MlUpdateControllerPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlUpdateControllerPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("controllers") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUpdateMemoryPath (ml.update_memory) +// --------------------------------------------------------------------------- + +// MlUpdateMemoryPath builds URL paths for the ml.update_memory operation. +// +// Update a memory. +// +// Available: >= 2.12.0 +type MlUpdateMemoryPath struct { + MemoryID string +} + +func (p MlUpdateMemoryPath) Build() (string, error) { + if p.MemoryID == "" { + return "", fmt.Errorf("MlUpdateMemoryPath.MemoryID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeReq(p.MemoryID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUpdateMemoryContainerPath (ml.update_memory_container) +// --------------------------------------------------------------------------- + +// MlUpdateMemoryContainerPath builds URL paths for the ml.update_memory_container operation. +// +// Update a memory container. +// +// Available: >= 3.3.0 +type MlUpdateMemoryContainerPath struct { + MemoryContainerID string +} + +func (p MlUpdateMemoryContainerPath) Build() (string, error) { + if p.MemoryContainerID == "" { + return "", fmt.Errorf("MlUpdateMemoryContainerPath.MemoryContainerID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory_containers") + pb.writeReq(p.MemoryContainerID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUpdateMessagePath (ml.update_message) +// --------------------------------------------------------------------------- + +// MlUpdateMessagePath builds URL paths for the ml.update_message operation. +// +// Update a message. +// +// Available: >= 2.12.0 +type MlUpdateMessagePath struct { + MessageID string +} + +func (p MlUpdateMessagePath) Build() (string, error) { + if p.MessageID == "" { + return "", fmt.Errorf("MlUpdateMessagePath.MessageID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("memory") + pb.writeLit("message") + pb.writeReq(p.MessageID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUpdateModelPath (ml.update_model) +// --------------------------------------------------------------------------- + +// MlUpdateModelPath builds URL paths for the ml.update_model operation. +// +// Updates a model. +// +// Available: >= 2.12.0 +type MlUpdateModelPath struct { + ModelID string +} + +func (p MlUpdateModelPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlUpdateModelPath.ModelID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUpdateModelGroupPath (ml.update_model_group) +// --------------------------------------------------------------------------- + +// MlUpdateModelGroupPath builds URL paths for the ml.update_model_group operation. +// +// Updates a model group. +// +// Available: >= 2.9.0 +type MlUpdateModelGroupPath struct { + ModelGroupID string +} + +func (p MlUpdateModelGroupPath) Build() (string, error) { + if p.ModelGroupID == "" { + return "", fmt.Errorf("MlUpdateModelGroupPath.ModelGroupID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("model_groups") + pb.writeReq(p.ModelGroupID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUploadChunkPath (ml.upload_chunk) +// --------------------------------------------------------------------------- + +// MlUploadChunkPath builds URL paths for the ml.upload_chunk operation. +// +// Uploads model chunk. +// +// Available: >= 2.7.0 +type MlUploadChunkPath struct { + ModelID string + ChunkNumber string +} + +func (p MlUploadChunkPath) Build() (string, error) { + if p.ModelID == "" { + return "", fmt.Errorf("MlUploadChunkPath.ModelID: %w", errRequired) + } + if p.ChunkNumber == "" { + return "", fmt.Errorf("MlUploadChunkPath.ChunkNumber: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeReq(p.ModelID) + pb.writeLit("upload_chunk") + pb.writeReq(p.ChunkNumber) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MlUploadModelPath (ml.upload_model) +// --------------------------------------------------------------------------- + +// MlUploadModelPath builds URL paths for the ml.upload_model operation. +// +// Registers a model. +// +// Deprecated: >= 2.7.0. Use `register_model` instead. +type MlUploadModelPath struct { +} + +func (p MlUploadModelPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ml") + pb.writeLit("models") + pb.writeLit("_upload") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MsearchPath (msearch) +// --------------------------------------------------------------------------- + +// MsearchPath builds URL paths for the msearch operation. +// +// Allows to execute several search operations in one request. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/multi-search/ +type MsearchPath struct { + Index []string +} + +func (p MsearchPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_msearch") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MsearchTemplatePath (msearch_template) +// --------------------------------------------------------------------------- + +// MsearchTemplatePath builds URL paths for the msearch_template operation. +// +// Allows to execute several search template operations in one request. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/search-template/ +type MsearchTemplatePath struct { + Index []string +} + +func (p MsearchTemplatePath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_msearch") + pb.writeLit("template") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// MtermvectorsPath (mtermvectors) +// --------------------------------------------------------------------------- + +// MtermvectorsPath builds URL paths for the mtermvectors operation. +// +// Returns multiple termvectors in one request. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type MtermvectorsPath struct { + Index string +} + +func (p MtermvectorsPath) Build() (string, error) { + pb := acquire() + if p.Index != "" { + pb.writeReq(p.Index) + } + pb.writeLit("_mtermvectors") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NeuralStatsPath (neural.stats) +// --------------------------------------------------------------------------- + +// NeuralStatsPath builds URL paths for the neural.stats operation. +// +// Provides information about the current status of the neural-search plugin. +// +// Available: >= 3.0.0 +type NeuralStatsPath struct { + NodeID string + Stat []string +} + +func (p NeuralStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_neural") + switch { + case p.NodeID != "" && hasNonEmpty(p.Stat): + pb.writeReq(p.NodeID) + pb.writeLit("stats") + writeSegments(pb, p.Stat) + case p.NodeID != "": + pb.writeReq(p.NodeID) + pb.writeLit("stats") + case hasNonEmpty(p.Stat): + pb.writeLit("stats") + writeSegments(pb, p.Stat) + default: + pb.writeLit("stats") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NodesHotThreadsPath (nodes.hot_threads) +// --------------------------------------------------------------------------- + +// NodesHotThreadsPath builds URL paths for the nodes.hot_threads operation. +// +// Returns information about hot threads on each node in the cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ +type NodesHotThreadsPath struct { + NodeID []string +} + +func (p NodesHotThreadsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_nodes") + writeSegments(pb, p.NodeID) + pb.writeLit("hot_threads") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NodesInfoPath (nodes.info) +// --------------------------------------------------------------------------- + +// NodesInfoPath builds URL paths for the nodes.info operation. +// +// Returns information about nodes in the cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-info/ +type NodesInfoPath struct { + NodeID []string + Metric []string +} + +func (p NodesInfoPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_nodes") + switch { + case hasNonEmpty(p.NodeID) && hasNonEmpty(p.Metric): + writeSegments(pb, p.NodeID) + writeSegments(pb, p.Metric) + case hasNonEmpty(p.Metric): + writeSegments(pb, p.Metric) + case hasNonEmpty(p.NodeID): + writeSegments(pb, p.NodeID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NodesReloadSecureSettingsPath (nodes.reload_secure_settings) +// --------------------------------------------------------------------------- + +// NodesReloadSecureSettingsPath builds URL paths for the nodes.reload_secure_settings operation. +// +// Reloads secure settings. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-reload-secure/ +type NodesReloadSecureSettingsPath struct { + NodeID []string +} + +func (p NodesReloadSecureSettingsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_nodes") + writeSegments(pb, p.NodeID) + pb.writeLit("reload_secure_settings") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NodesStatsPath (nodes.stats) +// --------------------------------------------------------------------------- + +// NodesStatsPath builds URL paths for the nodes.stats operation. +// +// Returns statistical information about nodes in the cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-usage/ +type NodesStatsPath struct { + NodeID []string + Metric []string + IndexMetric []string +} + +func (p NodesStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_nodes") + switch { + case hasNonEmpty(p.NodeID) && hasNonEmpty(p.Metric) && hasNonEmpty(p.IndexMetric): + writeSegments(pb, p.NodeID) + pb.writeLit("stats") + writeSegments(pb, p.Metric) + writeSegments(pb, p.IndexMetric) + case hasNonEmpty(p.Metric) && hasNonEmpty(p.IndexMetric): + pb.writeLit("stats") + writeSegments(pb, p.Metric) + writeSegments(pb, p.IndexMetric) + case hasNonEmpty(p.NodeID) && hasNonEmpty(p.Metric): + writeSegments(pb, p.NodeID) + pb.writeLit("stats") + writeSegments(pb, p.Metric) + case hasNonEmpty(p.Metric): + pb.writeLit("stats") + writeSegments(pb, p.Metric) + case hasNonEmpty(p.NodeID): + writeSegments(pb, p.NodeID) + pb.writeLit("stats") + default: + if hasNonEmpty(p.NodeID) || hasNonEmpty(p.Metric) || hasNonEmpty(p.IndexMetric) { + return "", explainNodesStatsPath(p) + } + pb.writeLit("stats") + } + return pb.release(), nil +} + +// explainNodesStatsPath returns a specific error describing why the +// caller's field combination does not match any spec path variant. The +// switch in NodesStatsPath.Build dispatches here from its +// default: case after confirming at least one optional field is set. +func explainNodesStatsPath(p NodesStatsPath) error { + if hasNonEmpty(p.IndexMetric) && !hasNonEmpty(p.Metric) { + return fmt.Errorf("NodesStatsPath.IndexMetric requires NodesStatsPath.Metric: %w", errRequired) + } + return fmt.Errorf("NodesStatsPath: invalid combination of fields: %w", errRequired) +} + +// --------------------------------------------------------------------------- +// NodesUsagePath (nodes.usage) +// --------------------------------------------------------------------------- + +// NodesUsagePath builds URL paths for the nodes.usage operation. +// +// Returns low-level information about REST actions usage on nodes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type NodesUsagePath struct { + NodeID []string + Metric []string +} + +func (p NodesUsagePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_nodes") + switch { + case hasNonEmpty(p.NodeID) && hasNonEmpty(p.Metric): + writeSegments(pb, p.NodeID) + pb.writeLit("usage") + writeSegments(pb, p.Metric) + case hasNonEmpty(p.Metric): + pb.writeLit("usage") + writeSegments(pb, p.Metric) + case hasNonEmpty(p.NodeID): + writeSegments(pb, p.NodeID) + pb.writeLit("usage") + default: + pb.writeLit("usage") + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsCreateConfigPath (notifications.create_config) +// --------------------------------------------------------------------------- + +// NotificationsCreateConfigPath builds URL paths for the notifications.create_config operation. +// +// Create channel configuration. +// +// Available: >= 2.0.0 +// +// See: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#create-channel-configuration +type NotificationsCreateConfigPath struct { +} + +func (p NotificationsCreateConfigPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("configs") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsDeleteConfigPath (notifications.delete_config) +// --------------------------------------------------------------------------- + +// NotificationsDeleteConfigPath builds URL paths for the notifications.delete_config operation. +// +// Delete a channel configuration. +// +// Available: >= 2.0.0 +// +// See: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#delete-channel-configuration +type NotificationsDeleteConfigPath struct { + ConfigID string +} + +func (p NotificationsDeleteConfigPath) Build() (string, error) { + if p.ConfigID == "" { + return "", fmt.Errorf("NotificationsDeleteConfigPath.ConfigID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("configs") + pb.writeReq(p.ConfigID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsDeleteConfigsPath (notifications.delete_configs) +// --------------------------------------------------------------------------- + +// NotificationsDeleteConfigsPath builds URL paths for the notifications.delete_configs operation. +// +// Delete multiple channel configurations. +// +// Available: >= 2.2.0 +// +// See: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#delete-channel-configuration +type NotificationsDeleteConfigsPath struct { +} + +func (p NotificationsDeleteConfigsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("configs") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsGetConfigPath (notifications.get_config) +// --------------------------------------------------------------------------- + +// NotificationsGetConfigPath builds URL paths for the notifications.get_config operation. +// +// Get a specific channel configuration. +// +// Available: >= 2.0.0 +type NotificationsGetConfigPath struct { + ConfigID string +} + +func (p NotificationsGetConfigPath) Build() (string, error) { + if p.ConfigID == "" { + return "", fmt.Errorf("NotificationsGetConfigPath.ConfigID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("configs") + pb.writeReq(p.ConfigID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsGetConfigsPath (notifications.get_configs) +// --------------------------------------------------------------------------- + +// NotificationsGetConfigsPath builds URL paths for the notifications.get_configs operation. +// +// Get multiple channel configurations with filtering. +// +// Available: >= 2.0.0 +// +// See: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#list-all-notification-configurations +type NotificationsGetConfigsPath struct { +} + +func (p NotificationsGetConfigsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("configs") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsListChannelsPath (notifications.list_channels) +// --------------------------------------------------------------------------- + +// NotificationsListChannelsPath builds URL paths for the notifications.list_channels operation. +// +// List created notification channels. +// +// Available: >= 2.0.0 +// +// See: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#list-all-notification-channels +type NotificationsListChannelsPath struct { +} + +func (p NotificationsListChannelsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("channels") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsListFeaturesPath (notifications.list_features) +// --------------------------------------------------------------------------- + +// NotificationsListFeaturesPath builds URL paths for the notifications.list_features operation. +// +// List supported channel configurations. +// +// Available: >= 2.0.0 +// +// See: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#list-supported-channel-configurations +type NotificationsListFeaturesPath struct { +} + +func (p NotificationsListFeaturesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("features") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsSendTestPath (notifications.send_test) +// --------------------------------------------------------------------------- + +// NotificationsSendTestPath builds URL paths for the notifications.send_test operation. +// +// Send a test notification. +// +// Available: >= 2.0.0 +// +// See: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#send-test-notification +type NotificationsSendTestPath struct { + ConfigID string +} + +func (p NotificationsSendTestPath) Build() (string, error) { + if p.ConfigID == "" { + return "", fmt.Errorf("NotificationsSendTestPath.ConfigID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("feature") + pb.writeLit("test") + pb.writeReq(p.ConfigID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// NotificationsUpdateConfigPath (notifications.update_config) +// --------------------------------------------------------------------------- + +// NotificationsUpdateConfigPath builds URL paths for the notifications.update_config operation. +// +// Update channel configuration. +// +// Available: >= 2.0.0 +// +// See: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#update-channel-configuration +type NotificationsUpdateConfigPath struct { + ConfigID string +} + +func (p NotificationsUpdateConfigPath) Build() (string, error) { + if p.ConfigID == "" { + return "", fmt.Errorf("NotificationsUpdateConfigPath.ConfigID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_notifications") + pb.writeLit("configs") + pb.writeReq(p.ConfigID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ObservabilityCreateObjectPath (observability.create_object) +// --------------------------------------------------------------------------- + +// ObservabilityCreateObjectPath builds URL paths for the observability.create_object operation. +// +// Creates a new observability object. +// +// Available: >= 1.1.0 +type ObservabilityCreateObjectPath struct { +} + +func (p ObservabilityCreateObjectPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_observability") + pb.writeLit("object") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ObservabilityDeleteObjectPath (observability.delete_object) +// --------------------------------------------------------------------------- + +// ObservabilityDeleteObjectPath builds URL paths for the observability.delete_object operation. +// +// Deletes specific observability object specified by ID. +// +// Available: >= 1.1.0 +type ObservabilityDeleteObjectPath struct { + ObjectID string +} + +func (p ObservabilityDeleteObjectPath) Build() (string, error) { + if p.ObjectID == "" { + return "", fmt.Errorf("ObservabilityDeleteObjectPath.ObjectID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_observability") + pb.writeLit("object") + pb.writeReq(p.ObjectID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ObservabilityDeleteObjectsPath (observability.delete_objects) +// --------------------------------------------------------------------------- + +// ObservabilityDeleteObjectsPath builds URL paths for the observability.delete_objects operation. +// +// Deletes specific observability objects specified by ID or a list of IDs. +// +// Available: >= 1.1.0 +type ObservabilityDeleteObjectsPath struct { +} + +func (p ObservabilityDeleteObjectsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_observability") + pb.writeLit("object") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ObservabilityGetLocalstatsPath (observability.get_localstats) +// --------------------------------------------------------------------------- + +// ObservabilityGetLocalstatsPath builds URL paths for the observability.get_localstats operation. +// +// Retrieves local stats of all observability objects. +// +// Available: >= 2.5.0 +type ObservabilityGetLocalstatsPath struct { +} + +func (p ObservabilityGetLocalstatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_observability") + pb.writeLit("_local") + pb.writeLit("stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ObservabilityGetObjectPath (observability.get_object) +// --------------------------------------------------------------------------- + +// ObservabilityGetObjectPath builds URL paths for the observability.get_object operation. +// +// Retrieves specific observability object specified by ID. +// +// Available: >= 1.1.0 +type ObservabilityGetObjectPath struct { + ObjectID string +} + +func (p ObservabilityGetObjectPath) Build() (string, error) { + if p.ObjectID == "" { + return "", fmt.Errorf("ObservabilityGetObjectPath.ObjectID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_observability") + pb.writeLit("object") + pb.writeReq(p.ObjectID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ObservabilityListObjectsPath (observability.list_objects) +// --------------------------------------------------------------------------- + +// ObservabilityListObjectsPath builds URL paths for the observability.list_objects operation. +// +// Retrieves list of all observability objects. +// +// Available: >= 1.1.0 +type ObservabilityListObjectsPath struct { +} + +func (p ObservabilityListObjectsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_observability") + pb.writeLit("object") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ObservabilityUpdateObjectPath (observability.update_object) +// --------------------------------------------------------------------------- + +// ObservabilityUpdateObjectPath builds URL paths for the observability.update_object operation. +// +// Updates an existing observability object. +// +// Available: >= 1.1.0 +type ObservabilityUpdateObjectPath struct { + ObjectID string +} + +func (p ObservabilityUpdateObjectPath) Build() (string, error) { + if p.ObjectID == "" { + return "", fmt.Errorf("ObservabilityUpdateObjectPath.ObjectID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_observability") + pb.writeLit("object") + pb.writeReq(p.ObjectID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// PingPath (ping) +// --------------------------------------------------------------------------- + +// PingPath builds URL paths for the ping operation. +// +// Returns whether the cluster is running. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type PingPath struct { +} + +func (p PingPath) Build() (string, error) { + return "/", nil +} + +// --------------------------------------------------------------------------- +// PplExplainPath (ppl.explain) +// --------------------------------------------------------------------------- + +// PplExplainPath builds URL paths for the ppl.explain operation. +// +// Returns the execution plan for a PPL query. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ +type PplExplainPath struct { +} + +func (p PplExplainPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ppl") + pb.writeLit("_explain") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// PplGetStatsPath (ppl.get_stats) +// --------------------------------------------------------------------------- + +// PplGetStatsPath builds URL paths for the ppl.get_stats operation. +// +// Retrieves performance metrics for the PPL plugin. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ +type PplGetStatsPath struct { +} + +func (p PplGetStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ppl") + pb.writeLit("stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// PplPostStatsPath (ppl.post_stats) +// --------------------------------------------------------------------------- + +// PplPostStatsPath builds URL paths for the ppl.post_stats operation. +// +// Retrieves filtered performance metrics for the PPL plugin. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ +type PplPostStatsPath struct { +} + +func (p PplPostStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ppl") + pb.writeLit("stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// PplQueryPath (ppl.query) +// --------------------------------------------------------------------------- + +// PplQueryPath builds URL paths for the ppl.query operation. +// +// Executes a PPL query against OpenSearch indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ +type PplQueryPath struct { +} + +func (p PplQueryPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_ppl") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// PutScriptPath (put_script) +// --------------------------------------------------------------------------- + +// PutScriptPath builds URL paths for the put_script operation. +// +// Creates or updates a script. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/script-apis/create-stored-script/ +type PutScriptPath struct { + ID string + Context string +} + +func (p PutScriptPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("PutScriptPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_scripts") + pb.writeReq(p.ID) + if p.Context != "" { + pb.writeReq(p.Context) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// QueryDatasourceDeletePath (query.datasource_delete) +// --------------------------------------------------------------------------- + +// QueryDatasourceDeletePath builds URL paths for the query.datasource_delete operation. +// +// Deletes a specific data source by name. +// +// Available: >= 2.7.0 +type QueryDatasourceDeletePath struct { + DatasourceName string +} + +func (p QueryDatasourceDeletePath) Build() (string, error) { + if p.DatasourceName == "" { + return "", fmt.Errorf("QueryDatasourceDeletePath.DatasourceName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_query") + pb.writeLit("_datasources") + pb.writeReq(p.DatasourceName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// QueryDatasourceRetrievePath (query.datasource_retrieve) +// --------------------------------------------------------------------------- + +// QueryDatasourceRetrievePath builds URL paths for the query.datasource_retrieve operation. +// +// Retrieves a specific data source by name. +// +// Available: >= 2.7.0 +type QueryDatasourceRetrievePath struct { + DatasourceName string +} + +func (p QueryDatasourceRetrievePath) Build() (string, error) { + if p.DatasourceName == "" { + return "", fmt.Errorf("QueryDatasourceRetrievePath.DatasourceName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_query") + pb.writeLit("_datasources") + pb.writeReq(p.DatasourceName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// QueryDatasourcesCreatePath (query.datasources_create) +// --------------------------------------------------------------------------- + +// QueryDatasourcesCreatePath builds URL paths for the query.datasources_create operation. +// +// Creates a new query data source. +// +// Available: >= 2.7.0 +type QueryDatasourcesCreatePath struct { +} + +func (p QueryDatasourcesCreatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_query") + pb.writeLit("_datasources") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// QueryDatasourcesListPath (query.datasources_list) +// --------------------------------------------------------------------------- + +// QueryDatasourcesListPath builds URL paths for the query.datasources_list operation. +// +// Retrieves a list of all available data sources. +// +// Available: >= 2.7.0 +type QueryDatasourcesListPath struct { +} + +func (p QueryDatasourcesListPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_query") + pb.writeLit("_datasources") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// QueryDatasourcesUpdatePath (query.datasources_update) +// --------------------------------------------------------------------------- + +// QueryDatasourcesUpdatePath builds URL paths for the query.datasources_update operation. +// +// Updates an existing query data source. +// +// Available: >= 2.7.0 +type QueryDatasourcesUpdatePath struct { +} + +func (p QueryDatasourcesUpdatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_query") + pb.writeLit("_datasources") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RankEvalPath (rank_eval) +// --------------------------------------------------------------------------- + +// RankEvalPath builds URL paths for the rank_eval operation. +// +// Allows to evaluate the quality of ranked search results over a set of typical search queries. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/rank-eval/ +type RankEvalPath struct { + Index []string +} + +func (p RankEvalPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_rank_eval") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReindexPath (reindex) +// --------------------------------------------------------------------------- + +// ReindexPath builds URL paths for the reindex operation. +// +// Allows to copy documents from one index to another, optionally filtering the source +// documents by a query, changing the destination index settings, or fetching the +// documents from a remote cluster. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/reindex-data/ +type ReindexPath struct { +} + +func (p ReindexPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_reindex") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReindexRethrottlePath (reindex_rethrottle) +// --------------------------------------------------------------------------- + +// ReindexRethrottlePath builds URL paths for the reindex_rethrottle operation. +// +// Changes the number of requests per second for a particular reindex operation. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type ReindexRethrottlePath struct { + TaskID string +} + +func (p ReindexRethrottlePath) Build() (string, error) { + if p.TaskID == "" { + return "", fmt.Errorf("ReindexRethrottlePath.TaskID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_reindex") + pb.writeReq(p.TaskID) + pb.writeLit("_rethrottle") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RemoteStoreRestorePath (remote_store.restore) +// --------------------------------------------------------------------------- + +// RemoteStoreRestorePath builds URL paths for the remote_store.restore operation. +// +// Restores from remote store. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/opensearch/remote/#restoring-from-a-backup +type RemoteStoreRestorePath struct { +} + +func (p RemoteStoreRestorePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_remotestore") + pb.writeLit("_restore") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RenderSearchTemplatePath (render_search_template) +// --------------------------------------------------------------------------- + +// RenderSearchTemplatePath builds URL paths for the render_search_template operation. +// +// Allows to use the Mustache language to pre-render a search definition. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/search-template/ +type RenderSearchTemplatePath struct { + ID string +} + +func (p RenderSearchTemplatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_render") + pb.writeLit("template") + if p.ID != "" { + pb.writeReq(p.ID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationAutofollowStatsPath (replication.autofollow_stats) +// --------------------------------------------------------------------------- + +// ReplicationAutofollowStatsPath builds URL paths for the replication.autofollow_stats operation. +// +// Retrieves information about any auto-follow activity and any replication rules configured on the specified cluster. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#get-auto-follow-stats +type ReplicationAutofollowStatsPath struct { +} + +func (p ReplicationAutofollowStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeLit("autofollow_stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationCreateReplicationRulePath (replication.create_replication_rule) +// --------------------------------------------------------------------------- + +// ReplicationCreateReplicationRulePath builds URL paths for the replication.create_replication_rule operation. +// +// Automatically starts the replication on indexes matching a specified pattern. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#create-replication-rule +type ReplicationCreateReplicationRulePath struct { +} + +func (p ReplicationCreateReplicationRulePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeLit("_autofollow") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationDeleteReplicationRulePath (replication.delete_replication_rule) +// --------------------------------------------------------------------------- + +// ReplicationDeleteReplicationRulePath builds URL paths for the replication.delete_replication_rule operation. +// +// Deletes the specified replication rule. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#delete-replication-rule +type ReplicationDeleteReplicationRulePath struct { +} + +func (p ReplicationDeleteReplicationRulePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeLit("_autofollow") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationFollowerStatsPath (replication.follower_stats) +// --------------------------------------------------------------------------- + +// ReplicationFollowerStatsPath builds URL paths for the replication.follower_stats operation. +// +// Retrieves information about any follower (syncing) indexes on a specified cluster. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#get-follower-cluster-stats +type ReplicationFollowerStatsPath struct { +} + +func (p ReplicationFollowerStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeLit("follower_stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationLeaderStatsPath (replication.leader_stats) +// --------------------------------------------------------------------------- + +// ReplicationLeaderStatsPath builds URL paths for the replication.leader_stats operation. +// +// Retrieves information about any replicated leader indexes on a specified cluster. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#get-leader-cluster-stats +type ReplicationLeaderStatsPath struct { +} + +func (p ReplicationLeaderStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeLit("leader_stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationPausePath (replication.pause) +// --------------------------------------------------------------------------- + +// ReplicationPausePath builds URL paths for the replication.pause operation. +// +// Pauses the replication of the leader index. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#pause-replication +type ReplicationPausePath struct { + Index string +} + +func (p ReplicationPausePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ReplicationPausePath.Index: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeReq(p.Index) + pb.writeLit("_pause") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationResumePath (replication.resume) +// --------------------------------------------------------------------------- + +// ReplicationResumePath builds URL paths for the replication.resume operation. +// +// Resumes replication of the leader index. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#resume-replication +type ReplicationResumePath struct { + Index string +} + +func (p ReplicationResumePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ReplicationResumePath.Index: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeReq(p.Index) + pb.writeLit("_resume") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationStartPath (replication.start) +// --------------------------------------------------------------------------- + +// ReplicationStartPath builds URL paths for the replication.start operation. +// +// Initiates the replication of an index from the leader cluster to the follower cluster. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#start-replication +type ReplicationStartPath struct { + Index string +} + +func (p ReplicationStartPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ReplicationStartPath.Index: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeReq(p.Index) + pb.writeLit("_start") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationStatusPath (replication.status) +// --------------------------------------------------------------------------- + +// ReplicationStatusPath builds URL paths for the replication.status operation. +// +// Retrieves the the status of an index replication. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#get-replication-status +type ReplicationStatusPath struct { + Index string +} + +func (p ReplicationStatusPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ReplicationStatusPath.Index: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeReq(p.Index) + pb.writeLit("_status") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationStopPath (replication.stop) +// --------------------------------------------------------------------------- + +// ReplicationStopPath builds URL paths for the replication.stop operation. +// +// Terminates the replication and converts the follower index to a standard index. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#stop-replication +type ReplicationStopPath struct { + Index string +} + +func (p ReplicationStopPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ReplicationStopPath.Index: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeReq(p.Index) + pb.writeLit("_stop") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ReplicationUpdateSettingsPath (replication.update_settings) +// --------------------------------------------------------------------------- + +// ReplicationUpdateSettingsPath builds URL paths for the replication.update_settings operation. +// +// Updates any settings on the follower index. +// +// Available: >= 1.1.0 +// +// See: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#update-settings +type ReplicationUpdateSettingsPath struct { + Index string +} + +func (p ReplicationUpdateSettingsPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("ReplicationUpdateSettingsPath.Index: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_replication") + pb.writeReq(p.Index) + pb.writeLit("_update") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RollupsDeletePath (rollups.delete) +// --------------------------------------------------------------------------- + +// RollupsDeletePath builds URL paths for the rollups.delete operation. +// +// Deletes an index rollup job configuration. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#delete-an-index-rollup-job +type RollupsDeletePath struct { + ID string +} + +func (p RollupsDeletePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("RollupsDeletePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_rollup") + pb.writeLit("jobs") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RollupsExplainPath (rollups.explain) +// --------------------------------------------------------------------------- + +// RollupsExplainPath builds URL paths for the rollups.explain operation. +// +// Retrieves the execution status information for an index rollup job. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#explain-an-index-rollup-job +type RollupsExplainPath struct { + ID string +} + +func (p RollupsExplainPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("RollupsExplainPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_rollup") + pb.writeLit("jobs") + pb.writeReq(p.ID) + pb.writeLit("_explain") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RollupsGetPath (rollups.get) +// --------------------------------------------------------------------------- + +// RollupsGetPath builds URL paths for the rollups.get operation. +// +// Retrieves an index rollup job configuration by ID. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#get-an-index-rollup-job +type RollupsGetPath struct { + ID string +} + +func (p RollupsGetPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("RollupsGetPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_rollup") + pb.writeLit("jobs") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RollupsPutPath (rollups.put) +// --------------------------------------------------------------------------- + +// RollupsPutPath builds URL paths for the rollups.put operation. +// +// Creates or updates an index rollup job configuration. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#create-or-update-an-index-rollup-job +type RollupsPutPath struct { + ID string +} + +func (p RollupsPutPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("RollupsPutPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_rollup") + pb.writeLit("jobs") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RollupsStartPath (rollups.start) +// --------------------------------------------------------------------------- + +// RollupsStartPath builds URL paths for the rollups.start operation. +// +// Starts the execution of an index rollup job. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#start-or-stop-an-index-rollup-job +type RollupsStartPath struct { + ID string +} + +func (p RollupsStartPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("RollupsStartPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_rollup") + pb.writeLit("jobs") + pb.writeReq(p.ID) + pb.writeLit("_start") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// RollupsStopPath (rollups.stop) +// --------------------------------------------------------------------------- + +// RollupsStopPath builds URL paths for the rollups.stop operation. +// +// Stops the execution of an index rollup job. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#start-or-stop-an-index-rollup-job +type RollupsStopPath struct { + ID string +} + +func (p RollupsStopPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("RollupsStopPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_rollup") + pb.writeLit("jobs") + pb.writeReq(p.ID) + pb.writeLit("_stop") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ScriptsPainlessExecutePath (scripts_painless_execute) +// --------------------------------------------------------------------------- + +// ScriptsPainlessExecutePath builds URL paths for the scripts_painless_execute operation. +// +// Allows an arbitrary script to be executed and a result to be returned. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/script-apis/exec-script/ +type ScriptsPainlessExecutePath struct { +} + +func (p ScriptsPainlessExecutePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_scripts") + pb.writeLit("painless") + pb.writeLit("_execute") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// ScrollPath (scroll) +// --------------------------------------------------------------------------- + +// ScrollPath builds URL paths for the scroll operation. +// +// Allows to retrieve a large numbers of results from a single search request. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/scroll/#path-and-http-methods +type ScrollPath struct { + ScrollID string +} + +func (p ScrollPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_search") + pb.writeLit("scroll") + if p.ScrollID != "" { + pb.writeReq(p.ScrollID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchPath (search) +// --------------------------------------------------------------------------- + +// SearchPath builds URL paths for the search operation. +// +// Returns results matching a query. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/search/ +type SearchPath struct { + Index []string +} + +func (p SearchPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchPipelineDeletePath (search_pipeline.delete) +// --------------------------------------------------------------------------- + +// SearchPipelineDeletePath builds URL paths for the search_pipeline.delete operation. +// +// Deletes the specified search pipeline. +// +// Available: >= 2.9.0 +type SearchPipelineDeletePath struct { + ID string +} + +func (p SearchPipelineDeletePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("SearchPipelineDeletePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_search") + pb.writeLit("pipeline") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchPipelineGetPath (search_pipeline.get) +// --------------------------------------------------------------------------- + +// SearchPipelineGetPath builds URL paths for the search_pipeline.get operation. +// +// Retrieves information about a specified search pipeline. +// +// Available: >= 2.9.0 +type SearchPipelineGetPath struct { + ID string +} + +func (p SearchPipelineGetPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_search") + pb.writeLit("pipeline") + if p.ID != "" { + pb.writeReq(p.ID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchPipelinePutPath (search_pipeline.put) +// --------------------------------------------------------------------------- + +// SearchPipelinePutPath builds URL paths for the search_pipeline.put operation. +// +// Creates or replaces the specified search pipeline. +// +// Available: >= 2.9.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/search-pipelines/creating-search-pipeline/ +type SearchPipelinePutPath struct { + ID string +} + +func (p SearchPipelinePutPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("SearchPipelinePutPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_search") + pb.writeLit("pipeline") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceDeleteExperimentsPath (search_relevance.delete_experiments) +// --------------------------------------------------------------------------- + +// SearchRelevanceDeleteExperimentsPath builds URL paths for the search_relevance.delete_experiments operation. +// +// Deletes a specified experiment. +// +// Available: >= 3.1.0 +type SearchRelevanceDeleteExperimentsPath struct { + ExperimentID string +} + +func (p SearchRelevanceDeleteExperimentsPath) Build() (string, error) { + if p.ExperimentID == "" { + return "", fmt.Errorf("SearchRelevanceDeleteExperimentsPath.ExperimentID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("experiments") + pb.writeReq(p.ExperimentID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceDeleteJudgmentsPath (search_relevance.delete_judgments) +// --------------------------------------------------------------------------- + +// SearchRelevanceDeleteJudgmentsPath builds URL paths for the search_relevance.delete_judgments operation. +// +// Deletes a specified judgment. +// +// Available: >= 3.1.0 +type SearchRelevanceDeleteJudgmentsPath struct { + JudgmentID string +} + +func (p SearchRelevanceDeleteJudgmentsPath) Build() (string, error) { + if p.JudgmentID == "" { + return "", fmt.Errorf("SearchRelevanceDeleteJudgmentsPath.JudgmentID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("judgments") + pb.writeReq(p.JudgmentID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceDeleteQuerySetsPath (search_relevance.delete_query_sets) +// --------------------------------------------------------------------------- + +// SearchRelevanceDeleteQuerySetsPath builds URL paths for the search_relevance.delete_query_sets operation. +// +// Deletes a query set. +// +// Available: >= 3.1.0 +type SearchRelevanceDeleteQuerySetsPath struct { + QuerySetID string +} + +func (p SearchRelevanceDeleteQuerySetsPath) Build() (string, error) { + if p.QuerySetID == "" { + return "", fmt.Errorf("SearchRelevanceDeleteQuerySetsPath.QuerySetID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("query_sets") + pb.writeReq(p.QuerySetID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceDeleteScheduledExperimentsPath (search_relevance.delete_scheduled_experiments) +// --------------------------------------------------------------------------- + +// SearchRelevanceDeleteScheduledExperimentsPath builds URL paths for the search_relevance.delete_scheduled_experiments operation. +// +// Deletes a specified scheduled experiment. +// +// Available: >= 3.4.0 +type SearchRelevanceDeleteScheduledExperimentsPath struct { + ExperimentID string +} + +func (p SearchRelevanceDeleteScheduledExperimentsPath) Build() (string, error) { + if p.ExperimentID == "" { + return "", fmt.Errorf("SearchRelevanceDeleteScheduledExperimentsPath.ExperimentID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("experiments") + pb.writeLit("schedule") + pb.writeReq(p.ExperimentID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceDeleteSearchConfigurationsPath (search_relevance.delete_search_configurations) +// --------------------------------------------------------------------------- + +// SearchRelevanceDeleteSearchConfigurationsPath builds URL paths for the search_relevance.delete_search_configurations operation. +// +// Deletes a specified search configuration. +// +// Available: >= 3.1.0 +type SearchRelevanceDeleteSearchConfigurationsPath struct { + SearchConfigurationID string +} + +func (p SearchRelevanceDeleteSearchConfigurationsPath) Build() (string, error) { + if p.SearchConfigurationID == "" { + return "", fmt.Errorf("SearchRelevanceDeleteSearchConfigurationsPath.SearchConfigurationID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("search_configurations") + pb.writeReq(p.SearchConfigurationID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceGetExperimentsPath (search_relevance.get_experiments) +// --------------------------------------------------------------------------- + +// SearchRelevanceGetExperimentsPath builds URL paths for the search_relevance.get_experiments operation. +// +// Gets experiments. +// +// Available: >= 3.1.0 +type SearchRelevanceGetExperimentsPath struct { + ExperimentID string +} + +func (p SearchRelevanceGetExperimentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("experiments") + if p.ExperimentID != "" { + pb.writeReq(p.ExperimentID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceGetJudgmentsPath (search_relevance.get_judgments) +// --------------------------------------------------------------------------- + +// SearchRelevanceGetJudgmentsPath builds URL paths for the search_relevance.get_judgments operation. +// +// Gets judgments. +// +// Available: >= 3.1.0 +type SearchRelevanceGetJudgmentsPath struct { + JudgmentID string +} + +func (p SearchRelevanceGetJudgmentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("judgments") + if p.JudgmentID != "" { + pb.writeReq(p.JudgmentID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceGetNodeStatsPath (search_relevance.get_node_stats) +// --------------------------------------------------------------------------- + +// SearchRelevanceGetNodeStatsPath builds URL paths for the search_relevance.get_node_stats operation. +// +// Gets stats by node. +// +// Available: >= 3.1.0 +type SearchRelevanceGetNodeStatsPath struct { + NodeID string + Stat string +} + +func (p SearchRelevanceGetNodeStatsPath) Build() (string, error) { + if p.NodeID == "" { + return "", fmt.Errorf("SearchRelevanceGetNodeStatsPath.NodeID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeReq(p.NodeID) + pb.writeLit("stats") + if p.Stat != "" { + pb.writeReq(p.Stat) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceGetQuerySetsPath (search_relevance.get_query_sets) +// --------------------------------------------------------------------------- + +// SearchRelevanceGetQuerySetsPath builds URL paths for the search_relevance.get_query_sets operation. +// +// Lists the current query sets available. +// +// Available: >= 3.1.0 +type SearchRelevanceGetQuerySetsPath struct { + QuerySetID string +} + +func (p SearchRelevanceGetQuerySetsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("query_sets") + if p.QuerySetID != "" { + pb.writeReq(p.QuerySetID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceGetScheduledExperimentsPath (search_relevance.get_scheduled_experiments) +// --------------------------------------------------------------------------- + +// SearchRelevanceGetScheduledExperimentsPath builds URL paths for the search_relevance.get_scheduled_experiments operation. +// +// Gets the scheduled experiments. +// +// Available: >= 3.4.0 +type SearchRelevanceGetScheduledExperimentsPath struct { + ExperimentID string +} + +func (p SearchRelevanceGetScheduledExperimentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("experiments") + pb.writeLit("schedule") + if p.ExperimentID != "" { + pb.writeReq(p.ExperimentID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceGetSearchConfigurationsPath (search_relevance.get_search_configurations) +// --------------------------------------------------------------------------- + +// SearchRelevanceGetSearchConfigurationsPath builds URL paths for the search_relevance.get_search_configurations operation. +// +// Gets the search configurations. +// +// Available: >= 3.1.0 +type SearchRelevanceGetSearchConfigurationsPath struct { + SearchConfigurationID string +} + +func (p SearchRelevanceGetSearchConfigurationsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("search_configurations") + if p.SearchConfigurationID != "" { + pb.writeReq(p.SearchConfigurationID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevanceGetStatsPath (search_relevance.get_stats) +// --------------------------------------------------------------------------- + +// SearchRelevanceGetStatsPath builds URL paths for the search_relevance.get_stats operation. +// +// Gets stats. +// +// Available: >= 3.1.0 +type SearchRelevanceGetStatsPath struct { + Stat string +} + +func (p SearchRelevanceGetStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("stats") + if p.Stat != "" { + pb.writeReq(p.Stat) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevancePostQuerySetsPath (search_relevance.post_query_sets) +// --------------------------------------------------------------------------- + +// SearchRelevancePostQuerySetsPath builds URL paths for the search_relevance.post_query_sets operation. +// +// Creates a new query set by sampling queries from the user behavior data. +// +// Available: >= 3.1.0 +type SearchRelevancePostQuerySetsPath struct { +} + +func (p SearchRelevancePostQuerySetsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("query_sets") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevancePostScheduledExperimentsPath (search_relevance.post_scheduled_experiments) +// --------------------------------------------------------------------------- + +// SearchRelevancePostScheduledExperimentsPath builds URL paths for the search_relevance.post_scheduled_experiments operation. +// +// Creates a scheduled experiment. +// +// Available: >= 3.4.0 +type SearchRelevancePostScheduledExperimentsPath struct { +} + +func (p SearchRelevancePostScheduledExperimentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("experiments") + pb.writeLit("schedule") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevancePutExperimentsPath (search_relevance.put_experiments) +// --------------------------------------------------------------------------- + +// SearchRelevancePutExperimentsPath builds URL paths for the search_relevance.put_experiments operation. +// +// Creates an experiment. +// +// Available: >= 3.1.0 +type SearchRelevancePutExperimentsPath struct { +} + +func (p SearchRelevancePutExperimentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("experiments") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevancePutJudgmentsPath (search_relevance.put_judgments) +// --------------------------------------------------------------------------- + +// SearchRelevancePutJudgmentsPath builds URL paths for the search_relevance.put_judgments operation. +// +// Creates a judgment. +// +// Available: >= 3.1.0 +type SearchRelevancePutJudgmentsPath struct { +} + +func (p SearchRelevancePutJudgmentsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("judgments") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevancePutQuerySetsPath (search_relevance.put_query_sets) +// --------------------------------------------------------------------------- + +// SearchRelevancePutQuerySetsPath builds URL paths for the search_relevance.put_query_sets operation. +// +// Creates a new query set by uploading manually. +// +// Available: >= 3.1.0 +type SearchRelevancePutQuerySetsPath struct { +} + +func (p SearchRelevancePutQuerySetsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("query_sets") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchRelevancePutSearchConfigurationsPath (search_relevance.put_search_configurations) +// --------------------------------------------------------------------------- + +// SearchRelevancePutSearchConfigurationsPath builds URL paths for the search_relevance.put_search_configurations operation. +// +// Creates a search configuration. +// +// Available: >= 3.1.0 +type SearchRelevancePutSearchConfigurationsPath struct { +} + +func (p SearchRelevancePutSearchConfigurationsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_search_relevance") + pb.writeLit("search_configurations") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchShardsPath (search_shards) +// --------------------------------------------------------------------------- + +// SearchShardsPath builds URL paths for the search_shards operation. +// +// Returns information about the indexes and shards that a search request would be executed against. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type SearchShardsPath struct { + Index []string +} + +func (p SearchShardsPath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_search_shards") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SearchTemplatePath (search_template) +// --------------------------------------------------------------------------- + +// SearchTemplatePath builds URL paths for the search_template operation. +// +// Allows to use the Mustache language to pre-render a search definition. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/search-template/ +type SearchTemplatePath struct { + Index []string +} + +func (p SearchTemplatePath) Build() (string, error) { + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_search") + pb.writeLit("template") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityAuthinfoPath (security.authinfo) +// --------------------------------------------------------------------------- + +// SecurityAuthinfoPath builds URL paths for the security.authinfo operation. +// +// Returns or updates authentication information for the currently authenticated user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityAuthinfoPath struct { +} + +func (p SecurityAuthinfoPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("authinfo") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityAuthtokenPath (security.authtoken) +// --------------------------------------------------------------------------- + +// SecurityAuthtokenPath builds URL paths for the security.authtoken operation. +// +// Returns the authorization token for the current user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityAuthtokenPath struct { +} + +func (p SecurityAuthtokenPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("authtoken") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityChangePasswordPath (security.change_password) +// --------------------------------------------------------------------------- + +// SecurityChangePasswordPath builds URL paths for the security.change_password operation. +// +// Changes the password for the current user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#change-password +type SecurityChangePasswordPath struct { +} + +func (p SecurityChangePasswordPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("account") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityConfigUpgradeCheckPath (security.config_upgrade_check) +// --------------------------------------------------------------------------- + +// SecurityConfigUpgradeCheckPath builds URL paths for the security.config_upgrade_check operation. +// +// Checks whether or not an upgrade can be performed and which security resources can be updated. +// +// Available: >= 2.14.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#configuration-upgrade-check +type SecurityConfigUpgradeCheckPath struct { +} + +func (p SecurityConfigUpgradeCheckPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("_upgrade_check") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityConfigUpgradePerformPath (security.config_upgrade_perform) +// --------------------------------------------------------------------------- + +// SecurityConfigUpgradePerformPath builds URL paths for the security.config_upgrade_perform operation. +// +// Assists the cluster operator with upgrading missing default values and stale default definitions. +// +// Available: >= 2.14.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#configuration-upgrade +type SecurityConfigUpgradePerformPath struct { +} + +func (p SecurityConfigUpgradePerformPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("_upgrade_perform") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityCreateActionGroupPath (security.create_action_group) +// --------------------------------------------------------------------------- + +// SecurityCreateActionGroupPath builds URL paths for the security.create_action_group operation. +// +// Creates or replaces the specified action group. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#create-action-group +type SecurityCreateActionGroupPath struct { + ActionGroup string +} + +func (p SecurityCreateActionGroupPath) Build() (string, error) { + if p.ActionGroup == "" { + return "", fmt.Errorf("SecurityCreateActionGroupPath.ActionGroup: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("actiongroups") + pb.writeReq(p.ActionGroup) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityCreateAllowlistPath (security.create_allowlist) +// --------------------------------------------------------------------------- + +// SecurityCreateAllowlistPath builds URL paths for the security.create_allowlist operation. +// +// Creates or replaces APIs permitted for users on the allow list. Requires a super admin certificate or REST API permissions. +// +// Available: >= 2.1.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api +type SecurityCreateAllowlistPath struct { +} + +func (p SecurityCreateAllowlistPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("allowlist") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityCreateRolePath (security.create_role) +// --------------------------------------------------------------------------- + +// SecurityCreateRolePath builds URL paths for the security.create_role operation. +// +// Creates or replaces the specified role. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#create-role +type SecurityCreateRolePath struct { + Role string +} + +func (p SecurityCreateRolePath) Build() (string, error) { + if p.Role == "" { + return "", fmt.Errorf("SecurityCreateRolePath.Role: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("roles") + pb.writeReq(p.Role) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityCreateRoleMappingPath (security.create_role_mapping) +// --------------------------------------------------------------------------- + +// SecurityCreateRoleMappingPath builds URL paths for the security.create_role_mapping operation. +// +// Creates or replaces the specified role mapping. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#create-role-mapping +type SecurityCreateRoleMappingPath struct { + Role string +} + +func (p SecurityCreateRoleMappingPath) Build() (string, error) { + if p.Role == "" { + return "", fmt.Errorf("SecurityCreateRoleMappingPath.Role: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("rolesmapping") + pb.writeReq(p.Role) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityCreateTenantPath (security.create_tenant) +// --------------------------------------------------------------------------- + +// SecurityCreateTenantPath builds URL paths for the security.create_tenant operation. +// +// Creates or replaces the specified tenant. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#create-tenant +type SecurityCreateTenantPath struct { + Tenant string +} + +func (p SecurityCreateTenantPath) Build() (string, error) { + if p.Tenant == "" { + return "", fmt.Errorf("SecurityCreateTenantPath.Tenant: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("tenants") + pb.writeReq(p.Tenant) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityCreateUpdateTenancyConfigPath (security.create_update_tenancy_config) +// --------------------------------------------------------------------------- + +// SecurityCreateUpdateTenancyConfigPath builds URL paths for the security.create_update_tenancy_config operation. +// +// Creates or replaces the multi-tenancy configuration. Requires super admin or REST API permissions. +// +// Available: >= 2.7.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/multi-tenancy/dynamic-config/#configuring-multi-tenancy-with-the-rest-api +type SecurityCreateUpdateTenancyConfigPath struct { +} + +func (p SecurityCreateUpdateTenancyConfigPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("tenancy") + pb.writeLit("config") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityCreateUserPath (security.create_user) +// --------------------------------------------------------------------------- + +// SecurityCreateUserPath builds URL paths for the security.create_user operation. +// +// Creates or replaces the specified user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#create-user +type SecurityCreateUserPath struct { + Username string +} + +func (p SecurityCreateUserPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityCreateUserPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("internalusers") + pb.writeReq(p.Username) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityCreateUserLegacyPath (security.create_user_legacy) +// --------------------------------------------------------------------------- + +// SecurityCreateUserLegacyPath builds URL paths for the security.create_user_legacy operation. +// +// Creates or replaces the specified user. Legacy API. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityCreateUserLegacyPath struct { + Username string +} + +func (p SecurityCreateUserLegacyPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityCreateUserLegacyPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("user") + pb.writeReq(p.Username) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityDeleteActionGroupPath (security.delete_action_group) +// --------------------------------------------------------------------------- + +// SecurityDeleteActionGroupPath builds URL paths for the security.delete_action_group operation. +// +// Deletes the specified action group. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#delete-action-group +type SecurityDeleteActionGroupPath struct { + ActionGroup string +} + +func (p SecurityDeleteActionGroupPath) Build() (string, error) { + if p.ActionGroup == "" { + return "", fmt.Errorf("SecurityDeleteActionGroupPath.ActionGroup: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("actiongroups") + pb.writeReq(p.ActionGroup) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityDeleteDistinguishedNamePath (security.delete_distinguished_name) +// --------------------------------------------------------------------------- + +// SecurityDeleteDistinguishedNamePath builds URL paths for the security.delete_distinguished_name operation. +// +// Deletes all distinguished names in the specified cluster or node allowlist. Requires super admin or REST API permissions. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#delete-distinguished-names +type SecurityDeleteDistinguishedNamePath struct { + ClusterName string +} + +func (p SecurityDeleteDistinguishedNamePath) Build() (string, error) { + if p.ClusterName == "" { + return "", fmt.Errorf("SecurityDeleteDistinguishedNamePath.ClusterName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("nodesdn") + pb.writeReq(p.ClusterName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityDeleteRolePath (security.delete_role) +// --------------------------------------------------------------------------- + +// SecurityDeleteRolePath builds URL paths for the security.delete_role operation. +// +// Deletes the specified role. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#delete-role +type SecurityDeleteRolePath struct { + Role string +} + +func (p SecurityDeleteRolePath) Build() (string, error) { + if p.Role == "" { + return "", fmt.Errorf("SecurityDeleteRolePath.Role: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("roles") + pb.writeReq(p.Role) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityDeleteRoleMappingPath (security.delete_role_mapping) +// --------------------------------------------------------------------------- + +// SecurityDeleteRoleMappingPath builds URL paths for the security.delete_role_mapping operation. +// +// Deletes the specified role mapping. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#delete-role-mapping +type SecurityDeleteRoleMappingPath struct { + Role string +} + +func (p SecurityDeleteRoleMappingPath) Build() (string, error) { + if p.Role == "" { + return "", fmt.Errorf("SecurityDeleteRoleMappingPath.Role: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("rolesmapping") + pb.writeReq(p.Role) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityDeleteTenantPath (security.delete_tenant) +// --------------------------------------------------------------------------- + +// SecurityDeleteTenantPath builds URL paths for the security.delete_tenant operation. +// +// Deletes the specified tenant. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#delete-action-group +type SecurityDeleteTenantPath struct { + Tenant string +} + +func (p SecurityDeleteTenantPath) Build() (string, error) { + if p.Tenant == "" { + return "", fmt.Errorf("SecurityDeleteTenantPath.Tenant: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("tenants") + pb.writeReq(p.Tenant) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityDeleteUserPath (security.delete_user) +// --------------------------------------------------------------------------- + +// SecurityDeleteUserPath builds URL paths for the security.delete_user operation. +// +// Deletes the specified internal user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#delete-user +type SecurityDeleteUserPath struct { + Username string +} + +func (p SecurityDeleteUserPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityDeleteUserPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("internalusers") + pb.writeReq(p.Username) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityDeleteUserLegacyPath (security.delete_user_legacy) +// --------------------------------------------------------------------------- + +// SecurityDeleteUserLegacyPath builds URL paths for the security.delete_user_legacy operation. +// +// Delete the specified user. Legacy API. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityDeleteUserLegacyPath struct { + Username string +} + +func (p SecurityDeleteUserLegacyPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityDeleteUserLegacyPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("user") + pb.writeReq(p.Username) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityFlushCachePath (security.flush_cache) +// --------------------------------------------------------------------------- + +// SecurityFlushCachePath builds URL paths for the security.flush_cache operation. +// +// Flushes the Security plugin's user, authentication, and authorization cache. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#flush-cache +type SecurityFlushCachePath struct { +} + +func (p SecurityFlushCachePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("cache") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGenerateOboTokenPath (security.generate_obo_token) +// --------------------------------------------------------------------------- + +// SecurityGenerateOboTokenPath builds URL paths for the security.generate_obo_token operation. +// +// Generates a `On-Behalf-Of` token for the current user. +// +// Available: >= 2.12.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/authentication-tokens/#api-endpoint +type SecurityGenerateOboTokenPath struct { +} + +func (p SecurityGenerateOboTokenPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("generateonbehalfoftoken") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGenerateUserTokenPath (security.generate_user_token) +// --------------------------------------------------------------------------- + +// SecurityGenerateUserTokenPath builds URL paths for the security.generate_user_token operation. +// +// Generates an authorization token for the specified user. +// +// Available: >= 2.7.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityGenerateUserTokenPath struct { + Username string +} + +func (p SecurityGenerateUserTokenPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityGenerateUserTokenPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("internalusers") + pb.writeReq(p.Username) + pb.writeLit("authtoken") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGenerateUserTokenLegacyPath (security.generate_user_token_legacy) +// --------------------------------------------------------------------------- + +// SecurityGenerateUserTokenLegacyPath builds URL paths for the security.generate_user_token_legacy operation. +// +// Generates authorization token for the given user. Legacy API. Not Implemented. +// +// Available: >= 2.7.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityGenerateUserTokenLegacyPath struct { + Username string +} + +func (p SecurityGenerateUserTokenLegacyPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityGenerateUserTokenLegacyPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("user") + pb.writeReq(p.Username) + pb.writeLit("authtoken") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetAccountDetailsPath (security.get_account_details) +// --------------------------------------------------------------------------- + +// SecurityGetAccountDetailsPath builds URL paths for the security.get_account_details operation. +// +// Returns account information for the current user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-account-details +type SecurityGetAccountDetailsPath struct { +} + +func (p SecurityGetAccountDetailsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("account") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetActionGroupPath (security.get_action_group) +// --------------------------------------------------------------------------- + +// SecurityGetActionGroupPath builds URL paths for the security.get_action_group operation. +// +// Retrieves one action group. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-action-group +type SecurityGetActionGroupPath struct { + ActionGroup string +} + +func (p SecurityGetActionGroupPath) Build() (string, error) { + if p.ActionGroup == "" { + return "", fmt.Errorf("SecurityGetActionGroupPath.ActionGroup: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("actiongroups") + pb.writeReq(p.ActionGroup) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetActionGroupsPath (security.get_action_groups) +// --------------------------------------------------------------------------- + +// SecurityGetActionGroupsPath builds URL paths for the security.get_action_groups operation. +// +// Retrieves all action groups. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-action-groups +type SecurityGetActionGroupsPath struct { +} + +func (p SecurityGetActionGroupsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("actiongroups") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetAllCertificatesPath (security.get_all_certificates) +// --------------------------------------------------------------------------- + +// SecurityGetAllCertificatesPath builds URL paths for the security.get_all_certificates operation. +// +// Retrieves the cluster security certificates. +// +// Available: >= 2.15.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityGetAllCertificatesPath struct { +} + +func (p SecurityGetAllCertificatesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("certificates") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetAllowlistPath (security.get_allowlist) +// --------------------------------------------------------------------------- + +// SecurityGetAllowlistPath builds URL paths for the security.get_allowlist operation. +// +// Retrieves the current list of allowed APIs accessible to a normal user. +// +// Available: >= 2.1.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api +type SecurityGetAllowlistPath struct { +} + +func (p SecurityGetAllowlistPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("allowlist") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetAuditConfigurationPath (security.get_audit_configuration) +// --------------------------------------------------------------------------- + +// SecurityGetAuditConfigurationPath builds URL paths for the security.get_audit_configuration operation. +// +// Retrieves the audit configuration. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#audit-logs +type SecurityGetAuditConfigurationPath struct { +} + +func (p SecurityGetAuditConfigurationPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("audit") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetCertificatesPath (security.get_certificates) +// --------------------------------------------------------------------------- + +// SecurityGetCertificatesPath builds URL paths for the security.get_certificates operation. +// +// Retrieves the cluster security certificates. +// +// Available: >= 2.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-certificates +type SecurityGetCertificatesPath struct { +} + +func (p SecurityGetCertificatesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("ssl") + pb.writeLit("certs") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetConfigurationPath (security.get_configuration) +// --------------------------------------------------------------------------- + +// SecurityGetConfigurationPath builds URL paths for the security.get_configuration operation. +// +// Returns the current Security plugin configuration in a JSON format. +// +// Available: >= 2.10.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-configuration +type SecurityGetConfigurationPath struct { +} + +func (p SecurityGetConfigurationPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("securityconfig") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetDashboardsInfoPath (security.get_dashboards_info) +// --------------------------------------------------------------------------- + +// SecurityGetDashboardsInfoPath builds URL paths for the security.get_dashboards_info operation. +// +// Retrieves the current values for dynamic security settings for OpenSearch Dashboards. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityGetDashboardsInfoPath struct { +} + +func (p SecurityGetDashboardsInfoPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("dashboardsinfo") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetDistinguishedNamePath (security.get_distinguished_name) +// --------------------------------------------------------------------------- + +// SecurityGetDistinguishedNamePath builds URL paths for the security.get_distinguished_name operation. +// +// Retrieves all node distinguished names. Requires super admin or REST API permissions. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-distinguished-names +type SecurityGetDistinguishedNamePath struct { + ClusterName string +} + +func (p SecurityGetDistinguishedNamePath) Build() (string, error) { + if p.ClusterName == "" { + return "", fmt.Errorf("SecurityGetDistinguishedNamePath.ClusterName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("nodesdn") + pb.writeReq(p.ClusterName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetDistinguishedNamesPath (security.get_distinguished_names) +// --------------------------------------------------------------------------- + +// SecurityGetDistinguishedNamesPath builds URL paths for the security.get_distinguished_names operation. +// +// Retrieves all node distinguished names. Requires super admin or REST API permissions. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-distinguished-names +type SecurityGetDistinguishedNamesPath struct { +} + +func (p SecurityGetDistinguishedNamesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("nodesdn") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetNodeCertificatesPath (security.get_node_certificates) +// --------------------------------------------------------------------------- + +// SecurityGetNodeCertificatesPath builds URL paths for the security.get_node_certificates operation. +// +// Retrieves the specified node's security certificates. +// +// Available: >= 2.15.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityGetNodeCertificatesPath struct { + NodeID string +} + +func (p SecurityGetNodeCertificatesPath) Build() (string, error) { + if p.NodeID == "" { + return "", fmt.Errorf("SecurityGetNodeCertificatesPath.NodeID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("certificates") + pb.writeReq(p.NodeID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetPermissionsInfoPath (security.get_permissions_info) +// --------------------------------------------------------------------------- + +// SecurityGetPermissionsInfoPath builds URL paths for the security.get_permissions_info operation. +// +// Retrieves the evaluated REST API permissions for the currently logged in user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityGetPermissionsInfoPath struct { +} + +func (p SecurityGetPermissionsInfoPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("permissionsinfo") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetRolePath (security.get_role) +// --------------------------------------------------------------------------- + +// SecurityGetRolePath builds URL paths for the security.get_role operation. +// +// Retrieves one role. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-role +type SecurityGetRolePath struct { + Role string +} + +func (p SecurityGetRolePath) Build() (string, error) { + if p.Role == "" { + return "", fmt.Errorf("SecurityGetRolePath.Role: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("roles") + pb.writeReq(p.Role) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetRoleMappingPath (security.get_role_mapping) +// --------------------------------------------------------------------------- + +// SecurityGetRoleMappingPath builds URL paths for the security.get_role_mapping operation. +// +// Retrieves the specified role mapping. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-role-mapping +type SecurityGetRoleMappingPath struct { + Role string +} + +func (p SecurityGetRoleMappingPath) Build() (string, error) { + if p.Role == "" { + return "", fmt.Errorf("SecurityGetRoleMappingPath.Role: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("rolesmapping") + pb.writeReq(p.Role) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetRoleMappingsPath (security.get_role_mappings) +// --------------------------------------------------------------------------- + +// SecurityGetRoleMappingsPath builds URL paths for the security.get_role_mappings operation. +// +// Retrieves all role mappings. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-role-mappings +type SecurityGetRoleMappingsPath struct { +} + +func (p SecurityGetRoleMappingsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("rolesmapping") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetRolesPath (security.get_roles) +// --------------------------------------------------------------------------- + +// SecurityGetRolesPath builds URL paths for the security.get_roles operation. +// +// Retrieves all roles. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-roles +type SecurityGetRolesPath struct { +} + +func (p SecurityGetRolesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("roles") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetSslinfoPath (security.get_sslinfo) +// --------------------------------------------------------------------------- + +// SecurityGetSslinfoPath builds URL paths for the security.get_sslinfo operation. +// +// Retrieves information about the SSL configuration. +// +// Available: >= 1.0.0 +type SecurityGetSslinfoPath struct { +} + +func (p SecurityGetSslinfoPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_opendistro") + pb.writeLit("_security") + pb.writeLit("sslinfo") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetTenancyConfigPath (security.get_tenancy_config) +// --------------------------------------------------------------------------- + +// SecurityGetTenancyConfigPath builds URL paths for the security.get_tenancy_config operation. +// +// Retrieves the multi-tenancy configuration. Requires super admin or REST API permissions. +// +// Available: >= 2.7.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/multi-tenancy/dynamic-config/#configuring-multi-tenancy-with-the-rest-api +type SecurityGetTenancyConfigPath struct { +} + +func (p SecurityGetTenancyConfigPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("tenancy") + pb.writeLit("config") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetTenantPath (security.get_tenant) +// --------------------------------------------------------------------------- + +// SecurityGetTenantPath builds URL paths for the security.get_tenant operation. +// +// Retrieves the specified tenant. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-tenant +type SecurityGetTenantPath struct { + Tenant string +} + +func (p SecurityGetTenantPath) Build() (string, error) { + if p.Tenant == "" { + return "", fmt.Errorf("SecurityGetTenantPath.Tenant: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("tenants") + pb.writeReq(p.Tenant) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetTenantsPath (security.get_tenants) +// --------------------------------------------------------------------------- + +// SecurityGetTenantsPath builds URL paths for the security.get_tenants operation. +// +// Retrieves all tenants. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-tenants +type SecurityGetTenantsPath struct { +} + +func (p SecurityGetTenantsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("tenants") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetUserPath (security.get_user) +// --------------------------------------------------------------------------- + +// SecurityGetUserPath builds URL paths for the security.get_user operation. +// +// Retrieve information about the specified internal user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-user +type SecurityGetUserPath struct { + Username string +} + +func (p SecurityGetUserPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityGetUserPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("internalusers") + pb.writeReq(p.Username) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetUserLegacyPath (security.get_user_legacy) +// --------------------------------------------------------------------------- + +// SecurityGetUserLegacyPath builds URL paths for the security.get_user_legacy operation. +// +// Retrieve one user. Legacy API. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityGetUserLegacyPath struct { + Username string +} + +func (p SecurityGetUserLegacyPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityGetUserLegacyPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("user") + pb.writeReq(p.Username) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetUsersPath (security.get_users) +// --------------------------------------------------------------------------- + +// SecurityGetUsersPath builds URL paths for the security.get_users operation. +// +// Retrieve all internal users. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#get-users +type SecurityGetUsersPath struct { +} + +func (p SecurityGetUsersPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("internalusers") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityGetUsersLegacyPath (security.get_users_legacy) +// --------------------------------------------------------------------------- + +// SecurityGetUsersLegacyPath builds URL paths for the security.get_users_legacy operation. +// +// Retrieve all internal users. Legacy API. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityGetUsersLegacyPath struct { +} + +func (p SecurityGetUsersLegacyPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("user") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityHealthPath (security.health) +// --------------------------------------------------------------------------- + +// SecurityHealthPath builds URL paths for the security.health operation. +// +// Checks to see if the Security plugin is running. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#health-check +type SecurityHealthPath struct { +} + +func (p SecurityHealthPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("health") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityMigratePath (security.migrate) +// --------------------------------------------------------------------------- + +// SecurityMigratePath builds URL paths for the security.migrate operation. +// +// Migrates the security configuration from v6 to v7. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityMigratePath struct { +} + +func (p SecurityMigratePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("migrate") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchActionGroupPath (security.patch_action_group) +// --------------------------------------------------------------------------- + +// SecurityPatchActionGroupPath builds URL paths for the security.patch_action_group operation. +// +// Updates the individual attributes of an action group. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-action-group +type SecurityPatchActionGroupPath struct { + ActionGroup string +} + +func (p SecurityPatchActionGroupPath) Build() (string, error) { + if p.ActionGroup == "" { + return "", fmt.Errorf("SecurityPatchActionGroupPath.ActionGroup: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("actiongroups") + pb.writeReq(p.ActionGroup) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchActionGroupsPath (security.patch_action_groups) +// --------------------------------------------------------------------------- + +// SecurityPatchActionGroupsPath builds URL paths for the security.patch_action_groups operation. +// +// Creates, updates, or deletes multiple action groups in a single request. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-action-groups +type SecurityPatchActionGroupsPath struct { +} + +func (p SecurityPatchActionGroupsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("actiongroups") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchAllowlistPath (security.patch_allowlist) +// --------------------------------------------------------------------------- + +// SecurityPatchAllowlistPath builds URL paths for the security.patch_allowlist operation. +// +// Updates the current list of APIs accessible for users on the allow list. +// +// Available: >= 2.1.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api +type SecurityPatchAllowlistPath struct { +} + +func (p SecurityPatchAllowlistPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("allowlist") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchAuditConfigurationPath (security.patch_audit_configuration) +// --------------------------------------------------------------------------- + +// SecurityPatchAuditConfigurationPath builds URL paths for the security.patch_audit_configuration operation. +// +// Updates the specified fields in the audit configuration. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#audit-logs +type SecurityPatchAuditConfigurationPath struct { +} + +func (p SecurityPatchAuditConfigurationPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("audit") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchConfigurationPath (security.patch_configuration) +// --------------------------------------------------------------------------- + +// SecurityPatchConfigurationPath builds URL paths for the security.patch_configuration operation. +// +// Updates the existing security configuration using the REST API. Requires super admin or REST API permissions. +// +// Available: >= 2.10.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-configuration +type SecurityPatchConfigurationPath struct { +} + +func (p SecurityPatchConfigurationPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("securityconfig") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchDistinguishedNamePath (security.patch_distinguished_name) +// --------------------------------------------------------------------------- + +// SecurityPatchDistinguishedNamePath builds URL paths for the security.patch_distinguished_name operation. +// +// Updates the distinguished cluster name for the specified cluster. Requires super admin or REST API permissions. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityPatchDistinguishedNamePath struct { + ClusterName string +} + +func (p SecurityPatchDistinguishedNamePath) Build() (string, error) { + if p.ClusterName == "" { + return "", fmt.Errorf("SecurityPatchDistinguishedNamePath.ClusterName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("nodesdn") + pb.writeReq(p.ClusterName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchDistinguishedNamesPath (security.patch_distinguished_names) +// --------------------------------------------------------------------------- + +// SecurityPatchDistinguishedNamesPath builds URL paths for the security.patch_distinguished_names operation. +// +// Bulk updates specified node distinguished names. Requires super admin or REST API permissions. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#update-all-distinguished-names +type SecurityPatchDistinguishedNamesPath struct { +} + +func (p SecurityPatchDistinguishedNamesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("nodesdn") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchRolePath (security.patch_role) +// --------------------------------------------------------------------------- + +// SecurityPatchRolePath builds URL paths for the security.patch_role operation. +// +// Updates the individual attributes of a role. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-role +type SecurityPatchRolePath struct { + Role string +} + +func (p SecurityPatchRolePath) Build() (string, error) { + if p.Role == "" { + return "", fmt.Errorf("SecurityPatchRolePath.Role: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("roles") + pb.writeReq(p.Role) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchRoleMappingPath (security.patch_role_mapping) +// --------------------------------------------------------------------------- + +// SecurityPatchRoleMappingPath builds URL paths for the security.patch_role_mapping operation. +// +// Updates the individual attributes of a role mapping. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-role-mapping +type SecurityPatchRoleMappingPath struct { + Role string +} + +func (p SecurityPatchRoleMappingPath) Build() (string, error) { + if p.Role == "" { + return "", fmt.Errorf("SecurityPatchRoleMappingPath.Role: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("rolesmapping") + pb.writeReq(p.Role) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchRoleMappingsPath (security.patch_role_mappings) +// --------------------------------------------------------------------------- + +// SecurityPatchRoleMappingsPath builds URL paths for the security.patch_role_mappings operation. +// +// Creates or updates multiple role mappings in a single request. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-role-mappings +type SecurityPatchRoleMappingsPath struct { +} + +func (p SecurityPatchRoleMappingsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("rolesmapping") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchRolesPath (security.patch_roles) +// --------------------------------------------------------------------------- + +// SecurityPatchRolesPath builds URL paths for the security.patch_roles operation. +// +// Creates, updates, or deletes multiple roles in a single call. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-roles +type SecurityPatchRolesPath struct { +} + +func (p SecurityPatchRolesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("roles") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchTenantPath (security.patch_tenant) +// --------------------------------------------------------------------------- + +// SecurityPatchTenantPath builds URL paths for the security.patch_tenant operation. +// +// Adds, deletes, or modifies a single tenant. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-tenant +type SecurityPatchTenantPath struct { + Tenant string +} + +func (p SecurityPatchTenantPath) Build() (string, error) { + if p.Tenant == "" { + return "", fmt.Errorf("SecurityPatchTenantPath.Tenant: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("tenants") + pb.writeReq(p.Tenant) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchTenantsPath (security.patch_tenants) +// --------------------------------------------------------------------------- + +// SecurityPatchTenantsPath builds URL paths for the security.patch_tenants operation. +// +// Adds, deletes, or modifies multiple tenants in a single request. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-tenants +type SecurityPatchTenantsPath struct { +} + +func (p SecurityPatchTenantsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("tenants") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchUserPath (security.patch_user) +// --------------------------------------------------------------------------- + +// SecurityPatchUserPath builds URL paths for the security.patch_user operation. +// +// Updates individual attributes for an internal user. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-user +type SecurityPatchUserPath struct { + Username string +} + +func (p SecurityPatchUserPath) Build() (string, error) { + if p.Username == "" { + return "", fmt.Errorf("SecurityPatchUserPath.Username: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("internalusers") + pb.writeReq(p.Username) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPatchUsersPath (security.patch_users) +// --------------------------------------------------------------------------- + +// SecurityPatchUsersPath builds URL paths for the security.patch_users operation. +// +// Creates, updates, or deletes multiple internal users in a single request. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#patch-users +type SecurityPatchUsersPath struct { +} + +func (p SecurityPatchUsersPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("internalusers") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityPostDashboardsInfoPath (security.post_dashboards_info) +// --------------------------------------------------------------------------- + +// SecurityPostDashboardsInfoPath builds URL paths for the security.post_dashboards_info operation. +// +// Retrieves the current values for dynamic security settings for OpenSearch Dashboards. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityPostDashboardsInfoPath struct { +} + +func (p SecurityPostDashboardsInfoPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("dashboardsinfo") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityReloadHTTPCertificatesPath (security.reload_http_certificates) +// --------------------------------------------------------------------------- + +// SecurityReloadHTTPCertificatesPath builds URL paths for the security.reload_http_certificates operation. +// +// Reloads the HTTP communication certificates. +// +// Available: >= 2.8.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#reload-http-certificates +type SecurityReloadHTTPCertificatesPath struct { +} + +func (p SecurityReloadHTTPCertificatesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("ssl") + pb.writeLit("http") + pb.writeLit("reloadcerts") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityReloadTransportCertificatesPath (security.reload_transport_certificates) +// --------------------------------------------------------------------------- + +// SecurityReloadTransportCertificatesPath builds URL paths for the security.reload_transport_certificates operation. +// +// Reloads the transport communication certificates. +// +// Available: >= 2.8.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#reload-transport-certificates +type SecurityReloadTransportCertificatesPath struct { +} + +func (p SecurityReloadTransportCertificatesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("ssl") + pb.writeLit("transport") + pb.writeLit("reloadcerts") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityTenantInfoPath (security.tenant_info) +// --------------------------------------------------------------------------- + +// SecurityTenantInfoPath builds URL paths for the security.tenant_info operation. +// +// Retrieves the names of current tenants. Requires super admin or `kibanaserver` permissions. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityTenantInfoPath struct { +} + +func (p SecurityTenantInfoPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("tenantinfo") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityUpdateAuditConfigurationPath (security.update_audit_configuration) +// --------------------------------------------------------------------------- + +// SecurityUpdateAuditConfigurationPath builds URL paths for the security.update_audit_configuration operation. +// +// Updates the audit configuration. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#audit-logs +type SecurityUpdateAuditConfigurationPath struct { +} + +func (p SecurityUpdateAuditConfigurationPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("audit") + pb.writeLit("config") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityUpdateConfigurationPath (security.update_configuration) +// --------------------------------------------------------------------------- + +// SecurityUpdateConfigurationPath builds URL paths for the security.update_configuration operation. +// +// Updates the settings for an existing security configuration. Requires super admin or REST API permissions. +// +// Available: >= 2.10.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#update-configuration +type SecurityUpdateConfigurationPath struct { +} + +func (p SecurityUpdateConfigurationPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("securityconfig") + pb.writeLit("config") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityUpdateDistinguishedNamePath (security.update_distinguished_name) +// --------------------------------------------------------------------------- + +// SecurityUpdateDistinguishedNamePath builds URL paths for the security.update_distinguished_name operation. +// +// Adds or updates the specified distinguished names in the cluster or node allowlist. Requires super admin or REST API permissions. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +// +// See: https://opensearch.org/docs/latest/security/access-control/api/#update-distinguished-names +type SecurityUpdateDistinguishedNamePath struct { + ClusterName string +} + +func (p SecurityUpdateDistinguishedNamePath) Build() (string, error) { + if p.ClusterName == "" { + return "", fmt.Errorf("SecurityUpdateDistinguishedNamePath.ClusterName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("nodesdn") + pb.writeReq(p.ClusterName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityValidatePath (security.validate) +// --------------------------------------------------------------------------- + +// SecurityValidatePath builds URL paths for the security.validate operation. +// +// Checks whether the v6 security configuration is valid and ready to be migrated to v7. +// +// Available: >= 1.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityValidatePath struct { +} + +func (p SecurityValidatePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("api") + pb.writeLit("validate") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityWhoAmIPath (security.who_am_i) +// --------------------------------------------------------------------------- + +// SecurityWhoAmIPath builds URL paths for the security.who_am_i operation. +// +// Gets the identity information for the user currently logged in. +// +// Available: >= 2.0.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityWhoAmIPath struct { +} + +func (p SecurityWhoAmIPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("whoami") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityWhoAmIProtectedPath (security.who_am_i_protected) +// --------------------------------------------------------------------------- + +// SecurityWhoAmIProtectedPath builds URL paths for the security.who_am_i_protected operation. +// +// Gets the identity information for the user currently logged in. To use this operation, you must have access to this endpoint when authorization at REST layer is enabled. +// +// Available: >= 2.11.0 +// +// Not available on: amazon-managed, amazon-serverless. +type SecurityWhoAmIProtectedPath struct { +} + +func (p SecurityWhoAmIProtectedPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security") + pb.writeLit("whoamiprotected") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityAnalyticsGetAlertsPath (security_analytics.get_alerts) +// --------------------------------------------------------------------------- + +// SecurityAnalyticsGetAlertsPath builds URL paths for the security_analytics.get_alerts operation. +// +// Retrieve alerts related to a specific detector type or detector ID. +// +// Available: >= 2.4.0 +// +// See: https://docs.opensearch.org/docs/latest/security-analytics/api-tools/alert-finding-api/#get-alerts +type SecurityAnalyticsGetAlertsPath struct { +} + +func (p SecurityAnalyticsGetAlertsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security_analytics") + pb.writeLit("alerts") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityAnalyticsGetFindingsPath (security_analytics.get_findings) +// --------------------------------------------------------------------------- + +// SecurityAnalyticsGetFindingsPath builds URL paths for the security_analytics.get_findings operation. +// +// Retrieve findings related to a specific detector type or detector ID. +// +// Available: >= 2.4.0 +// +// See: https://docs.opensearch.org/docs/latest/security-analytics/api-tools/alert-finding-api/#get-findings +type SecurityAnalyticsGetFindingsPath struct { +} + +func (p SecurityAnalyticsGetFindingsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security_analytics") + pb.writeLit("findings") + pb.writeLit("_search") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SecurityAnalyticsSearchFindingCorrelationsPath (security_analytics.search_finding_correlations) +// --------------------------------------------------------------------------- + +// SecurityAnalyticsSearchFindingCorrelationsPath builds URL paths for the security_analytics.search_finding_correlations operation. +// +// List correlations for a finding. +// +// Available: >= 2.7.0 +// +// See: https://docs.opensearch.org/docs/latest/security-analytics/api-tools/correlation-eng/#list-correlations-for-a-finding-belonging-to-a-log-type +type SecurityAnalyticsSearchFindingCorrelationsPath struct { +} + +func (p SecurityAnalyticsSearchFindingCorrelationsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_security_analytics") + pb.writeLit("findings") + pb.writeLit("correlate") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SmCreatePolicyPath (sm.create_policy) +// --------------------------------------------------------------------------- + +// SmCreatePolicyPath builds URL paths for the sm.create_policy operation. +// +// Creates a snapshot management policy. +// +// Available: >= 2.1.0 +type SmCreatePolicyPath struct { + PolicyName string +} + +func (p SmCreatePolicyPath) Build() (string, error) { + if p.PolicyName == "" { + return "", fmt.Errorf("SmCreatePolicyPath.PolicyName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sm") + pb.writeLit("policies") + pb.writeReq(p.PolicyName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SmDeletePolicyPath (sm.delete_policy) +// --------------------------------------------------------------------------- + +// SmDeletePolicyPath builds URL paths for the sm.delete_policy operation. +// +// Deletes a snapshot management policy. +// +// Available: >= 2.1.0 +type SmDeletePolicyPath struct { + PolicyName string +} + +func (p SmDeletePolicyPath) Build() (string, error) { + if p.PolicyName == "" { + return "", fmt.Errorf("SmDeletePolicyPath.PolicyName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sm") + pb.writeLit("policies") + pb.writeReq(p.PolicyName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SmExplainPolicyPath (sm.explain_policy) +// --------------------------------------------------------------------------- + +// SmExplainPolicyPath builds URL paths for the sm.explain_policy operation. +// +// Explains the state of the snapshot management policy. +// +// Available: >= 2.1.0 +type SmExplainPolicyPath struct { + PolicyName string +} + +func (p SmExplainPolicyPath) Build() (string, error) { + if p.PolicyName == "" { + return "", fmt.Errorf("SmExplainPolicyPath.PolicyName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sm") + pb.writeLit("policies") + pb.writeReq(p.PolicyName) + pb.writeLit("_explain") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SmGetPoliciesPath (sm.get_policies) +// --------------------------------------------------------------------------- + +// SmGetPoliciesPath builds URL paths for the sm.get_policies operation. +// +// Retrieves all snapshot management policies with optional pagination and filtering. +// +// Available: >= 2.1.0 +type SmGetPoliciesPath struct { +} + +func (p SmGetPoliciesPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sm") + pb.writeLit("policies") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SmGetPolicyPath (sm.get_policy) +// --------------------------------------------------------------------------- + +// SmGetPolicyPath builds URL paths for the sm.get_policy operation. +// +// Retrieves a specific snapshot management policy by name. +// +// Available: >= 2.1.0 +type SmGetPolicyPath struct { + PolicyName string +} + +func (p SmGetPolicyPath) Build() (string, error) { + if p.PolicyName == "" { + return "", fmt.Errorf("SmGetPolicyPath.PolicyName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sm") + pb.writeLit("policies") + pb.writeReq(p.PolicyName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SmStartPolicyPath (sm.start_policy) +// --------------------------------------------------------------------------- + +// SmStartPolicyPath builds URL paths for the sm.start_policy operation. +// +// Starts a snapshot management policy. +// +// Available: >= 2.1.0 +type SmStartPolicyPath struct { + PolicyName string +} + +func (p SmStartPolicyPath) Build() (string, error) { + if p.PolicyName == "" { + return "", fmt.Errorf("SmStartPolicyPath.PolicyName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sm") + pb.writeLit("policies") + pb.writeReq(p.PolicyName) + pb.writeLit("_start") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SmStopPolicyPath (sm.stop_policy) +// --------------------------------------------------------------------------- + +// SmStopPolicyPath builds URL paths for the sm.stop_policy operation. +// +// Stops a snapshot management policy. +// +// Available: >= 2.1.0 +type SmStopPolicyPath struct { + PolicyName string +} + +func (p SmStopPolicyPath) Build() (string, error) { + if p.PolicyName == "" { + return "", fmt.Errorf("SmStopPolicyPath.PolicyName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sm") + pb.writeLit("policies") + pb.writeReq(p.PolicyName) + pb.writeLit("_stop") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SmUpdatePolicyPath (sm.update_policy) +// --------------------------------------------------------------------------- + +// SmUpdatePolicyPath builds URL paths for the sm.update_policy operation. +// +// Updates an existing snapshot management policy. Requires `if_seq_no` and `if_primary_term`. +// +// Available: >= 2.1.0 +type SmUpdatePolicyPath struct { + PolicyName string +} + +func (p SmUpdatePolicyPath) Build() (string, error) { + if p.PolicyName == "" { + return "", fmt.Errorf("SmUpdatePolicyPath.PolicyName: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sm") + pb.writeLit("policies") + pb.writeReq(p.PolicyName) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotCleanupRepositoryPath (snapshot.cleanup_repository) +// --------------------------------------------------------------------------- + +// SnapshotCleanupRepositoryPath builds URL paths for the snapshot.cleanup_repository operation. +// +// Removes any stale data from a snapshot repository. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type SnapshotCleanupRepositoryPath struct { + Repository string +} + +func (p SnapshotCleanupRepositoryPath) Build() (string, error) { + if p.Repository == "" { + return "", fmt.Errorf("SnapshotCleanupRepositoryPath.Repository: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + pb.writeReq(p.Repository) + pb.writeLit("_cleanup") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotClonePath (snapshot.clone) +// --------------------------------------------------------------------------- + +// SnapshotClonePath builds URL paths for the snapshot.clone operation. +// +// Creates a clone of all or part of a snapshot in the same repository as the original snapshot. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type SnapshotClonePath struct { + Repository string + Snapshot string + TargetSnapshot string +} + +func (p SnapshotClonePath) Build() (string, error) { + if p.Repository == "" { + return "", fmt.Errorf("SnapshotClonePath.Repository: %w", errRequired) + } + if p.Snapshot == "" { + return "", fmt.Errorf("SnapshotClonePath.Snapshot: %w", errRequired) + } + if p.TargetSnapshot == "" { + return "", fmt.Errorf("SnapshotClonePath.TargetSnapshot: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + pb.writeReq(p.Repository) + pb.writeReq(p.Snapshot) + pb.writeLit("_clone") + pb.writeReq(p.TargetSnapshot) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotCreatePath (snapshot.create) +// --------------------------------------------------------------------------- + +// SnapshotCreatePath builds URL paths for the snapshot.create operation. +// +// Creates a snapshot within an existing repository. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/snapshots/create-snapshot/ +type SnapshotCreatePath struct { + Repository string + Snapshot string +} + +func (p SnapshotCreatePath) Build() (string, error) { + if p.Repository == "" { + return "", fmt.Errorf("SnapshotCreatePath.Repository: %w", errRequired) + } + if p.Snapshot == "" { + return "", fmt.Errorf("SnapshotCreatePath.Snapshot: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + pb.writeReq(p.Repository) + pb.writeReq(p.Snapshot) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotCreateRepositoryPath (snapshot.create_repository) +// --------------------------------------------------------------------------- + +// SnapshotCreateRepositoryPath builds URL paths for the snapshot.create_repository operation. +// +// Creates a snapshot repository. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/snapshots/create-repository/ +type SnapshotCreateRepositoryPath struct { + Repository string +} + +func (p SnapshotCreateRepositoryPath) Build() (string, error) { + if p.Repository == "" { + return "", fmt.Errorf("SnapshotCreateRepositoryPath.Repository: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + pb.writeReq(p.Repository) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotDeletePath (snapshot.delete) +// --------------------------------------------------------------------------- + +// SnapshotDeletePath builds URL paths for the snapshot.delete operation. +// +// Deletes a snapshot. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/snapshots/delete-snapshot/ +type SnapshotDeletePath struct { + Repository string + Snapshot []string +} + +func (p SnapshotDeletePath) Build() (string, error) { + if p.Repository == "" { + return "", fmt.Errorf("SnapshotDeletePath.Repository: %w", errRequired) + } + if !hasNonEmpty(p.Snapshot) { + return "", fmt.Errorf("SnapshotDeletePath.Snapshot: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + pb.writeReq(p.Repository) + writeSegments(pb, p.Snapshot) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotDeleteRepositoryPath (snapshot.delete_repository) +// --------------------------------------------------------------------------- + +// SnapshotDeleteRepositoryPath builds URL paths for the snapshot.delete_repository operation. +// +// Deletes a snapshot repository. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/snapshots/delete-snapshot-repository/ +type SnapshotDeleteRepositoryPath struct { + Repository []string +} + +func (p SnapshotDeleteRepositoryPath) Build() (string, error) { + if !hasNonEmpty(p.Repository) { + return "", fmt.Errorf("SnapshotDeleteRepositoryPath.Repository: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + writeSegments(pb, p.Repository) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotGetPath (snapshot.get) +// --------------------------------------------------------------------------- + +// SnapshotGetPath builds URL paths for the snapshot.get operation. +// +// Returns information about a snapshot. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type SnapshotGetPath struct { + Repository string + Snapshot []string +} + +func (p SnapshotGetPath) Build() (string, error) { + if p.Repository == "" { + return "", fmt.Errorf("SnapshotGetPath.Repository: %w", errRequired) + } + if !hasNonEmpty(p.Snapshot) { + return "", fmt.Errorf("SnapshotGetPath.Snapshot: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + pb.writeReq(p.Repository) + writeSegments(pb, p.Snapshot) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotGetRepositoryPath (snapshot.get_repository) +// --------------------------------------------------------------------------- + +// SnapshotGetRepositoryPath builds URL paths for the snapshot.get_repository operation. +// +// Returns information about a snapshot repository. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/snapshots/get-snapshot-repository/ +type SnapshotGetRepositoryPath struct { + Repository []string +} + +func (p SnapshotGetRepositoryPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_snapshot") + writeSegments(pb, p.Repository) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotRestorePath (snapshot.restore) +// --------------------------------------------------------------------------- + +// SnapshotRestorePath builds URL paths for the snapshot.restore operation. +// +// Restores a snapshot. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/snapshots/restore-snapshot/ +type SnapshotRestorePath struct { + Repository string + Snapshot string +} + +func (p SnapshotRestorePath) Build() (string, error) { + if p.Repository == "" { + return "", fmt.Errorf("SnapshotRestorePath.Repository: %w", errRequired) + } + if p.Snapshot == "" { + return "", fmt.Errorf("SnapshotRestorePath.Snapshot: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + pb.writeReq(p.Repository) + pb.writeReq(p.Snapshot) + pb.writeLit("_restore") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SnapshotStatusPath (snapshot.status) +// --------------------------------------------------------------------------- + +// SnapshotStatusPath builds URL paths for the snapshot.status operation. +// +// Returns information about the status of a snapshot. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/snapshots/get-snapshot-status/ +type SnapshotStatusPath struct { + Repository string + Snapshot []string +} + +func (p SnapshotStatusPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_snapshot") + switch { + case p.Repository != "" && hasNonEmpty(p.Snapshot): + pb.writeReq(p.Repository) + writeSegments(pb, p.Snapshot) + case p.Repository != "": + pb.writeReq(p.Repository) + default: + if p.Repository != "" || hasNonEmpty(p.Snapshot) { + return "", explainSnapshotStatusPath(p) + } + } + pb.writeLit("_status") + return pb.release(), nil +} + +// explainSnapshotStatusPath returns a specific error describing why the +// caller's field combination does not match any spec path variant. The +// switch in SnapshotStatusPath.Build dispatches here from its +// default: case after confirming at least one optional field is set. +func explainSnapshotStatusPath(p SnapshotStatusPath) error { + if hasNonEmpty(p.Snapshot) && p.Repository == "" { + return fmt.Errorf("SnapshotStatusPath.Snapshot requires SnapshotStatusPath.Repository: %w", errRequired) + } + return fmt.Errorf("SnapshotStatusPath: invalid combination of fields: %w", errRequired) +} + +// --------------------------------------------------------------------------- +// SnapshotVerifyRepositoryPath (snapshot.verify_repository) +// --------------------------------------------------------------------------- + +// SnapshotVerifyRepositoryPath builds URL paths for the snapshot.verify_repository operation. +// +// Verifies a repository. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/snapshots/verify-snapshot-repository/ +type SnapshotVerifyRepositoryPath struct { + Repository string +} + +func (p SnapshotVerifyRepositoryPath) Build() (string, error) { + if p.Repository == "" { + return "", fmt.Errorf("SnapshotVerifyRepositoryPath.Repository: %w", errRequired) + } + pb := acquire() + pb.writeLit("_snapshot") + pb.writeReq(p.Repository) + pb.writeLit("_verify") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SQLClosePath (sql.close) +// --------------------------------------------------------------------------- + +// SQLClosePath builds URL paths for the sql.close operation. +// +// Closes an open cursor to free server-side resources. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ +type SQLClosePath struct { +} + +func (p SQLClosePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sql") + pb.writeLit("close") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SQLExplainPath (sql.explain) +// --------------------------------------------------------------------------- + +// SQLExplainPath builds URL paths for the sql.explain operation. +// +// Returns the execution plan for a SQL or PPL query. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ +type SQLExplainPath struct { +} + +func (p SQLExplainPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sql") + pb.writeLit("_explain") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SQLGetStatsPath (sql.get_stats) +// --------------------------------------------------------------------------- + +// SQLGetStatsPath builds URL paths for the sql.get_stats operation. +// +// Retrieves performance metrics for the SQL plugin. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ +type SQLGetStatsPath struct { +} + +func (p SQLGetStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sql") + pb.writeLit("stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SQLPostStatsPath (sql.post_stats) +// --------------------------------------------------------------------------- + +// SQLPostStatsPath builds URL paths for the sql.post_stats operation. +// +// Retrieves filtered performance metrics for the SQL plugin. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ +type SQLPostStatsPath struct { +} + +func (p SQLPostStatsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sql") + pb.writeLit("stats") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SQLQueryPath (sql.query) +// --------------------------------------------------------------------------- + +// SQLQueryPath builds URL paths for the sql.query operation. +// +// Executes SQL or PPL queries against OpenSearch indexes. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ +type SQLQueryPath struct { +} + +func (p SQLQueryPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_sql") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// SQLSettingsPath (sql.settings) +// --------------------------------------------------------------------------- + +// SQLSettingsPath builds URL paths for the sql.settings operation. +// +// Updates SQL plugin settings in the OpenSearch cluster configuration. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/search-plugins/sql/settings/ +type SQLSettingsPath struct { +} + +func (p SQLSettingsPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_query") + pb.writeLit("settings") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TasksCancelPath (tasks.cancel) +// --------------------------------------------------------------------------- + +// TasksCancelPath builds URL paths for the tasks.cancel operation. +// +// Cancels a task, if it can be cancelled through an API. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/tasks/#task-canceling +type TasksCancelPath struct { + TaskID string +} + +func (p TasksCancelPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_tasks") + if p.TaskID != "" { + pb.writeReq(p.TaskID) + } + pb.writeLit("_cancel") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TasksGetPath (tasks.get) +// --------------------------------------------------------------------------- + +// TasksGetPath builds URL paths for the tasks.get operation. +// +// Returns information about a task. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/tasks/ +type TasksGetPath struct { + TaskID string +} + +func (p TasksGetPath) Build() (string, error) { + if p.TaskID == "" { + return "", fmt.Errorf("TasksGetPath.TaskID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_tasks") + pb.writeReq(p.TaskID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TasksListPath (tasks.list) +// --------------------------------------------------------------------------- + +// TasksListPath builds URL paths for the tasks.list operation. +// +// Returns a list of tasks. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/tasks/ +type TasksListPath struct { +} + +func (p TasksListPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_tasks") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TermvectorsPath (termvectors) +// --------------------------------------------------------------------------- + +// TermvectorsPath builds URL paths for the termvectors operation. +// +// Returns information and statistics about terms in the fields of a particular document. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type TermvectorsPath struct { + Index string + ID string +} + +func (p TermvectorsPath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("TermvectorsPath.Index: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_termvectors") + if p.ID != "" { + pb.writeReq(p.ID) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TransformsDeletePath (transforms.delete) +// --------------------------------------------------------------------------- + +// TransformsDeletePath builds URL paths for the transforms.delete operation. +// +// Delete an index transform. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#delete-a-transform-job +type TransformsDeletePath struct { + ID string +} + +func (p TransformsDeletePath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("TransformsDeletePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_transform") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TransformsExplainPath (transforms.explain) +// --------------------------------------------------------------------------- + +// TransformsExplainPath builds URL paths for the transforms.explain operation. +// +// Returns the status and metadata of a transform job. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#get-the-status-of-a-transform-job +type TransformsExplainPath struct { + ID string +} + +func (p TransformsExplainPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("TransformsExplainPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_transform") + pb.writeReq(p.ID) + pb.writeLit("_explain") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TransformsGetPath (transforms.get) +// --------------------------------------------------------------------------- + +// TransformsGetPath builds URL paths for the transforms.get operation. +// +// Returns the status and metadata of a transform job. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#get-a-transform-jobs-details +type TransformsGetPath struct { + ID string +} + +func (p TransformsGetPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("TransformsGetPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_transform") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TransformsPreviewPath (transforms.preview) +// --------------------------------------------------------------------------- + +// TransformsPreviewPath builds URL paths for the transforms.preview operation. +// +// Returns a preview of what a transformed index would look like. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#preview-a-transform-jobs-results +type TransformsPreviewPath struct { +} + +func (p TransformsPreviewPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_transform") + pb.writeLit("_preview") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TransformsPutPath (transforms.put) +// --------------------------------------------------------------------------- + +// TransformsPutPath builds URL paths for the transforms.put operation. +// +// Create an index transform, or update a transform if `if_seq_no` and `if_primary_term` are provided. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#create-a-transform-job +type TransformsPutPath struct { + ID string +} + +func (p TransformsPutPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("TransformsPutPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_transform") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TransformsSearchPath (transforms.search) +// --------------------------------------------------------------------------- + +// TransformsSearchPath builds URL paths for the transforms.search operation. +// +// Returns the details of all transform jobs. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#get-a-transform-jobs-details +type TransformsSearchPath struct { +} + +func (p TransformsSearchPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_transform") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TransformsStartPath (transforms.start) +// --------------------------------------------------------------------------- + +// TransformsStartPath builds URL paths for the transforms.start operation. +// +// Start transform. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#start-a-transform-job +type TransformsStartPath struct { + ID string +} + +func (p TransformsStartPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("TransformsStartPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_transform") + pb.writeReq(p.ID) + pb.writeLit("_start") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// TransformsStopPath (transforms.stop) +// --------------------------------------------------------------------------- + +// TransformsStopPath builds URL paths for the transforms.stop operation. +// +// Stop transform. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#stop-a-transform-job +type TransformsStopPath struct { + ID string +} + +func (p TransformsStopPath) Build() (string, error) { + if p.ID == "" { + return "", fmt.Errorf("TransformsStopPath.ID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("_transform") + pb.writeReq(p.ID) + pb.writeLit("_stop") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// UbiInitializePath (ubi.initialize) +// --------------------------------------------------------------------------- + +// UbiInitializePath builds URL paths for the ubi.initialize operation. +// +// Initializes the UBI indexes. +// +// Available: >= 1.0.0 +type UbiInitializePath struct { +} + +func (p UbiInitializePath) Build() (string, error) { + pb := acquire() + pb.writeLit("_plugins") + pb.writeLit("ubi") + pb.writeLit("initialize") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// UpdatePath (update) +// --------------------------------------------------------------------------- + +// UpdatePath builds URL paths for the update operation. +// +// Updates a document with a script or partial document. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/update-document/ +type UpdatePath struct { + Index string + ID string +} + +func (p UpdatePath) Build() (string, error) { + if p.Index == "" { + return "", fmt.Errorf("UpdatePath.Index: %w", errRequired) + } + if p.ID == "" { + return "", fmt.Errorf("UpdatePath.ID: %w", errRequired) + } + pb := acquire() + pb.writeReq(p.Index) + pb.writeLit("_update") + pb.writeReq(p.ID) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// UpdateByQueryPath (update_by_query) +// --------------------------------------------------------------------------- + +// UpdateByQueryPath builds URL paths for the update_by_query operation. +// +// Performs an update on every document in the index without changing the source, +// for example to pick up a mapping change. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest/api-reference/document-apis/update-by-query/ +type UpdateByQueryPath struct { + Index []string +} + +func (p UpdateByQueryPath) Build() (string, error) { + if !hasNonEmpty(p.Index) { + return "", fmt.Errorf("UpdateByQueryPath.Index: %w", errRequired) + } + pb := acquire() + writeSegments(pb, p.Index) + pb.writeLit("_update_by_query") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// UpdateByQueryRethrottlePath (update_by_query_rethrottle) +// --------------------------------------------------------------------------- + +// UpdateByQueryRethrottlePath builds URL paths for the update_by_query_rethrottle operation. +// +// Changes the number of requests per second for a particular Update By Query operation. +// +// Available: >= 1.0.0 +// +// See: https://opensearch.org/docs/latest +type UpdateByQueryRethrottlePath struct { + TaskID string +} + +func (p UpdateByQueryRethrottlePath) Build() (string, error) { + if p.TaskID == "" { + return "", fmt.Errorf("UpdateByQueryRethrottlePath.TaskID: %w", errRequired) + } + pb := acquire() + pb.writeLit("_update_by_query") + pb.writeReq(p.TaskID) + pb.writeLit("_rethrottle") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// WlmCreateQueryGroupPath (wlm.create_query_group) +// --------------------------------------------------------------------------- + +// WlmCreateQueryGroupPath builds URL paths for the wlm.create_query_group operation. +// +// Creates a new query group and sets the resource limits for the new query group. +// +// Available: >= 2.17.0 +type WlmCreateQueryGroupPath struct { +} + +func (p WlmCreateQueryGroupPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_wlm") + pb.writeLit("query_group") + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// WlmDeleteQueryGroupPath (wlm.delete_query_group) +// --------------------------------------------------------------------------- + +// WlmDeleteQueryGroupPath builds URL paths for the wlm.delete_query_group operation. +// +// Deletes the specified query group. +// +// Available: >= 2.17.0 +type WlmDeleteQueryGroupPath struct { + Name string +} + +func (p WlmDeleteQueryGroupPath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("WlmDeleteQueryGroupPath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_wlm") + pb.writeLit("query_group") + pb.writeReq(p.Name) + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// WlmGetQueryGroupPath (wlm.get_query_group) +// --------------------------------------------------------------------------- + +// WlmGetQueryGroupPath builds URL paths for the wlm.get_query_group operation. +// +// Retrieves the specified query group. If no query group is specified, all query groups in the cluster are retrieved. +// +// Available: >= 2.17.0 +type WlmGetQueryGroupPath struct { + Name string +} + +func (p WlmGetQueryGroupPath) Build() (string, error) { + pb := acquire() + pb.writeLit("_wlm") + pb.writeLit("query_group") + if p.Name != "" { + pb.writeReq(p.Name) + } + return pb.release(), nil +} + +// --------------------------------------------------------------------------- +// WlmUpdateQueryGroupPath (wlm.update_query_group) +// --------------------------------------------------------------------------- + +// WlmUpdateQueryGroupPath builds URL paths for the wlm.update_query_group operation. +// +// Updates the specified query group. +// +// Available: >= 2.17.0 +type WlmUpdateQueryGroupPath struct { + Name string +} + +func (p WlmUpdateQueryGroupPath) Build() (string, error) { + if p.Name == "" { + return "", fmt.Errorf("WlmUpdateQueryGroupPath.Name: %w", errRequired) + } + pb := acquire() + pb.writeLit("_wlm") + pb.writeLit("query_group") + pb.writeReq(p.Name) + return pb.release(), nil +} diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/doc.go b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/doc.go new file mode 100644 index 0000000000..973d2f504f --- /dev/null +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/doc.go @@ -0,0 +1,12 @@ +// SPDX-License-Identifier: Apache-2.0 +// +// The OpenSearch Contributors require contributions made to +// this file be licensed under the Apache-2.0 license or a +// compatible open source license. + +// Package path provides generated typed path builder structs for all OpenSearch +// API operations. Each struct corresponds to one x-operation-group from the +// OpenSearch API specification and builds the URL path used in HTTP requests. +// +//go:generate sh -c "cd ../../cmd/osgen && go run . paths -spec ../../opensearch-openapi.yaml -pkg path -o ../../internal/path/builders_gen.go -test-out ../../internal/path/builders_gen_test.go" +package path diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/errors.go b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/errors.go new file mode 100644 index 0000000000..6c0ebd6390 --- /dev/null +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/path/errors.go @@ -0,0 +1,11 @@ +// SPDX-License-Identifier: Apache-2.0 +// +// The OpenSearch Contributors require contributions made to +// this file be licensed under the Apache-2.0 license or a +// compatible open source license. + +package path + +// ErrRequired is exported so that the root opensearch package can re-export it +// as ErrPathRequired for consumer use with errors.Is. +var ErrRequired = errRequired diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/internal/version/version.go b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/version/version.go index 7fdc507b45..bb5b46c03a 100644 --- a/vendor/github.com/opensearch-project/opensearch-go/v4/internal/version/version.go +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/internal/version/version.go @@ -27,4 +27,4 @@ package version // Client returns the client version as a string. -const Client = "4.6.0" +const Client = "4.7.3" diff --git a/vendor/github.com/opensearch-project/opensearch-go/v4/opensearch-openapi.yaml b/vendor/github.com/opensearch-project/opensearch-go/v4/opensearch-openapi.yaml new file mode 100644 index 0000000000..aee6e76315 --- /dev/null +++ b/vendor/github.com/opensearch-project/opensearch-go/v4/opensearch-openapi.yaml @@ -0,0 +1,71919 @@ +openapi: 3.1.0 +info: + title: OpenSearch API Specification + version: 0.3.0 + x-api-version: 2.16.0 +paths: + /: + get: + operationId: info.0 + x-operation-group: info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-serverless + description: Returns basic information about the cluster. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/info___200' + head: + operationId: ping.0 + x-operation-group: ping + x-version-added: '1.0' + description: Returns whether the cluster is running. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ping___200' + /_alias: + get: + operationId: indices.get_alias.0 + x-operation-group: indices.get_alias + x-version-added: '1.0' + description: Returns an alias. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-alias/ + parameters: + - $ref: '#/components/parameters/indices.get_alias___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_alias___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_alias___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_alias___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_alias___200' + '404': + $ref: '#/components/responses/indices.get_alias___404' + put: + operationId: indices.put_alias.0 + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + /_alias/{name}: + get: + operationId: indices.get_alias.1 + x-operation-group: indices.get_alias + x-version-added: '1.0' + description: Returns an alias. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-alias/ + parameters: + - $ref: '#/components/parameters/indices.get_alias___path.name' + - $ref: '#/components/parameters/indices.get_alias___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_alias___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_alias___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_alias___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_alias___200' + '404': + $ref: '#/components/responses/indices.get_alias___404' + head: + operationId: indices.exists_alias.0 + x-operation-group: indices.exists_alias + x-version-added: '1.0' + description: Returns information about whether a particular alias exists. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.exists_alias___path.name' + - $ref: '#/components/parameters/indices.exists_alias___query.allow_no_indices' + - $ref: '#/components/parameters/indices.exists_alias___query.expand_wildcards' + - $ref: '#/components/parameters/indices.exists_alias___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.exists_alias___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.exists_alias___200' + '404': + $ref: '#/components/responses/indices.exists_alias___404' + post: + operationId: indices.put_alias.1 + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.name' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + put: + operationId: indices.put_alias.2 + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.name' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + /_aliases: + post: + operationId: indices.update_aliases.0 + x-operation-group: indices.update_aliases + x-version-added: '1.0' + description: Updates index aliases. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/alias/ + parameters: + - $ref: '#/components/parameters/indices.update_aliases___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.update_aliases___query.master_timeout' + - $ref: '#/components/parameters/indices.update_aliases___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.update_aliases' + responses: + '200': + $ref: '#/components/responses/indices.update_aliases___200' + /_aliases/{name}: + post: + operationId: indices.put_alias.3 + deprecated: true + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.name' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + put: + operationId: indices.put_alias.4 + deprecated: true + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.name' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + /_analyze: + get: + operationId: indices.analyze.0 + x-operation-group: indices.analyze + x-version-added: '1.0' + description: Performs the analysis process on a text and return the tokens breakdown of the text. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/analyze-apis/perform-text-analysis/ + parameters: + - $ref: '#/components/parameters/indices.analyze___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.analyze' + responses: + '200': + $ref: '#/components/responses/indices.analyze___200' + post: + operationId: indices.analyze.1 + x-operation-group: indices.analyze + x-version-added: '1.0' + description: Performs the analysis process on a text and return the tokens breakdown of the text. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/analyze-apis/perform-text-analysis/ + parameters: + - $ref: '#/components/parameters/indices.analyze___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.analyze' + responses: + '200': + $ref: '#/components/responses/indices.analyze___200' + /_bulk: + post: + operationId: bulk.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkItems' + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: bulk + x-version-added: '1.0' + description: Allows to perform multiple index/update/delete operations in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/bulk/ + parameters: + - $ref: '#/components/parameters/bulk___query._source' + - $ref: '#/components/parameters/bulk___query._source_excludes' + - $ref: '#/components/parameters/bulk___query._source_includes' + - $ref: '#/components/parameters/bulk___query.index' + - $ref: '#/components/parameters/bulk___query.pipeline' + - $ref: '#/components/parameters/bulk___query.refresh' + - $ref: '#/components/parameters/bulk___query.require_alias' + - $ref: '#/components/parameters/bulk___query.routing' + - $ref: '#/components/parameters/bulk___query.timeout' + - $ref: '#/components/parameters/bulk___query.type' + - $ref: '#/components/parameters/bulk___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/bulk' + responses: + '200': + $ref: '#/components/responses/bulk___200' + put: + operationId: bulk.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkItems' + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: bulk + x-version-added: '1.0' + description: Allows to perform multiple index/update/delete operations in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/bulk/ + parameters: + - $ref: '#/components/parameters/bulk___query._source' + - $ref: '#/components/parameters/bulk___query._source_excludes' + - $ref: '#/components/parameters/bulk___query._source_includes' + - $ref: '#/components/parameters/bulk___query.index' + - $ref: '#/components/parameters/bulk___query.pipeline' + - $ref: '#/components/parameters/bulk___query.refresh' + - $ref: '#/components/parameters/bulk___query.require_alias' + - $ref: '#/components/parameters/bulk___query.routing' + - $ref: '#/components/parameters/bulk___query.timeout' + - $ref: '#/components/parameters/bulk___query.type' + - $ref: '#/components/parameters/bulk___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/bulk' + responses: + '200': + $ref: '#/components/responses/bulk___200' + /_bulk/stream: + post: + operationId: bulk_stream.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkItems' + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: bulk_stream + x-version-added: '2.17' + description: Allows to perform multiple index/update/delete operations using request response streaming. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/bulk-streaming/ + parameters: + - $ref: '#/components/parameters/bulk_stream___query._source' + - $ref: '#/components/parameters/bulk_stream___query._source_excludes' + - $ref: '#/components/parameters/bulk_stream___query._source_includes' + - $ref: '#/components/parameters/bulk_stream___query.batch_interval' + - $ref: '#/components/parameters/bulk_stream___query.batch_size' + - $ref: '#/components/parameters/bulk_stream___query.pipeline' + - $ref: '#/components/parameters/bulk_stream___query.refresh' + - $ref: '#/components/parameters/bulk_stream___query.require_alias' + - $ref: '#/components/parameters/bulk_stream___query.routing' + - $ref: '#/components/parameters/bulk_stream___query.timeout' + - $ref: '#/components/parameters/bulk_stream___query.type' + - $ref: '#/components/parameters/bulk_stream___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/bulk_stream' + responses: + '200': + $ref: '#/components/responses/bulk_stream___200' + put: + operationId: bulk_stream.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkItems' + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: bulk_stream + x-version-added: '2.17' + description: Allows to perform multiple index/update/delete operations using request response streaming. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/bulk-streaming/ + parameters: + - $ref: '#/components/parameters/bulk_stream___query._source' + - $ref: '#/components/parameters/bulk_stream___query._source_excludes' + - $ref: '#/components/parameters/bulk_stream___query._source_includes' + - $ref: '#/components/parameters/bulk_stream___query.batch_interval' + - $ref: '#/components/parameters/bulk_stream___query.batch_size' + - $ref: '#/components/parameters/bulk_stream___query.pipeline' + - $ref: '#/components/parameters/bulk_stream___query.refresh' + - $ref: '#/components/parameters/bulk_stream___query.require_alias' + - $ref: '#/components/parameters/bulk_stream___query.routing' + - $ref: '#/components/parameters/bulk_stream___query.timeout' + - $ref: '#/components/parameters/bulk_stream___query.type' + - $ref: '#/components/parameters/bulk_stream___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/bulk_stream' + responses: + '200': + $ref: '#/components/responses/bulk_stream___200' + /_cache/clear: + post: + operationId: indices.clear_cache.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.clear_cache + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Clears all or specific caches for one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/clear-index-cache/ + parameters: + - $ref: '#/components/parameters/indices.clear_cache___query.allow_no_indices' + - $ref: '#/components/parameters/indices.clear_cache___query.expand_wildcards' + - $ref: '#/components/parameters/indices.clear_cache___query.fielddata' + - $ref: '#/components/parameters/indices.clear_cache___query.fields' + - $ref: '#/components/parameters/indices.clear_cache___query.file' + - $ref: '#/components/parameters/indices.clear_cache___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.clear_cache___query.index' + - $ref: '#/components/parameters/indices.clear_cache___query.query' + - $ref: '#/components/parameters/indices.clear_cache___query.request' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.clear_cache___200' + /_cat: + get: + operationId: cat.help.0 + x-operation-group: cat.help + x-version-added: '1.0' + description: Returns help for the Cat APIs. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/index/ + responses: + '200': + $ref: '#/components/responses/cat.help___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_cat/aliases: + get: + operationId: cat.aliases.0 + x-operation-group: cat.aliases + x-version-added: '1.0' + description: Shows information about aliases currently configured to indexes, including filter and routing information. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-aliases/ + parameters: + - $ref: '#/components/parameters/cat.aliases___query.expand_wildcards' + - $ref: '#/components/parameters/cat.aliases___query.format' + - $ref: '#/components/parameters/cat.aliases___query.h' + - $ref: '#/components/parameters/cat.aliases___query.help' + - $ref: '#/components/parameters/cat.aliases___query.local' + - $ref: '#/components/parameters/cat.aliases___query.s' + - $ref: '#/components/parameters/cat.aliases___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.aliases___200' + /_cat/aliases/{name}: + get: + operationId: cat.aliases.1 + x-operation-group: cat.aliases + x-version-added: '1.0' + description: Shows information about aliases currently configured to indexes, including filter and routing information. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-aliases/ + parameters: + - $ref: '#/components/parameters/cat.aliases___path.name' + - $ref: '#/components/parameters/cat.aliases___query.expand_wildcards' + - $ref: '#/components/parameters/cat.aliases___query.format' + - $ref: '#/components/parameters/cat.aliases___query.h' + - $ref: '#/components/parameters/cat.aliases___query.help' + - $ref: '#/components/parameters/cat.aliases___query.local' + - $ref: '#/components/parameters/cat.aliases___query.s' + - $ref: '#/components/parameters/cat.aliases___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.aliases___200' + /_cat/allocation: + get: + operationId: cat.allocation.0 + x-operation-group: cat.allocation + x-version-added: '1.0' + description: Provides a snapshot of how many shards are allocated to each data node and how much disk space they are using. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-allocation/ + parameters: + - $ref: '#/components/parameters/cat.allocation___query.bytes' + - $ref: '#/components/parameters/cat.allocation___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.allocation___query.format' + - $ref: '#/components/parameters/cat.allocation___query.h' + - $ref: '#/components/parameters/cat.allocation___query.help' + - $ref: '#/components/parameters/cat.allocation___query.local' + - $ref: '#/components/parameters/cat.allocation___query.master_timeout' + - $ref: '#/components/parameters/cat.allocation___query.s' + - $ref: '#/components/parameters/cat.allocation___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.allocation___200' + /_cat/allocation/{node_id}: + get: + operationId: cat.allocation.1 + x-operation-group: cat.allocation + x-version-added: '1.0' + description: Provides a snapshot of how many shards are allocated to each data node and how much disk space they are using. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-allocation/ + parameters: + - $ref: '#/components/parameters/cat.allocation___path.node_id' + - $ref: '#/components/parameters/cat.allocation___query.bytes' + - $ref: '#/components/parameters/cat.allocation___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.allocation___query.format' + - $ref: '#/components/parameters/cat.allocation___query.h' + - $ref: '#/components/parameters/cat.allocation___query.help' + - $ref: '#/components/parameters/cat.allocation___query.local' + - $ref: '#/components/parameters/cat.allocation___query.master_timeout' + - $ref: '#/components/parameters/cat.allocation___query.s' + - $ref: '#/components/parameters/cat.allocation___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.allocation___200' + /_cat/cluster_manager: + get: + operationId: cat.cluster_manager.0 + x-operation-group: cat.cluster_manager + x-version-added: '2.0' + description: Returns information about the cluster-manager node. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-cluster_manager/ + parameters: + - $ref: '#/components/parameters/cat.cluster_manager___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.cluster_manager___query.format' + - $ref: '#/components/parameters/cat.cluster_manager___query.h' + - $ref: '#/components/parameters/cat.cluster_manager___query.help' + - $ref: '#/components/parameters/cat.cluster_manager___query.local' + - $ref: '#/components/parameters/cat.cluster_manager___query.master_timeout' + - $ref: '#/components/parameters/cat.cluster_manager___query.s' + - $ref: '#/components/parameters/cat.cluster_manager___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.cluster_manager___200' + /_cat/count: + get: + operationId: cat.count.0 + x-operation-group: cat.count + x-version-added: '1.0' + description: Provides quick access to the document count of the entire cluster or of an individual index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-count/ + parameters: + - $ref: '#/components/parameters/cat.count___query.format' + - $ref: '#/components/parameters/cat.count___query.h' + - $ref: '#/components/parameters/cat.count___query.help' + - $ref: '#/components/parameters/cat.count___query.s' + - $ref: '#/components/parameters/cat.count___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.count___200' + /_cat/count/{index}: + get: + operationId: cat.count.1 + x-operation-group: cat.count + x-version-added: '1.0' + description: Provides quick access to the document count of the entire cluster or of an individual index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-count/ + parameters: + - $ref: '#/components/parameters/cat.count___path.index' + - $ref: '#/components/parameters/cat.count___query.format' + - $ref: '#/components/parameters/cat.count___query.h' + - $ref: '#/components/parameters/cat.count___query.help' + - $ref: '#/components/parameters/cat.count___query.s' + - $ref: '#/components/parameters/cat.count___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.count___200' + /_cat/fielddata: + get: + operationId: cat.fielddata.0 + x-operation-group: cat.fielddata + x-version-added: '1.0' + description: Shows how much heap memory is currently being used by field data on every data node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-field-data/ + parameters: + - $ref: '#/components/parameters/cat.fielddata___query.bytes' + - $ref: '#/components/parameters/cat.fielddata___query.fields' + - $ref: '#/components/parameters/cat.fielddata___query.format' + - $ref: '#/components/parameters/cat.fielddata___query.h' + - $ref: '#/components/parameters/cat.fielddata___query.help' + - $ref: '#/components/parameters/cat.fielddata___query.s' + - $ref: '#/components/parameters/cat.fielddata___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.fielddata___200' + /_cat/fielddata/{fields}: + get: + operationId: cat.fielddata.1 + x-operation-group: cat.fielddata + x-version-added: '1.0' + description: Shows how much heap memory is currently being used by field data on every data node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-field-data/ + parameters: + - $ref: '#/components/parameters/cat.fielddata___path.fields' + - $ref: '#/components/parameters/cat.fielddata___query.bytes' + - $ref: '#/components/parameters/cat.fielddata___query.fields' + - $ref: '#/components/parameters/cat.fielddata___query.format' + - $ref: '#/components/parameters/cat.fielddata___query.h' + - $ref: '#/components/parameters/cat.fielddata___query.help' + - $ref: '#/components/parameters/cat.fielddata___query.s' + - $ref: '#/components/parameters/cat.fielddata___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.fielddata___200' + /_cat/health: + get: + operationId: cat.health.0 + x-operation-group: cat.health + x-version-added: '1.0' + description: Returns a concise representation of the cluster health. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-health/ + parameters: + - $ref: '#/components/parameters/cat.health___query.format' + - $ref: '#/components/parameters/cat.health___query.h' + - $ref: '#/components/parameters/cat.health___query.help' + - $ref: '#/components/parameters/cat.health___query.s' + - $ref: '#/components/parameters/cat.health___query.time' + - $ref: '#/components/parameters/cat.health___query.ts' + - $ref: '#/components/parameters/cat.health___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.health___200' + /_cat/indices: + get: + operationId: cat.indices.0 + x-operation-group: cat.indices + x-version-added: '1.0' + description: Lists information related to indexes, that is, how much disk space they are using, how many shards they have, their health status, and so on. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-indices/ + parameters: + - $ref: '#/components/parameters/cat.indices___query.bytes' + - $ref: '#/components/parameters/cat.indices___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.indices___query.expand_wildcards' + - $ref: '#/components/parameters/cat.indices___query.format' + - $ref: '#/components/parameters/cat.indices___query.h' + - $ref: '#/components/parameters/cat.indices___query.health' + - $ref: '#/components/parameters/cat.indices___query.help' + - $ref: '#/components/parameters/cat.indices___query.include_unloaded_segments' + - $ref: '#/components/parameters/cat.indices___query.local' + - $ref: '#/components/parameters/cat.indices___query.master_timeout' + - $ref: '#/components/parameters/cat.indices___query.pri' + - $ref: '#/components/parameters/cat.indices___query.s' + - $ref: '#/components/parameters/cat.indices___query.time' + - $ref: '#/components/parameters/cat.indices___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.indices___200' + /_cat/indices/{index}: + get: + operationId: cat.indices.1 + x-operation-group: cat.indices + x-version-added: '1.0' + description: Lists information related to indexes, that is, how much disk space they are using, how many shards they have, their health status, and so on. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-indices/ + parameters: + - $ref: '#/components/parameters/cat.indices___path.index' + - $ref: '#/components/parameters/cat.indices___query.bytes' + - $ref: '#/components/parameters/cat.indices___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.indices___query.expand_wildcards' + - $ref: '#/components/parameters/cat.indices___query.format' + - $ref: '#/components/parameters/cat.indices___query.h' + - $ref: '#/components/parameters/cat.indices___query.health' + - $ref: '#/components/parameters/cat.indices___query.help' + - $ref: '#/components/parameters/cat.indices___query.include_unloaded_segments' + - $ref: '#/components/parameters/cat.indices___query.local' + - $ref: '#/components/parameters/cat.indices___query.master_timeout' + - $ref: '#/components/parameters/cat.indices___query.pri' + - $ref: '#/components/parameters/cat.indices___query.s' + - $ref: '#/components/parameters/cat.indices___query.time' + - $ref: '#/components/parameters/cat.indices___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.indices___200' + /_cat/master: + get: + operationId: cat.master.0 + x-operation-group: cat.master + deprecated: true + x-deprecation-message: To promote inclusive language, use '/_cat/cluster_manager' instead. + x-version-added: '1.0' + x-version-deprecated: '2.0' + description: Returns information about the cluster-manager node. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-cluster_manager/ + parameters: + - $ref: '#/components/parameters/cat.master___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.master___query.format' + - $ref: '#/components/parameters/cat.master___query.h' + - $ref: '#/components/parameters/cat.master___query.help' + - $ref: '#/components/parameters/cat.master___query.local' + - $ref: '#/components/parameters/cat.master___query.master_timeout' + - $ref: '#/components/parameters/cat.master___query.s' + - $ref: '#/components/parameters/cat.master___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.master___200' + /_cat/nodeattrs: + get: + operationId: cat.nodeattrs.0 + x-operation-group: cat.nodeattrs + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns information about custom node attributes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-nodeattrs/ + parameters: + - $ref: '#/components/parameters/cat.nodeattrs___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.nodeattrs___query.format' + - $ref: '#/components/parameters/cat.nodeattrs___query.h' + - $ref: '#/components/parameters/cat.nodeattrs___query.help' + - $ref: '#/components/parameters/cat.nodeattrs___query.local' + - $ref: '#/components/parameters/cat.nodeattrs___query.master_timeout' + - $ref: '#/components/parameters/cat.nodeattrs___query.s' + - $ref: '#/components/parameters/cat.nodeattrs___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.nodeattrs___200' + /_cat/nodes: + get: + operationId: cat.nodes.0 + x-operation-group: cat.nodes + x-version-added: '1.0' + description: Returns basic statistics about the performance of cluster nodes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-nodes/ + parameters: + - $ref: '#/components/parameters/cat.nodes___query.bytes' + - $ref: '#/components/parameters/cat.nodes___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.nodes___query.format' + - $ref: '#/components/parameters/cat.nodes___query.full_id' + - $ref: '#/components/parameters/cat.nodes___query.h' + - $ref: '#/components/parameters/cat.nodes___query.help' + - $ref: '#/components/parameters/cat.nodes___query.local' + - $ref: '#/components/parameters/cat.nodes___query.master_timeout' + - $ref: '#/components/parameters/cat.nodes___query.s' + - $ref: '#/components/parameters/cat.nodes___query.time' + - $ref: '#/components/parameters/cat.nodes___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.nodes___200' + /_cat/pending_tasks: + get: + operationId: cat.pending_tasks.0 + x-operation-group: cat.pending_tasks + x-version-added: '1.0' + description: Returns a concise representation of the cluster's pending tasks. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-pending-tasks/ + parameters: + - $ref: '#/components/parameters/cat.pending_tasks___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.pending_tasks___query.format' + - $ref: '#/components/parameters/cat.pending_tasks___query.h' + - $ref: '#/components/parameters/cat.pending_tasks___query.help' + - $ref: '#/components/parameters/cat.pending_tasks___query.local' + - $ref: '#/components/parameters/cat.pending_tasks___query.master_timeout' + - $ref: '#/components/parameters/cat.pending_tasks___query.s' + - $ref: '#/components/parameters/cat.pending_tasks___query.time' + - $ref: '#/components/parameters/cat.pending_tasks___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.pending_tasks___200' + /_cat/pit_segments: + get: + operationId: cat.pit_segments.0 + x-operation-group: cat.pit_segments + x-version-added: '2.4' + description: Lists one or several CAT point-in-time segments. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/ + parameters: + - $ref: '#/components/parameters/cat.pit_segments___query.bytes' + - $ref: '#/components/parameters/cat.pit_segments___query.format' + - $ref: '#/components/parameters/cat.pit_segments___query.h' + - $ref: '#/components/parameters/cat.pit_segments___query.help' + - $ref: '#/components/parameters/cat.pit_segments___query.s' + - $ref: '#/components/parameters/cat.pit_segments___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/cat.pit_segments' + responses: + '200': + $ref: '#/components/responses/cat.pit_segments___200' + /_cat/pit_segments/_all: + get: + operationId: cat.all_pit_segments.0 + x-operation-group: cat.all_pit_segments + x-version-added: '2.4' + description: Lists all active CAT point-in-time segments. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/ + parameters: + - $ref: '#/components/parameters/cat.all_pit_segments___query.bytes' + - $ref: '#/components/parameters/cat.all_pit_segments___query.format' + - $ref: '#/components/parameters/cat.all_pit_segments___query.h' + - $ref: '#/components/parameters/cat.all_pit_segments___query.help' + - $ref: '#/components/parameters/cat.all_pit_segments___query.s' + - $ref: '#/components/parameters/cat.all_pit_segments___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.all_pit_segments___200' + /_cat/plugins: + get: + operationId: cat.plugins.0 + x-operation-group: cat.plugins + x-version-added: '1.0' + description: Returns information about the names, components, and versions of the installed plugins. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-plugins/ + parameters: + - $ref: '#/components/parameters/cat.plugins___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.plugins___query.format' + - $ref: '#/components/parameters/cat.plugins___query.h' + - $ref: '#/components/parameters/cat.plugins___query.help' + - $ref: '#/components/parameters/cat.plugins___query.local' + - $ref: '#/components/parameters/cat.plugins___query.master_timeout' + - $ref: '#/components/parameters/cat.plugins___query.s' + - $ref: '#/components/parameters/cat.plugins___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.plugins___200' + /_cat/recovery: + get: + operationId: cat.recovery.0 + x-operation-group: cat.recovery + x-version-added: '1.0' + description: Returns all completed and ongoing index and shard recoveries. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-plugins/ + parameters: + - $ref: '#/components/parameters/cat.recovery___query.active_only' + - $ref: '#/components/parameters/cat.recovery___query.bytes' + - $ref: '#/components/parameters/cat.recovery___query.detailed' + - $ref: '#/components/parameters/cat.recovery___query.format' + - $ref: '#/components/parameters/cat.recovery___query.h' + - $ref: '#/components/parameters/cat.recovery___query.help' + - $ref: '#/components/parameters/cat.recovery___query.index' + - $ref: '#/components/parameters/cat.recovery___query.s' + - $ref: '#/components/parameters/cat.recovery___query.time' + - $ref: '#/components/parameters/cat.recovery___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.recovery___200' + /_cat/recovery/{index}: + get: + operationId: cat.recovery.1 + x-operation-group: cat.recovery + x-version-added: '1.0' + description: Returns all completed and ongoing index and shard recoveries. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-plugins/ + parameters: + - $ref: '#/components/parameters/cat.recovery___path.index' + - $ref: '#/components/parameters/cat.recovery___query.active_only' + - $ref: '#/components/parameters/cat.recovery___query.bytes' + - $ref: '#/components/parameters/cat.recovery___query.detailed' + - $ref: '#/components/parameters/cat.recovery___query.format' + - $ref: '#/components/parameters/cat.recovery___query.h' + - $ref: '#/components/parameters/cat.recovery___query.help' + - $ref: '#/components/parameters/cat.recovery___query.index' + - $ref: '#/components/parameters/cat.recovery___query.s' + - $ref: '#/components/parameters/cat.recovery___query.time' + - $ref: '#/components/parameters/cat.recovery___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.recovery___200' + /_cat/repositories: + get: + operationId: cat.repositories.0 + x-operation-group: cat.repositories + x-version-added: '1.0' + description: Returns information about all snapshot repositories for a cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-repositories/ + parameters: + - $ref: '#/components/parameters/cat.repositories___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.repositories___query.format' + - $ref: '#/components/parameters/cat.repositories___query.h' + - $ref: '#/components/parameters/cat.repositories___query.help' + - $ref: '#/components/parameters/cat.repositories___query.local' + - $ref: '#/components/parameters/cat.repositories___query.master_timeout' + - $ref: '#/components/parameters/cat.repositories___query.s' + - $ref: '#/components/parameters/cat.repositories___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.repositories___200' + /_cat/segment_replication: + get: + operationId: cat.segment_replication.0 + x-operation-group: cat.segment_replication + x-version-added: '2.6' + description: |- + Returns information about active and last-completed segment replication events on each replica shard, including related shard-level metrics. + These metrics provide information about how far behind the primary shard the replicas are lagging. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-segment-replication/ + parameters: + - $ref: '#/components/parameters/cat.segment_replication___query.active_only' + - $ref: '#/components/parameters/cat.segment_replication___query.allow_no_indices' + - $ref: '#/components/parameters/cat.segment_replication___query.bytes' + - $ref: '#/components/parameters/cat.segment_replication___query.completed_only' + - $ref: '#/components/parameters/cat.segment_replication___query.detailed' + - $ref: '#/components/parameters/cat.segment_replication___query.expand_wildcards' + - $ref: '#/components/parameters/cat.segment_replication___query.format' + - $ref: '#/components/parameters/cat.segment_replication___query.h' + - $ref: '#/components/parameters/cat.segment_replication___query.help' + - $ref: '#/components/parameters/cat.segment_replication___query.ignore_throttled' + - $ref: '#/components/parameters/cat.segment_replication___query.ignore_unavailable' + - $ref: '#/components/parameters/cat.segment_replication___query.index' + - $ref: '#/components/parameters/cat.segment_replication___query.s' + - $ref: '#/components/parameters/cat.segment_replication___query.shards' + - $ref: '#/components/parameters/cat.segment_replication___query.time' + - $ref: '#/components/parameters/cat.segment_replication___query.timeout' + - $ref: '#/components/parameters/cat.segment_replication___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.segment_replication___200' + /_cat/segment_replication/{index}: + get: + operationId: cat.segment_replication.1 + x-operation-group: cat.segment_replication + x-version-added: '2.6' + description: |- + Returns information about active and last-completed segment replication events on each replica shard, including related shard-level metrics. + These metrics provide information about how far behind the primary shard the replicas are lagging. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-segment-replication/ + parameters: + - $ref: '#/components/parameters/cat.segment_replication___path.index' + - $ref: '#/components/parameters/cat.segment_replication___query.active_only' + - $ref: '#/components/parameters/cat.segment_replication___query.allow_no_indices' + - $ref: '#/components/parameters/cat.segment_replication___query.bytes' + - $ref: '#/components/parameters/cat.segment_replication___query.completed_only' + - $ref: '#/components/parameters/cat.segment_replication___query.detailed' + - $ref: '#/components/parameters/cat.segment_replication___query.expand_wildcards' + - $ref: '#/components/parameters/cat.segment_replication___query.format' + - $ref: '#/components/parameters/cat.segment_replication___query.h' + - $ref: '#/components/parameters/cat.segment_replication___query.help' + - $ref: '#/components/parameters/cat.segment_replication___query.ignore_throttled' + - $ref: '#/components/parameters/cat.segment_replication___query.ignore_unavailable' + - $ref: '#/components/parameters/cat.segment_replication___query.index' + - $ref: '#/components/parameters/cat.segment_replication___query.s' + - $ref: '#/components/parameters/cat.segment_replication___query.shards' + - $ref: '#/components/parameters/cat.segment_replication___query.time' + - $ref: '#/components/parameters/cat.segment_replication___query.timeout' + - $ref: '#/components/parameters/cat.segment_replication___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.segment_replication___200' + /_cat/segments: + get: + operationId: cat.segments.0 + x-operation-group: cat.segments + x-version-added: '1.0' + description: Provides low-level information about the segments in the shards of an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-segments/ + parameters: + - $ref: '#/components/parameters/cat.segments___query.bytes' + - $ref: '#/components/parameters/cat.segments___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.segments___query.format' + - $ref: '#/components/parameters/cat.segments___query.h' + - $ref: '#/components/parameters/cat.segments___query.help' + - $ref: '#/components/parameters/cat.segments___query.master_timeout' + - $ref: '#/components/parameters/cat.segments___query.s' + - $ref: '#/components/parameters/cat.segments___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.segments___200' + /_cat/segments/{index}: + get: + operationId: cat.segments.1 + x-operation-group: cat.segments + x-version-added: '1.0' + description: Provides low-level information about the segments in the shards of an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-segments/ + parameters: + - $ref: '#/components/parameters/cat.segments___path.index' + - $ref: '#/components/parameters/cat.segments___query.bytes' + - $ref: '#/components/parameters/cat.segments___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.segments___query.format' + - $ref: '#/components/parameters/cat.segments___query.h' + - $ref: '#/components/parameters/cat.segments___query.help' + - $ref: '#/components/parameters/cat.segments___query.master_timeout' + - $ref: '#/components/parameters/cat.segments___query.s' + - $ref: '#/components/parameters/cat.segments___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.segments___200' + /_cat/shards: + get: + operationId: cat.shards.0 + x-operation-group: cat.shards + x-version-added: '1.0' + description: Lists the states of all primary and replica shards and how they are distributed. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-shards/ + parameters: + - $ref: '#/components/parameters/cat.shards___query.bytes' + - $ref: '#/components/parameters/cat.shards___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.shards___query.format' + - $ref: '#/components/parameters/cat.shards___query.h' + - $ref: '#/components/parameters/cat.shards___query.help' + - $ref: '#/components/parameters/cat.shards___query.local' + - $ref: '#/components/parameters/cat.shards___query.master_timeout' + - $ref: '#/components/parameters/cat.shards___query.s' + - $ref: '#/components/parameters/cat.shards___query.time' + - $ref: '#/components/parameters/cat.shards___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.shards___200' + /_cat/shards/{index}: + get: + operationId: cat.shards.1 + x-operation-group: cat.shards + x-version-added: '1.0' + description: Lists the states of all primary and replica shards and how they are distributed. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-shards/ + parameters: + - $ref: '#/components/parameters/cat.shards___path.index' + - $ref: '#/components/parameters/cat.shards___query.bytes' + - $ref: '#/components/parameters/cat.shards___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.shards___query.format' + - $ref: '#/components/parameters/cat.shards___query.h' + - $ref: '#/components/parameters/cat.shards___query.help' + - $ref: '#/components/parameters/cat.shards___query.local' + - $ref: '#/components/parameters/cat.shards___query.master_timeout' + - $ref: '#/components/parameters/cat.shards___query.s' + - $ref: '#/components/parameters/cat.shards___query.time' + - $ref: '#/components/parameters/cat.shards___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.shards___200' + /_cat/snapshots: + get: + operationId: cat.snapshots.0 + x-operation-group: cat.snapshots + x-version-added: '1.0' + description: Lists all of the snapshots stored in a specific repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-snapshots/ + parameters: + - $ref: '#/components/parameters/cat.snapshots___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.snapshots___query.format' + - $ref: '#/components/parameters/cat.snapshots___query.h' + - $ref: '#/components/parameters/cat.snapshots___query.help' + - $ref: '#/components/parameters/cat.snapshots___query.ignore_unavailable' + - $ref: '#/components/parameters/cat.snapshots___query.master_timeout' + - $ref: '#/components/parameters/cat.snapshots___query.repository' + - $ref: '#/components/parameters/cat.snapshots___query.s' + - $ref: '#/components/parameters/cat.snapshots___query.time' + - $ref: '#/components/parameters/cat.snapshots___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.snapshots___200' + /_cat/snapshots/{repository}: + get: + operationId: cat.snapshots.1 + x-operation-group: cat.snapshots + x-version-added: '1.0' + description: Lists all of the snapshots stored in a specific repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-snapshots/ + parameters: + - $ref: '#/components/parameters/cat.snapshots___path.repository' + - $ref: '#/components/parameters/cat.snapshots___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.snapshots___query.format' + - $ref: '#/components/parameters/cat.snapshots___query.h' + - $ref: '#/components/parameters/cat.snapshots___query.help' + - $ref: '#/components/parameters/cat.snapshots___query.ignore_unavailable' + - $ref: '#/components/parameters/cat.snapshots___query.master_timeout' + - $ref: '#/components/parameters/cat.snapshots___query.repository' + - $ref: '#/components/parameters/cat.snapshots___query.s' + - $ref: '#/components/parameters/cat.snapshots___query.time' + - $ref: '#/components/parameters/cat.snapshots___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.snapshots___200' + /_cat/tasks: + get: + operationId: cat.tasks.0 + x-operation-group: cat.tasks + x-version-added: '1.0' + description: Lists the progress of all tasks currently running on the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-tasks/ + parameters: + - $ref: '#/components/parameters/cat.tasks___query.actions' + - $ref: '#/components/parameters/cat.tasks___query.detailed' + - $ref: '#/components/parameters/cat.tasks___query.format' + - $ref: '#/components/parameters/cat.tasks___query.h' + - $ref: '#/components/parameters/cat.tasks___query.help' + - $ref: '#/components/parameters/cat.tasks___query.nodes' + - $ref: '#/components/parameters/cat.tasks___query.parent_task_id' + - $ref: '#/components/parameters/cat.tasks___query.s' + - $ref: '#/components/parameters/cat.tasks___query.time' + - $ref: '#/components/parameters/cat.tasks___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.tasks___200' + /_cat/templates: + get: + operationId: cat.templates.0 + x-operation-group: cat.templates + x-version-added: '1.0' + description: Lists the names, patterns, order numbers, and version numbers of index templates. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-templates/ + parameters: + - $ref: '#/components/parameters/cat.templates___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.templates___query.format' + - $ref: '#/components/parameters/cat.templates___query.h' + - $ref: '#/components/parameters/cat.templates___query.help' + - $ref: '#/components/parameters/cat.templates___query.local' + - $ref: '#/components/parameters/cat.templates___query.master_timeout' + - $ref: '#/components/parameters/cat.templates___query.s' + - $ref: '#/components/parameters/cat.templates___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.templates___200' + /_cat/templates/{name}: + get: + operationId: cat.templates.1 + x-operation-group: cat.templates + x-version-added: '1.0' + description: Lists the names, patterns, order numbers, and version numbers of index templates. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-templates/ + parameters: + - $ref: '#/components/parameters/cat.templates___path.name' + - $ref: '#/components/parameters/cat.templates___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.templates___query.format' + - $ref: '#/components/parameters/cat.templates___query.h' + - $ref: '#/components/parameters/cat.templates___query.help' + - $ref: '#/components/parameters/cat.templates___query.local' + - $ref: '#/components/parameters/cat.templates___query.master_timeout' + - $ref: '#/components/parameters/cat.templates___query.s' + - $ref: '#/components/parameters/cat.templates___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.templates___200' + /_cat/thread_pool: + get: + operationId: cat.thread_pool.0 + x-operation-group: cat.thread_pool + x-version-added: '1.0' + description: |- + Returns cluster-wide thread pool statistics per node. + By default the active, queued, and rejected statistics are returned for all thread pools. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-thread-pool/ + parameters: + - $ref: '#/components/parameters/cat.thread_pool___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.thread_pool___query.format' + - $ref: '#/components/parameters/cat.thread_pool___query.h' + - $ref: '#/components/parameters/cat.thread_pool___query.help' + - $ref: '#/components/parameters/cat.thread_pool___query.local' + - $ref: '#/components/parameters/cat.thread_pool___query.master_timeout' + - $ref: '#/components/parameters/cat.thread_pool___query.s' + - $ref: '#/components/parameters/cat.thread_pool___query.size' + - $ref: '#/components/parameters/cat.thread_pool___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.thread_pool___200' + /_cat/thread_pool/{thread_pool_patterns}: + get: + operationId: cat.thread_pool.1 + x-operation-group: cat.thread_pool + x-version-added: '1.0' + description: |- + Returns cluster-wide thread pool statistics per node. + By default the active, queued, and rejected statistics are returned for all thread pools. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cat/cat-thread-pool/ + parameters: + - $ref: '#/components/parameters/cat.thread_pool___path.thread_pool_patterns' + - $ref: '#/components/parameters/cat.thread_pool___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cat.thread_pool___query.format' + - $ref: '#/components/parameters/cat.thread_pool___query.h' + - $ref: '#/components/parameters/cat.thread_pool___query.help' + - $ref: '#/components/parameters/cat.thread_pool___query.local' + - $ref: '#/components/parameters/cat.thread_pool___query.master_timeout' + - $ref: '#/components/parameters/cat.thread_pool___query.s' + - $ref: '#/components/parameters/cat.thread_pool___query.size' + - $ref: '#/components/parameters/cat.thread_pool___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cat.thread_pool___200' + /_cluster/allocation/explain: + get: + operationId: cluster.allocation_explain.0 + x-operation-group: cluster.allocation_explain + x-version-added: '1.0' + description: Explains how shards are allocated in the current cluster and provides an explanation for why unassigned shards can't be allocated to a node. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-allocation/ + parameters: + - $ref: '#/components/parameters/cluster.allocation_explain___query.include_disk_info' + - $ref: '#/components/parameters/cluster.allocation_explain___query.include_yes_decisions' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/cluster.allocation_explain' + responses: + '200': + $ref: '#/components/responses/cluster.allocation_explain___200' + post: + operationId: cluster.allocation_explain.1 + x-operation-group: cluster.allocation_explain + x-version-added: '1.0' + description: Explains how shards are allocated in the current cluster and provides an explanation for why unassigned shards can't be allocated to a node. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-allocation/ + parameters: + - $ref: '#/components/parameters/cluster.allocation_explain___query.include_disk_info' + - $ref: '#/components/parameters/cluster.allocation_explain___query.include_yes_decisions' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/cluster.allocation_explain' + responses: + '200': + $ref: '#/components/responses/cluster.allocation_explain___200' + /_cluster/decommission/awareness: + delete: + operationId: cluster.delete_decommission_awareness.0 + x-operation-group: cluster.delete_decommission_awareness + x-version-added: '1.0' + description: Recommissions a decommissioned zone. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-decommission/#example-decommissioning-and-recommissioning-a-zone + responses: + '200': + $ref: '#/components/responses/cluster.delete_decommission_awareness___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_cluster/decommission/awareness/{awareness_attribute_name}/_status: + get: + operationId: cluster.get_decommission_awareness.0 + x-operation-group: cluster.get_decommission_awareness + x-version-added: '1.0' + description: Retrieves the decommission status for all zones. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-decommission/#example-getting-zone-decommission-status + parameters: + - $ref: '#/components/parameters/cluster.get_decommission_awareness___path.awareness_attribute_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.get_decommission_awareness___200' + /_cluster/decommission/awareness/{awareness_attribute_name}/{awareness_attribute_value}: + put: + operationId: cluster.put_decommission_awareness.0 + x-operation-group: cluster.put_decommission_awareness + x-version-added: '1.0' + description: Decommissions a cluster zone based on awareness. This can greatly benefit multi-zone deployments, where awareness attributes can aid in applying new upgrades to a cluster in a controlled fashion. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-decommission/#example-decommissioning-and-recommissioning-a-zone + parameters: + - $ref: '#/components/parameters/cluster.put_decommission_awareness___path.awareness_attribute_name' + - $ref: '#/components/parameters/cluster.put_decommission_awareness___path.awareness_attribute_value' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.put_decommission_awareness___200' + /_cluster/health: + get: + operationId: cluster.health.0 + x-operation-group: cluster.health + x-version-added: '1.0' + description: Returns basic information about the health of the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-health/ + parameters: + - $ref: '#/components/parameters/cluster.health___query.awareness_attribute' + - $ref: '#/components/parameters/cluster.health___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.health___query.expand_wildcards' + - $ref: '#/components/parameters/cluster.health___query.level' + - $ref: '#/components/parameters/cluster.health___query.local' + - $ref: '#/components/parameters/cluster.health___query.master_timeout' + - $ref: '#/components/parameters/cluster.health___query.timeout' + - $ref: '#/components/parameters/cluster.health___query.wait_for_active_shards' + - $ref: '#/components/parameters/cluster.health___query.wait_for_events' + - $ref: '#/components/parameters/cluster.health___query.wait_for_no_initializing_shards' + - $ref: '#/components/parameters/cluster.health___query.wait_for_no_relocating_shards' + - $ref: '#/components/parameters/cluster.health___query.wait_for_nodes' + - $ref: '#/components/parameters/cluster.health___query.wait_for_status' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.health___200' + /_cluster/health/{index}: + get: + operationId: cluster.health.1 + x-operation-group: cluster.health + x-version-added: '1.0' + description: Returns basic information about the health of the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-health/ + parameters: + - $ref: '#/components/parameters/cluster.health___path.index' + - $ref: '#/components/parameters/cluster.health___query.awareness_attribute' + - $ref: '#/components/parameters/cluster.health___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.health___query.expand_wildcards' + - $ref: '#/components/parameters/cluster.health___query.level' + - $ref: '#/components/parameters/cluster.health___query.local' + - $ref: '#/components/parameters/cluster.health___query.master_timeout' + - $ref: '#/components/parameters/cluster.health___query.timeout' + - $ref: '#/components/parameters/cluster.health___query.wait_for_active_shards' + - $ref: '#/components/parameters/cluster.health___query.wait_for_events' + - $ref: '#/components/parameters/cluster.health___query.wait_for_no_initializing_shards' + - $ref: '#/components/parameters/cluster.health___query.wait_for_no_relocating_shards' + - $ref: '#/components/parameters/cluster.health___query.wait_for_nodes' + - $ref: '#/components/parameters/cluster.health___query.wait_for_status' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.health___200' + /_cluster/nodes/{node_id}/hot_threads: + get: + operationId: nodes.hot_threads.2 + x-operation-group: nodes.hot_threads + x-ignorable: true + deprecated: true + x-deprecation-message: The hot accepts /_cluster/nodes as prefix for backwards compatibility reasons + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: Returns information about hot threads on each node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ + parameters: + - $ref: '#/components/parameters/nodes.hot_threads___path.node_id' + - $ref: '#/components/parameters/nodes.hot_threads___query.ignore_idle_threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.interval' + - $ref: '#/components/parameters/nodes.hot_threads___query.snapshots' + - $ref: '#/components/parameters/nodes.hot_threads___query.threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.timeout' + - $ref: '#/components/parameters/nodes.hot_threads___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.hot_threads___200' + /_cluster/nodes/hot_threads: + get: + operationId: nodes.hot_threads.0 + x-operation-group: nodes.hot_threads + x-ignorable: true + deprecated: true + x-deprecation-message: The hot accepts /_cluster/nodes as prefix for backwards compatibility reasons + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: Returns information about hot threads on each node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ + parameters: + - $ref: '#/components/parameters/nodes.hot_threads___query.ignore_idle_threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.interval' + - $ref: '#/components/parameters/nodes.hot_threads___query.snapshots' + - $ref: '#/components/parameters/nodes.hot_threads___query.threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.timeout' + - $ref: '#/components/parameters/nodes.hot_threads___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.hot_threads___200' + /_cluster/pending_tasks: + get: + operationId: cluster.pending_tasks.0 + x-operation-group: cluster.pending_tasks + x-version-added: '1.0' + description: |- + Returns a list of pending cluster-level tasks, such as index creation, mapping updates, + or new allocations. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.pending_tasks___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.pending_tasks___query.local' + - $ref: '#/components/parameters/cluster.pending_tasks___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.pending_tasks___200' + /_cluster/reroute: + post: + operationId: cluster.reroute.0 + x-operation-group: cluster.reroute + x-version-added: '1.0' + description: Allows to manually change the allocation of individual shards in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.reroute___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.reroute___query.dry_run' + - $ref: '#/components/parameters/cluster.reroute___query.explain' + - $ref: '#/components/parameters/cluster.reroute___query.master_timeout' + - $ref: '#/components/parameters/cluster.reroute___query.metric' + - $ref: '#/components/parameters/cluster.reroute___query.retry_failed' + - $ref: '#/components/parameters/cluster.reroute___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/cluster.reroute' + responses: + '200': + $ref: '#/components/responses/cluster.reroute___200' + /_cluster/routing/awareness/{attribute}/weights: + get: + operationId: cluster.get_weighted_routing.0 + x-operation-group: cluster.get_weighted_routing + x-version-added: '1.0' + description: Fetches weighted shard routing weights. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-awareness/#example-getting-weights-for-all-zones + parameters: + - $ref: '#/components/parameters/cluster.get_weighted_routing___path.attribute' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.get_weighted_routing___200' + put: + operationId: cluster.put_weighted_routing.0 + x-operation-group: cluster.put_weighted_routing + x-version-added: '1.0' + description: Updates weighted shard routing weights. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-awareness/#example-weighted-round-robin-search + parameters: + - $ref: '#/components/parameters/cluster.put_weighted_routing___path.attribute' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/cluster.put_weighted_routing' + responses: + '200': + $ref: '#/components/responses/cluster.put_weighted_routing___200' + /_cluster/routing/awareness/weights: + delete: + operationId: cluster.delete_weighted_routing.0 + x-operation-group: cluster.delete_weighted_routing + x-version-added: '1.0' + description: Delete weighted shard routing weights. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-awareness/#example-deleting-weights + requestBody: + $ref: '#/components/requestBodies/cluster.delete_weighted_routing' + responses: + '200': + $ref: '#/components/responses/cluster.delete_weighted_routing___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_cluster/settings: + get: + operationId: cluster.get_settings.0 + x-operation-group: cluster.get_settings + x-version-added: '1.0' + description: Returns cluster settings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-settings/ + parameters: + - $ref: '#/components/parameters/cluster.get_settings___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.get_settings___query.flat_settings' + - $ref: '#/components/parameters/cluster.get_settings___query.include_defaults' + - $ref: '#/components/parameters/cluster.get_settings___query.master_timeout' + - $ref: '#/components/parameters/cluster.get_settings___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.get_settings___200' + put: + operationId: cluster.put_settings.0 + x-operation-group: cluster.put_settings + x-version-added: '1.0' + description: Updates the cluster settings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-settings/ + parameters: + - $ref: '#/components/parameters/cluster.put_settings___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.put_settings___query.flat_settings' + - $ref: '#/components/parameters/cluster.put_settings___query.master_timeout' + - $ref: '#/components/parameters/cluster.put_settings___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/cluster.put_settings' + responses: + '200': + $ref: '#/components/responses/cluster.put_settings___200' + /_cluster/state: + get: + operationId: cluster.state.0 + x-operation-group: cluster.state + x-version-added: '1.0' + description: Returns comprehensive information about the state of the cluster. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.state___query.allow_no_indices' + - $ref: '#/components/parameters/cluster.state___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.state___query.expand_wildcards' + - $ref: '#/components/parameters/cluster.state___query.flat_settings' + - $ref: '#/components/parameters/cluster.state___query.ignore_unavailable' + - $ref: '#/components/parameters/cluster.state___query.local' + - $ref: '#/components/parameters/cluster.state___query.master_timeout' + - $ref: '#/components/parameters/cluster.state___query.wait_for_metadata_version' + - $ref: '#/components/parameters/cluster.state___query.wait_for_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.state___200' + /_cluster/state/{metric}: + get: + operationId: cluster.state.1 + x-operation-group: cluster.state + x-version-added: '1.0' + description: Returns comprehensive information about the state of the cluster. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.state___path.metric' + - $ref: '#/components/parameters/cluster.state___query.allow_no_indices' + - $ref: '#/components/parameters/cluster.state___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.state___query.expand_wildcards' + - $ref: '#/components/parameters/cluster.state___query.flat_settings' + - $ref: '#/components/parameters/cluster.state___query.ignore_unavailable' + - $ref: '#/components/parameters/cluster.state___query.local' + - $ref: '#/components/parameters/cluster.state___query.master_timeout' + - $ref: '#/components/parameters/cluster.state___query.wait_for_metadata_version' + - $ref: '#/components/parameters/cluster.state___query.wait_for_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.state___200' + /_cluster/state/{metric}/{index}: + get: + operationId: cluster.state.2 + x-operation-group: cluster.state + x-version-added: '1.0' + description: Returns comprehensive information about the state of the cluster. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.state___path.index' + - $ref: '#/components/parameters/cluster.state___path.metric' + - $ref: '#/components/parameters/cluster.state___query.allow_no_indices' + - $ref: '#/components/parameters/cluster.state___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.state___query.expand_wildcards' + - $ref: '#/components/parameters/cluster.state___query.flat_settings' + - $ref: '#/components/parameters/cluster.state___query.ignore_unavailable' + - $ref: '#/components/parameters/cluster.state___query.local' + - $ref: '#/components/parameters/cluster.state___query.master_timeout' + - $ref: '#/components/parameters/cluster.state___query.wait_for_metadata_version' + - $ref: '#/components/parameters/cluster.state___query.wait_for_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.state___200' + /_cluster/stats: + get: + operationId: cluster.stats.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: cluster.stats + x-version-added: '1.0' + description: Returns a high-level overview of cluster statistics. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-stats/ + parameters: + - $ref: '#/components/parameters/cluster.stats___query.flat_settings' + - $ref: '#/components/parameters/cluster.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.stats___200' + /_cluster/stats/{metric}/{index_metric}/nodes/{node_id}: + get: + operationId: cluster.stats.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: cluster.stats + x-version-added: '2.18' + description: Returns a high-level overview of cluster statistics. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-stats/ + parameters: + - $ref: '#/components/parameters/cluster.stats___path.index_metric' + - $ref: '#/components/parameters/cluster.stats___path.metric' + - $ref: '#/components/parameters/cluster.stats___path.node_id' + - $ref: '#/components/parameters/cluster.stats___query.flat_settings' + - $ref: '#/components/parameters/cluster.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.stats___200' + /_cluster/stats/{metric}/nodes/{node_id}: + get: + operationId: cluster.stats.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: cluster.stats + x-version-added: '2.18' + description: Returns a high-level overview of cluster statistics. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-stats/ + parameters: + - $ref: '#/components/parameters/cluster.stats___path.metric' + - $ref: '#/components/parameters/cluster.stats___path.node_id' + - $ref: '#/components/parameters/cluster.stats___query.flat_settings' + - $ref: '#/components/parameters/cluster.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.stats___200' + /_cluster/stats/nodes/{node_id}: + get: + operationId: cluster.stats.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: cluster.stats + x-version-added: '1.0' + description: Returns a high-level overview of cluster statistics. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/cluster-api/cluster-stats/ + parameters: + - $ref: '#/components/parameters/cluster.stats___path.node_id' + - $ref: '#/components/parameters/cluster.stats___query.flat_settings' + - $ref: '#/components/parameters/cluster.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.stats___200' + /_cluster/voting_config_exclusions: + delete: + operationId: cluster.delete_voting_config_exclusions.0 + x-operation-group: cluster.delete_voting_config_exclusions + x-version-added: '1.0' + description: Clears any cluster voting configuration exclusions. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.delete_voting_config_exclusions___query.wait_for_removal' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.delete_voting_config_exclusions___200' + post: + operationId: cluster.post_voting_config_exclusions.0 + x-operation-group: cluster.post_voting_config_exclusions + x-version-added: '1.0' + description: Updates the cluster voting configuration by excluding certain node IDs or names. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.post_voting_config_exclusions___query.node_ids' + - $ref: '#/components/parameters/cluster.post_voting_config_exclusions___query.node_names' + - $ref: '#/components/parameters/cluster.post_voting_config_exclusions___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.post_voting_config_exclusions___200' + /_component_template: + get: + operationId: cluster.get_component_template.0 + x-operation-group: cluster.get_component_template + x-version-added: '1.0' + description: Returns one or more component templates. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.get_component_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.get_component_template___query.flat_settings' + - $ref: '#/components/parameters/cluster.get_component_template___query.local' + - $ref: '#/components/parameters/cluster.get_component_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.get_component_template___200' + /_component_template/{name}: + delete: + operationId: cluster.delete_component_template.0 + x-operation-group: cluster.delete_component_template + x-version-added: '1.0' + description: Deletes a component template. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.delete_component_template___path.name' + - $ref: '#/components/parameters/cluster.delete_component_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.delete_component_template___query.master_timeout' + - $ref: '#/components/parameters/cluster.delete_component_template___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.delete_component_template___200' + get: + operationId: cluster.get_component_template.1 + x-operation-group: cluster.get_component_template + x-version-added: '1.0' + description: Returns one or more component templates. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.get_component_template___path.name' + - $ref: '#/components/parameters/cluster.get_component_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.get_component_template___query.flat_settings' + - $ref: '#/components/parameters/cluster.get_component_template___query.local' + - $ref: '#/components/parameters/cluster.get_component_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.get_component_template___200' + head: + operationId: cluster.exists_component_template.0 + x-operation-group: cluster.exists_component_template + x-version-added: '1.0' + description: Returns information about whether a particular component template exist. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/cluster.exists_component_template___path.name' + - $ref: '#/components/parameters/cluster.exists_component_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.exists_component_template___query.local' + - $ref: '#/components/parameters/cluster.exists_component_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.exists_component_template___200' + post: + operationId: cluster.put_component_template.0 + x-operation-group: cluster.put_component_template + x-version-added: '1.0' + description: Creates or updates a component template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/#use-component-templates-to-create-an-index-template + parameters: + - $ref: '#/components/parameters/cluster.put_component_template___path.name' + - $ref: '#/components/parameters/cluster.put_component_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.put_component_template___query.create' + - $ref: '#/components/parameters/cluster.put_component_template___query.master_timeout' + - $ref: '#/components/parameters/cluster.put_component_template___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/cluster.put_component_template' + responses: + '200': + $ref: '#/components/responses/cluster.put_component_template___200' + put: + operationId: cluster.put_component_template.1 + x-operation-group: cluster.put_component_template + x-version-added: '1.0' + description: Creates or updates a component template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/#use-component-templates-to-create-an-index-template + parameters: + - $ref: '#/components/parameters/cluster.put_component_template___path.name' + - $ref: '#/components/parameters/cluster.put_component_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/cluster.put_component_template___query.create' + - $ref: '#/components/parameters/cluster.put_component_template___query.master_timeout' + - $ref: '#/components/parameters/cluster.put_component_template___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/cluster.put_component_template' + responses: + '200': + $ref: '#/components/responses/cluster.put_component_template___200' + /_count: + get: + operationId: count.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: count + x-version-added: '1.0' + description: Returns number of documents matching a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/count/ + parameters: + - $ref: '#/components/parameters/count___query.allow_no_indices' + - $ref: '#/components/parameters/count___query.analyze_wildcard' + - $ref: '#/components/parameters/count___query.analyzer' + - $ref: '#/components/parameters/count___query.default_operator' + - $ref: '#/components/parameters/count___query.df' + - $ref: '#/components/parameters/count___query.expand_wildcards' + - $ref: '#/components/parameters/count___query.ignore_throttled' + - $ref: '#/components/parameters/count___query.ignore_unavailable' + - $ref: '#/components/parameters/count___query.lenient' + - $ref: '#/components/parameters/count___query.min_score' + - $ref: '#/components/parameters/count___query.preference' + - $ref: '#/components/parameters/count___query.q' + - $ref: '#/components/parameters/count___query.routing' + - $ref: '#/components/parameters/count___query.terminate_after' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/count' + responses: + '200': + $ref: '#/components/responses/count___200' + post: + operationId: count.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: count + x-version-added: '1.0' + description: Returns number of documents matching a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/count/ + parameters: + - $ref: '#/components/parameters/count___query.allow_no_indices' + - $ref: '#/components/parameters/count___query.analyze_wildcard' + - $ref: '#/components/parameters/count___query.analyzer' + - $ref: '#/components/parameters/count___query.default_operator' + - $ref: '#/components/parameters/count___query.df' + - $ref: '#/components/parameters/count___query.expand_wildcards' + - $ref: '#/components/parameters/count___query.ignore_throttled' + - $ref: '#/components/parameters/count___query.ignore_unavailable' + - $ref: '#/components/parameters/count___query.lenient' + - $ref: '#/components/parameters/count___query.min_score' + - $ref: '#/components/parameters/count___query.preference' + - $ref: '#/components/parameters/count___query.q' + - $ref: '#/components/parameters/count___query.routing' + - $ref: '#/components/parameters/count___query.terminate_after' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/count' + responses: + '200': + $ref: '#/components/responses/count___200' + /_dangling: + get: + operationId: dangling_indices.list_dangling_indices.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: dangling_indices.list_dangling_indices + x-version-added: '1.0' + description: Returns all dangling indexes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/dangling-index/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/dangling_indices.list_dangling_indices___200' + /_dangling/{index_uuid}: + delete: + operationId: dangling_indices.delete_dangling_index.0 + x-operation-group: dangling_indices.delete_dangling_index + x-version-added: '1.0' + description: Deletes the specified dangling index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/dangling-index/ + parameters: + - $ref: '#/components/parameters/dangling_indices.delete_dangling_index___path.index_uuid' + - $ref: '#/components/parameters/dangling_indices.delete_dangling_index___query.accept_data_loss' + - $ref: '#/components/parameters/dangling_indices.delete_dangling_index___query.cluster_manager_timeout' + - $ref: '#/components/parameters/dangling_indices.delete_dangling_index___query.master_timeout' + - $ref: '#/components/parameters/dangling_indices.delete_dangling_index___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '202': + $ref: '#/components/responses/dangling_indices.delete_dangling_index___202' + post: + operationId: dangling_indices.import_dangling_index.0 + x-operation-group: dangling_indices.import_dangling_index + x-version-added: '1.0' + description: Imports the specified dangling index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/dangling-index/ + parameters: + - $ref: '#/components/parameters/dangling_indices.import_dangling_index___path.index_uuid' + - $ref: '#/components/parameters/dangling_indices.import_dangling_index___query.accept_data_loss' + - $ref: '#/components/parameters/dangling_indices.import_dangling_index___query.cluster_manager_timeout' + - $ref: '#/components/parameters/dangling_indices.import_dangling_index___query.master_timeout' + - $ref: '#/components/parameters/dangling_indices.import_dangling_index___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '202': + $ref: '#/components/responses/dangling_indices.import_dangling_index___202' + /_data_stream: + get: + operationId: indices.get_data_stream.0 + x-operation-group: indices.get_data_stream + x-version-added: '1.0' + description: Returns data streams. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/data-streams/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_data_stream___200' + /_data_stream/_stats: + get: + operationId: indices.data_streams_stats.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.data_streams_stats + x-version-added: '1.0' + description: Provides statistics on operations happening in a data stream. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/data-streams/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.data_streams_stats___200' + /_data_stream/{name}: + delete: + operationId: indices.delete_data_stream.0 + x-operation-group: indices.delete_data_stream + x-version-added: '1.0' + description: Deletes a data stream. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/data-streams/ + parameters: + - $ref: '#/components/parameters/indices.delete_data_stream___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.delete_data_stream___200' + get: + operationId: indices.get_data_stream.1 + x-operation-group: indices.get_data_stream + x-version-added: '1.0' + description: Returns data streams. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/data-streams/ + parameters: + - $ref: '#/components/parameters/indices.get_data_stream___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_data_stream___200' + put: + operationId: indices.create_data_stream.0 + x-operation-group: indices.create_data_stream + x-version-added: '1.0' + description: Creates or updates a data stream. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/data-streams/ + parameters: + - $ref: '#/components/parameters/indices.create_data_stream___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.create_data_stream' + responses: + '200': + $ref: '#/components/responses/indices.create_data_stream___200' + /_data_stream/{name}/_stats: + get: + operationId: indices.data_streams_stats.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.data_streams_stats + x-version-added: '1.0' + description: Provides statistics on operations happening in a data stream. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/data-streams/ + parameters: + - $ref: '#/components/parameters/indices.data_streams_stats___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.data_streams_stats___200' + /_delete_by_query/{task_id}/_rethrottle: + post: + operationId: delete_by_query_rethrottle.0 + x-operation-group: delete_by_query_rethrottle + x-version-added: '1.0' + description: Changes the number of requests per second for a particular Delete By Query operation. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/delete_by_query_rethrottle___path.task_id' + - $ref: '#/components/parameters/delete_by_query_rethrottle___query.requests_per_second' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/delete_by_query_rethrottle___200' + /_field_caps: + get: + operationId: field_caps.0 + x-operation-group: field_caps + x-version-added: '1.0' + description: Returns the information about the capabilities of fields among multiple indexes. + externalDocs: + url: https://opensearch.org/docs/latest/field-types/supported-field-types/alias/#using-aliases-in-field-capabilities-api-operations + parameters: + - $ref: '#/components/parameters/field_caps___query.allow_no_indices' + - $ref: '#/components/parameters/field_caps___query.expand_wildcards' + - $ref: '#/components/parameters/field_caps___query.fields' + - $ref: '#/components/parameters/field_caps___query.ignore_unavailable' + - $ref: '#/components/parameters/field_caps___query.include_unmapped' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/field_caps' + responses: + '200': + $ref: '#/components/responses/field_caps___200' + post: + operationId: field_caps.1 + x-operation-group: field_caps + x-version-added: '1.0' + description: Returns the information about the capabilities of fields among multiple indexes. + externalDocs: + url: https://opensearch.org/docs/latest/field-types/supported-field-types/alias/#using-aliases-in-field-capabilities-api-operations + parameters: + - $ref: '#/components/parameters/field_caps___query.allow_no_indices' + - $ref: '#/components/parameters/field_caps___query.expand_wildcards' + - $ref: '#/components/parameters/field_caps___query.fields' + - $ref: '#/components/parameters/field_caps___query.ignore_unavailable' + - $ref: '#/components/parameters/field_caps___query.include_unmapped' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/field_caps' + responses: + '200': + $ref: '#/components/responses/field_caps___200' + /_flush: + get: + operationId: indices.flush.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.flush + x-version-added: '1.0' + description: Performs the flush operation on one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.flush___query.allow_no_indices' + - $ref: '#/components/parameters/indices.flush___query.expand_wildcards' + - $ref: '#/components/parameters/indices.flush___query.force' + - $ref: '#/components/parameters/indices.flush___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.flush___query.wait_if_ongoing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.flush___200' + post: + operationId: indices.flush.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.flush + x-version-added: '1.0' + description: Performs the flush operation on one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.flush___query.allow_no_indices' + - $ref: '#/components/parameters/indices.flush___query.expand_wildcards' + - $ref: '#/components/parameters/indices.flush___query.force' + - $ref: '#/components/parameters/indices.flush___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.flush___query.wait_if_ongoing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.flush___200' + /_forcemerge: + post: + operationId: indices.forcemerge.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.forcemerge + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Performs the force merge operation on one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.forcemerge___query.allow_no_indices' + - $ref: '#/components/parameters/indices.forcemerge___query.expand_wildcards' + - $ref: '#/components/parameters/indices.forcemerge___query.flush' + - $ref: '#/components/parameters/indices.forcemerge___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.forcemerge___query.max_num_segments' + - $ref: '#/components/parameters/indices.forcemerge___query.only_expunge_deletes' + - $ref: '#/components/parameters/indices.forcemerge___query.primary_only' + - $ref: '#/components/parameters/indices.forcemerge___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.forcemerge___200' + /_index_template: + get: + operationId: indices.get_index_template.0 + x-operation-group: indices.get_index_template + x-version-added: '1.0' + description: Returns an index template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/ + parameters: + - $ref: '#/components/parameters/indices.get_index_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_index_template___query.flat_settings' + - $ref: '#/components/parameters/indices.get_index_template___query.local' + - $ref: '#/components/parameters/indices.get_index_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_index_template___200' + /_index_template/_simulate: + post: + operationId: indices.simulate_template.0 + x-operation-group: indices.simulate_template + x-version-added: '1.0' + description: Simulate resolving the given template name or body. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.simulate_template___query.cause' + - $ref: '#/components/parameters/indices.simulate_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.simulate_template___query.create' + - $ref: '#/components/parameters/indices.simulate_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.simulate_template' + responses: + '200': + $ref: '#/components/responses/indices.simulate_template___200' + /_index_template/_simulate_index/{name}: + post: + operationId: indices.simulate_index_template.0 + x-operation-group: indices.simulate_index_template + x-version-added: '1.0' + description: Simulate matching the given index name against the index templates in the system. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.simulate_index_template___path.name' + - $ref: '#/components/parameters/indices.simulate_index_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.simulate_index_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.simulate_index_template' + responses: + '200': + $ref: '#/components/responses/indices.simulate_index_template___200' + /_index_template/_simulate/{name}: + post: + operationId: indices.simulate_template.1 + x-operation-group: indices.simulate_template + x-version-added: '1.0' + description: Simulate resolving the given template name or body. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.simulate_template___path.name' + - $ref: '#/components/parameters/indices.simulate_template___query.cause' + - $ref: '#/components/parameters/indices.simulate_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.simulate_template___query.create' + - $ref: '#/components/parameters/indices.simulate_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.simulate_template' + responses: + '200': + $ref: '#/components/responses/indices.simulate_template___200' + /_index_template/{name}: + delete: + operationId: indices.delete_index_template.0 + x-operation-group: indices.delete_index_template + x-version-added: '1.0' + description: Deletes an index template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/#delete-a-template + parameters: + - $ref: '#/components/parameters/indices.delete_index_template___path.name' + - $ref: '#/components/parameters/indices.delete_index_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.delete_index_template___query.master_timeout' + - $ref: '#/components/parameters/indices.delete_index_template___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.delete_index_template___200' + get: + operationId: indices.get_index_template.1 + x-operation-group: indices.get_index_template + x-version-added: '1.0' + description: Returns an index template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/ + parameters: + - $ref: '#/components/parameters/indices.get_index_template___path.name' + - $ref: '#/components/parameters/indices.get_index_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_index_template___query.flat_settings' + - $ref: '#/components/parameters/indices.get_index_template___query.local' + - $ref: '#/components/parameters/indices.get_index_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_index_template___200' + head: + operationId: indices.exists_index_template.0 + x-operation-group: indices.exists_index_template + x-version-added: '1.0' + description: Returns information about whether a particular index template exists. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/ + parameters: + - $ref: '#/components/parameters/indices.exists_index_template___path.name' + - $ref: '#/components/parameters/indices.exists_index_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.exists_index_template___query.flat_settings' + - $ref: '#/components/parameters/indices.exists_index_template___query.local' + - $ref: '#/components/parameters/indices.exists_index_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.exists_index_template___200' + post: + operationId: indices.put_index_template.0 + x-operation-group: indices.put_index_template + x-version-added: '1.0' + description: Creates or updates an index template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/ + parameters: + - $ref: '#/components/parameters/indices.put_index_template___path.name' + - $ref: '#/components/parameters/indices.put_index_template___query.cause' + - $ref: '#/components/parameters/indices.put_index_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_index_template___query.create' + - $ref: '#/components/parameters/indices.put_index_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_index_template' + responses: + '200': + $ref: '#/components/responses/indices.put_index_template___200' + put: + operationId: indices.put_index_template.1 + x-operation-group: indices.put_index_template + x-version-added: '1.0' + description: Creates or updates an index template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/ + parameters: + - $ref: '#/components/parameters/indices.put_index_template___path.name' + - $ref: '#/components/parameters/indices.put_index_template___query.cause' + - $ref: '#/components/parameters/indices.put_index_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_index_template___query.create' + - $ref: '#/components/parameters/indices.put_index_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_index_template' + responses: + '200': + $ref: '#/components/responses/indices.put_index_template___200' + /_ingest/pipeline: + get: + operationId: ingest.get_pipeline.0 + x-operation-group: ingest.get_pipeline + x-version-added: '1.0' + description: Returns an ingest pipeline. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/ingest-apis/get-ingest/ + parameters: + - $ref: '#/components/parameters/ingest.get_pipeline___query.cluster_manager_timeout' + - $ref: '#/components/parameters/ingest.get_pipeline___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ingest.get_pipeline___200' + /_ingest/pipeline/_simulate: + get: + operationId: ingest.simulate.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SimulateDocFailures' + x-operation-group: ingest.simulate + x-version-added: '1.0' + description: Simulates an ingest pipeline with example documents. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/ingest-apis/simulate-ingest/ + parameters: + - $ref: '#/components/parameters/ingest.simulate___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ingest.simulate' + responses: + '200': + $ref: '#/components/responses/ingest.simulate___200' + post: + operationId: ingest.simulate.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SimulateDocFailures' + x-operation-group: ingest.simulate + x-version-added: '1.0' + description: Simulates an ingest pipeline with example documents. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/ingest-apis/simulate-ingest/ + parameters: + - $ref: '#/components/parameters/ingest.simulate___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ingest.simulate' + responses: + '200': + $ref: '#/components/responses/ingest.simulate___200' + /_ingest/pipeline/{id}: + delete: + operationId: ingest.delete_pipeline.0 + x-operation-group: ingest.delete_pipeline + x-version-added: '1.0' + description: Deletes an ingest pipeline. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/ingest-apis/delete-ingest/ + parameters: + - $ref: '#/components/parameters/ingest.delete_pipeline___path.id' + - $ref: '#/components/parameters/ingest.delete_pipeline___query.cluster_manager_timeout' + - $ref: '#/components/parameters/ingest.delete_pipeline___query.master_timeout' + - $ref: '#/components/parameters/ingest.delete_pipeline___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ingest.delete_pipeline___200' + get: + operationId: ingest.get_pipeline.1 + x-operation-group: ingest.get_pipeline + x-version-added: '1.0' + description: Returns an ingest pipeline. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/ingest-apis/get-ingest/ + parameters: + - $ref: '#/components/parameters/ingest.get_pipeline___path.id' + - $ref: '#/components/parameters/ingest.get_pipeline___query.cluster_manager_timeout' + - $ref: '#/components/parameters/ingest.get_pipeline___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ingest.get_pipeline___200' + put: + operationId: ingest.put_pipeline.0 + x-operation-group: ingest.put_pipeline + x-version-added: '1.0' + description: Creates or updates an ingest pipeline. + externalDocs: + url: https://docs.opensearch.org/latest/ingest-pipelines/create-ingest/ + parameters: + - $ref: '#/components/parameters/ingest.put_pipeline___path.id' + - $ref: '#/components/parameters/ingest.put_pipeline___query.cluster_manager_timeout' + - $ref: '#/components/parameters/ingest.put_pipeline___query.master_timeout' + - $ref: '#/components/parameters/ingest.put_pipeline___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ingest.put_pipeline' + responses: + '200': + $ref: '#/components/responses/ingest.put_pipeline___200' + /_ingest/pipeline/{id}/_simulate: + get: + operationId: ingest.simulate.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SimulateDocFailures' + x-operation-group: ingest.simulate + x-version-added: '1.0' + description: Simulates an ingest pipeline with example documents. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/ingest-apis/simulate-ingest/ + parameters: + - $ref: '#/components/parameters/ingest.simulate___path.id' + - $ref: '#/components/parameters/ingest.simulate___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ingest.simulate' + responses: + '200': + $ref: '#/components/responses/ingest.simulate___200' + post: + operationId: ingest.simulate.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SimulateDocFailures' + x-operation-group: ingest.simulate + x-version-added: '1.0' + description: Simulates an ingest pipeline with example documents. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/ingest-apis/simulate-ingest/ + parameters: + - $ref: '#/components/parameters/ingest.simulate___path.id' + - $ref: '#/components/parameters/ingest.simulate___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ingest.simulate' + responses: + '200': + $ref: '#/components/responses/ingest.simulate___200' + /_ingest/processor/grok: + get: + operationId: ingest.processor_grok.0 + x-operation-group: ingest.processor_grok + x-version-added: '1.0' + description: Returns a list of built-in grok patterns. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/ingest.processor_grok___query.s' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ingest.processor_grok___200' + /_insights/top_queries: + get: + operationId: insights.top_queries.0 + x-operation-group: insights.top_queries + x-version-added: '1.0' + description: Retrieves the top queries based on the given metric type (latency, CPU, or memory). + parameters: + - $ref: '#/components/parameters/insights.top_queries___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/insights.top_queries___200' + /_list: + get: + operationId: list.help.0 + x-operation-group: list.help + x-version-added: '2.18' + description: Returns help for the List APIs. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/list/index/ + responses: + '200': + $ref: '#/components/responses/list.help___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_list/indices: + get: + operationId: list.indices.0 + x-operation-group: list.indices + x-version-added: '2.18' + description: Returns paginated information about indexes including number of primaries and replicas, document counts, disk size. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/list/list-indices/ + parameters: + - $ref: '#/components/parameters/list.indices___query.bytes' + - $ref: '#/components/parameters/list.indices___query.cluster_manager_timeout' + - $ref: '#/components/parameters/list.indices___query.expand_wildcards' + - $ref: '#/components/parameters/list.indices___query.format' + - $ref: '#/components/parameters/list.indices___query.h' + - $ref: '#/components/parameters/list.indices___query.health' + - $ref: '#/components/parameters/list.indices___query.help' + - $ref: '#/components/parameters/list.indices___query.include_unloaded_segments' + - $ref: '#/components/parameters/list.indices___query.local' + - $ref: '#/components/parameters/list.indices___query.master_timeout' + - $ref: '#/components/parameters/list.indices___query.next_token' + - $ref: '#/components/parameters/list.indices___query.pri' + - $ref: '#/components/parameters/list.indices___query.s' + - $ref: '#/components/parameters/list.indices___query.size' + - $ref: '#/components/parameters/list.indices___query.sort' + - $ref: '#/components/parameters/list.indices___query.time' + - $ref: '#/components/parameters/list.indices___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/list.indices___200' + /_list/indices/{index}: + get: + operationId: list.indices.1 + x-operation-group: list.indices + x-version-added: '2.18' + description: Returns paginated information about indexes including number of primaries and replicas, document counts, disk size. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/list/list-indices/ + parameters: + - $ref: '#/components/parameters/list.indices___path.index' + - $ref: '#/components/parameters/list.indices___query.bytes' + - $ref: '#/components/parameters/list.indices___query.cluster_manager_timeout' + - $ref: '#/components/parameters/list.indices___query.expand_wildcards' + - $ref: '#/components/parameters/list.indices___query.format' + - $ref: '#/components/parameters/list.indices___query.h' + - $ref: '#/components/parameters/list.indices___query.health' + - $ref: '#/components/parameters/list.indices___query.help' + - $ref: '#/components/parameters/list.indices___query.include_unloaded_segments' + - $ref: '#/components/parameters/list.indices___query.local' + - $ref: '#/components/parameters/list.indices___query.master_timeout' + - $ref: '#/components/parameters/list.indices___query.next_token' + - $ref: '#/components/parameters/list.indices___query.pri' + - $ref: '#/components/parameters/list.indices___query.s' + - $ref: '#/components/parameters/list.indices___query.size' + - $ref: '#/components/parameters/list.indices___query.sort' + - $ref: '#/components/parameters/list.indices___query.time' + - $ref: '#/components/parameters/list.indices___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/list.indices___200' + /_list/shards: + get: + operationId: list.shards.0 + x-operation-group: list.shards + x-version-added: '2.18' + description: Returns paginated details of shard allocation on nodes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/list/list-shards/ + parameters: + - $ref: '#/components/parameters/list.shards___query.bytes' + - $ref: '#/components/parameters/list.shards___query.cluster_manager_timeout' + - $ref: '#/components/parameters/list.shards___query.format' + - $ref: '#/components/parameters/list.shards___query.h' + - $ref: '#/components/parameters/list.shards___query.help' + - $ref: '#/components/parameters/list.shards___query.local' + - $ref: '#/components/parameters/list.shards___query.master_timeout' + - $ref: '#/components/parameters/list.shards___query.next_token' + - $ref: '#/components/parameters/list.shards___query.s' + - $ref: '#/components/parameters/list.shards___query.size' + - $ref: '#/components/parameters/list.shards___query.sort' + - $ref: '#/components/parameters/list.shards___query.time' + - $ref: '#/components/parameters/list.shards___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/list.shards___200' + /_list/shards/{index}: + get: + operationId: list.shards.1 + x-operation-group: list.shards + x-version-added: '2.18' + description: Returns paginated details of shard allocation on nodes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/list/list-shards/ + parameters: + - $ref: '#/components/parameters/list.shards___path.index' + - $ref: '#/components/parameters/list.shards___query.bytes' + - $ref: '#/components/parameters/list.shards___query.cluster_manager_timeout' + - $ref: '#/components/parameters/list.shards___query.format' + - $ref: '#/components/parameters/list.shards___query.h' + - $ref: '#/components/parameters/list.shards___query.help' + - $ref: '#/components/parameters/list.shards___query.local' + - $ref: '#/components/parameters/list.shards___query.master_timeout' + - $ref: '#/components/parameters/list.shards___query.next_token' + - $ref: '#/components/parameters/list.shards___query.s' + - $ref: '#/components/parameters/list.shards___query.size' + - $ref: '#/components/parameters/list.shards___query.sort' + - $ref: '#/components/parameters/list.shards___query.time' + - $ref: '#/components/parameters/list.shards___query.v' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/list.shards___200' + /_ltr: + delete: + operationId: ltr.delete_default_store.0 + x-operation-group: ltr.delete_default_store + x-version-added: 2.17.1 + description: Deletes the default feature store. + responses: + '200': + $ref: '#/components/responses/ltr.delete_default_store___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + get: + operationId: ltr.list_stores.0 + x-operation-group: ltr.list_stores + x-version-added: 2.17.1 + description: Lists all available feature stores. + responses: + '200': + $ref: '#/components/responses/ltr.list_stores___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: ltr.create_default_store.0 + x-operation-group: ltr.create_default_store + x-version-added: 2.17.1 + description: Creates the default feature store. + responses: + '200': + $ref: '#/components/responses/ltr.create_default_store___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_ltr/_cachestats: + get: + operationId: ltr.cache_stats.0 + x-operation-group: ltr.cache_stats + x-version-added: '2.19' + description: Retrieves cache statistics for all feature stores. + responses: + '200': + $ref: '#/components/responses/ltr.cache_stats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_ltr/_clearcache: + post: + operationId: ltr.clear_cache.0 + x-operation-group: ltr.clear_cache + x-version-added: '2.19' + description: Clears the store caches. + responses: + '200': + $ref: '#/components/responses/ltr.clear_cache___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_ltr/_feature: + get: + operationId: ltr.search_features.0 + x-operation-group: ltr.search_features + x-version-added: '2.19' + description: Search for features in a feature store. + parameters: + - $ref: '#/components/parameters/ltr.search_features___query.from' + - $ref: '#/components/parameters/ltr.search_features___query.prefix' + - $ref: '#/components/parameters/ltr.search_features___query.size' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.search_features___200' + /_ltr/_feature/{id}: + delete: + operationId: ltr.delete_feature.0 + x-operation-group: ltr.delete_feature + x-version-added: '2.19' + description: Delete a feature from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.delete_feature___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.delete_feature___200' + '404': + $ref: '#/components/responses/ltr.delete_feature___404' + get: + operationId: ltr.get_feature.0 + x-operation-group: ltr.get_feature + x-version-added: '2.19' + description: Get a feature from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.get_feature___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.get_feature___200' + '404': + $ref: '#/components/responses/ltr.get_feature___404' + post: + operationId: ltr.update_feature.0 + x-operation-group: ltr.update_feature + x-version-added: '2.19' + description: Update a feature in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.update_feature___path.id' + - $ref: '#/components/parameters/ltr.update_feature___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.update_feature' + responses: + '200': + $ref: '#/components/responses/ltr.update_feature___200' + '404': + $ref: '#/components/responses/ltr.update_feature___404' + '409': + $ref: '#/components/responses/ltr.update_feature___409' + put: + operationId: ltr.create_feature.0 + x-operation-group: ltr.create_feature + x-version-added: '2.19' + description: Create or update a feature in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.create_feature___path.id' + - $ref: '#/components/parameters/ltr.create_feature___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.create_feature' + responses: + '200': + $ref: '#/components/responses/ltr.create_feature___200' + '201': + $ref: '#/components/responses/ltr.create_feature___201' + '409': + $ref: '#/components/responses/ltr.create_feature___409' + /_ltr/_featureset: + get: + operationId: ltr.search_featuresets.0 + x-operation-group: ltr.search_featuresets + x-version-added: '2.19' + description: Search for feature sets in a feature store. + parameters: + - $ref: '#/components/parameters/ltr.search_featuresets___query.from' + - $ref: '#/components/parameters/ltr.search_featuresets___query.prefix' + - $ref: '#/components/parameters/ltr.search_featuresets___query.size' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.search_featuresets___200' + /_ltr/_featureset/{id}: + delete: + operationId: ltr.delete_featureset.0 + x-operation-group: ltr.delete_featureset + x-version-added: '2.19' + description: Delete a feature set from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.delete_featureset___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.delete_featureset___200' + '404': + $ref: '#/components/responses/ltr.delete_featureset___404' + get: + operationId: ltr.get_featureset.0 + x-operation-group: ltr.get_featureset + x-version-added: '2.19' + description: Get a feature set from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.get_featureset___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.get_featureset___200' + '404': + $ref: '#/components/responses/ltr.get_featureset___404' + post: + operationId: ltr.update_featureset.0 + x-operation-group: ltr.update_featureset + x-version-added: '2.19' + description: Update a feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.update_featureset___path.id' + - $ref: '#/components/parameters/ltr.update_featureset___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.update_featureset' + responses: + '200': + $ref: '#/components/responses/ltr.update_featureset___200' + '404': + $ref: '#/components/responses/ltr.update_featureset___404' + '409': + $ref: '#/components/responses/ltr.update_featureset___409' + put: + operationId: ltr.create_featureset.0 + x-operation-group: ltr.create_featureset + x-version-added: '2.19' + description: Create or update a feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.create_featureset___path.id' + - $ref: '#/components/parameters/ltr.create_featureset___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.create_featureset' + responses: + '200': + $ref: '#/components/responses/ltr.create_featureset___200' + '201': + $ref: '#/components/responses/ltr.create_featureset___201' + '409': + $ref: '#/components/responses/ltr.create_featureset___409' + /_ltr/_featureset/{name}/_addfeatures: + post: + operationId: ltr.add_features_to_set.0 + x-operation-group: ltr.add_features_to_set + x-version-added: '2.19' + description: Add features to an existing feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.add_features_to_set___path.name' + - $ref: '#/components/parameters/ltr.add_features_to_set___query.merge' + - $ref: '#/components/parameters/ltr.add_features_to_set___query.routing' + - $ref: '#/components/parameters/ltr.add_features_to_set___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.add_features_to_set' + responses: + '200': + $ref: '#/components/responses/ltr.add_features_to_set___200' + '201': + $ref: '#/components/responses/ltr.add_features_to_set___201' + '400': + $ref: '#/components/responses/ltr.add_features_to_set___400' + '404': + $ref: '#/components/responses/ltr.add_features_to_set___404' + '409': + $ref: '#/components/responses/ltr.add_features_to_set___409' + /_ltr/_featureset/{name}/_addfeatures/{query}: + post: + operationId: ltr.add_features_to_set_by_query.0 + x-operation-group: ltr.add_features_to_set_by_query + x-version-added: '2.19' + description: Add features to an existing feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___path.name' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___path.query' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___query.merge' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___query.routing' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___200' + '201': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___201' + '400': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___400' + '404': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___404' + '409': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___409' + /_ltr/_featureset/{name}/_createmodel: + post: + operationId: ltr.create_model_from_set.0 + x-operation-group: ltr.create_model_from_set + x-version-added: '2.19' + description: Create a model from an existing feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.create_model_from_set___path.name' + - $ref: '#/components/parameters/ltr.create_model_from_set___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.create_model_from_set' + responses: + '200': + $ref: '#/components/responses/ltr.create_model_from_set___200' + '201': + $ref: '#/components/responses/ltr.create_model_from_set___201' + '405': + $ref: '#/components/responses/ltr.create_model_from_set___405' + /_ltr/_model: + get: + operationId: ltr.search_models.0 + x-operation-group: ltr.search_models + x-version-added: '2.19' + description: Search for models in a feature store. + parameters: + - $ref: '#/components/parameters/ltr.search_models___query.from' + - $ref: '#/components/parameters/ltr.search_models___query.prefix' + - $ref: '#/components/parameters/ltr.search_models___query.size' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.search_models___200' + /_ltr/_model/{id}: + delete: + operationId: ltr.delete_model.0 + x-operation-group: ltr.delete_model + x-version-added: '2.19' + description: Delete a model from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.delete_model___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.delete_model___200' + '404': + $ref: '#/components/responses/ltr.delete_model___404' + get: + operationId: ltr.get_model.0 + x-operation-group: ltr.get_model + x-version-added: '2.19' + description: Get a model from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.get_model___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.get_model___200' + '404': + $ref: '#/components/responses/ltr.get_model___404' + put: + operationId: ltr.create_model.0 + x-operation-group: ltr.create_model + x-version-added: '2.19' + description: Create or update a model in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.create_model___path.id' + - $ref: '#/components/parameters/ltr.create_model___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.create_model' + responses: + '200': + $ref: '#/components/responses/ltr.create_model___200' + '201': + $ref: '#/components/responses/ltr.create_model___201' + '409': + $ref: '#/components/responses/ltr.create_model___409' + /_ltr/{store}: + delete: + operationId: ltr.delete_store.0 + x-operation-group: ltr.delete_store + x-version-added: 2.17.1 + description: Deletes a feature store with the specified name. + parameters: + - $ref: '#/components/parameters/ltr.delete_store___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.delete_store___200' + get: + operationId: ltr.get_store.0 + x-operation-group: ltr.get_store + x-version-added: 2.17.1 + description: Checks if a store exists. + parameters: + - $ref: '#/components/parameters/ltr.get_store___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.get_store___200' + '404': + $ref: '#/components/responses/ltr.get_store___404' + put: + operationId: ltr.create_store.0 + x-operation-group: ltr.create_store + x-version-added: 2.17.1 + description: Creates a new feature store with the specified name. + parameters: + - $ref: '#/components/parameters/ltr.create_store___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.create_store___200' + /_ltr/{store}/_clearcache: + post: + operationId: ltr.clear_cache.1 + x-operation-group: ltr.clear_cache + x-version-added: '2.19' + description: Clears the store caches. + parameters: + - $ref: '#/components/parameters/ltr.clear_cache___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.clear_cache___200' + /_ltr/{store}/_feature: + get: + operationId: ltr.search_features.1 + x-operation-group: ltr.search_features + x-version-added: '2.19' + description: Search for features in a feature store. + parameters: + - $ref: '#/components/parameters/ltr.search_features___path.store' + - $ref: '#/components/parameters/ltr.search_features___query.from' + - $ref: '#/components/parameters/ltr.search_features___query.prefix' + - $ref: '#/components/parameters/ltr.search_features___query.size' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.search_features___200' + /_ltr/{store}/_feature/{id}: + delete: + operationId: ltr.delete_feature.1 + x-operation-group: ltr.delete_feature + x-version-added: '2.19' + description: Delete a feature from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.delete_feature___path.id' + - $ref: '#/components/parameters/ltr.delete_feature___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.delete_feature___200' + '404': + $ref: '#/components/responses/ltr.delete_feature___404' + get: + operationId: ltr.get_feature.1 + x-operation-group: ltr.get_feature + x-version-added: '2.19' + description: Get a feature from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.get_feature___path.id' + - $ref: '#/components/parameters/ltr.get_feature___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.get_feature___200' + '404': + $ref: '#/components/responses/ltr.get_feature___404' + post: + operationId: ltr.update_feature.1 + x-operation-group: ltr.update_feature + x-version-added: '2.19' + description: Update a feature in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.update_feature___path.id' + - $ref: '#/components/parameters/ltr.update_feature___path.store' + - $ref: '#/components/parameters/ltr.update_feature___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.update_feature' + responses: + '200': + $ref: '#/components/responses/ltr.update_feature___200' + '404': + $ref: '#/components/responses/ltr.update_feature___404' + '409': + $ref: '#/components/responses/ltr.update_feature___409' + put: + operationId: ltr.create_feature.1 + x-operation-group: ltr.create_feature + x-version-added: '2.19' + description: Create or update a feature in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.create_feature___path.id' + - $ref: '#/components/parameters/ltr.create_feature___path.store' + - $ref: '#/components/parameters/ltr.create_feature___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.create_feature' + responses: + '200': + $ref: '#/components/responses/ltr.create_feature___200' + '201': + $ref: '#/components/responses/ltr.create_feature___201' + '409': + $ref: '#/components/responses/ltr.create_feature___409' + /_ltr/{store}/_featureset: + get: + operationId: ltr.search_featuresets.1 + x-operation-group: ltr.search_featuresets + x-version-added: '2.19' + description: Search for feature sets in a feature store. + parameters: + - $ref: '#/components/parameters/ltr.search_featuresets___path.store' + - $ref: '#/components/parameters/ltr.search_featuresets___query.from' + - $ref: '#/components/parameters/ltr.search_featuresets___query.prefix' + - $ref: '#/components/parameters/ltr.search_featuresets___query.size' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.search_featuresets___200' + /_ltr/{store}/_featureset/{id}: + delete: + operationId: ltr.delete_featureset.1 + x-operation-group: ltr.delete_featureset + x-version-added: '2.19' + description: Delete a feature set from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.delete_featureset___path.id' + - $ref: '#/components/parameters/ltr.delete_featureset___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.delete_featureset___200' + '404': + $ref: '#/components/responses/ltr.delete_featureset___404' + get: + operationId: ltr.get_featureset.1 + x-operation-group: ltr.get_featureset + x-version-added: '2.19' + description: Get a feature set from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.get_featureset___path.id' + - $ref: '#/components/parameters/ltr.get_featureset___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.get_featureset___200' + '404': + $ref: '#/components/responses/ltr.get_featureset___404' + post: + operationId: ltr.update_featureset.1 + x-operation-group: ltr.update_featureset + x-version-added: '2.19' + description: Update a feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.update_featureset___path.id' + - $ref: '#/components/parameters/ltr.update_featureset___path.store' + - $ref: '#/components/parameters/ltr.update_featureset___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.update_featureset' + responses: + '200': + $ref: '#/components/responses/ltr.update_featureset___200' + '404': + $ref: '#/components/responses/ltr.update_featureset___404' + '409': + $ref: '#/components/responses/ltr.update_featureset___409' + put: + operationId: ltr.create_featureset.1 + x-operation-group: ltr.create_featureset + x-version-added: '2.19' + description: Create or update a feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.create_featureset___path.id' + - $ref: '#/components/parameters/ltr.create_featureset___path.store' + - $ref: '#/components/parameters/ltr.create_featureset___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.create_featureset' + responses: + '200': + $ref: '#/components/responses/ltr.create_featureset___200' + '201': + $ref: '#/components/responses/ltr.create_featureset___201' + '409': + $ref: '#/components/responses/ltr.create_featureset___409' + /_ltr/{store}/_featureset/{name}/_addfeatures: + post: + operationId: ltr.add_features_to_set.2 + x-operation-group: ltr.add_features_to_set + x-version-added: '2.19' + description: Add features to an existing feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.add_features_to_set___path.name' + - $ref: '#/components/parameters/ltr.add_features_to_set___path.store' + - $ref: '#/components/parameters/ltr.add_features_to_set___query.merge' + - $ref: '#/components/parameters/ltr.add_features_to_set___query.routing' + - $ref: '#/components/parameters/ltr.add_features_to_set___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.add_features_to_set' + responses: + '200': + $ref: '#/components/responses/ltr.add_features_to_set___200' + '201': + $ref: '#/components/responses/ltr.add_features_to_set___201' + '400': + $ref: '#/components/responses/ltr.add_features_to_set___400' + '404': + $ref: '#/components/responses/ltr.add_features_to_set___404' + '409': + $ref: '#/components/responses/ltr.add_features_to_set___409' + /_ltr/{store}/_featureset/{name}/_addfeatures/{query}: + post: + operationId: ltr.add_features_to_set_by_query.1 + x-operation-group: ltr.add_features_to_set_by_query + x-version-added: '2.19' + description: Add features to an existing feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___path.name' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___path.query' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___path.store' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___query.merge' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___query.routing' + - $ref: '#/components/parameters/ltr.add_features_to_set_by_query___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___200' + '201': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___201' + '400': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___400' + '404': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___404' + '409': + $ref: '#/components/responses/ltr.add_features_to_set_by_query___409' + /_ltr/{store}/_featureset/{name}/_createmodel: + post: + operationId: ltr.create_model_from_set.1 + x-operation-group: ltr.create_model_from_set + x-version-added: '2.19' + description: Create a model from an existing feature set in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.create_model_from_set___path.name' + - $ref: '#/components/parameters/ltr.create_model_from_set___path.store' + - $ref: '#/components/parameters/ltr.create_model_from_set___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.create_model_from_set' + responses: + '200': + $ref: '#/components/responses/ltr.create_model_from_set___200' + '201': + $ref: '#/components/responses/ltr.create_model_from_set___201' + '405': + $ref: '#/components/responses/ltr.create_model_from_set___405' + /_ltr/{store}/_model: + get: + operationId: ltr.search_models.1 + x-operation-group: ltr.search_models + x-version-added: '2.19' + description: Search for models in a feature store. + parameters: + - $ref: '#/components/parameters/ltr.search_models___path.store' + - $ref: '#/components/parameters/ltr.search_models___query.from' + - $ref: '#/components/parameters/ltr.search_models___query.prefix' + - $ref: '#/components/parameters/ltr.search_models___query.size' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.search_models___200' + /_ltr/{store}/_model/{id}: + delete: + operationId: ltr.delete_model.1 + x-operation-group: ltr.delete_model + x-version-added: '2.19' + description: Delete a model from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.delete_model___path.id' + - $ref: '#/components/parameters/ltr.delete_model___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.delete_model___200' + '404': + $ref: '#/components/responses/ltr.delete_model___404' + get: + operationId: ltr.get_model.1 + x-operation-group: ltr.get_model + x-version-added: '2.19' + description: Get a model from the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.get_model___path.id' + - $ref: '#/components/parameters/ltr.get_model___path.store' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.get_model___200' + '404': + $ref: '#/components/responses/ltr.get_model___404' + put: + operationId: ltr.create_model.1 + x-operation-group: ltr.create_model + x-version-added: '2.19' + description: Create or update a model in the default feature store. + parameters: + - $ref: '#/components/parameters/ltr.create_model___path.id' + - $ref: '#/components/parameters/ltr.create_model___path.store' + - $ref: '#/components/parameters/ltr.create_model___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ltr.create_model' + responses: + '200': + $ref: '#/components/responses/ltr.create_model___200' + '201': + $ref: '#/components/responses/ltr.create_model___201' + '409': + $ref: '#/components/responses/ltr.create_model___409' + /_mapping: + get: + operationId: indices.get_mapping.0 + x-operation-group: indices.get_mapping + x-version-added: '1.0' + description: Returns mappings for one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/field-types/index/#get-a-mapping + parameters: + - $ref: '#/components/parameters/indices.get_mapping___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_mapping___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_mapping___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_mapping___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_mapping___query.index' + - $ref: '#/components/parameters/indices.get_mapping___query.local' + - $ref: '#/components/parameters/indices.get_mapping___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_mapping___200' + /_mapping/field/{fields}: + get: + operationId: indices.get_field_mapping.0 + x-operation-group: indices.get_field_mapping + x-version-added: '1.0' + description: Returns mapping for one or more fields. + externalDocs: + url: https://opensearch.org/docs/latest/field-types/index/ + parameters: + - $ref: '#/components/parameters/indices.get_field_mapping___path.fields' + - $ref: '#/components/parameters/indices.get_field_mapping___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_field_mapping___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_field_mapping___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_field_mapping___query.include_defaults' + - $ref: '#/components/parameters/indices.get_field_mapping___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_field_mapping___200' + /_mget: + get: + operationId: mget.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___MultiDocItems' + x-operation-group: mget + x-version-added: '1.0' + description: Allows to get multiple documents in one request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/multi-get/ + parameters: + - $ref: '#/components/parameters/mget___query._source' + - $ref: '#/components/parameters/mget___query._source_excludes' + - $ref: '#/components/parameters/mget___query._source_includes' + - $ref: '#/components/parameters/mget___query.preference' + - $ref: '#/components/parameters/mget___query.realtime' + - $ref: '#/components/parameters/mget___query.refresh' + - $ref: '#/components/parameters/mget___query.routing' + - $ref: '#/components/parameters/mget___query.stored_fields' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/mget' + responses: + '200': + $ref: '#/components/responses/mget___200' + post: + operationId: mget.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___MultiDocItems' + x-operation-group: mget + x-version-added: '1.0' + description: Allows to get multiple documents in one request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/multi-get/ + parameters: + - $ref: '#/components/parameters/mget___query._source' + - $ref: '#/components/parameters/mget___query._source_excludes' + - $ref: '#/components/parameters/mget___query._source_includes' + - $ref: '#/components/parameters/mget___query.preference' + - $ref: '#/components/parameters/mget___query.realtime' + - $ref: '#/components/parameters/mget___query.refresh' + - $ref: '#/components/parameters/mget___query.routing' + - $ref: '#/components/parameters/mget___query.stored_fields' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/mget' + responses: + '200': + $ref: '#/components/responses/mget___200' + /_msearch: + get: + operationId: msearch.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + - $ref: '#/components/schemas/_common.errors___MultiSearchItems' + x-operation-group: msearch + x-version-added: '1.0' + description: Allows to execute several search operations in one request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/multi-search/ + parameters: + - $ref: '#/components/parameters/msearch___query.allow_partial_results' + - $ref: '#/components/parameters/msearch___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/msearch___query.max_concurrent_searches' + - $ref: '#/components/parameters/msearch___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/msearch___query.pre_filter_shard_size' + - $ref: '#/components/parameters/msearch___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/msearch___query.search_type' + - $ref: '#/components/parameters/msearch___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/msearch' + responses: + '200': + $ref: '#/components/responses/msearch___200' + post: + operationId: msearch.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + - $ref: '#/components/schemas/_common.errors___MultiSearchItems' + x-operation-group: msearch + x-version-added: '1.0' + description: Allows to execute several search operations in one request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/multi-search/ + parameters: + - $ref: '#/components/parameters/msearch___query.allow_partial_results' + - $ref: '#/components/parameters/msearch___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/msearch___query.max_concurrent_searches' + - $ref: '#/components/parameters/msearch___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/msearch___query.pre_filter_shard_size' + - $ref: '#/components/parameters/msearch___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/msearch___query.search_type' + - $ref: '#/components/parameters/msearch___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/msearch' + responses: + '200': + $ref: '#/components/responses/msearch___200' + /_msearch/template: + get: + operationId: msearch_template.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + - $ref: '#/components/schemas/_common.errors___MultiSearchItems' + x-operation-group: msearch_template + x-version-added: '1.0' + description: Allows to execute several search template operations in one request. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/msearch_template___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/msearch_template___query.max_concurrent_searches' + - $ref: '#/components/parameters/msearch_template___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/msearch_template___query.search_type' + - $ref: '#/components/parameters/msearch_template___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/msearch_template' + responses: + '200': + $ref: '#/components/responses/msearch_template___200' + post: + operationId: msearch_template.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + - $ref: '#/components/schemas/_common.errors___MultiSearchItems' + x-operation-group: msearch_template + x-version-added: '1.0' + description: Allows to execute several search template operations in one request. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/msearch_template___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/msearch_template___query.max_concurrent_searches' + - $ref: '#/components/parameters/msearch_template___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/msearch_template___query.search_type' + - $ref: '#/components/parameters/msearch_template___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/msearch_template' + responses: + '200': + $ref: '#/components/responses/msearch_template___200' + /_mtermvectors: + get: + operationId: mtermvectors.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___MultiDocItems' + x-operation-group: mtermvectors + x-version-added: '1.0' + description: Returns multiple termvectors in one request. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/mtermvectors___query.field_statistics' + - $ref: '#/components/parameters/mtermvectors___query.fields' + - $ref: '#/components/parameters/mtermvectors___query.ids' + - $ref: '#/components/parameters/mtermvectors___query.offsets' + - $ref: '#/components/parameters/mtermvectors___query.payloads' + - $ref: '#/components/parameters/mtermvectors___query.positions' + - $ref: '#/components/parameters/mtermvectors___query.preference' + - $ref: '#/components/parameters/mtermvectors___query.realtime' + - $ref: '#/components/parameters/mtermvectors___query.routing' + - $ref: '#/components/parameters/mtermvectors___query.term_statistics' + - $ref: '#/components/parameters/mtermvectors___query.version' + - $ref: '#/components/parameters/mtermvectors___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/mtermvectors' + responses: + '200': + $ref: '#/components/responses/mtermvectors___200' + post: + operationId: mtermvectors.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___MultiDocItems' + x-operation-group: mtermvectors + x-version-added: '1.0' + description: Returns multiple termvectors in one request. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/mtermvectors___query.field_statistics' + - $ref: '#/components/parameters/mtermvectors___query.fields' + - $ref: '#/components/parameters/mtermvectors___query.ids' + - $ref: '#/components/parameters/mtermvectors___query.offsets' + - $ref: '#/components/parameters/mtermvectors___query.payloads' + - $ref: '#/components/parameters/mtermvectors___query.positions' + - $ref: '#/components/parameters/mtermvectors___query.preference' + - $ref: '#/components/parameters/mtermvectors___query.realtime' + - $ref: '#/components/parameters/mtermvectors___query.routing' + - $ref: '#/components/parameters/mtermvectors___query.term_statistics' + - $ref: '#/components/parameters/mtermvectors___query.version' + - $ref: '#/components/parameters/mtermvectors___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/mtermvectors' + responses: + '200': + $ref: '#/components/responses/mtermvectors___200' + /_nodes: + get: + operationId: nodes.info.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.info + x-version-added: '1.0' + description: Returns information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-info/ + parameters: + - $ref: '#/components/parameters/nodes.info___query.flat_settings' + - $ref: '#/components/parameters/nodes.info___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.info___200' + /_nodes/{node_id_or_metric}: + get: + operationId: nodes.info.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.info + x-version-added: '1.0' + description: Returns information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-info/ + parameters: + - $ref: '#/components/parameters/nodes.info___path.node_id_or_metric' + - $ref: '#/components/parameters/nodes.info___query.flat_settings' + - $ref: '#/components/parameters/nodes.info___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.info___200' + /_nodes/{node_id}/{metric}: + get: + operationId: nodes.info.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.info + x-version-added: '1.0' + description: Returns information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-info/ + parameters: + - $ref: '#/components/parameters/nodes.info___path.metric' + - $ref: '#/components/parameters/nodes.info___path.node_id' + - $ref: '#/components/parameters/nodes.info___query.flat_settings' + - $ref: '#/components/parameters/nodes.info___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.info___200' + /_nodes/{node_id}/hot_threads: + get: + operationId: nodes.hot_threads.6 + x-operation-group: nodes.hot_threads + x-version-added: '1.0' + description: Returns information about hot threads on each node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ + parameters: + - $ref: '#/components/parameters/nodes.hot_threads___path.node_id' + - $ref: '#/components/parameters/nodes.hot_threads___query.ignore_idle_threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.interval' + - $ref: '#/components/parameters/nodes.hot_threads___query.snapshots' + - $ref: '#/components/parameters/nodes.hot_threads___query.threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.timeout' + - $ref: '#/components/parameters/nodes.hot_threads___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.hot_threads___200' + /_nodes/{node_id}/reload_secure_settings: + post: + operationId: nodes.reload_secure_settings.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.reload_secure_settings + x-version-added: '1.0' + description: Reloads secure settings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-reload-secure/ + parameters: + - $ref: '#/components/parameters/nodes.reload_secure_settings___path.node_id' + - $ref: '#/components/parameters/nodes.reload_secure_settings___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/nodes.reload_secure_settings' + responses: + '200': + $ref: '#/components/responses/nodes.reload_secure_settings___200' + /_nodes/{node_id}/stats: + get: + operationId: nodes.stats.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.stats + x-version-added: '1.0' + description: Returns statistical information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-usage/ + parameters: + - $ref: '#/components/parameters/nodes.stats___path.node_id' + - $ref: '#/components/parameters/nodes.stats___query.completion_fields' + - $ref: '#/components/parameters/nodes.stats___query.fielddata_fields' + - $ref: '#/components/parameters/nodes.stats___query.fields' + - $ref: '#/components/parameters/nodes.stats___query.groups' + - $ref: '#/components/parameters/nodes.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/nodes.stats___query.level' + - $ref: '#/components/parameters/nodes.stats___query.timeout' + - $ref: '#/components/parameters/nodes.stats___query.types' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.stats___200' + /_nodes/{node_id}/stats/{metric}: + get: + operationId: nodes.stats.4 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.stats + x-version-added: '1.0' + description: Returns statistical information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-usage/ + parameters: + - $ref: '#/components/parameters/nodes.stats___path.metric' + - $ref: '#/components/parameters/nodes.stats___path.node_id' + - $ref: '#/components/parameters/nodes.stats___query.completion_fields' + - $ref: '#/components/parameters/nodes.stats___query.fielddata_fields' + - $ref: '#/components/parameters/nodes.stats___query.fields' + - $ref: '#/components/parameters/nodes.stats___query.groups' + - $ref: '#/components/parameters/nodes.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/nodes.stats___query.level' + - $ref: '#/components/parameters/nodes.stats___query.timeout' + - $ref: '#/components/parameters/nodes.stats___query.types' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.stats___200' + /_nodes/{node_id}/stats/{metric}/{index_metric}: + get: + operationId: nodes.stats.5 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.stats + x-version-added: '1.0' + description: Returns statistical information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-usage/ + parameters: + - $ref: '#/components/parameters/nodes.stats___path.index_metric' + - $ref: '#/components/parameters/nodes.stats___path.metric' + - $ref: '#/components/parameters/nodes.stats___path.node_id' + - $ref: '#/components/parameters/nodes.stats___query.completion_fields' + - $ref: '#/components/parameters/nodes.stats___query.fielddata_fields' + - $ref: '#/components/parameters/nodes.stats___query.fields' + - $ref: '#/components/parameters/nodes.stats___query.groups' + - $ref: '#/components/parameters/nodes.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/nodes.stats___query.level' + - $ref: '#/components/parameters/nodes.stats___query.timeout' + - $ref: '#/components/parameters/nodes.stats___query.types' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.stats___200' + /_nodes/{node_id}/usage: + get: + operationId: nodes.usage.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.usage + x-version-added: '1.0' + description: Returns low-level information about REST actions usage on nodes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/nodes.usage___path.node_id' + - $ref: '#/components/parameters/nodes.usage___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.usage___200' + /_nodes/{node_id}/usage/{metric}: + get: + operationId: nodes.usage.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.usage + x-version-added: '1.0' + description: Returns low-level information about REST actions usage on nodes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/nodes.usage___path.metric' + - $ref: '#/components/parameters/nodes.usage___path.node_id' + - $ref: '#/components/parameters/nodes.usage___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.usage___200' + /_nodes/hot_threads: + get: + operationId: nodes.hot_threads.4 + x-operation-group: nodes.hot_threads + x-version-added: '1.0' + description: Returns information about hot threads on each node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ + parameters: + - $ref: '#/components/parameters/nodes.hot_threads___query.ignore_idle_threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.interval' + - $ref: '#/components/parameters/nodes.hot_threads___query.snapshots' + - $ref: '#/components/parameters/nodes.hot_threads___query.threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.timeout' + - $ref: '#/components/parameters/nodes.hot_threads___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.hot_threads___200' + /_nodes/reload_secure_settings: + post: + operationId: nodes.reload_secure_settings.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.reload_secure_settings + x-version-added: '1.0' + description: Reloads secure settings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-reload-secure/ + parameters: + - $ref: '#/components/parameters/nodes.reload_secure_settings___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/nodes.reload_secure_settings' + responses: + '200': + $ref: '#/components/responses/nodes.reload_secure_settings___200' + /_nodes/stats: + get: + operationId: nodes.stats.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.stats + x-version-added: '1.0' + description: Returns statistical information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-usage/ + parameters: + - $ref: '#/components/parameters/nodes.stats___query.completion_fields' + - $ref: '#/components/parameters/nodes.stats___query.fielddata_fields' + - $ref: '#/components/parameters/nodes.stats___query.fields' + - $ref: '#/components/parameters/nodes.stats___query.groups' + - $ref: '#/components/parameters/nodes.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/nodes.stats___query.level' + - $ref: '#/components/parameters/nodes.stats___query.timeout' + - $ref: '#/components/parameters/nodes.stats___query.types' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.stats___200' + /_nodes/stats/{metric}: + get: + operationId: nodes.stats.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.stats + x-version-added: '1.0' + description: Returns statistical information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-usage/ + parameters: + - $ref: '#/components/parameters/nodes.stats___path.metric' + - $ref: '#/components/parameters/nodes.stats___query.completion_fields' + - $ref: '#/components/parameters/nodes.stats___query.fielddata_fields' + - $ref: '#/components/parameters/nodes.stats___query.fields' + - $ref: '#/components/parameters/nodes.stats___query.groups' + - $ref: '#/components/parameters/nodes.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/nodes.stats___query.level' + - $ref: '#/components/parameters/nodes.stats___query.timeout' + - $ref: '#/components/parameters/nodes.stats___query.types' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.stats___200' + /_nodes/stats/{metric}/{index_metric}: + get: + operationId: nodes.stats.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.stats + x-version-added: '1.0' + description: Returns statistical information about nodes in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-usage/ + parameters: + - $ref: '#/components/parameters/nodes.stats___path.index_metric' + - $ref: '#/components/parameters/nodes.stats___path.metric' + - $ref: '#/components/parameters/nodes.stats___query.completion_fields' + - $ref: '#/components/parameters/nodes.stats___query.fielddata_fields' + - $ref: '#/components/parameters/nodes.stats___query.fields' + - $ref: '#/components/parameters/nodes.stats___query.groups' + - $ref: '#/components/parameters/nodes.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/nodes.stats___query.level' + - $ref: '#/components/parameters/nodes.stats___query.timeout' + - $ref: '#/components/parameters/nodes.stats___query.types' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.stats___200' + /_nodes/usage: + get: + operationId: nodes.usage.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.usage + x-version-added: '1.0' + description: Returns low-level information about REST actions usage on nodes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/nodes.usage___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.usage___200' + /_nodes/usage/{metric}: + get: + operationId: nodes.usage.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___NodeFailures' + x-operation-group: nodes.usage + x-version-added: '1.0' + description: Returns low-level information about REST actions usage on nodes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/nodes.usage___path.metric' + - $ref: '#/components/parameters/nodes.usage___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.usage___200' + /_opendistro/_security/sslinfo: + get: + operationId: security.get_sslinfo.0 + x-operation-group: security.get_sslinfo + x-version-added: '1.0' + description: Retrieves information about the SSL configuration. + parameters: + - $ref: '#/components/parameters/security.get_sslinfo___query.show_dn' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_sslinfo___200' + '500': + $ref: '#/components/responses/security.get_sslinfo___500' + /_plugins/_asynchronous_search: + post: + operationId: asynchronous_search.search.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: asynchronous_search.search + x-version-added: '1.0' + description: Performs an asynchronous search. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/async/index/#rest-api + parameters: + - $ref: '#/components/parameters/asynchronous_search.search___query.index' + - $ref: '#/components/parameters/asynchronous_search.search___query.keep_alive' + - $ref: '#/components/parameters/asynchronous_search.search___query.keep_on_completion' + - $ref: '#/components/parameters/asynchronous_search.search___query.wait_for_completion_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/asynchronous_search.search' + responses: + '200': + $ref: '#/components/responses/asynchronous_search.search___200' + /_plugins/_asynchronous_search/{id}: + delete: + operationId: asynchronous_search.delete.0 + x-operation-group: asynchronous_search.delete + x-version-added: '1.0' + description: Deletes any responses from an asynchronous search. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/async/index/#delete-searches-and-results + parameters: + - $ref: '#/components/parameters/asynchronous_search.delete___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/asynchronous_search.delete___200' + get: + operationId: asynchronous_search.get.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: asynchronous_search.get + x-version-added: '1.0' + description: Gets partial responses from an asynchronous search. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/async/index/#get-partial-results + parameters: + - $ref: '#/components/parameters/asynchronous_search.get___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/asynchronous_search.get___200' + /_plugins/_asynchronous_search/stats: + get: + operationId: asynchronous_search.stats.0 + x-operation-group: asynchronous_search.stats + x-version-added: '1.0' + description: Monitors any asynchronous searches that are `running`, `completed`, or `persisted`. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/async/index/#monitor-stats + responses: + '200': + $ref: '#/components/responses/asynchronous_search.stats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_flow_framework/workflow: + post: + operationId: flow_framework.create.0 + x-operation-group: flow_framework.create + x-version-added: '2.12' + description: Creates a new workflow template. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/create-workflow/ + parameters: + - $ref: '#/components/parameters/flow_framework.create___query.provision' + - $ref: '#/components/parameters/flow_framework.create___query.reprovision' + - $ref: '#/components/parameters/flow_framework.create___query.update_fields' + - $ref: '#/components/parameters/flow_framework.create___query.use_case' + - $ref: '#/components/parameters/flow_framework.create___query.validation' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/flow_framework.create' + responses: + '201': + $ref: '#/components/responses/flow_framework.create___201' + '202': + $ref: '#/components/responses/flow_framework.create___202' + '400': + $ref: '#/components/responses/flow_framework.create___400' + '403': + $ref: '#/components/responses/flow_framework.create___403' + /_plugins/_flow_framework/workflow/_search: + get: + operationId: flow_framework.search.1 + x-operation-group: flow_framework.search + x-version-added: '2.12' + description: Search for workflows by using a query matching a field. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/provision-workflow/ + requestBody: + $ref: '#/components/requestBodies/flow_framework.search' + responses: + '200': + $ref: '#/components/responses/flow_framework.search___200' + '400': + $ref: '#/components/responses/flow_framework.search___400' + '403': + $ref: '#/components/responses/flow_framework.search___403' + '408': + $ref: '#/components/responses/flow_framework.search___408' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: flow_framework.search.0 + x-operation-group: flow_framework.search + x-version-added: '2.12' + description: Search for workflows by using a query matching a field. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/provision-workflow/ + requestBody: + $ref: '#/components/requestBodies/flow_framework.search' + responses: + '200': + $ref: '#/components/responses/flow_framework.search___200' + '400': + $ref: '#/components/responses/flow_framework.search___400' + '403': + $ref: '#/components/responses/flow_framework.search___403' + '408': + $ref: '#/components/responses/flow_framework.search___408' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_flow_framework/workflow/_steps: + get: + operationId: flow_framework.get_steps.0 + x-operation-group: flow_framework.get_steps + x-version-added: '2.12' + description: Retrieves available workflow steps. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/get-workflow-steps/ + parameters: + - $ref: '#/components/parameters/flow_framework.get_steps___query.workflow_step' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/flow_framework.get_steps___200' + '400': + $ref: '#/components/responses/flow_framework.get_steps___400' + '403': + $ref: '#/components/responses/flow_framework.get_steps___403' + /_plugins/_flow_framework/workflow/{workflow_id}: + delete: + operationId: flow_framework.delete.0 + x-operation-group: flow_framework.delete + x-version-added: '2.12' + description: Deletes a workflow template. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/delete-workflow/ + parameters: + - $ref: '#/components/parameters/flow_framework.delete___path.workflow_id' + - $ref: '#/components/parameters/flow_framework.delete___query.clear_status' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/flow_framework.delete___200' + '400': + $ref: '#/components/responses/flow_framework.delete___400' + '403': + $ref: '#/components/responses/flow_framework.delete___403' + get: + operationId: flow_framework.get.0 + x-operation-group: flow_framework.get + x-version-added: '2.12' + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/get-workflow/ + description: Retrieves a workflow template. + parameters: + - $ref: '#/components/parameters/flow_framework.get___path.workflow_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/flow_framework.get___200' + '404': + $ref: '#/components/responses/flow_framework.get___404' + put: + operationId: flow_framework.update.0 + x-operation-group: flow_framework.update + x-version-added: '2.12' + description: Updates a workflow template that has not been provisioned. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/create-workflow/ + parameters: + - $ref: '#/components/parameters/flow_framework.update___path.workflow_id' + - $ref: '#/components/parameters/flow_framework.update___query.provision' + - $ref: '#/components/parameters/flow_framework.update___query.reprovision' + - $ref: '#/components/parameters/flow_framework.update___query.update_fields' + - $ref: '#/components/parameters/flow_framework.update___query.use_case' + - $ref: '#/components/parameters/flow_framework.update___query.validation' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/flow_framework.update' + responses: + '201': + $ref: '#/components/responses/flow_framework.update___201' + description: It returns the `workflow_id`. + '400': + $ref: '#/components/responses/flow_framework.update___400' + '404': + $ref: '#/components/responses/flow_framework.update___404' + /_plugins/_flow_framework/workflow/{workflow_id}/_deprovision: + post: + operationId: flow_framework.deprovision.0 + x-operation-group: flow_framework.deprovision + x-version-added: '2.12' + description: Deprovision workflow's resources when you no longer need them. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/deprovision-workflow/ + parameters: + - $ref: '#/components/parameters/flow_framework.deprovision___path.workflow_id' + - $ref: '#/components/parameters/flow_framework.deprovision___query.allow_delete' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/flow_framework.deprovision___200' + '202': + $ref: '#/components/responses/flow_framework.deprovision___202' + '403': + $ref: '#/components/responses/flow_framework.deprovision___403' + '404': + $ref: '#/components/responses/flow_framework.deprovision___404' + /_plugins/_flow_framework/workflow/{workflow_id}/_provision: + post: + operationId: flow_framework.provision.0 + x-operation-group: flow_framework.provision + x-version-added: '2.12' + description: Provisioning a workflow. This API is also executed when the Create or Update Workflow API is called with the provision parameter set to true. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/provision-workflow/ + parameters: + - $ref: '#/components/parameters/flow_framework.provision___path.workflow_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + description: |- + Pass dynamic substitution expressions as key-value pairs, either as query parameters or in the request body. + For example, if you specified a credential field in the template as `openai_key: '$'`, + you can pass `openai_key` as a query parameter or in the request body. + $ref: '#/components/requestBodies/flow_framework.provision' + responses: + '200': + $ref: '#/components/responses/flow_framework.provision___200' + '202': + $ref: '#/components/responses/flow_framework.provision___202' + '400': + $ref: '#/components/responses/flow_framework.provision___400' + '403': + $ref: '#/components/responses/flow_framework.provision___403' + /_plugins/_flow_framework/workflow/{workflow_id}/_status: + get: + operationId: flow_framework.get_status.0 + x-operation-group: flow_framework.get_status + x-version-added: '2.12' + description: Retrieves the current workflow provisioning status. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/get-workflow-status/ + parameters: + - $ref: '#/components/parameters/flow_framework.get_status___path.workflow_id' + - $ref: '#/components/parameters/flow_framework.get_status___query.all' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/flow_framework.get_status___200' + '403': + $ref: '#/components/responses/flow_framework.get_status___403' + '404': + $ref: '#/components/responses/flow_framework.get_status___404' + /_plugins/_flow_framework/workflow/state/_search: + get: + operationId: flow_framework.search_state.1 + x-operation-group: flow_framework.search_state + x-version-added: '2.12' + description: Search for workflows by using a query matching a field. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/search-workflow-state/ + requestBody: + $ref: '#/components/requestBodies/flow_framework.search_state' + responses: + '200': + $ref: '#/components/responses/flow_framework.search_state___200' + '400': + $ref: '#/components/responses/flow_framework.search_state___400' + '403': + $ref: '#/components/responses/flow_framework.search_state___403' + '408': + $ref: '#/components/responses/flow_framework.search_state___408' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: flow_framework.search_state.0 + x-operation-group: flow_framework.search_state + x-version-added: '2.12' + description: Search for workflows by using a query matching a field. + externalDocs: + url: https://opensearch.org/docs/latest/automating-configurations/api/search-workflow-state/ + requestBody: + $ref: '#/components/requestBodies/flow_framework.search_state' + responses: + '200': + $ref: '#/components/responses/flow_framework.search_state___200' + '400': + $ref: '#/components/responses/flow_framework.search_state___400' + '403': + $ref: '#/components/responses/flow_framework.search_state___403' + '408': + $ref: '#/components/responses/flow_framework.search_state___408' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ism/add: + post: + operationId: ism.add_policy.0 + x-operation-group: ism.add_policy + description: Adds a policy to an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#add-policy + parameters: + - $ref: '#/components/parameters/ism.add_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.add_policy' + responses: + '200': + $ref: '#/components/responses/ism.add_policy___200' + /_plugins/_ism/add/{index}: + post: + operationId: ism.add_policy.1 + x-operation-group: ism.add_policy + description: Adds a policy to an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#add-policy + parameters: + - $ref: '#/components/parameters/ism.add_policy___path.index' + - $ref: '#/components/parameters/ism.add_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.add_policy' + responses: + '200': + $ref: '#/components/responses/ism.add_policy___200' + /_plugins/_ism/change_policy: + post: + operationId: ism.change_policy.0 + x-operation-group: ism.change_policy + description: Updates the managed index policy to a new policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#update-managed-index-policy + parameters: + - $ref: '#/components/parameters/ism.change_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.change_policy' + responses: + '200': + $ref: '#/components/responses/ism.change_policy___200' + /_plugins/_ism/change_policy/{index}: + post: + operationId: ism.change_policy.1 + x-operation-group: ism.change_policy + description: Updates the managed index policy to a new policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#update-managed-index-policy + parameters: + - $ref: '#/components/parameters/ism.change_policy___path.index' + - $ref: '#/components/parameters/ism.change_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.change_policy' + responses: + '200': + $ref: '#/components/responses/ism.change_policy___200' + /_plugins/_ism/explain: + get: + operationId: ism.explain_policy.0 + x-operation-group: ism.explain_policy + description: Retrieves the currently applied policy on the specified indexes. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index + requestBody: + $ref: '#/components/requestBodies/ism.explain_policy' + responses: + '200': + $ref: '#/components/responses/ism.explain_policy___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: ism.explain_policy.1 + x-operation-group: ism.explain_policy + description: Retrieves the currently applied policy on the specified indexes. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index + requestBody: + $ref: '#/components/requestBodies/ism.explain_policy' + responses: + '200': + $ref: '#/components/responses/ism.explain_policy___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ism/explain/{index}: + get: + operationId: ism.explain_policy.3 + x-operation-group: ism.explain_policy + description: Retrieves the currently applied policy on the specified indexes. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index + parameters: + - $ref: '#/components/parameters/ism.explain_policy___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.explain_policy' + responses: + '200': + $ref: '#/components/responses/ism.explain_policy___200' + post: + operationId: ism.explain_policy.4 + x-operation-group: ism.explain_policy + description: Retrieves the currently applied policy on the specified indexes. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index + parameters: + - $ref: '#/components/parameters/ism.explain_policy___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.explain_policy' + responses: + '200': + $ref: '#/components/responses/ism.explain_policy___200' + /_plugins/_ism/policies: + get: + operationId: ism.get_policies.0 + x-operation-group: ism.get_policies + description: Retrieves the policies. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#get-policy + responses: + '200': + $ref: '#/components/responses/ism.get_policies___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: ism.put_policies.0 + x-operation-group: ism.put_policies + description: Creates or updates policies. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#create-policy + requestBody: + $ref: '#/components/requestBodies/ism.put_policies' + parameters: + - $ref: '#/components/parameters/ism.put_policies___query.if_primary_term' + - $ref: '#/components/parameters/ism.put_policies___query.if_seq_no' + - $ref: '#/components/parameters/ism.put_policies___query.policyID' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.put_policies___200' + /_plugins/_ism/policies/{policy_id}: + delete: + operationId: ism.delete_policy.0 + x-operation-group: ism.delete_policy + description: Deletes a policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#delete-policy + parameters: + - $ref: '#/components/parameters/ism.delete_policy___path.policy_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.delete_policy___200' + get: + operationId: ism.get_policy.0 + x-operation-group: ism.get_policy + description: Retrieves a specific policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#put-policy + parameters: + - $ref: '#/components/parameters/ism.get_policy___path.policy_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.get_policy___200' + head: + operationId: ism.exists_policy.0 + x-operation-group: ism.exists_policy + description: Checks for the existence of a policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#get-policy + parameters: + - $ref: '#/components/parameters/ism.exists_policy___path.policy_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.exists_policy___200' + '404': + $ref: '#/components/responses/ism.exists_policy___404' + put: + operationId: ism.put_policy.0 + x-operation-group: ism.put_policy + description: Creates or updates a policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#create-policy + parameters: + - $ref: '#/components/parameters/ism.put_policy___path.policy_id' + - $ref: '#/components/parameters/ism.put_policy___query.if_primary_term' + - $ref: '#/components/parameters/ism.put_policy___query.if_seq_no' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.put_policy' + responses: + '200': + $ref: '#/components/responses/ism.put_policy___200' + '201': + $ref: '#/components/responses/ism.put_policy___201' + /_plugins/_ism/remove: + post: + operationId: ism.remove_policy.0 + x-operation-group: ism.remove_policy + description: Removes a policy from an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#remove-policy + parameters: + - $ref: '#/components/parameters/ism.remove_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.remove_policy___200' + /_plugins/_ism/remove/{index}: + post: + operationId: ism.remove_policy.1 + x-operation-group: ism.remove_policy + description: Removes a policy from an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#remove-policy + parameters: + - $ref: '#/components/parameters/ism.remove_policy___path.index' + - $ref: '#/components/parameters/ism.remove_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.remove_policy___200' + /_plugins/_ism/retry: + post: + operationId: ism.retry_index.0 + x-operation-group: ism.retry_index + description: Retries the failed action for an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#retry-failed-index + parameters: + - $ref: '#/components/parameters/ism.retry_index___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.retry_index' + responses: + '200': + $ref: '#/components/responses/ism.retry_index___200' + /_plugins/_ism/retry/{index}: + post: + operationId: ism.retry_index.1 + x-operation-group: ism.retry_index + description: Retries the failed action for an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#retry-failed-index + parameters: + - $ref: '#/components/parameters/ism.retry_index___path.index' + - $ref: '#/components/parameters/ism.retry_index___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.retry_index' + responses: + '200': + $ref: '#/components/responses/ism.retry_index___200' + /_plugins/_knn/{node_id}/stats: + get: + operationId: knn.stats.2 + x-operation-group: knn.stats + x-version-added: '1.0' + description: Provides information about the current status of the k-NN plugin. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#stats + parameters: + - $ref: '#/components/parameters/knn.stats___path.node_id' + - $ref: '#/components/parameters/knn.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.stats___200' + /_plugins/_knn/{node_id}/stats/{stat}: + get: + operationId: knn.stats.3 + x-operation-group: knn.stats + x-version-added: '1.0' + description: Provides information about the current status of the k-NN plugin. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#stats + parameters: + - $ref: '#/components/parameters/knn.stats___path.node_id' + - $ref: '#/components/parameters/knn.stats___path.stat' + - $ref: '#/components/parameters/knn.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.stats___200' + /_plugins/_knn/models/_search: + get: + operationId: knn.search_models.0 + x-operation-group: knn.search_models + x-version-added: '1.0' + description: Use an OpenSearch query to search for models in the index. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#search-for-a-model + parameters: + - $ref: '#/components/parameters/knn.search_models___query._source' + - $ref: '#/components/parameters/knn.search_models___query._source_excludes' + - $ref: '#/components/parameters/knn.search_models___query._source_includes' + - $ref: '#/components/parameters/knn.search_models___query.allow_no_indices' + - $ref: '#/components/parameters/knn.search_models___query.allow_partial_search_results' + - $ref: '#/components/parameters/knn.search_models___query.analyze_wildcard' + - $ref: '#/components/parameters/knn.search_models___query.analyzer' + - $ref: '#/components/parameters/knn.search_models___query.batched_reduce_size' + - $ref: '#/components/parameters/knn.search_models___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/knn.search_models___query.default_operator' + - $ref: '#/components/parameters/knn.search_models___query.df' + - $ref: '#/components/parameters/knn.search_models___query.docvalue_fields' + - $ref: '#/components/parameters/knn.search_models___query.expand_wildcards' + - $ref: '#/components/parameters/knn.search_models___query.explain' + - $ref: '#/components/parameters/knn.search_models___query.from' + - $ref: '#/components/parameters/knn.search_models___query.ignore_throttled' + - $ref: '#/components/parameters/knn.search_models___query.ignore_unavailable' + - $ref: '#/components/parameters/knn.search_models___query.lenient' + - $ref: '#/components/parameters/knn.search_models___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/knn.search_models___query.pre_filter_shard_size' + - $ref: '#/components/parameters/knn.search_models___query.preference' + - $ref: '#/components/parameters/knn.search_models___query.q' + - $ref: '#/components/parameters/knn.search_models___query.request_cache' + - $ref: '#/components/parameters/knn.search_models___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/knn.search_models___query.routing' + - $ref: '#/components/parameters/knn.search_models___query.scroll' + - $ref: '#/components/parameters/knn.search_models___query.search_type' + - $ref: '#/components/parameters/knn.search_models___query.seq_no_primary_term' + - $ref: '#/components/parameters/knn.search_models___query.size' + - $ref: '#/components/parameters/knn.search_models___query.sort' + - $ref: '#/components/parameters/knn.search_models___query.stats' + - $ref: '#/components/parameters/knn.search_models___query.stored_fields' + - $ref: '#/components/parameters/knn.search_models___query.suggest_field' + - $ref: '#/components/parameters/knn.search_models___query.suggest_mode' + - $ref: '#/components/parameters/knn.search_models___query.suggest_size' + - $ref: '#/components/parameters/knn.search_models___query.suggest_text' + - $ref: '#/components/parameters/knn.search_models___query.terminate_after' + - $ref: '#/components/parameters/knn.search_models___query.timeout' + - $ref: '#/components/parameters/knn.search_models___query.track_scores' + - $ref: '#/components/parameters/knn.search_models___query.track_total_hits' + - $ref: '#/components/parameters/knn.search_models___query.typed_keys' + - $ref: '#/components/parameters/knn.search_models___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/knn.search_models' + responses: + '200': + $ref: '#/components/responses/knn.search_models___200' + post: + operationId: knn.search_models.1 + x-operation-group: knn.search_models + x-version-added: '1.0' + description: Use an OpenSearch query to search for models in the index. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#search-for-a-model + parameters: + - $ref: '#/components/parameters/knn.search_models___query._source' + - $ref: '#/components/parameters/knn.search_models___query._source_excludes' + - $ref: '#/components/parameters/knn.search_models___query._source_includes' + - $ref: '#/components/parameters/knn.search_models___query.allow_no_indices' + - $ref: '#/components/parameters/knn.search_models___query.allow_partial_search_results' + - $ref: '#/components/parameters/knn.search_models___query.analyze_wildcard' + - $ref: '#/components/parameters/knn.search_models___query.analyzer' + - $ref: '#/components/parameters/knn.search_models___query.batched_reduce_size' + - $ref: '#/components/parameters/knn.search_models___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/knn.search_models___query.default_operator' + - $ref: '#/components/parameters/knn.search_models___query.df' + - $ref: '#/components/parameters/knn.search_models___query.docvalue_fields' + - $ref: '#/components/parameters/knn.search_models___query.expand_wildcards' + - $ref: '#/components/parameters/knn.search_models___query.explain' + - $ref: '#/components/parameters/knn.search_models___query.from' + - $ref: '#/components/parameters/knn.search_models___query.ignore_throttled' + - $ref: '#/components/parameters/knn.search_models___query.ignore_unavailable' + - $ref: '#/components/parameters/knn.search_models___query.lenient' + - $ref: '#/components/parameters/knn.search_models___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/knn.search_models___query.pre_filter_shard_size' + - $ref: '#/components/parameters/knn.search_models___query.preference' + - $ref: '#/components/parameters/knn.search_models___query.q' + - $ref: '#/components/parameters/knn.search_models___query.request_cache' + - $ref: '#/components/parameters/knn.search_models___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/knn.search_models___query.routing' + - $ref: '#/components/parameters/knn.search_models___query.scroll' + - $ref: '#/components/parameters/knn.search_models___query.search_type' + - $ref: '#/components/parameters/knn.search_models___query.seq_no_primary_term' + - $ref: '#/components/parameters/knn.search_models___query.size' + - $ref: '#/components/parameters/knn.search_models___query.sort' + - $ref: '#/components/parameters/knn.search_models___query.stats' + - $ref: '#/components/parameters/knn.search_models___query.stored_fields' + - $ref: '#/components/parameters/knn.search_models___query.suggest_field' + - $ref: '#/components/parameters/knn.search_models___query.suggest_mode' + - $ref: '#/components/parameters/knn.search_models___query.suggest_size' + - $ref: '#/components/parameters/knn.search_models___query.suggest_text' + - $ref: '#/components/parameters/knn.search_models___query.terminate_after' + - $ref: '#/components/parameters/knn.search_models___query.timeout' + - $ref: '#/components/parameters/knn.search_models___query.track_scores' + - $ref: '#/components/parameters/knn.search_models___query.track_total_hits' + - $ref: '#/components/parameters/knn.search_models___query.typed_keys' + - $ref: '#/components/parameters/knn.search_models___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/knn.search_models' + responses: + '200': + $ref: '#/components/responses/knn.search_models___200' + /_plugins/_knn/models/_train: + post: + operationId: knn.train_model.0 + x-operation-group: knn.train_model + x-version-added: '1.0' + description: Create and train a model that can be used for initializing k-NN native library indexes during indexing. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#train-a-model + parameters: + - $ref: '#/components/parameters/knn.train_model___query.preference' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/knn.train_model' + responses: + '200': + $ref: '#/components/responses/knn.train_model___200' + /_plugins/_knn/models/{model_id}: + delete: + operationId: knn.delete_model.0 + x-operation-group: knn.delete_model + x-version-added: '1.0' + description: Used to delete a particular model in the cluster. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#delete-a-model + parameters: + - $ref: '#/components/parameters/knn.delete_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.delete_model___200' + get: + operationId: knn.get_model.0 + x-operation-group: knn.get_model + x-version-added: '1.0' + description: Used to retrieve information about models present in the cluster. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#get-a-model + parameters: + - $ref: '#/components/parameters/knn.get_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.get_model___200' + /_plugins/_knn/models/{model_id}/_train: + post: + operationId: knn.train_model.1 + x-operation-group: knn.train_model + x-version-added: '1.0' + description: Create and train a model that can be used for initializing k-NN native library indexes during indexing. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#train-a-model + parameters: + - $ref: '#/components/parameters/knn.train_model___path.model_id' + - $ref: '#/components/parameters/knn.train_model___query.preference' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/knn.train_model' + responses: + '200': + $ref: '#/components/responses/knn.train_model___200' + /_plugins/_knn/stats: + get: + operationId: knn.stats.0 + x-operation-group: knn.stats + x-version-added: '1.0' + description: Provides information about the current status of the k-NN plugin. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#stats + parameters: + - $ref: '#/components/parameters/knn.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.stats___200' + /_plugins/_knn/stats/{stat}: + get: + operationId: knn.stats.1 + x-operation-group: knn.stats + x-version-added: '1.0' + description: Provides information about the current status of the k-NN plugin. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#stats + parameters: + - $ref: '#/components/parameters/knn.stats___path.stat' + - $ref: '#/components/parameters/knn.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.stats___200' + /_plugins/_knn/warmup/{index}: + get: + operationId: knn.warmup.0 + x-operation-group: knn.warmup + x-version-added: '1.0' + description: Preloads native library files into memory, reducing initial search latency for specified indexes. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#warmup-operation + parameters: + - $ref: '#/components/parameters/knn.warmup___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.warmup___200' + /_plugins/_ltr/{node_id}/stats: + get: + operationId: ltr.stats.2 + x-operation-group: ltr.stats + x-version-added: '2.19' + description: Provides information about the current status of the LTR plugin. + parameters: + - $ref: '#/components/parameters/ltr.stats___path.node_id' + - $ref: '#/components/parameters/ltr.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.stats___200' + /_plugins/_ltr/{node_id}/stats/{stat}: + get: + operationId: ltr.stats.3 + x-operation-group: ltr.stats + x-version-added: '2.19' + description: Provides information about the current status of the LTR plugin. + parameters: + - $ref: '#/components/parameters/ltr.stats___path.node_id' + - $ref: '#/components/parameters/ltr.stats___path.stat' + - $ref: '#/components/parameters/ltr.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.stats___200' + /_plugins/_ltr/stats: + get: + operationId: ltr.stats.0 + x-operation-group: ltr.stats + x-version-added: '2.19' + description: Provides information about the current status of the LTR plugin. + parameters: + - $ref: '#/components/parameters/ltr.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.stats___200' + /_plugins/_ltr/stats/{stat}: + get: + operationId: ltr.stats.1 + x-operation-group: ltr.stats + x-version-added: '2.19' + description: Provides information about the current status of the LTR plugin. + parameters: + - $ref: '#/components/parameters/ltr.stats___path.stat' + - $ref: '#/components/parameters/ltr.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ltr.stats___200' + /_plugins/_ml/_execute/{algorithm_name}: + post: + operationId: ml.execute_algorithm.0 + x-operation-group: ml.execute_algorithm + x-version-added: '2.0' + description: Execute an algorithm. + parameters: + - $ref: '#/components/parameters/ml.execute_algorithm___path.algorithm_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.execute_algorithm' + responses: + '200': + $ref: '#/components/responses/ml.execute_algorithm___200' + /_plugins/_ml/_predict/{algorithm_name}/{model_id}: + post: + operationId: ml.predict.0 + x-operation-group: ml.predict + x-version-added: '1.3' + description: Predicts new data with trained model. + parameters: + - $ref: '#/components/parameters/ml.predict___path.algorithm_name' + - $ref: '#/components/parameters/ml.predict___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.predict' + responses: + '200': + $ref: '#/components/responses/ml.predict___200' + /_plugins/_ml/_train_predict/{algorithm_name}: + post: + operationId: ml.train_predict.0 + x-operation-group: ml.train_predict + x-version-added: '1.3' + description: Trains a model and predicts against the same training dataset. + parameters: + - $ref: '#/components/parameters/ml.train_predict___path.algorithm_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.train_predict' + responses: + '200': + $ref: '#/components/responses/ml.train_predict___200' + /_plugins/_ml/_train/{algorithm_name}: + post: + operationId: ml.train.0 + x-operation-group: ml.train + x-version-added: '1.3' + description: Trains a model synchronously. + parameters: + - $ref: '#/components/parameters/ml.train___path.algorithm_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.train' + responses: + '200': + $ref: '#/components/responses/ml.train___200' + /_plugins/_ml/{node_id}/stats: + get: + operationId: ml.get_stats.2 + x-operation-group: ml.get_stats + x-version-added: '1.3' + description: Get stats. + parameters: + - $ref: '#/components/parameters/ml.get_stats___path.node_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_stats___200' + /_plugins/_ml/{node_id}/stats/{stat}: + get: + operationId: ml.get_stats.3 + x-operation-group: ml.get_stats + x-version-added: '1.3' + description: Get stats. + parameters: + - $ref: '#/components/parameters/ml.get_stats___path.node_id' + - $ref: '#/components/parameters/ml.get_stats___path.stat' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_stats___200' + /_plugins/_ml/agents/_register: + post: + operationId: ml.register_agents.0 + x-operation-group: ml.register_agents + x-version-added: '2.13' + description: Register an agent. + requestBody: + $ref: '#/components/requestBodies/ml.register_agents' + responses: + '200': + $ref: '#/components/responses/ml.register_agents___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/agents/_search: + get: + operationId: ml.search_agents.0 + x-operation-group: ml.search_agents + x-version-added: '2.13' + description: Search agents. + requestBody: + $ref: '#/components/requestBodies/ml.search_agents' + responses: + '200': + $ref: '#/components/responses/ml.search_agents___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: ml.search_agents.1 + x-operation-group: ml.search_agents + description: Search agents. + x-version-added: '2.13' + requestBody: + $ref: '#/components/requestBodies/ml.search_agents' + responses: + '200': + $ref: '#/components/responses/ml.search_agents___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/agents/{agent_id}: + delete: + operationId: ml.delete_agent.0 + x-operation-group: ml.delete_agent + x-version-added: '2.13' + description: Delete an agent. + parameters: + - $ref: '#/components/parameters/ml.delete_agent___path.agent_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_agent___200' + get: + operationId: ml.get_agent.0 + x-operation-group: ml.get_agent + x-version-added: '2.13' + description: Get an agent. + parameters: + - $ref: '#/components/parameters/ml.get_agent___path.agent_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_agent___200' + /_plugins/_ml/agents/{agent_id}/_execute: + post: + operationId: ml.execute_agent.0 + x-operation-group: ml.execute_agent + x-version-added: '2.13' + description: Execute an agent. + parameters: + - $ref: '#/components/parameters/ml.execute_agent___path.agent_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.execute_agent' + responses: + '200': + $ref: '#/components/responses/ml.execute_agent___200' + /_plugins/_ml/agents/{agent_id}/_execute/stream: + post: + operationId: ml.execute_agent_stream.0 + x-operation-group: ml.execute_agent_stream + x-version-added: '3.3' + description: Execute an agent in streaming mode. + parameters: + - $ref: '#/components/parameters/ml.execute_agent_stream___path.agent_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.execute_agent_stream' + responses: + '200': + $ref: '#/components/responses/ml.execute_agent_stream___200' + /_plugins/_ml/connectors/_create: + post: + operationId: ml.create_connector.0 + x-operation-group: ml.create_connector + description: Creates a standalone connector. + requestBody: + $ref: '#/components/requestBodies/ml.create_connector' + responses: + '200': + $ref: '#/components/responses/ml.create_connector___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/connectors/_search: + get: + operationId: ml.search_connectors.0 + x-operation-group: ml.search_connectors + x-version-added: '2.11' + description: Searches for standalone connectors. + requestBody: + $ref: '#/components/requestBodies/ml.search_connectors' + responses: + '200': + $ref: '#/components/responses/ml.search_connectors___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: ml.search_connectors.1 + x-operation-group: ml.search_connectors + x-version-added: '2.11' + description: Searches for standalone connectors. + requestBody: + $ref: '#/components/requestBodies/ml.search_connectors' + responses: + '200': + $ref: '#/components/responses/ml.search_connectors___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/connectors/{connector_id}: + delete: + operationId: ml.delete_connector.0 + x-operation-group: ml.delete_connector + description: Deletes a standalone connector. + parameters: + - $ref: '#/components/parameters/ml.delete_connector___path.connector_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_connector___200' + get: + operationId: ml.get_connector.0 + x-operation-group: ml.get_connector + x-version-added: '2.11' + description: Retrieves a standalone connector. + parameters: + - $ref: '#/components/parameters/ml.get_connector___path.connector_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_connector___200' + put: + operationId: ml.update_connector.0 + x-operation-group: ml.update_connector + x-version-added: '2.12' + description: Updates a standalone connector. + parameters: + - $ref: '#/components/parameters/ml.update_connector___path.connector_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.update_connector' + responses: + '200': + $ref: '#/components/responses/ml.update_connector___200' + /_plugins/_ml/controllers/{model_id}: + delete: + operationId: ml.delete_controller.0 + x-operation-group: ml.delete_controller + x-version-added: '2.12' + description: Deletes a controller. + parameters: + - $ref: '#/components/parameters/ml.delete_controller___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_controller___200' + get: + operationId: ml.get_controller.0 + x-operation-group: ml.get_controller + x-version-added: '2.12' + description: Retrieves a controller. + parameters: + - $ref: '#/components/parameters/ml.get_controller___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_controller___200' + post: + operationId: ml.create_controller.0 + x-operation-group: ml.create_controller + x-version-added: '2.12' + description: Creates a controller. + requestBody: + $ref: '#/components/requestBodies/ml.create_controller' + parameters: + - $ref: '#/components/parameters/ml.create_controller___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.create_controller___200' + put: + operationId: ml.update_controller.0 + x-operation-group: ml.update_controller + x-version-added: '2.12' + description: Updates a controller. + requestBody: + $ref: '#/components/requestBodies/ml.update_controller' + parameters: + - $ref: '#/components/parameters/ml.update_controller___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.update_controller___200' + /_plugins/_ml/memory: + get: + operationId: ml.get_all_memories.0 + x-operation-group: ml.get_all_memories + x-version-added: '2.12' + description: Get all memories. + parameters: + - $ref: '#/components/parameters/ml.get_all_memories___query.max_results' + - $ref: '#/components/parameters/ml.get_all_memories___query.next_token' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_all_memories___200' + post: + operationId: ml.create_memory.0 + x-operation-group: ml.create_memory + x-version-added: '2.12' + description: Create a memory. + requestBody: + $ref: '#/components/requestBodies/ml.create_memory' + responses: + '200': + $ref: '#/components/responses/ml.create_memory___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/memory_containers/_create: + post: + operationId: ml.create_memory_container.0 + x-operation-group: ml.create_memory_container + x-version-added: '3.3' + description: Create a memory container. + requestBody: + $ref: '#/components/requestBodies/ml.create_memory_container' + responses: + '200': + $ref: '#/components/responses/ml.create_memory_container___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/memory_containers/_search: + get: + operationId: ml.search_memory_container.1 + x-operation-group: ml.search_memory_container + x-version-added: '3.3' + description: Search memory containers. + requestBody: + $ref: '#/components/requestBodies/ml.search_memory_container' + responses: + '200': + $ref: '#/components/responses/ml.search_memory_container___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: ml.search_memory_container.0 + x-operation-group: ml.search_memory_container + x-version-added: '3.3' + description: Search memory containers. + requestBody: + $ref: '#/components/requestBodies/ml.search_memory_container' + responses: + '200': + $ref: '#/components/responses/ml.search_memory_container___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/memory_containers/{memory_container_id}: + delete: + operationId: ml.delete_memory_container.0 + x-operation-group: ml.delete_memory_container + x-version-added: '3.3' + description: Delete a memory container. + parameters: + - $ref: '#/components/parameters/ml.delete_memory_container___path.memory_container_id' + - $ref: '#/components/parameters/ml.delete_memory_container___query.delete_all_memories' + - $ref: '#/components/parameters/ml.delete_memory_container___query.delete_memories' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_memory_container___200' + get: + operationId: ml.get_memory_container.0 + x-operation-group: ml.get_memory_container + x-version-added: '3.3' + description: Get a memory container. + parameters: + - $ref: '#/components/parameters/ml.get_memory_container___path.memory_container_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_memory_container___200' + put: + operationId: ml.update_memory_container.0 + x-operation-group: ml.update_memory_container + x-version-added: '3.3' + description: Update a memory container. + parameters: + - $ref: '#/components/parameters/ml.update_memory_container___path.memory_container_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.update_memory_container' + responses: + '200': + $ref: '#/components/responses/ml.update_memory_container___200' + /_plugins/_ml/memory_containers/{memory_container_id}/memories: + post: + operationId: ml.add_agentic_memory.0 + x-operation-group: ml.add_agentic_memory + x-version-added: '3.3' + description: Add agentic memory to a memory container. + parameters: + - $ref: '#/components/parameters/ml.add_agentic_memory___path.memory_container_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.add_agentic_memory' + responses: + '200': + $ref: '#/components/responses/ml.add_agentic_memory___200' + /_plugins/_ml/memory_containers/{memory_container_id}/memories/{type}/_delete_by_query: + post: + operationId: ml.delete_agentic_memory_query.0 + x-operation-group: ml.delete_agentic_memory_query + x-version-added: '3.3' + description: Delete multiple memories using a query to match specific criteria. + parameters: + - $ref: '#/components/parameters/ml.delete_agentic_memory_query___path.memory_container_id' + - $ref: '#/components/parameters/ml.delete_agentic_memory_query___path.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.delete_agentic_memory_query' + responses: + '200': + $ref: '#/components/responses/ml.delete_agentic_memory_query___200' + /_plugins/_ml/memory_containers/{memory_container_id}/memories/{type}/_search: + get: + operationId: ml.search_agentic_memory.0 + x-operation-group: ml.search_agentic_memory + x-version-added: '3.3' + description: Search for memories of a specific type within a memory container. + parameters: + - $ref: '#/components/parameters/ml.search_agentic_memory___path.memory_container_id' + - $ref: '#/components/parameters/ml.search_agentic_memory___path.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.search_agentic_memory' + responses: + '200': + $ref: '#/components/responses/ml.search_agentic_memory___200' + /_plugins/_ml/memory_containers/{memory_container_id}/memories/{type}/{id}: + delete: + operationId: ml.delete_agentic_memory.0 + x-operation-group: ml.delete_agentic_memory + x-version-added: '3.3' + description: Delete a specific memory by its type and ID. + parameters: + - $ref: '#/components/parameters/ml.delete_agentic_memory___path.id' + - $ref: '#/components/parameters/ml.delete_agentic_memory___path.memory_container_id' + - $ref: '#/components/parameters/ml.delete_agentic_memory___path.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_agentic_memory___200' + get: + operationId: ml.get_agentic_memory.0 + x-operation-group: ml.get_agentic_memory + x-version-added: '3.3' + description: Get a specific memory by its type and ID. + parameters: + - $ref: '#/components/parameters/ml.get_agentic_memory___path.id' + - $ref: '#/components/parameters/ml.get_agentic_memory___path.memory_container_id' + - $ref: '#/components/parameters/ml.get_agentic_memory___path.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_agentic_memory___200' + put: + operationId: ml.update_agentic_memory.0 + x-operation-group: ml.update_agentic_memory + x-version-added: '3.3' + description: Update a specific memory by its type and ID. + parameters: + - $ref: '#/components/parameters/ml.update_agentic_memory___path.id' + - $ref: '#/components/parameters/ml.update_agentic_memory___path.memory_container_id' + - $ref: '#/components/parameters/ml.update_agentic_memory___path.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.update_agentic_memory' + responses: + '200': + $ref: '#/components/responses/ml.update_agentic_memory___200' + /_plugins/_ml/memory_containers/{memory_container_id}/memories/sessions: + post: + operationId: ml.create_memory_container_session.0 + x-operation-group: ml.create_memory_container_session + x-version-added: '3.3' + description: Create session in a memory container. + parameters: + - $ref: '#/components/parameters/ml.create_memory_container_session___path.memory_container_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.create_memory_container_session' + responses: + '200': + $ref: '#/components/responses/ml.create_memory_container_session___200' + /_plugins/_ml/memory/_search: + get: + operationId: ml.search_memory.0 + x-operation-group: ml.search_memory + x-version-added: '2.12' + description: Search memory. + requestBody: + $ref: '#/components/requestBodies/ml.search_memory' + responses: + '200': + $ref: '#/components/responses/ml.search_memory___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: ml.search_memory.1 + x-operation-group: ml.search_memory + x-version-added: '2.12' + description: Search memory. + requestBody: + $ref: '#/components/requestBodies/ml.search_memory' + responses: + '200': + $ref: '#/components/responses/ml.search_memory___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/memory/{memory_id}: + delete: + operationId: ml.delete_memory.0 + x-operation-group: ml.delete_memory + x-version-added: '2.12' + description: Delete a memory. + parameters: + - $ref: '#/components/parameters/ml.delete_memory___path.memory_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_memory___200' + get: + operationId: ml.get_memory.0 + x-operation-group: ml.get_memory + x-version-added: '2.12' + description: Get a memory. + parameters: + - $ref: '#/components/parameters/ml.get_memory___path.memory_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_memory___200' + put: + operationId: ml.update_memory.0 + x-operation-group: ml.update_memory + x-version-added: '2.12' + description: Update a memory. + parameters: + - $ref: '#/components/parameters/ml.update_memory___path.memory_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.update_memory' + responses: + '200': + $ref: '#/components/responses/ml.update_memory___200' + /_plugins/_ml/memory/{memory_id}/_search: + get: + operationId: ml.search_message.0 + x-operation-group: ml.search_message + x-version-added: '2.12' + description: Search messages. + parameters: + - $ref: '#/components/parameters/ml.search_message___path.memory_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.search_message' + responses: + '200': + $ref: '#/components/responses/ml.search_message___200' + post: + operationId: ml.search_message.1 + x-operation-group: ml.search_message + x-version-added: '2.12' + description: Search messages. + parameters: + - $ref: '#/components/parameters/ml.search_message___path.memory_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.search_message' + responses: + '200': + $ref: '#/components/responses/ml.search_message___200' + /_plugins/_ml/memory/{memory_id}/messages: + get: + operationId: ml.get_all_messages.0 + x-operation-group: ml.get_all_messages + x-version-added: '2.12' + description: Get all messages in a memory. + parameters: + - $ref: '#/components/parameters/ml.get_all_messages___path.memory_id' + - $ref: '#/components/parameters/ml.get_all_messages___query.max_results' + - $ref: '#/components/parameters/ml.get_all_messages___query.next_token' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_all_messages___200' + post: + operationId: ml.create_message.0 + x-operation-group: ml.create_message + x-version-added: '2.12' + description: Create a message. + parameters: + - $ref: '#/components/parameters/ml.create_message___path.memory_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.create_message' + responses: + '200': + $ref: '#/components/responses/ml.create_message___200' + /_plugins/_ml/memory/message/{message_id}: + get: + operationId: ml.get_message.0 + x-operation-group: ml.get_message + x-version-added: '2.12' + description: Get a message. + parameters: + - $ref: '#/components/parameters/ml.get_message___path.message_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_message___200' + put: + operationId: ml.update_message.0 + x-operation-group: ml.update_message + x-version-added: '2.12' + description: Update a message. + parameters: + - $ref: '#/components/parameters/ml.update_message___path.message_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.update_message' + responses: + '200': + $ref: '#/components/responses/ml.update_message___200' + /_plugins/_ml/memory/message/{message_id}/traces: + get: + operationId: ml.get_message_traces.0 + x-operation-group: ml.get_message_traces + x-version-added: '2.12' + description: Get a message traces. + parameters: + - $ref: '#/components/parameters/ml.get_message_traces___path.message_id' + - $ref: '#/components/parameters/ml.get_message_traces___query.max_results' + - $ref: '#/components/parameters/ml.get_message_traces___query.next_token' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_message_traces___200' + /_plugins/_ml/model_groups/_register: + post: + operationId: ml.register_model_group.0 + x-operation-group: ml.register_model_group + description: Registers a model group. + requestBody: + $ref: '#/components/requestBodies/ml.register_model_group' + responses: + '200': + $ref: '#/components/responses/ml.register_model_group___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/model_groups/_search: + get: + operationId: ml.search_model_group.0 + x-operation-group: ml.search_model_group + x-version-added: '2.9' + description: Searches for model groups. + requestBody: + $ref: '#/components/requestBodies/ml.search_model_group' + responses: + '200': + $ref: '#/components/responses/ml.search_model_group___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: ml.search_model_group.1 + x-operation-group: ml.search_model_group + x-version-added: '2.9' + description: Searches for model groups. + requestBody: + $ref: '#/components/requestBodies/ml.search_model_group' + responses: + '200': + $ref: '#/components/responses/ml.search_model_group___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/model_groups/{model_group_id}: + delete: + operationId: ml.delete_model_group.0 + x-operation-group: ml.delete_model_group + description: Deletes a model group. + parameters: + - $ref: '#/components/parameters/ml.delete_model_group___path.model_group_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_model_group___200' + get: + operationId: ml.get_model_group.0 + x-operation-group: ml.get_model_group + description: Retrieves a model group. + parameters: + - $ref: '#/components/parameters/ml.get_model_group___path.model_group_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_model_group___200' + put: + operationId: ml.update_model_group.0 + x-operation-group: ml.update_model_group + x-version-added: '2.9' + description: Updates a model group. + parameters: + - $ref: '#/components/parameters/ml.update_model_group___path.model_group_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.update_model_group' + responses: + '200': + $ref: '#/components/responses/ml.update_model_group___200' + /_plugins/_ml/models/_register: + post: + operationId: ml.register_model.0 + x-operation-group: ml.register_model + x-version-added: '2.7' + description: Registers a model. + requestBody: + $ref: '#/components/requestBodies/ml.register_model' + responses: + '200': + $ref: '#/components/responses/ml.register_model___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/models/_register_meta: + post: + operationId: ml.register_model_meta.0 + x-operation-group: ml.register_model_meta + x-version-added: '2.7' + description: Registers model metadata. + requestBody: + $ref: '#/components/requestBodies/ml.register_model_meta' + responses: + '200': + $ref: '#/components/responses/ml.register_model_meta___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/models/_search: + get: + operationId: ml.search_models.0 + x-operation-group: ml.search_models + x-version-added: '1.3' + description: Searches for models. + requestBody: + $ref: '#/components/requestBodies/ml.search_models' + responses: + '200': + $ref: '#/components/responses/ml.search_models___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: ml.search_models.1 + x-operation-group: ml.search_models + x-version-added: '1.3' + description: Searches for models. + requestBody: + $ref: '#/components/requestBodies/ml.search_models' + responses: + '200': + $ref: '#/components/responses/ml.search_models___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/models/_undeploy: + post: + operationId: ml.undeploy_model.1 + x-operation-group: ml.undeploy_model + x-version-added: '2.7' + description: Undeploys a model. + requestBody: + $ref: '#/components/requestBodies/ml.undeploy_model' + responses: + '200': + $ref: '#/components/responses/ml.undeploy_model___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/models/_unload: + post: + operationId: ml.unload_model.1 + x-operation-group: ml.unload_model + deprecated: true + x-version-deprecated: '2.7' + x-deprecation-message: Use `undeploy_model` instead. + description: Unloads a model. + requestBody: + $ref: '#/components/requestBodies/ml.unload_model' + responses: + '200': + $ref: '#/components/responses/ml.unload_model___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/models/_upload: + post: + operationId: ml.upload_model.0 + x-operation-group: ml.upload_model + deprecated: true + x-version-deprecated: '2.7' + x-deprecation-message: Use `register_model` instead. + description: Registers a model. + requestBody: + $ref: '#/components/requestBodies/ml.upload_model' + responses: + '200': + $ref: '#/components/responses/ml.upload_model___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/models/{model_id}: + delete: + operationId: ml.delete_model.0 + x-operation-group: ml.delete_model + x-version-added: '1.3' + description: Deletes a model. + parameters: + - $ref: '#/components/parameters/ml.delete_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_model___200' + get: + operationId: ml.get_model.0 + x-operation-group: ml.get_model + x-version-added: '1.3' + description: Retrieves a model. + parameters: + - $ref: '#/components/parameters/ml.get_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_model___200' + put: + operationId: ml.update_model.0 + x-operation-group: ml.update_model + x-version-added: '2.12' + description: Updates a model. + parameters: + - $ref: '#/components/parameters/ml.update_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.update_model' + responses: + '200': + $ref: '#/components/responses/ml.update_model___200' + /_plugins/_ml/models/{model_id}/_deploy: + post: + operationId: ml.deploy_model.0 + x-operation-group: ml.deploy_model + x-version-added: '2.7' + description: Deploys a model. + parameters: + - $ref: '#/components/parameters/ml.deploy_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.deploy_model___200' + /_plugins/_ml/models/{model_id}/_load: + post: + operationId: ml.load_model.0 + x-operation-group: ml.load_model + deprecated: true + x-version-deprecated: '2.7' + x-deprecation-message: Use `deploy_model` instead. + description: Deploys a model. + parameters: + - $ref: '#/components/parameters/ml.load_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.load_model___200' + /_plugins/_ml/models/{model_id}/_predict: + post: + operationId: ml.predict_model.0 + x-operation-group: ml.predict_model + x-version-added: '2.12' + description: Predicts a model. + parameters: + - $ref: '#/components/parameters/ml.predict_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.predict_model' + responses: + '200': + $ref: '#/components/responses/ml.predict_model___200' + /_plugins/_ml/models/{model_id}/_predict/stream: + post: + operationId: ml.predict_model_stream.0 + x-operation-group: ml.predict_model_stream + x-version-added: '3.3' + description: Predicts a model in streaming mode. + parameters: + - $ref: '#/components/parameters/ml.predict_model_stream___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.predict_model_stream' + responses: + '200': + $ref: '#/components/responses/ml.predict_model_stream___200' + /_plugins/_ml/models/{model_id}/_undeploy: + post: + operationId: ml.undeploy_model.0 + x-operation-group: ml.undeploy_model + x-version-added: '2.7' + description: Undeploys a model. + parameters: + - $ref: '#/components/parameters/ml.undeploy_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.undeploy_model' + responses: + '200': + $ref: '#/components/responses/ml.undeploy_model___200' + /_plugins/_ml/models/{model_id}/_unload: + post: + operationId: ml.unload_model.0 + x-operation-group: ml.unload_model + deprecated: true + x-version-deprecated: '2.7' + x-deprecation-message: Use `undeploy_model` instead. + description: Unloads a model. + parameters: + - $ref: '#/components/parameters/ml.unload_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.unload_model' + responses: + '200': + $ref: '#/components/responses/ml.unload_model___200' + /_plugins/_ml/models/{model_id}/chunk/{chunk_number}: + post: + operationId: ml.chunk_model.0 + x-operation-group: ml.chunk_model + deprecated: true + x-version-deprecated: '2.7' + x-deprecation-message: Use `upload_chunk` instead. + description: Uploads model chunk. + parameters: + - $ref: '#/components/parameters/ml.chunk_model___path.chunk_number' + - $ref: '#/components/parameters/ml.chunk_model___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.chunk_model' + responses: + '200': + $ref: '#/components/responses/ml.chunk_model___200' + /_plugins/_ml/models/{model_id}/upload_chunk/{chunk_number}: + post: + operationId: ml.upload_chunk.0 + x-operation-group: ml.upload_chunk + x-version-added: '2.7' + description: Uploads model chunk. + parameters: + - $ref: '#/components/parameters/ml.upload_chunk___path.chunk_number' + - $ref: '#/components/parameters/ml.upload_chunk___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.upload_chunk' + responses: + '200': + $ref: '#/components/responses/ml.upload_chunk___200' + /_plugins/_ml/models/meta: + post: + operationId: ml.create_model_meta.0 + x-operation-group: ml.create_model_meta + deprecated: true + x-version-deprecated: '2.7' + x-deprecation-message: Use `_register_meta` instead. + description: Registers model metadata. + requestBody: + $ref: '#/components/requestBodies/ml.create_model_meta' + responses: + '200': + $ref: '#/components/responses/ml.create_model_meta___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/profile: + get: + operationId: ml.get_profile.0 + x-operation-group: ml.get_profile + x-version-added: '2.4' + description: Get a profile. + requestBody: + $ref: '#/components/requestBodies/ml.get_profile' + responses: + '200': + $ref: '#/components/responses/ml.get_profile___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/profile/models: + get: + operationId: ml.get_profile_models.0 + x-operation-group: ml.get_profile_models + x-version-added: '2.4' + description: Get a profile models. + requestBody: + $ref: '#/components/requestBodies/ml.get_profile_models' + responses: + '200': + $ref: '#/components/responses/ml.get_profile_models___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/profile/models/{model_id}: + get: + operationId: ml.get_profile_models.1 + x-operation-group: ml.get_profile_models + x-version-added: '2.11' + description: Get a profile models. + requestBody: + $ref: '#/components/requestBodies/ml.get_profile_models' + parameters: + - $ref: '#/components/parameters/ml.get_profile_models___path.model_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_profile_models___200' + /_plugins/_ml/profile/tasks: + get: + operationId: ml.get_profile_tasks.0 + x-operation-group: ml.get_profile_tasks + x-version-added: '2.4' + description: Get a profile tasks. + requestBody: + $ref: '#/components/requestBodies/ml.get_profile_tasks' + responses: + '200': + $ref: '#/components/responses/ml.get_profile_tasks___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/profile/tasks/{task_id}: + get: + operationId: ml.get_profile_tasks.1 + x-operation-group: ml.get_profile_tasks + x-version-added: '2.11' + description: Get a profile tasks. + requestBody: + $ref: '#/components/requestBodies/ml.get_profile_tasks' + parameters: + - $ref: '#/components/parameters/ml.get_profile_tasks___path.task_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_profile_tasks___200' + /_plugins/_ml/stats: + get: + operationId: ml.get_stats.0 + x-operation-group: ml.get_stats + x-version-added: '1.3' + description: Get stats. + responses: + '200': + $ref: '#/components/responses/ml.get_stats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/stats/{stat}: + get: + operationId: ml.get_stats.1 + x-operation-group: ml.get_stats + x-version-added: '1.3' + description: Get stats. + parameters: + - $ref: '#/components/parameters/ml.get_stats___path.stat' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_stats___200' + /_plugins/_ml/tasks/_search: + get: + operationId: ml.search_tasks.0 + x-operation-group: ml.search_tasks + x-version-added: '1.3' + description: Searches for tasks. + requestBody: + $ref: '#/components/requestBodies/ml.search_tasks' + responses: + '200': + $ref: '#/components/responses/ml.search_tasks___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: ml.search_tasks.1 + x-operation-group: ml.search_tasks + x-version-added: '1.3' + description: Searches for tasks. + requestBody: + $ref: '#/components/requestBodies/ml.search_tasks' + responses: + '200': + $ref: '#/components/responses/ml.search_tasks___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/tasks/{task_id}: + delete: + operationId: ml.delete_task.0 + x-operation-group: ml.delete_task + x-version-added: '1.3' + description: Deletes a task. + parameters: + - $ref: '#/components/parameters/ml.delete_task___path.task_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.delete_task___200' + get: + operationId: ml.get_task.0 + x-operation-group: ml.get_task + x-version-added: '1.3' + description: Retrieves a task. + parameters: + - $ref: '#/components/parameters/ml.get_task___path.task_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_task___200' + /_plugins/_ml/tools: + get: + operationId: ml.get_all_tools.0 + x-operation-group: ml.get_all_tools + x-version-added: '2.12' + description: Get tools. + responses: + '200': + $ref: '#/components/responses/ml.get_all_tools___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_ml/tools/_execute/{tool_name}: + post: + operationId: ml.execute_tool.0 + x-operation-group: ml.execute_tool + x-version-added: '3.3' + description: Execute a tool. + parameters: + - $ref: '#/components/parameters/ml.execute_tool___path.tool_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ml.execute_tool' + responses: + '200': + $ref: '#/components/responses/ml.execute_tool___200' + /_plugins/_ml/tools/{tool_name}: + get: + operationId: ml.get_tool.0 + x-operation-group: ml.get_tool + x-version-added: '2.12' + description: Get tools. + parameters: + - $ref: '#/components/parameters/ml.get_tool___path.tool_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ml.get_tool___200' + /_plugins/_neural/{node_id}/stats: + get: + operationId: neural.stats.2 + x-operation-group: neural.stats + x-version-added: '3.0' + description: Provides information about the current status of the neural-search plugin. + parameters: + - $ref: '#/components/parameters/neural.stats___path.node_id' + - $ref: '#/components/parameters/neural.stats___query.flat_stat_paths' + - $ref: '#/components/parameters/neural.stats___query.include_all_nodes' + - $ref: '#/components/parameters/neural.stats___query.include_individual_nodes' + - $ref: '#/components/parameters/neural.stats___query.include_info' + - $ref: '#/components/parameters/neural.stats___query.include_metadata' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/neural.stats___200' + /_plugins/_neural/{node_id}/stats/{stat}: + get: + operationId: neural.stats.3 + x-operation-group: neural.stats + x-version-added: '3.0' + description: Provides information about the current status of the neural-search plugin. + parameters: + - $ref: '#/components/parameters/neural.stats___path.node_id' + - $ref: '#/components/parameters/neural.stats___path.stat' + - $ref: '#/components/parameters/neural.stats___query.flat_stat_paths' + - $ref: '#/components/parameters/neural.stats___query.include_all_nodes' + - $ref: '#/components/parameters/neural.stats___query.include_individual_nodes' + - $ref: '#/components/parameters/neural.stats___query.include_info' + - $ref: '#/components/parameters/neural.stats___query.include_metadata' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/neural.stats___200' + /_plugins/_neural/stats: + get: + operationId: neural.stats.0 + x-operation-group: neural.stats + x-version-added: '3.0' + description: Provides information about the current status of the neural-search plugin. + parameters: + - $ref: '#/components/parameters/neural.stats___query.flat_stat_paths' + - $ref: '#/components/parameters/neural.stats___query.include_all_nodes' + - $ref: '#/components/parameters/neural.stats___query.include_individual_nodes' + - $ref: '#/components/parameters/neural.stats___query.include_info' + - $ref: '#/components/parameters/neural.stats___query.include_metadata' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/neural.stats___200' + /_plugins/_neural/stats/{stat}: + get: + operationId: neural.stats.1 + x-operation-group: neural.stats + x-version-added: '3.0' + description: Provides information about the current status of the neural-search plugin. + parameters: + - $ref: '#/components/parameters/neural.stats___path.stat' + - $ref: '#/components/parameters/neural.stats___query.flat_stat_paths' + - $ref: '#/components/parameters/neural.stats___query.include_all_nodes' + - $ref: '#/components/parameters/neural.stats___query.include_individual_nodes' + - $ref: '#/components/parameters/neural.stats___query.include_info' + - $ref: '#/components/parameters/neural.stats___query.include_metadata' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/neural.stats___200' + /_plugins/_notifications/channels: + get: + operationId: notifications.list_channels.0 + x-operation-group: notifications.list_channels + x-version-added: '2.0' + description: List created notification channels. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#list-all-notification-channels + responses: + '200': + $ref: '#/components/responses/notifications.list_channels___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_notifications/configs: + delete: + operationId: notifications.delete_configs.0 + x-operation-group: notifications.delete_configs + x-version-added: '2.2' + description: Delete multiple channel configurations. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#delete-channel-configuration + parameters: + - $ref: '#/components/parameters/notifications.delete_configs___query.config_id' + - $ref: '#/components/parameters/notifications.delete_configs___query.config_id_list' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/notifications.delete_configs___200' + get: + operationId: notifications.get_configs.0 + x-operation-group: notifications.get_configs + x-version-added: '2.0' + description: Get multiple channel configurations with filtering. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#list-all-notification-configurations + parameters: + - $ref: '#/components/parameters/notifications.get_configs___query.chime.url' + - $ref: '#/components/parameters/notifications.get_configs___query.chime.url.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.config_id' + - $ref: '#/components/parameters/notifications.get_configs___query.config_id_list' + - $ref: '#/components/parameters/notifications.get_configs___query.config_type' + - $ref: '#/components/parameters/notifications.get_configs___query.created_time_ms' + - $ref: '#/components/parameters/notifications.get_configs___query.description' + - $ref: '#/components/parameters/notifications.get_configs___query.description.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.email.email_account_id' + - $ref: '#/components/parameters/notifications.get_configs___query.email.email_group_id_list' + - $ref: '#/components/parameters/notifications.get_configs___query.email.recipient_list.recipient' + - $ref: '#/components/parameters/notifications.get_configs___query.email.recipient_list.recipient.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.email_group.recipient_list.recipient' + - $ref: '#/components/parameters/notifications.get_configs___query.email_group.recipient_list.recipient.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.is_enabled' + - $ref: '#/components/parameters/notifications.get_configs___query.last_updated_time_ms' + - $ref: '#/components/parameters/notifications.get_configs___query.microsoft_teams.url' + - $ref: '#/components/parameters/notifications.get_configs___query.microsoft_teams.url.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.name' + - $ref: '#/components/parameters/notifications.get_configs___query.name.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.query' + - $ref: '#/components/parameters/notifications.get_configs___query.ses_account.from_address' + - $ref: '#/components/parameters/notifications.get_configs___query.ses_account.from_address.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.ses_account.region' + - $ref: '#/components/parameters/notifications.get_configs___query.ses_account.role_arn' + - $ref: '#/components/parameters/notifications.get_configs___query.ses_account.role_arn.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.slack.url' + - $ref: '#/components/parameters/notifications.get_configs___query.slack.url.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.smtp_account.from_address' + - $ref: '#/components/parameters/notifications.get_configs___query.smtp_account.from_address.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.smtp_account.host' + - $ref: '#/components/parameters/notifications.get_configs___query.smtp_account.host.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.smtp_account.method' + - $ref: '#/components/parameters/notifications.get_configs___query.sns.role_arn' + - $ref: '#/components/parameters/notifications.get_configs___query.sns.role_arn.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.sns.topic_arn' + - $ref: '#/components/parameters/notifications.get_configs___query.sns.topic_arn.keyword' + - $ref: '#/components/parameters/notifications.get_configs___query.text_query' + - $ref: '#/components/parameters/notifications.get_configs___query.webhook.url' + - $ref: '#/components/parameters/notifications.get_configs___query.webhook.url.keyword' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/notifications.get_configs' + responses: + '200': + $ref: '#/components/responses/notifications.get_configs___200' + post: + operationId: notifications.create_config.0 + x-operation-group: notifications.create_config + x-version-added: '2.0' + description: Create channel configuration. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#create-channel-configuration + requestBody: + $ref: '#/components/requestBodies/notifications.create_config' + responses: + '200': + $ref: '#/components/responses/notifications.create_config___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_notifications/configs/{config_id}: + delete: + operationId: notifications.delete_config.0 + x-operation-group: notifications.delete_config + x-version-added: '2.0' + description: Delete a channel configuration. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#delete-channel-configuration + parameters: + - $ref: '#/components/parameters/notifications.delete_config___path.config_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/notifications.delete_config___200' + get: + operationId: notifications.get_config.0 + x-operation-group: notifications.get_config + x-version-added: '2.0' + description: Get a specific channel configuration. + parameters: + - $ref: '#/components/parameters/notifications.get_config___path.config_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/notifications.get_config___200' + put: + operationId: notifications.update_config.0 + x-operation-group: notifications.update_config + x-version-added: '2.0' + description: Update channel configuration. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#update-channel-configuration + parameters: + - $ref: '#/components/parameters/notifications.update_config___path.config_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/notifications.update_config' + responses: + '200': + $ref: '#/components/responses/notifications.update_config___200' + /_plugins/_notifications/feature/test/{config_id}: + get: + operationId: notifications.send_test.0 + x-operation-group: notifications.send_test + deprecated: true + x-deprecation-message: Use the POST method instead. + x-version-added: '2.0' + x-version-deprecated: '2.3' + description: Send a test notification. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#send-test-notification + parameters: + - $ref: '#/components/parameters/notifications.send_test___path.config_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/notifications.send_test___200' + post: + operationId: notifications.send_test.1 + x-operation-group: notifications.send_test + x-version-added: '2.0' + description: Send a test notification. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#send-test-notification + parameters: + - $ref: '#/components/parameters/notifications.send_test___path.config_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/notifications.send_test___200' + /_plugins/_notifications/features: + get: + operationId: notifications.list_features.0 + x-operation-group: notifications.list_features + x-version-added: '2.0' + description: List supported channel configurations. + externalDocs: + url: https://opensearch.org/docs/latest/observing-your-data/notifications/api/#list-supported-channel-configurations + responses: + '200': + $ref: '#/components/responses/notifications.list_features___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_observability/_local/stats: + get: + operationId: observability.get_localstats.0 + x-operation-group: observability.get_localstats + x-version-added: '2.5' + description: Retrieves local stats of all observability objects. + responses: + '200': + $ref: '#/components/responses/observability.get_localstats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_observability/object: + delete: + operationId: observability.delete_objects.0 + x-operation-group: observability.delete_objects + x-version-added: '1.1' + description: Deletes specific observability objects specified by ID or a list of IDs. + parameters: + - $ref: '#/components/parameters/observability.delete_objects___query.objectId' + - $ref: '#/components/parameters/observability.delete_objects___query.objectIdList' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/observability.delete_objects___200' + '404': + $ref: '#/components/responses/observability.delete_objects___404' + get: + operationId: observability.list_objects.0 + x-operation-group: observability.list_objects + x-version-added: '1.1' + description: Retrieves list of all observability objects. + responses: + '200': + $ref: '#/components/responses/observability.list_objects___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: observability.create_object.0 + x-operation-group: observability.create_object + x-version-added: '1.1' + description: Creates a new observability object. + requestBody: + $ref: '#/components/requestBodies/observability.create_object' + responses: + '200': + $ref: '#/components/responses/observability.create_object___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_observability/object/{object_id}: + delete: + operationId: observability.delete_object.0 + x-operation-group: observability.delete_object + x-version-added: '1.1' + description: Deletes specific observability object specified by ID. + parameters: + - $ref: '#/components/parameters/observability.delete_object___path.object_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/observability.delete_object___200' + '404': + $ref: '#/components/responses/observability.delete_object___404' + get: + operationId: observability.get_object.0 + x-operation-group: observability.get_object + x-version-added: '1.1' + description: Retrieves specific observability object specified by ID. + parameters: + - $ref: '#/components/parameters/observability.get_object___path.object_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/observability.get_object___200' + '404': + $ref: '#/components/responses/observability.get_object___404' + put: + operationId: observability.update_object.0 + x-operation-group: observability.update_object + x-version-added: '1.1' + description: Updates an existing observability object. + parameters: + - $ref: '#/components/parameters/observability.update_object___path.object_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/observability.update_object' + responses: + '200': + $ref: '#/components/responses/observability.update_object___200' + '404': + $ref: '#/components/responses/observability.update_object___404' + /_plugins/_ppl: + post: + operationId: ppl.query.0 + x-operation-group: ppl.query + x-version-added: '1.0' + description: Executes a PPL query against OpenSearch indexes. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/ppl.query___query.format' + - $ref: '#/components/parameters/ppl.query___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ppl.query' + responses: + '200': + $ref: '#/components/responses/ppl.query___200' + /_plugins/_ppl/_explain: + post: + operationId: ppl.explain.0 + x-operation-group: ppl.explain + x-version-added: '1.0' + description: Returns the execution plan for a PPL query. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/ppl.explain___query.format' + - $ref: '#/components/parameters/ppl.explain___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ppl.explain' + responses: + '200': + $ref: '#/components/responses/ppl.explain___200' + /_plugins/_ppl/stats: + get: + operationId: ppl.get_stats.0 + x-operation-group: ppl.get_stats + x-version-added: '1.0' + description: Retrieves performance metrics for the PPL plugin. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ + parameters: + - $ref: '#/components/parameters/ppl.get_stats___query.format' + - $ref: '#/components/parameters/ppl.get_stats___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ppl.get_stats___200' + post: + operationId: ppl.post_stats.1 + x-operation-group: ppl.post_stats + x-version-added: '1.0' + description: Retrieves filtered performance metrics for the PPL plugin. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ + parameters: + - $ref: '#/components/parameters/ppl.post_stats___query.format' + - $ref: '#/components/parameters/ppl.post_stats___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ppl.post_stats' + responses: + '200': + $ref: '#/components/responses/ppl.post_stats___200' + /_plugins/_query/_datasources: + get: + operationId: query.datasources_list.0 + x-operation-group: query.datasources_list + x-version-added: '2.7' + description: Retrieves a list of all available data sources. + responses: + '200': + $ref: '#/components/responses/query.datasources_list___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: query.datasources_create.0 + x-operation-group: query.datasources_create + x-version-added: '2.7' + description: Creates a new query data source. + requestBody: + $ref: '#/components/requestBodies/query.datasources_create' + responses: + '201': + $ref: '#/components/responses/query.datasources_create___201' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: query.datasources_update.0 + x-operation-group: query.datasources_update + x-version-added: '2.7' + description: Updates an existing query data source. + requestBody: + $ref: '#/components/requestBodies/query.datasources_update' + responses: + '200': + $ref: '#/components/responses/query.datasources_update___200' + '404': + $ref: '#/components/responses/query.datasources_update___404' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_query/_datasources/{datasource_name}: + delete: + operationId: query.datasource_delete.0 + x-operation-group: query.datasource_delete + x-version-added: '2.7' + description: Deletes a specific data source by name. + parameters: + - $ref: '#/components/parameters/query.datasource_delete___path.datasource_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '204': + $ref: '#/components/responses/query.datasource_delete___204' + '404': + $ref: '#/components/responses/query.datasource_delete___404' + get: + operationId: query.datasource_retrieve.0 + x-operation-group: query.datasource_retrieve + x-version-added: '2.7' + description: Retrieves a specific data source by name. + parameters: + - $ref: '#/components/parameters/query.datasource_retrieve___path.datasource_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/query.datasource_retrieve___200' + '404': + $ref: '#/components/responses/query.datasource_retrieve___404' + /_plugins/_query/settings: + put: + operationId: sql.settings.0 + x-operation-group: sql.settings + x-version-added: '1.0' + description: Updates SQL plugin settings in the OpenSearch cluster configuration. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/settings/ + parameters: + - $ref: '#/components/parameters/sql.settings___query.format' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.settings' + responses: + '200': + $ref: '#/components/responses/sql.settings___200' + /_plugins/_refresh_search_analyzers/{index}: + post: + operationId: ism.refresh_search_analyzers.0 + x-operation-group: ism.refresh_search_analyzers + description: Refreshes search analyzers in real time. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/refresh-analyzer/ + parameters: + - $ref: '#/components/parameters/ism.refresh_search_analyzers___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.refresh_search_analyzers___200' + /_plugins/_replication/_autofollow: + delete: + operationId: replication.delete_replication_rule.0 + x-operation-group: replication.delete_replication_rule + x-version-added: '1.1' + description: Deletes the specified replication rule. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#delete-replication-rule + requestBody: + $ref: '#/components/requestBodies/replication.delete_replication_rule' + responses: + '200': + $ref: '#/components/responses/replication.delete_replication_rule___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: replication.create_replication_rule.0 + x-operation-group: replication.create_replication_rule + x-version-added: '1.1' + description: Automatically starts the replication on indexes matching a specified pattern. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#create-replication-rule + requestBody: + $ref: '#/components/requestBodies/replication.create_replication_rule' + responses: + '200': + $ref: '#/components/responses/replication.create_replication_rule___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_replication/{index}/_pause: + post: + operationId: replication.pause.0 + x-operation-group: replication.pause + x-version-added: '1.1' + description: Pauses the replication of the leader index. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#pause-replication + parameters: + - $ref: '#/components/parameters/replication.pause___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/replication.pause' + responses: + '200': + $ref: '#/components/responses/replication.pause___200' + /_plugins/_replication/{index}/_resume: + post: + operationId: replication.resume.0 + x-operation-group: replication.resume + x-version-added: '1.1' + description: Resumes replication of the leader index. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#resume-replication + parameters: + - $ref: '#/components/parameters/replication.resume___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/replication.resume' + responses: + '200': + $ref: '#/components/responses/replication.resume___200' + /_plugins/_replication/{index}/_start: + put: + operationId: replication.start.0 + x-operation-group: replication.start + x-version-added: '1.1' + description: Initiates the replication of an index from the leader cluster to the follower cluster. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#start-replication + parameters: + - $ref: '#/components/parameters/replication.start___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/replication.start' + responses: + '200': + $ref: '#/components/responses/replication.start___200' + /_plugins/_replication/{index}/_status: + get: + operationId: replication.status.0 + x-operation-group: replication.status + x-version-added: '1.1' + description: Retrieves the the status of an index replication. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#get-replication-status + parameters: + - $ref: '#/components/parameters/replication.status___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/replication.status___200' + /_plugins/_replication/{index}/_stop: + post: + operationId: replication.stop.0 + x-operation-group: replication.stop + x-version-added: '1.1' + description: Terminates the replication and converts the follower index to a standard index. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#stop-replication + parameters: + - $ref: '#/components/parameters/replication.stop___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/replication.stop' + responses: + '200': + $ref: '#/components/responses/replication.stop___200' + /_plugins/_replication/{index}/_update: + put: + operationId: replication.update_settings.0 + x-operation-group: replication.update_settings + x-version-added: '1.1' + description: Updates any settings on the follower index. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#update-settings + parameters: + - $ref: '#/components/parameters/replication.update_settings___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/replication.update_settings' + responses: + '200': + $ref: '#/components/responses/replication.update_settings___200' + /_plugins/_replication/autofollow_stats: + get: + operationId: replication.autofollow_stats.0 + x-operation-group: replication.autofollow_stats + x-version-added: '1.1' + description: Retrieves information about any auto-follow activity and any replication rules configured on the specified cluster. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#get-auto-follow-stats + responses: + '200': + $ref: '#/components/responses/replication.autofollow_stats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_replication/follower_stats: + get: + operationId: replication.follower_stats.0 + x-operation-group: replication.follower_stats + x-version-added: '1.1' + description: Retrieves information about any follower (syncing) indexes on a specified cluster. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#get-follower-cluster-stats + responses: + '200': + $ref: '#/components/responses/replication.follower_stats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_replication/leader_stats: + get: + operationId: replication.leader_stats.0 + x-operation-group: replication.leader_stats + x-version-added: '1.1' + description: Retrieves information about any replicated leader indexes on a specified cluster. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/replication-plugin/api/#get-leader-cluster-stats + responses: + '200': + $ref: '#/components/responses/replication.leader_stats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_rollup/jobs/{id}: + delete: + operationId: rollups.delete.0 + x-operation-group: rollups.delete + x-version-added: '1.0' + description: Deletes an index rollup job configuration. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#delete-an-index-rollup-job + responses: + '200': + $ref: '#/components/responses/rollups.delete___200' + parameters: + - $ref: '#/components/parameters/rollups.delete___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + get: + operationId: rollups.get.0 + x-operation-group: rollups.get + x-version-added: '1.0' + description: Retrieves an index rollup job configuration by ID. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#get-an-index-rollup-job + parameters: + - $ref: '#/components/parameters/rollups.get___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/rollups.get___200' + put: + operationId: rollups.put.0 + x-operation-group: rollups.put + x-version-added: '1.0' + description: Creates or updates an index rollup job configuration. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#create-or-update-an-index-rollup-job + responses: + '201': + $ref: '#/components/responses/rollups.put___201' + parameters: + - $ref: '#/components/parameters/rollups.put___path.id' + - $ref: '#/components/parameters/rollups.put___query.if_primary_term' + - $ref: '#/components/parameters/rollups.put___query.if_seq_no' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/rollups.put' + /_plugins/_rollup/jobs/{id}/_explain: + get: + operationId: rollups.explain.0 + x-operation-group: rollups.explain + x-version-added: '1.0' + description: Retrieves the execution status information for an index rollup job. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#explain-an-index-rollup-job + parameters: + - $ref: '#/components/parameters/rollups.explain___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/rollups.explain___200' + /_plugins/_rollup/jobs/{id}/_start: + post: + operationId: rollups.start.0 + x-operation-group: rollups.start + x-version-added: '1.0' + description: Starts the execution of an index rollup job. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#start-or-stop-an-index-rollup-job + parameters: + - $ref: '#/components/parameters/rollups.start___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/rollups.start___200' + /_plugins/_rollup/jobs/{id}/_stop: + post: + operationId: rollups.stop.0 + x-operation-group: rollups.stop + x-version-added: '1.0' + description: Stops the execution of an index rollup job. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#start-or-stop-an-index-rollup-job + parameters: + - $ref: '#/components/parameters/rollups.stop___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/rollups.stop___200' + /_plugins/_search_relevance/{node_id}/stats: + get: + operationId: search_relevance.get_node_stats.0 + x-operation-group: search_relevance.get_node_stats + x-version-added: '3.1' + description: Gets stats by node. + parameters: + - $ref: '#/components/parameters/search_relevance.get_node_stats___path.node_id' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.flat_stat_paths' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.include_all_nodes' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.include_individual_nodes' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.include_info' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.include_metadata' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_node_stats___200' + /_plugins/_search_relevance/{node_id}/stats/{stat}: + get: + operationId: search_relevance.get_node_stats.1 + x-operation-group: search_relevance.get_node_stats + x-version-added: '3.1' + description: Gets stats by node. + parameters: + - $ref: '#/components/parameters/search_relevance.get_node_stats___path.node_id' + - $ref: '#/components/parameters/search_relevance.get_node_stats___path.stat' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.flat_stat_paths' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.include_all_nodes' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.include_individual_nodes' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.include_info' + - $ref: '#/components/parameters/search_relevance.get_node_stats___query.include_metadata' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_node_stats___200' + /_plugins/_search_relevance/experiments: + get: + operationId: search_relevance.get_experiments.0 + x-operation-group: search_relevance.get_experiments + x-version-added: '3.1' + description: Gets experiments. + responses: + '200': + $ref: '#/components/responses/search_relevance.get_experiments___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: search_relevance.put_experiments.0 + x-operation-group: search_relevance.put_experiments + x-version-added: '3.1' + description: Creates an experiment. + requestBody: + $ref: '#/components/requestBodies/search_relevance.put_experiments' + responses: + '200': + $ref: '#/components/responses/search_relevance.put_experiments___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_search_relevance/experiments/{experiment_id}: + delete: + operationId: search_relevance.delete_experiments.0 + x-operation-group: search_relevance.delete_experiments + x-version-added: '3.1' + description: Deletes a specified experiment. + parameters: + - $ref: '#/components/parameters/search_relevance.delete_experiments___path.experiment_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.delete_experiments___200' + get: + operationId: search_relevance.get_experiments.1 + x-operation-group: search_relevance.get_experiments + x-version-added: '3.1' + description: Gets experiments. + parameters: + - $ref: '#/components/parameters/search_relevance.get_experiments___path.experiment_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_experiments___200' + /_plugins/_search_relevance/experiments/schedule: + get: + operationId: search_relevance.get_scheduled_experiments.0 + x-operation-group: search_relevance.get_scheduled_experiments + x-version-added: '3.4' + description: Gets the scheduled experiments. + responses: + '200': + $ref: '#/components/responses/search_relevance.get_scheduled_experiments___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: search_relevance.post_scheduled_experiments.0 + x-operation-group: search_relevance.post_scheduled_experiments + x-version-added: '3.4' + description: Creates a scheduled experiment. + requestBody: + $ref: '#/components/requestBodies/search_relevance.post_scheduled_experiments' + responses: + '200': + $ref: '#/components/responses/search_relevance.post_scheduled_experiments___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_search_relevance/experiments/schedule/{experiment_id}: + delete: + operationId: search_relevance.delete_scheduled_experiments.0 + x-operation-group: search_relevance.delete_scheduled_experiments + x-version-added: '3.4' + description: Deletes a specified scheduled experiment. + parameters: + - $ref: '#/components/parameters/search_relevance.delete_scheduled_experiments___path.experiment_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.delete_scheduled_experiments___200' + get: + operationId: search_relevance.get_scheduled_experiments.1 + x-operation-group: search_relevance.get_scheduled_experiments + x-version-added: '3.4' + description: Gets the scheduled experiments. + parameters: + - $ref: '#/components/parameters/search_relevance.get_scheduled_experiments___path.experiment_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_scheduled_experiments___200' + /_plugins/_search_relevance/judgments: + get: + operationId: search_relevance.get_judgments.0 + x-operation-group: search_relevance.get_judgments + x-version-added: '3.1' + description: Gets judgments. + responses: + '200': + $ref: '#/components/responses/search_relevance.get_judgments___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: search_relevance.put_judgments.0 + x-operation-group: search_relevance.put_judgments + x-version-added: '3.1' + description: Creates a judgment. + requestBody: + description: The request body of the judgment to be created. + $ref: '#/components/requestBodies/search_relevance.put_judgments' + responses: + '200': + $ref: '#/components/responses/search_relevance.put_judgments___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_search_relevance/judgments/{judgment_id}: + delete: + operationId: search_relevance.delete_judgments.0 + x-operation-group: search_relevance.delete_judgments + x-version-added: '3.1' + description: Deletes a specified judgment. + parameters: + - $ref: '#/components/parameters/search_relevance.delete_judgments___path.judgment_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.delete_judgments___200' + get: + operationId: search_relevance.get_judgments.1 + x-operation-group: search_relevance.get_judgments + x-version-added: '3.1' + description: Gets judgments. + parameters: + - $ref: '#/components/parameters/search_relevance.get_judgments___path.judgment_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_judgments___200' + /_plugins/_search_relevance/query_sets: + get: + operationId: search_relevance.get_query_sets.0 + x-operation-group: search_relevance.get_query_sets + x-version-added: '3.1' + description: Lists the current query sets available. + responses: + '200': + $ref: '#/components/responses/search_relevance.get_query_sets___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: search_relevance.post_query_sets.0 + x-operation-group: search_relevance.post_query_sets + x-version-added: '3.1' + description: Creates a new query set by sampling queries from the user behavior data. + requestBody: + $ref: '#/components/requestBodies/search_relevance.post_query_sets' + responses: + '200': + $ref: '#/components/responses/search_relevance.post_query_sets___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: search_relevance.put_query_sets.0 + x-operation-group: search_relevance.put_query_sets + x-version-added: '3.1' + description: Creates a new query set by uploading manually. + requestBody: + $ref: '#/components/requestBodies/search_relevance.put_query_sets' + responses: + '200': + $ref: '#/components/responses/search_relevance.put_query_sets___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_search_relevance/query_sets/{query_set_id}: + delete: + operationId: search_relevance.delete_query_sets.0 + x-operation-group: search_relevance.delete_query_sets + x-version-added: '3.1' + description: Deletes a query set. + parameters: + - $ref: '#/components/parameters/search_relevance.delete_query_sets___path.query_set_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.delete_query_sets___200' + get: + operationId: search_relevance.get_query_sets.1 + x-operation-group: search_relevance.get_query_sets + x-version-added: '3.1' + description: Lists the current query sets available. + parameters: + - $ref: '#/components/parameters/search_relevance.get_query_sets___path.query_set_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_query_sets___200' + /_plugins/_search_relevance/search_configurations: + get: + operationId: search_relevance.get_search_configurations.0 + x-operation-group: search_relevance.get_search_configurations + x-version-added: '3.1' + description: Gets the search configurations. + responses: + '200': + $ref: '#/components/responses/search_relevance.get_search_configurations___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: search_relevance.put_search_configurations.0 + x-operation-group: search_relevance.put_search_configurations + x-version-added: '3.1' + description: Creates a search configuration. + requestBody: + $ref: '#/components/requestBodies/search_relevance.put_search_configurations' + responses: + '200': + $ref: '#/components/responses/search_relevance.put_search_configurations___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_search_relevance/search_configurations/{search_configuration_id}: + delete: + operationId: search_relevance.delete_search_configurations.0 + x-operation-group: search_relevance.delete_search_configurations + x-version-added: '3.1' + description: Deletes a specified search configuration. + parameters: + - $ref: '#/components/parameters/search_relevance.delete_search_configurations___path.search_configuration_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.delete_search_configurations___200' + get: + operationId: search_relevance.get_search_configurations.1 + x-operation-group: search_relevance.get_search_configurations + x-version-added: '3.1' + description: Gets the search configurations. + parameters: + - $ref: '#/components/parameters/search_relevance.get_search_configurations___path.search_configuration_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_search_configurations___200' + /_plugins/_search_relevance/stats: + get: + operationId: search_relevance.get_stats.0 + x-operation-group: search_relevance.get_stats + x-version-added: '3.1' + description: Gets stats. + parameters: + - $ref: '#/components/parameters/search_relevance.get_stats___query.flat_stat_paths' + - $ref: '#/components/parameters/search_relevance.get_stats___query.include_all_nodes' + - $ref: '#/components/parameters/search_relevance.get_stats___query.include_individual_nodes' + - $ref: '#/components/parameters/search_relevance.get_stats___query.include_info' + - $ref: '#/components/parameters/search_relevance.get_stats___query.include_metadata' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_stats___200' + /_plugins/_search_relevance/stats/{stat}: + get: + operationId: search_relevance.get_stats.1 + x-operation-group: search_relevance.get_stats + x-version-added: '3.1' + description: Gets stats. + parameters: + - $ref: '#/components/parameters/search_relevance.get_stats___path.stat' + - $ref: '#/components/parameters/search_relevance.get_stats___query.flat_stat_paths' + - $ref: '#/components/parameters/search_relevance.get_stats___query.include_all_nodes' + - $ref: '#/components/parameters/search_relevance.get_stats___query.include_individual_nodes' + - $ref: '#/components/parameters/search_relevance.get_stats___query.include_info' + - $ref: '#/components/parameters/search_relevance.get_stats___query.include_metadata' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_relevance.get_stats___200' + /_plugins/_security_analytics/alerts: + get: + operationId: security_analytics.get_alerts.0 + x-operation-group: security_analytics.get_alerts + x-version-added: '2.4' + description: Retrieve alerts related to a specific detector type or detector ID. + externalDocs: + url: https://docs.opensearch.org/docs/latest/security-analytics/api-tools/alert-finding-api/#get-alerts + parameters: + - $ref: '#/components/parameters/security_analytics.get_alerts___query.alertState' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.detectorType' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.detector_id' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.endTime' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.missing' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.searchString' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.severityLevel' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.size' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.sortOrder' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.sortString' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.startIndex' + - $ref: '#/components/parameters/security_analytics.get_alerts___query.startTime' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security_analytics.get_alerts___200' + /_plugins/_security_analytics/findings/_search: + get: + operationId: security_analytics.get_findings.0 + x-operation-group: security_analytics.get_findings + x-version-added: '2.4' + description: Retrieve findings related to a specific detector type or detector ID. + externalDocs: + url: https://docs.opensearch.org/docs/latest/security-analytics/api-tools/alert-finding-api/#get-findings + parameters: + - $ref: '#/components/parameters/security_analytics.get_findings___query.detectionType' + - $ref: '#/components/parameters/security_analytics.get_findings___query.detectorType' + - $ref: '#/components/parameters/security_analytics.get_findings___query.detector_id' + - $ref: '#/components/parameters/security_analytics.get_findings___query.endTime' + - $ref: '#/components/parameters/security_analytics.get_findings___query.findingIds' + - $ref: '#/components/parameters/security_analytics.get_findings___query.missing' + - $ref: '#/components/parameters/security_analytics.get_findings___query.searchString' + - $ref: '#/components/parameters/security_analytics.get_findings___query.severity' + - $ref: '#/components/parameters/security_analytics.get_findings___query.size' + - $ref: '#/components/parameters/security_analytics.get_findings___query.sortOrder' + - $ref: '#/components/parameters/security_analytics.get_findings___query.sortString' + - $ref: '#/components/parameters/security_analytics.get_findings___query.startIndex' + - $ref: '#/components/parameters/security_analytics.get_findings___query.startTime' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security_analytics.get_findings___200' + /_plugins/_security_analytics/findings/correlate: + get: + operationId: security_analytics.search_finding_correlations.0 + x-operation-group: security_analytics.search_finding_correlations + x-version-added: '2.7' + description: List correlations for a finding. + externalDocs: + url: https://docs.opensearch.org/docs/latest/security-analytics/api-tools/correlation-eng/#list-correlations-for-a-finding-belonging-to-a-log-type + parameters: + - $ref: '#/components/parameters/security_analytics.search_finding_correlations___query.detector_type' + - $ref: '#/components/parameters/security_analytics.search_finding_correlations___query.finding' + - $ref: '#/components/parameters/security_analytics.search_finding_correlations___query.nearby_findings' + - $ref: '#/components/parameters/security_analytics.search_finding_correlations___query.time_window' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security_analytics.search_finding_correlations___200' + /_plugins/_security/api/_upgrade_check: + get: + operationId: security.config_upgrade_check.0 + x-operation-group: security.config_upgrade_check + x-version-added: '2.14' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Checks whether or not an upgrade can be performed and which security resources can be updated. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#configuration-upgrade-check + responses: + '200': + $ref: '#/components/responses/security.config_upgrade_check___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/_upgrade_perform: + post: + operationId: security.config_upgrade_perform.0 + x-operation-group: security.config_upgrade_perform + x-version-added: '2.14' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Assists the cluster operator with upgrading missing default values and stale default definitions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#configuration-upgrade + requestBody: + $ref: '#/components/requestBodies/security.config_upgrade_perform' + responses: + '200': + $ref: '#/components/responses/security.config_upgrade_perform___200' + '400': + $ref: '#/components/responses/security.config_upgrade_perform___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/account: + get: + operationId: security.get_account_details.0 + x-operation-group: security.get_account_details + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns account information for the current user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-account-details + responses: + '200': + $ref: '#/components/responses/security.get_account_details___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: security.change_password.0 + x-operation-group: security.change_password + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Changes the password for the current user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#change-password + requestBody: + $ref: '#/components/requestBodies/security.change_password' + responses: + '200': + $ref: '#/components/responses/security.change_password___200' + '403': + $ref: '#/components/responses/security.change_password___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/actiongroups: + get: + operationId: security.get_action_groups.0 + x-operation-group: security.get_action_groups + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves all action groups. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-action-groups + responses: + '200': + $ref: '#/components/responses/security.get_action_groups___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + patch: + operationId: security.patch_action_groups.1 + x-operation-group: security.patch_action_groups + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates, updates, or deletes multiple action groups in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-action-groups + requestBody: + $ref: '#/components/requestBodies/security.patch_action_groups' + responses: + '200': + $ref: '#/components/responses/security.patch_action_groups___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/actiongroups/{action_group}: + delete: + operationId: security.delete_action_group.0 + x-operation-group: security.delete_action_group + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified action group. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-action-group + parameters: + - $ref: '#/components/parameters/security.delete_action_group___path.action_group' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_action_group___200' + get: + operationId: security.get_action_group.0 + x-operation-group: security.get_action_group + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves one action group. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-action-group + parameters: + - $ref: '#/components/parameters/security.get_action_group___path.action_group' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_action_group___200' + patch: + operationId: security.patch_action_group.0 + x-operation-group: security.patch_action_group + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the individual attributes of an action group. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-action-group + parameters: + - $ref: '#/components/parameters/security.patch_action_group___path.action_group' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_action_group' + responses: + '200': + $ref: '#/components/responses/security.patch_action_group___200' + put: + operationId: security.create_action_group.0 + x-operation-group: security.create_action_group + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified action group. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-action-group + parameters: + - $ref: '#/components/parameters/security.create_action_group___path.action_group' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_action_group' + responses: + '200': + $ref: '#/components/responses/security.create_action_group___200' + '201': + $ref: '#/components/responses/security.create_action_group___201' + /_plugins/_security/api/allowlist: + get: + operationId: security.get_allowlist.0 + x-operation-group: security.get_allowlist + x-version-added: '2.1' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the current list of allowed APIs accessible to a normal user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api + responses: + '200': + $ref: '#/components/responses/security.get_allowlist___200' + '403': + $ref: '#/components/responses/security.get_allowlist___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + patch: + operationId: security.patch_allowlist.0 + x-operation-group: security.patch_allowlist + x-version-added: '2.1' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the current list of APIs accessible for users on the allow list. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api + requestBody: + $ref: '#/components/requestBodies/security.patch_allowlist' + responses: + '200': + $ref: '#/components/responses/security.patch_allowlist___200' + '403': + $ref: '#/components/responses/security.patch_allowlist___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: security.create_allowlist.0 + x-operation-group: security.create_allowlist + x-version-added: '2.1' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces APIs permitted for users on the allow list. Requires a super admin certificate or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api + requestBody: + $ref: '#/components/requestBodies/security.create_allowlist' + responses: + '200': + $ref: '#/components/responses/security.create_allowlist___200' + '403': + $ref: '#/components/responses/security.create_allowlist___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/audit: + get: + operationId: security.get_audit_configuration.0 + x-operation-group: security.get_audit_configuration + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the audit configuration. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#audit-logs + responses: + '200': + $ref: '#/components/responses/security.get_audit_configuration___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + patch: + operationId: security.patch_audit_configuration.0 + x-operation-group: security.patch_audit_configuration + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the specified fields in the audit configuration. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#audit-logs + requestBody: + $ref: '#/components/requestBodies/security.patch_audit_configuration' + responses: + '200': + $ref: '#/components/responses/security.patch_audit_configuration___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/audit/config: + put: + operationId: security.update_audit_configuration.0 + x-operation-group: security.update_audit_configuration + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the audit configuration. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#audit-logs + requestBody: + $ref: '#/components/requestBodies/security.update_audit_configuration' + responses: + '200': + $ref: '#/components/responses/security.update_audit_configuration___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/authtoken: + post: + operationId: security.authtoken.0 + x-operation-group: security.authtoken + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns the authorization token for the current user. + responses: + '200': + $ref: '#/components/responses/security.authtoken___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/cache: + delete: + operationId: security.flush_cache.0 + x-operation-group: security.flush_cache + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Flushes the Security plugin's user, authentication, and authorization cache. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#flush-cache + responses: + '200': + $ref: '#/components/responses/security.flush_cache___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + get: + operationId: security.cache.1 + x-operation-group: security.cache + x-ignorable: true + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Not supported for the Cache API. + responses: + '405': + $ref: '#/components/responses/security.cache___405' + '501': + $ref: '#/components/responses/security.cache___501' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: security.cache.2 + x-operation-group: security.cache + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + x-ignorable: true + description: Not supported for the Cache API. + responses: + '405': + $ref: '#/components/responses/security.cache___405' + '501': + $ref: '#/components/responses/security.cache___501' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: security.cache.3 + x-operation-group: security.cache + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + x-ignorable: true + description: Not supported for the Cache API. + responses: + '405': + $ref: '#/components/responses/security.cache___405' + '501': + $ref: '#/components/responses/security.cache___501' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/certificates: + get: + operationId: security.get_all_certificates.0 + x-operation-group: security.get_all_certificates + x-version-added: '2.15' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the cluster security certificates. + parameters: + - $ref: '#/components/parameters/security.get_all_certificates___query.cert_type' + - $ref: '#/components/parameters/security.get_all_certificates___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_all_certificates___200' + '403': + $ref: '#/components/responses/security.get_all_certificates___403' + '500': + $ref: '#/components/responses/security.get_all_certificates___500' + /_plugins/_security/api/certificates/{node_id}: + get: + operationId: security.get_node_certificates.0 + x-operation-group: security.get_node_certificates + x-version-added: '2.15' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the specified node's security certificates. + parameters: + - $ref: '#/components/parameters/security.get_node_certificates___path.node_id' + - $ref: '#/components/parameters/security.get_node_certificates___query.cert_type' + - $ref: '#/components/parameters/security.get_node_certificates___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_node_certificates___200' + '403': + $ref: '#/components/responses/security.get_node_certificates___403' + '500': + $ref: '#/components/responses/security.get_node_certificates___500' + /_plugins/_security/api/generateonbehalfoftoken: + post: + operationId: security.generate_obo_token.0 + x-operation-group: security.generate_obo_token + x-version-added: '2.12' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Generates a `On-Behalf-Of` token for the current user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/authentication-tokens/#api-endpoint + requestBody: + $ref: '#/components/requestBodies/security.generate_obo_token' + responses: + '200': + $ref: '#/components/responses/security.generate_obo_token___200' + '400': + $ref: '#/components/responses/security.generate_obo_token___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/internalusers: + get: + operationId: security.get_users.0 + x-operation-group: security.get_users + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieve all internal users. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-users + responses: + '200': + $ref: '#/components/responses/security.get_users___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + patch: + operationId: security.patch_users.0 + x-operation-group: security.patch_users + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates, updates, or deletes multiple internal users in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-users + requestBody: + $ref: '#/components/requestBodies/security.patch_users' + responses: + '200': + $ref: '#/components/responses/security.patch_users___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/internalusers/{username}: + delete: + operationId: security.delete_user.0 + x-operation-group: security.delete_user + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified internal user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-user + parameters: + - $ref: '#/components/parameters/security.delete_user___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_user___200' + get: + operationId: security.get_user.0 + x-operation-group: security.get_user + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieve information about the specified internal user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-user + parameters: + - $ref: '#/components/parameters/security.get_user___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_user___200' + patch: + operationId: security.patch_user.0 + x-operation-group: security.patch_user + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates individual attributes for an internal user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-user + parameters: + - $ref: '#/components/parameters/security.patch_user___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_user' + responses: + '200': + $ref: '#/components/responses/security.patch_user___200' + put: + operationId: security.create_user.0 + x-operation-group: security.create_user + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-user + parameters: + - $ref: '#/components/parameters/security.create_user___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_user' + responses: + '200': + $ref: '#/components/responses/security.create_user___200' + '201': + $ref: '#/components/responses/security.create_user___201' + /_plugins/_security/api/internalusers/{username}/authtoken: + post: + operationId: security.generate_user_token.0 + x-operation-group: security.generate_user_token + x-version-added: '2.7' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Generates an authorization token for the specified user. + parameters: + - $ref: '#/components/parameters/security.generate_user_token___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.generate_user_token___200' + '400': + $ref: '#/components/responses/security.generate_user_token___400' + /_plugins/_security/api/migrate: + post: + operationId: security.migrate.0 + x-operation-group: security.migrate + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Migrates the security configuration from v6 to v7. + responses: + '200': + $ref: '#/components/responses/security.migrate___200' + '400': + $ref: '#/components/responses/security.migrate___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/nodesdn: + get: + operationId: security.get_distinguished_names.0 + x-operation-group: security.get_distinguished_names + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves all node distinguished names. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-distinguished-names + parameters: + - $ref: '#/components/parameters/security.get_distinguished_names___query.show_all' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_distinguished_names___200' + '400': + $ref: '#/components/responses/security.get_distinguished_names___400' + '403': + $ref: '#/components/responses/security.get_distinguished_names___403' + patch: + operationId: security.patch_distinguished_names.0 + x-operation-group: security.patch_distinguished_names + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Bulk updates specified node distinguished names. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#update-all-distinguished-names + requestBody: + $ref: '#/components/requestBodies/security.patch_distinguished_names' + responses: + '200': + $ref: '#/components/responses/security.patch_distinguished_names___200' + '400': + $ref: '#/components/responses/security.patch_distinguished_names___400' + '403': + $ref: '#/components/responses/security.patch_distinguished_names___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/nodesdn/{cluster_name}: + delete: + operationId: security.delete_distinguished_name.0 + x-operation-group: security.delete_distinguished_name + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes all distinguished names in the specified cluster or node allowlist. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-distinguished-names + parameters: + - $ref: '#/components/parameters/security.delete_distinguished_name___path.cluster_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_distinguished_name___200' + '400': + $ref: '#/components/responses/security.delete_distinguished_name___400' + '403': + $ref: '#/components/responses/security.delete_distinguished_name___403' + get: + operationId: security.get_distinguished_name.0 + x-operation-group: security.get_distinguished_name + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves all node distinguished names. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-distinguished-names + parameters: + - $ref: '#/components/parameters/security.get_distinguished_name___path.cluster_name' + - $ref: '#/components/parameters/security.get_distinguished_name___query.show_all' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_distinguished_name___200' + '400': + $ref: '#/components/responses/security.get_distinguished_name___400' + '403': + $ref: '#/components/responses/security.get_distinguished_name___403' + patch: + operationId: security.patch_distinguished_name.0 + x-operation-group: security.patch_distinguished_name + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the distinguished cluster name for the specified cluster. Requires super admin or REST API permissions. + parameters: + - $ref: '#/components/parameters/security.patch_distinguished_name___path.cluster_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_distinguished_name' + responses: + '200': + $ref: '#/components/responses/security.patch_distinguished_name___200' + '400': + $ref: '#/components/responses/security.patch_distinguished_name___400' + '403': + $ref: '#/components/responses/security.patch_distinguished_name___403' + put: + operationId: security.update_distinguished_name.0 + x-operation-group: security.update_distinguished_name + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Adds or updates the specified distinguished names in the cluster or node allowlist. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#update-distinguished-names + parameters: + - $ref: '#/components/parameters/security.update_distinguished_name___path.cluster_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.update_distinguished_name' + responses: + '200': + $ref: '#/components/responses/security.update_distinguished_name___200' + '201': + $ref: '#/components/responses/security.update_distinguished_name___201' + '400': + $ref: '#/components/responses/security.update_distinguished_name___400' + '403': + $ref: '#/components/responses/security.update_distinguished_name___403' + /_plugins/_security/api/permissionsinfo: + get: + operationId: security.get_permissions_info.0 + x-operation-group: security.get_permissions_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the evaluated REST API permissions for the currently logged in user. + responses: + '200': + $ref: '#/components/responses/security.get_permissions_info___200' + '500': + $ref: '#/components/responses/security.get_permissions_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/roles: + get: + operationId: security.get_roles.0 + x-operation-group: security.get_roles + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves all roles. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-roles + responses: + '200': + $ref: '#/components/responses/security.get_roles___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + patch: + operationId: security.patch_roles.0 + x-operation-group: security.patch_roles + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates, updates, or deletes multiple roles in a single call. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-roles + requestBody: + $ref: '#/components/requestBodies/security.patch_roles' + responses: + '200': + $ref: '#/components/responses/security.patch_roles___200' + '400': + $ref: '#/components/responses/security.patch_roles___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/roles/{role}: + delete: + operationId: security.delete_role.0 + x-operation-group: security.delete_role + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified role. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-role + parameters: + - $ref: '#/components/parameters/security.delete_role___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_role___200' + get: + operationId: security.get_role.0 + x-operation-group: security.get_role + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves one role. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-role + parameters: + - $ref: '#/components/parameters/security.get_role___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_role___200' + patch: + operationId: security.patch_role.0 + x-operation-group: security.patch_role + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the individual attributes of a role. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-role + parameters: + - $ref: '#/components/parameters/security.patch_role___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_role' + responses: + '200': + $ref: '#/components/responses/security.patch_role___200' + '400': + $ref: '#/components/responses/security.patch_role___400' + put: + operationId: security.create_role.0 + x-operation-group: security.create_role + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified role. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-role + parameters: + - $ref: '#/components/parameters/security.create_role___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_role' + responses: + '200': + $ref: '#/components/responses/security.create_role___200' + '201': + $ref: '#/components/responses/security.create_role___201' + /_plugins/_security/api/rolesmapping: + get: + operationId: security.get_role_mappings.0 + x-operation-group: security.get_role_mappings + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves all role mappings. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-role-mappings + responses: + '200': + $ref: '#/components/responses/security.get_role_mappings___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + patch: + operationId: security.patch_role_mappings.0 + x-operation-group: security.patch_role_mappings + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or updates multiple role mappings in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-role-mappings + requestBody: + $ref: '#/components/requestBodies/security.patch_role_mappings' + responses: + '200': + $ref: '#/components/responses/security.patch_role_mappings___200' + '400': + $ref: '#/components/responses/security.patch_role_mappings___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/rolesmapping/{role}: + delete: + operationId: security.delete_role_mapping.0 + x-operation-group: security.delete_role_mapping + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified role mapping. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-role-mapping + parameters: + - $ref: '#/components/parameters/security.delete_role_mapping___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_role_mapping___200' + get: + operationId: security.get_role_mapping.0 + x-operation-group: security.get_role_mapping + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the specified role mapping. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-role-mapping + parameters: + - $ref: '#/components/parameters/security.get_role_mapping___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_role_mapping___200' + patch: + operationId: security.patch_role_mapping.0 + x-operation-group: security.patch_role_mapping + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the individual attributes of a role mapping. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-role-mapping + parameters: + - $ref: '#/components/parameters/security.patch_role_mapping___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_role_mapping' + responses: + '200': + $ref: '#/components/responses/security.patch_role_mapping___200' + '400': + $ref: '#/components/responses/security.patch_role_mapping___400' + put: + operationId: security.create_role_mapping.0 + x-operation-group: security.create_role_mapping + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified role mapping. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-role-mapping + parameters: + - $ref: '#/components/parameters/security.create_role_mapping___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_role_mapping' + responses: + '200': + $ref: '#/components/responses/security.create_role_mapping___200' + '201': + $ref: '#/components/responses/security.create_role_mapping___201' + /_plugins/_security/api/securityconfig: + get: + operationId: security.get_configuration.0 + x-operation-group: security.get_configuration + x-version-added: '2.10' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns the current Security plugin configuration in a JSON format. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-configuration + responses: + '200': + $ref: '#/components/responses/security.get_configuration___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + patch: + operationId: security.patch_configuration.0 + x-operation-group: security.patch_configuration + x-version-added: '2.10' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the existing security configuration using the REST API. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-configuration + requestBody: + $ref: '#/components/requestBodies/security.patch_configuration' + responses: + '200': + $ref: '#/components/responses/security.patch_configuration___200' + '403': + $ref: '#/components/responses/security.patch_configuration___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/securityconfig/config: + put: + operationId: security.update_configuration.0 + x-operation-group: security.update_configuration + x-version-added: '2.10' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the settings for an existing security configuration. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#update-configuration + requestBody: + $ref: '#/components/requestBodies/security.update_configuration' + responses: + '200': + $ref: '#/components/responses/security.update_configuration___200' + '403': + $ref: '#/components/responses/security.update_configuration___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/ssl/certs: + get: + operationId: security.get_certificates.0 + x-operation-group: security.get_certificates + x-version-added: '2.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the cluster security certificates. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-certificates + responses: + '200': + $ref: '#/components/responses/security.get_certificates___200' + '400': + $ref: '#/components/responses/security.get_certificates___400' + '403': + $ref: '#/components/responses/security.get_certificates___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/ssl/http/reloadcerts: + put: + operationId: security.reload_http_certificates.0 + x-operation-group: security.reload_http_certificates + x-version-added: '2.8' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Reloads the HTTP communication certificates. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#reload-http-certificates + responses: + '200': + $ref: '#/components/responses/security.reload_http_certificates___200' + '400': + $ref: '#/components/responses/security.reload_http_certificates___400' + '403': + $ref: '#/components/responses/security.reload_http_certificates___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/ssl/transport/reloadcerts: + put: + operationId: security.reload_transport_certificates.0 + x-operation-group: security.reload_transport_certificates + x-version-added: '2.8' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Reloads the transport communication certificates. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#reload-transport-certificates + responses: + '200': + $ref: '#/components/responses/security.reload_transport_certificates___200' + '400': + $ref: '#/components/responses/security.reload_transport_certificates___400' + '403': + $ref: '#/components/responses/security.reload_transport_certificates___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/tenancy/config: + get: + operationId: security.get_tenancy_config.0 + x-operation-group: security.get_tenancy_config + x-version-added: '2.7' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the multi-tenancy configuration. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/multi-tenancy/dynamic-config/#configuring-multi-tenancy-with-the-rest-api + responses: + '200': + $ref: '#/components/responses/security.get_tenancy_config___200' + '400': + $ref: '#/components/responses/security.get_tenancy_config___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: security.create_update_tenancy_config.0 + x-operation-group: security.create_update_tenancy_config + x-version-added: '2.7' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the multi-tenancy configuration. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/multi-tenancy/dynamic-config/#configuring-multi-tenancy-with-the-rest-api + requestBody: + $ref: '#/components/requestBodies/security.create_update_tenancy_config' + responses: + '200': + $ref: '#/components/responses/security.create_update_tenancy_config___200' + '400': + $ref: '#/components/responses/security.create_update_tenancy_config___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/tenants: + get: + operationId: security.get_tenants.0 + x-operation-group: security.get_tenants + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves all tenants. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-tenants + responses: + '200': + $ref: '#/components/responses/security.get_tenants___200' + '400': + $ref: '#/components/responses/security.get_tenants___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + patch: + operationId: security.patch_tenants.0 + x-operation-group: security.patch_tenants + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Adds, deletes, or modifies multiple tenants in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-tenants + requestBody: + $ref: '#/components/requestBodies/security.patch_tenants' + responses: + '200': + $ref: '#/components/responses/security.patch_tenants___200' + '400': + $ref: '#/components/responses/security.patch_tenants___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/tenants/{tenant}: + delete: + operationId: security.delete_tenant.0 + x-operation-group: security.delete_tenant + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified tenant. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-action-group + parameters: + - $ref: '#/components/parameters/security.delete_tenant___path.tenant' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_tenant___200' + '400': + $ref: '#/components/responses/security.delete_tenant___400' + get: + operationId: security.get_tenant.0 + x-operation-group: security.get_tenant + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the specified tenant. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-tenant + parameters: + - $ref: '#/components/parameters/security.get_tenant___path.tenant' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_tenant___200' + patch: + operationId: security.patch_tenant.0 + x-operation-group: security.patch_tenant + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Adds, deletes, or modifies a single tenant. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-tenant + parameters: + - $ref: '#/components/parameters/security.patch_tenant___path.tenant' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_tenant' + responses: + '200': + $ref: '#/components/responses/security.patch_tenant___200' + '400': + $ref: '#/components/responses/security.patch_tenant___400' + put: + operationId: security.create_tenant.0 + x-operation-group: security.create_tenant + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified tenant. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-tenant + parameters: + - $ref: '#/components/parameters/security.create_tenant___path.tenant' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_tenant' + responses: + '200': + $ref: '#/components/responses/security.create_tenant___200' + '201': + $ref: '#/components/responses/security.create_tenant___201' + '400': + $ref: '#/components/responses/security.create_tenant___400' + /_plugins/_security/api/user: + get: + operationId: security.get_users_legacy.0 + x-operation-group: security.get_users_legacy + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieve all internal users. Legacy API. + responses: + '200': + $ref: '#/components/responses/security.get_users_legacy___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/api/user/{username}: + delete: + operationId: security.delete_user_legacy.0 + x-operation-group: security.delete_user_legacy + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Delete the specified user. Legacy API. + parameters: + - $ref: '#/components/parameters/security.delete_user_legacy___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_user_legacy___200' + get: + operationId: security.get_user_legacy.0 + x-operation-group: security.get_user_legacy + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieve one user. Legacy API. + parameters: + - $ref: '#/components/parameters/security.get_user_legacy___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_user_legacy___200' + put: + operationId: security.create_user_legacy.0 + x-operation-group: security.create_user_legacy + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified user. Legacy API. + parameters: + - $ref: '#/components/parameters/security.create_user_legacy___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_user_legacy' + responses: + '200': + $ref: '#/components/responses/security.create_user_legacy___200' + '201': + $ref: '#/components/responses/security.create_user_legacy___201' + /_plugins/_security/api/user/{username}/authtoken: + post: + operationId: security.generate_user_token_legacy.0 + x-operation-group: security.generate_user_token_legacy + x-version-added: '2.7' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Generates authorization token for the given user. Legacy API. Not Implemented. + parameters: + - $ref: '#/components/parameters/security.generate_user_token_legacy___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '501': + $ref: '#/components/responses/security.generate_user_token_legacy___501' + /_plugins/_security/api/validate: + get: + operationId: security.validate.0 + x-operation-group: security.validate + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Checks whether the v6 security configuration is valid and ready to be migrated to v7. + parameters: + - $ref: '#/components/parameters/security.validate___query.accept_invalid' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.validate___200' + '400': + $ref: '#/components/responses/security.validate___400' + /_plugins/_security/authinfo: + get: + operationId: security.authinfo.0 + x-operation-group: security.authinfo + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns or updates authentication information for the currently authenticated user. + parameters: + - $ref: '#/components/parameters/security.authinfo___query.auth_type' + - $ref: '#/components/parameters/security.authinfo___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.authinfo___200' + '500': + $ref: '#/components/responses/security.authinfo___500' + post: + operationId: security.authinfo.1 + x-operation-group: security.authinfo + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns or updates authentication information for the currently authenticated user. + parameters: + - $ref: '#/components/parameters/security.authinfo___query.auth_type' + - $ref: '#/components/parameters/security.authinfo___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.authinfo___200' + '500': + $ref: '#/components/responses/security.authinfo___500' + /_plugins/_security/dashboardsinfo: + get: + operationId: security.get_dashboards_info.0 + x-operation-group: security.get_dashboards_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the current values for dynamic security settings for OpenSearch Dashboards. + responses: + '200': + $ref: '#/components/responses/security.get_dashboards_info___200' + '500': + $ref: '#/components/responses/security.get_dashboards_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: security.post_dashboards_info.1 + x-operation-group: security.post_dashboards_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the current values for dynamic security settings for OpenSearch Dashboards. + responses: + '200': + $ref: '#/components/responses/security.post_dashboards_info___200' + '500': + $ref: '#/components/responses/security.post_dashboards_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/health: + get: + operationId: security.health.0 + x-operation-group: security.health + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Checks to see if the Security plugin is running. + parameters: + - $ref: '#/components/parameters/security.health___query.mode' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#health-check + responses: + '200': + $ref: '#/components/responses/security.health___200' + post: + operationId: security.health.1 + x-operation-group: security.health + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Checks to see if the Security plugin is running. + parameters: + - $ref: '#/components/parameters/security.health___query.mode' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#health-check + responses: + '200': + $ref: '#/components/responses/security.health___200' + /_plugins/_security/tenantinfo: + get: + operationId: security.tenant_info.0 + x-operation-group: security.tenant_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the names of current tenants. Requires super admin or `kibanaserver` permissions. + responses: + '200': + $ref: '#/components/responses/security.tenant_info___200' + '403': + $ref: '#/components/responses/security.tenant_info___403' + '500': + $ref: '#/components/responses/security.tenant_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: security.tenant_info.1 + x-operation-group: security.tenant_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the names of current tenants. Requires super admin or `kibanaserver` permissions. + responses: + '200': + $ref: '#/components/responses/security.tenant_info___200' + '403': + $ref: '#/components/responses/security.tenant_info___403' + '500': + $ref: '#/components/responses/security.tenant_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/whoami: + get: + operationId: security.who_am_i.0 + x-operation-group: security.who_am_i + x-version-added: '2.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Gets the identity information for the user currently logged in. + responses: + '200': + $ref: '#/components/responses/security.who_am_i___200' + '500': + $ref: '#/components/responses/security.who_am_i___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + post: + operationId: security.who_am_i.1 + x-operation-group: security.who_am_i + x-version-added: '2.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Gets the identity information for the user currently logged in. + responses: + '200': + $ref: '#/components/responses/security.who_am_i___200' + '500': + $ref: '#/components/responses/security.who_am_i___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_security/whoamiprotected: + get: + operationId: security.who_am_i_protected.0 + x-operation-group: security.who_am_i_protected + x-version-added: '2.11' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Gets the identity information for the user currently logged in. To use this operation, you must have access to this endpoint when authorization at REST layer is enabled. + responses: + '200': + $ref: '#/components/responses/security.who_am_i_protected___200' + '500': + $ref: '#/components/responses/security.who_am_i_protected___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_sm/policies: + get: + operationId: sm.get_policies.0 + x-operation-group: sm.get_policies + x-version-added: '2.1' + description: Retrieves all snapshot management policies with optional pagination and filtering. + parameters: + - $ref: '#/components/parameters/sm.get_policies___query.from' + - $ref: '#/components/parameters/sm.get_policies___query.queryString' + - $ref: '#/components/parameters/sm.get_policies___query.size' + - $ref: '#/components/parameters/sm.get_policies___query.sortField' + - $ref: '#/components/parameters/sm.get_policies___query.sortOrder' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/sm.get_policies___200' + /_plugins/_sm/policies/{policy_name}: + delete: + operationId: sm.delete_policy.0 + x-operation-group: sm.delete_policy + x-version-added: '2.1' + description: Deletes a snapshot management policy. + parameters: + - $ref: '#/components/parameters/sm.delete_policy___path.policy_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/sm.delete_policy___200' + '404': + $ref: '#/components/responses/sm.delete_policy___404' + get: + operationId: sm.get_policy.0 + x-operation-group: sm.get_policy + x-version-added: '2.1' + description: Retrieves a specific snapshot management policy by name. + parameters: + - $ref: '#/components/parameters/sm.get_policy___path.policy_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/sm.get_policy___200' + '404': + $ref: '#/components/responses/sm.get_policy___404' + post: + operationId: sm.create_policy.0 + x-operation-group: sm.create_policy + x-version-added: '2.1' + description: Creates a snapshot management policy. + parameters: + - $ref: '#/components/parameters/sm.create_policy___path.policy_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sm.create_policy' + responses: + '201': + $ref: '#/components/responses/sm.create_policy___201' + '400': + $ref: '#/components/responses/sm.create_policy___400' + put: + operationId: sm.update_policy.0 + x-operation-group: sm.update_policy + x-version-added: '2.1' + description: Updates an existing snapshot management policy. Requires `if_seq_no` and `if_primary_term`. + parameters: + - $ref: '#/components/parameters/sm.update_policy___path.policy_name' + - $ref: '#/components/parameters/sm.update_policy___query.if_primary_term' + - $ref: '#/components/parameters/sm.update_policy___query.if_seq_no' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sm.update_policy' + responses: + '200': + $ref: '#/components/responses/sm.update_policy___200' + '404': + $ref: '#/components/responses/sm.update_policy___404' + /_plugins/_sm/policies/{policy_name}/_explain: + get: + operationId: sm.explain_policy.0 + x-operation-group: sm.explain_policy + x-version-added: '2.1' + description: Explains the state of the snapshot management policy. + parameters: + - $ref: '#/components/parameters/sm.explain_policy___path.policy_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/sm.explain_policy___200' + /_plugins/_sm/policies/{policy_name}/_start: + post: + operationId: sm.start_policy.0 + x-operation-group: sm.start_policy + x-version-added: '2.1' + description: Starts a snapshot management policy. + parameters: + - $ref: '#/components/parameters/sm.start_policy___path.policy_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/sm.start_policy___200' + /_plugins/_sm/policies/{policy_name}/_stop: + post: + operationId: sm.stop_policy.0 + x-operation-group: sm.stop_policy + x-version-added: '2.1' + description: Stops a snapshot management policy. + parameters: + - $ref: '#/components/parameters/sm.stop_policy___path.policy_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/sm.stop_policy___200' + /_plugins/_sql: + post: + operationId: sql.query.0 + x-operation-group: sql.query + x-version-added: '1.0' + description: Executes SQL or PPL queries against OpenSearch indexes. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/sql.query___query.format' + - $ref: '#/components/parameters/sql.query___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.query' + responses: + '200': + $ref: '#/components/responses/sql.query___200' + /_plugins/_sql/_explain: + post: + operationId: sql.explain.0 + x-operation-group: sql.explain + x-version-added: '1.0' + description: Returns the execution plan for a SQL or PPL query. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/sql.explain___query.format' + - $ref: '#/components/parameters/sql.explain___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.explain' + responses: + '200': + $ref: '#/components/responses/sql.explain___200' + /_plugins/_sql/close: + post: + operationId: sql.close.0 + x-operation-group: sql.close + x-version-added: '1.0' + description: Closes an open cursor to free server-side resources. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/sql.close___query.format' + - $ref: '#/components/parameters/sql.close___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.close' + responses: + '200': + $ref: '#/components/responses/sql.close___200' + /_plugins/_sql/stats: + get: + operationId: sql.get_stats.0 + x-operation-group: sql.get_stats + x-version-added: '1.0' + description: Retrieves performance metrics for the SQL plugin. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ + parameters: + - $ref: '#/components/parameters/sql.get_stats___query.format' + - $ref: '#/components/parameters/sql.get_stats___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/sql.get_stats___200' + post: + operationId: sql.post_stats.1 + x-operation-group: sql.post_stats + x-version-added: '1.0' + description: Retrieves filtered performance metrics for the SQL plugin. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ + parameters: + - $ref: '#/components/parameters/sql.post_stats___query.format' + - $ref: '#/components/parameters/sql.post_stats___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.post_stats' + responses: + '200': + $ref: '#/components/responses/sql.post_stats___200' + /_plugins/_transform: + get: + operationId: transforms.search.0 + x-operation-group: transforms.search + x-version-added: '1.0' + description: Returns the details of all transform jobs. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#get-a-transform-jobs-details + parameters: + - $ref: '#/components/parameters/transforms.search___query.from' + - $ref: '#/components/parameters/transforms.search___query.search' + - $ref: '#/components/parameters/transforms.search___query.size' + - $ref: '#/components/parameters/transforms.search___query.sortDirection' + - $ref: '#/components/parameters/transforms.search___query.sortField' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/transforms.search___200' + /_plugins/_transform/_preview: + post: + operationId: transforms.preview.0 + x-operation-group: transforms.preview + x-version-added: '1.0' + description: Returns a preview of what a transformed index would look like. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#preview-a-transform-jobs-results + requestBody: + $ref: '#/components/requestBodies/transforms.preview' + responses: + '200': + $ref: '#/components/responses/transforms.preview___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/_transform/{id}: + delete: + operationId: transforms.delete.0 + x-operation-group: transforms.delete + x-version-added: '1.0' + description: Delete an index transform. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#delete-a-transform-job + parameters: + - $ref: '#/components/parameters/transforms.delete___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/transforms.delete___200' + get: + operationId: transforms.get.0 + x-operation-group: transforms.get + x-version-added: '1.0' + description: Returns the status and metadata of a transform job. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#get-a-transform-jobs-details + parameters: + - $ref: '#/components/parameters/transforms.get___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/transforms.get___200' + put: + operationId: transforms.put.0 + x-operation-group: transforms.put + x-version-added: '1.0' + description: Create an index transform, or update a transform if `if_seq_no` and `if_primary_term` are provided. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#create-a-transform-job + parameters: + - $ref: '#/components/parameters/transforms.put___path.id' + - $ref: '#/components/parameters/transforms.put___query.if_primary_term' + - $ref: '#/components/parameters/transforms.put___query.if_seq_no' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/transforms.put' + responses: + '200': + $ref: '#/components/responses/transforms.put___200' + '201': + $ref: '#/components/responses/transforms.put___201' + /_plugins/_transform/{id}/_explain: + get: + operationId: transforms.explain.0 + x-operation-group: transforms.explain + x-version-added: '1.0' + description: Returns the status and metadata of a transform job. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#get-the-status-of-a-transform-job + parameters: + - $ref: '#/components/parameters/transforms.explain___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/transforms.explain___200' + /_plugins/_transform/{id}/_start: + post: + operationId: transforms.start.0 + x-operation-group: transforms.start + x-version-added: '1.0' + description: Start transform. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#start-a-transform-job + parameters: + - $ref: '#/components/parameters/transforms.start___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/transforms.start___200' + /_plugins/_transform/{id}/_stop: + post: + operationId: transforms.stop.0 + x-operation-group: transforms.stop + x-version-added: '1.0' + description: Stop transform. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-transforms/transforms-apis/#stop-a-transform-job + parameters: + - $ref: '#/components/parameters/transforms.stop___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/transforms.stop___200' + /_plugins/geospatial/_upload/stats: + get: + operationId: geospatial.get_upload_stats.0 + x-operation-group: geospatial.get_upload_stats + x-version-added: '2.11' + description: Retrieves statistics for all geospatial uploads. + responses: + '200': + $ref: '#/components/responses/geospatial.get_upload_stats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/geospatial/geojson/_upload: + post: + operationId: geospatial.geojson_upload_post.0 + x-operation-group: geospatial.geojson_upload_post + x-version-added: '2.11' + description: |- + Use an OpenSearch query to upload `GeoJSON`, operation will fail if index exists. + - When type is `geo_point`, only Point geometry is allowed + - When type is `geo_shape`, all geometry types are allowed (Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Envelope). + requestBody: + $ref: '#/components/requestBodies/geospatial.geojson_upload_post' + responses: + '200': + $ref: '#/components/responses/geospatial.geojson_upload_post___200' + '400': + $ref: '#/components/responses/geospatial.geojson_upload_post___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: geospatial.geojson_upload_put.0 + x-operation-group: geospatial.geojson_upload_put + x-version-added: '2.11' + description: |- + Use an OpenSearch query to upload `GeoJSON` regardless if index exists. + - When type is `geo_point`, only Point geometry is allowed + - When type is `geo_shape`, all geometry types are allowed (Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Envelope). + requestBody: + $ref: '#/components/requestBodies/geospatial.geojson_upload_put' + responses: + '200': + $ref: '#/components/responses/geospatial.geojson_upload_put___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/geospatial/ip2geo/datasource: + get: + operationId: geospatial.get_ip2geo_datasource.0 + x-operation-group: geospatial.get_ip2geo_datasource + x-version-added: '2.11' + description: Get one or more IP2Geo data sources, defaulting to returning all if no names specified. + externalDocs: + url: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#sending-a-get-request + responses: + '200': + $ref: '#/components/responses/geospatial.get_ip2geo_datasource___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_plugins/geospatial/ip2geo/datasource/{name}: + delete: + operationId: geospatial.delete_ip2geo_datasource.0 + x-operation-group: geospatial.delete_ip2geo_datasource + x-version-added: '2.11' + description: Delete a specific IP2Geo data source. + externalDocs: + url: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#deleting-the-ip2geo-data-source + parameters: + - $ref: '#/components/parameters/geospatial.delete_ip2geo_datasource___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/geospatial.delete_ip2geo_datasource___200' + '404': + $ref: '#/components/responses/geospatial.delete_ip2geo_datasource___404' + get: + operationId: geospatial.get_ip2geo_datasource.1 + x-operation-group: geospatial.get_ip2geo_datasource + x-version-added: '2.11' + description: Get one or more IP2Geo data sources, defaulting to returning all if no names specified. + externalDocs: + url: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#sending-a-get-request + parameters: + - $ref: '#/components/parameters/geospatial.get_ip2geo_datasource___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/geospatial.get_ip2geo_datasource___200' + put: + operationId: geospatial.put_ip2geo_datasource.0 + x-operation-group: geospatial.put_ip2geo_datasource + x-version-added: '2.11' + description: |- + Create a specific IP2Geo data source. + Default values: + - `endpoint`: `"https://geoip.maps.opensearch.org/v1/geolite2-city/manifest.json"` + - `update_interval_in_days`: 3. + externalDocs: + url: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#data-source-options + parameters: + - $ref: '#/components/parameters/geospatial.put_ip2geo_datasource___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/geospatial.put_ip2geo_datasource' + responses: + '200': + $ref: '#/components/responses/geospatial.put_ip2geo_datasource___200' + '400': + $ref: '#/components/responses/geospatial.put_ip2geo_datasource___400' + /_plugins/geospatial/ip2geo/datasource/{name}/_settings: + put: + operationId: geospatial.put_ip2geo_datasource_settings.0 + x-operation-group: geospatial.put_ip2geo_datasource_settings + x-version-added: '2.11' + description: Update a specific IP2Geo data source. + externalDocs: + url: https://docs.opensearch.org/docs/latest/ingest-pipelines/processors/ip2geo/#updating-an-ip2geo-data-source + parameters: + - $ref: '#/components/parameters/geospatial.put_ip2geo_datasource_settings___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/geospatial.put_ip2geo_datasource_settings' + responses: + '200': + $ref: '#/components/responses/geospatial.put_ip2geo_datasource_settings___200' + '404': + $ref: '#/components/responses/geospatial.put_ip2geo_datasource_settings___404' + /_plugins/ubi/initialize: + post: + operationId: ubi.initialize.0 + x-operation-group: ubi.initialize + x-version-added: '1.0' + description: Initializes the UBI indexes. + responses: + '200': + $ref: '#/components/responses/ubi.initialize___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_rank_eval: + get: + operationId: rank_eval.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___RankEvalFailures' + x-operation-group: rank_eval + x-version-added: '1.0' + description: Allows to evaluate the quality of ranked search results over a set of typical search queries. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/rank-eval/ + parameters: + - $ref: '#/components/parameters/rank_eval___query.allow_no_indices' + - $ref: '#/components/parameters/rank_eval___query.expand_wildcards' + - $ref: '#/components/parameters/rank_eval___query.ignore_unavailable' + - $ref: '#/components/parameters/rank_eval___query.search_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/rank_eval' + responses: + '200': + $ref: '#/components/responses/rank_eval___200' + post: + operationId: rank_eval.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___RankEvalFailures' + x-operation-group: rank_eval + x-version-added: '1.0' + description: Allows to evaluate the quality of ranked search results over a set of typical search queries. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/rank-eval/ + parameters: + - $ref: '#/components/parameters/rank_eval___query.allow_no_indices' + - $ref: '#/components/parameters/rank_eval___query.expand_wildcards' + - $ref: '#/components/parameters/rank_eval___query.ignore_unavailable' + - $ref: '#/components/parameters/rank_eval___query.search_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/rank_eval' + responses: + '200': + $ref: '#/components/responses/rank_eval___200' + /_recovery: + get: + operationId: indices.recovery.0 + x-operation-group: indices.recovery + x-version-added: '1.0' + description: Returns information about ongoing index shard recoveries. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.recovery___query.active_only' + - $ref: '#/components/parameters/indices.recovery___query.detailed' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.recovery___200' + /_refresh: + get: + operationId: indices.refresh.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.refresh + x-version-added: '1.0' + description: Performs the refresh operation in one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/availability-and-recovery/remote-store/index/#refresh-level-and-request-level-durability + parameters: + - $ref: '#/components/parameters/indices.refresh___query.allow_no_indices' + - $ref: '#/components/parameters/indices.refresh___query.expand_wildcards' + - $ref: '#/components/parameters/indices.refresh___query.ignore_unavailable' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.refresh___200' + post: + operationId: indices.refresh.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.refresh + x-version-added: '1.0' + description: Performs the refresh operation in one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/availability-and-recovery/remote-store/index/#refresh-level-and-request-level-durability + parameters: + - $ref: '#/components/parameters/indices.refresh___query.allow_no_indices' + - $ref: '#/components/parameters/indices.refresh___query.expand_wildcards' + - $ref: '#/components/parameters/indices.refresh___query.ignore_unavailable' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.refresh___200' + /_reindex: + post: + operationId: reindex.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkByScrollFailures' + x-operation-group: reindex + x-version-added: '1.0' + description: |- + Allows to copy documents from one index to another, optionally filtering the source + documents by a query, changing the destination index settings, or fetching the + documents from a remote cluster. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/reindex-data/ + parameters: + - $ref: '#/components/parameters/reindex___query.max_docs' + - $ref: '#/components/parameters/reindex___query.refresh' + - $ref: '#/components/parameters/reindex___query.requests_per_second' + - $ref: '#/components/parameters/reindex___query.require_alias' + - $ref: '#/components/parameters/reindex___query.scroll' + - $ref: '#/components/parameters/reindex___query.slices' + - $ref: '#/components/parameters/reindex___query.timeout' + - $ref: '#/components/parameters/reindex___query.wait_for_active_shards' + - $ref: '#/components/parameters/reindex___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/reindex' + responses: + '200': + $ref: '#/components/responses/reindex___200' + /_reindex/{task_id}/_rethrottle: + post: + operationId: reindex_rethrottle.0 + x-operation-group: reindex_rethrottle + x-version-added: '1.0' + description: Changes the number of requests per second for a particular reindex operation. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/reindex_rethrottle___path.task_id' + - $ref: '#/components/parameters/reindex_rethrottle___query.requests_per_second' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/reindex_rethrottle___200' + /_remote/info: + get: + operationId: cluster.remote_info.0 + x-operation-group: cluster.remote_info + x-version-added: '1.0' + description: Returns the information about configured remote clusters. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/remote-info/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/cluster.remote_info___200' + /_remotestore/_restore: + post: + operationId: remote_store.restore.0 + x-operation-group: remote_store.restore + x-version-added: '1.0' + description: Restores from remote store. + externalDocs: + url: https://opensearch.org/docs/latest/opensearch/remote/#restoring-from-a-backup + parameters: + - $ref: '#/components/parameters/remote_store.restore___query.cluster_manager_timeout' + - $ref: '#/components/parameters/remote_store.restore___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/remote_store.restore' + responses: + '200': + $ref: '#/components/responses/remote_store.restore___200' + /_render/template: + get: + operationId: render_search_template.0 + x-operation-group: render_search_template + x-version-added: '1.0' + description: Allows to use the Mustache language to pre-render a search definition. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/render_search_template' + responses: + '200': + $ref: '#/components/responses/render_search_template___200' + post: + operationId: render_search_template.1 + x-operation-group: render_search_template + x-version-added: '1.0' + description: Allows to use the Mustache language to pre-render a search definition. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/render_search_template' + responses: + '200': + $ref: '#/components/responses/render_search_template___200' + /_render/template/{id}: + get: + operationId: render_search_template.2 + x-operation-group: render_search_template + x-version-added: '1.0' + description: Allows to use the Mustache language to pre-render a search definition. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/render_search_template___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/render_search_template' + responses: + '200': + $ref: '#/components/responses/render_search_template___200' + post: + operationId: render_search_template.3 + x-operation-group: render_search_template + x-version-added: '1.0' + description: Allows to use the Mustache language to pre-render a search definition. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/render_search_template___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/render_search_template' + responses: + '200': + $ref: '#/components/responses/render_search_template___200' + /_resolve/index/{name}: + get: + operationId: indices.resolve_index.0 + x-operation-group: indices.resolve_index + x-version-added: '1.0' + description: Returns information about any matching indexes, aliases, and data streams. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.resolve_index___path.name' + - $ref: '#/components/parameters/indices.resolve_index___query.expand_wildcards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.resolve_index___200' + /_script_context: + get: + operationId: get_script_context.0 + x-operation-group: get_script_context + x-version-added: '1.0' + description: Returns all script contexts. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/get-script-contexts/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/get_script_context___200' + /_script_language: + get: + operationId: get_script_languages.0 + x-operation-group: get_script_languages + x-version-added: '1.0' + description: Returns available script types, languages and contexts. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/get-script-language/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/get_script_languages___200' + /_scripts/{id}: + delete: + operationId: delete_script.0 + x-operation-group: delete_script + x-version-added: '1.0' + description: Deletes a script. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/delete-script/ + parameters: + - $ref: '#/components/parameters/delete_script___path.id' + - $ref: '#/components/parameters/delete_script___query.cluster_manager_timeout' + - $ref: '#/components/parameters/delete_script___query.master_timeout' + - $ref: '#/components/parameters/delete_script___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/delete_script___200' + get: + operationId: get_script.0 + x-operation-group: get_script + x-version-added: '1.0' + description: Returns a script. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/get-stored-script/ + parameters: + - $ref: '#/components/parameters/get_script___path.id' + - $ref: '#/components/parameters/get_script___query.cluster_manager_timeout' + - $ref: '#/components/parameters/get_script___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/get_script___200' + post: + operationId: put_script.0 + x-operation-group: put_script + x-version-added: '1.0' + description: Creates or updates a script. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/create-stored-script/ + parameters: + - $ref: '#/components/parameters/put_script___path.id' + - $ref: '#/components/parameters/put_script___query.cluster_manager_timeout' + - $ref: '#/components/parameters/put_script___query.context' + - $ref: '#/components/parameters/put_script___query.master_timeout' + - $ref: '#/components/parameters/put_script___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/put_script' + responses: + '200': + $ref: '#/components/responses/put_script___200' + put: + operationId: put_script.1 + x-operation-group: put_script + x-version-added: '1.0' + description: Creates or updates a script. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/create-stored-script/ + parameters: + - $ref: '#/components/parameters/put_script___path.id' + - $ref: '#/components/parameters/put_script___query.cluster_manager_timeout' + - $ref: '#/components/parameters/put_script___query.context' + - $ref: '#/components/parameters/put_script___query.master_timeout' + - $ref: '#/components/parameters/put_script___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/put_script' + responses: + '200': + $ref: '#/components/responses/put_script___200' + /_scripts/{id}/{context}: + post: + operationId: put_script.2 + x-operation-group: put_script + x-version-added: '1.0' + description: Creates or updates a script. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/create-stored-script/ + parameters: + - $ref: '#/components/parameters/put_script___path.context' + - $ref: '#/components/parameters/put_script___path.id' + - $ref: '#/components/parameters/put_script___query.cluster_manager_timeout' + - $ref: '#/components/parameters/put_script___query.context' + - $ref: '#/components/parameters/put_script___query.master_timeout' + - $ref: '#/components/parameters/put_script___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/put_script' + responses: + '200': + $ref: '#/components/responses/put_script___200' + put: + operationId: put_script.3 + x-operation-group: put_script + x-version-added: '1.0' + description: Creates or updates a script. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/create-stored-script/ + parameters: + - $ref: '#/components/parameters/put_script___path.context' + - $ref: '#/components/parameters/put_script___path.id' + - $ref: '#/components/parameters/put_script___query.cluster_manager_timeout' + - $ref: '#/components/parameters/put_script___query.context' + - $ref: '#/components/parameters/put_script___query.master_timeout' + - $ref: '#/components/parameters/put_script___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/put_script' + responses: + '200': + $ref: '#/components/responses/put_script___200' + /_scripts/painless/_execute: + get: + operationId: scripts_painless_execute.0 + x-operation-group: scripts_painless_execute + x-version-added: '1.0' + description: Allows an arbitrary script to be executed and a result to be returned. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/exec-script/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/scripts_painless_execute' + responses: + '200': + $ref: '#/components/responses/scripts_painless_execute___200' + post: + operationId: scripts_painless_execute.1 + x-operation-group: scripts_painless_execute + x-version-added: '1.0' + description: Allows an arbitrary script to be executed and a result to be returned. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/script-apis/exec-script/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/scripts_painless_execute' + responses: + '200': + $ref: '#/components/responses/scripts_painless_execute___200' + /_search: + get: + operationId: search.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: search + x-version-added: '1.0' + description: Returns results matching a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/search/ + parameters: + - $ref: '#/components/parameters/search___query._source' + - $ref: '#/components/parameters/search___query._source_excludes' + - $ref: '#/components/parameters/search___query._source_includes' + - $ref: '#/components/parameters/search___query.allow_no_indices' + - $ref: '#/components/parameters/search___query.allow_partial_search_results' + - $ref: '#/components/parameters/search___query.analyze_wildcard' + - $ref: '#/components/parameters/search___query.analyzer' + - $ref: '#/components/parameters/search___query.batched_reduce_size' + - $ref: '#/components/parameters/search___query.cancel_after_time_interval' + - $ref: '#/components/parameters/search___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/search___query.default_operator' + - $ref: '#/components/parameters/search___query.df' + - $ref: '#/components/parameters/search___query.docvalue_fields' + - $ref: '#/components/parameters/search___query.expand_wildcards' + - $ref: '#/components/parameters/search___query.explain' + - $ref: '#/components/parameters/search___query.from' + - $ref: '#/components/parameters/search___query.ignore_throttled' + - $ref: '#/components/parameters/search___query.ignore_unavailable' + - $ref: '#/components/parameters/search___query.include_named_queries_score' + - $ref: '#/components/parameters/search___query.index' + - $ref: '#/components/parameters/search___query.lenient' + - $ref: '#/components/parameters/search___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/search___query.phase_took' + - $ref: '#/components/parameters/search___query.pre_filter_shard_size' + - $ref: '#/components/parameters/search___query.preference' + - $ref: '#/components/parameters/search___query.q' + - $ref: '#/components/parameters/search___query.request_cache' + - $ref: '#/components/parameters/search___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/search___query.routing' + - $ref: '#/components/parameters/search___query.scroll' + - $ref: '#/components/parameters/search___query.search_pipeline' + - $ref: '#/components/parameters/search___query.search_type' + - $ref: '#/components/parameters/search___query.seq_no_primary_term' + - $ref: '#/components/parameters/search___query.size' + - $ref: '#/components/parameters/search___query.sort' + - $ref: '#/components/parameters/search___query.stats' + - $ref: '#/components/parameters/search___query.stored_fields' + - $ref: '#/components/parameters/search___query.suggest_field' + - $ref: '#/components/parameters/search___query.suggest_mode' + - $ref: '#/components/parameters/search___query.suggest_size' + - $ref: '#/components/parameters/search___query.suggest_text' + - $ref: '#/components/parameters/search___query.terminate_after' + - $ref: '#/components/parameters/search___query.timeout' + - $ref: '#/components/parameters/search___query.track_scores' + - $ref: '#/components/parameters/search___query.track_total_hits' + - $ref: '#/components/parameters/search___query.typed_keys' + - $ref: '#/components/parameters/search___query.verbose_pipeline' + - $ref: '#/components/parameters/search___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search' + responses: + '200': + $ref: '#/components/responses/search___200' + '400': + $ref: '#/components/responses/search___400' + '404': + $ref: '#/components/responses/search___404' + post: + operationId: search.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: search + x-version-added: '1.0' + description: Returns results matching a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/search/ + parameters: + - $ref: '#/components/parameters/search___query._source' + - $ref: '#/components/parameters/search___query._source_excludes' + - $ref: '#/components/parameters/search___query._source_includes' + - $ref: '#/components/parameters/search___query.allow_no_indices' + - $ref: '#/components/parameters/search___query.allow_partial_search_results' + - $ref: '#/components/parameters/search___query.analyze_wildcard' + - $ref: '#/components/parameters/search___query.analyzer' + - $ref: '#/components/parameters/search___query.batched_reduce_size' + - $ref: '#/components/parameters/search___query.cancel_after_time_interval' + - $ref: '#/components/parameters/search___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/search___query.default_operator' + - $ref: '#/components/parameters/search___query.df' + - $ref: '#/components/parameters/search___query.docvalue_fields' + - $ref: '#/components/parameters/search___query.expand_wildcards' + - $ref: '#/components/parameters/search___query.explain' + - $ref: '#/components/parameters/search___query.from' + - $ref: '#/components/parameters/search___query.ignore_throttled' + - $ref: '#/components/parameters/search___query.ignore_unavailable' + - $ref: '#/components/parameters/search___query.include_named_queries_score' + - $ref: '#/components/parameters/search___query.index' + - $ref: '#/components/parameters/search___query.lenient' + - $ref: '#/components/parameters/search___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/search___query.phase_took' + - $ref: '#/components/parameters/search___query.pre_filter_shard_size' + - $ref: '#/components/parameters/search___query.preference' + - $ref: '#/components/parameters/search___query.q' + - $ref: '#/components/parameters/search___query.request_cache' + - $ref: '#/components/parameters/search___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/search___query.routing' + - $ref: '#/components/parameters/search___query.scroll' + - $ref: '#/components/parameters/search___query.search_pipeline' + - $ref: '#/components/parameters/search___query.search_type' + - $ref: '#/components/parameters/search___query.seq_no_primary_term' + - $ref: '#/components/parameters/search___query.size' + - $ref: '#/components/parameters/search___query.sort' + - $ref: '#/components/parameters/search___query.stats' + - $ref: '#/components/parameters/search___query.stored_fields' + - $ref: '#/components/parameters/search___query.suggest_field' + - $ref: '#/components/parameters/search___query.suggest_mode' + - $ref: '#/components/parameters/search___query.suggest_size' + - $ref: '#/components/parameters/search___query.suggest_text' + - $ref: '#/components/parameters/search___query.terminate_after' + - $ref: '#/components/parameters/search___query.timeout' + - $ref: '#/components/parameters/search___query.track_scores' + - $ref: '#/components/parameters/search___query.track_total_hits' + - $ref: '#/components/parameters/search___query.typed_keys' + - $ref: '#/components/parameters/search___query.verbose_pipeline' + - $ref: '#/components/parameters/search___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search' + responses: + '200': + $ref: '#/components/responses/search___200' + '400': + $ref: '#/components/responses/search___400' + '404': + $ref: '#/components/responses/search___404' + /_search_shards: + get: + operationId: search_shards.0 + x-operation-group: search_shards + x-version-added: '1.0' + description: Returns information about the indexes and shards that a search request would be executed against. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/search_shards___query.allow_no_indices' + - $ref: '#/components/parameters/search_shards___query.expand_wildcards' + - $ref: '#/components/parameters/search_shards___query.ignore_unavailable' + - $ref: '#/components/parameters/search_shards___query.local' + - $ref: '#/components/parameters/search_shards___query.preference' + - $ref: '#/components/parameters/search_shards___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_shards' + responses: + '200': + $ref: '#/components/responses/search_shards___200' + post: + operationId: search_shards.1 + x-operation-group: search_shards + x-version-added: '1.0' + description: Returns information about the indexes and shards that a search request would be executed against. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/search_shards___query.allow_no_indices' + - $ref: '#/components/parameters/search_shards___query.expand_wildcards' + - $ref: '#/components/parameters/search_shards___query.ignore_unavailable' + - $ref: '#/components/parameters/search_shards___query.local' + - $ref: '#/components/parameters/search_shards___query.preference' + - $ref: '#/components/parameters/search_shards___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_shards' + responses: + '200': + $ref: '#/components/responses/search_shards___200' + /_search/pipeline: + get: + operationId: search_pipeline.get.0 + x-operation-group: search_pipeline.get + x-version-added: '2.9' + description: Retrieves information about a specified search pipeline. + parameters: + - $ref: '#/components/parameters/search_pipeline.get___query.cluster_manager_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_pipeline.get___200' + /_search/pipeline/{id}: + delete: + operationId: search_pipeline.delete.0 + x-operation-group: search_pipeline.delete + x-version-added: '2.9' + description: Deletes the specified search pipeline. + parameters: + - $ref: '#/components/parameters/search_pipeline.delete___path.id' + - $ref: '#/components/parameters/search_pipeline.delete___query.cluster_manager_timeout' + - $ref: '#/components/parameters/search_pipeline.delete___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_pipeline.delete___200' + get: + operationId: search_pipeline.get.1 + x-operation-group: search_pipeline.get + x-version-added: '2.9' + description: Retrieves information about a specified search pipeline. + parameters: + - $ref: '#/components/parameters/search_pipeline.get___path.id' + - $ref: '#/components/parameters/search_pipeline.get___query.cluster_manager_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/search_pipeline.get___200' + put: + operationId: search_pipeline.put.0 + x-operation-group: search_pipeline.put + x-version-added: '2.9' + description: Creates or replaces the specified search pipeline. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-pipelines/creating-search-pipeline/ + parameters: + - $ref: '#/components/parameters/search_pipeline.put___path.id' + - $ref: '#/components/parameters/search_pipeline.put___query.cluster_manager_timeout' + - $ref: '#/components/parameters/search_pipeline.put___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_pipeline.put' + responses: + '200': + $ref: '#/components/responses/search_pipeline.put___200' + /_search/point_in_time: + delete: + operationId: delete_pit.0 + x-operation-group: delete_pit + x-version-added: '2.4' + description: Deletes one or more point in time searches based on the IDs passed. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/#delete-pits + requestBody: + $ref: '#/components/requestBodies/delete_pit' + responses: + '200': + $ref: '#/components/responses/delete_pit___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_search/point_in_time/_all: + delete: + operationId: delete_all_pits.0 + x-operation-group: delete_all_pits + x-version-added: '2.4' + description: Deletes all active point in time searches. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/#delete-pits + responses: + '200': + $ref: '#/components/responses/delete_all_pits___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + get: + operationId: get_all_pits.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___PitNodeFailures' + x-operation-group: get_all_pits + x-version-added: '2.4' + description: Lists all active point in time searches. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/#list-all-pits + responses: + '200': + $ref: '#/components/responses/get_all_pits___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_search/scroll: + delete: + operationId: clear_scroll.0 + x-operation-group: clear_scroll + x-version-added: '1.0' + description: Explicitly clears the search context for a scroll. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/scroll/ + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/clear_scroll' + responses: + '200': + $ref: '#/components/responses/clear_scroll___200' + '404': + $ref: '#/components/responses/clear_scroll___404' + get: + operationId: scroll.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: scroll + x-version-added: '1.0' + description: Allows to retrieve a large numbers of results from a single search request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/scroll/#path-and-http-methods + parameters: + - $ref: '#/components/parameters/scroll___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/scroll___query.scroll' + - $ref: '#/components/parameters/scroll___query.scroll_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/scroll' + responses: + '200': + $ref: '#/components/responses/scroll___200' + post: + operationId: scroll.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: scroll + x-version-added: '1.0' + description: Allows to retrieve a large numbers of results from a single search request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/scroll/#path-and-http-methods + parameters: + - $ref: '#/components/parameters/scroll___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/scroll___query.scroll' + - $ref: '#/components/parameters/scroll___query.scroll_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/scroll' + responses: + '200': + $ref: '#/components/responses/scroll___200' + /_search/scroll/{scroll_id}: + delete: + operationId: clear_scroll.1 + x-operation-group: clear_scroll + deprecated: true + x-deprecation-message: A scroll id can be quite large and should be specified as part of the body + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: Explicitly clears the search context for a scroll. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/scroll/ + parameters: + - $ref: '#/components/parameters/clear_scroll___path.scroll_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/clear_scroll' + responses: + '200': + $ref: '#/components/responses/clear_scroll___200' + '404': + $ref: '#/components/responses/clear_scroll___404' + get: + operationId: scroll.2 + x-operation-group: scroll + deprecated: true + x-deprecation-message: A scroll id can be quite large and should be specified as part of the body + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: Allows to retrieve a large numbers of results from a single search request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/scroll/#path-and-http-methods + parameters: + - $ref: '#/components/parameters/scroll___path.scroll_id' + - $ref: '#/components/parameters/scroll___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/scroll___query.scroll' + - $ref: '#/components/parameters/scroll___query.scroll_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/scroll' + responses: + '200': + $ref: '#/components/responses/scroll___200' + post: + operationId: scroll.3 + x-operation-group: scroll + deprecated: true + x-deprecation-message: A scroll id can be quite large and should be specified as part of the body + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: Allows to retrieve a large numbers of results from a single search request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/scroll/#path-and-http-methods + parameters: + - $ref: '#/components/parameters/scroll___path.scroll_id' + - $ref: '#/components/parameters/scroll___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/scroll___query.scroll' + - $ref: '#/components/parameters/scroll___query.scroll_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/scroll' + responses: + '200': + $ref: '#/components/responses/scroll___200' + /_search/template: + get: + operationId: search_template.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: search_template + x-version-added: '1.0' + description: Allows to use the Mustache language to pre-render a search definition. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/search_template___query.allow_no_indices' + - $ref: '#/components/parameters/search_template___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/search_template___query.expand_wildcards' + - $ref: '#/components/parameters/search_template___query.explain' + - $ref: '#/components/parameters/search_template___query.ignore_throttled' + - $ref: '#/components/parameters/search_template___query.ignore_unavailable' + - $ref: '#/components/parameters/search_template___query.phase_took' + - $ref: '#/components/parameters/search_template___query.preference' + - $ref: '#/components/parameters/search_template___query.profile' + - $ref: '#/components/parameters/search_template___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/search_template___query.routing' + - $ref: '#/components/parameters/search_template___query.scroll' + - $ref: '#/components/parameters/search_template___query.search_pipeline' + - $ref: '#/components/parameters/search_template___query.search_type' + - $ref: '#/components/parameters/search_template___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_template' + responses: + '200': + $ref: '#/components/responses/search_template___200' + post: + operationId: search_template.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: search_template + x-version-added: '1.0' + description: Allows to use the Mustache language to pre-render a search definition. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/search_template___query.allow_no_indices' + - $ref: '#/components/parameters/search_template___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/search_template___query.expand_wildcards' + - $ref: '#/components/parameters/search_template___query.explain' + - $ref: '#/components/parameters/search_template___query.ignore_throttled' + - $ref: '#/components/parameters/search_template___query.ignore_unavailable' + - $ref: '#/components/parameters/search_template___query.phase_took' + - $ref: '#/components/parameters/search_template___query.preference' + - $ref: '#/components/parameters/search_template___query.profile' + - $ref: '#/components/parameters/search_template___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/search_template___query.routing' + - $ref: '#/components/parameters/search_template___query.scroll' + - $ref: '#/components/parameters/search_template___query.search_pipeline' + - $ref: '#/components/parameters/search_template___query.search_type' + - $ref: '#/components/parameters/search_template___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_template' + responses: + '200': + $ref: '#/components/responses/search_template___200' + /_segments: + get: + operationId: indices.segments.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.segments + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Provides low-level information about segments in a Lucene index. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.segments___query.allow_no_indices' + - $ref: '#/components/parameters/indices.segments___query.expand_wildcards' + - $ref: '#/components/parameters/indices.segments___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.segments___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.segments___200' + /_settings: + get: + operationId: indices.get_settings.0 + x-operation-group: indices.get_settings + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns settings for one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/get-settings/ + parameters: + - $ref: '#/components/parameters/indices.get_settings___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_settings___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_settings___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_settings___query.flat_settings' + - $ref: '#/components/parameters/indices.get_settings___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_settings___query.include_defaults' + - $ref: '#/components/parameters/indices.get_settings___query.local' + - $ref: '#/components/parameters/indices.get_settings___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_settings___200' + put: + operationId: indices.put_settings.0 + x-operation-group: indices.put_settings + x-version-added: '1.0' + description: Updates the index settings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-settings/ + parameters: + - $ref: '#/components/parameters/indices.put_settings___query.allow_no_indices' + - $ref: '#/components/parameters/indices.put_settings___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_settings___query.expand_wildcards' + - $ref: '#/components/parameters/indices.put_settings___query.flat_settings' + - $ref: '#/components/parameters/indices.put_settings___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.put_settings___query.master_timeout' + - $ref: '#/components/parameters/indices.put_settings___query.preserve_existing' + - $ref: '#/components/parameters/indices.put_settings___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_settings' + responses: + '200': + $ref: '#/components/responses/indices.put_settings___200' + /_settings/{name}: + get: + operationId: indices.get_settings.1 + x-operation-group: indices.get_settings + x-version-added: '1.0' + description: Returns settings for one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/get-settings/ + parameters: + - $ref: '#/components/parameters/indices.get_settings___path.name' + - $ref: '#/components/parameters/indices.get_settings___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_settings___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_settings___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_settings___query.flat_settings' + - $ref: '#/components/parameters/indices.get_settings___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_settings___query.include_defaults' + - $ref: '#/components/parameters/indices.get_settings___query.local' + - $ref: '#/components/parameters/indices.get_settings___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_settings___200' + /_shard_stores: + get: + operationId: indices.shard_stores.0 + x-operation-group: indices.shard_stores + x-version-added: '1.0' + description: Provides store information for shard copies of indexes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.shard_stores___query.allow_no_indices' + - $ref: '#/components/parameters/indices.shard_stores___query.expand_wildcards' + - $ref: '#/components/parameters/indices.shard_stores___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.shard_stores___query.status' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.shard_stores___200' + /_snapshot: + get: + operationId: snapshot.get_repository.0 + x-operation-group: snapshot.get_repository + x-version-added: '1.0' + description: Returns information about a snapshot repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/get-snapshot-repository/ + parameters: + - $ref: '#/components/parameters/snapshot.get_repository___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.get_repository___query.local' + - $ref: '#/components/parameters/snapshot.get_repository___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.get_repository___200' + /_snapshot/_status: + get: + operationId: snapshot.status.0 + x-operation-group: snapshot.status + x-version-added: '1.0' + description: Returns information about the status of a snapshot. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/get-snapshot-status/ + parameters: + - $ref: '#/components/parameters/snapshot.status___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.status___query.ignore_unavailable' + - $ref: '#/components/parameters/snapshot.status___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.status___200' + /_snapshot/{repository}: + delete: + operationId: snapshot.delete_repository.0 + x-operation-group: snapshot.delete_repository + x-version-added: '1.0' + description: Deletes a snapshot repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/delete-snapshot-repository/ + parameters: + - $ref: '#/components/parameters/snapshot.delete_repository___path.repository' + - $ref: '#/components/parameters/snapshot.delete_repository___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.delete_repository___query.master_timeout' + - $ref: '#/components/parameters/snapshot.delete_repository___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.delete_repository___200' + get: + operationId: snapshot.get_repository.1 + x-operation-group: snapshot.get_repository + x-version-added: '1.0' + description: Returns information about a snapshot repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/get-snapshot-repository/ + parameters: + - $ref: '#/components/parameters/snapshot.get_repository___path.repository' + - $ref: '#/components/parameters/snapshot.get_repository___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.get_repository___query.local' + - $ref: '#/components/parameters/snapshot.get_repository___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.get_repository___200' + post: + operationId: snapshot.create_repository.0 + x-operation-group: snapshot.create_repository + x-version-added: '1.0' + description: Creates a snapshot repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/create-repository/ + parameters: + - $ref: '#/components/parameters/snapshot.create_repository___path.repository' + - $ref: '#/components/parameters/snapshot.create_repository___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.create_repository___query.master_timeout' + - $ref: '#/components/parameters/snapshot.create_repository___query.timeout' + - $ref: '#/components/parameters/snapshot.create_repository___query.verify' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/snapshot.create_repository' + responses: + '200': + $ref: '#/components/responses/snapshot.create_repository___200' + put: + operationId: snapshot.create_repository.1 + x-operation-group: snapshot.create_repository + x-version-added: '1.0' + description: Creates a snapshot repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/create-repository/ + parameters: + - $ref: '#/components/parameters/snapshot.create_repository___path.repository' + - $ref: '#/components/parameters/snapshot.create_repository___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.create_repository___query.master_timeout' + - $ref: '#/components/parameters/snapshot.create_repository___query.timeout' + - $ref: '#/components/parameters/snapshot.create_repository___query.verify' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/snapshot.create_repository' + responses: + '200': + $ref: '#/components/responses/snapshot.create_repository___200' + /_snapshot/{repository}/_cleanup: + post: + operationId: snapshot.cleanup_repository.0 + x-operation-group: snapshot.cleanup_repository + x-version-added: '1.0' + description: Removes any stale data from a snapshot repository. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/snapshot.cleanup_repository___path.repository' + - $ref: '#/components/parameters/snapshot.cleanup_repository___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.cleanup_repository___query.master_timeout' + - $ref: '#/components/parameters/snapshot.cleanup_repository___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.cleanup_repository___200' + /_snapshot/{repository}/_status: + get: + operationId: snapshot.status.1 + x-operation-group: snapshot.status + x-version-added: '1.0' + description: Returns information about the status of a snapshot. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/get-snapshot-status/ + parameters: + - $ref: '#/components/parameters/snapshot.status___path.repository' + - $ref: '#/components/parameters/snapshot.status___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.status___query.ignore_unavailable' + - $ref: '#/components/parameters/snapshot.status___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.status___200' + /_snapshot/{repository}/_verify: + post: + operationId: snapshot.verify_repository.0 + x-operation-group: snapshot.verify_repository + x-version-added: '1.0' + description: Verifies a repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/verify-snapshot-repository/ + parameters: + - $ref: '#/components/parameters/snapshot.verify_repository___path.repository' + - $ref: '#/components/parameters/snapshot.verify_repository___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.verify_repository___query.master_timeout' + - $ref: '#/components/parameters/snapshot.verify_repository___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.verify_repository___200' + /_snapshot/{repository}/{snapshot}: + delete: + operationId: snapshot.delete.0 + x-operation-group: snapshot.delete + x-version-added: '1.0' + description: Deletes a snapshot. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/delete-snapshot/ + parameters: + - $ref: '#/components/parameters/snapshot.delete___path.repository' + - $ref: '#/components/parameters/snapshot.delete___path.snapshot' + - $ref: '#/components/parameters/snapshot.delete___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.delete___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.delete___200' + get: + operationId: snapshot.get.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SnapshotGetShardFailures' + x-operation-group: snapshot.get + x-version-added: '1.0' + description: Returns information about a snapshot. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/snapshot.get___path.repository' + - $ref: '#/components/parameters/snapshot.get___path.snapshot' + - $ref: '#/components/parameters/snapshot.get___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.get___query.ignore_unavailable' + - $ref: '#/components/parameters/snapshot.get___query.master_timeout' + - $ref: '#/components/parameters/snapshot.get___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.get___200' + post: + operationId: snapshot.create.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SnapshotCreateShardFailures' + x-operation-group: snapshot.create + x-version-added: '1.0' + description: Creates a snapshot within an existing repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/create-snapshot/ + parameters: + - $ref: '#/components/parameters/snapshot.create___path.repository' + - $ref: '#/components/parameters/snapshot.create___path.snapshot' + - $ref: '#/components/parameters/snapshot.create___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.create___query.master_timeout' + - $ref: '#/components/parameters/snapshot.create___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/snapshot.create' + responses: + '200': + $ref: '#/components/responses/snapshot.create___200' + put: + operationId: snapshot.create.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SnapshotCreateShardFailures' + x-operation-group: snapshot.create + x-version-added: '1.0' + description: Creates a snapshot within an existing repository. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/create-snapshot/ + parameters: + - $ref: '#/components/parameters/snapshot.create___path.repository' + - $ref: '#/components/parameters/snapshot.create___path.snapshot' + - $ref: '#/components/parameters/snapshot.create___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.create___query.master_timeout' + - $ref: '#/components/parameters/snapshot.create___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/snapshot.create' + responses: + '200': + $ref: '#/components/responses/snapshot.create___200' + /_snapshot/{repository}/{snapshot}/_clone/{target_snapshot}: + put: + operationId: snapshot.clone.0 + x-operation-group: snapshot.clone + x-version-added: '1.0' + description: Creates a clone of all or part of a snapshot in the same repository as the original snapshot. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/snapshot.clone___path.repository' + - $ref: '#/components/parameters/snapshot.clone___path.snapshot' + - $ref: '#/components/parameters/snapshot.clone___path.target_snapshot' + - $ref: '#/components/parameters/snapshot.clone___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.clone___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/snapshot.clone' + responses: + '200': + $ref: '#/components/responses/snapshot.clone___200' + /_snapshot/{repository}/{snapshot}/_restore: + post: + operationId: snapshot.restore.0 + x-operation-group: snapshot.restore + x-version-added: '1.0' + description: Restores a snapshot. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/restore-snapshot/ + parameters: + - $ref: '#/components/parameters/snapshot.restore___path.repository' + - $ref: '#/components/parameters/snapshot.restore___path.snapshot' + - $ref: '#/components/parameters/snapshot.restore___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.restore___query.master_timeout' + - $ref: '#/components/parameters/snapshot.restore___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/snapshot.restore' + responses: + '200': + $ref: '#/components/responses/snapshot.restore___200' + /_snapshot/{repository}/{snapshot}/_status: + get: + operationId: snapshot.status.2 + x-operation-group: snapshot.status + x-version-added: '1.0' + description: Returns information about the status of a snapshot. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/snapshots/get-snapshot-status/ + parameters: + - $ref: '#/components/parameters/snapshot.status___path.repository' + - $ref: '#/components/parameters/snapshot.status___path.snapshot' + - $ref: '#/components/parameters/snapshot.status___query.cluster_manager_timeout' + - $ref: '#/components/parameters/snapshot.status___query.ignore_unavailable' + - $ref: '#/components/parameters/snapshot.status___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/snapshot.status___200' + /_stats: + get: + operationId: indices.stats.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.stats + x-version-added: '1.0' + description: Provides statistics on operations happening in an index. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.stats___query.completion_fields' + - $ref: '#/components/parameters/indices.stats___query.expand_wildcards' + - $ref: '#/components/parameters/indices.stats___query.fielddata_fields' + - $ref: '#/components/parameters/indices.stats___query.fields' + - $ref: '#/components/parameters/indices.stats___query.forbid_closed_indices' + - $ref: '#/components/parameters/indices.stats___query.groups' + - $ref: '#/components/parameters/indices.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/indices.stats___query.include_unloaded_segments' + - $ref: '#/components/parameters/indices.stats___query.level' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.stats___200' + /_stats/{metric}: + get: + operationId: indices.stats.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.stats + x-version-added: '1.0' + description: Provides statistics on operations happening in an index. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.stats___path.metric' + - $ref: '#/components/parameters/indices.stats___query.completion_fields' + - $ref: '#/components/parameters/indices.stats___query.expand_wildcards' + - $ref: '#/components/parameters/indices.stats___query.fielddata_fields' + - $ref: '#/components/parameters/indices.stats___query.fields' + - $ref: '#/components/parameters/indices.stats___query.forbid_closed_indices' + - $ref: '#/components/parameters/indices.stats___query.groups' + - $ref: '#/components/parameters/indices.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/indices.stats___query.include_unloaded_segments' + - $ref: '#/components/parameters/indices.stats___query.level' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.stats___200' + /_tasks: + get: + operationId: tasks.list.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___TaskFailures' + x-operation-group: tasks.list + x-version-added: '1.0' + description: Returns a list of tasks. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/tasks/ + parameters: + - $ref: '#/components/parameters/tasks.list___query.actions' + - $ref: '#/components/parameters/tasks.list___query.detailed' + - $ref: '#/components/parameters/tasks.list___query.group_by' + - $ref: '#/components/parameters/tasks.list___query.nodes' + - $ref: '#/components/parameters/tasks.list___query.parent_task_id' + - $ref: '#/components/parameters/tasks.list___query.timeout' + - $ref: '#/components/parameters/tasks.list___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/tasks.list___200' + /_tasks/_cancel: + post: + operationId: tasks.cancel.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___TaskFailures' + x-operation-group: tasks.cancel + x-version-added: '1.0' + description: Cancels a task, if it can be cancelled through an API. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/tasks/#task-canceling + parameters: + - $ref: '#/components/parameters/tasks.cancel___query.actions' + - $ref: '#/components/parameters/tasks.cancel___query.nodes' + - $ref: '#/components/parameters/tasks.cancel___query.parent_task_id' + - $ref: '#/components/parameters/tasks.cancel___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/tasks.cancel___200' + /_tasks/{task_id}: + get: + operationId: tasks.get.0 + x-operation-group: tasks.get + x-version-added: '1.0' + description: Returns information about a task. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/tasks/ + parameters: + - $ref: '#/components/parameters/tasks.get___path.task_id' + - $ref: '#/components/parameters/tasks.get___query.timeout' + - $ref: '#/components/parameters/tasks.get___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/tasks.get___200' + /_tasks/{task_id}/_cancel: + post: + operationId: tasks.cancel.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___TaskFailures' + x-operation-group: tasks.cancel + x-version-added: '1.0' + description: Cancels a task, if it can be cancelled through an API. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/tasks/#task-canceling + parameters: + - $ref: '#/components/parameters/tasks.cancel___path.task_id' + - $ref: '#/components/parameters/tasks.cancel___query.actions' + - $ref: '#/components/parameters/tasks.cancel___query.nodes' + - $ref: '#/components/parameters/tasks.cancel___query.parent_task_id' + - $ref: '#/components/parameters/tasks.cancel___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/tasks.cancel___200' + /_template: + get: + operationId: indices.get_template.0 + x-operation-group: indices.get_template + x-version-added: '1.0' + description: Returns an index template. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.get_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_template___query.flat_settings' + - $ref: '#/components/parameters/indices.get_template___query.local' + - $ref: '#/components/parameters/indices.get_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_template___200' + /_template/{name}: + delete: + operationId: indices.delete_template.0 + x-operation-group: indices.delete_template + x-version-added: '1.0' + description: Deletes an index template. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.delete_template___path.name' + - $ref: '#/components/parameters/indices.delete_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.delete_template___query.master_timeout' + - $ref: '#/components/parameters/indices.delete_template___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.delete_template___200' + get: + operationId: indices.get_template.1 + x-operation-group: indices.get_template + x-version-added: '1.0' + description: Returns an index template. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.get_template___path.name' + - $ref: '#/components/parameters/indices.get_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_template___query.flat_settings' + - $ref: '#/components/parameters/indices.get_template___query.local' + - $ref: '#/components/parameters/indices.get_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_template___200' + head: + operationId: indices.exists_template.0 + x-operation-group: indices.exists_template + x-version-added: '1.0' + description: Returns information about whether a particular index template exists. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.exists_template___path.name' + - $ref: '#/components/parameters/indices.exists_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.exists_template___query.flat_settings' + - $ref: '#/components/parameters/indices.exists_template___query.local' + - $ref: '#/components/parameters/indices.exists_template___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.exists_template___200' + post: + operationId: indices.put_template.0 + x-operation-group: indices.put_template + x-version-added: '1.0' + description: Creates or updates an index template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/ + parameters: + - $ref: '#/components/parameters/indices.put_template___path.name' + - $ref: '#/components/parameters/indices.put_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_template___query.create' + - $ref: '#/components/parameters/indices.put_template___query.master_timeout' + - $ref: '#/components/parameters/indices.put_template___query.order' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_template' + responses: + '200': + $ref: '#/components/responses/indices.put_template___200' + put: + operationId: indices.put_template.1 + x-operation-group: indices.put_template + x-version-added: '1.0' + description: Creates or updates an index template. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-templates/ + parameters: + - $ref: '#/components/parameters/indices.put_template___path.name' + - $ref: '#/components/parameters/indices.put_template___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_template___query.create' + - $ref: '#/components/parameters/indices.put_template___query.master_timeout' + - $ref: '#/components/parameters/indices.put_template___query.order' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_template' + responses: + '200': + $ref: '#/components/responses/indices.put_template___200' + /_update_by_query/{task_id}/_rethrottle: + post: + operationId: update_by_query_rethrottle.0 + x-operation-group: update_by_query_rethrottle + x-version-added: '1.0' + description: Changes the number of requests per second for a particular Update By Query operation. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/update_by_query_rethrottle___path.task_id' + - $ref: '#/components/parameters/update_by_query_rethrottle___query.requests_per_second' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/update_by_query_rethrottle___200' + /_upgrade: + get: + operationId: indices.get_upgrade.0 + x-operation-group: indices.get_upgrade + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: The `_upgrade` API is no longer useful and will be removed. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.get_upgrade___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_upgrade___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_upgrade___query.ignore_unavailable' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_upgrade___200' + post: + operationId: indices.upgrade.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.upgrade + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: The `_upgrade` API is no longer useful and will be removed. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.upgrade___query.allow_no_indices' + - $ref: '#/components/parameters/indices.upgrade___query.expand_wildcards' + - $ref: '#/components/parameters/indices.upgrade___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.upgrade___query.only_ancient_segments' + - $ref: '#/components/parameters/indices.upgrade___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.upgrade___200' + /_validate/query: + get: + operationId: indices.validate_query.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.validate_query + x-version-added: '1.0' + description: Allows a user to validate a potentially expensive query without executing it. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.validate_query___query.all_shards' + - $ref: '#/components/parameters/indices.validate_query___query.allow_no_indices' + - $ref: '#/components/parameters/indices.validate_query___query.analyze_wildcard' + - $ref: '#/components/parameters/indices.validate_query___query.analyzer' + - $ref: '#/components/parameters/indices.validate_query___query.default_operator' + - $ref: '#/components/parameters/indices.validate_query___query.df' + - $ref: '#/components/parameters/indices.validate_query___query.expand_wildcards' + - $ref: '#/components/parameters/indices.validate_query___query.explain' + - $ref: '#/components/parameters/indices.validate_query___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.validate_query___query.lenient' + - $ref: '#/components/parameters/indices.validate_query___query.q' + - $ref: '#/components/parameters/indices.validate_query___query.rewrite' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.validate_query' + responses: + '200': + $ref: '#/components/responses/indices.validate_query___200' + post: + operationId: indices.validate_query.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.validate_query + x-version-added: '1.0' + description: Allows a user to validate a potentially expensive query without executing it. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.validate_query___query.all_shards' + - $ref: '#/components/parameters/indices.validate_query___query.allow_no_indices' + - $ref: '#/components/parameters/indices.validate_query___query.analyze_wildcard' + - $ref: '#/components/parameters/indices.validate_query___query.analyzer' + - $ref: '#/components/parameters/indices.validate_query___query.default_operator' + - $ref: '#/components/parameters/indices.validate_query___query.df' + - $ref: '#/components/parameters/indices.validate_query___query.expand_wildcards' + - $ref: '#/components/parameters/indices.validate_query___query.explain' + - $ref: '#/components/parameters/indices.validate_query___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.validate_query___query.lenient' + - $ref: '#/components/parameters/indices.validate_query___query.q' + - $ref: '#/components/parameters/indices.validate_query___query.rewrite' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.validate_query' + responses: + '200': + $ref: '#/components/responses/indices.validate_query___200' + /_wlm/query_group: + get: + operationId: wlm.get_query_group.0 + x-operation-group: wlm.get_query_group + x-version-added: '2.17' + description: Retrieves the specified query group. If no query group is specified, all query groups in the cluster are retrieved. + responses: + '200': + $ref: '#/components/responses/wlm.get_query_group___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + put: + operationId: wlm.create_query_group.0 + x-operation-group: wlm.create_query_group + x-version-added: '2.17' + description: Creates a new query group and sets the resource limits for the new query group. + requestBody: + $ref: '#/components/requestBodies/wlm.create_query_group' + responses: + '200': + $ref: '#/components/responses/wlm.create_query_group___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + /_wlm/query_group/{name}: + delete: + operationId: wlm.delete_query_group.0 + x-operation-group: wlm.delete_query_group + x-version-added: '2.17' + description: Deletes the specified query group. + parameters: + - $ref: '#/components/parameters/wlm.delete_query_group___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/wlm.delete_query_group___200' + get: + operationId: wlm.get_query_group.1 + x-operation-group: wlm.get_query_group + x-version-added: '2.17' + description: Retrieves the specified query group. If no query group is specified, all query groups in the cluster are retrieved. + parameters: + - $ref: '#/components/parameters/wlm.get_query_group___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/wlm.get_query_group___200' + put: + operationId: wlm.update_query_group.0 + x-operation-group: wlm.update_query_group + x-version-added: '2.17' + description: Updates the specified query group. + parameters: + - $ref: '#/components/parameters/wlm.update_query_group___path.name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/wlm.update_query_group' + responses: + '200': + $ref: '#/components/responses/wlm.update_query_group___200' + /{alias}/_rollover: + post: + operationId: indices.rollover.0 + x-operation-group: indices.rollover + x-version-added: '1.0' + description: |- + Updates an alias to point to a new index when the existing index + is considered to be too large or too old. + externalDocs: + url: https://opensearch.org/docs/latest/dashboards/im-dashboards/rollover/ + parameters: + - $ref: '#/components/parameters/indices.rollover___path.alias' + - $ref: '#/components/parameters/indices.rollover___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.rollover___query.dry_run' + - $ref: '#/components/parameters/indices.rollover___query.master_timeout' + - $ref: '#/components/parameters/indices.rollover___query.timeout' + - $ref: '#/components/parameters/indices.rollover___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.rollover' + responses: + '200': + $ref: '#/components/responses/indices.rollover___200' + /{alias}/_rollover/{new_index}: + post: + operationId: indices.rollover.1 + x-operation-group: indices.rollover + x-version-added: '1.0' + description: |- + Updates an alias to point to a new index when the existing index + is considered to be too large or too old. + externalDocs: + url: https://opensearch.org/docs/latest/dashboards/im-dashboards/rollover/ + parameters: + - $ref: '#/components/parameters/indices.rollover___path.alias' + - $ref: '#/components/parameters/indices.rollover___path.new_index' + - $ref: '#/components/parameters/indices.rollover___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.rollover___query.dry_run' + - $ref: '#/components/parameters/indices.rollover___query.master_timeout' + - $ref: '#/components/parameters/indices.rollover___query.timeout' + - $ref: '#/components/parameters/indices.rollover___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.rollover' + responses: + '200': + $ref: '#/components/responses/indices.rollover___200' + /{index}: + delete: + operationId: indices.delete.0 + x-operation-group: indices.delete + x-version-added: '1.0' + description: Deletes an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/delete-index/ + parameters: + - $ref: '#/components/parameters/indices.delete___path.index' + - $ref: '#/components/parameters/indices.delete___query.allow_no_indices' + - $ref: '#/components/parameters/indices.delete___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.delete___query.expand_wildcards' + - $ref: '#/components/parameters/indices.delete___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.delete___query.master_timeout' + - $ref: '#/components/parameters/indices.delete___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.delete___200' + '404': + $ref: '#/components/responses/indices.delete___404' + get: + operationId: indices.get.0 + x-operation-group: indices.get + x-version-added: '1.0' + description: Returns information about one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/get-index/ + parameters: + - $ref: '#/components/parameters/indices.get___path.index' + - $ref: '#/components/parameters/indices.get___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get___query.flat_settings' + - $ref: '#/components/parameters/indices.get___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get___query.include_defaults' + - $ref: '#/components/parameters/indices.get___query.local' + - $ref: '#/components/parameters/indices.get___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get___200' + head: + operationId: indices.exists.0 + x-operation-group: indices.exists + x-version-added: '1.0' + description: Returns information about whether a particular index exists. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/exists/ + parameters: + - $ref: '#/components/parameters/indices.exists___path.index' + - $ref: '#/components/parameters/indices.exists___query.allow_no_indices' + - $ref: '#/components/parameters/indices.exists___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.exists___query.expand_wildcards' + - $ref: '#/components/parameters/indices.exists___query.flat_settings' + - $ref: '#/components/parameters/indices.exists___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.exists___query.include_defaults' + - $ref: '#/components/parameters/indices.exists___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.exists___200' + '404': + $ref: '#/components/responses/indices.exists___404' + put: + operationId: indices.create.0 + x-operation-group: indices.create + x-version-added: '1.0' + description: Creates an index with optional settings and mappings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/create-index/ + parameters: + - $ref: '#/components/parameters/indices.create___path.index' + - $ref: '#/components/parameters/indices.create___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.create___query.master_timeout' + - $ref: '#/components/parameters/indices.create___query.timeout' + - $ref: '#/components/parameters/indices.create___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.create' + responses: + '200': + $ref: '#/components/responses/indices.create___200' + '400': + $ref: '#/components/responses/indices.create___400' + '500': + $ref: '#/components/responses/indices.create___500' + /{index}/_alias: + get: + operationId: indices.get_alias.2 + x-operation-group: indices.get_alias + x-version-added: '1.0' + description: Returns an alias. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-alias/ + parameters: + - $ref: '#/components/parameters/indices.get_alias___path.index' + - $ref: '#/components/parameters/indices.get_alias___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_alias___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_alias___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_alias___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_alias___200' + '404': + $ref: '#/components/responses/indices.get_alias___404' + put: + operationId: indices.put_alias.5 + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.index' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + /{index}/_alias/{name}: + delete: + operationId: indices.delete_alias.0 + x-operation-group: indices.delete_alias + x-version-added: '1.0' + description: Deletes an alias. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-alias/#delete-aliases + parameters: + - $ref: '#/components/parameters/indices.delete_alias___path.index' + - $ref: '#/components/parameters/indices.delete_alias___path.name' + - $ref: '#/components/parameters/indices.delete_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.delete_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.delete_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.delete_alias___200' + get: + operationId: indices.get_alias.3 + x-operation-group: indices.get_alias + x-version-added: '1.0' + description: Returns an alias. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-alias/ + parameters: + - $ref: '#/components/parameters/indices.get_alias___path.index' + - $ref: '#/components/parameters/indices.get_alias___path.name' + - $ref: '#/components/parameters/indices.get_alias___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_alias___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_alias___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_alias___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_alias___200' + '404': + $ref: '#/components/responses/indices.get_alias___404' + head: + operationId: indices.exists_alias.1 + x-operation-group: indices.exists_alias + x-version-added: '1.0' + description: Returns information about whether a particular alias exists. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.exists_alias___path.index' + - $ref: '#/components/parameters/indices.exists_alias___path.name' + - $ref: '#/components/parameters/indices.exists_alias___query.allow_no_indices' + - $ref: '#/components/parameters/indices.exists_alias___query.expand_wildcards' + - $ref: '#/components/parameters/indices.exists_alias___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.exists_alias___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.exists_alias___200' + '404': + $ref: '#/components/responses/indices.exists_alias___404' + post: + operationId: indices.put_alias.6 + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.index' + - $ref: '#/components/parameters/indices.put_alias___path.name' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + put: + operationId: indices.put_alias.7 + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.index' + - $ref: '#/components/parameters/indices.put_alias___path.name' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + /{index}/_aliases: + put: + operationId: indices.put_alias.8 + deprecated: true + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.index' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + /{index}/_aliases/{name}: + delete: + operationId: indices.delete_alias.1 + deprecated: true + x-operation-group: indices.delete_alias + x-version-added: '1.0' + description: Deletes an alias. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-alias/#delete-aliases + parameters: + - $ref: '#/components/parameters/indices.delete_alias___path.index' + - $ref: '#/components/parameters/indices.delete_alias___path.name' + - $ref: '#/components/parameters/indices.delete_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.delete_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.delete_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.delete_alias___200' + post: + operationId: indices.put_alias.9 + deprecated: true + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.index' + - $ref: '#/components/parameters/indices.put_alias___path.name' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + put: + operationId: indices.put_alias.10 + deprecated: true + x-operation-group: indices.put_alias + x-version-added: '1.0' + description: Creates or updates an alias. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-alias/ + parameters: + - $ref: '#/components/parameters/indices.put_alias___path.index' + - $ref: '#/components/parameters/indices.put_alias___path.name' + - $ref: '#/components/parameters/indices.put_alias___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.master_timeout' + - $ref: '#/components/parameters/indices.put_alias___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_alias' + responses: + '200': + $ref: '#/components/responses/indices.put_alias___200' + /{index}/_analyze: + get: + operationId: indices.analyze.2 + x-operation-group: indices.analyze + x-version-added: '1.0' + description: Performs the analysis process on a text and return the tokens breakdown of the text. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/analyze-apis/perform-text-analysis/ + parameters: + - $ref: '#/components/parameters/indices.analyze___path.index' + - $ref: '#/components/parameters/indices.analyze___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.analyze' + responses: + '200': + $ref: '#/components/responses/indices.analyze___200' + post: + operationId: indices.analyze.3 + x-operation-group: indices.analyze + x-version-added: '1.0' + description: Performs the analysis process on a text and return the tokens breakdown of the text. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/analyze-apis/perform-text-analysis/ + parameters: + - $ref: '#/components/parameters/indices.analyze___path.index' + - $ref: '#/components/parameters/indices.analyze___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.analyze' + responses: + '200': + $ref: '#/components/responses/indices.analyze___200' + /{index}/_block/{block}: + put: + operationId: indices.add_block.0 + x-operation-group: indices.add_block + x-version-added: '1.0' + description: Adds a block to an index. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.add_block___path.block' + - $ref: '#/components/parameters/indices.add_block___path.index' + - $ref: '#/components/parameters/indices.add_block___query.allow_no_indices' + - $ref: '#/components/parameters/indices.add_block___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.add_block___query.expand_wildcards' + - $ref: '#/components/parameters/indices.add_block___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.add_block___query.master_timeout' + - $ref: '#/components/parameters/indices.add_block___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.add_block___200' + /{index}/_bulk: + post: + operationId: bulk.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkItems' + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: bulk + x-version-added: '1.0' + description: Allows to perform multiple index/update/delete operations in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/bulk/ + parameters: + - $ref: '#/components/parameters/bulk___path.index' + - $ref: '#/components/parameters/bulk___query._source' + - $ref: '#/components/parameters/bulk___query._source_excludes' + - $ref: '#/components/parameters/bulk___query._source_includes' + - $ref: '#/components/parameters/bulk___query.index' + - $ref: '#/components/parameters/bulk___query.pipeline' + - $ref: '#/components/parameters/bulk___query.refresh' + - $ref: '#/components/parameters/bulk___query.require_alias' + - $ref: '#/components/parameters/bulk___query.routing' + - $ref: '#/components/parameters/bulk___query.timeout' + - $ref: '#/components/parameters/bulk___query.type' + - $ref: '#/components/parameters/bulk___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/bulk' + responses: + '200': + $ref: '#/components/responses/bulk___200' + put: + operationId: bulk.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkItems' + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: bulk + x-version-added: '1.0' + description: Allows to perform multiple index/update/delete operations in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/bulk/ + parameters: + - $ref: '#/components/parameters/bulk___path.index' + - $ref: '#/components/parameters/bulk___query._source' + - $ref: '#/components/parameters/bulk___query._source_excludes' + - $ref: '#/components/parameters/bulk___query._source_includes' + - $ref: '#/components/parameters/bulk___query.index' + - $ref: '#/components/parameters/bulk___query.pipeline' + - $ref: '#/components/parameters/bulk___query.refresh' + - $ref: '#/components/parameters/bulk___query.require_alias' + - $ref: '#/components/parameters/bulk___query.routing' + - $ref: '#/components/parameters/bulk___query.timeout' + - $ref: '#/components/parameters/bulk___query.type' + - $ref: '#/components/parameters/bulk___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/bulk' + responses: + '200': + $ref: '#/components/responses/bulk___200' + /{index}/_bulk/stream: + post: + operationId: bulk_stream.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkItems' + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: bulk_stream + x-version-added: '2.17' + description: Allows to perform multiple index/update/delete operations using request response streaming. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/bulk-streaming/ + parameters: + - $ref: '#/components/parameters/bulk_stream___path.index' + - $ref: '#/components/parameters/bulk_stream___query._source' + - $ref: '#/components/parameters/bulk_stream___query._source_excludes' + - $ref: '#/components/parameters/bulk_stream___query._source_includes' + - $ref: '#/components/parameters/bulk_stream___query.batch_interval' + - $ref: '#/components/parameters/bulk_stream___query.batch_size' + - $ref: '#/components/parameters/bulk_stream___query.pipeline' + - $ref: '#/components/parameters/bulk_stream___query.refresh' + - $ref: '#/components/parameters/bulk_stream___query.require_alias' + - $ref: '#/components/parameters/bulk_stream___query.routing' + - $ref: '#/components/parameters/bulk_stream___query.timeout' + - $ref: '#/components/parameters/bulk_stream___query.type' + - $ref: '#/components/parameters/bulk_stream___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/bulk_stream' + responses: + '200': + $ref: '#/components/responses/bulk_stream___200' + put: + operationId: bulk_stream.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkItems' + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: bulk_stream + x-version-added: '2.17' + description: Allows to perform multiple index/update/delete operations using request response streaming. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/bulk-streaming/ + parameters: + - $ref: '#/components/parameters/bulk_stream___path.index' + - $ref: '#/components/parameters/bulk_stream___query._source' + - $ref: '#/components/parameters/bulk_stream___query._source_excludes' + - $ref: '#/components/parameters/bulk_stream___query._source_includes' + - $ref: '#/components/parameters/bulk_stream___query.batch_interval' + - $ref: '#/components/parameters/bulk_stream___query.batch_size' + - $ref: '#/components/parameters/bulk_stream___query.pipeline' + - $ref: '#/components/parameters/bulk_stream___query.refresh' + - $ref: '#/components/parameters/bulk_stream___query.require_alias' + - $ref: '#/components/parameters/bulk_stream___query.routing' + - $ref: '#/components/parameters/bulk_stream___query.timeout' + - $ref: '#/components/parameters/bulk_stream___query.type' + - $ref: '#/components/parameters/bulk_stream___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/bulk_stream' + responses: + '200': + $ref: '#/components/responses/bulk_stream___200' + /{index}/_cache/clear: + post: + operationId: indices.clear_cache.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.clear_cache + x-version-added: '1.0' + description: Clears all or specific caches for one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/clear-index-cache/ + parameters: + - $ref: '#/components/parameters/indices.clear_cache___path.index' + - $ref: '#/components/parameters/indices.clear_cache___query.allow_no_indices' + - $ref: '#/components/parameters/indices.clear_cache___query.expand_wildcards' + - $ref: '#/components/parameters/indices.clear_cache___query.fielddata' + - $ref: '#/components/parameters/indices.clear_cache___query.fields' + - $ref: '#/components/parameters/indices.clear_cache___query.file' + - $ref: '#/components/parameters/indices.clear_cache___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.clear_cache___query.index' + - $ref: '#/components/parameters/indices.clear_cache___query.query' + - $ref: '#/components/parameters/indices.clear_cache___query.request' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.clear_cache___200' + /{index}/_clone/{target}: + post: + operationId: indices.clone.0 + x-operation-group: indices.clone + x-version-added: '1.0' + description: Clones an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/clone/ + parameters: + - $ref: '#/components/parameters/indices.clone___path.index' + - $ref: '#/components/parameters/indices.clone___path.target' + - $ref: '#/components/parameters/indices.clone___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.clone___query.master_timeout' + - $ref: '#/components/parameters/indices.clone___query.task_execution_timeout' + - $ref: '#/components/parameters/indices.clone___query.timeout' + - $ref: '#/components/parameters/indices.clone___query.wait_for_active_shards' + - $ref: '#/components/parameters/indices.clone___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.clone' + responses: + '200': + $ref: '#/components/responses/indices.clone___200' + put: + operationId: indices.clone.1 + x-operation-group: indices.clone + x-version-added: '1.0' + description: Clones an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/clone/ + parameters: + - $ref: '#/components/parameters/indices.clone___path.index' + - $ref: '#/components/parameters/indices.clone___path.target' + - $ref: '#/components/parameters/indices.clone___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.clone___query.master_timeout' + - $ref: '#/components/parameters/indices.clone___query.task_execution_timeout' + - $ref: '#/components/parameters/indices.clone___query.timeout' + - $ref: '#/components/parameters/indices.clone___query.wait_for_active_shards' + - $ref: '#/components/parameters/indices.clone___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.clone' + responses: + '200': + $ref: '#/components/responses/indices.clone___200' + /{index}/_close: + post: + operationId: indices.close.0 + x-operation-group: indices.close + x-version-added: '1.0' + description: Closes an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/close-index/ + parameters: + - $ref: '#/components/parameters/indices.close___path.index' + - $ref: '#/components/parameters/indices.close___query.allow_no_indices' + - $ref: '#/components/parameters/indices.close___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.close___query.expand_wildcards' + - $ref: '#/components/parameters/indices.close___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.close___query.master_timeout' + - $ref: '#/components/parameters/indices.close___query.timeout' + - $ref: '#/components/parameters/indices.close___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.close___200' + /{index}/_count: + get: + operationId: count.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: count + x-version-added: '1.0' + description: Returns number of documents matching a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/count/ + parameters: + - $ref: '#/components/parameters/count___path.index' + - $ref: '#/components/parameters/count___query.allow_no_indices' + - $ref: '#/components/parameters/count___query.analyze_wildcard' + - $ref: '#/components/parameters/count___query.analyzer' + - $ref: '#/components/parameters/count___query.default_operator' + - $ref: '#/components/parameters/count___query.df' + - $ref: '#/components/parameters/count___query.expand_wildcards' + - $ref: '#/components/parameters/count___query.ignore_throttled' + - $ref: '#/components/parameters/count___query.ignore_unavailable' + - $ref: '#/components/parameters/count___query.lenient' + - $ref: '#/components/parameters/count___query.min_score' + - $ref: '#/components/parameters/count___query.preference' + - $ref: '#/components/parameters/count___query.q' + - $ref: '#/components/parameters/count___query.routing' + - $ref: '#/components/parameters/count___query.terminate_after' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/count' + responses: + '200': + $ref: '#/components/responses/count___200' + post: + operationId: count.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: count + x-version-added: '1.0' + description: Returns number of documents matching a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/count/ + parameters: + - $ref: '#/components/parameters/count___path.index' + - $ref: '#/components/parameters/count___query.allow_no_indices' + - $ref: '#/components/parameters/count___query.analyze_wildcard' + - $ref: '#/components/parameters/count___query.analyzer' + - $ref: '#/components/parameters/count___query.default_operator' + - $ref: '#/components/parameters/count___query.df' + - $ref: '#/components/parameters/count___query.expand_wildcards' + - $ref: '#/components/parameters/count___query.ignore_throttled' + - $ref: '#/components/parameters/count___query.ignore_unavailable' + - $ref: '#/components/parameters/count___query.lenient' + - $ref: '#/components/parameters/count___query.min_score' + - $ref: '#/components/parameters/count___query.preference' + - $ref: '#/components/parameters/count___query.q' + - $ref: '#/components/parameters/count___query.routing' + - $ref: '#/components/parameters/count___query.terminate_after' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/count' + responses: + '200': + $ref: '#/components/responses/count___200' + /{index}/_create/{id}: + post: + operationId: create.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: create + x-version-added: '1.0' + description: |- + Creates a new document in the index. + + Returns a 409 response when a document with a same ID already exists in the index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/index-document/ + parameters: + - $ref: '#/components/parameters/create___path.id' + - $ref: '#/components/parameters/create___path.index' + - $ref: '#/components/parameters/create___query.pipeline' + - $ref: '#/components/parameters/create___query.refresh' + - $ref: '#/components/parameters/create___query.routing' + - $ref: '#/components/parameters/create___query.timeout' + - $ref: '#/components/parameters/create___query.version' + - $ref: '#/components/parameters/create___query.version_type' + - $ref: '#/components/parameters/create___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/create' + responses: + '201': + $ref: '#/components/responses/create___201' + put: + operationId: create.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: create + x-version-added: '1.0' + description: |- + Creates a new document in the index. + + Returns a 409 response when a document with a same ID already exists in the index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/index-document/ + parameters: + - $ref: '#/components/parameters/create___path.id' + - $ref: '#/components/parameters/create___path.index' + - $ref: '#/components/parameters/create___query.pipeline' + - $ref: '#/components/parameters/create___query.refresh' + - $ref: '#/components/parameters/create___query.routing' + - $ref: '#/components/parameters/create___query.timeout' + - $ref: '#/components/parameters/create___query.version' + - $ref: '#/components/parameters/create___query.version_type' + - $ref: '#/components/parameters/create___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/create' + responses: + '201': + $ref: '#/components/responses/create___201' + /{index}/_delete_by_query: + post: + operationId: delete_by_query.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkByScrollFailures' + x-operation-group: delete_by_query + x-version-added: '1.0' + description: Deletes documents matching the provided query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/delete-by-query/ + parameters: + - $ref: '#/components/parameters/delete_by_query___path.index' + - $ref: '#/components/parameters/delete_by_query___query._source' + - $ref: '#/components/parameters/delete_by_query___query._source_excludes' + - $ref: '#/components/parameters/delete_by_query___query._source_includes' + - $ref: '#/components/parameters/delete_by_query___query.allow_no_indices' + - $ref: '#/components/parameters/delete_by_query___query.analyze_wildcard' + - $ref: '#/components/parameters/delete_by_query___query.analyzer' + - $ref: '#/components/parameters/delete_by_query___query.conflicts' + - $ref: '#/components/parameters/delete_by_query___query.default_operator' + - $ref: '#/components/parameters/delete_by_query___query.df' + - $ref: '#/components/parameters/delete_by_query___query.expand_wildcards' + - $ref: '#/components/parameters/delete_by_query___query.from' + - $ref: '#/components/parameters/delete_by_query___query.ignore_unavailable' + - $ref: '#/components/parameters/delete_by_query___query.lenient' + - $ref: '#/components/parameters/delete_by_query___query.max_docs' + - $ref: '#/components/parameters/delete_by_query___query.preference' + - $ref: '#/components/parameters/delete_by_query___query.q' + - $ref: '#/components/parameters/delete_by_query___query.refresh' + - $ref: '#/components/parameters/delete_by_query___query.request_cache' + - $ref: '#/components/parameters/delete_by_query___query.requests_per_second' + - $ref: '#/components/parameters/delete_by_query___query.routing' + - $ref: '#/components/parameters/delete_by_query___query.scroll' + - $ref: '#/components/parameters/delete_by_query___query.scroll_size' + - $ref: '#/components/parameters/delete_by_query___query.search_timeout' + - $ref: '#/components/parameters/delete_by_query___query.search_type' + - $ref: '#/components/parameters/delete_by_query___query.size' + - $ref: '#/components/parameters/delete_by_query___query.slices' + - $ref: '#/components/parameters/delete_by_query___query.sort' + - $ref: '#/components/parameters/delete_by_query___query.stats' + - $ref: '#/components/parameters/delete_by_query___query.terminate_after' + - $ref: '#/components/parameters/delete_by_query___query.timeout' + - $ref: '#/components/parameters/delete_by_query___query.version' + - $ref: '#/components/parameters/delete_by_query___query.wait_for_active_shards' + - $ref: '#/components/parameters/delete_by_query___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/delete_by_query' + responses: + '200': + $ref: '#/components/responses/delete_by_query___200' + /{index}/_doc: + post: + operationId: index.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: index + x-version-added: '1.0' + description: Creates or updates a document in an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/index-document/ + parameters: + - $ref: '#/components/parameters/index___path.index' + - $ref: '#/components/parameters/index___query.if_primary_term' + - $ref: '#/components/parameters/index___query.if_seq_no' + - $ref: '#/components/parameters/index___query.op_type' + - $ref: '#/components/parameters/index___query.pipeline' + - $ref: '#/components/parameters/index___query.refresh' + - $ref: '#/components/parameters/index___query.require_alias' + - $ref: '#/components/parameters/index___query.routing' + - $ref: '#/components/parameters/index___query.timeout' + - $ref: '#/components/parameters/index___query.version' + - $ref: '#/components/parameters/index___query.version_type' + - $ref: '#/components/parameters/index___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/index' + responses: + '200': + $ref: '#/components/responses/index___200' + '201': + $ref: '#/components/responses/index___201' + /{index}/_doc/{id}: + delete: + operationId: delete.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: delete + x-version-added: '1.0' + description: Removes a document from the index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/delete-document/ + parameters: + - $ref: '#/components/parameters/delete___path.id' + - $ref: '#/components/parameters/delete___path.index' + - $ref: '#/components/parameters/delete___query.if_primary_term' + - $ref: '#/components/parameters/delete___query.if_seq_no' + - $ref: '#/components/parameters/delete___query.refresh' + - $ref: '#/components/parameters/delete___query.routing' + - $ref: '#/components/parameters/delete___query.timeout' + - $ref: '#/components/parameters/delete___query.version' + - $ref: '#/components/parameters/delete___query.version_type' + - $ref: '#/components/parameters/delete___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/delete___200' + '404': + $ref: '#/components/responses/delete___404' + get: + operationId: get.0 + x-operation-group: get + x-version-added: '1.0' + description: Returns a document. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/get-documents/ + parameters: + - $ref: '#/components/parameters/get___path.id' + - $ref: '#/components/parameters/get___path.index' + - $ref: '#/components/parameters/get___query._source' + - $ref: '#/components/parameters/get___query._source_excludes' + - $ref: '#/components/parameters/get___query._source_includes' + - $ref: '#/components/parameters/get___query.preference' + - $ref: '#/components/parameters/get___query.realtime' + - $ref: '#/components/parameters/get___query.refresh' + - $ref: '#/components/parameters/get___query.routing' + - $ref: '#/components/parameters/get___query.stored_fields' + - $ref: '#/components/parameters/get___query.version' + - $ref: '#/components/parameters/get___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/get___200' + '404': + $ref: '#/components/responses/get___404' + head: + operationId: exists.0 + x-operation-group: exists + x-version-added: '1.0' + description: Returns information about whether a document exists in an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/get-documents/ + parameters: + - $ref: '#/components/parameters/exists___path.id' + - $ref: '#/components/parameters/exists___path.index' + - $ref: '#/components/parameters/exists___query._source' + - $ref: '#/components/parameters/exists___query._source_excludes' + - $ref: '#/components/parameters/exists___query._source_includes' + - $ref: '#/components/parameters/exists___query.preference' + - $ref: '#/components/parameters/exists___query.realtime' + - $ref: '#/components/parameters/exists___query.refresh' + - $ref: '#/components/parameters/exists___query.routing' + - $ref: '#/components/parameters/exists___query.stored_fields' + - $ref: '#/components/parameters/exists___query.version' + - $ref: '#/components/parameters/exists___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/exists___200' + '404': + $ref: '#/components/responses/exists___404' + post: + operationId: index.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: index + x-version-added: '1.0' + description: Creates or updates a document in an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/index-document/ + parameters: + - $ref: '#/components/parameters/index___path.id' + - $ref: '#/components/parameters/index___path.index' + - $ref: '#/components/parameters/index___query.if_primary_term' + - $ref: '#/components/parameters/index___query.if_seq_no' + - $ref: '#/components/parameters/index___query.op_type' + - $ref: '#/components/parameters/index___query.pipeline' + - $ref: '#/components/parameters/index___query.refresh' + - $ref: '#/components/parameters/index___query.require_alias' + - $ref: '#/components/parameters/index___query.routing' + - $ref: '#/components/parameters/index___query.timeout' + - $ref: '#/components/parameters/index___query.version' + - $ref: '#/components/parameters/index___query.version_type' + - $ref: '#/components/parameters/index___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/index' + responses: + '200': + $ref: '#/components/responses/index___200' + '201': + $ref: '#/components/responses/index___201' + put: + operationId: index.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: index + x-version-added: '1.0' + description: Creates or updates a document in an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/index-document/ + parameters: + - $ref: '#/components/parameters/index___path.id' + - $ref: '#/components/parameters/index___path.index' + - $ref: '#/components/parameters/index___query.if_primary_term' + - $ref: '#/components/parameters/index___query.if_seq_no' + - $ref: '#/components/parameters/index___query.op_type' + - $ref: '#/components/parameters/index___query.pipeline' + - $ref: '#/components/parameters/index___query.refresh' + - $ref: '#/components/parameters/index___query.require_alias' + - $ref: '#/components/parameters/index___query.routing' + - $ref: '#/components/parameters/index___query.timeout' + - $ref: '#/components/parameters/index___query.version' + - $ref: '#/components/parameters/index___query.version_type' + - $ref: '#/components/parameters/index___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/index' + responses: + '200': + $ref: '#/components/responses/index___200' + '201': + $ref: '#/components/responses/index___201' + /{index}/_explain/{id}: + get: + operationId: explain.0 + x-operation-group: explain + x-version-added: '1.0' + description: Returns information about why a specific document matches (or doesn't match) a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/explain/ + parameters: + - $ref: '#/components/parameters/explain___path.id' + - $ref: '#/components/parameters/explain___path.index' + - $ref: '#/components/parameters/explain___query._source' + - $ref: '#/components/parameters/explain___query._source_excludes' + - $ref: '#/components/parameters/explain___query._source_includes' + - $ref: '#/components/parameters/explain___query.analyze_wildcard' + - $ref: '#/components/parameters/explain___query.analyzer' + - $ref: '#/components/parameters/explain___query.default_operator' + - $ref: '#/components/parameters/explain___query.df' + - $ref: '#/components/parameters/explain___query.lenient' + - $ref: '#/components/parameters/explain___query.preference' + - $ref: '#/components/parameters/explain___query.q' + - $ref: '#/components/parameters/explain___query.routing' + - $ref: '#/components/parameters/explain___query.stored_fields' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/explain' + responses: + '200': + $ref: '#/components/responses/explain___200' + post: + operationId: explain.1 + x-operation-group: explain + x-version-added: '1.0' + description: Returns information about why a specific document matches (or doesn't match) a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/explain/ + parameters: + - $ref: '#/components/parameters/explain___path.id' + - $ref: '#/components/parameters/explain___path.index' + - $ref: '#/components/parameters/explain___query._source' + - $ref: '#/components/parameters/explain___query._source_excludes' + - $ref: '#/components/parameters/explain___query._source_includes' + - $ref: '#/components/parameters/explain___query.analyze_wildcard' + - $ref: '#/components/parameters/explain___query.analyzer' + - $ref: '#/components/parameters/explain___query.default_operator' + - $ref: '#/components/parameters/explain___query.df' + - $ref: '#/components/parameters/explain___query.lenient' + - $ref: '#/components/parameters/explain___query.preference' + - $ref: '#/components/parameters/explain___query.q' + - $ref: '#/components/parameters/explain___query.routing' + - $ref: '#/components/parameters/explain___query.stored_fields' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/explain' + responses: + '200': + $ref: '#/components/responses/explain___200' + /{index}/_field_caps: + get: + operationId: field_caps.2 + x-operation-group: field_caps + x-version-added: '1.0' + description: Returns the information about the capabilities of fields among multiple indexes. + externalDocs: + url: https://opensearch.org/docs/latest/field-types/supported-field-types/alias/#using-aliases-in-field-capabilities-api-operations + parameters: + - $ref: '#/components/parameters/field_caps___path.index' + - $ref: '#/components/parameters/field_caps___query.allow_no_indices' + - $ref: '#/components/parameters/field_caps___query.expand_wildcards' + - $ref: '#/components/parameters/field_caps___query.fields' + - $ref: '#/components/parameters/field_caps___query.ignore_unavailable' + - $ref: '#/components/parameters/field_caps___query.include_unmapped' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/field_caps' + responses: + '200': + $ref: '#/components/responses/field_caps___200' + post: + operationId: field_caps.3 + x-operation-group: field_caps + x-version-added: '1.0' + description: Returns the information about the capabilities of fields among multiple indexes. + externalDocs: + url: https://opensearch.org/docs/latest/field-types/supported-field-types/alias/#using-aliases-in-field-capabilities-api-operations + parameters: + - $ref: '#/components/parameters/field_caps___path.index' + - $ref: '#/components/parameters/field_caps___query.allow_no_indices' + - $ref: '#/components/parameters/field_caps___query.expand_wildcards' + - $ref: '#/components/parameters/field_caps___query.fields' + - $ref: '#/components/parameters/field_caps___query.ignore_unavailable' + - $ref: '#/components/parameters/field_caps___query.include_unmapped' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/field_caps' + responses: + '200': + $ref: '#/components/responses/field_caps___200' + /{index}/_flush: + get: + operationId: indices.flush.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.flush + x-version-added: '1.0' + description: Performs the flush operation on one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.flush___path.index' + - $ref: '#/components/parameters/indices.flush___query.allow_no_indices' + - $ref: '#/components/parameters/indices.flush___query.expand_wildcards' + - $ref: '#/components/parameters/indices.flush___query.force' + - $ref: '#/components/parameters/indices.flush___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.flush___query.wait_if_ongoing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.flush___200' + post: + operationId: indices.flush.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.flush + x-version-added: '1.0' + description: Performs the flush operation on one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.flush___path.index' + - $ref: '#/components/parameters/indices.flush___query.allow_no_indices' + - $ref: '#/components/parameters/indices.flush___query.expand_wildcards' + - $ref: '#/components/parameters/indices.flush___query.force' + - $ref: '#/components/parameters/indices.flush___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.flush___query.wait_if_ongoing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.flush___200' + /{index}/_forcemerge: + post: + operationId: indices.forcemerge.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.forcemerge + x-version-added: '1.0' + description: Performs the force merge operation on one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.forcemerge___path.index' + - $ref: '#/components/parameters/indices.forcemerge___query.allow_no_indices' + - $ref: '#/components/parameters/indices.forcemerge___query.expand_wildcards' + - $ref: '#/components/parameters/indices.forcemerge___query.flush' + - $ref: '#/components/parameters/indices.forcemerge___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.forcemerge___query.max_num_segments' + - $ref: '#/components/parameters/indices.forcemerge___query.only_expunge_deletes' + - $ref: '#/components/parameters/indices.forcemerge___query.primary_only' + - $ref: '#/components/parameters/indices.forcemerge___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.forcemerge___200' + /{index}/_mapping: + get: + operationId: indices.get_mapping.1 + x-operation-group: indices.get_mapping + x-version-added: '1.0' + description: Returns mappings for one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/field-types/index/#get-a-mapping + parameters: + - $ref: '#/components/parameters/indices.get_mapping___path.index' + - $ref: '#/components/parameters/indices.get_mapping___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_mapping___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_mapping___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_mapping___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_mapping___query.index' + - $ref: '#/components/parameters/indices.get_mapping___query.local' + - $ref: '#/components/parameters/indices.get_mapping___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_mapping___200' + post: + operationId: indices.put_mapping.0 + x-operation-group: indices.put_mapping + x-version-added: '1.0' + description: Updates the index mappings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/put-mapping/ + parameters: + - $ref: '#/components/parameters/indices.put_mapping___path.index' + - $ref: '#/components/parameters/indices.put_mapping___query.allow_no_indices' + - $ref: '#/components/parameters/indices.put_mapping___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_mapping___query.expand_wildcards' + - $ref: '#/components/parameters/indices.put_mapping___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.put_mapping___query.master_timeout' + - $ref: '#/components/parameters/indices.put_mapping___query.timeout' + - $ref: '#/components/parameters/indices.put_mapping___query.write_index_only' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_mapping' + responses: + '200': + $ref: '#/components/responses/indices.put_mapping___200' + put: + operationId: indices.put_mapping.1 + x-operation-group: indices.put_mapping + x-version-added: '1.0' + description: Updates the index mappings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/put-mapping/ + parameters: + - $ref: '#/components/parameters/indices.put_mapping___path.index' + - $ref: '#/components/parameters/indices.put_mapping___query.allow_no_indices' + - $ref: '#/components/parameters/indices.put_mapping___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_mapping___query.expand_wildcards' + - $ref: '#/components/parameters/indices.put_mapping___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.put_mapping___query.master_timeout' + - $ref: '#/components/parameters/indices.put_mapping___query.timeout' + - $ref: '#/components/parameters/indices.put_mapping___query.write_index_only' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_mapping' + responses: + '200': + $ref: '#/components/responses/indices.put_mapping___200' + /{index}/_mapping/field/{fields}: + get: + operationId: indices.get_field_mapping.1 + x-operation-group: indices.get_field_mapping + x-version-added: '1.0' + description: Returns mapping for one or more fields. + externalDocs: + url: https://opensearch.org/docs/latest/field-types/index/ + parameters: + - $ref: '#/components/parameters/indices.get_field_mapping___path.fields' + - $ref: '#/components/parameters/indices.get_field_mapping___path.index' + - $ref: '#/components/parameters/indices.get_field_mapping___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_field_mapping___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_field_mapping___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_field_mapping___query.include_defaults' + - $ref: '#/components/parameters/indices.get_field_mapping___query.local' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_field_mapping___200' + /{index}/_mget: + get: + operationId: mget.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___MultiDocItems' + x-operation-group: mget + x-version-added: '1.0' + description: Allows to get multiple documents in one request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/multi-get/ + parameters: + - $ref: '#/components/parameters/mget___path.index' + - $ref: '#/components/parameters/mget___query._source' + - $ref: '#/components/parameters/mget___query._source_excludes' + - $ref: '#/components/parameters/mget___query._source_includes' + - $ref: '#/components/parameters/mget___query.preference' + - $ref: '#/components/parameters/mget___query.realtime' + - $ref: '#/components/parameters/mget___query.refresh' + - $ref: '#/components/parameters/mget___query.routing' + - $ref: '#/components/parameters/mget___query.stored_fields' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/mget' + responses: + '200': + $ref: '#/components/responses/mget___200' + post: + operationId: mget.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___MultiDocItems' + x-operation-group: mget + x-version-added: '1.0' + description: Allows to get multiple documents in one request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/multi-get/ + parameters: + - $ref: '#/components/parameters/mget___path.index' + - $ref: '#/components/parameters/mget___query._source' + - $ref: '#/components/parameters/mget___query._source_excludes' + - $ref: '#/components/parameters/mget___query._source_includes' + - $ref: '#/components/parameters/mget___query.preference' + - $ref: '#/components/parameters/mget___query.realtime' + - $ref: '#/components/parameters/mget___query.refresh' + - $ref: '#/components/parameters/mget___query.routing' + - $ref: '#/components/parameters/mget___query.stored_fields' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/mget' + responses: + '200': + $ref: '#/components/responses/mget___200' + /{index}/_msearch: + get: + operationId: msearch.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + - $ref: '#/components/schemas/_common.errors___MultiSearchItems' + x-operation-group: msearch + x-version-added: '1.0' + description: Allows to execute several search operations in one request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/multi-search/ + parameters: + - $ref: '#/components/parameters/msearch___path.index' + - $ref: '#/components/parameters/msearch___query.allow_partial_results' + - $ref: '#/components/parameters/msearch___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/msearch___query.max_concurrent_searches' + - $ref: '#/components/parameters/msearch___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/msearch___query.pre_filter_shard_size' + - $ref: '#/components/parameters/msearch___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/msearch___query.search_type' + - $ref: '#/components/parameters/msearch___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/msearch' + responses: + '200': + $ref: '#/components/responses/msearch___200' + post: + operationId: msearch.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + - $ref: '#/components/schemas/_common.errors___MultiSearchItems' + x-operation-group: msearch + x-version-added: '1.0' + description: Allows to execute several search operations in one request. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/multi-search/ + parameters: + - $ref: '#/components/parameters/msearch___path.index' + - $ref: '#/components/parameters/msearch___query.allow_partial_results' + - $ref: '#/components/parameters/msearch___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/msearch___query.max_concurrent_searches' + - $ref: '#/components/parameters/msearch___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/msearch___query.pre_filter_shard_size' + - $ref: '#/components/parameters/msearch___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/msearch___query.search_type' + - $ref: '#/components/parameters/msearch___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/msearch' + responses: + '200': + $ref: '#/components/responses/msearch___200' + /{index}/_msearch/template: + get: + operationId: msearch_template.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + - $ref: '#/components/schemas/_common.errors___MultiSearchItems' + x-operation-group: msearch_template + x-version-added: '1.0' + description: Allows to execute several search template operations in one request. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/msearch_template___path.index' + - $ref: '#/components/parameters/msearch_template___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/msearch_template___query.max_concurrent_searches' + - $ref: '#/components/parameters/msearch_template___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/msearch_template___query.search_type' + - $ref: '#/components/parameters/msearch_template___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/msearch_template' + responses: + '200': + $ref: '#/components/responses/msearch_template___200' + post: + operationId: msearch_template.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + - $ref: '#/components/schemas/_common.errors___MultiSearchItems' + x-operation-group: msearch_template + x-version-added: '1.0' + description: Allows to execute several search template operations in one request. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/msearch_template___path.index' + - $ref: '#/components/parameters/msearch_template___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/msearch_template___query.max_concurrent_searches' + - $ref: '#/components/parameters/msearch_template___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/msearch_template___query.search_type' + - $ref: '#/components/parameters/msearch_template___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/msearch_template' + responses: + '200': + $ref: '#/components/responses/msearch_template___200' + /{index}/_mtermvectors: + get: + operationId: mtermvectors.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___MultiDocItems' + x-operation-group: mtermvectors + x-version-added: '1.0' + description: Returns multiple termvectors in one request. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/mtermvectors___path.index' + - $ref: '#/components/parameters/mtermvectors___query.field_statistics' + - $ref: '#/components/parameters/mtermvectors___query.fields' + - $ref: '#/components/parameters/mtermvectors___query.ids' + - $ref: '#/components/parameters/mtermvectors___query.offsets' + - $ref: '#/components/parameters/mtermvectors___query.payloads' + - $ref: '#/components/parameters/mtermvectors___query.positions' + - $ref: '#/components/parameters/mtermvectors___query.preference' + - $ref: '#/components/parameters/mtermvectors___query.realtime' + - $ref: '#/components/parameters/mtermvectors___query.routing' + - $ref: '#/components/parameters/mtermvectors___query.term_statistics' + - $ref: '#/components/parameters/mtermvectors___query.version' + - $ref: '#/components/parameters/mtermvectors___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/mtermvectors' + responses: + '200': + $ref: '#/components/responses/mtermvectors___200' + post: + operationId: mtermvectors.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___MultiDocItems' + x-operation-group: mtermvectors + x-version-added: '1.0' + description: Returns multiple termvectors in one request. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/mtermvectors___path.index' + - $ref: '#/components/parameters/mtermvectors___query.field_statistics' + - $ref: '#/components/parameters/mtermvectors___query.fields' + - $ref: '#/components/parameters/mtermvectors___query.ids' + - $ref: '#/components/parameters/mtermvectors___query.offsets' + - $ref: '#/components/parameters/mtermvectors___query.payloads' + - $ref: '#/components/parameters/mtermvectors___query.positions' + - $ref: '#/components/parameters/mtermvectors___query.preference' + - $ref: '#/components/parameters/mtermvectors___query.realtime' + - $ref: '#/components/parameters/mtermvectors___query.routing' + - $ref: '#/components/parameters/mtermvectors___query.term_statistics' + - $ref: '#/components/parameters/mtermvectors___query.version' + - $ref: '#/components/parameters/mtermvectors___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/mtermvectors' + responses: + '200': + $ref: '#/components/responses/mtermvectors___200' + /{index}/_open: + post: + operationId: indices.open.0 + x-operation-group: indices.open + x-version-added: '1.0' + description: Opens an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/open-index/ + parameters: + - $ref: '#/components/parameters/indices.open___path.index' + - $ref: '#/components/parameters/indices.open___query.allow_no_indices' + - $ref: '#/components/parameters/indices.open___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.open___query.expand_wildcards' + - $ref: '#/components/parameters/indices.open___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.open___query.master_timeout' + - $ref: '#/components/parameters/indices.open___query.task_execution_timeout' + - $ref: '#/components/parameters/indices.open___query.timeout' + - $ref: '#/components/parameters/indices.open___query.wait_for_active_shards' + - $ref: '#/components/parameters/indices.open___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.open___200' + /{index}/_rank_eval: + get: + operationId: rank_eval.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___RankEvalFailures' + x-operation-group: rank_eval + x-version-added: '1.0' + description: Allows to evaluate the quality of ranked search results over a set of typical search queries. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/rank-eval/ + parameters: + - $ref: '#/components/parameters/rank_eval___path.index' + - $ref: '#/components/parameters/rank_eval___query.allow_no_indices' + - $ref: '#/components/parameters/rank_eval___query.expand_wildcards' + - $ref: '#/components/parameters/rank_eval___query.ignore_unavailable' + - $ref: '#/components/parameters/rank_eval___query.search_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/rank_eval' + responses: + '200': + $ref: '#/components/responses/rank_eval___200' + post: + operationId: rank_eval.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___RankEvalFailures' + x-operation-group: rank_eval + x-version-added: '1.0' + description: Allows to evaluate the quality of ranked search results over a set of typical search queries. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/rank-eval/ + parameters: + - $ref: '#/components/parameters/rank_eval___path.index' + - $ref: '#/components/parameters/rank_eval___query.allow_no_indices' + - $ref: '#/components/parameters/rank_eval___query.expand_wildcards' + - $ref: '#/components/parameters/rank_eval___query.ignore_unavailable' + - $ref: '#/components/parameters/rank_eval___query.search_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/rank_eval' + responses: + '200': + $ref: '#/components/responses/rank_eval___200' + /{index}/_recovery: + get: + operationId: indices.recovery.1 + x-operation-group: indices.recovery + x-version-added: '1.0' + description: Returns information about ongoing index shard recoveries. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.recovery___path.index' + - $ref: '#/components/parameters/indices.recovery___query.active_only' + - $ref: '#/components/parameters/indices.recovery___query.detailed' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.recovery___200' + /{index}/_refresh: + get: + operationId: indices.refresh.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.refresh + x-version-added: '1.0' + description: Performs the refresh operation in one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/availability-and-recovery/remote-store/index/#refresh-level-and-request-level-durability + parameters: + - $ref: '#/components/parameters/indices.refresh___path.index' + - $ref: '#/components/parameters/indices.refresh___query.allow_no_indices' + - $ref: '#/components/parameters/indices.refresh___query.expand_wildcards' + - $ref: '#/components/parameters/indices.refresh___query.ignore_unavailable' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.refresh___200' + post: + operationId: indices.refresh.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.refresh + x-version-added: '1.0' + description: Performs the refresh operation in one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/tuning-your-cluster/availability-and-recovery/remote-store/index/#refresh-level-and-request-level-durability + parameters: + - $ref: '#/components/parameters/indices.refresh___path.index' + - $ref: '#/components/parameters/indices.refresh___query.allow_no_indices' + - $ref: '#/components/parameters/indices.refresh___query.expand_wildcards' + - $ref: '#/components/parameters/indices.refresh___query.ignore_unavailable' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.refresh___200' + /{index}/_search: + get: + operationId: search.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: search + x-version-added: '1.0' + description: Returns results matching a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/search/ + parameters: + - $ref: '#/components/parameters/search___path.index' + - $ref: '#/components/parameters/search___query._source' + - $ref: '#/components/parameters/search___query._source_excludes' + - $ref: '#/components/parameters/search___query._source_includes' + - $ref: '#/components/parameters/search___query.allow_no_indices' + - $ref: '#/components/parameters/search___query.allow_partial_search_results' + - $ref: '#/components/parameters/search___query.analyze_wildcard' + - $ref: '#/components/parameters/search___query.analyzer' + - $ref: '#/components/parameters/search___query.batched_reduce_size' + - $ref: '#/components/parameters/search___query.cancel_after_time_interval' + - $ref: '#/components/parameters/search___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/search___query.default_operator' + - $ref: '#/components/parameters/search___query.df' + - $ref: '#/components/parameters/search___query.docvalue_fields' + - $ref: '#/components/parameters/search___query.expand_wildcards' + - $ref: '#/components/parameters/search___query.explain' + - $ref: '#/components/parameters/search___query.from' + - $ref: '#/components/parameters/search___query.ignore_throttled' + - $ref: '#/components/parameters/search___query.ignore_unavailable' + - $ref: '#/components/parameters/search___query.include_named_queries_score' + - $ref: '#/components/parameters/search___query.index' + - $ref: '#/components/parameters/search___query.lenient' + - $ref: '#/components/parameters/search___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/search___query.phase_took' + - $ref: '#/components/parameters/search___query.pre_filter_shard_size' + - $ref: '#/components/parameters/search___query.preference' + - $ref: '#/components/parameters/search___query.q' + - $ref: '#/components/parameters/search___query.request_cache' + - $ref: '#/components/parameters/search___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/search___query.routing' + - $ref: '#/components/parameters/search___query.scroll' + - $ref: '#/components/parameters/search___query.search_pipeline' + - $ref: '#/components/parameters/search___query.search_type' + - $ref: '#/components/parameters/search___query.seq_no_primary_term' + - $ref: '#/components/parameters/search___query.size' + - $ref: '#/components/parameters/search___query.sort' + - $ref: '#/components/parameters/search___query.stats' + - $ref: '#/components/parameters/search___query.stored_fields' + - $ref: '#/components/parameters/search___query.suggest_field' + - $ref: '#/components/parameters/search___query.suggest_mode' + - $ref: '#/components/parameters/search___query.suggest_size' + - $ref: '#/components/parameters/search___query.suggest_text' + - $ref: '#/components/parameters/search___query.terminate_after' + - $ref: '#/components/parameters/search___query.timeout' + - $ref: '#/components/parameters/search___query.track_scores' + - $ref: '#/components/parameters/search___query.track_total_hits' + - $ref: '#/components/parameters/search___query.typed_keys' + - $ref: '#/components/parameters/search___query.verbose_pipeline' + - $ref: '#/components/parameters/search___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search' + responses: + '200': + $ref: '#/components/responses/search___200' + '400': + $ref: '#/components/responses/search___400' + '404': + $ref: '#/components/responses/search___404' + post: + operationId: search.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: search + x-version-added: '1.0' + description: Returns results matching a query. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/search/ + parameters: + - $ref: '#/components/parameters/search___path.index' + - $ref: '#/components/parameters/search___query._source' + - $ref: '#/components/parameters/search___query._source_excludes' + - $ref: '#/components/parameters/search___query._source_includes' + - $ref: '#/components/parameters/search___query.allow_no_indices' + - $ref: '#/components/parameters/search___query.allow_partial_search_results' + - $ref: '#/components/parameters/search___query.analyze_wildcard' + - $ref: '#/components/parameters/search___query.analyzer' + - $ref: '#/components/parameters/search___query.batched_reduce_size' + - $ref: '#/components/parameters/search___query.cancel_after_time_interval' + - $ref: '#/components/parameters/search___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/search___query.default_operator' + - $ref: '#/components/parameters/search___query.df' + - $ref: '#/components/parameters/search___query.docvalue_fields' + - $ref: '#/components/parameters/search___query.expand_wildcards' + - $ref: '#/components/parameters/search___query.explain' + - $ref: '#/components/parameters/search___query.from' + - $ref: '#/components/parameters/search___query.ignore_throttled' + - $ref: '#/components/parameters/search___query.ignore_unavailable' + - $ref: '#/components/parameters/search___query.include_named_queries_score' + - $ref: '#/components/parameters/search___query.index' + - $ref: '#/components/parameters/search___query.lenient' + - $ref: '#/components/parameters/search___query.max_concurrent_shard_requests' + - $ref: '#/components/parameters/search___query.phase_took' + - $ref: '#/components/parameters/search___query.pre_filter_shard_size' + - $ref: '#/components/parameters/search___query.preference' + - $ref: '#/components/parameters/search___query.q' + - $ref: '#/components/parameters/search___query.request_cache' + - $ref: '#/components/parameters/search___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/search___query.routing' + - $ref: '#/components/parameters/search___query.scroll' + - $ref: '#/components/parameters/search___query.search_pipeline' + - $ref: '#/components/parameters/search___query.search_type' + - $ref: '#/components/parameters/search___query.seq_no_primary_term' + - $ref: '#/components/parameters/search___query.size' + - $ref: '#/components/parameters/search___query.sort' + - $ref: '#/components/parameters/search___query.stats' + - $ref: '#/components/parameters/search___query.stored_fields' + - $ref: '#/components/parameters/search___query.suggest_field' + - $ref: '#/components/parameters/search___query.suggest_mode' + - $ref: '#/components/parameters/search___query.suggest_size' + - $ref: '#/components/parameters/search___query.suggest_text' + - $ref: '#/components/parameters/search___query.terminate_after' + - $ref: '#/components/parameters/search___query.timeout' + - $ref: '#/components/parameters/search___query.track_scores' + - $ref: '#/components/parameters/search___query.track_total_hits' + - $ref: '#/components/parameters/search___query.typed_keys' + - $ref: '#/components/parameters/search___query.verbose_pipeline' + - $ref: '#/components/parameters/search___query.version' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search' + responses: + '200': + $ref: '#/components/responses/search___200' + '400': + $ref: '#/components/responses/search___400' + '404': + $ref: '#/components/responses/search___404' + /{index}/_search_shards: + get: + operationId: search_shards.2 + x-operation-group: search_shards + x-version-added: '1.0' + description: Returns information about the indexes and shards that a search request would be executed against. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/search_shards___path.index' + - $ref: '#/components/parameters/search_shards___query.allow_no_indices' + - $ref: '#/components/parameters/search_shards___query.expand_wildcards' + - $ref: '#/components/parameters/search_shards___query.ignore_unavailable' + - $ref: '#/components/parameters/search_shards___query.local' + - $ref: '#/components/parameters/search_shards___query.preference' + - $ref: '#/components/parameters/search_shards___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_shards' + responses: + '200': + $ref: '#/components/responses/search_shards___200' + post: + operationId: search_shards.3 + x-operation-group: search_shards + x-version-added: '1.0' + description: Returns information about the indexes and shards that a search request would be executed against. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/search_shards___path.index' + - $ref: '#/components/parameters/search_shards___query.allow_no_indices' + - $ref: '#/components/parameters/search_shards___query.expand_wildcards' + - $ref: '#/components/parameters/search_shards___query.ignore_unavailable' + - $ref: '#/components/parameters/search_shards___query.local' + - $ref: '#/components/parameters/search_shards___query.preference' + - $ref: '#/components/parameters/search_shards___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_shards' + responses: + '200': + $ref: '#/components/responses/search_shards___200' + /{index}/_search/point_in_time: + post: + operationId: create_pit.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: create_pit + x-version-added: '2.4' + description: Creates point in time context. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/point-in-time-api/#create-a-pit + parameters: + - $ref: '#/components/parameters/create_pit___path.index' + - $ref: '#/components/parameters/create_pit___query.allow_partial_pit_creation' + - $ref: '#/components/parameters/create_pit___query.expand_wildcards' + - $ref: '#/components/parameters/create_pit___query.keep_alive' + - $ref: '#/components/parameters/create_pit___query.preference' + - $ref: '#/components/parameters/create_pit___query.routing' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/create_pit___200' + /{index}/_search/template: + get: + operationId: search_template.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: search_template + x-version-added: '1.0' + description: Allows to use the Mustache language to pre-render a search definition. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/search_template___path.index' + - $ref: '#/components/parameters/search_template___query.allow_no_indices' + - $ref: '#/components/parameters/search_template___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/search_template___query.expand_wildcards' + - $ref: '#/components/parameters/search_template___query.explain' + - $ref: '#/components/parameters/search_template___query.ignore_throttled' + - $ref: '#/components/parameters/search_template___query.ignore_unavailable' + - $ref: '#/components/parameters/search_template___query.phase_took' + - $ref: '#/components/parameters/search_template___query.preference' + - $ref: '#/components/parameters/search_template___query.profile' + - $ref: '#/components/parameters/search_template___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/search_template___query.routing' + - $ref: '#/components/parameters/search_template___query.scroll' + - $ref: '#/components/parameters/search_template___query.search_pipeline' + - $ref: '#/components/parameters/search_template___query.search_type' + - $ref: '#/components/parameters/search_template___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_template' + responses: + '200': + $ref: '#/components/responses/search_template___200' + post: + operationId: search_template.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___SearchShards' + x-operation-group: search_template + x-version-added: '1.0' + description: Allows to use the Mustache language to pre-render a search definition. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/search-template/ + parameters: + - $ref: '#/components/parameters/search_template___path.index' + - $ref: '#/components/parameters/search_template___query.allow_no_indices' + - $ref: '#/components/parameters/search_template___query.ccs_minimize_roundtrips' + - $ref: '#/components/parameters/search_template___query.expand_wildcards' + - $ref: '#/components/parameters/search_template___query.explain' + - $ref: '#/components/parameters/search_template___query.ignore_throttled' + - $ref: '#/components/parameters/search_template___query.ignore_unavailable' + - $ref: '#/components/parameters/search_template___query.phase_took' + - $ref: '#/components/parameters/search_template___query.preference' + - $ref: '#/components/parameters/search_template___query.profile' + - $ref: '#/components/parameters/search_template___query.rest_total_hits_as_int' + - $ref: '#/components/parameters/search_template___query.routing' + - $ref: '#/components/parameters/search_template___query.scroll' + - $ref: '#/components/parameters/search_template___query.search_pipeline' + - $ref: '#/components/parameters/search_template___query.search_type' + - $ref: '#/components/parameters/search_template___query.typed_keys' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/search_template' + responses: + '200': + $ref: '#/components/responses/search_template___200' + /{index}/_segments: + get: + operationId: indices.segments.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.segments + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Provides low-level information about segments in a Lucene index. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.segments___path.index' + - $ref: '#/components/parameters/indices.segments___query.allow_no_indices' + - $ref: '#/components/parameters/indices.segments___query.expand_wildcards' + - $ref: '#/components/parameters/indices.segments___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.segments___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.segments___200' + /{index}/_settings: + get: + operationId: indices.get_settings.2 + x-operation-group: indices.get_settings + x-version-added: '1.0' + description: Returns settings for one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/get-settings/ + parameters: + - $ref: '#/components/parameters/indices.get_settings___path.index' + - $ref: '#/components/parameters/indices.get_settings___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_settings___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_settings___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_settings___query.flat_settings' + - $ref: '#/components/parameters/indices.get_settings___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_settings___query.include_defaults' + - $ref: '#/components/parameters/indices.get_settings___query.local' + - $ref: '#/components/parameters/indices.get_settings___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_settings___200' + put: + operationId: indices.put_settings.1 + x-operation-group: indices.put_settings + x-version-added: '1.0' + description: Updates the index settings. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/update-settings/ + parameters: + - $ref: '#/components/parameters/indices.put_settings___path.index' + - $ref: '#/components/parameters/indices.put_settings___query.allow_no_indices' + - $ref: '#/components/parameters/indices.put_settings___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.put_settings___query.expand_wildcards' + - $ref: '#/components/parameters/indices.put_settings___query.flat_settings' + - $ref: '#/components/parameters/indices.put_settings___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.put_settings___query.master_timeout' + - $ref: '#/components/parameters/indices.put_settings___query.preserve_existing' + - $ref: '#/components/parameters/indices.put_settings___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.put_settings' + responses: + '200': + $ref: '#/components/responses/indices.put_settings___200' + /{index}/_settings/{name}: + get: + operationId: indices.get_settings.3 + x-operation-group: indices.get_settings + x-version-added: '1.0' + description: Returns settings for one or more indexes. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/get-settings/ + parameters: + - $ref: '#/components/parameters/indices.get_settings___path.index' + - $ref: '#/components/parameters/indices.get_settings___path.name' + - $ref: '#/components/parameters/indices.get_settings___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_settings___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.get_settings___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_settings___query.flat_settings' + - $ref: '#/components/parameters/indices.get_settings___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.get_settings___query.include_defaults' + - $ref: '#/components/parameters/indices.get_settings___query.local' + - $ref: '#/components/parameters/indices.get_settings___query.master_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_settings___200' + /{index}/_shard_stores: + get: + operationId: indices.shard_stores.1 + x-operation-group: indices.shard_stores + x-version-added: '1.0' + description: Provides store information for shard copies of indexes. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.shard_stores___path.index' + - $ref: '#/components/parameters/indices.shard_stores___query.allow_no_indices' + - $ref: '#/components/parameters/indices.shard_stores___query.expand_wildcards' + - $ref: '#/components/parameters/indices.shard_stores___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.shard_stores___query.status' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.shard_stores___200' + /{index}/_shrink/{target}: + post: + operationId: indices.shrink.0 + x-operation-group: indices.shrink + x-version-added: '1.0' + description: Allow to shrink an existing index into a new index with fewer primary shards. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/shrink-index/ + parameters: + - $ref: '#/components/parameters/indices.shrink___path.index' + - $ref: '#/components/parameters/indices.shrink___path.target' + - $ref: '#/components/parameters/indices.shrink___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.shrink___query.copy_settings' + - $ref: '#/components/parameters/indices.shrink___query.master_timeout' + - $ref: '#/components/parameters/indices.shrink___query.task_execution_timeout' + - $ref: '#/components/parameters/indices.shrink___query.timeout' + - $ref: '#/components/parameters/indices.shrink___query.wait_for_active_shards' + - $ref: '#/components/parameters/indices.shrink___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.shrink' + responses: + '200': + $ref: '#/components/responses/indices.shrink___200' + put: + operationId: indices.shrink.1 + x-operation-group: indices.shrink + x-version-added: '1.0' + description: Allow to shrink an existing index into a new index with fewer primary shards. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/shrink-index/ + parameters: + - $ref: '#/components/parameters/indices.shrink___path.index' + - $ref: '#/components/parameters/indices.shrink___path.target' + - $ref: '#/components/parameters/indices.shrink___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.shrink___query.copy_settings' + - $ref: '#/components/parameters/indices.shrink___query.master_timeout' + - $ref: '#/components/parameters/indices.shrink___query.task_execution_timeout' + - $ref: '#/components/parameters/indices.shrink___query.timeout' + - $ref: '#/components/parameters/indices.shrink___query.wait_for_active_shards' + - $ref: '#/components/parameters/indices.shrink___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.shrink' + responses: + '200': + $ref: '#/components/responses/indices.shrink___200' + /{index}/_source/{id}: + get: + operationId: get_source.0 + x-operation-group: get_source + x-version-added: '1.0' + description: Returns the source of a document. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/get-documents/ + parameters: + - $ref: '#/components/parameters/get_source___path.id' + - $ref: '#/components/parameters/get_source___path.index' + - $ref: '#/components/parameters/get_source___query._source' + - $ref: '#/components/parameters/get_source___query._source_excludes' + - $ref: '#/components/parameters/get_source___query._source_includes' + - $ref: '#/components/parameters/get_source___query.preference' + - $ref: '#/components/parameters/get_source___query.realtime' + - $ref: '#/components/parameters/get_source___query.refresh' + - $ref: '#/components/parameters/get_source___query.routing' + - $ref: '#/components/parameters/get_source___query.version' + - $ref: '#/components/parameters/get_source___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/get_source___200' + '404': + $ref: '#/components/responses/get_source___404' + head: + operationId: exists_source.0 + x-operation-group: exists_source + x-version-added: '1.0' + description: Returns information about whether a document source exists in an index. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/get-documents/ + parameters: + - $ref: '#/components/parameters/exists_source___path.id' + - $ref: '#/components/parameters/exists_source___path.index' + - $ref: '#/components/parameters/exists_source___query._source' + - $ref: '#/components/parameters/exists_source___query._source_excludes' + - $ref: '#/components/parameters/exists_source___query._source_includes' + - $ref: '#/components/parameters/exists_source___query.preference' + - $ref: '#/components/parameters/exists_source___query.realtime' + - $ref: '#/components/parameters/exists_source___query.refresh' + - $ref: '#/components/parameters/exists_source___query.routing' + - $ref: '#/components/parameters/exists_source___query.version' + - $ref: '#/components/parameters/exists_source___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/exists_source___200' + '404': + $ref: '#/components/responses/exists_source___404' + /{index}/_split/{target}: + post: + operationId: indices.split.0 + x-operation-group: indices.split + x-version-added: '1.0' + description: Allows you to split an existing index into a new index with more primary shards. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/split/ + parameters: + - $ref: '#/components/parameters/indices.split___path.index' + - $ref: '#/components/parameters/indices.split___path.target' + - $ref: '#/components/parameters/indices.split___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.split___query.copy_settings' + - $ref: '#/components/parameters/indices.split___query.master_timeout' + - $ref: '#/components/parameters/indices.split___query.task_execution_timeout' + - $ref: '#/components/parameters/indices.split___query.timeout' + - $ref: '#/components/parameters/indices.split___query.wait_for_active_shards' + - $ref: '#/components/parameters/indices.split___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.split' + responses: + '200': + $ref: '#/components/responses/indices.split___200' + put: + operationId: indices.split.1 + x-operation-group: indices.split + x-version-added: '1.0' + description: Allows you to split an existing index into a new index with more primary shards. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/index-apis/split/ + parameters: + - $ref: '#/components/parameters/indices.split___path.index' + - $ref: '#/components/parameters/indices.split___path.target' + - $ref: '#/components/parameters/indices.split___query.cluster_manager_timeout' + - $ref: '#/components/parameters/indices.split___query.copy_settings' + - $ref: '#/components/parameters/indices.split___query.master_timeout' + - $ref: '#/components/parameters/indices.split___query.task_execution_timeout' + - $ref: '#/components/parameters/indices.split___query.timeout' + - $ref: '#/components/parameters/indices.split___query.wait_for_active_shards' + - $ref: '#/components/parameters/indices.split___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.split' + responses: + '200': + $ref: '#/components/responses/indices.split___200' + /{index}/_stats: + get: + operationId: indices.stats.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.stats + x-version-added: '1.0' + description: Provides statistics on operations happening in an index. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.stats___path.index' + - $ref: '#/components/parameters/indices.stats___query.completion_fields' + - $ref: '#/components/parameters/indices.stats___query.expand_wildcards' + - $ref: '#/components/parameters/indices.stats___query.fielddata_fields' + - $ref: '#/components/parameters/indices.stats___query.fields' + - $ref: '#/components/parameters/indices.stats___query.forbid_closed_indices' + - $ref: '#/components/parameters/indices.stats___query.groups' + - $ref: '#/components/parameters/indices.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/indices.stats___query.include_unloaded_segments' + - $ref: '#/components/parameters/indices.stats___query.level' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.stats___200' + /{index}/_stats/{metric}: + get: + operationId: indices.stats.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.stats + x-version-added: '1.0' + description: Provides statistics on operations happening in an index. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.stats___path.index' + - $ref: '#/components/parameters/indices.stats___path.metric' + - $ref: '#/components/parameters/indices.stats___query.completion_fields' + - $ref: '#/components/parameters/indices.stats___query.expand_wildcards' + - $ref: '#/components/parameters/indices.stats___query.fielddata_fields' + - $ref: '#/components/parameters/indices.stats___query.fields' + - $ref: '#/components/parameters/indices.stats___query.forbid_closed_indices' + - $ref: '#/components/parameters/indices.stats___query.groups' + - $ref: '#/components/parameters/indices.stats___query.include_segment_file_sizes' + - $ref: '#/components/parameters/indices.stats___query.include_unloaded_segments' + - $ref: '#/components/parameters/indices.stats___query.level' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.stats___200' + /{index}/_termvectors: + get: + operationId: termvectors.0 + x-operation-group: termvectors + x-version-added: '1.0' + description: Returns information and statistics about terms in the fields of a particular document. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/termvectors___path.index' + - $ref: '#/components/parameters/termvectors___query.field_statistics' + - $ref: '#/components/parameters/termvectors___query.fields' + - $ref: '#/components/parameters/termvectors___query.offsets' + - $ref: '#/components/parameters/termvectors___query.payloads' + - $ref: '#/components/parameters/termvectors___query.positions' + - $ref: '#/components/parameters/termvectors___query.preference' + - $ref: '#/components/parameters/termvectors___query.realtime' + - $ref: '#/components/parameters/termvectors___query.routing' + - $ref: '#/components/parameters/termvectors___query.term_statistics' + - $ref: '#/components/parameters/termvectors___query.version' + - $ref: '#/components/parameters/termvectors___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/termvectors' + responses: + '200': + $ref: '#/components/responses/termvectors___200' + post: + operationId: termvectors.1 + x-operation-group: termvectors + x-version-added: '1.0' + description: Returns information and statistics about terms in the fields of a particular document. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/termvectors___path.index' + - $ref: '#/components/parameters/termvectors___query.field_statistics' + - $ref: '#/components/parameters/termvectors___query.fields' + - $ref: '#/components/parameters/termvectors___query.offsets' + - $ref: '#/components/parameters/termvectors___query.payloads' + - $ref: '#/components/parameters/termvectors___query.positions' + - $ref: '#/components/parameters/termvectors___query.preference' + - $ref: '#/components/parameters/termvectors___query.realtime' + - $ref: '#/components/parameters/termvectors___query.routing' + - $ref: '#/components/parameters/termvectors___query.term_statistics' + - $ref: '#/components/parameters/termvectors___query.version' + - $ref: '#/components/parameters/termvectors___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/termvectors' + responses: + '200': + $ref: '#/components/responses/termvectors___200' + /{index}/_termvectors/{id}: + get: + operationId: termvectors.2 + x-operation-group: termvectors + x-version-added: '1.0' + description: Returns information and statistics about terms in the fields of a particular document. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/termvectors___path.id' + - $ref: '#/components/parameters/termvectors___path.index' + - $ref: '#/components/parameters/termvectors___query.field_statistics' + - $ref: '#/components/parameters/termvectors___query.fields' + - $ref: '#/components/parameters/termvectors___query.offsets' + - $ref: '#/components/parameters/termvectors___query.payloads' + - $ref: '#/components/parameters/termvectors___query.positions' + - $ref: '#/components/parameters/termvectors___query.preference' + - $ref: '#/components/parameters/termvectors___query.realtime' + - $ref: '#/components/parameters/termvectors___query.routing' + - $ref: '#/components/parameters/termvectors___query.term_statistics' + - $ref: '#/components/parameters/termvectors___query.version' + - $ref: '#/components/parameters/termvectors___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/termvectors' + responses: + '200': + $ref: '#/components/responses/termvectors___200' + post: + operationId: termvectors.3 + x-operation-group: termvectors + x-version-added: '1.0' + description: Returns information and statistics about terms in the fields of a particular document. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/termvectors___path.id' + - $ref: '#/components/parameters/termvectors___path.index' + - $ref: '#/components/parameters/termvectors___query.field_statistics' + - $ref: '#/components/parameters/termvectors___query.fields' + - $ref: '#/components/parameters/termvectors___query.offsets' + - $ref: '#/components/parameters/termvectors___query.payloads' + - $ref: '#/components/parameters/termvectors___query.positions' + - $ref: '#/components/parameters/termvectors___query.preference' + - $ref: '#/components/parameters/termvectors___query.realtime' + - $ref: '#/components/parameters/termvectors___query.routing' + - $ref: '#/components/parameters/termvectors___query.term_statistics' + - $ref: '#/components/parameters/termvectors___query.version' + - $ref: '#/components/parameters/termvectors___query.version_type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/termvectors' + responses: + '200': + $ref: '#/components/responses/termvectors___200' + /{index}/_update_by_query: + post: + operationId: update_by_query.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BulkByScrollFailures' + x-operation-group: update_by_query + x-version-added: '1.0' + description: |- + Performs an update on every document in the index without changing the source, + for example to pick up a mapping change. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/update-by-query/ + parameters: + - $ref: '#/components/parameters/update_by_query___path.index' + - $ref: '#/components/parameters/update_by_query___query._source' + - $ref: '#/components/parameters/update_by_query___query._source_excludes' + - $ref: '#/components/parameters/update_by_query___query._source_includes' + - $ref: '#/components/parameters/update_by_query___query.allow_no_indices' + - $ref: '#/components/parameters/update_by_query___query.analyze_wildcard' + - $ref: '#/components/parameters/update_by_query___query.analyzer' + - $ref: '#/components/parameters/update_by_query___query.conflicts' + - $ref: '#/components/parameters/update_by_query___query.default_operator' + - $ref: '#/components/parameters/update_by_query___query.df' + - $ref: '#/components/parameters/update_by_query___query.expand_wildcards' + - $ref: '#/components/parameters/update_by_query___query.from' + - $ref: '#/components/parameters/update_by_query___query.ignore_unavailable' + - $ref: '#/components/parameters/update_by_query___query.lenient' + - $ref: '#/components/parameters/update_by_query___query.max_docs' + - $ref: '#/components/parameters/update_by_query___query.pipeline' + - $ref: '#/components/parameters/update_by_query___query.preference' + - $ref: '#/components/parameters/update_by_query___query.q' + - $ref: '#/components/parameters/update_by_query___query.refresh' + - $ref: '#/components/parameters/update_by_query___query.request_cache' + - $ref: '#/components/parameters/update_by_query___query.requests_per_second' + - $ref: '#/components/parameters/update_by_query___query.routing' + - $ref: '#/components/parameters/update_by_query___query.scroll' + - $ref: '#/components/parameters/update_by_query___query.scroll_size' + - $ref: '#/components/parameters/update_by_query___query.search_timeout' + - $ref: '#/components/parameters/update_by_query___query.search_type' + - $ref: '#/components/parameters/update_by_query___query.size' + - $ref: '#/components/parameters/update_by_query___query.slices' + - $ref: '#/components/parameters/update_by_query___query.sort' + - $ref: '#/components/parameters/update_by_query___query.stats' + - $ref: '#/components/parameters/update_by_query___query.terminate_after' + - $ref: '#/components/parameters/update_by_query___query.timeout' + - $ref: '#/components/parameters/update_by_query___query.version' + - $ref: '#/components/parameters/update_by_query___query.wait_for_active_shards' + - $ref: '#/components/parameters/update_by_query___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/update_by_query' + responses: + '200': + $ref: '#/components/responses/update_by_query___200' + /{index}/_update/{id}: + post: + operationId: update.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___WriteShards' + x-operation-group: update + x-version-added: '1.0' + description: Updates a document with a script or partial document. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/document-apis/update-document/ + parameters: + - $ref: '#/components/parameters/update___path.id' + - $ref: '#/components/parameters/update___path.index' + - $ref: '#/components/parameters/update___query._source' + - $ref: '#/components/parameters/update___query._source_excludes' + - $ref: '#/components/parameters/update___query._source_includes' + - $ref: '#/components/parameters/update___query.if_primary_term' + - $ref: '#/components/parameters/update___query.if_seq_no' + - $ref: '#/components/parameters/update___query.lang' + - $ref: '#/components/parameters/update___query.refresh' + - $ref: '#/components/parameters/update___query.require_alias' + - $ref: '#/components/parameters/update___query.retry_on_conflict' + - $ref: '#/components/parameters/update___query.routing' + - $ref: '#/components/parameters/update___query.timeout' + - $ref: '#/components/parameters/update___query.wait_for_active_shards' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/update' + responses: + '200': + $ref: '#/components/responses/update___200' + /{index}/_upgrade: + get: + operationId: indices.get_upgrade.1 + x-operation-group: indices.get_upgrade + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: The `_upgrade` API is no longer useful and will be removed. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.get_upgrade___path.index' + - $ref: '#/components/parameters/indices.get_upgrade___query.allow_no_indices' + - $ref: '#/components/parameters/indices.get_upgrade___query.expand_wildcards' + - $ref: '#/components/parameters/indices.get_upgrade___query.ignore_unavailable' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.get_upgrade___200' + post: + operationId: indices.upgrade.1 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.upgrade + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: The `_upgrade` API is no longer useful and will be removed. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.upgrade___path.index' + - $ref: '#/components/parameters/indices.upgrade___query.allow_no_indices' + - $ref: '#/components/parameters/indices.upgrade___query.expand_wildcards' + - $ref: '#/components/parameters/indices.upgrade___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.upgrade___query.only_ancient_segments' + - $ref: '#/components/parameters/indices.upgrade___query.wait_for_completion' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/indices.upgrade___200' + /{index}/_validate/query: + get: + operationId: indices.validate_query.2 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.validate_query + x-version-added: '1.0' + description: Allows a user to validate a potentially expensive query without executing it. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.validate_query___path.index' + - $ref: '#/components/parameters/indices.validate_query___query.all_shards' + - $ref: '#/components/parameters/indices.validate_query___query.allow_no_indices' + - $ref: '#/components/parameters/indices.validate_query___query.analyze_wildcard' + - $ref: '#/components/parameters/indices.validate_query___query.analyzer' + - $ref: '#/components/parameters/indices.validate_query___query.default_operator' + - $ref: '#/components/parameters/indices.validate_query___query.df' + - $ref: '#/components/parameters/indices.validate_query___query.expand_wildcards' + - $ref: '#/components/parameters/indices.validate_query___query.explain' + - $ref: '#/components/parameters/indices.validate_query___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.validate_query___query.lenient' + - $ref: '#/components/parameters/indices.validate_query___query.q' + - $ref: '#/components/parameters/indices.validate_query___query.rewrite' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.validate_query' + responses: + '200': + $ref: '#/components/responses/indices.validate_query___200' + post: + operationId: indices.validate_query.3 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: indices.validate_query + x-version-added: '1.0' + description: Allows a user to validate a potentially expensive query without executing it. + externalDocs: + url: https://opensearch.org/docs/latest + parameters: + - $ref: '#/components/parameters/indices.validate_query___path.index' + - $ref: '#/components/parameters/indices.validate_query___query.all_shards' + - $ref: '#/components/parameters/indices.validate_query___query.allow_no_indices' + - $ref: '#/components/parameters/indices.validate_query___query.analyze_wildcard' + - $ref: '#/components/parameters/indices.validate_query___query.analyzer' + - $ref: '#/components/parameters/indices.validate_query___query.default_operator' + - $ref: '#/components/parameters/indices.validate_query___query.df' + - $ref: '#/components/parameters/indices.validate_query___query.expand_wildcards' + - $ref: '#/components/parameters/indices.validate_query___query.explain' + - $ref: '#/components/parameters/indices.validate_query___query.ignore_unavailable' + - $ref: '#/components/parameters/indices.validate_query___query.lenient' + - $ref: '#/components/parameters/indices.validate_query___query.q' + - $ref: '#/components/parameters/indices.validate_query___query.rewrite' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/indices.validate_query' + responses: + '200': + $ref: '#/components/responses/indices.validate_query___200' + /{index}/ingestion/_pause: + post: + summary: Pause streaming ingestion for the given index. + operationId: ingestion.pause.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___IngestionShardFailures' + x-operation-group: ingestion.pause + x-version-added: '3.1' + description: Use this API to pause ingestion for a given index. + externalDocs: + url: https://docs.opensearch.org/docs/latest/api-reference/document-apis/pull-based-ingestion-management/ + parameters: + - $ref: '#/components/parameters/ingestion.pause___path.index' + - $ref: '#/components/parameters/ingestion.pause___query.cluster_manager_timeout' + - $ref: '#/components/parameters/ingestion.pause___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ingestion.pause___200' + /{index}/ingestion/_resume: + post: + summary: Resume streaming ingestion for the given index. + operationId: ingestion.resume.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___IngestionShardFailures' + x-operation-group: ingestion.resume + x-version-added: '3.1' + description: Use this API to resume ingestion for the given index. + externalDocs: + url: https://docs.opensearch.org/docs/latest/api-reference/document-apis/pull-based-ingestion-management/ + parameters: + - $ref: '#/components/parameters/ingestion.resume___path.index' + - $ref: '#/components/parameters/ingestion.resume___query.cluster_manager_timeout' + - $ref: '#/components/parameters/ingestion.resume___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ingestion.resume' + responses: + '200': + $ref: '#/components/responses/ingestion.resume___200' + /{index}/ingestion/_state: + get: + summary: Get the current ingestion state for a given index. + operationId: ingestion.get_state.0 + x-error-responses: + - $ref: '#/components/schemas/_common.errors___BroadcastShards' + x-operation-group: ingestion.get_state + x-version-added: '3.1' + description: Use this API to retrieve the ingestion state for a given index. + externalDocs: + url: https://docs.opensearch.org/docs/latest/api-reference/document-apis/pull-based-ingestion-management/ + parameters: + - $ref: '#/components/parameters/ingestion.get_state___path.index' + - $ref: '#/components/parameters/ingestion.get_state___query.next_token' + - $ref: '#/components/parameters/ingestion.get_state___query.size' + - $ref: '#/components/parameters/ingestion.get_state___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ingestion.get_state___200' + /_opendistro/_asynchronous_search: + post: + operationId: asynchronous_search.search.0_superseded + x-operation-group: asynchronous_search.search + x-version-added: '1.0' + description: Performs an asynchronous search. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/async/index/#rest-api + parameters: + - $ref: '#/components/parameters/asynchronous_search.search___query.index' + - $ref: '#/components/parameters/asynchronous_search.search___query.keep_alive' + - $ref: '#/components/parameters/asynchronous_search.search___query.keep_on_completion' + - $ref: '#/components/parameters/asynchronous_search.search___query.wait_for_completion_timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/asynchronous_search.search' + responses: + '200': + $ref: '#/components/responses/asynchronous_search.search___200' + deprecated: true + x-ignorable: true + /_opendistro/_asynchronous_search/stats: + get: + operationId: asynchronous_search.stats.0_superseded + x-operation-group: asynchronous_search.stats + x-version-added: '1.0' + description: Monitors any asynchronous searches that are `running`, `completed`, or `persisted`. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/async/index/#monitor-stats + responses: + '200': + $ref: '#/components/responses/asynchronous_search.stats___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_asynchronous_search/{id}: + get: + operationId: asynchronous_search.get.0_superseded + x-operation-group: asynchronous_search.get + x-version-added: '1.0' + description: Gets partial responses from an asynchronous search. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/async/index/#get-partial-results + parameters: + - $ref: '#/components/parameters/asynchronous_search.get___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/asynchronous_search.get___200' + deprecated: true + x-ignorable: true + delete: + operationId: asynchronous_search.delete.0_superseded + x-operation-group: asynchronous_search.delete + x-version-added: '1.0' + description: Deletes any responses from an asynchronous search. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/async/index/#delete-searches-and-results + parameters: + - $ref: '#/components/parameters/asynchronous_search.delete___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/asynchronous_search.delete___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/add: + post: + operationId: ism.add_policy.0_superseded + x-operation-group: ism.add_policy + description: Adds a policy to an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#add-policy + parameters: + - $ref: '#/components/parameters/ism.add_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.add_policy' + responses: + '200': + $ref: '#/components/responses/ism.add_policy___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/add/{index}: + post: + operationId: ism.add_policy.1_superseded + x-operation-group: ism.add_policy + description: Adds a policy to an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#add-policy + parameters: + - $ref: '#/components/parameters/ism.add_policy___path.index' + - $ref: '#/components/parameters/ism.add_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.add_policy' + responses: + '200': + $ref: '#/components/responses/ism.add_policy___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/change_policy: + post: + operationId: ism.change_policy.0_superseded + x-operation-group: ism.change_policy + description: Updates the managed index policy to a new policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#update-managed-index-policy + parameters: + - $ref: '#/components/parameters/ism.change_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.change_policy' + responses: + '200': + $ref: '#/components/responses/ism.change_policy___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/change_policy/{index}: + post: + operationId: ism.change_policy.1_superseded + x-operation-group: ism.change_policy + description: Updates the managed index policy to a new policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#update-managed-index-policy + parameters: + - $ref: '#/components/parameters/ism.change_policy___path.index' + - $ref: '#/components/parameters/ism.change_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.change_policy' + responses: + '200': + $ref: '#/components/responses/ism.change_policy___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/explain: + get: + operationId: ism.explain_policy.0_superseded + x-operation-group: ism.explain_policy + description: Retrieves the currently applied policy on the specified indexes. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index + requestBody: + $ref: '#/components/requestBodies/ism.explain_policy' + responses: + '200': + $ref: '#/components/responses/ism.explain_policy___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + post: + operationId: ism.explain_policy.1_superseded + x-operation-group: ism.explain_policy + description: Retrieves the currently applied policy on the specified indexes. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index + requestBody: + $ref: '#/components/requestBodies/ism.explain_policy' + responses: + '200': + $ref: '#/components/responses/ism.explain_policy___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_ism/explain/{index}: + get: + operationId: ism.explain_policy.3_superseded + x-operation-group: ism.explain_policy + description: Retrieves the currently applied policy on the specified indexes. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index + parameters: + - $ref: '#/components/parameters/ism.explain_policy___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.explain_policy' + responses: + '200': + $ref: '#/components/responses/ism.explain_policy___200' + deprecated: true + x-ignorable: true + post: + operationId: ism.explain_policy.4_superseded + x-operation-group: ism.explain_policy + description: Retrieves the currently applied policy on the specified indexes. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#explain-index + parameters: + - $ref: '#/components/parameters/ism.explain_policy___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.explain_policy' + responses: + '200': + $ref: '#/components/responses/ism.explain_policy___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/policies: + get: + operationId: ism.get_policies.0_superseded + x-operation-group: ism.get_policies + description: Retrieves the policies. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#get-policy + responses: + '200': + $ref: '#/components/responses/ism.get_policies___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + put: + operationId: ism.put_policies.0_superseded + x-operation-group: ism.put_policies + description: Creates or updates policies. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#create-policy + requestBody: + $ref: '#/components/requestBodies/ism.put_policies' + parameters: + - $ref: '#/components/parameters/ism.put_policies___query.if_primary_term' + - $ref: '#/components/parameters/ism.put_policies___query.if_seq_no' + - $ref: '#/components/parameters/ism.put_policies___query.policyID' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.put_policies___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/policies/{policy_id}: + get: + operationId: ism.get_policy.0_superseded + x-operation-group: ism.get_policy + description: Retrieves a specific policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#put-policy + parameters: + - $ref: '#/components/parameters/ism.get_policy___path.policy_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.get_policy___200' + deprecated: true + x-ignorable: true + head: + operationId: ism.exists_policy.0_superseded + x-operation-group: ism.exists_policy + description: Checks for the existence of a policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#get-policy + parameters: + - $ref: '#/components/parameters/ism.exists_policy___path.policy_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.exists_policy___200' + '404': + $ref: '#/components/responses/ism.exists_policy___404' + deprecated: true + x-ignorable: true + put: + operationId: ism.put_policy.0_superseded + x-operation-group: ism.put_policy + description: Creates or updates a policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#create-policy + parameters: + - $ref: '#/components/parameters/ism.put_policy___path.policy_id' + - $ref: '#/components/parameters/ism.put_policy___query.if_primary_term' + - $ref: '#/components/parameters/ism.put_policy___query.if_seq_no' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.put_policy' + responses: + '200': + $ref: '#/components/responses/ism.put_policy___200' + '201': + $ref: '#/components/responses/ism.put_policy___201' + deprecated: true + x-ignorable: true + delete: + operationId: ism.delete_policy.0_superseded + x-operation-group: ism.delete_policy + description: Deletes a policy. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#delete-policy + parameters: + - $ref: '#/components/parameters/ism.delete_policy___path.policy_id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.delete_policy___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/remove: + post: + operationId: ism.remove_policy.0_superseded + x-operation-group: ism.remove_policy + description: Removes a policy from an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#remove-policy + parameters: + - $ref: '#/components/parameters/ism.remove_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.remove_policy___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/remove/{index}: + post: + operationId: ism.remove_policy.1_superseded + x-operation-group: ism.remove_policy + description: Removes a policy from an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#remove-policy + parameters: + - $ref: '#/components/parameters/ism.remove_policy___path.index' + - $ref: '#/components/parameters/ism.remove_policy___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.remove_policy___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/retry: + post: + operationId: ism.retry_index.0_superseded + x-operation-group: ism.retry_index + description: Retries the failed action for an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#retry-failed-index + parameters: + - $ref: '#/components/parameters/ism.retry_index___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.retry_index' + responses: + '200': + $ref: '#/components/responses/ism.retry_index___200' + deprecated: true + x-ignorable: true + /_opendistro/_ism/retry/{index}: + post: + operationId: ism.retry_index.1_superseded + x-operation-group: ism.retry_index + description: Retries the failed action for an index. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/ism/api/#retry-failed-index + parameters: + - $ref: '#/components/parameters/ism.retry_index___path.index' + - $ref: '#/components/parameters/ism.retry_index___query.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ism.retry_index' + responses: + '200': + $ref: '#/components/responses/ism.retry_index___200' + deprecated: true + x-ignorable: true + /_opendistro/_knn/stats/{stat}: + get: + operationId: knn.stats.1_superseded + x-operation-group: knn.stats + x-version-added: '1.0' + description: Provides information about the current status of the k-NN plugin. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#stats + parameters: + - $ref: '#/components/parameters/knn.stats___path.stat' + - $ref: '#/components/parameters/knn.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.stats___200' + deprecated: true + x-ignorable: true + /_opendistro/_knn/warmup/{index}: + get: + operationId: knn.warmup.0_superseded + x-operation-group: knn.warmup + x-version-added: '1.0' + description: Preloads native library files into memory, reducing initial search latency for specified indexes. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#warmup-operation + parameters: + - $ref: '#/components/parameters/knn.warmup___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.warmup___200' + deprecated: true + x-ignorable: true + /_opendistro/_knn/{node_id}/stats/{stat}: + get: + operationId: knn.stats.3_superseded + x-operation-group: knn.stats + x-version-added: '1.0' + description: Provides information about the current status of the k-NN plugin. + externalDocs: + url: https://docs.opensearch.org/latest/vector-search/api/knn/#stats + parameters: + - $ref: '#/components/parameters/knn.stats___path.node_id' + - $ref: '#/components/parameters/knn.stats___path.stat' + - $ref: '#/components/parameters/knn.stats___query.timeout' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/knn.stats___200' + deprecated: true + x-ignorable: true + /_opendistro/_ppl: + post: + operationId: ppl.query.0_superseded + x-operation-group: ppl.query + x-version-added: '1.0' + description: Executes a PPL query against OpenSearch indexes. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/ppl.query___query.format' + - $ref: '#/components/parameters/ppl.query___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ppl.query' + responses: + '200': + $ref: '#/components/responses/ppl.query___200' + deprecated: true + x-ignorable: true + /_opendistro/_ppl/_explain: + post: + operationId: ppl.explain.0_superseded + x-operation-group: ppl.explain + x-version-added: '1.0' + description: Returns the execution plan for a PPL query. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/ppl.explain___query.format' + - $ref: '#/components/parameters/ppl.explain___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ppl.explain' + responses: + '200': + $ref: '#/components/responses/ppl.explain___200' + deprecated: true + x-ignorable: true + /_opendistro/_ppl/stats: + get: + operationId: ppl.get_stats.0_superseded + x-operation-group: ppl.get_stats + x-version-added: '1.0' + description: Retrieves performance metrics for the PPL plugin. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ + parameters: + - $ref: '#/components/parameters/ppl.get_stats___query.format' + - $ref: '#/components/parameters/ppl.get_stats___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ppl.get_stats___200' + deprecated: true + x-ignorable: true + post: + operationId: ppl.post_stats.1_superseded + x-operation-group: ppl.post_stats + x-version-added: '1.0' + description: Retrieves filtered performance metrics for the PPL plugin. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ + parameters: + - $ref: '#/components/parameters/ppl.post_stats___query.format' + - $ref: '#/components/parameters/ppl.post_stats___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/ppl.post_stats' + responses: + '200': + $ref: '#/components/responses/ppl.post_stats___200' + deprecated: true + x-ignorable: true + /_opendistro/_refresh_search_analyzers/{index}: + post: + operationId: ism.refresh_search_analyzers.0_superseded + x-operation-group: ism.refresh_search_analyzers + description: Refreshes search analyzers in real time. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/refresh-analyzer/ + parameters: + - $ref: '#/components/parameters/ism.refresh_search_analyzers___path.index' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/ism.refresh_search_analyzers___200' + deprecated: true + x-ignorable: true + /_opendistro/_rollup/jobs/{id}: + get: + operationId: rollups.get.0_superseded + x-operation-group: rollups.get + x-version-added: '1.0' + description: Retrieves an index rollup job configuration by ID. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#get-an-index-rollup-job + parameters: + - $ref: '#/components/parameters/rollups.get___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/rollups.get___200' + deprecated: true + x-ignorable: true + put: + operationId: rollups.put.0_superseded + x-operation-group: rollups.put + x-version-added: '1.0' + description: Creates or updates an index rollup job configuration. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#create-or-update-an-index-rollup-job + responses: + '201': + $ref: '#/components/responses/rollups.put___201' + parameters: + - $ref: '#/components/parameters/rollups.put___path.id' + - $ref: '#/components/parameters/rollups.put___query.if_primary_term' + - $ref: '#/components/parameters/rollups.put___query.if_seq_no' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/rollups.put' + deprecated: true + x-ignorable: true + delete: + operationId: rollups.delete.0_superseded + x-operation-group: rollups.delete + x-version-added: '1.0' + description: Deletes an index rollup job configuration. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#delete-an-index-rollup-job + responses: + '200': + $ref: '#/components/responses/rollups.delete___200' + parameters: + - $ref: '#/components/parameters/rollups.delete___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_rollup/jobs/{id}/_explain: + get: + operationId: rollups.explain.0_superseded + x-operation-group: rollups.explain + x-version-added: '1.0' + description: Retrieves the execution status information for an index rollup job. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#explain-an-index-rollup-job + parameters: + - $ref: '#/components/parameters/rollups.explain___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/rollups.explain___200' + deprecated: true + x-ignorable: true + /_opendistro/_rollup/jobs/{id}/_start: + post: + operationId: rollups.start.0_superseded + x-operation-group: rollups.start + x-version-added: '1.0' + description: Starts the execution of an index rollup job. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#start-or-stop-an-index-rollup-job + parameters: + - $ref: '#/components/parameters/rollups.start___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/rollups.start___200' + deprecated: true + x-ignorable: true + /_opendistro/_rollup/jobs/{id}/_stop: + post: + operationId: rollups.stop.0_superseded + x-operation-group: rollups.stop + x-version-added: '1.0' + description: Stops the execution of an index rollup job. + externalDocs: + url: https://opensearch.org/docs/latest/im-plugin/index-rollups/rollup-api/#start-or-stop-an-index-rollup-job + parameters: + - $ref: '#/components/parameters/rollups.stop___path.id' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/rollups.stop___200' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/account: + get: + operationId: security.get_account_details.0_superseded + x-operation-group: security.get_account_details + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns account information for the current user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-account-details + responses: + '200': + $ref: '#/components/responses/security.get_account_details___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + put: + operationId: security.change_password.0_superseded + x-operation-group: security.change_password + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Changes the password for the current user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#change-password + requestBody: + $ref: '#/components/requestBodies/security.change_password' + responses: + '200': + $ref: '#/components/responses/security.change_password___200' + '403': + $ref: '#/components/responses/security.change_password___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/actiongroups/{action_group}: + get: + operationId: security.get_action_group.0_superseded + x-operation-group: security.get_action_group + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves one action group. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-action-group + parameters: + - $ref: '#/components/parameters/security.get_action_group___path.action_group' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_action_group___200' + deprecated: true + x-ignorable: true + put: + operationId: security.create_action_group.0_superseded + x-operation-group: security.create_action_group + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified action group. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-action-group + parameters: + - $ref: '#/components/parameters/security.create_action_group___path.action_group' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_action_group' + responses: + '200': + $ref: '#/components/responses/security.create_action_group___200' + '201': + $ref: '#/components/responses/security.create_action_group___201' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_action_group.0_superseded + x-operation-group: security.patch_action_group + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the individual attributes of an action group. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-action-group + parameters: + - $ref: '#/components/parameters/security.patch_action_group___path.action_group' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_action_group' + responses: + '200': + $ref: '#/components/responses/security.patch_action_group___200' + deprecated: true + x-ignorable: true + delete: + operationId: security.delete_action_group.0_superseded + x-operation-group: security.delete_action_group + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified action group. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-action-group + parameters: + - $ref: '#/components/parameters/security.delete_action_group___path.action_group' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_action_group___200' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/audit/config: + put: + operationId: security.update_audit_configuration.0_superseded + x-operation-group: security.update_audit_configuration + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the audit configuration. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#audit-logs + requestBody: + $ref: '#/components/requestBodies/security.update_audit_configuration' + responses: + '200': + $ref: '#/components/responses/security.update_audit_configuration___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/authtoken: + post: + operationId: security.authtoken.0_superseded + x-operation-group: security.authtoken + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns the authorization token for the current user. + responses: + '200': + $ref: '#/components/responses/security.authtoken___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/cache: + get: + operationId: security.cache.1_superseded + x-operation-group: security.cache + x-ignorable: true + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Not supported for the Cache API. + responses: + '405': + $ref: '#/components/responses/security.cache___405' + '501': + $ref: '#/components/responses/security.cache___501' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + post: + operationId: security.cache.2_superseded + x-operation-group: security.cache + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + x-ignorable: true + description: Not supported for the Cache API. + responses: + '405': + $ref: '#/components/responses/security.cache___405' + '501': + $ref: '#/components/responses/security.cache___501' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + put: + operationId: security.cache.3_superseded + x-operation-group: security.cache + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + x-ignorable: true + description: Not supported for the Cache API. + responses: + '405': + $ref: '#/components/responses/security.cache___405' + '501': + $ref: '#/components/responses/security.cache___501' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + delete: + operationId: security.flush_cache.0_superseded + x-operation-group: security.flush_cache + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Flushes the Security plugin's user, authentication, and authorization cache. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#flush-cache + responses: + '200': + $ref: '#/components/responses/security.flush_cache___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/internalusers/{username}: + get: + operationId: security.get_user.0_superseded + x-operation-group: security.get_user + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieve information about the specified internal user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-user + parameters: + - $ref: '#/components/parameters/security.get_user___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_user___200' + deprecated: true + x-ignorable: true + put: + operationId: security.create_user.0_superseded + x-operation-group: security.create_user + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-user + parameters: + - $ref: '#/components/parameters/security.create_user___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_user' + responses: + '200': + $ref: '#/components/responses/security.create_user___200' + '201': + $ref: '#/components/responses/security.create_user___201' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_user.0_superseded + x-operation-group: security.patch_user + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates individual attributes for an internal user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-user + parameters: + - $ref: '#/components/parameters/security.patch_user___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_user' + responses: + '200': + $ref: '#/components/responses/security.patch_user___200' + deprecated: true + x-ignorable: true + delete: + operationId: security.delete_user.0_superseded + x-operation-group: security.delete_user + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified internal user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-user + parameters: + - $ref: '#/components/parameters/security.delete_user___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_user___200' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/internalusers/{username}/authtoken: + post: + operationId: security.generate_user_token.0_superseded + x-operation-group: security.generate_user_token + x-version-added: '2.7' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Generates an authorization token for the specified user. + parameters: + - $ref: '#/components/parameters/security.generate_user_token___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.generate_user_token___200' + '400': + $ref: '#/components/responses/security.generate_user_token___400' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/migrate: + post: + operationId: security.migrate.0_superseded + x-operation-group: security.migrate + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Migrates the security configuration from v6 to v7. + responses: + '200': + $ref: '#/components/responses/security.migrate___200' + '400': + $ref: '#/components/responses/security.migrate___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/permissionsinfo: + get: + operationId: security.get_permissions_info.0_superseded + x-operation-group: security.get_permissions_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the evaluated REST API permissions for the currently logged in user. + responses: + '200': + $ref: '#/components/responses/security.get_permissions_info___200' + '500': + $ref: '#/components/responses/security.get_permissions_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/roles/{role}: + get: + operationId: security.get_role.0_superseded + x-operation-group: security.get_role + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves one role. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-role + parameters: + - $ref: '#/components/parameters/security.get_role___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_role___200' + deprecated: true + x-ignorable: true + put: + operationId: security.create_role.0_superseded + x-operation-group: security.create_role + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified role. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-role + parameters: + - $ref: '#/components/parameters/security.create_role___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_role' + responses: + '200': + $ref: '#/components/responses/security.create_role___200' + '201': + $ref: '#/components/responses/security.create_role___201' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_role.0_superseded + x-operation-group: security.patch_role + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the individual attributes of a role. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-role + parameters: + - $ref: '#/components/parameters/security.patch_role___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_role' + responses: + '200': + $ref: '#/components/responses/security.patch_role___200' + '400': + $ref: '#/components/responses/security.patch_role___400' + deprecated: true + x-ignorable: true + delete: + operationId: security.delete_role.0_superseded + x-operation-group: security.delete_role + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified role. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-role + parameters: + - $ref: '#/components/parameters/security.delete_role___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_role___200' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/rolesmapping/{role}: + get: + operationId: security.get_role_mapping.0_superseded + x-operation-group: security.get_role_mapping + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the specified role mapping. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-role-mapping + parameters: + - $ref: '#/components/parameters/security.get_role_mapping___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_role_mapping___200' + deprecated: true + x-ignorable: true + put: + operationId: security.create_role_mapping.0_superseded + x-operation-group: security.create_role_mapping + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified role mapping. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-role-mapping + parameters: + - $ref: '#/components/parameters/security.create_role_mapping___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_role_mapping' + responses: + '200': + $ref: '#/components/responses/security.create_role_mapping___200' + '201': + $ref: '#/components/responses/security.create_role_mapping___201' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_role_mapping.0_superseded + x-operation-group: security.patch_role_mapping + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the individual attributes of a role mapping. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-role-mapping + parameters: + - $ref: '#/components/parameters/security.patch_role_mapping___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_role_mapping' + responses: + '200': + $ref: '#/components/responses/security.patch_role_mapping___200' + '400': + $ref: '#/components/responses/security.patch_role_mapping___400' + deprecated: true + x-ignorable: true + delete: + operationId: security.delete_role_mapping.0_superseded + x-operation-group: security.delete_role_mapping + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified role mapping. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-role-mapping + parameters: + - $ref: '#/components/parameters/security.delete_role_mapping___path.role' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_role_mapping___200' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/securityconfig: + get: + operationId: security.get_configuration.0_superseded + x-operation-group: security.get_configuration + x-version-added: '2.10' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns the current Security plugin configuration in a JSON format. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-configuration + responses: + '200': + $ref: '#/components/responses/security.get_configuration___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_configuration.0_superseded + x-operation-group: security.patch_configuration + x-version-added: '2.10' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the existing security configuration using the REST API. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-configuration + requestBody: + $ref: '#/components/requestBodies/security.patch_configuration' + responses: + '200': + $ref: '#/components/responses/security.patch_configuration___200' + '403': + $ref: '#/components/responses/security.patch_configuration___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/securityconfig/config: + put: + operationId: security.update_configuration.0_superseded + x-operation-group: security.update_configuration + x-version-added: '2.10' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the settings for an existing security configuration. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#update-configuration + requestBody: + $ref: '#/components/requestBodies/security.update_configuration' + responses: + '200': + $ref: '#/components/responses/security.update_configuration___200' + '403': + $ref: '#/components/responses/security.update_configuration___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/ssl/certs: + get: + operationId: security.get_certificates.0_superseded + x-operation-group: security.get_certificates + x-version-added: '2.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the cluster security certificates. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-certificates + responses: + '200': + $ref: '#/components/responses/security.get_certificates___200' + '400': + $ref: '#/components/responses/security.get_certificates___400' + '403': + $ref: '#/components/responses/security.get_certificates___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/ssl/transport/reloadcerts: + put: + operationId: security.reload_transport_certificates.0_superseded + x-operation-group: security.reload_transport_certificates + x-version-added: '2.8' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Reloads the transport communication certificates. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#reload-transport-certificates + responses: + '200': + $ref: '#/components/responses/security.reload_transport_certificates___200' + '400': + $ref: '#/components/responses/security.reload_transport_certificates___400' + '403': + $ref: '#/components/responses/security.reload_transport_certificates___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/ssl/http/reloadcerts: + put: + operationId: security.reload_http_certificates.0_superseded + x-operation-group: security.reload_http_certificates + x-version-added: '2.8' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Reloads the HTTP communication certificates. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#reload-http-certificates + responses: + '200': + $ref: '#/components/responses/security.reload_http_certificates___200' + '400': + $ref: '#/components/responses/security.reload_http_certificates___400' + '403': + $ref: '#/components/responses/security.reload_http_certificates___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/nodesdn/{cluster_name}: + get: + operationId: security.get_distinguished_name.0_superseded + x-operation-group: security.get_distinguished_name + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves all node distinguished names. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-distinguished-names + parameters: + - $ref: '#/components/parameters/security.get_distinguished_name___path.cluster_name' + - $ref: '#/components/parameters/security.get_distinguished_name___query.show_all' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_distinguished_name___200' + '400': + $ref: '#/components/responses/security.get_distinguished_name___400' + '403': + $ref: '#/components/responses/security.get_distinguished_name___403' + deprecated: true + x-ignorable: true + put: + operationId: security.update_distinguished_name.0_superseded + x-operation-group: security.update_distinguished_name + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Adds or updates the specified distinguished names in the cluster or node allowlist. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#update-distinguished-names + parameters: + - $ref: '#/components/parameters/security.update_distinguished_name___path.cluster_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.update_distinguished_name' + responses: + '200': + $ref: '#/components/responses/security.update_distinguished_name___200' + '201': + $ref: '#/components/responses/security.update_distinguished_name___201' + '400': + $ref: '#/components/responses/security.update_distinguished_name___400' + '403': + $ref: '#/components/responses/security.update_distinguished_name___403' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_distinguished_name.0_superseded + x-operation-group: security.patch_distinguished_name + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the distinguished cluster name for the specified cluster. Requires super admin or REST API permissions. + parameters: + - $ref: '#/components/parameters/security.patch_distinguished_name___path.cluster_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_distinguished_name' + responses: + '200': + $ref: '#/components/responses/security.patch_distinguished_name___200' + '400': + $ref: '#/components/responses/security.patch_distinguished_name___400' + '403': + $ref: '#/components/responses/security.patch_distinguished_name___403' + deprecated: true + x-ignorable: true + delete: + operationId: security.delete_distinguished_name.0_superseded + x-operation-group: security.delete_distinguished_name + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes all distinguished names in the specified cluster or node allowlist. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-distinguished-names + parameters: + - $ref: '#/components/parameters/security.delete_distinguished_name___path.cluster_name' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_distinguished_name___200' + '400': + $ref: '#/components/responses/security.delete_distinguished_name___400' + '403': + $ref: '#/components/responses/security.delete_distinguished_name___403' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/tenancy/config: + get: + operationId: security.get_tenancy_config.0_superseded + x-operation-group: security.get_tenancy_config + x-version-added: '2.7' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the multi-tenancy configuration. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/multi-tenancy/dynamic-config/#configuring-multi-tenancy-with-the-rest-api + responses: + '200': + $ref: '#/components/responses/security.get_tenancy_config___200' + '400': + $ref: '#/components/responses/security.get_tenancy_config___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + put: + operationId: security.create_update_tenancy_config.0_superseded + x-operation-group: security.create_update_tenancy_config + x-version-added: '2.7' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the multi-tenancy configuration. Requires super admin or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/multi-tenancy/dynamic-config/#configuring-multi-tenancy-with-the-rest-api + requestBody: + $ref: '#/components/requestBodies/security.create_update_tenancy_config' + responses: + '200': + $ref: '#/components/responses/security.create_update_tenancy_config___200' + '400': + $ref: '#/components/responses/security.create_update_tenancy_config___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/tenants: + get: + operationId: security.get_tenants.0_superseded + x-operation-group: security.get_tenants + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves all tenants. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-tenants + responses: + '200': + $ref: '#/components/responses/security.get_tenants___200' + '400': + $ref: '#/components/responses/security.get_tenants___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_tenants.0_superseded + x-operation-group: security.patch_tenants + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Adds, deletes, or modifies multiple tenants in a single request. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-tenants + requestBody: + $ref: '#/components/requestBodies/security.patch_tenants' + responses: + '200': + $ref: '#/components/responses/security.patch_tenants___200' + '400': + $ref: '#/components/responses/security.patch_tenants___400' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/tenants/{tenant}: + get: + operationId: security.get_tenant.0_superseded + x-operation-group: security.get_tenant + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the specified tenant. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#get-tenant + parameters: + - $ref: '#/components/parameters/security.get_tenant___path.tenant' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_tenant___200' + deprecated: true + x-ignorable: true + put: + operationId: security.create_tenant.0_superseded + x-operation-group: security.create_tenant + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified tenant. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#create-tenant + parameters: + - $ref: '#/components/parameters/security.create_tenant___path.tenant' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_tenant' + responses: + '200': + $ref: '#/components/responses/security.create_tenant___200' + '201': + $ref: '#/components/responses/security.create_tenant___201' + '400': + $ref: '#/components/responses/security.create_tenant___400' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_tenant.0_superseded + x-operation-group: security.patch_tenant + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Adds, deletes, or modifies a single tenant. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#patch-tenant + parameters: + - $ref: '#/components/parameters/security.patch_tenant___path.tenant' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.patch_tenant' + responses: + '200': + $ref: '#/components/responses/security.patch_tenant___200' + '400': + $ref: '#/components/responses/security.patch_tenant___400' + deprecated: true + x-ignorable: true + delete: + operationId: security.delete_tenant.0_superseded + x-operation-group: security.delete_tenant + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Deletes the specified tenant. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#delete-action-group + parameters: + - $ref: '#/components/parameters/security.delete_tenant___path.tenant' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_tenant___200' + '400': + $ref: '#/components/responses/security.delete_tenant___400' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/user: + get: + operationId: security.get_users_legacy.0_superseded + x-operation-group: security.get_users_legacy + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieve all internal users. Legacy API. + responses: + '200': + $ref: '#/components/responses/security.get_users_legacy___200' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/user/{username}: + get: + operationId: security.get_user_legacy.0_superseded + x-operation-group: security.get_user_legacy + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieve one user. Legacy API. + parameters: + - $ref: '#/components/parameters/security.get_user_legacy___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.get_user_legacy___200' + deprecated: true + x-ignorable: true + put: + operationId: security.create_user_legacy.0_superseded + x-operation-group: security.create_user_legacy + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces the specified user. Legacy API. + parameters: + - $ref: '#/components/parameters/security.create_user_legacy___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/security.create_user_legacy' + responses: + '200': + $ref: '#/components/responses/security.create_user_legacy___200' + '201': + $ref: '#/components/responses/security.create_user_legacy___201' + deprecated: true + x-ignorable: true + delete: + operationId: security.delete_user_legacy.0_superseded + x-operation-group: security.delete_user_legacy + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Delete the specified user. Legacy API. + parameters: + - $ref: '#/components/parameters/security.delete_user_legacy___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.delete_user_legacy___200' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/user/{username}/authtoken: + post: + operationId: security.generate_user_token_legacy.0_superseded + x-operation-group: security.generate_user_token_legacy + x-version-added: '2.7' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Generates authorization token for the given user. Legacy API. Not Implemented. + parameters: + - $ref: '#/components/parameters/security.generate_user_token_legacy___path.username' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '501': + $ref: '#/components/responses/security.generate_user_token_legacy___501' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/validate: + get: + operationId: security.validate.0_superseded + x-operation-group: security.validate + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Checks whether the v6 security configuration is valid and ready to be migrated to v7. + parameters: + - $ref: '#/components/parameters/security.validate___query.accept_invalid' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.validate___200' + '400': + $ref: '#/components/responses/security.validate___400' + deprecated: true + x-ignorable: true + /_opendistro/_security/api/allowlist: + get: + operationId: security.get_allowlist.0_superseded + x-operation-group: security.get_allowlist + x-version-added: '2.1' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the current list of allowed APIs accessible to a normal user. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api + responses: + '200': + $ref: '#/components/responses/security.get_allowlist___200' + '403': + $ref: '#/components/responses/security.get_allowlist___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + put: + operationId: security.create_allowlist.0_superseded + x-operation-group: security.create_allowlist + x-version-added: '2.1' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Creates or replaces APIs permitted for users on the allow list. Requires a super admin certificate or REST API permissions. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api + requestBody: + $ref: '#/components/requestBodies/security.create_allowlist' + responses: + '200': + $ref: '#/components/responses/security.create_allowlist___200' + '403': + $ref: '#/components/responses/security.create_allowlist___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + patch: + operationId: security.patch_allowlist.0_superseded + x-operation-group: security.patch_allowlist + x-version-added: '2.1' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Updates the current list of APIs accessible for users on the allow list. + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#access-control-for-the-api + requestBody: + $ref: '#/components/requestBodies/security.patch_allowlist' + responses: + '200': + $ref: '#/components/responses/security.patch_allowlist___200' + '403': + $ref: '#/components/responses/security.patch_allowlist___403' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/authinfo: + get: + operationId: security.authinfo.0_superseded + x-operation-group: security.authinfo + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns or updates authentication information for the currently authenticated user. + parameters: + - $ref: '#/components/parameters/security.authinfo___query.auth_type' + - $ref: '#/components/parameters/security.authinfo___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.authinfo___200' + '500': + $ref: '#/components/responses/security.authinfo___500' + deprecated: true + x-ignorable: true + post: + operationId: security.authinfo.1_superseded + x-operation-group: security.authinfo + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Returns or updates authentication information for the currently authenticated user. + parameters: + - $ref: '#/components/parameters/security.authinfo___query.auth_type' + - $ref: '#/components/parameters/security.authinfo___query.verbose' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/security.authinfo___200' + '500': + $ref: '#/components/responses/security.authinfo___500' + deprecated: true + x-ignorable: true + /_opendistro/_security/health: + get: + operationId: security.health.0_superseded + x-operation-group: security.health + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Checks to see if the Security plugin is running. + parameters: + - $ref: '#/components/parameters/security.health___query.mode' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#health-check + responses: + '200': + $ref: '#/components/responses/security.health___200' + deprecated: true + x-ignorable: true + post: + operationId: security.health.1_superseded + x-operation-group: security.health + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Checks to see if the Security plugin is running. + parameters: + - $ref: '#/components/parameters/security.health___query.mode' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + externalDocs: + url: https://opensearch.org/docs/latest/security/access-control/api/#health-check + responses: + '200': + $ref: '#/components/responses/security.health___200' + deprecated: true + x-ignorable: true + /_opendistro/_security/kibanainfo: + get: + operationId: security.get_dashboards_info.0_superseded + x-operation-group: security.get_dashboards_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the current values for dynamic security settings for OpenSearch Dashboards. + responses: + '200': + $ref: '#/components/responses/security.get_dashboards_info___200' + '500': + $ref: '#/components/responses/security.get_dashboards_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + post: + operationId: security.post_dashboards_info.1_superseded + x-operation-group: security.post_dashboards_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the current values for dynamic security settings for OpenSearch Dashboards. + responses: + '200': + $ref: '#/components/responses/security.post_dashboards_info___200' + '500': + $ref: '#/components/responses/security.post_dashboards_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_security/tenantinfo: + get: + operationId: security.tenant_info.0_superseded + x-operation-group: security.tenant_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the names of current tenants. Requires super admin or `kibanaserver` permissions. + responses: + '200': + $ref: '#/components/responses/security.tenant_info___200' + '403': + $ref: '#/components/responses/security.tenant_info___403' + '500': + $ref: '#/components/responses/security.tenant_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + post: + operationId: security.tenant_info.1_superseded + x-operation-group: security.tenant_info + x-version-added: '1.0' + x-distributions-excluded: + - amazon-managed + - amazon-serverless + description: Retrieves the names of current tenants. Requires super admin or `kibanaserver` permissions. + responses: + '200': + $ref: '#/components/responses/security.tenant_info___200' + '403': + $ref: '#/components/responses/security.tenant_info___403' + '500': + $ref: '#/components/responses/security.tenant_info___500' + parameters: + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + deprecated: true + x-ignorable: true + /_opendistro/_sql: + post: + operationId: sql.query.0_superseded + x-operation-group: sql.query + x-version-added: '1.0' + description: Executes SQL or PPL queries against OpenSearch indexes. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/sql.query___query.format' + - $ref: '#/components/parameters/sql.query___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.query' + responses: + '200': + $ref: '#/components/responses/sql.query___200' + deprecated: true + x-ignorable: true + /_opendistro/_sql/_explain: + post: + operationId: sql.explain.0_superseded + x-operation-group: sql.explain + x-version-added: '1.0' + description: Returns the execution plan for a SQL or PPL query. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/sql.explain___query.format' + - $ref: '#/components/parameters/sql.explain___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.explain' + responses: + '200': + $ref: '#/components/responses/sql.explain___200' + deprecated: true + x-ignorable: true + /_opendistro/_sql/close: + post: + operationId: sql.close.0_superseded + x-operation-group: sql.close + x-version-added: '1.0' + description: Closes an open cursor to free server-side resources. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/sql-ppl-api/ + parameters: + - $ref: '#/components/parameters/sql.close___query.format' + - $ref: '#/components/parameters/sql.close___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.close' + responses: + '200': + $ref: '#/components/responses/sql.close___200' + deprecated: true + x-ignorable: true + /_opendistro/_sql/settings: + put: + operationId: sql.settings.0_superseded + x-operation-group: sql.settings + x-version-added: '1.0' + description: Updates SQL plugin settings in the OpenSearch cluster configuration. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/settings/ + parameters: + - $ref: '#/components/parameters/sql.settings___query.format' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.settings' + responses: + '200': + $ref: '#/components/responses/sql.settings___200' + deprecated: true + x-ignorable: true + /_opendistro/_sql/stats: + get: + operationId: sql.get_stats.0_superseded + x-operation-group: sql.get_stats + x-version-added: '1.0' + description: Retrieves performance metrics for the SQL plugin. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ + parameters: + - $ref: '#/components/parameters/sql.get_stats___query.format' + - $ref: '#/components/parameters/sql.get_stats___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/sql.get_stats___200' + deprecated: true + x-ignorable: true + post: + operationId: sql.post_stats.1_superseded + x-operation-group: sql.post_stats + x-version-added: '1.0' + description: Retrieves filtered performance metrics for the SQL plugin. + externalDocs: + url: https://opensearch.org/docs/latest/search-plugins/sql/monitoring/ + parameters: + - $ref: '#/components/parameters/sql.post_stats___query.format' + - $ref: '#/components/parameters/sql.post_stats___query.sanitize' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + requestBody: + $ref: '#/components/requestBodies/sql.post_stats' + responses: + '200': + $ref: '#/components/responses/sql.post_stats___200' + deprecated: true + x-ignorable: true + /_cluster/nodes/hotthreads: + get: + operationId: nodes.hot_threads.0_superseded + x-operation-group: nodes.hot_threads + x-ignorable: true + deprecated: true + x-deprecation-message: The hot accepts /_cluster/nodes as prefix for backwards compatibility reasons + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: Returns information about hot threads on each node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ + parameters: + - $ref: '#/components/parameters/nodes.hot_threads___query.ignore_idle_threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.interval' + - $ref: '#/components/parameters/nodes.hot_threads___query.snapshots' + - $ref: '#/components/parameters/nodes.hot_threads___query.threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.timeout' + - $ref: '#/components/parameters/nodes.hot_threads___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.hot_threads___200' + /_cluster/nodes/{node_id}/hotthreads: + get: + operationId: nodes.hot_threads.2_superseded + x-operation-group: nodes.hot_threads + x-ignorable: true + deprecated: true + x-deprecation-message: The hot accepts /_cluster/nodes as prefix for backwards compatibility reasons + x-version-added: '1.0' + x-version-deprecated: '1.0' + description: Returns information about hot threads on each node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ + parameters: + - $ref: '#/components/parameters/nodes.hot_threads___path.node_id' + - $ref: '#/components/parameters/nodes.hot_threads___query.ignore_idle_threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.interval' + - $ref: '#/components/parameters/nodes.hot_threads___query.snapshots' + - $ref: '#/components/parameters/nodes.hot_threads___query.threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.timeout' + - $ref: '#/components/parameters/nodes.hot_threads___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.hot_threads___200' + /_nodes/{node_id}/hotthreads: + get: + operationId: nodes.hot_threads.6_superseded + x-operation-group: nodes.hot_threads + x-version-added: '1.0' + description: Returns information about hot threads on each node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ + parameters: + - $ref: '#/components/parameters/nodes.hot_threads___path.node_id' + - $ref: '#/components/parameters/nodes.hot_threads___query.ignore_idle_threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.interval' + - $ref: '#/components/parameters/nodes.hot_threads___query.snapshots' + - $ref: '#/components/parameters/nodes.hot_threads___query.threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.timeout' + - $ref: '#/components/parameters/nodes.hot_threads___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.hot_threads___200' + deprecated: true + x-ignorable: true + /_nodes/hotthreads: + get: + operationId: nodes.hot_threads.4_superseded + x-operation-group: nodes.hot_threads + x-version-added: '1.0' + description: Returns information about hot threads on each node in the cluster. + externalDocs: + url: https://opensearch.org/docs/latest/api-reference/nodes-apis/nodes-hot-threads/ + parameters: + - $ref: '#/components/parameters/nodes.hot_threads___query.ignore_idle_threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.interval' + - $ref: '#/components/parameters/nodes.hot_threads___query.snapshots' + - $ref: '#/components/parameters/nodes.hot_threads___query.threads' + - $ref: '#/components/parameters/nodes.hot_threads___query.timeout' + - $ref: '#/components/parameters/nodes.hot_threads___query.type' + - $ref: '#/components/parameters/_global___query.pretty' + - $ref: '#/components/parameters/_global___query.human' + - $ref: '#/components/parameters/_global___query.error_trace' + - $ref: '#/components/parameters/_global___query.source' + - $ref: '#/components/parameters/_global___query.filter_path' + responses: + '200': + $ref: '#/components/responses/nodes.hot_threads___200' + deprecated: true + x-ignorable: true +components: + parameters: + _global___query.pretty: + name: pretty + in: query + description: Whether to pretty-format the returned JSON response. + x-protobuf-excluded: true + schema: + type: boolean + default: false + x-global: true + _global___query.human: + name: human + in: query + description: Whether to return human-readable values for statistics. + schema: + type: boolean + default: false + x-global: true + _global___query.error_trace: + name: error_trace + in: query + description: Whether to include the stack trace of returned errors. + schema: + type: boolean + default: false + x-global: true + _global___query.source: + name: source + in: query + x-protobuf-excluded: true + description: The URL-encoded request definition. Useful for libraries that do not accept a request body for non-POST requests. + schema: + type: string + x-global: true + _global___query.filter_path: + name: filter_path + in: query + description: A comma-separated list of filters used to filter the response. Use wildcards to match any field or part of a field's name. To exclude fields, use `-`. + schema: + $ref: '#/components/schemas/_common___StringOrStringArray' + x-global: true + asynchronous_search.delete___path.id: + name: id + in: path + schema: + type: string + required: true + asynchronous_search.get___path.id: + name: id + in: path + schema: + type: string + required: true + asynchronous_search.search___query.index: + name: index + in: query + description: The name of the index to be searched. Can be an individual name, a comma-separated list of indexes, or a wildcard expression of index names. + schema: + type: string + asynchronous_search.search___query.keep_alive: + name: keep_alive + in: query + description: |- + The amount of time that the result is saved in the cluster. For example, `2d` means that the results are stored in the cluster for 48 hours. + The saved search results are deleted after this period or if the search is canceled. Note that this includes the query execution time. + If the query exceeds this amount of time, the process cancels this query automatically. + schema: + type: string + asynchronous_search.search___query.keep_on_completion: + name: keep_on_completion + in: query + description: Whether to save the results in the cluster after the search is complete. You can examine the stored results at a later time. + schema: + type: boolean + asynchronous_search.search___query.wait_for_completion_timeout: + name: wait_for_completion_timeout + in: query + description: The amount of time to wait for the results. You can poll the remaining results based on an ID. The maximum value is 300 seconds. Default is `1s`. + schema: + type: string + bulk_stream___path.index: + in: path + name: index + description: Name of the data stream, index, or index alias to perform bulk actions on. + required: true + schema: + $ref: '#/components/schemas/_common___IndexName' + style: simple + bulk_stream___query._source: + in: query + name: _source + description: '`true` or `false` to return the `_source` field or not, or a list of fields to return.' + schema: + $ref: '#/components/schemas/_core.search___SourceConfigParam' + style: form + bulk_stream___query._source_excludes: + in: query + name: _source_excludes + description: A comma-separated list of source fields to exclude from the response. + schema: + $ref: '#/components/schemas/_common___Fields' + style: form + bulk_stream___query._source_includes: + in: query + name: _source_includes + description: A comma-separated list of source fields to include in the response. + schema: + $ref: '#/components/schemas/_common___Fields' + style: form + bulk_stream___query.batch_interval: + in: query + name: batch_interval + description: Specifies for how long bulk operations should be accumulated into a batch before sending the batch to data nodes. + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + bulk_stream___query.batch_size: + in: query + name: batch_size + description: Specifies how many bulk operations should be accumulated into a batch before sending the batch to data nodes. + schema: + $ref: '#/components/schemas/_common___BatchSize' + style: form + x-default: 1 + bulk_stream___query.pipeline: + in: query + name: pipeline + description: |- + ID of the pipeline to use to preprocess incoming documents. + If the index has a default ingest pipeline specified, then setting the value to `_none` disables the default ingest pipeline for this request. + If a final pipeline is configured it will always run, regardless of the value of this parameter. + schema: + type: string + style: form + bulk_stream___query.refresh: + in: query + name: refresh + description: |- + If `true`, OpenSearch refreshes the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` do nothing with refreshes. + Valid values: `true`, `false`, `wait_for`. + schema: + $ref: '#/components/schemas/_common___Refresh' + style: form + bulk_stream___query.require_alias: + in: query + name: require_alias + description: If `true`, the request's actions must target an index alias. + schema: + type: boolean + default: false + style: form + bulk_stream___query.routing: + in: query + name: routing + description: A custom value used to route operations to a specific shard. + schema: + $ref: '#/components/schemas/_common___RoutingInQueryString' + style: form + bulk_stream___query.timeout: + in: query + name: timeout + description: 'Period each action waits for the following operations: automatic index creation, dynamic mapping updates, waiting for active shards.' + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + bulk_stream___query.type: + name: type + in: query + description: Default document type for items which don't provide one. + schema: + type: string + description: Default document type for items which don't provide one. + bulk_stream___query.wait_for_active_shards: + in: query + name: wait_for_active_shards + description: |- + The number of shard copies that must be active before proceeding with the operation. + Set to all or any positive integer up to the total number of shards in the index (`number_of_replicas+1`). + schema: + $ref: '#/components/schemas/_common___WaitForActiveShards' + style: form + x-default: '1' + bulk___path.index: + in: path + name: index + description: Name of the data stream, index, or index alias to perform bulk actions on. + required: true + schema: + $ref: '#/components/schemas/_common___IndexName' + style: simple + x-protobuf-excluded: true + bulk___query._source: + in: query + name: _source + description: '`true` or `false` to return the `_source` field or not, or a list of fields to return.' + schema: + $ref: '#/components/schemas/_core.search___SourceConfigParam' + style: form + bulk___query._source_excludes: + in: query + name: _source_excludes + description: A comma-separated list of source fields to exclude from the response. + schema: + $ref: '#/components/schemas/_common___Fields' + style: form + bulk___query._source_includes: + in: query + name: _source_includes + description: A comma-separated list of source fields to include in the response. + schema: + $ref: '#/components/schemas/_common___Fields' + style: form + bulk___query.index: + in: query + name: index + description: Name of the data stream, index, or index alias to perform bulk actions on. + schema: + $ref: '#/components/schemas/_common___IndexName' + style: form + bulk___query.pipeline: + in: query + name: pipeline + description: |- + ID of the pipeline to use to preprocess incoming documents. + If the index has a default ingest pipeline specified, then setting the value to `_none` disables the default ingest pipeline for this request. + If a final pipeline is configured it will always run, regardless of the value of this parameter. + schema: + type: string + style: form + bulk___query.refresh: + in: query + name: refresh + description: |- + If `true`, OpenSearch refreshes the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` do nothing with refreshes. + Valid values: `true`, `false`, `wait_for`. + schema: + $ref: '#/components/schemas/_common___Refresh' + style: form + bulk___query.require_alias: + in: query + name: require_alias + description: If `true`, the request's actions must target an index alias. + schema: + type: boolean + default: false + style: form + bulk___query.routing: + in: query + name: routing + description: A custom value used to route operations to a specific shard. + schema: + $ref: '#/components/schemas/_common___Routing' + style: form + bulk___query.timeout: + in: query + name: timeout + description: 'Period each action waits for the following operations: automatic index creation, dynamic mapping updates, waiting for active shards.' + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + bulk___query.type: + name: type + in: query + description: Default document type for items which don't provide one. + schema: + type: string + description: Default document type for items which don't provide one. + bulk___query.wait_for_active_shards: + in: query + name: wait_for_active_shards + description: |- + The number of shard copies that must be active before proceeding with the operation. + Set to all or any positive integer up to the total number of shards in the index (`number_of_replicas+1`). + schema: + $ref: '#/components/schemas/_common___WaitForActiveShards' + style: form + x-default: '1' + cat.aliases___path.name: + in: path + name: name + required: true + schema: + $ref: '#/components/schemas/_common___Names' + style: simple + cat.aliases___query.expand_wildcards: + in: query + name: expand_wildcards + schema: + $ref: '#/components/schemas/_common___ExpandWildcards' + style: form + cat.aliases___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.aliases___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.aliases___query.help: + name: help + in: query + description: Returns help information. + schema: + description: Returns help information. + type: boolean + default: false + cat.aliases___query.local: + name: local + in: query + description: Whether to return information from the local node only instead of from the cluster manager node. + schema: + type: boolean + default: false + description: Whether to return information from the local node only instead of from the cluster manager node. + cat.aliases___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.aliases___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.all_pit_segments___query.bytes: + name: bytes + in: query + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + cat.all_pit_segments___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.all_pit_segments___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.all_pit_segments___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.all_pit_segments___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.all_pit_segments___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.allocation___path.node_id: + in: path + name: node_id + description: A comma-separated list of node IDs or names used to limit the returned information. + required: true + schema: + $ref: '#/components/schemas/_common___NodeIds' + style: simple + cat.allocation___query.bytes: + in: query + name: bytes + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + style: form + cat.allocation___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: A timeout for connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.allocation___query.format: + name: format + in: query + description: A short version of the HTTP `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.allocation___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.allocation___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.allocation___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from cluster-manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from cluster-manager node. + cat.allocation___query.master_timeout: + name: master_timeout + in: query + description: A timeout for connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.allocation___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.allocation___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.cluster_manager___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: A timeout for connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.cluster_manager___query.format: + name: format + in: query + description: A short version of the HTTP `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.cluster_manager___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.cluster_manager___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.cluster_manager___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.cluster_manager___query.master_timeout: + name: master_timeout + in: query + description: A timeout for connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.cluster_manager___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.cluster_manager___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.count___path.index: + in: path + name: index + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + required: true + schema: + $ref: '#/components/schemas/_common___Indices' + style: simple + cat.count___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.count___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.count___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.count___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.count___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.fielddata___path.fields: + in: path + name: fields + description: |- + A comma-separated list of fields used to limit the amount of returned information. + To retrieve all fields, omit this parameter. + required: true + schema: + $ref: '#/components/schemas/_common___Fields' + style: simple + cat.fielddata___query.bytes: + in: query + name: bytes + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + style: form + cat.fielddata___query.fields: + in: query + name: fields + description: A comma-separated list of fields used to limit the amount of returned information. + schema: + $ref: '#/components/schemas/_common___Fields' + style: form + cat.fielddata___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.fielddata___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.fielddata___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.fielddata___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.fielddata___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.health___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.health___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.health___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.health___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.health___query.time: + in: query + name: time + description: The unit used to display time values. + schema: + $ref: '#/components/schemas/_common___TimeUnit' + style: form + cat.health___query.ts: + in: query + name: ts + description: When `true`, returns `HH:MM:SS` and Unix epoch timestamps. + schema: + type: boolean + default: true + style: form + cat.health___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.indices___path.index: + in: path + name: index + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + required: true + schema: + $ref: '#/components/schemas/_common___Indices' + style: simple + cat.indices___query.bytes: + in: query + name: bytes + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + style: form + cat.indices___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.indices___query.expand_wildcards: + in: query + name: expand_wildcards + schema: + $ref: '#/components/schemas/_common___ExpandWildcards' + style: form + cat.indices___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.indices___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.indices___query.health: + in: query + name: health + description: Limits indexes based on their health status. Supported values are `green`, `yellow`, and `red`. + schema: + $ref: '#/components/schemas/_common___HealthStatus' + style: form + cat.indices___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.indices___query.include_unloaded_segments: + in: query + name: include_unloaded_segments + description: Whether to include information from segments not loaded into memory. + schema: + type: boolean + default: false + style: form + cat.indices___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.indices___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.indices___query.pri: + in: query + name: pri + description: When `true`, returns information only from the primary shards. + schema: + type: boolean + default: false + style: form + cat.indices___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.indices___query.time: + in: query + name: time + description: Specifies the time units. + schema: + $ref: '#/components/schemas/_common___TimeUnit' + style: form + cat.indices___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.master___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.master___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.master___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.master___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.master___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.master___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.master___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.master___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.nodeattrs___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.nodeattrs___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.nodeattrs___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.nodeattrs___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.nodeattrs___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.nodeattrs___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.nodeattrs___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.nodeattrs___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.nodes___query.bytes: + in: query + name: bytes + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + style: form + cat.nodes___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.nodes___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.nodes___query.full_id: + in: query + name: full_id + description: When `true`, returns the full node ID. When `false`, returns the shortened node ID. + schema: + $ref: '#/components/schemas/_common___StringifiedBoolean' + default: false + style: form + cat.nodes___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.nodes___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.nodes___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + deprecated: true + x-version-deprecated: '1.0' + x-deprecation-message: This parameter does not cause this API to act locally. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.nodes___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.nodes___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.nodes___query.time: + name: time + in: query + description: Specifies the time units, for example, `5d` or `7h`. For more information, see [Supported units](https://opensearch.org/docs/latest/api-reference/units/). + schema: + $ref: '#/components/schemas/_common___TimeUnit' + cat.nodes___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.pending_tasks___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.pending_tasks___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.pending_tasks___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.pending_tasks___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.pending_tasks___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.pending_tasks___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.pending_tasks___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.pending_tasks___query.time: + name: time + in: query + description: Specifies the time units, for example, `5d` or `7h`. For more information, see [Supported units](https://opensearch.org/docs/latest/api-reference/units/). + schema: + $ref: '#/components/schemas/_common___TimeUnit' + cat.pending_tasks___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.pit_segments___query.bytes: + name: bytes + in: query + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + cat.pit_segments___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.pit_segments___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.pit_segments___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.pit_segments___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.pit_segments___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.plugins___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.plugins___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.plugins___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.plugins___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.plugins___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.plugins___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.plugins___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.plugins___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.recovery___path.index: + in: path + name: index + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + required: true + schema: + $ref: '#/components/schemas/_common___Indices' + style: simple + cat.recovery___query.active_only: + in: query + name: active_only + description: If `true`, the response only includes ongoing shard recoveries. + schema: + type: boolean + default: false + style: form + cat.recovery___query.bytes: + in: query + name: bytes + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + style: form + cat.recovery___query.detailed: + in: query + name: detailed + description: When `true`, includes detailed information about shard recoveries. + schema: + type: boolean + default: false + style: form + cat.recovery___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.recovery___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.recovery___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.recovery___query.index: + name: index + in: query + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + style: form + schema: + type: array + items: + type: string + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + explode: true + cat.recovery___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.recovery___query.time: + name: time + in: query + description: Specifies the time units, for example, `5d` or `7h`. For more information, see [Supported units](https://opensearch.org/docs/latest/api-reference/units/). + schema: + $ref: '#/components/schemas/_common___TimeUnit' + cat.recovery___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.repositories___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.repositories___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.repositories___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.repositories___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.repositories___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.repositories___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.repositories___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.repositories___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.segment_replication___path.index: + name: index + in: path + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + schema: + type: array + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + items: + type: string + required: true + style: simple + cat.segment_replication___query.active_only: + name: active_only + in: query + description: When `true`, the response only includes ongoing segment replication events. + schema: + type: boolean + default: false + description: When `true`, the response only includes ongoing segment replication events. + cat.segment_replication___query.allow_no_indices: + name: allow_no_indices + in: query + description: Whether to ignore the index if a wildcard index expression resolves to no concrete indexes. This includes the `_all` string or when no indexes have been specified. + schema: + type: boolean + description: Whether to ignore the index if a wildcard index expression resolves to no concrete indexes. This includes the `_all` string or when no indexes have been specified. + cat.segment_replication___query.bytes: + name: bytes + in: query + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + cat.segment_replication___query.completed_only: + name: completed_only + in: query + description: When `true`, the response only includes the last-completed segment replication events. + schema: + type: boolean + default: false + description: When `true`, the response only includes the last-completed segment replication events. + cat.segment_replication___query.detailed: + name: detailed + in: query + description: When `true`, the response includes additional metrics for each stage of a segment replication event. + schema: + type: boolean + default: false + description: When `true`, the response includes additional metrics for each stage of a segment replication event. + cat.segment_replication___query.expand_wildcards: + name: expand_wildcards + in: query + schema: + $ref: '#/components/schemas/_common___ExpandWildcards' + cat.segment_replication___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.segment_replication___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.segment_replication___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.segment_replication___query.ignore_throttled: + name: ignore_throttled + in: query + description: Whether specified concrete, expanded, or aliased indexes should be ignored when throttled. + schema: + type: boolean + description: Whether specified concrete, expanded, or aliased indexes should be ignored when throttled. + cat.segment_replication___query.ignore_unavailable: + name: ignore_unavailable + in: query + description: Whether the specified concrete indexes should be ignored when missing or closed. + schema: + type: boolean + description: Whether the specified concrete indexes should be ignored when missing or closed. + cat.segment_replication___query.index: + name: index + in: query + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + style: form + schema: + type: array + items: + type: string + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`. + explode: true + cat.segment_replication___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.segment_replication___query.shards: + name: shards + in: query + description: A comma-separated list of shards to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of shards to display. + explode: true + cat.segment_replication___query.time: + name: time + in: query + description: Specifies the time units, for example, `5d` or `7h`. For more information, see [Supported units](https://opensearch.org/docs/latest/api-reference/units/). + schema: + $ref: '#/components/schemas/_common___TimeUnit' + cat.segment_replication___query.timeout: + name: timeout + in: query + description: The operation timeout. + schema: + $ref: '#/components/schemas/_common___Duration' + cat.segment_replication___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.segments___path.index: + in: path + name: index + description: |- + A comma-separated list of data streams, indexes, and aliases used to limit the request. + Supports wildcards (`*`). + To target all data streams and indexes, omit this parameter or use `*` or `_all`. + required: true + schema: + $ref: '#/components/schemas/_common___Indices' + style: simple + cat.segments___query.bytes: + in: query + name: bytes + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + style: form + cat.segments___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.segments___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.segments___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.segments___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.segments___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.segments___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.segments___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.shards___path.index: + in: path + name: index + required: true + schema: + $ref: '#/components/schemas/_common___Indices' + style: simple + cat.shards___query.bytes: + in: query + name: bytes + description: The units used to display byte values. + schema: + $ref: '#/components/schemas/_common___ByteUnit' + style: form + cat.shards___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.shards___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.shards___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.shards___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.shards___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.shards___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.shards___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.shards___query.time: + name: time + in: query + schema: + $ref: '#/components/schemas/_common___TimeUnit' + cat.shards___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.snapshots___path.repository: + in: path + name: repository + description: |- + A comma-separated list of snapshot repositories used to limit the request. + Accepts wildcard expressions. + `_all` returns all repositories. + If any repository fails during the request, OpenSearch returns an error. + required: true + schema: + $ref: '#/components/schemas/_common___Names' + style: simple + cat.snapshots___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.snapshots___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.snapshots___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.snapshots___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.snapshots___query.ignore_unavailable: + in: query + name: ignore_unavailable + description: When `true`, the response does not include information from unavailable snapshots. + schema: + type: boolean + default: false + style: form + cat.snapshots___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.snapshots___query.repository: + in: query + name: repository + description: |- + A comma-separated list of snapshot repositories used to limit the request. + Accepts wildcard expressions. + `_all` returns all repositories. + If any repository fails during the request, OpenSearch returns an error. + required: true + schema: + $ref: '#/components/schemas/_common___Names' + cat.snapshots___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.snapshots___query.time: + name: time + in: query + description: Specifies the time units, for example, `5d` or `7h`. For more information, see [Supported units](https://opensearch.org/docs/latest/api-reference/units/). + schema: + $ref: '#/components/schemas/_common___TimeUnit' + cat.snapshots___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.tasks___query.actions: + in: query + name: actions + description: The task action names used to limit the response. + schema: + type: array + items: + type: string + style: form + cat.tasks___query.detailed: + in: query + name: detailed + description: If `true`, the response includes detailed information about shard recoveries. + schema: + type: boolean + default: false + style: form + cat.tasks___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.tasks___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.tasks___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.tasks___query.nodes: + name: nodes + in: query + description: |- + A comma-separated list of node IDs or names used to limit the returned information. + Use `_local` to return information from the node to which you're connecting, specify a specific node from which to get information, or keep the parameter empty to get information from all nodes. + style: form + schema: + type: array + items: + type: string + description: |- + A comma-separated list of node IDs or names used to limit the returned information. + Use `_local` to return information from the node to which you're connecting, specify a specific node from which to get information, or keep the parameter empty to get information from all nodes. + cat.tasks___query.parent_task_id: + in: query + name: parent_task_id + description: The parent task identifier, which is used to limit the response. + schema: + type: string + style: form + cat.tasks___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.tasks___query.time: + name: time + in: query + description: Specifies the time units, for example, `5d` or `7h`. For more information, see [Supported units](https://opensearch.org/docs/latest/api-reference/units/). + schema: + $ref: '#/components/schemas/_common___TimeUnit' + cat.tasks___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.templates___path.name: + in: path + name: name + description: |- + The name of the template to return. + Accepts wildcard expressions. If omitted, all templates are returned. + required: true + schema: + $ref: '#/components/schemas/_common___Name' + style: simple + cat.templates___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.templates___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.templates___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.templates___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.templates___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.templates___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.templates___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.templates___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + cat.thread_pool___path.thread_pool_patterns: + in: path + name: thread_pool_patterns + description: |- + A comma-separated list of thread pool names used to limit the request. + Accepts wildcard expressions. + required: true + schema: + $ref: '#/components/schemas/_common___Names' + style: simple + cat.thread_pool___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: A timeout for connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cat.thread_pool___query.format: + name: format + in: query + description: A short version of the `Accept` header, such as `json` or `yaml`. + schema: + $ref: '#/components/schemas/_common___CatResponseFormat' + cat.thread_pool___query.h: + name: h + in: query + description: A comma-separated list of column names to display. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names to display. + explode: true + cat.thread_pool___query.help: + name: help + in: query + description: Returns help information. + schema: + type: boolean + default: false + description: Returns help information. + cat.thread_pool___query.local: + name: local + in: query + description: Returns local information but does not retrieve the state from the cluster manager node. + schema: + type: boolean + default: false + description: Returns local information but does not retrieve the state from the cluster manager node. + cat.thread_pool___query.master_timeout: + name: master_timeout + in: query + description: The amount of time allowed to establish a connection to the cluster manager node. + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + deprecated: true + cat.thread_pool___query.s: + name: s + in: query + description: A comma-separated list of column names or column aliases to sort by. + style: form + schema: + type: array + items: + type: string + description: A comma-separated list of column names or column aliases to sort by. + explode: true + cat.thread_pool___query.size: + name: size + in: query + description: The multiplier in which to display values. + schema: + type: integer + description: The multiplier in which to display values. + format: int32 + cat.thread_pool___query.v: + name: v + in: query + description: Enables verbose mode, which displays column headers. + schema: + type: boolean + default: false + description: Enables verbose mode, which displays column headers. + clear_scroll___path.scroll_id: + in: path + name: scroll_id + description: |- + A comma-separated list of scroll IDs to clear. + To clear all scroll IDs, use `_all`. + required: true + deprecated: true + schema: + $ref: '#/components/schemas/_common___ScrollIds' + style: simple + cluster.allocation_explain___query.include_disk_info: + in: query + name: include_disk_info + description: When `true`, returns information about disk usage and shard sizes. + schema: + type: boolean + default: false + style: form + cluster.allocation_explain___query.include_yes_decisions: + in: query + name: include_yes_decisions + description: When `true`, returns any `YES` decisions in the allocation explanation. `YES` decisions indicate when a particular shard allocation attempt was successful for the given node. + schema: + type: boolean + default: false + style: form + cluster.delete_component_template___path.name: + in: path + name: name + description: |- + The name of the component template to delete. + Supports wildcard (*) expressions. + required: true + schema: + $ref: '#/components/schemas/_common___Name' + style: simple + cluster.delete_component_template___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time to wait for a response from the cluster manager node. For more information about supported time units, see [Common parameters](https://opensearch.org/docs/latest/api-reference/common-parameters/#time-units). + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cluster.delete_component_template___query.master_timeout: + in: query + name: master_timeout + deprecated: true + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + cluster.delete_component_template___query.timeout: + in: query + name: timeout + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + cluster.delete_voting_config_exclusions___query.wait_for_removal: + in: query + name: wait_for_removal + description: |- + Specifies whether to wait for all excluded nodes to be removed from the + cluster before clearing the voting configuration exclusions list. + When `true`, all excluded nodes are removed from + the cluster before this API takes any action. When `false`, the + voting configuration exclusions list is cleared even if some excluded + nodes are still in the cluster. + schema: + type: boolean + default: true + style: form + cluster.exists_component_template___path.name: + in: path + name: name + description: |- + The name of the component template. + Wildcard (*) expressions are supported. + required: true + schema: + $ref: '#/components/schemas/_common___Name' + style: simple + cluster.exists_component_template___query.cluster_manager_timeout: + name: cluster_manager_timeout + description: The amount of time to wait for a response from the cluster manager node. For more information about supported time units, see [Common parameters](https://opensearch.org/docs/latest/api-reference/common-parameters/#time-units). + in: query + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cluster.exists_component_template___query.local: + in: query + name: local + description: |- + When `true`, the request retrieves information from the local node only. + When `false`, information is retrieved from the cluster manager node. + schema: + type: boolean + default: false + style: form + cluster.exists_component_template___query.master_timeout: + in: query + name: master_timeout + deprecated: true + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + cluster.get_component_template___path.name: + in: path + name: name + description: |- + The name of the component template to retrieve. + Wildcard (`*`) expressions are supported. + required: true + schema: + $ref: '#/components/schemas/_common___Name' + style: simple + cluster.get_component_template___query.cluster_manager_timeout: + name: cluster_manager_timeout + description: The amount of time to wait for a response from the cluster manager node. For more information about supported time units, see [Common parameters](https://opensearch.org/docs/latest/api-reference/common-parameters/#time-units). + in: query + schema: + $ref: '#/components/schemas/_common___Duration' + default: 30s + x-version-added: '2.0' + cluster.get_component_template___query.flat_settings: + in: query + name: flat_settings + description: |- + Whether to return settings in the flat form, which can improve readability, especially for heavily nested settings. + For example, the flat form of `"cluster": { "max_shards_per_node": 500 }` is `"cluster.max_shards_per_node": "500"`. + schema: + type: boolean + default: false + style: form + cluster.get_component_template___query.local: + in: query + name: local + description: |- + When `true`, the request retrieves information from the local node only. + When `false`, information is retrieved from the cluster manager node. + schema: + type: boolean + default: false + style: form + cluster.get_component_template___query.master_timeout: + in: query + name: master_timeout + deprecated: true + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + cluster.get_decommission_awareness___path.awareness_attribute_name: + name: awareness_attribute_name + in: path + description: The name of the awareness attribute. + schema: + type: string + description: The name of the awareness attribute. + required: true + cluster.get_settings___query.cluster_manager_timeout: + name: cluster_manager_timeout + description: The amount of time to wait for a response from the cluster manager node. For more information about supported time units, see [Common parameters](https://opensearch.org/docs/latest/api-reference/common-parameters/#time-units). + in: query + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cluster.get_settings___query.flat_settings: + in: query + name: flat_settings + description: |- + Whether to return settings in the flat form, which can improve readability, especially for heavily nested settings. + For example, the flat form of `"cluster": { "max_shards_per_node": 500 }` is `"cluster.max_shards_per_node": "500"`. + schema: + type: boolean + default: false + style: form + cluster.get_settings___query.include_defaults: + in: query + name: include_defaults + description: When `true`, returns default cluster settings from the local node. + schema: + type: boolean + default: false + style: form + cluster.get_settings___query.master_timeout: + in: query + name: master_timeout + deprecated: true + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + cluster.get_settings___query.timeout: + in: query + name: timeout + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + cluster.get_weighted_routing___path.attribute: + name: attribute + in: path + description: The name of the awareness attribute. + schema: + type: string + description: The name of the awareness attribute. + required: true + cluster.health___path.index: + in: path + name: index + required: true + schema: + $ref: '#/components/schemas/_common___Indices' + style: simple + cluster.health___query.awareness_attribute: + name: awareness_attribute + in: query + description: The name of the awareness attribute for which to return the cluster health status (for example, `zone`). Applicable only if `level` is set to `awareness_attributes`. + schema: + type: string + description: The name of the awareness attribute for which to return the cluster health status (for example, `zone`). Applicable only if `level` is set to `awareness_attributes`. + cluster.health___query.cluster_manager_timeout: + name: cluster_manager_timeout + in: query + description: The amount of time to wait for a response from the cluster manager node. For more information about supported time units, see [Common parameters](https://opensearch.org/docs/latest/api-reference/common-parameters/#time-units). + schema: + $ref: '#/components/schemas/_common___Duration' + x-version-added: '2.0' + cluster.health___query.expand_wildcards: + in: query + name: expand_wildcards + schema: + $ref: '#/components/schemas/_common___ExpandWildcards' + default: open + style: form + cluster.health___query.level: + in: query + name: level + schema: + $ref: '#/components/schemas/cluster.health___Level' + default: cluster + style: form + cluster.health___query.local: + in: query + name: local + description: Whether to return information from the local node only instead of from the cluster manager node. + schema: + type: boolean + default: false + style: form + cluster.health___query.master_timeout: + in: query + name: master_timeout + deprecated: true + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + x-version-deprecated: '2.0' + x-deprecation-message: To promote inclusive language, use `cluster_manager_timeout` instead. + cluster.health___query.timeout: + in: query + name: timeout + description: The amount of time to wait for a response from the cluster manager node. For more information about supported time units, see [Common parameters](https://opensearch.org/docs/latest/api-reference/common-parameters/#time-units). + schema: + $ref: '#/components/schemas/_common___Duration' + style: form + cluster.health___query.wait_for_active_shards: + in: query + name: wait_for_active_shards + schema: + default: 0 + $ref: '#/components/schemas/_common___WaitForActiveShards' + style: form + cluster.health___query.wait_for_events: + in: query + name: wait_for_events + schema: + $ref: '#/components/schemas/_common___WaitForEvents' + style: form + cluster.health___query.wait_for_no_initializing_shards: + in: query + name: wait_for_no_initializing_shards + description: Whether to wait until there are no initializing shards in the cluster. + schema: + type: boolean + default: false + style: form + cluster.health___query.wait_for_no_relocating_shards: + in: query + name: wait_for_no_relocating_shards + description: Whether to wait until there are no relocating shards in the cluster. + schema: + type: boolean + default: false + style: form + cluster.health___query.wait_for_nodes: + in: query + name: wait_for_nodes + description: Waits until the specified number of nodes (`N`) is available. Accepts `>=N`, `<=N`, `>N`, and `