New to Kestra?
Use blueprints to kickstart your first workflows.
Use Kestra to extract API data, index it into an Elasticsearch index, and verify it with parallel search and scroll queries in declarative YAML.
Build a complete extract, load, and verify pipeline for Elasticsearch with Kestra. This blueprint pulls JSON from a public REST API, indexes the document into an Elasticsearch index, and immediately validates it with both a search query and a scroll query. It is an ideal starting point for ingesting API payloads, application events, or operational records into Elasticsearch and confirming that they are queryable, without writing custom ingestion scripts.
extract task (io.kestra.plugin.core.http.Request) calls the PokeAPI endpoint for the Pokemon name supplied in the pokemon input and returns the JSON response body.load task (io.kestra.plugin.elasticsearch.Put) writes that body into the local index, keyed by the Pokemon name, connecting to the cluster defined in the host variable.parallel task (io.kestra.plugin.core.flow.Parallel) runs two reads at once: search (io.kestra.plugin.elasticsearch.Search) issues a term query on the name field, and scroll (io.kestra.plugin.elasticsearch.Scroll) pages through matching documents to confirm the data is indexed and retrievable.Put step for indexing documents by key.Search and Scroll reads that prove indexing succeeded.pokemon input so each run targets a different record.Elasticsearch indexes and serves data, but it does not schedule, retry, or coordinate the upstream extraction and downstream verification around it. With Kestra you define the whole flow in declarative YAML, trigger it on a schedule or an event, add retries and alerting around each task, and capture execution lineage from the API call through indexing to the search results. The Parallel task fans the verification reads out concurrently, something an Elasticsearch query alone cannot orchestrate.
host variable (defaults to http://host.docker.internal:9200).This flow uses no secrets. It connects to an open local Elasticsearch instance and a public API. For a secured cluster, move credentials into Kestra secrets and reference them with {{ secret('NAME') }} in the connection block.
docker run -d --name elasticsearch -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" docker.elastic.co/elasticsearch/elasticsearch:7.10.2.pokemon input value.search and scroll outputs to confirm the document was indexed.host variable at a managed or self-hosted production cluster.Schedule or webhook trigger to ingest on a cadence or on demand.Put with a bulk load task for high-volume ingestion.