OpenSearch/docs/java-rest/high-level/cluster/get_component_template.asciidoc
Andrei Dan a7968a1a5e
[7.x] HLRC: document index template v2 and component template APIs () ()
This documents the index template v2 and component template APIs in the
high level rest client.

(cherry picked from commit 9bcf89b1e27613ab8887ce611ec2b0d1356cba8b)
Signed-off-by: Andrei Dan <andrei.dan@elastic.co>
2020-05-05 19:51:54 +01:00

43 lines
1.5 KiB
Plaintext

--
:api: get-component-templates
:request: GetComponentTemplatesRequest
:response: GetComponentTemplatesResponse
--
[id="{upid}-{api}"]
=== Get Component Templates API
The Get Component Templates API allows to retrieve information about one or more component templates.
[id="{upid}-{api}-request"]
==== Get Component Templates Request
A +{request}+ specifies one component template name to retrieve.
To return all component templates omit the name altogether.
["source","java",subs="attributes,callouts,macros"]
--------------------------------------------------
include-tagged::{doc-tests-file}[{api}-request]
--------------------------------------------------
<1> A single component template name
["source","java",subs="attributes,callouts,macros"]
--------------------------------------------------
include-tagged::{doc-tests-file}[{api}-request-masterTimeout]
--------------------------------------------------
<1> Timeout to connect to the master node as a `TimeValue`
<2> Timeout to connect to the master node as a `String`
include::../execution.asciidoc[]
[id="{upid}-{api}-response"]
==== Get Component Templates Response
The returned +{response}+ consists a map of component template names and their corresponding definition.
["source","java",subs="attributes,callouts,macros"]
--------------------------------------------------
include-tagged::{doc-tests-file}[{api}-response]
--------------------------------------------------
<1> A map of matching component template names and the corresponding definitions