1. Packages
  2. Packages
  3. Elasticstack Provider
  4. API Docs
  5. ElasticsearchWatch
Viewing docs for elasticstack 0.14.5
published on Thursday, Apr 23, 2026 by elastic
Viewing docs for elasticstack 0.14.5
published on Thursday, Apr 23, 2026 by elastic

    Manage Watches. See the Watcher API documentation for more details.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as elasticstack from "@pulumi/elasticstack";
    
    const example = new elasticstack.ElasticsearchWatch("example", {
        watchId: "test_watch",
        active: true,
        trigger: JSON.stringify({
            schedule: {
                cron: "0 0/1 * * * ?",
            },
        }),
        input: JSON.stringify({
            none: {},
        }),
        condition: JSON.stringify({
            always: {},
        }),
        actions: JSON.stringify({}),
        metadata: JSON.stringify({
            example_key: "example_value",
        }),
        transform: JSON.stringify({
            script: "return [ 'time' : ctx.trigger.scheduled_time ]",
        }),
        throttlePeriodInMillis: 10000,
    });
    export const watch = example.watchId;
    
    import pulumi
    import json
    import pulumi_elasticstack as elasticstack
    
    example = elasticstack.ElasticsearchWatch("example",
        watch_id="test_watch",
        active=True,
        trigger=json.dumps({
            "schedule": {
                "cron": "0 0/1 * * * ?",
            },
        }),
        input=json.dumps({
            "none": {},
        }),
        condition=json.dumps({
            "always": {},
        }),
        actions=json.dumps({}),
        metadata=json.dumps({
            "example_key": "example_value",
        }),
        transform=json.dumps({
            "script": "return [ 'time' : ctx.trigger.scheduled_time ]",
        }),
        throttle_period_in_millis=10000)
    pulumi.export("watch", example.watch_id)
    
    package main
    
    import (
    	"encoding/json"
    
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/elasticstack/elasticstack"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		tmpJSON0, err := json.Marshal(map[string]interface{}{
    			"schedule": map[string]interface{}{
    				"cron": "0 0/1 * * * ?",
    			},
    		})
    		if err != nil {
    			return err
    		}
    		json0 := string(tmpJSON0)
    		tmpJSON1, err := json.Marshal(map[string]interface{}{
    			"none": map[string]interface{}{},
    		})
    		if err != nil {
    			return err
    		}
    		json1 := string(tmpJSON1)
    		tmpJSON2, err := json.Marshal(map[string]interface{}{
    			"always": map[string]interface{}{},
    		})
    		if err != nil {
    			return err
    		}
    		json2 := string(tmpJSON2)
    		tmpJSON3, err := json.Marshal(map[string]interface{}{})
    		if err != nil {
    			return err
    		}
    		json3 := string(tmpJSON3)
    		tmpJSON4, err := json.Marshal(map[string]interface{}{
    			"example_key": "example_value",
    		})
    		if err != nil {
    			return err
    		}
    		json4 := string(tmpJSON4)
    		tmpJSON5, err := json.Marshal(map[string]interface{}{
    			"script": "return [ 'time' : ctx.trigger.scheduled_time ]",
    		})
    		if err != nil {
    			return err
    		}
    		json5 := string(tmpJSON5)
    		example, err := elasticstack.NewElasticsearchWatch(ctx, "example", &elasticstack.ElasticsearchWatchArgs{
    			WatchId:                pulumi.String("test_watch"),
    			Active:                 pulumi.Bool(true),
    			Trigger:                pulumi.String(json0),
    			Input:                  pulumi.String(json1),
    			Condition:              pulumi.String(json2),
    			Actions:                pulumi.String(json3),
    			Metadata:               pulumi.String(json4),
    			Transform:              pulumi.String(json5),
    			ThrottlePeriodInMillis: pulumi.Float64(10000),
    		})
    		if err != nil {
    			return err
    		}
    		ctx.Export("watch", example.WatchId)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using System.Text.Json;
    using Pulumi;
    using Elasticstack = Pulumi.Elasticstack;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Elasticstack.ElasticsearchWatch("example", new()
        {
            WatchId = "test_watch",
            Active = true,
            Trigger = JsonSerializer.Serialize(new Dictionary<string, object?>
            {
                ["schedule"] = new Dictionary<string, object?>
                {
                    ["cron"] = "0 0/1 * * * ?",
                },
            }),
            Input = JsonSerializer.Serialize(new Dictionary<string, object?>
            {
                ["none"] = new Dictionary<string, object?>
                {
                },
            }),
            Condition = JsonSerializer.Serialize(new Dictionary<string, object?>
            {
                ["always"] = new Dictionary<string, object?>
                {
                },
            }),
            Actions = JsonSerializer.Serialize(new Dictionary<string, object?>
            {
            }),
            Metadata = JsonSerializer.Serialize(new Dictionary<string, object?>
            {
                ["example_key"] = "example_value",
            }),
            Transform = JsonSerializer.Serialize(new Dictionary<string, object?>
            {
                ["script"] = "return [ 'time' : ctx.trigger.scheduled_time ]",
            }),
            ThrottlePeriodInMillis = 10000,
        });
    
        return new Dictionary<string, object?>
        {
            ["watch"] = example.WatchId,
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.elasticstack.ElasticsearchWatch;
    import com.pulumi.elasticstack.ElasticsearchWatchArgs;
    import static com.pulumi.codegen.internal.Serialization.*;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new ElasticsearchWatch("example", ElasticsearchWatchArgs.builder()
                .watchId("test_watch")
                .active(true)
                .trigger(serializeJson(
                    jsonObject(
                        jsonProperty("schedule", jsonObject(
                            jsonProperty("cron", "0 0/1 * * * ?")
                        ))
                    )))
                .input(serializeJson(
                    jsonObject(
                        jsonProperty("none", jsonObject(
    
                        ))
                    )))
                .condition(serializeJson(
                    jsonObject(
                        jsonProperty("always", jsonObject(
    
                        ))
                    )))
                .actions(serializeJson(
                    jsonObject(
    
                    )))
                .metadata(serializeJson(
                    jsonObject(
                        jsonProperty("example_key", "example_value")
                    )))
                .transform(serializeJson(
                    jsonObject(
                        jsonProperty("script", "return [ 'time' : ctx.trigger.scheduled_time ]")
                    )))
                .throttlePeriodInMillis(10000.0)
                .build());
    
            ctx.export("watch", example.watchId());
        }
    }
    
    resources:
      example:
        type: elasticstack:ElasticsearchWatch
        properties:
          watchId: test_watch
          active: true
          trigger:
            fn::toJSON:
              schedule:
                cron: 0 0/1 * * * ?
          input:
            fn::toJSON:
              none: {}
          condition:
            fn::toJSON:
              always: {}
          actions:
            fn::toJSON: {}
          metadata:
            fn::toJSON:
              example_key: example_value
          transform:
            fn::toJSON:
              script: 'return [ ''time'' : ctx.trigger.scheduled_time ]'
          throttlePeriodInMillis: 10000
    outputs:
      watch: ${example.watchId}
    

    Create ElasticsearchWatch Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new ElasticsearchWatch(name: string, args: ElasticsearchWatchArgs, opts?: CustomResourceOptions);
    @overload
    def ElasticsearchWatch(resource_name: str,
                           args: ElasticsearchWatchArgs,
                           opts: Optional[ResourceOptions] = None)
    
    @overload
    def ElasticsearchWatch(resource_name: str,
                           opts: Optional[ResourceOptions] = None,
                           trigger: Optional[str] = None,
                           watch_id: Optional[str] = None,
                           actions: Optional[str] = None,
                           active: Optional[bool] = None,
                           condition: Optional[str] = None,
                           elasticsearch_connections: Optional[Sequence[ElasticsearchWatchElasticsearchConnectionArgs]] = None,
                           input: Optional[str] = None,
                           metadata: Optional[str] = None,
                           throttle_period_in_millis: Optional[float] = None,
                           transform: Optional[str] = None)
    func NewElasticsearchWatch(ctx *Context, name string, args ElasticsearchWatchArgs, opts ...ResourceOption) (*ElasticsearchWatch, error)
    public ElasticsearchWatch(string name, ElasticsearchWatchArgs args, CustomResourceOptions? opts = null)
    public ElasticsearchWatch(String name, ElasticsearchWatchArgs args)
    public ElasticsearchWatch(String name, ElasticsearchWatchArgs args, CustomResourceOptions options)
    
    type: elasticstack:ElasticsearchWatch
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args ElasticsearchWatchArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args ElasticsearchWatchArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args ElasticsearchWatchArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ElasticsearchWatchArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ElasticsearchWatchArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var elasticsearchWatchResource = new Elasticstack.ElasticsearchWatch("elasticsearchWatchResource", new()
    {
        Trigger = "string",
        WatchId = "string",
        Actions = "string",
        Active = false,
        Condition = "string",
        ElasticsearchConnections = new[]
        {
            new Elasticstack.Inputs.ElasticsearchWatchElasticsearchConnectionArgs
            {
                ApiKey = "string",
                BearerToken = "string",
                CaData = "string",
                CaFile = "string",
                CertData = "string",
                CertFile = "string",
                Endpoints = new[]
                {
                    "string",
                },
                EsClientAuthentication = "string",
                Headers = 
                {
                    { "string", "string" },
                },
                Insecure = false,
                KeyData = "string",
                KeyFile = "string",
                Password = "string",
                Username = "string",
            },
        },
        Input = "string",
        Metadata = "string",
        ThrottlePeriodInMillis = 0,
        Transform = "string",
    });
    
    example, err := elasticstack.NewElasticsearchWatch(ctx, "elasticsearchWatchResource", &elasticstack.ElasticsearchWatchArgs{
    	Trigger:   pulumi.String("string"),
    	WatchId:   pulumi.String("string"),
    	Actions:   pulumi.String("string"),
    	Active:    pulumi.Bool(false),
    	Condition: pulumi.String("string"),
    	ElasticsearchConnections: elasticstack.ElasticsearchWatchElasticsearchConnectionArray{
    		&elasticstack.ElasticsearchWatchElasticsearchConnectionArgs{
    			ApiKey:      pulumi.String("string"),
    			BearerToken: pulumi.String("string"),
    			CaData:      pulumi.String("string"),
    			CaFile:      pulumi.String("string"),
    			CertData:    pulumi.String("string"),
    			CertFile:    pulumi.String("string"),
    			Endpoints: pulumi.StringArray{
    				pulumi.String("string"),
    			},
    			EsClientAuthentication: pulumi.String("string"),
    			Headers: pulumi.StringMap{
    				"string": pulumi.String("string"),
    			},
    			Insecure: pulumi.Bool(false),
    			KeyData:  pulumi.String("string"),
    			KeyFile:  pulumi.String("string"),
    			Password: pulumi.String("string"),
    			Username: pulumi.String("string"),
    		},
    	},
    	Input:                  pulumi.String("string"),
    	Metadata:               pulumi.String("string"),
    	ThrottlePeriodInMillis: pulumi.Float64(0),
    	Transform:              pulumi.String("string"),
    })
    
    var elasticsearchWatchResource = new ElasticsearchWatch("elasticsearchWatchResource", ElasticsearchWatchArgs.builder()
        .trigger("string")
        .watchId("string")
        .actions("string")
        .active(false)
        .condition("string")
        .elasticsearchConnections(ElasticsearchWatchElasticsearchConnectionArgs.builder()
            .apiKey("string")
            .bearerToken("string")
            .caData("string")
            .caFile("string")
            .certData("string")
            .certFile("string")
            .endpoints("string")
            .esClientAuthentication("string")
            .headers(Map.of("string", "string"))
            .insecure(false)
            .keyData("string")
            .keyFile("string")
            .password("string")
            .username("string")
            .build())
        .input("string")
        .metadata("string")
        .throttlePeriodInMillis(0.0)
        .transform("string")
        .build());
    
    elasticsearch_watch_resource = elasticstack.ElasticsearchWatch("elasticsearchWatchResource",
        trigger="string",
        watch_id="string",
        actions="string",
        active=False,
        condition="string",
        elasticsearch_connections=[{
            "api_key": "string",
            "bearer_token": "string",
            "ca_data": "string",
            "ca_file": "string",
            "cert_data": "string",
            "cert_file": "string",
            "endpoints": ["string"],
            "es_client_authentication": "string",
            "headers": {
                "string": "string",
            },
            "insecure": False,
            "key_data": "string",
            "key_file": "string",
            "password": "string",
            "username": "string",
        }],
        input="string",
        metadata="string",
        throttle_period_in_millis=float(0),
        transform="string")
    
    const elasticsearchWatchResource = new elasticstack.ElasticsearchWatch("elasticsearchWatchResource", {
        trigger: "string",
        watchId: "string",
        actions: "string",
        active: false,
        condition: "string",
        elasticsearchConnections: [{
            apiKey: "string",
            bearerToken: "string",
            caData: "string",
            caFile: "string",
            certData: "string",
            certFile: "string",
            endpoints: ["string"],
            esClientAuthentication: "string",
            headers: {
                string: "string",
            },
            insecure: false,
            keyData: "string",
            keyFile: "string",
            password: "string",
            username: "string",
        }],
        input: "string",
        metadata: "string",
        throttlePeriodInMillis: 0,
        transform: "string",
    });
    
    type: elasticstack:ElasticsearchWatch
    properties:
        actions: string
        active: false
        condition: string
        elasticsearchConnections:
            - apiKey: string
              bearerToken: string
              caData: string
              caFile: string
              certData: string
              certFile: string
              endpoints:
                - string
              esClientAuthentication: string
              headers:
                string: string
              insecure: false
              keyData: string
              keyFile: string
              password: string
              username: string
        input: string
        metadata: string
        throttlePeriodInMillis: 0
        transform: string
        trigger: string
        watchId: string
    

    ElasticsearchWatch Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The ElasticsearchWatch resource accepts the following input properties:

    Trigger string
    The trigger that defines when the watch should run.
    WatchId string
    Identifier for the watch.
    Actions string
    The list of actions that will be run if the condition matches.
    Active bool
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    Condition string
    The condition that defines if the actions should be run.
    ElasticsearchConnections List<ElasticsearchWatchElasticsearchConnection>
    Elasticsearch connection configuration block.
    Input string
    The input that defines the input that loads the data for the watch.
    Metadata string
    Metadata json that will be copied into the history entries.
    ThrottlePeriodInMillis double
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    Transform string
    Processes the watch payload to prepare it for the watch actions.
    Trigger string
    The trigger that defines when the watch should run.
    WatchId string
    Identifier for the watch.
    Actions string
    The list of actions that will be run if the condition matches.
    Active bool
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    Condition string
    The condition that defines if the actions should be run.
    ElasticsearchConnections []ElasticsearchWatchElasticsearchConnectionArgs
    Elasticsearch connection configuration block.
    Input string
    The input that defines the input that loads the data for the watch.
    Metadata string
    Metadata json that will be copied into the history entries.
    ThrottlePeriodInMillis float64
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    Transform string
    Processes the watch payload to prepare it for the watch actions.
    trigger String
    The trigger that defines when the watch should run.
    watchId String
    Identifier for the watch.
    actions String
    The list of actions that will be run if the condition matches.
    active Boolean
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    condition String
    The condition that defines if the actions should be run.
    elasticsearchConnections List<ElasticsearchWatchElasticsearchConnection>
    Elasticsearch connection configuration block.
    input String
    The input that defines the input that loads the data for the watch.
    metadata String
    Metadata json that will be copied into the history entries.
    throttlePeriodInMillis Double
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    transform String
    Processes the watch payload to prepare it for the watch actions.
    trigger string
    The trigger that defines when the watch should run.
    watchId string
    Identifier for the watch.
    actions string
    The list of actions that will be run if the condition matches.
    active boolean
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    condition string
    The condition that defines if the actions should be run.
    elasticsearchConnections ElasticsearchWatchElasticsearchConnection[]
    Elasticsearch connection configuration block.
    input string
    The input that defines the input that loads the data for the watch.
    metadata string
    Metadata json that will be copied into the history entries.
    throttlePeriodInMillis number
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    transform string
    Processes the watch payload to prepare it for the watch actions.
    trigger str
    The trigger that defines when the watch should run.
    watch_id str
    Identifier for the watch.
    actions str
    The list of actions that will be run if the condition matches.
    active bool
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    condition str
    The condition that defines if the actions should be run.
    elasticsearch_connections Sequence[ElasticsearchWatchElasticsearchConnectionArgs]
    Elasticsearch connection configuration block.
    input str
    The input that defines the input that loads the data for the watch.
    metadata str
    Metadata json that will be copied into the history entries.
    throttle_period_in_millis float
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    transform str
    Processes the watch payload to prepare it for the watch actions.
    trigger String
    The trigger that defines when the watch should run.
    watchId String
    Identifier for the watch.
    actions String
    The list of actions that will be run if the condition matches.
    active Boolean
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    condition String
    The condition that defines if the actions should be run.
    elasticsearchConnections List<Property Map>
    Elasticsearch connection configuration block.
    input String
    The input that defines the input that loads the data for the watch.
    metadata String
    Metadata json that will be copied into the history entries.
    throttlePeriodInMillis Number
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    transform String
    Processes the watch payload to prepare it for the watch actions.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the ElasticsearchWatch resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing ElasticsearchWatch Resource

    Get an existing ElasticsearchWatch resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: ElasticsearchWatchState, opts?: CustomResourceOptions): ElasticsearchWatch
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            actions: Optional[str] = None,
            active: Optional[bool] = None,
            condition: Optional[str] = None,
            elasticsearch_connections: Optional[Sequence[ElasticsearchWatchElasticsearchConnectionArgs]] = None,
            input: Optional[str] = None,
            metadata: Optional[str] = None,
            throttle_period_in_millis: Optional[float] = None,
            transform: Optional[str] = None,
            trigger: Optional[str] = None,
            watch_id: Optional[str] = None) -> ElasticsearchWatch
    func GetElasticsearchWatch(ctx *Context, name string, id IDInput, state *ElasticsearchWatchState, opts ...ResourceOption) (*ElasticsearchWatch, error)
    public static ElasticsearchWatch Get(string name, Input<string> id, ElasticsearchWatchState? state, CustomResourceOptions? opts = null)
    public static ElasticsearchWatch get(String name, Output<String> id, ElasticsearchWatchState state, CustomResourceOptions options)
    resources:  _:    type: elasticstack:ElasticsearchWatch    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Actions string
    The list of actions that will be run if the condition matches.
    Active bool
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    Condition string
    The condition that defines if the actions should be run.
    ElasticsearchConnections List<ElasticsearchWatchElasticsearchConnection>
    Elasticsearch connection configuration block.
    Input string
    The input that defines the input that loads the data for the watch.
    Metadata string
    Metadata json that will be copied into the history entries.
    ThrottlePeriodInMillis double
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    Transform string
    Processes the watch payload to prepare it for the watch actions.
    Trigger string
    The trigger that defines when the watch should run.
    WatchId string
    Identifier for the watch.
    Actions string
    The list of actions that will be run if the condition matches.
    Active bool
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    Condition string
    The condition that defines if the actions should be run.
    ElasticsearchConnections []ElasticsearchWatchElasticsearchConnectionArgs
    Elasticsearch connection configuration block.
    Input string
    The input that defines the input that loads the data for the watch.
    Metadata string
    Metadata json that will be copied into the history entries.
    ThrottlePeriodInMillis float64
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    Transform string
    Processes the watch payload to prepare it for the watch actions.
    Trigger string
    The trigger that defines when the watch should run.
    WatchId string
    Identifier for the watch.
    actions String
    The list of actions that will be run if the condition matches.
    active Boolean
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    condition String
    The condition that defines if the actions should be run.
    elasticsearchConnections List<ElasticsearchWatchElasticsearchConnection>
    Elasticsearch connection configuration block.
    input String
    The input that defines the input that loads the data for the watch.
    metadata String
    Metadata json that will be copied into the history entries.
    throttlePeriodInMillis Double
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    transform String
    Processes the watch payload to prepare it for the watch actions.
    trigger String
    The trigger that defines when the watch should run.
    watchId String
    Identifier for the watch.
    actions string
    The list of actions that will be run if the condition matches.
    active boolean
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    condition string
    The condition that defines if the actions should be run.
    elasticsearchConnections ElasticsearchWatchElasticsearchConnection[]
    Elasticsearch connection configuration block.
    input string
    The input that defines the input that loads the data for the watch.
    metadata string
    Metadata json that will be copied into the history entries.
    throttlePeriodInMillis number
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    transform string
    Processes the watch payload to prepare it for the watch actions.
    trigger string
    The trigger that defines when the watch should run.
    watchId string
    Identifier for the watch.
    actions str
    The list of actions that will be run if the condition matches.
    active bool
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    condition str
    The condition that defines if the actions should be run.
    elasticsearch_connections Sequence[ElasticsearchWatchElasticsearchConnectionArgs]
    Elasticsearch connection configuration block.
    input str
    The input that defines the input that loads the data for the watch.
    metadata str
    Metadata json that will be copied into the history entries.
    throttle_period_in_millis float
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    transform str
    Processes the watch payload to prepare it for the watch actions.
    trigger str
    The trigger that defines when the watch should run.
    watch_id str
    Identifier for the watch.
    actions String
    The list of actions that will be run if the condition matches.
    active Boolean
    Defines whether the watch is active or inactive by default. The default value is true, which means the watch is active by default.
    condition String
    The condition that defines if the actions should be run.
    elasticsearchConnections List<Property Map>
    Elasticsearch connection configuration block.
    input String
    The input that defines the input that loads the data for the watch.
    metadata String
    Metadata json that will be copied into the history entries.
    throttlePeriodInMillis Number
    Minimum time in milliseconds between actions being run. Defaults to 5000.
    transform String
    Processes the watch payload to prepare it for the watch actions.
    trigger String
    The trigger that defines when the watch should run.
    watchId String
    Identifier for the watch.

    Supporting Types

    ElasticsearchWatchElasticsearchConnection, ElasticsearchWatchElasticsearchConnectionArgs

    ApiKey string
    API Key to use for authentication to Elasticsearch
    BearerToken string
    Bearer Token to use for authentication to Elasticsearch
    CaData string
    PEM-encoded custom Certificate Authority certificate
    CaFile string
    Path to a custom Certificate Authority certificate
    CertData string
    PEM encoded certificate for client auth
    CertFile string
    Path to a file containing the PEM encoded certificate for client auth
    Endpoints List<string>
    EsClientAuthentication string
    ES Client Authentication field to be used with the JWT token
    Headers Dictionary<string, string>
    A list of headers to be sent with each request to Elasticsearch.
    Insecure bool
    Disable TLS certificate validation
    KeyData string
    PEM encoded private key for client auth
    KeyFile string
    Path to a file containing the PEM encoded private key for client auth
    Password string
    Password to use for API authentication to Elasticsearch.
    Username string
    Username to use for API authentication to Elasticsearch.
    ApiKey string
    API Key to use for authentication to Elasticsearch
    BearerToken string
    Bearer Token to use for authentication to Elasticsearch
    CaData string
    PEM-encoded custom Certificate Authority certificate
    CaFile string
    Path to a custom Certificate Authority certificate
    CertData string
    PEM encoded certificate for client auth
    CertFile string
    Path to a file containing the PEM encoded certificate for client auth
    Endpoints []string
    EsClientAuthentication string
    ES Client Authentication field to be used with the JWT token
    Headers map[string]string
    A list of headers to be sent with each request to Elasticsearch.
    Insecure bool
    Disable TLS certificate validation
    KeyData string
    PEM encoded private key for client auth
    KeyFile string
    Path to a file containing the PEM encoded private key for client auth
    Password string
    Password to use for API authentication to Elasticsearch.
    Username string
    Username to use for API authentication to Elasticsearch.
    apiKey String
    API Key to use for authentication to Elasticsearch
    bearerToken String
    Bearer Token to use for authentication to Elasticsearch
    caData String
    PEM-encoded custom Certificate Authority certificate
    caFile String
    Path to a custom Certificate Authority certificate
    certData String
    PEM encoded certificate for client auth
    certFile String
    Path to a file containing the PEM encoded certificate for client auth
    endpoints List<String>
    esClientAuthentication String
    ES Client Authentication field to be used with the JWT token
    headers Map<String,String>
    A list of headers to be sent with each request to Elasticsearch.
    insecure Boolean
    Disable TLS certificate validation
    keyData String
    PEM encoded private key for client auth
    keyFile String
    Path to a file containing the PEM encoded private key for client auth
    password String
    Password to use for API authentication to Elasticsearch.
    username String
    Username to use for API authentication to Elasticsearch.
    apiKey string
    API Key to use for authentication to Elasticsearch
    bearerToken string
    Bearer Token to use for authentication to Elasticsearch
    caData string
    PEM-encoded custom Certificate Authority certificate
    caFile string
    Path to a custom Certificate Authority certificate
    certData string
    PEM encoded certificate for client auth
    certFile string
    Path to a file containing the PEM encoded certificate for client auth
    endpoints string[]
    esClientAuthentication string
    ES Client Authentication field to be used with the JWT token
    headers {[key: string]: string}
    A list of headers to be sent with each request to Elasticsearch.
    insecure boolean
    Disable TLS certificate validation
    keyData string
    PEM encoded private key for client auth
    keyFile string
    Path to a file containing the PEM encoded private key for client auth
    password string
    Password to use for API authentication to Elasticsearch.
    username string
    Username to use for API authentication to Elasticsearch.
    api_key str
    API Key to use for authentication to Elasticsearch
    bearer_token str
    Bearer Token to use for authentication to Elasticsearch
    ca_data str
    PEM-encoded custom Certificate Authority certificate
    ca_file str
    Path to a custom Certificate Authority certificate
    cert_data str
    PEM encoded certificate for client auth
    cert_file str
    Path to a file containing the PEM encoded certificate for client auth
    endpoints Sequence[str]
    es_client_authentication str
    ES Client Authentication field to be used with the JWT token
    headers Mapping[str, str]
    A list of headers to be sent with each request to Elasticsearch.
    insecure bool
    Disable TLS certificate validation
    key_data str
    PEM encoded private key for client auth
    key_file str
    Path to a file containing the PEM encoded private key for client auth
    password str
    Password to use for API authentication to Elasticsearch.
    username str
    Username to use for API authentication to Elasticsearch.
    apiKey String
    API Key to use for authentication to Elasticsearch
    bearerToken String
    Bearer Token to use for authentication to Elasticsearch
    caData String
    PEM-encoded custom Certificate Authority certificate
    caFile String
    Path to a custom Certificate Authority certificate
    certData String
    PEM encoded certificate for client auth
    certFile String
    Path to a file containing the PEM encoded certificate for client auth
    endpoints List<String>
    esClientAuthentication String
    ES Client Authentication field to be used with the JWT token
    headers Map<String>
    A list of headers to be sent with each request to Elasticsearch.
    insecure Boolean
    Disable TLS certificate validation
    keyData String
    PEM encoded private key for client auth
    keyFile String
    Path to a file containing the PEM encoded private key for client auth
    password String
    Password to use for API authentication to Elasticsearch.
    username String
    Username to use for API authentication to Elasticsearch.

    Import

    The pulumi import command can be used, for example:

    $ pulumi import elasticstack:index/elasticsearchWatch:ElasticsearchWatch watch_id <cluster_uuid>/<watch ID>
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    elasticstack elastic/terraform-provider-elasticstack
    License
    Notes
    This Pulumi package is based on the elasticstack Terraform Provider.
    Viewing docs for elasticstack 0.14.5
    published on Thursday, Apr 23, 2026 by elastic
      Try Pulumi Cloud free. Your team will thank you.