Add a step and choose the Elasticsearch connector.
Pick the Create or update a component template (POST) action (under indices).
Fill in the fields below, then reference the result from later steps as {{createOrUpdateAComponentTemplatePost.response.data}}.
Request
Path parameters
namestringrequired
Name of the component template to create.
Elasticsearch includes the following built-in component templates: `logs-mappings`; `logs-settings`; `metrics-mappings`; `metrics-settings`;`synthetics-mapping`; `synthetics-settings`.
Elastic Agent uses these templates to configure backing indices for its data streams.
If you use Elastic Agent and want to overwrite one of these templates, set the `version` for your replacement template higher than the current version.
If you don’t use Elastic Agent and want to disable all built-in component and index templates, set `stack.templates.enabled` to `false` using the cluster update settings API.
Query parameters
createboolean
If `true`, this request cannot replace or update existing component templates.
causestring
User defined reason for create the component template.
master_timeoutoneOf
Period to wait for a connection to the master node.
If no response is received before the timeout expires, the request fails and returns an error.
Response
Returns 200 with an object. Read it in later steps with {{createOrUpdateAComponentTemplatePost.response.data.<field>}}.
acknowledgedboolean
For a successful response, this value is always true. On failure, an exception is returned instead.
json
{"acknowledged":false}
Need more? See the Elasticsearch guide for connection setup and behaviour shared by every action.
Was this page helpful?
Create or update a component template (POST) — Elasticsearch — Documentation