Datadog v4.28.1 published on Monday, Jun 24, 2024 by Pulumi
datadog.getHosts
Explore with Pulumi AI
Use this data source to retrieve information about your live hosts in Datadog.
Example Usage
Coming soon!
Coming soon!
Coming soon!
Coming soon!
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.datadog.DatadogFunctions;
import com.pulumi.datadog.inputs.GetHostsArgs;
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) {
final var foo = DatadogFunctions.getHosts(GetHostsArgs.builder()
.includeMutedHostsData(true)
.includeHostsMetadata(true)
.build());
}
}
variables:
foo:
fn::invoke:
Function: datadog:getHosts
Arguments:
includeMutedHostsData: true
includeHostsMetadata: true
Using getHosts
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getHosts(args: GetHostsArgs, opts?: InvokeOptions): Promise<GetHostsResult>
function getHostsOutput(args: GetHostsOutputArgs, opts?: InvokeOptions): Output<GetHostsResult>
def get_hosts(filter: Optional[str] = None,
from_: Optional[int] = None,
include_muted_hosts_data: Optional[bool] = None,
sort_dir: Optional[str] = None,
sort_field: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetHostsResult
def get_hosts_output(filter: Optional[pulumi.Input[str]] = None,
from_: Optional[pulumi.Input[int]] = None,
include_muted_hosts_data: Optional[pulumi.Input[bool]] = None,
sort_dir: Optional[pulumi.Input[str]] = None,
sort_field: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetHostsResult]
func GetHosts(ctx *Context, args *GetHostsArgs, opts ...InvokeOption) (*GetHostsResult, error)
func GetHostsOutput(ctx *Context, args *GetHostsOutputArgs, opts ...InvokeOption) GetHostsResultOutput
> Note: This function is named GetHosts
in the Go SDK.
public static class GetHosts
{
public static Task<GetHostsResult> InvokeAsync(GetHostsArgs args, InvokeOptions? opts = null)
public static Output<GetHostsResult> Invoke(GetHostsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetHostsResult> getHosts(GetHostsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: datadog:index/getHosts:getHosts
arguments:
# arguments dictionary
The following arguments are supported:
- Filter string
- String to filter search results.
- From int
- Number of seconds since UNIX epoch from which you want to search your hosts.
- Include
Muted boolHosts Data - Include information on the muted status of hosts and when the mute expires.
- Sort
Dir string - Direction of sort.
- Sort
Field string - Sort hosts by this field.
- Filter string
- String to filter search results.
- From int
- Number of seconds since UNIX epoch from which you want to search your hosts.
- Include
Muted boolHosts Data - Include information on the muted status of hosts and when the mute expires.
- Sort
Dir string - Direction of sort.
- Sort
Field string - Sort hosts by this field.
- filter String
- String to filter search results.
- from Integer
- Number of seconds since UNIX epoch from which you want to search your hosts.
- include
Muted BooleanHosts Data - Include information on the muted status of hosts and when the mute expires.
- sort
Dir String - Direction of sort.
- sort
Field String - Sort hosts by this field.
- filter string
- String to filter search results.
- from number
- Number of seconds since UNIX epoch from which you want to search your hosts.
- include
Muted booleanHosts Data - Include information on the muted status of hosts and when the mute expires.
- sort
Dir string - Direction of sort.
- sort
Field string - Sort hosts by this field.
- filter str
- String to filter search results.
- from_ int
- Number of seconds since UNIX epoch from which you want to search your hosts.
- include_
muted_ boolhosts_ data - Include information on the muted status of hosts and when the mute expires.
- sort_
dir str - Direction of sort.
- sort_
field str - Sort hosts by this field.
- filter String
- String to filter search results.
- from Number
- Number of seconds since UNIX epoch from which you want to search your hosts.
- include
Muted BooleanHosts Data - Include information on the muted status of hosts and when the mute expires.
- sort
Dir String - Direction of sort.
- sort
Field String - Sort hosts by this field.
getHosts Result
The following output properties are available:
- Host
Lists List<GetHosts Host List> - List of hosts (1000 Max).
- Id string
- The ID of this resource.
- Total
Matching int - Number of host matching the query.
- Total
Returned int - Number of host returned.
- Filter string
- String to filter search results.
- From int
- Number of seconds since UNIX epoch from which you want to search your hosts.
- Include
Muted boolHosts Data - Include information on the muted status of hosts and when the mute expires.
- Sort
Dir string - Direction of sort.
- Sort
Field string - Sort hosts by this field.
- Host
Lists []GetHosts Host List - List of hosts (1000 Max).
- Id string
- The ID of this resource.
- Total
Matching int - Number of host matching the query.
- Total
Returned int - Number of host returned.
- Filter string
- String to filter search results.
- From int
- Number of seconds since UNIX epoch from which you want to search your hosts.
- Include
Muted boolHosts Data - Include information on the muted status of hosts and when the mute expires.
- Sort
Dir string - Direction of sort.
- Sort
Field string - Sort hosts by this field.
- host
Lists List<GetHosts Host List> - List of hosts (1000 Max).
- id String
- The ID of this resource.
- total
Matching Integer - Number of host matching the query.
- total
Returned Integer - Number of host returned.
- filter String
- String to filter search results.
- from Integer
- Number of seconds since UNIX epoch from which you want to search your hosts.
- include
Muted BooleanHosts Data - Include information on the muted status of hosts and when the mute expires.
- sort
Dir String - Direction of sort.
- sort
Field String - Sort hosts by this field.
- host
Lists GetHosts Host List[] - List of hosts (1000 Max).
- id string
- The ID of this resource.
- total
Matching number - Number of host matching the query.
- total
Returned number - Number of host returned.
- filter string
- String to filter search results.
- from number
- Number of seconds since UNIX epoch from which you want to search your hosts.
- include
Muted booleanHosts Data - Include information on the muted status of hosts and when the mute expires.
- sort
Dir string - Direction of sort.
- sort
Field string - Sort hosts by this field.
- host_
lists Sequence[GetHosts Host List] - List of hosts (1000 Max).
- id str
- The ID of this resource.
- total_
matching int - Number of host matching the query.
- total_
returned int - Number of host returned.
- filter str
- String to filter search results.
- from_ int
- Number of seconds since UNIX epoch from which you want to search your hosts.
- include_
muted_ boolhosts_ data - Include information on the muted status of hosts and when the mute expires.
- sort_
dir str - Direction of sort.
- sort_
field str - Sort hosts by this field.
- host
Lists List<Property Map> - List of hosts (1000 Max).
- id String
- The ID of this resource.
- total
Matching Number - Number of host matching the query.
- total
Returned Number - Number of host returned.
- filter String
- String to filter search results.
- from Number
- Number of seconds since UNIX epoch from which you want to search your hosts.
- include
Muted BooleanHosts Data - Include information on the muted status of hosts and when the mute expires.
- sort
Dir String - Direction of sort.
- sort
Field String - Sort hosts by this field.
Supporting Types
GetHostsHostList
- Aliases List<string>
- Apps List<string>
- Aws
Name string - Host
Name string - Id int
- Is
Muted bool - Last
Reported intTime - Meta
Get
Hosts Host List Meta - Metrics
Get
Hosts Host List Metrics - Mute
Timeout int - Name string
- Sources List<string>
- Up bool
- Aliases []string
- Apps []string
- Aws
Name string - Host
Name string - Id int
- Is
Muted bool - Last
Reported intTime - Meta
Get
Hosts Host List Meta - Metrics
Get
Hosts Host List Metrics - Mute
Timeout int - Name string
- Sources []string
- Up bool
- aliases List<String>
- apps List<String>
- aws
Name String - host
Name String - id Integer
- is
Muted Boolean - last
Reported IntegerTime - meta
Get
Hosts Host List Meta - metrics
Get
Hosts Host List Metrics - mute
Timeout Integer - name String
- sources List<String>
- up Boolean
- aliases string[]
- apps string[]
- aws
Name string - host
Name string - id number
- is
Muted boolean - last
Reported numberTime - meta
Get
Hosts Host List Meta - metrics
Get
Hosts Host List Metrics - mute
Timeout number - name string
- sources string[]
- up boolean
- aliases Sequence[str]
- apps Sequence[str]
- aws_
name str - host_
name str - id int
- is_
muted bool - last_
reported_ inttime - meta
Get
Hosts Host List Meta - metrics
Get
Hosts Host List Metrics - mute_
timeout int - name str
- sources Sequence[str]
- up bool
- aliases List<String>
- apps List<String>
- aws
Name String - host
Name String - id Number
- is
Muted Boolean - last
Reported NumberTime - meta Property Map
- metrics Property Map
- mute
Timeout Number - name String
- sources List<String>
- up Boolean
GetHostsHostListMeta
- Agent
Version string - Cpu
Cores int - Gohai string
- Machine string
- Platform string
- Processor string
- Python
Version string - Socket
Fqdn string - Socket
Hostname string
- Agent
Version string - Cpu
Cores int - Gohai string
- Machine string
- Platform string
- Processor string
- Python
Version string - Socket
Fqdn string - Socket
Hostname string
- agent
Version String - cpu
Cores Integer - gohai String
- machine String
- platform String
- processor String
- python
Version String - socket
Fqdn String - socket
Hostname String
- agent
Version string - cpu
Cores number - gohai string
- machine string
- platform string
- processor string
- python
Version string - socket
Fqdn string - socket
Hostname string
- agent_
version str - cpu_
cores int - gohai str
- machine str
- platform str
- processor str
- python_
version str - socket_
fqdn str - socket_
hostname str
- agent
Version String - cpu
Cores Number - gohai String
- machine String
- platform String
- processor String
- python
Version String - socket
Fqdn String - socket
Hostname String
GetHostsHostListMetrics
Package Details
- Repository
- Datadog pulumi/pulumi-datadog
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
datadog
Terraform Provider.