1. Packages
  2. Honeycombio Provider
  3. API Docs
  4. getSlos
honeycombio 0.32.0 published on Monday, Apr 7, 2025 by honeycombio

honeycombio.getSlos

Explore with Pulumi AI

# Data Source: honeycombio.getSlos

The SLOs data source retrieves the SLOs of a dataset, with the option of narrowing the retrieval by providing a detail_filter.

Note Multi-Dataset SLOs are not supported yet for this data source.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as honeycombio from "@pulumi/honeycombio";

const config = new pulumi.Config();
const dataset = config.require("dataset");
const all = honeycombio.getSlos({
    dataset: dataset,
});
const foo = honeycombio.getSlos({
    dataset: dataset,
    detailFilters: [{
        name: "name",
        valueRegex: "foo_*",
    }],
});
Copy
import pulumi
import pulumi_honeycombio as honeycombio

config = pulumi.Config()
dataset = config.require("dataset")
all = honeycombio.get_slos(dataset=dataset)
foo = honeycombio.get_slos(dataset=dataset,
    detail_filters=[{
        "name": "name",
        "value_regex": "foo_*",
    }])
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/honeycombio/honeycombio"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		cfg := config.New(ctx, "")
		dataset := cfg.Require("dataset")
		_, err := honeycombio.GetSlos(ctx, &honeycombio.GetSlosArgs{
			Dataset: dataset,
		}, nil)
		if err != nil {
			return err
		}
		_, err = honeycombio.GetSlos(ctx, &honeycombio.GetSlosArgs{
			Dataset: dataset,
			DetailFilters: []honeycombio.GetSlosDetailFilter{
				{
					Name:       "name",
					ValueRegex: pulumi.StringRef("foo_*"),
				},
			},
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Honeycombio = Pulumi.Honeycombio;

return await Deployment.RunAsync(() => 
{
    var config = new Config();
    var dataset = config.Require("dataset");
    var all = Honeycombio.GetSlos.Invoke(new()
    {
        Dataset = dataset,
    });

    var foo = Honeycombio.GetSlos.Invoke(new()
    {
        Dataset = dataset,
        DetailFilters = new[]
        {
            new Honeycombio.Inputs.GetSlosDetailFilterInputArgs
            {
                Name = "name",
                ValueRegex = "foo_*",
            },
        },
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.honeycombio.HoneycombioFunctions;
import com.pulumi.honeycombio.inputs.GetSlosArgs;
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 config = ctx.config();
        final var dataset = config.get("dataset");
        final var all = HoneycombioFunctions.getSlos(GetSlosArgs.builder()
            .dataset(dataset)
            .build());

        final var foo = HoneycombioFunctions.getSlos(GetSlosArgs.builder()
            .dataset(dataset)
            .detailFilters(GetSlosDetailFilterArgs.builder()
                .name("name")
                .valueRegex("foo_*")
                .build())
            .build());

    }
}
Copy
configuration:
  dataset:
    type: string
variables:
  all:
    fn::invoke:
      function: honeycombio:getSlos
      arguments:
        dataset: ${dataset}
  foo:
    fn::invoke:
      function: honeycombio:getSlos
      arguments:
        dataset: ${dataset}
        detailFilters:
          - name: name
            valueRegex: foo_*
Copy

Using getSlos

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 getSlos(args: GetSlosArgs, opts?: InvokeOptions): Promise<GetSlosResult>
function getSlosOutput(args: GetSlosOutputArgs, opts?: InvokeOptions): Output<GetSlosResult>
Copy
def get_slos(dataset: Optional[str] = None,
             detail_filters: Optional[Sequence[GetSlosDetailFilter]] = None,
             opts: Optional[InvokeOptions] = None) -> GetSlosResult
def get_slos_output(dataset: Optional[pulumi.Input[str]] = None,
             detail_filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetSlosDetailFilterArgs]]]] = None,
             opts: Optional[InvokeOptions] = None) -> Output[GetSlosResult]
Copy
func GetSlos(ctx *Context, args *GetSlosArgs, opts ...InvokeOption) (*GetSlosResult, error)
func GetSlosOutput(ctx *Context, args *GetSlosOutputArgs, opts ...InvokeOption) GetSlosResultOutput
Copy

> Note: This function is named GetSlos in the Go SDK.

public static class GetSlos 
{
    public static Task<GetSlosResult> InvokeAsync(GetSlosArgs args, InvokeOptions? opts = null)
    public static Output<GetSlosResult> Invoke(GetSlosInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetSlosResult> getSlos(GetSlosArgs args, InvokeOptions options)
public static Output<GetSlosResult> getSlos(GetSlosArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: honeycombio:index/getSlos:getSlos
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Dataset This property is required. string
The dataset to retrieve the SLOs list from
DetailFilters List<GetSlosDetailFilter>
a block to further filter results as described below. name must be set when providing a filter.
Dataset This property is required. string
The dataset to retrieve the SLOs list from
DetailFilters []GetSlosDetailFilter
a block to further filter results as described below. name must be set when providing a filter.
dataset This property is required. String
The dataset to retrieve the SLOs list from
detailFilters List<GetSlosDetailFilter>
a block to further filter results as described below. name must be set when providing a filter.
dataset This property is required. string
The dataset to retrieve the SLOs list from
detailFilters GetSlosDetailFilter[]
a block to further filter results as described below. name must be set when providing a filter.
dataset This property is required. str
The dataset to retrieve the SLOs list from
detail_filters Sequence[GetSlosDetailFilter]
a block to further filter results as described below. name must be set when providing a filter.
dataset This property is required. String
The dataset to retrieve the SLOs list from
detailFilters List<Property Map>
a block to further filter results as described below. name must be set when providing a filter.

getSlos Result

The following output properties are available:

Dataset string
Id string
Ids List<string>
a list of all the SLO IDs found in the dataset
DetailFilters List<GetSlosDetailFilter>
Dataset string
Id string
Ids []string
a list of all the SLO IDs found in the dataset
DetailFilters []GetSlosDetailFilter
dataset String
id String
ids List<String>
a list of all the SLO IDs found in the dataset
detailFilters List<GetSlosDetailFilter>
dataset string
id string
ids string[]
a list of all the SLO IDs found in the dataset
detailFilters GetSlosDetailFilter[]
dataset str
id str
ids Sequence[str]
a list of all the SLO IDs found in the dataset
detail_filters Sequence[GetSlosDetailFilter]
dataset String
id String
ids List<String>
a list of all the SLO IDs found in the dataset
detailFilters List<Property Map>

Supporting Types

GetSlosDetailFilter

Name This property is required. string
The name of the detail field to filter by. Currently only name is supported.
Value string
The value of the detail field to match on.
ValueRegex string

A regular expression string to apply to the value of the detail field to match on.

Note one of value or value_regex is required.

Name This property is required. string
The name of the detail field to filter by. Currently only name is supported.
Value string
The value of the detail field to match on.
ValueRegex string

A regular expression string to apply to the value of the detail field to match on.

Note one of value or value_regex is required.

name This property is required. String
The name of the detail field to filter by. Currently only name is supported.
value String
The value of the detail field to match on.
valueRegex String

A regular expression string to apply to the value of the detail field to match on.

Note one of value or value_regex is required.

name This property is required. string
The name of the detail field to filter by. Currently only name is supported.
value string
The value of the detail field to match on.
valueRegex string

A regular expression string to apply to the value of the detail field to match on.

Note one of value or value_regex is required.

name This property is required. str
The name of the detail field to filter by. Currently only name is supported.
value str
The value of the detail field to match on.
value_regex str

A regular expression string to apply to the value of the detail field to match on.

Note one of value or value_regex is required.

name This property is required. String
The name of the detail field to filter by. Currently only name is supported.
value String
The value of the detail field to match on.
valueRegex String

A regular expression string to apply to the value of the detail field to match on.

Note one of value or value_regex is required.

Package Details

Repository
honeycombio honeycombio/terraform-provider-honeycombio
License
Notes
This Pulumi package is based on the honeycombio Terraform Provider.